This commit is contained in:
mkm 2024-03-27 10:34:05 +08:00
parent b0714f610f
commit 2d278c23c2
2 changed files with 25 additions and 19 deletions

View File

@ -138,6 +138,10 @@ class ProjectTask extends Model
$item['priority_name'] = self::$Priority[(int) $item['priority']];
$item['flow_name'] = self::$FlowStatus[(int) $item['flow_status']];
$item['type_name'] = self::$Type[(int) $item['type']];
$item['create_time'] = date('Y-m-d H:i:s',$item['create_time']);
if ($item['admin_id'] > 0) {
$item['admin_name'] = Db::name('Admin')->where(['id' => $item['admin_id']])->value('name');
}
return $item;
});
return $list;

View File

@ -101,25 +101,27 @@
return html;
}
}
, { field: 'before_task', title: '前置任务编号',align: 'center', width: 110, templet: function (d) {
var html = '-';
if(d.before_task > 0){
html = '<a class="side-a" data-href="/project/task/view/id/' + d.before_task + '">T' + d.before_task + '</a>';
}
return html;
}
}
, { field: 'after_num', title: '后置任务数', align: 'center',width: 100, templet: function (d) {
var html = '-';
if(d.after_num > 0){
html = '<a class="blue" lay-event="more" style="cursor:pointer;">'+d.after_num+'</a>';
if(d.after_num == 1){
html = ' <a class="side-a" data-href="/project/task/view/id/' + d.after_id + '">'+d.after_num+'</a>';
}
}
return html;
}
}
// , { field: 'before_task', title: '前置任务编号',align: 'center', width: 110, templet: function (d) {
// var html = '-';
// if(d.before_task > 0){
// html = '<a class="side-a" data-href="/project/task/view/id/' + d.before_task + '">T' + d.before_task + '</a>';
// }
// return html;
// }
// }
// , { field: 'after_num', title: '后置任务数', align: 'center',width: 100, templet: function (d) {
// var html = '-';
// if(d.after_num > 0){
// html = '<a class="blue" lay-event="more" style="cursor:pointer;">'+d.after_num+'</a>';
// if(d.after_num == 1){
// html = ' <a class="side-a" data-href="/project/task/view/id/' + d.after_id + '">'+d.after_num+'</a>';
// }
// }
// return html;
// }
// }
, { field: 'admin_name', title: '创建人', width: 300 }
, { field: 'create_time', title: '创建时间', width: 300 }
, { field: 'project_name', title: '关联项目', width: 300 }
, { field: 'director_name', title: '负责人', align: 'center', width: 80 }
, { field: 'assist_admin_names', title: '协作人', width: 200 }