d9e56607 by lxs

分类分级任务联调

1 parent 967a81c8
......@@ -254,26 +254,40 @@ export const getCgTaskDetail = (data) => request({
})
// 分来分级任务-新增
export const getCgTaskSave = (data) => request({
export const cgTaskSave = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-task/save`,
method: 'post',
data
})
// 分来分级任务-修改
export const getCgTaskUpdate = (data) => request({
export const cgTaskUpdate = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-task/update`,
method: 'put',
data
})
// 分来分级任务-删除
export const getCgTaskDelete = (data) => request({
export const cgTaskDelete = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-task/delete`,
method: 'delete',
data
})
// 手动执行任务
export const runExecTask = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-task/exec-task`,
method: 'put',
data
})
// 分类分级任务日志
export const getTaskExecPageList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-task-exec/page-list`,
method: 'post',
data
})
// 标签规则-分页
export const getCgLabelPageList = (data) => request({
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/cg-label/page-list`,
......@@ -317,7 +331,7 @@ export const filterVal = (val, type) => {
status = '已确认';
break;
default:
status = '草稿中';
status = '--';
break;
}
}
......
......@@ -86,7 +86,7 @@ export const getMetaDataBase = (params) => request({
})
// 表分页查询
export const getMetaDataSheet = (params) => request({
url: `${import.meta.env.VITE_APP_PLAN_BASEURL}/meta-table/meta-table-detail-list`,
url: `${import.meta.env.VITE_APP_CHECK_BASEURL}/meta-table/meta-table-detail-list`,
method: 'post',
data: params
})
......
......@@ -54,6 +54,7 @@ const useUserStore = defineStore(
userName.value = res.data.userName
// userData.value = JSON.stringify(res.data.data);
currentTenantGuid.value = res.data.tenantInfoList && res.data.tenantInfoList.length ? res.data.tenantInfoList[0].guid : '';
localStorage.setItem('currentTenantGuid', currentTenantGuid.value);
let currentTenant = res.data.tenantInfoList?.[0];
return getSystemMenu({ tenantGuid: currentTenantGuid.value }).then((info: any) => {
if (info.code == '00000') {
......
......@@ -9,7 +9,7 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, ElMessageBox } from "element-plus";
import useDataAssetStore from "@/store/modules/dataAsset";
import { filterVal, getCgTaskPageList, } from "@/api/modules/dataInventory";
import { filterVal, getCgTaskPageList, cgTaskDelete, runExecTask } from "@/api/modules/dataInventory";
import { TableColumnWidth } from '@/utils/enum';
import Table from "@/components/Table/index.vue";
......@@ -46,7 +46,12 @@ const tableInfo = ref({
});
}
},
{ label: "元数据", field: "metaNames", width: 200 },
{
label: "元数据", field: "metaNames", width: 200, getName: (scope) => {
const metaNames = scope.row.metaNames || [];
return metaNames.join(',');
}
},
{
label: "执行状态", field: "status", width: TableColumnWidth.STATE, align: 'center', type: "tag", getName: (scope) => {
return filterVal(scope.row.status, 'status');
......@@ -73,19 +78,18 @@ const tableInfo = ref({
actionInfo: {
label: "操作",
type: "btn",
width: 220,
width: 280,
btns: (scope) => {
let row = scope.row, btnArr: any = [
{ label: "手动执行", value: "run" },
{ label: "编辑", value: "edit" },
{ label: "日志", value: "log" },
{ label: "删除", value: "delete" }
];
if (row.status == 'Y') {
if (row.confirmStatus == 'Y') {
btnArr.splice(0, 0, { label: "结果修改", value: "modify" });
} else {
btnArr.splice(0, 0, { label: "结果确认", value: "confirm" });
}
if (row.confirmStatus == 'Y') {
btnArr.splice(0, 0, { label: "结果修改", value: "modify" });
} else {
btnArr.splice(0, 0, { label: "结果确认", value: "confirm", disabled: row.status != 'Y' });
}
return btnArr;
},
......@@ -115,8 +119,25 @@ const tableBtnClick = (scope, btn) => {
const type = btn.value;
const row = scope.row;
currTableData.value = row;
if(type == 'confirm' || type == 'modify' || type == 'edit' || type == "log"){
if (type == 'confirm' || type == 'modify' || type == 'edit' || type == "log") {
toPath(type);
} else if (type == 'run') {
const guids = [currTableData.value.guid];
runExecTask(guids).then((res: any) => {
if (res.code == proxy.$passCode) {
getFirstPageData();
} else {
ElMessage({
type: "error",
message: res.msg,
});
}
}).catch((res) => {
ElMessage({
type: "error",
message: '请求失败',
});
});
} else if (type === "delete") {
open("此操作将永久删除,是否继续?", "warning");
}
......@@ -130,21 +151,21 @@ const toPath = (type) => {
type
},
});
} else if(type == 'edit'){
} else if (type == 'edit') {
router.push({
name: "taskEdit",
query: {
guid: currTableData.value.guid,
name: currTableData.value.damName,
name: currTableData.value.taskName,
type
},
});
} else if(type == 'confirm' || type == 'modify'){
} else if (type == 'confirm' || type == 'modify') {
router.push({
name: "taskDetail",
query: {
guid: currTableData.value.guid,
name: currTableData.value.damName,
name: currTableData.value.taskName,
type
},
});
......@@ -153,7 +174,7 @@ const toPath = (type) => {
name: "taskLog",
query: {
guid: currTableData.value.guid,
name: currTableData.value.damName,
name: currTableData.value.taskName,
type
},
});
......@@ -175,7 +196,7 @@ const open = (msg, type, isBatch = false) => {
type: type,
}).then(() => {
const guids = [currTableData.value.guid];
listingDelete(guids).then((res: any) => {
cgTaskDelete(guids).then((res: any) => {
if (res.code == proxy.$passCode) {
getFirstPageData();
ElMessage({
......@@ -200,24 +221,22 @@ const getFirstPageData = () => {
getTableData();
}
// onActivated(() => {
// if (assetStore.isRefresh) {//如果是首次加载,则不需要调用
// getFirstPageData();
// assetStore.set(false);
// }
// })
onActivated(() => {
// if (assetStore.isRefresh) {//如果是首次加载,则不需要调用
// getFirstPageData();
// assetStore.set(false);
// }
getFirstPageData()
})
onBeforeMount(() => {
getFirstPageData()
})
</script>
<template>
<div class="container_wrap" v-if="tableInfo.data.length">
<div class="table_tool_wrap">
<div class="table_title">分类分级任务</div>
</div>
<div class="table_panel_wrap">
<Table :tableInfo="tableInfo" @tableBtnClick="tableBtnClick" @tablePageChange="tablePageChange" />
</div>
......@@ -225,7 +244,7 @@ onBeforeMount(() => {
<div class="container_wrap" v-else>
<div class="card-noData">
<img src="@/assets/images/no-data.png" :style="{ width: '96px', height: '96px' }" />
<p>暂无分类分级任务,<span class="text_btn" @click="toPath('add')">去新建</span></p>
<p>暂无日志记录</p>
</div>
</div>
</template>
......@@ -247,7 +266,7 @@ onBeforeMount(() => {
.table_panel_wrap {
width: 100%;
height: calc(100% - 40px);
height: 100%;
padding: 0px 8px 0;
}
......
......@@ -9,16 +9,18 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, ElMessageBox } from "element-plus";
import { Search } from "@element-plus/icons-vue";
import useDataAssetStore from "@/store/modules/dataAsset";
import { getClassifyGradList, getClassifyTreeList, getCgLabelPageList, getMetaTableCollectList, } from "@/api/modules/dataInventory";
import { getCgTaskDetail, getClassifyGradList, getClassifyTreeList, getCgLabelPageList, getMetaTableCollectList, cgTaskSave, cgTaskUpdate } from "@/api/modules/dataInventory";
const { proxy } = getCurrentInstance() as any;
const router = useRouter();
const route = useRoute();
const userStore = useUserStore();
const userData = JSON.parse(userStore.userData);
const assetStore = useDataAssetStore();
const step = ref(0);
const selectIndex = ref(0);
const taskDetail = ref({});
const asideSearchInput = ref("");
const permissionList: any = ref([])
const listLoading = ref(false)
......@@ -29,12 +31,12 @@ const listPage = ref({
})
const currpermissionList: any = ref([])
const templateInfo = ref({})
const treeIndex: any = ref({})
const treeInfoRef = ref();
const treeInfo = ref({
id: "data-pickup-tree",
filter: true,
queryValue: "",
loading: false,
queryPlaceholder: "请输入分类名称搜索",
props: {
label: "classifyName",
......@@ -49,6 +51,7 @@ const treeInfo = ref({
const expand1 = ref(true)
const expand2 = ref(true)
const taskFormRef = ref();
const taskFormItems: any = ref([
{
label: '任务名称',
......@@ -63,7 +66,7 @@ const taskFormItems: any = ref([
label: '分级分类目录名称',
type: 'input',
placeholder: '请输入',
field: 'catalogName',
field: 'cgDirName',
default: '',
maxlength: 50,
required: true
......@@ -74,7 +77,7 @@ const taskFormRules = ref({
taskName: [
{ required: true, trigger: 'blur', message: "请填写任务名称" }
],
catalogName: [
cgDirName: [
{ required: true, trigger: 'blur', message: "请填写分级分类目录名称" }
],
});
......@@ -95,13 +98,18 @@ const searchItemValue: any = ref({
detailGuid: ''
});
const currTableData: any = ref({});
const selectRowData = ref([])
const tableInfo = ref({
id: "mapping-table",
fields: [
{ label: "序号", type: "index", width: 56, align: "center", fixed: "left" },
{ label: "标签", field: "label", width: 96 },
{ label: "分类", field: "classifyDetailName", width: 380 },
{
label: "分类", field: "classifyNames", width: 380, getName: (scope) => {
const names = scope.row.classifyNames || [];
return names.join('/');
}
},
{ label: "分级", field: "gradeDetailName", width: 55 },
{ label: "规则", field: "rule", width: 380 },
],
......@@ -117,31 +125,45 @@ const tableInfo = ref({
},
});
const metadataTableRef = ref();
const metadataTableInfo = ref({
id: "metadata-table",
multiple: true,
rowKey: 'guid',
fields: [
{ label: "序号", type: "index", width: 56, align: "center", fixed: "left" },
{ label: "数据库名称", field: "damCode", width: 200 },
{ label: "数据库名", field: "damTypeName", width: 200 },
{ label: "总表数", field: "damName", width: 120, align: "right" },
{ label: "存储量(约/MB)", field: "damTypeName", width: 200, align: "right" },
{ label: "数据库名称", field: "databaseNameZh", width: 200 },
{ label: "数据库名", field: "databaseName", width: 200 },
{ label: "总表数", field: "tableCount", width: 120, align: "right" },
{ label: "存储量(约/MB)", field: "storageCapacities", width: 200, align: "right" },
],
loading: false,
data: [],
page: {
type: "normal",
rows: 0,
...page.value,
},
showPage: false,
// page: {
// type: "normal",
// rows: 0,
// ...page.value,
// },
actionInfo: {
show: false
},
})
const getTaskDetail = (data) => {
getCgTaskDetail(data).then((res: any) => {
const data = res.data || {};
taskDetail.value = data;
taskFormItems.value.map((item) => {
item.default = data[item.field] || '';
})
selectRowData.value = data.metaGuids || [];
getPermissionList({});
getMetaTableData();
})
}
const nodeClick = (data) => {
treeIndex.value = data
searchItemValue.value.classifyGuid = templateInfo.value.guid;
searchItemValue.value.detailGuid = data.guid;
getTableData();
......@@ -167,17 +189,6 @@ const getTableData = () => {
});
};
const tableBtnClick = (scope, btn) => {
const type = btn.value;
const row = scope.row;
currTableData.value = row;
if (type == "detail" || type === "edit") {
toPath(type);
} else if (type === "delete") {
open("此操作将永久删除,是否继续?", "warning");
}
};
const toPath = (type = null) => {
router.push({
name: "taskConfig",
......@@ -187,21 +198,38 @@ const toPath = (type = null) => {
});
}
const tableSelectionChange = (val) => {
selectRowData.value = val.map((item) => item.databaseGuid);
};
const tablePageChange = (info) => {
page.value.curr = Number(info.curr);
page.value.limit = Number(info.limit);
tableInfo.value.page.limit = page.value.limit;
tableInfo.value.page.curr = page.value.curr;
getTableData();
if (step.value == 0) {
page.value.curr = Number(info.curr);
page.value.limit = Number(info.limit);
tableInfo.value.page.limit = page.value.limit;
tableInfo.value.page.curr = page.value.curr;
getTableData();
} else {
}
};
// 获取元数据表格
const getMetaTableData = () => {
getMetaTableCollectList({}).then((res: any) => {
metadataTableInfo.value.loading = false;
metadataTableInfo.value.data = res.data.records || [];
metadataTableInfo.value.page.curr = res.data.pageIndex;
metadataTableInfo.value.page.limit = res.data.pageSize;
metadataTableInfo.value.page.rows = res.data.totalRows;
const data = res.data.records || [];
metadataTableInfo.value.data = data;
// metadataTableInfo.value.page.curr = res.data.pageIndex;
// metadataTableInfo.value.page.limit = res.data.pageSize;
// metadataTableInfo.value.page.rows = res.data.totalRows;
if (route.query.type === 'edit') {
nextTick(() => {
data.map((row) => {
taskDetail.value.metaGuids.indexOf(row.guid) > -1 && metadataTableRef.value.tableRef.toggleRowSelection(row, true);
});
})
}
})
}
......@@ -220,11 +248,73 @@ const btnClick = async (btn, bType = null) => {
step.value++;
} else if (type == 'prev') {
step.value--;
} else if (type == 'path') {
if (selectRowData.value.length == 0) {
ElMessage({
type: 'warning',
message: '请选择元数据'
})
return
}
const formEl = taskFormRef.value.ruleFormRef;
const form = taskFormRef.value.formInline;
const subForm = { ...form };
submitForm(formEl, subForm);
} else {
toPath()
}
};
const submitForm = (formEl, info) => {
if (!formEl) return;
formEl.validate((valid, fields) => {
if (valid) {
const params = {
classifyGuid: templateInfo.value.guid,
metaGuids: selectRowData.value,
...info
}
if (route.query.type === 'edit') {
params.guid = taskDetail.value.guid;
params.execGuid = taskDetail.value.execGuid;
cgTaskUpdate(params).then((res: any) => {
if (res.code == proxy.$passCode) {
toPath()
} else {
ElMessage({
type: "error",
message: res.msg,
});
}
}).catch(() => {
ElMessage({
type: "error",
message: '请求失败',
});
})
} else {
cgTaskSave(params).then((res: any) => {
if (res.code == proxy.$passCode) {
toPath()
} else {
ElMessage({
type: "error",
message: res.msg,
});
}
}).catch(() => {
ElMessage({
type: "error",
message: '请求失败',
});
})
}
} else {
console.log("error submit!", fields);
}
});
};
// 监听滚动事件
const handleScroll = () => {
if (listPage.value.curr < listPage.value.totalPages) {
......@@ -258,7 +348,11 @@ const getPermissionList = (val, init = false) => {
querySearch(asideSearchInput.value)
}
if (data.length) {
templateInfo.value = data[0];
if (route.query.type == 'edit') {
templateInfo.value = data.filter(item => item.guid == taskDetail.value.classifyGuid)[0]
} else {
templateInfo.value = data[0];
}
getClassifyTree()
}
}
......@@ -273,17 +367,27 @@ const getClassifyTree = () => {
const params = {
guid: templateInfo.value.guid
}
treeInfo.value.loading = true;
getClassifyTreeList(params).then((res: any) => {
if (res.code == proxy.$passCode) {
const data = res.data || [];
treeInfo.value.data = data;
treeInfoRef.value.setCurrentKey('');
tableInfo.value.data = [];
}
treeInfo.value.loading = false;
}).catch(() => {
treeInfo.value.loading = false;
})
}
onActivated(() => {
getPermissionList({});
getMetaTableData();
if (route.query.type == 'edit') {
getTaskDetail({ guid: route.query.guid })
} else {
getPermissionList({});
getMetaTableData();
}
})
onBeforeMount(() => {
......@@ -323,17 +427,17 @@ onBeforeMount(() => {
</div>
<div class="panel_content">
<div class="box_left">
<Tree :treeInfo="treeInfo" @nodeClick="nodeClick" />
<Tree ref="treeInfoRef" :treeInfo="treeInfo" @nodeClick="nodeClick" />
</div>
<div class="box_right">
<div class="table_panel_wrap">
<Table :tableInfo="tableInfo" @tableBtnClick="tableBtnClick" @tablePageChange="tablePageChange" />
<Table :tableInfo="tableInfo" @tablePageChange="tablePageChange" />
</div>
</div>
</div>
</div>
<div class="content_main panel" v-show="step == 1">
<ContentWrap id="id-approveInfo" title="创建任务" expandSwicth style="margin-top: 15px" :isExpand="expand1"
<ContentWrap title="创建任务" expandSwicth style="margin-top: 15px" :isExpand="expand1"
@expand="(v) => expand1 = v">
<div class="form_panel">
<Form ref="taskFormRef" formId="edit-standard-form" :itemList="taskFormItems" :rules="taskFormRules"
......@@ -342,7 +446,9 @@ onBeforeMount(() => {
</ContentWrap>
<ContentWrap id="id-approveInfo" title="选择元数据" expandSwicth style="margin-top: 15px" :isExpand="expand2"
@expand="(v) => expand2 = v">
<Table :tableInfo="metadataTableInfo" />
<div class="table_panel_wrap full">
<Table ref="metadataTableRef" :tableInfo="metadataTableInfo" @tableSelectionChange="tableSelectionChange" />
</div>
</ContentWrap>
</div>
<div class="tool_btns">
......@@ -466,7 +572,6 @@ onBeforeMount(() => {
.box_left {
width: 240px;
height: 100%;
padding-top: 12px;
border-right: 1px solid #d9d9d9;
.aside_title {
......@@ -479,13 +584,13 @@ onBeforeMount(() => {
}
.tree_panel {
padding: 0;
height: 100%;
}
}
.box_right {
width: 100%;
padding-top: 12px;
width: calc(100% - 240px);
padding-top: 8px;
.el-breadcrumb {
padding: 0 12px;
......@@ -494,10 +599,26 @@ onBeforeMount(() => {
}
}
:deep(#id-approveInfo) {
height: calc(100% - 192px);
.el-card__body {
height: calc(100% - 50px) !important;
.card-body-content {
height: 100%;
}
}
}
.table_panel_wrap {
width: 100%;
height: 100%;
padding: 0 12px;
&.full {
padding: 0;
}
}
}
......
......@@ -9,328 +9,17 @@ import useUserStore from "@/store/modules/user";
import { ElMessage, ElMessageBox } from "element-plus";
import useDataAssetStore from "@/store/modules/dataAsset";
import { getListingList, listingDelete, listingUpdateStatus, filterVal, getParamsDataList } from "@/api/modules/dataProduct";
import { getTaskExecPageList, filterVal } from "@/api/modules/dataInventory";
import { TableColumnWidth } from '@/utils/enum';
import Table from "@/components/Table/index.vue";
const { proxy } = getCurrentInstance() as any;
const router = useRouter();
const route = useRoute();
const userStore = useUserStore();
const userData = JSON.parse(userStore.userData);
const assetStore = useDataAssetStore();
const datas = [
{
"updateTime": "2024-07-16 13:17:00",
"updateUserName": "数往知来管理员",
"guid": "4e0e76c48fa043d5b35d09f3ccc7c265",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202406070021",
"dataVersion": 1,
"chName": "地址",
"enName": "address",
"dataTypeValue": "字符型",
"dataTypeCode": "varchar",
"dataDicGuid": "",
"dataDicName": null,
"isDataDic": "N",
"fieldLength": 600,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": "合伙人",
"dataEncryptionLevel": "界面加密",
"businessDefDesc": "地址",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-27 10:19:45",
"updateUserName": "数往知来管理员",
"guid": "bc630207357c466dbff7613ea38985cc",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260124",
"dataVersion": 1,
"chName": "包含最小销售包装单元数量",
"enName": "inboxQuantity",
"dataTypeValue": "整型",
"dataTypeCode": "int",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": null,
"fieldPrecision": null,
"dataState": 1,
"approveState": "A",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "当前药品追溯码中包含的最小销售包装单元药品追溯码的数量,发货类型为03时可选",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-27 11:03:59",
"updateUserName": "审批人4",
"guid": "420f2a68bd4441bf92010eadf698b685",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260122",
"dataVersion": 1,
"chName": "包装层级",
"enName": "packageLevel",
"dataTypeValue": "字符型",
"dataTypeCode": "varchar",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": 200,
"fieldPrecision": null,
"dataState": 1,
"approveState": "A",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "当前药品追溯码所处包装层级描述,发货类型为03时可选",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-06-06 10:01:06",
"updateUserName": "审批人1",
"guid": "f841e1848ab94b1e81a0217a09a7a3d3",
"approvalGuid": "b674bffe8d2f4132918016b6baaf75aa",
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260120",
"dataVersion": 1,
"chName": "上一级包装药品追溯码",
"enName": "parentDTC",
"dataTypeValue": "字符型",
"dataTypeCode": "varchar",
"dataDicGuid": "",
"dataDicName": null,
"isDataDic": "N",
"fieldLength": 200,
"fieldPrecision": null,
"dataState": 1,
"approveState": "Y",
"dataCategory": "",
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "当前药品追溯码大一级包装上的药品追溯码,发货类型为03时可选;当存在上一级包装时必选",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-26 00:10:47",
"updateUserName": "数往知来管理员",
"guid": "d4d42dea2a5844b4a7f9238806ea507b",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260118",
"dataVersion": 1,
"chName": "药品追溯码",
"enName": "DTC",
"dataTypeValue": "字符型",
"dataTypeCode": "varchar",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": 200,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "用于唯一标识药品各级销售包装单元的代码,发货类型为03时可选",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-26 00:10:47",
"updateUserName": "数往知来管理员",
"guid": "ff9d0e4f6fbb444c8dcf6f67bffcb659",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260116",
"dataVersion": 1,
"chName": "发货数量",
"enName": "deliveryQuantity",
"dataTypeValue": "整型",
"dataTypeCode": "int",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": null,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "发货的最小销售包装单元数量",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-26 00:10:46",
"updateUserName": "数往知来管理员",
"guid": "fe88ac9e8d9c4f148833dbb3976fca77",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260114",
"dataVersion": 1,
"chName": "药品生产批号",
"enName": "batch",
"dataTypeValue": "字符型",
"dataTypeCode": "varchar",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": 20,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "药品包装上标示的生产批号",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-26 00:10:45",
"updateUserName": "数往知来管理员",
"guid": "9759837e0d72472ab7441c1873c9159a",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260112",
"dataVersion": 1,
"chName": "药品有效期截止日期",
"enName": "expirationDate",
"dataTypeValue": "日期型",
"dataTypeCode": "date",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": null,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "药品有效期的截止日期",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-26 00:10:45",
"updateUserName": "数往知来管理员",
"guid": "a39ed6123c6a420d9d1265315e714f86",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260110",
"dataVersion": 1,
"chName": "药品生产日期",
"enName": "productionDate",
"dataTypeValue": "日期型",
"dataTypeCode": "date",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": null,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "药品包装上标示的生产日期",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
},
{
"updateTime": "2024-01-26 00:10:45",
"updateUserName": "数往知来管理员",
"guid": "ea597c1b8bb24a5ab053a80b084de98c",
"approvalGuid": null,
"standardSetGuid": "58d1178a04904d599284fc1e61594c43",
"fieldStandardCode": "COL202401260108",
"dataVersion": 1,
"chName": "统一社会信用代码(进口药品代理企业)",
"enName": "drugImporterUSCID",
"dataTypeValue": "字符型",
"dataTypeCode": "varchar",
"dataDicGuid": null,
"dataDicName": null,
"isDataDic": null,
"fieldLength": 18,
"fieldPrecision": null,
"dataState": 0,
"approveState": "N",
"dataCategory": null,
"dataEncryptionLevel": "明文显示",
"businessDefDesc": "进口药品代理企业的统一社会信用代码,进口药品必选;没有统一社会信用代码时使用组织机构代码",
"flowFlag": null,
"flowCode": null,
"functionCode": null,
"createStaffGuid": null,
"createUserId": "98df01b8d86c46f786dd10b4d0eb11dd",
"displayVersion": "V1",
"standardSetName": null,
"ruleType": null
}
]
const page = ref({
limit: 50,
......@@ -349,30 +38,33 @@ const tableInfo = ref({
id: "mapping-table",
fields: [
{ label: "序号", type: "index", width: 56, align: "center", fixed: "left" },
{ label: "任务名称", field: "chName", width: 96 },
{ label: "任务名称", field: "taskName", width: 96 },
{
label: "目录名称", field: "dataTypeValue", width: 120, type: "text_btn", columClass: 'text_btn', click: (scope) => {
label: "目录名称", field: "cgDirName", width: 120, type: "text_btn", columClass: 'text_btn', click: (scope) => {
router.push({
name: "templateConfig",
query: { guid: scope.row.damGuid },
});
}
},
{ label: "分类分级模板", field: "dataTypeValue", width: 200 },
{ label: "元数据", field: "fieldStandardCode", width: 200 },
{ label: "任务修改人", field: "dataCategory", width: 120 },
{
label: "元数据", field: "metaNames", width: 200, getName: (scope) => {
const metaNames = scope.row.metaNames || [];
return metaNames.join(',');
}
},
{ label: "任务修改人", field: "updateUserName", width: 120 },
{ label: "修改时间", field: "updateTime", width: TableColumnWidth.DATETIME },
{ label: "确认次数", field: "fieldLength", width: 96, align: 'right' },
{ label: "结果确认人", field: "updateUserName", width: 120 },
{ label: "确认时间", field: "updateTime", width: TableColumnWidth.DATETIME },
{ label: "结果确认人", field: "confirmUserName", width: 120 },
{ label: "确认时间", field: "confirmTime", width: TableColumnWidth.DATETIME },
{
label: "结果状态", field: "approveState", width: TableColumnWidth.STATE, align: 'center', type: "tag", getName: (scope) => {
return filterVal(scope.row.approveState, 'approveState');
label: "结果状态", field: "status", width: TableColumnWidth.STATE, align: 'center', type: "tag", getName: (scope) => {
return filterVal(scope.row.status, 'confirmStatus');
}
},
],
loading: false,
data: datas || [],
data: [],
page: {
type: "normal",
rows: 0,
......@@ -386,19 +78,6 @@ const tableInfo = ref({
let row = scope.row, btnArr: any = [
{ label: "查看结果", value: "path" },
];
// if (row.approveState == 'Y') {
// if (row.listingStatus == 'Y') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// } else {
// if (row.approveState == 'A') {
// btnArr.splice(0, 0, { label: "详情", value: "detail" });
// } else {
// btnArr.splice(0, 0, { label: "编辑", value: "edit" }, { label: "详情", value: "detail" }, { label: "删除", value: "delete" });
// }
// }
return btnArr;
},
},
......@@ -406,10 +85,11 @@ const tableInfo = ref({
const getTableData = () => {
tableInfo.value.loading = true;
getListingList(
getTaskExecPageList(
Object.assign({}, searchItemValue.value, {
pageIndex: page.value.curr,
pageSize: page.value.limit,
taskGuid: route.query.guid
})
).then((res: any) => {
tableInfo.value.loading = false;
......@@ -486,10 +166,7 @@ const getFirstPageData = () => {
}
onActivated(() => {
if (assetStore.isRefresh) {//如果是首次加载,则不需要调用
getFirstPageData();
assetStore.set(false);
}
getFirstPageData()
})
onBeforeMount(() => {
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!