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/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/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%; 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({
import { onMounted, ref } from "vue"; +import testImg from "@/assets/images/test.png"; +import {chunk} from 'lodash-es' const emit = defineEmits(["changeShow"]); function changeContent() { emit("changeShow"); } +const initRem = () => { + const designWidth = 1440; + const rempPx = 16; + const scale = window.innerWidth / designWidth; + document.documentElement.style.fontSize = scale * rempPx + "px"; +}; +onMounted(() => { + initRem(); +}); const item = { - // img: "/src/assets/images/test.png", - img: "http://47.93.59.251/api/image/thumbnail_1755061416414842880.jpeg", + img: testImg, checked: false, title: "YP4567890545", date: "2023-12-19 12:09:18", @@ -19,6 +29,7 @@ onMounted(() => { for (let i = 0; i < 8; i++) { data.value.push(item as any); } + data.value = chunk(data.value,4) }); @@ -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/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, 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/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" />
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) => {
+