bb427c9b by lihua

添加最新代码修改

1 parent d4e71aa1
1 /**
2 * API响应处理工具函数
3 * 统一处理API请求的成功/失败逻辑
4 */
5
6 interface ApiResponse {
7 code: number;
8 data?: any;
9 msg?: string;
10 }
11
12 export interface ApiHandlerOptions {
13 /* 当前实例的proxy对象(用于获取$passCode和$ElMessage)*/
14 proxy: any
15 /** 加载状态ref */
16 loadingRef?: Ref<boolean>;
17 /** 成功回调函数 */
18 onSuccess?: (res: any) => void;
19 /** 失败回调函数 */
20 onError?: (res: any) => void;
21 /** 是否显示错误消息,默认true */
22 showError?: boolean;
23 }
24
25 /**
26 * 统一处理API响应的工具函数
27 * @param apiPromise API请求Promise
28 * @param options 配置选项
29 */
30 export const handleApiResponse = async (
31 apiPromise: Promise<ApiResponse>,
32 options: ApiHandlerOptions,
33 ) => {
34 const {
35 loadingRef,
36 onSuccess,
37 onError,
38 showError = true,
39 proxy
40 } = options;
41
42 try {
43 // 设置加载状态
44 if (loadingRef) {
45 loadingRef.value = true;
46 }
47
48 // 执行API请求
49 const res = await apiPromise;
50
51 // 设置加载状态
52 if (loadingRef) {
53 loadingRef.value = false;
54 }
55
56 // 判断请求是否成功
57 if (res?.code == proxy.$passCode) {
58 // 成功回调
59 onSuccess && onSuccess(res);
60 } else {
61 // 失败处理
62 const errorMsg = res?.msg || '';
63 if (showError) {
64 proxy.$ElMessage.error(errorMsg);
65 }
66 onError && onError(res);
67 }
68 } catch (error: any) {
69 // 异常处理
70 if (loadingRef) {
71 loadingRef.value = false;
72 }
73 }
74 };
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
2 * 匿名化管理的接口api文件 2 * 匿名化管理的接口api文件
3 */ 3 */
4 import request from "@/utils/request"; 4 import request from "@/utils/request";
5 import { handleApiResponse, ApiHandlerOptions } from '../apiHander'; // 导入公共处理方法
5 6
6 /** 获取标签列表。 */ 7 /** 获取标签列表。 */
7 export const getDataLabelList = (params) => request({ 8 export const getDataLabelList = (params) => request({
...@@ -246,6 +247,12 @@ export const updateAnonTask = (params) => request({ ...@@ -246,6 +247,12 @@ export const updateAnonTask = (params) => request({
246 }) 247 })
247 248
248 /** 获取匿名化任务详情 */ 249 /** 获取匿名化任务详情 */
250 // export const getAnonTaskDetail = (guid, defaultOptions: ApiHandlerOptions) => handleApiResponse(request({
251 // url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/detail?guid=${guid}`,
252 // method: 'get'
253 // }), defaultOptions)
254
255 /** 获取匿名化任务详情 */
249 export const getAnonTaskDetail = (guid) => request({ 256 export const getAnonTaskDetail = (guid) => request({
250 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/detail?guid=${guid}`, 257 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/detail?guid=${guid}`,
251 method: 'get' 258 method: 'get'
...@@ -265,12 +272,18 @@ export const anonTaskCheck = (params) => request({ ...@@ -265,12 +272,18 @@ export const anonTaskCheck = (params) => request({
265 }) 272 })
266 273
267 /** 获取匿名化任务分析结果数据 */ 274 /** 获取匿名化任务分析结果数据 */
268 export const getAnonAnalyzeResult = (execGuid) => request({ 275 export const getAnonAnalyzeResult1 = (execGuid) => request({
269 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/get-anon-analyze?taskExecGuid=${execGuid}`, 276 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/get-anon-analyze?taskExecGuid=${execGuid}`,
270 method: 'get' 277 method: 'get'
271 }) 278 })
272 279
273 /** 获取匿名化任务分析结果数据 */ 280 /** 获取匿名化任务分析结果数据 */
281 export const getAnonAnalyzeResult = (execGuid, defaultOptions: ApiHandlerOptions) => handleApiResponse(request({
282 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/get-anon-analyze?taskExecGuid=${execGuid}`,
283 method: 'get'
284 }), defaultOptions)
285
286 /** 获取匿名化任务分析结果数据 */
274 export const getLastAnonAnalyzeResult = (execGuid) => request({ 287 export const getLastAnonAnalyzeResult = (execGuid) => request({
275 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/get-anon-analyze?isResult=true&taskExecGuid=${execGuid}`, 288 url: `${import.meta.env.VITE_API_COMMON_URL}/anon-task/get-anon-analyze?isResult=true&taskExecGuid=${execGuid}`,
276 method: 'get' 289 method: 'get'
......
1 import CommonTable from './src/CommonTable.vue'
2
3 export { CommonTable }
4 export default CommonTable
...\ No newline at end of file ...\ No newline at end of file
1 <script lang="ts" setup name="CommonTable">
2 import { ref, watch, computed } from "vue";
3 import { TableColumnWidth } from "@/utils/enum";
4 import { calcColumnWidth } from "@/utils/index";
5 import Moment from 'moment';
6
7 const props = defineProps({
8 data: {
9 type: Array,
10 default: () => []
11 },
12 fields: {
13 type: Array,
14 default: () => []
15 },
16 loading: {
17 type: Boolean,
18 default: false
19 },
20 height: {
21 type: String,
22 default: '100%'
23 },
24 showIndex: {
25 type: Boolean,
26 default: false
27 },
28 rowKey: {
29 type: String,
30 default: 'guid'
31 },
32 style: {
33 type: Object,
34 default: () => ({})
35 }
36 });
37
38 const originTableFieldColumn = ref({});
39
40 const getTextAlign = (field) => {
41 if (field.dataType === 'decimal' || field.dataType === 'int' || field.dataType == 'bit' || field.dataType == 'tinyint') {
42 return 'right';
43 }
44 return 'left'
45 };
46
47 const formatterPreviewDate = (row, info) => {
48 let enName = info.enName;
49 let v = row[enName];
50 if (v === 0) {
51 return v;
52 }
53 if (!v || v == 'null') {
54 return '--';
55 }
56 if (info.dataType === 'datetime') {
57 return Moment(v).format('YYYY-MM-DD HH:mm:ss');
58 }
59 if (info.dataType === 'date') {
60 if (isNaN(<any>(new Date(v)))) {
61 return Moment(parseInt(v)).format('YYYY-MM-DD');
62 } else {
63 return Moment(v).format('YYYY-MM-DD');
64 }
65 }
66 return v;
67 };
68
69 const calcTableColumnWidth = (data: any[], prop, title, otherWidth = 0) => {
70 let d: any[] = [];
71 data.forEach((dt) => d.push(dt[prop]));
72 return calcColumnWidth(
73 d,
74 title,
75 {
76 fontSize: 14,
77 fontFamily: "SimSun",
78 },
79 {
80 fontSize: 14,
81 fontFamily: "SimSun",
82 },
83 otherWidth
84 );
85 };
86
87 watch(
88 () => props.data,
89 (val: any[], oldVal) => {
90 if (!props.fields?.length) {
91 originTableFieldColumn.value = {};
92 return;
93 }
94 originTableFieldColumn.value = {};
95 props.fields.forEach((field, index) => {
96 originTableFieldColumn.value[field.enName] = calcTableColumnWidth(
97 val?.slice(0, 20) || [],
98 field.enName,
99 field.chName,
100 24
101 );
102 });
103 },
104 {
105 deep: true,
106 }
107 );
108 </script>
109
110 <template>
111 <div class="common-table" v-loading="loading">
112 <el-table
113 :data="data"
114 :highlight-current-row="true"
115 stripe
116 border
117 tooltip-effect="light"
118 :height="height"
119 :row-key="rowKey"
120 :style="style"
121 >
122 <el-table-column
123 v-if="showIndex"
124 label="序号"
125 type="index"
126 width="56px"
127 align="center"
128 show-overflow-tooltip
129 ></el-table-column>
130 <template v-for="(item, index) in (fields || [])" :key="index">
131 <el-table-column
132 :label="item.chName"
133 :width="item.dataType === 'datetime'
134 ? TableColumnWidth.DATETIME
135 : item.dataType === 'date'
136 ? TableColumnWidth.DATE
137 : originTableFieldColumn[item.enName]
138 "
139 :align="getTextAlign(item)"
140 :header-align="getTextAlign(item)"
141 :formatter="(row) => formatterPreviewDate(row, item)"
142 :show-overflow-tooltip="true"
143 >
144 </el-table-column>
145 </template>
146 </el-table>
147 <div v-show="!fields.length" class="empty-content">
148 <img src="@/assets/images/empty-data.png" :style="{ width: '168px', height: '96px' }" />
149 <div class="empty-text">暂无数据</div>
150 </div>
151 </div>
152 </template>
153
154 <style lang="scss" scoped>
155 .common-table {
156 width: 100%;
157 height: 100%;
158
159 .el-table {
160 display: inline-block;
161 }
162
163 .empty-content {
164 display: flex;
165 align-items: center;
166 justify-content: center;
167 height: 100%;
168 width: 100%;
169 flex-direction: column;
170
171 .empty-text {
172 font-size: 14px;
173 color: #b2b2b2;
174 }
175 }
176 }
177 </style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -133,8 +133,8 @@ const routes: RouteRecordRaw[] = [ ...@@ -133,8 +133,8 @@ const routes: RouteRecordRaw[] = [
133 children: [ 133 children: [
134 { 134 {
135 path: '', 135 path: '',
136 name: 'resultProcess', 136 name: 'anonResultProcessManage',
137 component: () => import('@/views/data_anonymization/resultProcess.vue'), 137 component: () => import('@/views/data_anonymization/anonResultProcessManage.vue'),
138 meta: { 138 meta: {
139 title: '匿名化处理', 139 title: '匿名化处理',
140 sidebar: false, 140 sidebar: false,
......
1 <route lang="yaml">
2 name: anonResultProcessManage
3 </route>
4
5 <script lang="ts" setup name="anonResultProcessManage">
6 import TableTools from "@/components/Tools/table_tools.vue";
7 import { commonPageConfig } from '@/components/PageNav/index';
8 import { TableColumnWidth } from "@/utils/enum";
9 import {
10 dataSourceTypeList,
11 getAnonTaskList,
12 deleteAnonTask,
13 } from '@/api/modules/dataAnonymization';
14 import useDataAnonymizationStore from "@/store/modules/dataAnonymization";
15
16 const anonymizationStore = useDataAnonymizationStore();
17 const router = useRouter()
18 const { proxy } = getCurrentInstance() as any;
19
20 /** -------------- 搜索栏输入框配置 ------------------------ */
21 const searchItemList = ref([{
22 type: "input",
23 label: "",
24 field: "taskName",
25 default: "",
26 placeholder: "数据集名称",
27 clearable: true,
28 }, {
29 type: "select",
30 label: "",
31 field: "dataSource",
32 default: null,
33 options: dataSourceTypeList,
34 placeholder: "数据来源",
35 clearable: true,
36 filterable: true,
37 }])
38
39 /** 分页及搜索传参信息配置。 */
40 const page = ref({
41 ...commonPageConfig,
42 taskName: '',
43 dataSource: null
44 });
45
46 /** ----------------- 表格展示配置信息,及查询数据处理 ----------------- */
47 const tableInfo = ref({
48 id: 'data-file-table',
49 fields: [
50 { label: "序号", type: "index", width: TableColumnWidth.INDEX, align: "center" },
51 { label: "数据集名称", field: "taskName", width: 160 },
52 {
53 label: "数据来源", field: "dataSource", width: 100, getName: (scope) => {
54 return scope.row.dataSource == 4 ? '外部数据' : (scope.row.dataSource && dataSourceTypeList.find(f => f.value == scope.row.dataSource)?.label || '--');
55 }
56 },
57 { label: "任务状态", field: "sensitiveIdentifyTaskStatus", width: TableColumnWidth.STATE, align: 'center', type: "tag" },
58 { label: "导出时间", field: "exportTime", width: TableColumnWidth.DATETIME },
59 { label: "修改人", field: "updateUserName", width: TableColumnWidth.USERNAME },
60 { label: "修改时间", field: "updateTime", width: TableColumnWidth.DATETIME },
61 ],
62 data: [],
63 page: {
64 type: "normal",
65 rows: 0,
66 ...page.value,
67 },
68 loading: false,
69 actionInfo: {
70 label: "操作",
71 type: "btn",
72 width: 230,
73 fixed: 'right',
74 btns: (scope) => {
75 return [{ label: "编辑", value: "edit", disabled: scope.row.isConfirm == 'Y' || scope.row.dataSource == 4, click: tableBtnHandles['edit'] }, {
76 label: '查看报告', value: 'report', disabled: scope.row.status != 'Y', click: tableBtnHandles['report']
77 }, {
78 label: '查看数据', value: 'view', disabled: scope.row.status != 'Y' || scope.row.handleType == '02', click: tableBtnHandles['view']
79 }, {
80 label: "删除", value: "delete", click: tableBtnHandles['delete']
81 }]
82 }
83 }
84 })
85
86 /** 搜索栏触发搜索 */
87 const toSearch = (val: any, clear: boolean = false) => {
88 if (clear) {
89 searchItemList.value.map((item) => (item.default = ""));
90 page.value.taskName = '';
91 page.value.dataSource = null;
92 } else {
93 page.value.taskName = val.taskName;
94 page.value.dataSource = val.dataSource;
95 }
96 getTableData();
97 };
98
99 const getTableData = () => {
100 tableInfo.value.loading = true
101 getAnonTaskList({
102 pageIndex: page.value.curr,
103 pageSize: page.value.limit,
104 taskName: page.value.taskName,
105 dataSource: page.value.dataSource
106 }).then((res: any) => {
107 if (res?.code == proxy.$passCode) {
108 const data = res.data || {};
109 tableInfo.value.data = data.records?.map(d => {
110 d.sensitiveIdentifyTaskStatus = d.status;
111 return d;
112 }) || []
113 tableInfo.value.page.limit = data.pageSize
114 tableInfo.value.page.curr = data.pageIndex
115 tableInfo.value.page.rows = data.totalRows
116 } else {
117 proxy.$ElMessage({
118 type: 'error',
119 message: res.msg,
120 })
121 }
122 tableInfo.value.loading = false
123 })
124 };
125
126 const tablePageChange = (info) => {
127 page.value.curr = Number(info.curr);
128 page.value.limit = Number(info.limit);
129 getTableData();
130 };
131
132 const tableBtnHandles = {
133 edit: (scope) => {
134 router.push({
135 name: 'anonTaskCreate',
136 query: {
137 guid: scope.row.guid,
138 taskName: scope.row.taskName
139 }
140 });
141 },
142 report: (scope) => {
143 router.push({
144 name: 'anonResultReportView',
145 query: {
146 guid: scope.row.guid,
147 execGuid: scope.row.lastExecGuid,
148 taskName: scope.row.taskName
149 }
150 });
151 },
152 view: (scope) => {
153 router.push({
154 name: 'anonResultView',
155 query: {
156 guid: scope.row.guid,
157 execGuid: scope.row.lastExecGuid,
158 taskName: scope.row.taskName
159 }
160 });
161 },
162 delete: (scope) => {
163 proxy.$openMessageBox("此操作将永久删除, 是否继续?", () => {
164 let guids = [scope.row.guid];
165 deleteAnonTask(guids).then((res: any) => {
166 if (res?.code == proxy.$passCode) {
167 page.value.curr = 1;
168 getTableData();
169 proxy.$ElMessage({
170 type: "success",
171 message: "删除成功",
172 });
173 } else {
174 proxy.$ElMessage({
175 type: "error",
176 message: res.msg,
177 });
178 }
179 });
180 })
181 }
182 }
183
184 const handleCreate = () => {
185 router.push({
186 name: 'anonTaskCreate'
187 });
188 }
189
190 onBeforeMount(() => {
191 toSearch({});
192 anonymizationStore?.setIsAnonPageRefresh?.(false);
193 })
194
195 onActivated(() => {
196 if (anonymizationStore.isAnonPageRefresh) {//如果是首次加载,则不需要调用
197 page.value.curr = 1;
198 getTableData();
199 anonymizationStore.setIsAnonPageRefresh(false);
200 }
201 });
202
203 </script>
204
205 <template>
206 <div class="container_wrap">
207 <div class="table_tool_wrap">
208 <!-- 头部搜索 -->
209 <TableTools :searchItems="searchItemList" :searchId="'data-label-search'" @search="toSearch" :init="false" />
210 <div class="tools_btns">
211 <el-button type="primary" @click="handleCreate">新建</el-button>
212 </div>
213 </div>
214 <div class="table_panel_wrap">
215 <!-- 右侧标签管理表格 -->
216 <Table :tableInfo="tableInfo" @tablePageChange="tablePageChange" />
217 </div>
218 </div>
219 </template>
220
221 <style lang="scss" scoped>
222 .table_tool_wrap {
223 width: 100%;
224 height: 84px !important;
225 padding: 0 8px;
226
227 .tools_btns {
228 padding: 0px 0 0;
229 }
230 }
231
232 .table_panel_wrap {
233 width: 100%;
234 height: calc(100% - 84px);
235 padding: 0px 8px 0;
236 }
237 </style>
...\ No newline at end of file ...\ No newline at end of file
...@@ -228,17 +228,16 @@ onMounted(() => { ...@@ -228,17 +228,16 @@ onMounted(() => {
228 228
229 onBeforeMount(() => { 229 onBeforeMount(() => {
230 resultDataLoading.value = true; 230 resultDataLoading.value = true;
231 getAnonAnalyzeResult(taskExecGuid.value).then((res: any) => { 231 getAnonAnalyzeResult(taskExecGuid.value, {
232 resultDataLoading.value = false; 232 proxy: proxy,
233 if (res?.code == proxy.$passCode) { 233 loadingRef: resultDataLoading,
234 analysisResultInfo.value = res.data || {}; 234 onSuccess: (res: any) => {
235 analysisResultInfo.value = res?.data || {};
235 analysisResultTableFields.value = res.data?.column || []; 236 analysisResultTableFields.value = res.data?.column || [];
236 pageInfo.value.curr = 1; 237 pageInfo.value.curr = 1;
237 getAnalysisResultPageData(true); 238 getAnalysisResultPageData(true);
238 } else {
239 res?.msg && proxy.$ElMessage.error(res.msg);
240 } 239 }
241 }); 240 })
242 getAnonTaskDetail(taskGuid.value).then((res: any) => { 241 getAnonTaskDetail(taskGuid.value).then((res: any) => {
243 if (res?.code == proxy.$passCode) { 242 if (res?.code == proxy.$passCode) {
244 oldAnonTaskValueInfo.value = res.data || {}; 243 oldAnonTaskValueInfo.value = res.data || {};
......
...@@ -9,9 +9,6 @@ import { ...@@ -9,9 +9,6 @@ import {
9 getLastAnonAnalyzeResult, 9 getLastAnonAnalyzeResult,
10 exportAnonExecData, 10 exportAnonExecData,
11 } from "@/api/modules/dataAnonymization"; 11 } from "@/api/modules/dataAnonymization";
12 import { calcColumnWidth } from "@/utils/index";
13 import Moment from 'moment';
14 import { TableColumnWidth } from "@/utils/enum";
15 import { ElMessage } from "element-plus"; 12 import { ElMessage } from "element-plus";
16 import { commonPageConfig } from '@/components/PageNav/index'; 13 import { commonPageConfig } from '@/components/PageNav/index';
17 import { download } from "@/utils/common"; 14 import { download } from "@/utils/common";
...@@ -69,56 +66,7 @@ const getData = () => { ...@@ -69,56 +66,7 @@ const getData = () => {
69 }); 66 });
70 } 67 }
71 68
72 const getTextAlign = (field) => {
73 if (field.dataType === 'decimal' || field.dataType === 'int' || field.dataType == 'bit' || field.dataType == 'tinyint') {
74 return 'right';
75 }
76 return 'left'
77 }
78
79 /** otherWidth表示使用标题宽度时添加标题排序图标等宽度 */
80 const calcTableColumnWidth = (data: any[], prop, title, otherWidth = 0) => {
81 let d: any[] = [];
82 data.forEach((dt) => d.push(dt[prop]));
83 return calcColumnWidth(
84 d,
85 title,
86 {
87 fontSize: 14,
88 fontFamily: "SimSun",
89 },
90 {
91 fontSize: 14,
92 fontFamily: "SimSun",
93 },
94 otherWidth
95 );
96 };
97
98 /** 每列字段对应的列宽计算结果。 */
99 const originTableFieldColumn = ref({});
100 69
101 watch(
102 tableData,
103 (val: any[], oldVal) => {
104 if (!tableFields.value?.length) {
105 originTableFieldColumn.value = {};
106 return;
107 }
108 originTableFieldColumn.value = {};
109 tableFields.value.forEach((field, index) => {
110 originTableFieldColumn.value[field.enName] = calcTableColumnWidth(
111 val?.slice(0, 20) || [],
112 field.enName,
113 field.chName,
114 24
115 );
116 });
117 },
118 {
119 deep: true,
120 }
121 );
122 70
123 watch(() => props.execGuid, (val) => { 71 watch(() => props.execGuid, (val) => {
124 if (!val) { 72 if (!val) {
...@@ -157,27 +105,7 @@ onBeforeMount(() => { ...@@ -157,27 +105,7 @@ onBeforeMount(() => {
157 }); 105 });
158 }); 106 });
159 107
160 const formatterPreviewDate = (row, info) => { 108
161 let enName = info.enName;
162 let v = row[enName];
163 if (v === 0) {
164 return v;
165 }
166 if (!v || v == 'null') {
167 return '--';
168 }
169 if (info.dataType === 'datetime') {
170 return Moment(v).format('YYYY-MM-DD HH:mm:ss');
171 }
172 if (info.dataType === 'date') {
173 if (isNaN(<any>(new Date(v)))) {
174 return Moment(parseInt(v)).format('YYYY-MM-DD');
175 } else {
176 return Moment(v).format('YYYY-MM-DD');
177 }
178 }
179 return v;
180 };
181 109
182 const pageChange = (info) => { 110 const pageChange = (info) => {
183 pageInfo.value.curr = Number(info.curr); 111 pageInfo.value.curr = Number(info.curr);
...@@ -212,19 +140,14 @@ const exportData = () => { ...@@ -212,19 +140,14 @@ const exportData = () => {
212 <div class="table_tool_wrap" v-loading="tableDataLoading"> 140 <div class="table_tool_wrap" v-loading="tableDataLoading">
213 <el-button v-show="props.isPage" style="margin-bottom: 8px;" type="primary" @click="exportData" 141 <el-button v-show="props.isPage" style="margin-bottom: 8px;" type="primary" @click="exportData"
214 v-preReClick>导出数据</el-button> 142 v-preReClick>导出数据</el-button>
215 <el-table ref="tableRef" v-show="tableFields.length" :data="tableData" :highlight-current-row="true" stripe border 143 <CommonTable
216 tooltip-effect="light" height="100%" row-key="guid" :style="{ width: '100%', height: !props.isPage ? 'calc(100% - 34px)' : 'calc(100% - 64px)' }"> 144 v-show="tableFields.length"
217 <template v-for="(item, index) in (tableFields || [])"> 145 :data="tableData"
218 <el-table-column :label="item.chName" :width="item.dataType === 'datetime' 146 :fields="tableFields"
219 ? TableColumnWidth.DATETIME 147 :loading="tableDataLoading"
220 : item.dataType === 'date' 148 :height="'100%'"
221 ? TableColumnWidth.DATE 149 :style="{ width: '100%', height: !props.isPage ? 'calc(100% - 34px)' : 'calc(100% - 64px)' }"
222 : originTableFieldColumn[item.enName] 150 />
223 " :align="getTextAlign(item)" :header-align="getTextAlign(item)"
224 :formatter="(row) => formatterPreviewDate(row, item)" :show-overflow-tooltip="true">
225 </el-table-column>
226 </template>
227 </el-table>
228 <div v-show="!tableFields.length" class="empty-content"> 151 <div v-show="!tableFields.length" class="empty-content">
229 <img src="../../assets/images/empty-data.png" :style="{ width: '168px', height: '96px' }" /> 152 <img src="../../assets/images/empty-data.png" :style="{ width: '168px', height: '96px' }" />
230 <div class="empty-text">暂无数据</div> 153 <div class="empty-text">暂无数据</div>
......
...@@ -98,7 +98,7 @@ ...@@ -98,7 +98,7 @@
98 </div> 98 </div>
99 </div> 99 </div>
100 <div class="result-title">重标识风险表</div> 100 <div class="result-title">重标识风险表</div>
101 <el-table ref="tableRef" v-show="analysisResultTableFields.length" :data="resultData" 101 <el-table ref="tableRef" v-show="analysisResultTableFields?.length" :data="resultData"
102 v-loading="analysisResultLoading" :highlight-current-row="true" stripe border tooltip-effect="light" 102 v-loading="analysisResultLoading" :highlight-current-row="true" stripe border tooltip-effect="light"
103 height="100%" row-key="guid" :style="{ width: '100%', height: '280px' }"> 103 height="100%" row-key="guid" :style="{ width: '100%', height: '280px' }">
104 <el-table-column label="等价类" type="index" width="68px" align="center" show-overflow-tooltip> 104 <el-table-column label="等价类" type="index" width="68px" align="center" show-overflow-tooltip>
...@@ -127,14 +127,14 @@ ...@@ -127,14 +127,14 @@
127 <el-table-column label="判断重风险是否大于门限阈值" prop="isGtThreshold" width="130" align="left" fixed="right" 127 <el-table-column label="判断重风险是否大于门限阈值" prop="isGtThreshold" width="130" align="left" fixed="right"
128 show-overflow-tooltip></el-table-column> 128 show-overflow-tooltip></el-table-column>
129 </el-table> 129 </el-table>
130 <div v-show="!analysisResultTableFields.length" class="empty-content"> 130 <div v-show="!analysisResultTableFields?.length" class="empty-content">
131 <img src="../../../assets/images/empty-data.png" :style="{ width: '168px', height: '96px' }" /> 131 <img src="../../../assets/images/empty-data.png" :style="{ width: '168px', height: '96px' }" />
132 <div class="empty-text">暂无数据</div> 132 <div class="empty-text">暂无数据</div>
133 </div> 133 </div>
134 <div v-show="analysisResultTableFields.length" class="result-table-desc">门限阈值的取值:完全公开共享数据发布,取值 134 <div v-show="analysisResultTableFields?.length" class="result-table-desc">门限阈值的取值:完全公开共享数据发布,取值
135 1/20;受控公开共享数据发布,取值 135 1/20;受控公开共享数据发布,取值
136 1/5;领地公开共享数据发布,取值 1/3</div> 136 1/5;领地公开共享数据发布,取值 1/3</div>
137 <PageNav v-show="analysisResultTableFields.length" :class="[pageInfo.type]" :pageInfo="pageInfo" 137 <PageNav v-show="analysisResultTableFields?.length" :class="[pageInfo.type]" :pageInfo="pageInfo"
138 @pageChange="pageChange" /> 138 @pageChange="pageChange" />
139 <div class="row-two-main" style="margin-top: 12px;"> 139 <div class="row-two-main" style="margin-top: 12px;">
140 <div class="table-one"> 140 <div class="table-one">
...@@ -199,7 +199,6 @@ ...@@ -199,7 +199,6 @@
199 </div> 199 </div>
200 </div> 200 </div>
201 <div v-show="isWordStyle" class="analysis-result-main report-main" ref="report"> 201 <div v-show="isWordStyle" class="analysis-result-main report-main" ref="report">
202 <!-- TODO,报告里需要添加数据对象,对什么做了什么。 -->
203 <div 202 <div
204 style="font-family: simsun;height: 40px;display: block;line-height: 32px;font-size: 18px;color: #212121;font-weight: 700;text-align: center;margin-top: 10px;margin-bottom: 10px;">匿名化效果评估指标</div> 203 style="font-family: simsun;height: 40px;display: block;line-height: 32px;font-size: 18px;color: #212121;font-weight: 700;text-align: center;margin-top: 10px;margin-bottom: 10px;">匿名化效果评估指标</div>
205 <p style="font-family: simsun;margin: 0px;font-size: 14px;line-height: 21px;white-space: pre-wrap;color: #212121;">{{ ' 依据GB/T 42460-2023《信息安全技术个人信息去标识化效果评估指南》附录D,对去标识化以后的数据集基于K匿名模型进行去标识化效果的评估。' }}</p> 204 <p style="font-family: simsun;margin: 0px;font-size: 14px;line-height: 21px;white-space: pre-wrap;color: #212121;">{{ ' 依据GB/T 42460-2023《信息安全技术个人信息去标识化效果评估指南》附录D,对去标识化以后的数据集基于K匿名模型进行去标识化效果的评估。' }}</p>
...@@ -395,7 +394,7 @@ const props = defineProps({ ...@@ -395,7 +394,7 @@ const props = defineProps({
395 }, 394 },
396 analysisResultTableFields: { 395 analysisResultTableFields: {
397 type: Array, 396 type: Array,
398 default: [], 397 default: <any>[],
399 }, 398 },
400 originResultTableFieldColumn: { 399 originResultTableFieldColumn: {
401 type: Object, 400 type: Object,
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!