diff --git a/ruoyi-admin/src/main/resources/templates/system/baseEvectionForm/baseEvectionForm.html b/ruoyi-admin/src/main/resources/templates/system/baseEvectionForm/baseEvectionForm.html
index b00bdbb3..672d69d1 100644
--- a/ruoyi-admin/src/main/resources/templates/system/baseEvectionForm/baseEvectionForm.html
+++ b/ruoyi-admin/src/main/resources/templates/system/baseEvectionForm/baseEvectionForm.html
@@ -29,14 +29,14 @@
-
-
+
+
-
-
+
+
-
-
+
搜索
@@ -64,6 +64,8 @@
var removeFlag = [[${@permission.hasPermi('system:baseEvectionForm:remove')}]];
var cancelFlag = [[${@permission.hasPermi('system:baseEvectionForm:cancel')}]];
var restoreFlag = [[${@permission.hasPermi('system:baseEvectionForm:restore')}]];
+ var hrRecordFlag = [[${@permission.hasPermi('system:baseEvectionForm:hrRecord')}]];
+ var hrApproveFlag = [[${@permission.hasPermi('system:baseEvectionForm:hrApprove')}]];
var auditStatusDatas = [[${@dict.getType('auditStatus')}]];
var useStatusDatas = [[${@dict.getType('useStatus')}]];
var administrationStatusDatas = [[${@dict.getType('administration_status')}]];
@@ -118,6 +120,9 @@
{ title: '当前状态',field: 'taskStatus',
align: 'center',
formatter: function(value, row, index) {
+ if(value == "未启动" || value == "审核拒绝"){
+ return '' + value + '';
+ }
return '' + value + '';
}
},
@@ -138,7 +143,7 @@
}
},
{title: '出差单编号',field: 'evectionCode',align: 'center',},
- {title: '出差人',field: 'evectionBy',align: 'center',},
+ {title: '出差人',field: 'evectionBy',align: 'center',visible: false,},
{title: '同行人',field: 'partnerBy',align: 'center',},
{title: '出差地',field: 'evectionAddr',align: 'center',},
{title: '出差详细地址',field: 'evectionDetailAddr',align: 'center',},
@@ -161,10 +166,24 @@
align: 'center',
formatter: function(value, row, index) {
var actions = [];
- // 审核状态-审核通过
- if(row.auditStatus=="1"){
+ // 审核状态-审核通过 使用状态是
+ if(row.auditStatus=="1"&&row.useStatus == "1"&&row.personnelAdministration == "0"){
// 编辑
// actions.push(' 编辑 ');
+ actions.push(' 出行费用 ');
+ }
+ if(row.auditStatus=="1"&&row.useStatus == "1"&&row.personnelAdministration == "1"){
+ // 核准
+ actions.push(' 核准 ');
+ }
+ if(row.auditStatus == "1"&& row.useStatus == "1"){
+ // 作废
+ actions.push(' 作废');
+ }
+ // 已作废
+ if(row.useStatus=="2" && !row.restoreInstanceId){
+ // 恢复
+ actions.push(' 恢复 ');
}
// 有流程实例id
if (row.instanceId) {
@@ -197,7 +216,39 @@
}
};
$.table.init(options);
+ selectUserAll();
});
+
+ function cancel(id) {
+ $.modal.confirm("确定作废该出差单信息吗?", function() {
+ var url = prefix + "/cancel/" + id;
+ $.modal.open("作废", url);
+ })
+ }
+ function selectUserAll(){
+ $.ajax({
+ url: ctx +'system/baseExpense/getExpenseUser',
+ type: 'post',
+ async: false,
+ success: function (result) {
+ userList = result.data;
+ var selectUser = $("select[name='applyUser']");
+ var selectHtml = '';
+ userList.forEach(function (user) {
+ selectHtml += '';
+ });
+ selectUser.html(selectHtml);
+ }
+ });
+ }
+
+ function hrRecord(evectionId){
+ $.modal.open("出行费用",prefix + "/hrRecord/" + evectionId);
+ }
+
+ function hrApprove(evectionId){
+ $.modal.open("核准",prefix + "/hrApprove/" + evectionId);
+ }