瀏覽代碼

reactor知识库审核记录调整;

zhangchong 8 月之前
父節點
當前提交
f7110c628e

+ 1 - 1
package.json

@@ -26,7 +26,7 @@
 		"axios": "^1.4.0",
 		"dayjs": "^1.11.9",
 		"echarts": "^5.5.0",
-		"element-plus": "^2.7.1",
+		"element-plus": "^2.7.7",
 		"file-saver": "^2.0.5",
 		"html-docx-js-typescript": "^0.1.5",
 		"html2canvas": "^1.4.1",

+ 84 - 30
src/components/CommonAdvice/index.vue

@@ -1,20 +1,23 @@
 <template>
 	<div class="textarea w100">
-		<el-input
-			v-model="value"
-			type="textarea"
-			show-word-limit
-			:autosize="{ minRows: props.minRows, maxRows: props.maxRows }"
-			:placeholder="props.placeholder"
-			:maxlength="props.maxlength"
-			:disabled="props.disabled"
-      class="textarea-content"
-		>
-		</el-input>
-		<span class="buttons">
-			<el-button @click="showAdvice" class="default-button"  :disabled="props.disabled">常用意见</el-button>
-			<el-button type="primary" @click="onAddAdvice" :disabled="props.disabled">添加到常用意见</el-button>
-		</span>
+		<div style="position: relative">
+			<el-input
+				v-model="value"
+				type="textarea"
+				show-word-limit
+				:autosize="{ minRows: props.minRows, maxRows: props.maxRows }"
+				:placeholder="props.placeholder"
+				:maxlength="props.maxlength"
+				:disabled="props.disabled"
+				class="textarea-content"
+			>
+			</el-input>
+			<span class="buttons">
+				<el-button @click="textCheck" class="default-button" :disabled="props.disabled" v-if="props.showTextCheck">文本检查</el-button>
+				<el-button @click="showAdvice" class="default-button" :disabled="props.disabled">常用意见</el-button>
+				<el-button type="primary" @click="onAddAdvice" :disabled="props.disabled">添加到常用意见</el-button>
+			</span>
+		</div>
 		<el-drawer v-model="state.showDrawer" :size="props.drawerWidth" :show-close="false" :modal="props.modal">
 			<template #header="{ close }">
 				<div class="comments-header">
@@ -73,7 +76,7 @@
 						</ul>
 					</template>
 				</template>
-        <el-empty v-if="!state.adviceList.length && state.active !== 'add'"/>
+				<el-empty v-if="!state.adviceList.length && state.active !== 'add'" />
 				<!-- 新增意见 -->
 				<template v-if="state.active === 'add'">
 					<div>
@@ -84,8 +87,8 @@
 									type="textarea"
 									:autosize="{ minRows: 10, maxRows: 10 }"
 									placeholder="请填写常用意见内容"
-                  show-word-limit
-                  maxlength="200"
+									show-word-limit
+									maxlength="200"
 								>
 								</el-input>
 							</el-form-item>
@@ -106,6 +109,9 @@
 				</div>
 			</template>
 		</el-drawer>
+		<div v-if="wrongText" class="wrong-text">
+			<span class="wrong-label">错别字:</span><span class="color-danger wrong-content">{{ wrongText }}</span>
+		</div>
 	</div>
 </template>
 
@@ -118,7 +124,7 @@ const emit = defineEmits(['chooseAdvice', 'update:modelValue']);
 const props = defineProps({
 	modal: {
 		type: Boolean,
-		default:false,
+		default: false,
 	},
 	modelValue: {
 		type: String,
@@ -156,6 +162,11 @@ const props = defineProps({
 		type: [Number, String],
 		default: '35%',
 	},
+	showTextCheck: {
+		// 是否展示文本检查
+		type: Boolean,
+		default: false,
+	},
 } as any);
 const activeName = ref('personal'); // 默认选中tab
 const value = computed({
@@ -235,7 +246,7 @@ const getList = async () => {
 // 切换tab查询意见
 const handleClick = (val: string) => {
 	isOpen.value = val === 'public';
-  if(isOpen.value) state.manage = false;
+	if (isOpen.value) state.manage = false;
 	getList();
 };
 // 选中常用意见(管理)
@@ -276,7 +287,7 @@ const deleteAdvice = () => {
 		type: 'warning',
 	})
 		.then(() => {
-      const ids = state.chooseAdvice.map((item: any) => item.id);
+			const ids = state.chooseAdvice.map((item: any) => item.id);
 			deleteCommon({ ids }).then(() => {
 				ElMessage.success('操作成功');
 				resetState();
@@ -310,6 +321,36 @@ const chooseAdvice = (item: any) => {
 const closeDialog = () => {
 	state.showDrawer = false;
 };
+// 文件检查
+const wrongText = ref('');
+const textCheck = () => {
+	ElMessageBox.confirm(`确认要检查文本内容?`, '提示', {
+		confirmButtonText: '确认',
+		cancelButtonText: '取消',
+		type: 'warning',
+		draggable: true,
+		cancelButtonClass: 'default-button',
+		autofocus: false,
+		beforeClose: (action, instance, done) => {
+			if (action === 'confirm') {
+				instance.confirmButtonLoading = true;
+				instance.confirmButtonText = '检查中,请稍后';
+				setTimeout(() => {
+					done();
+					instance.confirmButtonLoading = false;
+				}, 700);
+			} else {
+				done();
+			}
+		},
+	})
+		.then(async () => {
+			ElMessage.success('检查成功');
+			wrongText.value = '';
+			closeDialog();
+		})
+		.catch(() => {});
+};
 // 暴露变量
 defineExpose({
 	openDialog,
@@ -318,17 +359,16 @@ defineExpose({
 </script>
 <style lang="scss" scoped>
 .textarea {
-  .textarea-content{
-    position: relative;
-    :deep(.el-input__count) {
-      font-size: 16px;
-      bottom: 18px;
-      right: 250px;
-    }
-  }
+	.textarea-content {
+		:deep(.el-input__count) {
+			font-size: 16px;
+			bottom: 15px;
+			right: 10px;
+		}
+	}
 	.buttons {
 		position: absolute;
-		right: 10px;
+		right: 80px;
 		bottom: 10px;
 	}
 	:deep(.el-textarea__inner) {
@@ -360,6 +400,20 @@ defineExpose({
 		}
 	}
 }
+.wrong-text{
+	line-height: 24px;
+	display: flex;
+	margin-top: 5px;
+	.wrong-label{
+		flex: 0 0 auto;
+	}
+	.wrong-content{
+		align-items: center;
+		flex:1;
+		min-width: 0;
+		word-break: break-all;
+	}
+}
 .comments-header {
 	.active {
 		color: var(--el-color-primary);

+ 6 - 3
src/views/business/secondHandle/audit.vue

@@ -51,7 +51,7 @@
 					</el-form>
 				</template>
 				<template #tableHeader="scope">
-					<el-button type="primary" @click="onAuditMultiple" v-auth="'business:secondHandle:audit:multiple'" :disabled="!scope.isSelected"
+					<el-button type="primary" @click="onAuditMultiple" v-auth="'business:secondHandle:audit:multiple'" :disabled="!scope.isSelected" v-if="state.queryParams.Status === 1"
 						>批量审批
 					</el-button>
 				</template>
@@ -99,8 +99,11 @@ const ruleFormRef = ref<RefType>(); // 表单ref
 const router = useRouter(); // 路由
 const proTableRef = ref<RefType>(); // 表格ref
 // 表格配置项
+const selectable = (row: any) => {
+	return row.state === 1;
+};
 const columns = ref<any[]>([
-	{ type: 'selection', fixed: 'left', width: 40, align: 'center' },
+	{ type: 'selection', fixed: 'left', width: 40, align: 'center',selectable: selectable },
 	{ prop: 'order.expiredStatusText', label: '超期状态', align: 'center', width: 80 },
 	{ prop: 'order.no', label: '工单编码', minWidth: 140 },
 	{ prop: 'stateText', label: '办理状态', minWidth: 100 },
@@ -119,7 +122,7 @@ const columns = ref<any[]>([
 	},
 	{ prop: 'order.acceptType', label: '受理类型', minWidth: 100 },
 	{ prop: 'order.hotspotName', label: '热点分类', minWidth: 150 },
-	{ prop: 'operation', label: '操作', fixed: 'right', minWidth: 90, align: 'center' },
+	{ prop: 'operation', label: '操作', fixed: 'right', minWidth: 120, align: 'center' },
 ]);
 const state = reactive<any>({
 	queryParams: {

+ 3 - 3
src/views/knowledge/component/Audit-progress.vue

@@ -33,10 +33,10 @@ const columns = ref<any[]>([
 	{ prop: 'workflow.actualHandlerName', label: '审核人', width: 150 },
 	{ prop: 'workFlowApplyStatusText', label: '审核状态', width: 150 },
 	{
-		prop: 'workflow.actualHandleTime',
+		prop: 'handleTime',
 		label: '审核时间',
 		width: 170,
-		render: (scope: any) => formatDate(scope.row.workflow.actualHandleTime, 'YYYY-mm-dd HH:MM:SS'),
+		render: (scope: any) => formatDate(scope.row.handleTime, 'YYYY-mm-dd HH:MM:SS'),
 	},
 	{ prop: 'actualOpinion', label: '备注' },
 ]);
@@ -57,8 +57,8 @@ const loading = ref<Boolean>(false);
 // 打开弹窗
 const openDialog = (id: string) => {
 	state.queryParams.id = id;
-	queryList();
 	state.dialogVisible = true;
+	queryList();
 };
 const queryList = () => {
 	loading.value = true;

+ 4 - 4
yarn.lock

@@ -2292,10 +2292,10 @@ electron-to-chromium@^1.4.820:
   resolved "https://registry.npmmirror.com/electron-to-chromium/-/electron-to-chromium-1.4.832.tgz#d25882ce0a9237577b039bffa124ecef1822003b"
   integrity sha512-cTen3SB0H2SGU7x467NRe1eVcQgcuS6jckKfWJHia2eo0cHIGOqHoAxevIYZD4eRHcWjkvFzo93bi3vJ9W+1lA==
 
-element-plus@^2.7.1:
-  version "2.7.7"
-  resolved "https://registry.npmmirror.com/element-plus/-/element-plus-2.7.7.tgz#317a4b826d577f4572ca040f2568eb751edd891d"
-  integrity sha512-7ucUiDAxevyBE8JbXBTe9ofHhS047VmWMLoksE45zZ08XSnhnyG7WUuk3gmDbAklfVMHedb9sEV3OovPUWt+Sw==
+element-plus@^2.7.7:
+  version "2.7.8"
+  resolved "https://registry.npmmirror.com/element-plus/-/element-plus-2.7.8.tgz#5de53bbcb455653a27b43418e3569a22ead59866"
+  integrity sha512-h6dx2XihAbQaud0v+6O7Fy0b0G3YNplNVH7QnK3csTcvQd4y4raiyMRQpf9EKbRbTMdNrFsqAZrs9ok9DMcJHg==
   dependencies:
     "@ctrl/tinycolor" "^3.4.1"
     "@element-plus/icons-vue" "^2.3.1"