作者 郭盛
1 个管道 的构建 通过 耗费 8 秒

修改过期时间

@@ -152,6 +152,12 @@ @@ -152,6 +152,12 @@
152 {:build_radios('row[identity]', ['1'=>'普通会员','2'=>'黄金会员','3'=>'钻石会员'], $row['identity'])} 152 {:build_radios('row[identity]', ['1'=>'普通会员','2'=>'黄金会员','3'=>'钻石会员'], $row['identity'])}
153 </div> 153 </div>
154 </div> 154 </div>
  155 + <div class="form-group">
  156 + <label for="c-expirationtime" class="control-label col-xs-12 col-sm-2">{:__('到期时间')}:</label>
  157 + <div class="col-xs-12 col-sm-4">
  158 + <input id="c-expirationtime" data-rule="required" class="form-control datetimepicker" data-date-format="YYYY-MM-DD HH:mm:ss" data-use-current="true" name="row[expirationtime]" type="text" value="{$row.expirationtime|datetime}">
  159 + </div>
  160 + </div>
155 <div class="form-group layer-footer"> 161 <div class="form-group layer-footer">
156 <label class="control-label col-xs-12 col-sm-2"></label> 162 <label class="control-label col-xs-12 col-sm-2"></label>
157 <div class="col-xs-12 col-sm-8"> 163 <div class="col-xs-12 col-sm-8">
@@ -512,17 +512,27 @@ class Login extends Api @@ -512,17 +512,27 @@ class Login extends Api
512 } 512 }
513 if(empty($param['file_pwd'])){ 513 if(empty($param['file_pwd'])){
514 unset($param['file_pwd']); 514 unset($param['file_pwd']);
515 - }  
516 - $param['salt'] = Random::alnum();  
517 - $param['pwd'] = $param['password'];  
518 - $param['password'] = md5(md5($param['pwd']) . $param['salt']);  
519 - $data = Db::name('user')->where('id',$user_id)->update($param);  
520 - if(empty($data)){  
521 - $this->error('修改失败'); 515 + $data = Db::name('user')->where('id',$user_id)->update($param);
  516 + if(empty($data)){
  517 + $this->error('修改失败');
  518 + }else{
  519 + $this->success('SUCCESS');
  520 + }
  521 +
522 }else{ 522 }else{
523 - $this->success('SUCCESS'); 523 + $param['salt'] = Random::alnum();
  524 + $param['pwd'] = $param['password'];
  525 + $param['password'] = md5(md5($param['pwd']) . $param['salt']);
  526 + $param['whiteip_ids'] = '';
  527 + $data = Db::name('user')->where('id',$user_id)->update($param);
  528 + if(empty($data)){
  529 + $this->error('修改失败');
  530 + }else{
  531 + $this->success('SUCCESS');
  532 + }
524 } 533 }
525 534
  535 +
526 } 536 }
527 537
528 538
@@ -5621,6 +5621,7 @@ @@ -5621,6 +5621,7 @@
5621 "is_open": 1, 5621 "is_open": 1,
5622 "is_real": 1, 5622 "is_real": 1,
5623 "is_white": 1 5623 "is_white": 1
  5624 + "is_subscribe"://是否订阅 1订阅2未订阅
5624 } 5625 }
5625 ] 5626 ]
5626 } 5627 }
@@ -9091,7 +9092,7 @@ @@ -9091,7 +9092,7 @@
9091 9092
9092 <div class="row mt0 footer"> 9093 <div class="row mt0 footer">
9093 <div class="col-md-6" align="left"> 9094 <div class="col-md-6" align="left">
9094 - Generated on 2020-08-17 09:58:09 </div> 9095 + Generated on 2020-08-18 09:28:58 </div>
9095 <div class="col-md-6" align="right"> 9096 <div class="col-md-6" align="right">
9096 <a href="./" target="_blank">彩云盘</a> 9097 <a href="./" target="_blank">彩云盘</a>
9097 </div> 9098 </div>
@@ -33,6 +33,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin @@ -33,6 +33,7 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
33 {field: 'avatar', title: __('Avatar'), events: Table.api.events.image, formatter: Table.api.formatter.image, operate: false}, 33 {field: 'avatar', title: __('Avatar'), events: Table.api.events.image, formatter: Table.api.formatter.image, operate: false},
34 {field: 'audit', title: __('审核状态'), searchList: {"0":"待审核","1":"审核通过","2":'审核未通过'},formatter: Table.api.formatter.status}, 34 {field: 'audit', title: __('审核状态'), searchList: {"0":"待审核","1":"审核通过","2":'审核未通过'},formatter: Table.api.formatter.status},
35 {field: 'identity', title: __('身份标识'), searchList: {"1":"普通会员","2":"黄金会员","3":'钻石会员'},formatter: Table.api.formatter.flag}, 35 {field: 'identity', title: __('身份标识'), searchList: {"1":"普通会员","2":"黄金会员","3":'钻石会员'},formatter: Table.api.formatter.flag},
  36 + {field: 'expirationtime', title: __('过期时间'), formatter: Table.api.formatter.datetime, operate: 'RANGE', addclass: 'datetimerange', sortable: true},
36 // {field: 'level', title: __('Level'), operate: 'BETWEEN', sortable: true}, 37 // {field: 'level', title: __('Level'), operate: 'BETWEEN', sortable: true},
37 // {field: 'gender', title: __('Gender'), visible: false, searchList: {1: __('Male'), 0: __('Female')}}, 38 // {field: 'gender', title: __('Gender'), visible: false, searchList: {1: __('Male'), 0: __('Female')}},
38 // {field: 'score', title: __('Score'), operate: 'BETWEEN', sortable: true}, 39 // {field: 'score', title: __('Score'), operate: 'BETWEEN', sortable: true},