From 49a7e5c0535fbf2f9194875fba9e2ce033048c0a Mon Sep 17 00:00:00 2001 From: liushilong <2224574157@qq.com> Date: Wed, 10 Apr 2024 11:42:00 +0800 Subject: [PATCH 1/5] =?UTF-8?q?feat:=20=E6=89=80=E6=9C=89=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E6=96=B0=E5=A2=9E=E5=8F=B3=E4=B8=8B=E8=A7=92=E5=9B=BE?= =?UTF-8?q?=E6=A0=87=EF=BC=8C=E4=BF=AE=E6=94=B9=E7=99=BB=E5=BD=95=E5=BC=B9?= =?UTF-8?q?=E7=AA=97=EF=BC=8C=E4=BF=AE=E6=94=B9=E6=A0=B7=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components.d.ts | 1 + src/assets/icons/modal_reImg.svg | 61 +++++++++++++++++++ src/components/Robot/index.vue | 29 +++++++++ src/views/final/content/ListContent.vue | 50 +++++++++++---- src/views/final/index.vue | 4 ++ src/views/home/content/Content.vue | 9 ++- .../home/content/modal/LoginSuccessModal.vue | 6 ++ src/views/home/index.vue | 13 +++- src/views/task/index.vue | 2 + src/views/worksheet/index.vue | 4 ++ 10 files changed, 163 insertions(+), 16 deletions(-) create mode 100644 src/assets/icons/modal_reImg.svg create mode 100644 src/components/Robot/index.vue diff --git a/components.d.ts b/components.d.ts index d6fb45b..9398d24 100644 --- a/components.d.ts +++ b/components.d.ts @@ -53,6 +53,7 @@ declare module 'vue' { NUpload: typeof import('naive-ui')['NUpload'] NUploadDragger: typeof import('naive-ui')['NUploadDragger'] Quill: typeof import('./src/components/RichEditor/Quill.vue')['default'] + Robot: typeof import('./src/components/Robot/index.vue')['default'] RouterLink: typeof import('vue-router')['RouterLink'] RouterView: typeof import('vue-router')['RouterView'] Search: typeof import('./src/components/Search/Search.vue')['default'] diff --git a/src/assets/icons/modal_reImg.svg b/src/assets/icons/modal_reImg.svg new file mode 100644 index 0000000..56273c1 --- /dev/null +++ b/src/assets/icons/modal_reImg.svg @@ -0,0 +1,61 @@ + + + 编组 33 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/components/Robot/index.vue b/src/components/Robot/index.vue new file mode 100644 index 0000000..aef8ee2 --- /dev/null +++ b/src/components/Robot/index.vue @@ -0,0 +1,29 @@ + + + + + diff --git a/src/views/final/content/ListContent.vue b/src/views/final/content/ListContent.vue index c9e0ee5..ee0cc20 100644 --- a/src/views/final/content/ListContent.vue +++ b/src/views/final/content/ListContent.vue @@ -1,14 +1,24 @@ @@ -40,14 +51,14 @@ onMounted(() => { -
-
+
+
-
+
任务ID:{{ item.title }}
@@ -164,22 +175,26 @@ onMounted(() => { display: flex; flex-flow: row wrap; align-items: center; - justify-content: flex-start; + // justify-content: flex-start; + justify-content: space-between; flex: 1; .item { - width: 23%; + min-width: 14.125rem; border: 1px solid #ededed; border-radius: 3px; padding: 8px 10px; - margin-right: 10px; + margin-right: 20px; + margin-bottom: 16px; .top { display: flex; flex-flow: row nowrap; align-items: center; justify-content: flex-start; .img { - width: 50%; - height: 70px; + width: 84px; + height: 55px; + // height: auto; + object-fit: cover; border-radius: 3px; .check_box { margin-left: 8px; @@ -202,15 +217,21 @@ onMounted(() => { align-items: center; justify-content: flex-start; .tag_item { - width: 31px; - height: 14px; + min-width: 31px; + min-height: 14px; font-size: 10px; + padding: 1px 3px; font-weight: bolder; text-align: left; // color: #507afd; line-height: 14px; letter-spacing: 0.1px; margin-right: 8px; + // opacity: 0.1; + background: #c0f7e4; + border-radius: 2px; + text-align: center; + white-space: nowrap } } } @@ -219,6 +240,9 @@ onMounted(() => { flex-flow: row nowrap; align-items: center; justify-content: flex-end; + div { + cursor: pointer; + } .resovle_action { font-size: 12px; font-weight: bolder; @@ -230,7 +254,7 @@ onMounted(() => { font-size: 12px; font-weight: bolder; text-align: left; - color: #ff4e4f; + color: #FF4E4F; line-height: 17px; margin-left: 15px; } diff --git a/src/views/final/index.vue b/src/views/final/index.vue index 102a011..20d020f 100644 --- a/src/views/final/index.vue +++ b/src/views/final/index.vue @@ -3,6 +3,8 @@ import { ref } from 'vue' import Aside from './aside/Aside.vue' import Content from './content/Content.vue' import ListContent from './content/ListContent.vue' +import Robot from '@/components/Robot/index.vue' + defineOptions({ name: 'FinalMain', @@ -24,6 +26,8 @@ function inputChange(keyword) { + +
diff --git a/src/views/home/content/Content.vue b/src/views/home/content/Content.vue index fdc5e9b..87c3a39 100644 --- a/src/views/home/content/Content.vue +++ b/src/views/home/content/Content.vue @@ -378,7 +378,7 @@ async function tasksLoadingCloseCallback() { async function showLoginSuccessModal() { const modal = LoginSuccessModalRef.value as any; - // modal.showModal() + modal.showModal() } // 包id @@ -621,6 +621,11 @@ const loadImgOver = (item) => { console.log("loadImgOver", item); setTimeout(() => (item.loadOver = true), 2000); }; + +defineExpose({ + showLoginSuccessModal +}) + diff --git a/src/views/task/index.vue b/src/views/task/index.vue index e4451c0..20a4d52 100644 --- a/src/views/task/index.vue +++ b/src/views/task/index.vue @@ -3,6 +3,7 @@ import { ref } from "vue"; import Aside from "./aside/Aside.vue"; import Content from "./content/Content.vue"; import DataHeader from "@/components/DataHeader/index.vue"; +import Robot from '@/components/Robot/index.vue' const asideRef: any = ref(null); @@ -23,6 +24,7 @@ function setAsideItemName(text) {
+
diff --git a/src/views/worksheet/index.vue b/src/views/worksheet/index.vue index a183336..2c6ccfd 100644 --- a/src/views/worksheet/index.vue +++ b/src/views/worksheet/index.vue @@ -4,6 +4,9 @@ import { ref } from "vue"; import Aside from "./aside/Aside.vue"; import Content from "./content/Content.vue"; import { useWorkOrder } from "@/store/modules/workOrder"; +import Robot from '@/components/Robot/index.vue' + + const workStore = useWorkOrder(); const contentRef: any = ref(null); const ApprovalOver = (packageId) => { @@ -24,6 +27,7 @@ const ApprovalOver = (packageId) => {
+
From af102caccd82847ebbc141f5c199b9f529ac8238 Mon Sep 17 00:00:00 2001 From: Dragon <> Date: Wed, 10 Apr 2024 11:44:10 +0800 Subject: [PATCH 2/5] =?UTF-8?q?=E6=98=BE=E7=A4=BA=E5=85=A8=E9=83=A8?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E6=95=B0=E6=8D=AE=E9=BB=98=E8=AE=A4=E5=80=BC?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/config/final.ts | 2 +- src/views/home/aside/comp/items/IzShowAll.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/config/final.ts b/src/config/final.ts index 23cbfc5..a258f4b 100644 --- a/src/config/final.ts +++ b/src/config/final.ts @@ -122,7 +122,7 @@ export const asideMap: Recordable = { }, izshowall: { label: '显示全部任务数据', - defaultValue: true, + defaultValue: false, isDefaultFilter: false, key: 'izshowall', component: IzShowAll, diff --git a/src/views/home/aside/comp/items/IzShowAll.vue b/src/views/home/aside/comp/items/IzShowAll.vue index 37908b4..132c576 100644 --- a/src/views/home/aside/comp/items/IzShowAll.vue +++ b/src/views/home/aside/comp/items/IzShowAll.vue @@ -5,7 +5,7 @@ import { useConfig } from '@/store/modules/asideConfig' const props = defineProps({ value: { type: Boolean, - default: true, + default: false, }, label: { type: String, From b4ef13b319e9edb8d2edb43f292db5c888180c7c Mon Sep 17 00:00:00 2001 From: lihui_ocr Date: Wed, 10 Apr 2024 12:02:08 +0800 Subject: [PATCH 3/5] =?UTF-8?q?feat:=E4=B8=BB=E5=9B=BE=E5=8A=A0=E5=85=A5?= =?UTF-8?q?=E5=88=B0=E5=8F=AF=E7=96=91=E6=96=87=E4=BB=B6=E4=B8=AD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/task/content/Content.vue | 41 +++++++++++++++++++++++------- 1 file changed, 32 insertions(+), 9 deletions(-) diff --git a/src/views/task/content/Content.vue b/src/views/task/content/Content.vue index 050a734..fc77327 100644 --- a/src/views/task/content/Content.vue +++ b/src/views/task/content/Content.vue @@ -124,13 +124,17 @@ function handleKeydown(event) { if (now - lastKeyPressTime < doubleClickInterval) { // 清除已经设置的定时器(如果有的话) clearTimeout(keyPressTimer); - const item = taskDetailInfo.value; - if (item?.userapprove?.statshis === 2 || item?.userapprove?.statshis == 3) { - overTask.value = null; - return; - } + const item = taskDetailInfo.value; + if ( + item?.userapprove?.statshis === 2 || + item?.userapprove?.statshis == 3 + ) { + overTask.value = null; + return; + } - if (validate([item]) == null && batch.value === false) overTask.value = item; + if (validate([item]) == null && batch.value === false) + overTask.value = item; // 执行想要的操作 approvalHandler(); @@ -158,7 +162,7 @@ function handleKeydown(event) { // 执行想要的操作 const modal = unref(notPassModalRef)! as any; - modal.showModal([taskDetailInfo.value]); + modal.showModal([taskDetailInfo.value]); // 重置上次按键时间 lastKeyPressTime = 0; @@ -307,6 +311,7 @@ function backHandler() { } async function handleDragEnd(event, item) { + console.log(event, item); // 可以在这里添加拖拽结束后的逻辑 const flag = taskStore.getInFile; if (flag) { @@ -322,7 +327,25 @@ async function handleDragEnd(event, item) { taskStore.setInFile(false); } } +async function addSuspicious() { + console.log(taskDetailInfo.value.ocrPicture) + if (taskDetailInfo.value.ocrPicture.pictureid) { + const res = await dubiousfileyd({ + pictureid: taskDetailInfo.value.ocrPicture.id, + }); + console.log(res) + if (res.code === "OK") { + message.success("加入成功"); + setBatch(false); + getTableData(); + getImgList(); + } else { + message.error(res.message); + } + taskStore.setInFile(false); + +}} async function getTableData() { const useInfo = userStore.getUserInfo; const listData = []; @@ -616,10 +639,10 @@ function overTaskHandelr(item: any) { @click.stop="singleRejectHandler" />
From bc7fcf648d66e1fc1432ab3da2fc44b74019e2ba Mon Sep 17 00:00:00 2001 From: Dragon <> Date: Wed, 10 Apr 2024 13:32:06 +0800 Subject: [PATCH 4/5] =?UTF-8?q?=E7=BB=88=E5=AE=A1=E5=8A=A8=E6=80=81?= =?UTF-8?q?=E5=88=97=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/final/content/Content.vue | 30 +++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) diff --git a/src/views/final/content/Content.vue b/src/views/final/content/Content.vue index 07589d1..a7aa03d 100644 --- a/src/views/final/content/Content.vue +++ b/src/views/final/content/Content.vue @@ -58,6 +58,7 @@ const actionsColumns = { title: '操作', key: 'actions', minWidth: 200, + width: 200, fixed: 'right', render(row) { return h(ListAction, { @@ -394,15 +395,6 @@ async function formatColumns() { key: columnsRef.value[index].key, fixed: columnsRef.value[index].fixed || undefined, width: 200, - sorter: 'default', - renderSorterIcon: ({ order }) => { - if (order === false) - return h(SvgIcon, { name: 'sort-2' }) - if (order === 'ascend') - return h(SvgIcon, { name: 'sort-1' }) - if (order === 'descend') - return h(SvgIcon, { name: 'sort-3' }) - }, render(row: any) { return row.fromusername }, @@ -576,6 +568,23 @@ const maxHeight = computed(() => { return tableData.value.length ? `${unref(deviceHeight)}px` : 'auto' }) +const scrollX = computed(() => { + const table = unref(tableRef) + if (!table) + return + const tableEl: any = table?.$el + const wrapper = tableEl.querySelector('.n-data-table-wrapper') + const arr = columnsRef.value.filter(item => !item.fixed) + let width = 0 + console.log(arr) + arr.forEach((item) => { + width += Number(item.width) || 200 + }) + console.log(wrapper.offsetWidth + width) + console.log(arr) + return wrapper.offsetWidth + width +}) + query(pagination.page, pagination.pageSize) const customTabelRef = ref(null) @@ -967,11 +976,12 @@ defineExpose({
Date: Wed, 10 Apr 2024 13:42:22 +0800 Subject: [PATCH 5/5] =?UTF-8?q?=E7=AD=9B=E9=80=89=E8=83=8C=E6=99=AF?= =?UTF-8?q?=E8=89=B2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/final/comp/CustomFilterModalVue.vue | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/views/final/comp/CustomFilterModalVue.vue b/src/views/final/comp/CustomFilterModalVue.vue index b8f1a58..fd81a3b 100644 --- a/src/views/final/comp/CustomFilterModalVue.vue +++ b/src/views/final/comp/CustomFilterModalVue.vue @@ -260,7 +260,7 @@ const rightInputHandler = debounce((keyword) => { 自定义筛选
- 筛选项信息 + 筛选项信息
@@ -442,7 +442,6 @@ const rightInputHandler = debounce((keyword) => { .draggable-ul { width: 100%; overflow: hidden; - background: #f8f8f8; .draggable-li { width: 100%;