master
yulingwei 5 years ago
parent d9c338acd8
commit 175502e384

@ -176,7 +176,7 @@ class WorkOrderController extends ThinkController
case 2:
$data = array_merge(I('feedback'), $data);
$user = M('user', 'tab_')->where(['account'=>$data['user_account']])->find();
if (empty($user)) $this->error("账号不存在23123{$data['user_account']}");
if (empty($user)) $this->error("账号不存在{$data['user_account']}");
$log = $this->modifyProcessLog($info, $data);
if ($log) {
$process_log = json_decode($info['process_log'], true) ?: [];
@ -296,13 +296,11 @@ class WorkOrderController extends ThinkController
if (IS_POST) {
if (empty(I('evaluate_content'))) $this->error('请填写评价内容');
$data['score'] = I('evaluate', 5);
if($info['type'] == 2) {
$info['process_log'] = json_decode($info['process_log'], true);
$log = [['type'=>3, 'title'=>sprintf('%s于 %s 评价了工单%s为%s分工单状态%s', get_admin_name(is_login()), date('Y-m-d H:i:s'), $info['order_no'], $data['score'], $this->getOrderStatus($info['status'])), 'detail'=>I('evaluate_content')]];
$data['process_log'] = json_encode(array_merge($info['process_log'], $log));
$upt = M('work_order_info', 'tab_')->where(['id'=>$id])->save($data);
return $upt ? $this->success('评价成功', U('WorkOrder/list')) : $this->error('评价失败');
}
$info['process_log'] = json_decode($info['process_log'], true);
$log = [['type'=>3, 'title'=>sprintf('%s于 %s 评价了工单%s为%s分工单状态%s', get_admin_name(is_login()), date('Y-m-d H:i:s'), $info['order_no'], $data['score'], $this->getOrderStatus($info['status'])), 'detail'=>I('evaluate_content')]];
$data['process_log'] = json_encode(array_merge($info['process_log'], $log));
$upt = M('work_order_info', 'tab_')->where(['id'=>$id])->save($data);
return $upt ? $this->success('评价成功', U('WorkOrder/list')) : $this->error('评价失败');
} else {
$this->assign('data', $info);
$this->display('feedbackEvaluate');

@ -33,6 +33,9 @@
.tabcon1711 input {
width: 100%;
}
.tabcon1711 input[type=text], .tabcon1711 input[type=password] {
width: auto;
}
</style>
<style>
@ -154,7 +157,7 @@
<td class="r">
<div class="from-element from-input">
<input type="text" title="申请元宝或钻石数量" placeholder="申请元宝或钻石数量" class="my_text"
name='resource[apply_resource]' onkeyup="value=value.replace(/[^\d]/g,'')" value="{$data.resource_num}"></div>
name='resource[resource_num]' onkeyup="value=value.replace(/[^\d]/g,'')" value="{$data.resource_num}"></div>
</td>
<td class="r">
<div class="from-element from-input">

@ -34,6 +34,9 @@
.tabcon1711 input {
width: 100%;
}
.tabcon1711 input[type=text], .tabcon1711 input[type=password] {
width: auto;
}
</style>
<style>

Loading…
Cancel
Save