review taskHistory.html

This commit is contained in:
yuebenshan committed 2023-02-14 17:16:18 +08:00
1 parent 8adc013351
commit dc2e284685
1 file changed
+19 -44
+19 -44
View File
@@ -16,7 +16,6 @@
<v-breadcrumbs class="pb-3 pt-0 px-0" :items="breadcrumbs" divider="-"></v-breadcrumbs> <v-breadcrumbs class="pb-3 pt-0 px-0" :items="breadcrumbs" divider="-"></v-breadcrumbs>
</div> </div>
<!-- <<<<<<<<<<<<< 头部内容 --> <!-- <<<<<<<<<<<<< 头部内容 -->
<div class="jh-page-body-container px-8"> <div class="jh-page-body-container px-8">
<!-- 页面内容 >>>>>>>>>>>>> --> <!-- 页面内容 >>>>>>>>>>>>> -->
<v-card class="rounded-lg"> <v-card class="rounded-lg">
@@ -41,30 +40,22 @@
checkbox-color="success" checkbox-color="success"
fixed-header fixed-header
class="jh-fixed-table-height elevation-0 mt-0 mb-xs-4"> class="jh-fixed-table-height elevation-0 mt-0 mb-xs-4">
<!--标题-->
<template v-slot:item.taskTitle="{ item }"> <template v-slot:item.taskTitle="{ item }">
<span>{{item.taskTitle}}</span> <span>{{item.taskTitle}}</span>
</template> </template>
<!--审核状态-->
<template v-slot:item.taskStatus="{ item }"> <template v-slot:item.taskStatus="{ item }">
<v-chip <v-chip v-if="item.taskStatus === '已结束'" color="red" x-small dark>
v-if="item.taskStatus === '已结束'"
color="red"
small dark
>
{{item.taskStatus}} {{item.taskStatus}}
</v-chip> </v-chip>
<v-chip <v-chip v-else color="green" x-small dark >
v-else
color="green"
small dark
>
{{item.taskStatus}} {{item.taskStatus}}
</v-chip> </v-chip>
</template> </template>
<!--表格行操作按钮--> <!--表格行操作按钮-->
<template v-slot:item.action="{ item }"> <template v-slot:item.action="{ item }">
<span role="button" class="success--text jh-font-size-3 pr-2" <span role="button" class="success--text jh-font-size-3 pr-2" @click="doUiAction('startUpdateItem', item)">
@click="doUiAction('startUpdateItem', item)">
<v-icon size="14" class="success--text">mdi-text-box-outline</v-icon> <v-icon size="14" class="success--text">mdi-text-box-outline</v-icon>
查看 查看
</span> </span>
@@ -108,12 +99,12 @@
</v-row> </v-row>
<!--抽屉表单--> <!--抽屉表单-->
<v-row class="mt-0 px-6"> <v-row class="mt-0 px-6">
<v-col cols="12" sm="12" md="4" v-for="(item, index) in updateItem.taskFormInput.formList" :key="index"> <v-col cols="12" sm="12" md="4" v-for="(item, index) in viewItem.taskFormInput.formList" :key="index">
<form-item :form-item="item" readonly></form-item> <form-item :form-item="item" readonly></form-item>
</v-col> </v-col>
<v-col cols="12" sm="12" md="12"> <v-col cols="12" sm="12" md="12">
<span class="jh-input-label">审核申请信息</span> <span class="jh-input-label">审核申请信息</span>
<task-history :task-id="updateItem.taskId"></task-history> <task-history :task-id="viewItem.taskId"></task-history>
</v-col> </v-col>
</v-row> </v-row>
</v-form> </v-form>
@@ -129,8 +120,7 @@
<!-- 帮助页抽屉 >>>>>>>>>>>>> --> <!-- 帮助页抽屉 >>>>>>>>>>>>> -->
<v-navigation-drawer v-model="isHelpPageDrawerShown" v-click-outside="drawerClickOutside" fixed temporary right width="80%" <v-navigation-drawer v-model="isHelpPageDrawerShown" v-click-outside="drawerClickOutside" fixed temporary right width="80%"
class="elevation-24"> class="elevation-24">
<iframe style="border: 0" :src="`/${appInfo.appId}/pageDoc#taskHistory.md`" width="100%" <iframe style="border: 0" :src="`/${appInfo.appId}/pageDoc#taskHistory.md`" width="100%" height="100%"></iframe>
height="100%"></iframe>
<v-btn elevation="0" color="success" fab absolute top left small tile class="drawer-close-float-btn" <v-btn elevation="0" color="success" fab absolute top left small tile class="drawer-close-float-btn"
@click="isHelpPageDrawerShown = false"> @click="isHelpPageDrawerShown = false">
@@ -171,17 +161,10 @@
data: { data: {
// 面包屑 // 面包屑
breadcrumbs: [ breadcrumbs: [
{ {text: '首页', disabled: true,},
text: '首页', {text: '全部任务列表', disabled: true,}
disabled: true,
},
{
text: '全部任务列表',
disabled: true,
}
], ],
isHelpPageDrawerShown: false, isHelpPageDrawerShown: false,
// 表格相关数据 // 表格相关数据
isTableZebraLineShown: true, isTableZebraLineShown: true,
// 生日日期选择 // 生日日期选择
@@ -193,9 +176,8 @@
searchInput: null, searchInput: null,
isTableLoading: true, isTableLoading: true,
tableData: [], tableData: [],
historyData: [],
headers: [ headers: [
{ text: '操作', value: 'action', align: 'center', sortable: false, width: 120, class: 'fixed', cellClass: 'fixed' }, { text: '操作', value: 'action', align: 'center', sortable: false, width: 80, class: 'fixed', cellClass: 'fixed' },
{ text: "审批项", value: "taskTitle" }, { text: "审批项", value: "taskTitle" },
{ text: "审核状态", value: "taskStatus" }, { text: "审核状态", value: "taskStatus" },
{ text: "操作者", value: "operationByUser", width: 120 }, { text: "操作者", value: "operationByUser", width: 120 },
@@ -203,9 +185,7 @@
], ],
isViewDrawerShown: false, isViewDrawerShown: false,
updateItem: {}, viewItem: {},
workflowType: 'todo', // todo, history
lineTypeList: [],
userId: '<$ ctx.userInfo.userId $>' userId: '<$ ctx.userInfo.userId $>'
}, },
// 计算 // 计算
@@ -226,8 +206,8 @@
await this.openDataPicker(uiActionData); await this.openDataPicker(uiActionData);
break; break;
case 'startUpdateItem': case 'startUpdateItem':
await this.prepareUpdateFormData(uiActionData); await this.prepareViewItemData(uiActionData);
await this.openUpdateDrawer(); await this.openViewDrawer();
break; break;
default: default:
console.error("[doUiAction] uiActionId not find", { uiActionId }); console.error("[doUiAction] uiActionId not find", { uiActionId });
@@ -261,20 +241,15 @@
this.tableData = rows; this.tableData = rows;
this.isTableLoading = false; this.isTableLoading = false;
}, },
// ---------- 审核、查看 uiAction >>>>>>>>>>>> -------- // ---------- 查看 uiAction >>>>>>>>>>>> --------
async prepareUpdateFormData(funObj) { async prepareViewItemData(funObj) {
this.updateItem = _.cloneDeep(funObj); this.viewItem = _.cloneDeep(funObj);
console.log(this.updateItem)
}, },
async closeSubmitDrawer() { async openViewDrawer() {
this.isViewDrawerShown = false;
},
async openUpdateDrawer() {
this.isViewDrawerShown = true; this.isViewDrawerShown = true;
}, },
// ---------- 审核、查看 uiAction >>>>>>>>>>>> -------- // ---------- 查看 uiAction >>>>>>>>>>>> --------
} }
}) })
</script> </script>