作者 王晓刚
1 个管道 的构建 通过 耗费 1 秒

修改问题文档

@@ -58,6 +58,7 @@ class Profile extends Backend @@ -58,6 +58,7 @@ class Profile extends Backend
58 if ($this->request->isPost()) { 58 if ($this->request->isPost()) {
59 $this->token(); 59 $this->token();
60 $params = $this->request->post("row/a"); 60 $params = $this->request->post("row/a");
  61 + $name = $params['name'];
61 $money = $params['money']; 62 $money = $params['money'];
62 $freight = $params['freight']; 63 $freight = $params['freight'];
63 $phone = $params['phone']; 64 $phone = $params['phone'];
@@ -91,7 +92,7 @@ class Profile extends Backend @@ -91,7 +92,7 @@ class Profile extends Backend
91 Session::set("admin", $admin->toArray()); 92 Session::set("admin", $admin->toArray());
92 $store_id = Db::name('admin')->where(['id'=>$this->auth->id])->value('store_id'); 93 $store_id = Db::name('admin')->where(['id'=>$this->auth->id])->value('store_id');
93 if(!empty($store_id)){ 94 if(!empty($store_id)){
94 - echo Db::name('store')->where(['id'=>$store_id])->update(['money'=>$money,'freight'=>$freight,'phone'=>$phone,'address'=>$address,'lng'=>$lng,'lat'=>$lat,'content'=>$content]); 95 + echo Db::name('store')->where(['id'=>$store_id])->update(['name'=>$name,'money'=>$money,'freight'=>$freight,'phone'=>$phone,'address'=>$address,'lng'=>$lng,'lat'=>$lat,'content'=>$content]);
95 } 96 }
96 $this->success(); 97 $this->success();
97 } 98 }
@@ -77,6 +77,10 @@ @@ -77,6 +77,10 @@
77 </div> 77 </div>
78 {notempty name="$admin.store_id"} 78 {notempty name="$admin.store_id"}
79 <div class="form-group"> 79 <div class="form-group">
  80 + <label class="control-label">{:__('店铺名称')}:</label>
  81 + <input id="c-name" data-rule="required" class="form-control" name="row[name]" type="text" value="{$row.name|htmlentities}">
  82 + </div>
  83 + <div class="form-group">
80 <label class="control-label">{:__('满免运费价格')}:</label> 84 <label class="control-label">{:__('满免运费价格')}:</label>
81 <input id="c-money" data-rule="required" class="form-control" name="row[money]" type="text" value="{$row.money|htmlentities}"> 85 <input id="c-money" data-rule="required" class="form-control" name="row[money]" type="text" value="{$row.money|htmlentities}">
82 </div> 86 </div>