Merge branch 'dev' into dev_tides
# Conflicts:
# src/permission.js
# src/utils/auth.js
已修改178个文件
已复制2个文件
已重命名4个文件
已删除2个文件
已添加7个文件
| | |
| | | "@vue-office/excel": "^1.7.14", |
| | | "@vue/composition-api": "^1.7.2", |
| | | "axios": "0.28.1", |
| | | "big.js": "^6.2.2", |
| | | "clipboard": "2.0.8", |
| | | "core-js": "3.37.1", |
| | | "dom-to-image": "^2.6.0", |
| | |
| | | data: query |
| | | }) |
| | | } |
| | | |
| | | // æ¥åå¯¼åº |
| | | export function reportAllExport(query) { |
| | | return request({ |
| | | url: '/insReport/reportAllExport', |
| | | method: 'get', |
| | | params: query, |
| | | responseType: "blob" |
| | | }) |
| | | } |
| | | |
| | |
| | | return request({ |
| | | url: '/rawMaterialOrder/rawAllExport', |
| | | method: 'get', |
| | | data: query, |
| | | params: query, |
| | | responseType: "blob" |
| | | }) |
| | | } |
| | |
| | | data: query |
| | | }) |
| | | } |
| | | // ä¿®æ¹æ ·ååå· |
| | | export function updateSampleModel(query) { |
| | | return request({ |
| | | url: '/insOrder/updateSampleModel', |
| | | method: 'post', |
| | | data: query |
| | | }) |
| | | } |
| | |
| | | return request({ |
| | | url: '/rawMaterialOrder/rawAllExport', |
| | | method: 'get', |
| | | data: query, |
| | | params: query, |
| | | responseType: "blob" |
| | | }) |
| | | } |
| | |
| | | export function saveUnqualifiedContext(query) { |
| | | return request({ |
| | | url: '/insOrderPlan/saveUnqualifiedContext', |
| | | method: 'delete', |
| | | params: query |
| | | method: 'post', |
| | | data: query |
| | | }) |
| | | } |
| | |
| | | params: query, |
| | | }); |
| | | } |
| | | //å é¤ä¸åæ ¼å¤ç |
| | | //æäº¤OAæµç¨ |
| | | export function pushOA(query) { |
| | | return request({ |
| | | url: "/unqualifiedHandler/pushOA", |
| | | method: "delete", |
| | | params: query, |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | |
| | | export function confirmPersonnelCapability(query) { |
| | | return request({ |
| | | url: "/personPersonnelCapacity/confirmPersonnelCapability", |
| | | method: "get", |
| | | params: query |
| | | method: "post", |
| | | data: query |
| | | }); |
| | | } |
| | | // å é¤äººåè½å |
| | |
| | | return request({ |
| | | url: "/personBasicInfo/exportPersonBasicInfo", |
| | | method: "get", |
| | | data: query, |
| | | params: query, |
| | | responseType: "blob" |
| | | }); |
| | | } |
| | |
| | | return request({ |
| | | url: '/qualitySupervise/exportQualitySupervise', |
| | | method: 'get', |
| | | data: query, |
| | | params: query, |
| | | responseType: "blob" |
| | | }) |
| | | } |
| | |
| | | }); |
| | | } |
| | | |
| | | // 导å
¥æ åæç» |
| | | export function importStandardDetails(data) { |
| | | return request({ |
| | | url: "/standardMethod/importStandardDetails", |
| | | method: "post", |
| | | data: data, |
| | | }); |
| | | } |
| | |
| | | url: "/processReport/exportProcessReport", |
| | | method: "get", |
| | | params: data, |
| | | responseType: "blob", |
| | | }); |
| | | } |
| | | |
| | |
| | | // æ£æµææ ¡åç©åçå¤ç½® |
| | | import request from "@/utils/request"; |
| | | |
| | | // æ£æµææ ¡åç©åçå¤ç½® |
| | | // ä¿®æ¹ |
| | | export function doProcessDeal(data) { |
| | | return request({ |
| | |
| | | }); |
| | | } |
| | | |
| | | // æ°å¢ |
| | | // æ°å¢è¯¦æ
|
| | | export function addProcessDeal(data) { |
| | | return request({ |
| | | url: "/processDeal/addProcessDeal", |
| | |
| | | data: data, |
| | | }); |
| | | } |
| | | // æäº¤åå² ä¼ åid |
| | | export function addProcessTotaldeal(data) { |
| | | return request({ |
| | | url: "/processTotaldeal/addProcessTotaldeal", |
| | | method: "post", |
| | | data: data, |
| | | }); |
| | | } |
| | | |
| | | //æ¥è¯¢è¯¦æ
å页æ¥è¯¢éé¢totaldealId ä¼ ååå²çid |
| | | export function pageProcessDeal(query) { |
| | | export function getProcessDeal(query) { |
| | | return request({ |
| | | url: "/processDeal/pageProcessDeal", |
| | | url: "/processDeal/getProcessDeal", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | |
| | | params: query, |
| | | }); |
| | | } |
| | | |
| | | //æ ·åå¤çå¯¼åº |
| | | export function exportProcessTotaldeal(query) { |
| | | return request({ |
| | | url: "/processTotaldeal/exportProcessTotaldeal", |
| | | method: "get", |
| | | responseType: "blob", |
| | | params: query, |
| | | }); |
| | | } |
| | | |
| | | // æ ·åæ¥æ¶-å页æ¥è¯¢ |
| | | export function pageProcessSample(query) { |
| | | return request({ |
| | | url: "/processSample/pageProcessSample", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | // æ ·åæ¥æ¶-æ°å¢/ä¿®æ¹ |
| | | export function addProcessSample(query) { |
| | | return request({ |
| | | url: "/processSample/addProcessSample", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | | // æ ·åæ¥æ¶-å é¤ |
| | | export function delProcessSample(query) { |
| | | return request({ |
| | | url: "/processSample/delProcessSample", |
| | | method: "delete", |
| | | params: query, |
| | | }); |
| | | } |
| | | // æ ·åæ¥æ¶-å¯¼åº |
| | | export function exportProcessSample(query) { |
| | | return request({ |
| | | url: "/processSample/exportProcessSample", |
| | | method: "get", |
| | | responseType: "blob", |
| | | params: query, |
| | | }); |
| | | } |
| | |
| | | }); |
| | | } |
| | | |
| | | //æ¥è¯¢æ°éé
ç½® |
| | | // æ¥è¯¢æ°éé
ç½® |
| | | export function queryDataAcquisitionConfiguration(query) { |
| | | return request({ |
| | | url: "/deviceScope/queryDataAcquisitionConfiguration", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | // æ¥è¯¢æ°éé
ç½® |
| | | export function queryProductConfiguration(query) { |
| | | return request({ |
| | | url: "/deviceScope/queryProductConfiguration", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | // æ°éé
ç½®--æ¥è¯¢æ£éªé¡¹ |
| | | export function getNoConfigProduct(query) { |
| | | return request({ |
| | | url: "/deviceScope/getNoConfigProduct", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | |
| | | data: data, |
| | | }); |
| | | } |
| | | |
| | | //å 餿°éé
ç½® |
| | | export function deleteDataAcquisitionConfiguration(data) { |
| | | // ç»´æ¤æä»¶é
ç½® |
| | | export function saveDeviceFileConfiguration(data) { |
| | | return request({ |
| | | url: "/deviceScope/deleteDataAcquisitionConfiguration", |
| | | url: "/deviceScope/saveDeviceFileConfiguration", |
| | | method: "post", |
| | | data: data, |
| | | }); |
| | | } |
| | | |
| | | //å 餿°éé
ç½® |
| | | export function deleteDataAcquisitionConfiguration(query) { |
| | | return request({ |
| | | url: "/deviceScope/deleteDataAcquisitionConfiguration", |
| | | method: "delete", |
| | | params: query, |
| | | }); |
| | | } |
| | | |
| | |
| | | }); |
| | | } |
| | | |
| | | //设å¤ä¿å
»åæ¡å¯¼åº |
| | | export function exportMaintenanceRecord(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/exportMaintenanceRecord", |
| | | method: "get", |
| | | responseType: "blob", |
| | | params: query, |
| | | }); |
| | | } |
| | | |
| | | //设å¤ç»´æ¤å é¤ |
| | | export function deleteDeviceMaintenance(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/deleteDeviceMaintenance", |
| | | method: "delete", |
| | | params: query, |
| | | }); |
| | | } |
| | | |
| | | // æ°å¢è®¾å¤ç»´æ¤ä¿å
» |
| | | export function addDeviceMaintenance(data) { |
| | | return request({ |
| | | url: "/deviceMaintain/addDeviceMaintenance", |
| | | method: "post", |
| | | data: data, |
| | | }); |
| | | } |
| | | //设å¤ç»´æ¤è¡¨ æ¥è¯¢ |
| | | export function getDeviceMaintenancePage(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/getDeviceMaintenancePage", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | |
| | | // åç¨-ä¿å |
| | | export function saveDeviceBorrow(data) { |
| | | return request({ |
| | |
| | | params: query, |
| | | }); |
| | | } |
| | | //ä½ä¸æå¯¼ä¹¦ æ¥è¯¢ |
| | | export function getDeviceById(query) { |
| | | return request({ |
| | | url: "/deviceScope/getDeviceById", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ç»´æ¤ä¿å
» æ¥è¯¢ |
| | | export function selectDeviceMaintenancePage(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/selectDeviceMaintenancePage", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ç»´æ¤ä¿å
» å é¤ |
| | | export function deleteDeviceMaintenance(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/deleteDeviceMaintenance", |
| | | method: "delete", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ç»´æ¤ä¿å
» æ°å¢ |
| | | export function addDeviceMaintenance(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/addDeviceMaintenance", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | | |
| | | //使ç¨è®°å½ å¯¼åº |
| | | export function exportDeviceMaintenance(query) { |
| | | return request({ |
| | | url: "/deviceMaintain/exportDeviceMaintenance", |
| | | method: "get", |
| | | responseType: "blob", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ å页æ¥è¯¢ |
| | | export function selectDeviceImpowerByPage(query) { |
| | | return request({ |
| | | url: "/deviceImpower/selectDeviceImpowerByPage", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ æ¥è¯¢è¯¦æ
|
| | | export function getImpowerDetail(query) { |
| | | return request({ |
| | | url: "/deviceImpower/getImpowerDetail", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ å é¤ |
| | | export function deleteImpower(query) { |
| | | return request({ |
| | | url: "/deviceImpower/deleteImpower", |
| | | method: "delete", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ å¯¼åº |
| | | export function exportDeviceImpower(query) { |
| | | return request({ |
| | | url: "/deviceImpower/exportDeviceImpower", |
| | | method: "get", |
| | | responseType: "blob", |
| | | params: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ æ°å¢ |
| | | export function addImpower(query) { |
| | | return request({ |
| | | url: "/deviceImpower/addImpower", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ ä¿®æ¹ |
| | | export function updateImpower(query) { |
| | | return request({ |
| | | url: "/deviceImpower/updateImpower", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ æ¹åææ |
| | | export function reviewImpowerStatus(query) { |
| | | return request({ |
| | | url: "/deviceImpower/reviewImpowerStatus", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | | //设å¤ä½¿ç¨ææ æä»·æ¹åéç¥ |
| | | export function submitReviewImpowerStatus(query) { |
| | | return request({ |
| | | url: "/deviceImpower/submitReviewImpowerStatus", |
| | | method: "post", |
| | | data: query, |
| | | }); |
| | | } |
| | |
| | | params: query |
| | | }) |
| | | } |
| | | //é¦é¡µ-->ä¿®æ¹å¾
åäºé¡¹ç¶æ |
| | | export function triggerModificationStatusToRead(query) { |
| | | return request({ |
| | | url: '/informationNotification/triggerModificationStatusToRead', |
| | | method: 'post', |
| | | data: query |
| | | }) |
| | | } |
| | |
| | | }); |
| | | } |
| | | |
| | | // éç½®æ ååºåä»· |
| | | export function resetTreeOfPrice(data) { |
| | | return request({ |
| | | url: "/standardTree/resetTreeOfPrice", |
| | | method: "post", |
| | | data: data, |
| | | }); |
| | | } |
| | | |
| | | // éç½®æ ååºå·¥æ¶ç³»æ° |
| | | export function resetTreeOfHour(data) { |
| | | return request({ |
| | | url: "/standardTree/resetTreeOfHour", |
| | | method: "post", |
| | | data: data, |
| | | }); |
| | | } |
| | | |
| | | // æ£éªé¡¹å¤å¶æåº |
| | | export function copyStandardProductSort(data) { |
| | |
| | | data: query, |
| | | }); |
| | | } |
| | | //æ¥è¯¢é¢è¦å表 |
| | | export function selectDeviationWarningPage(query) { |
| | | return request({ |
| | | url: "/insProductDeviationWarning/selectDeviationWarningPage", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | | //æ¥è¯¢é¢è¦å表 |
| | | export function selectDeviationWarning(query) { |
| | | return request({ |
| | | url: "/insProductDeviationWarning/selectDeviationWarning", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | | } |
| | |
| | | export function deleteProductPart(query) { |
| | | return request({ |
| | | url: '/productPart/deleteProductPart', |
| | | method: 'post', |
| | | method: 'delete', |
| | | params: query |
| | | }) |
| | | } |
| | |
| | | return request({ |
| | | url: "/companies/addPersonUser", |
| | | method: "post", |
| | | params: data, |
| | | data: data, |
| | | }); |
| | | } |
| | | // è·åè§è² |
| | |
| | | .el-button--primary { |
| | | background: #3a7bfa; |
| | | } |
| | | //æ»å¨æ¡ |
| | | ::-webkit-scrollbar |
| | | { |
| | | width: 8px !important; |
| | | height: 8px !important; |
| | | } |
| | |
| | | } |
| | | |
| | | .el-menu-item, .el-submenu__title { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | .el-submenu__title span { |
| | | white-space: normal; |
| | | word-break: break-all; |
| | | line-height: 20px; |
| | | flex: 1; |
| | | padding-right: 20px; |
| | | } |
| | | |
| | | .el-menu-item { |
| | | display: flex; |
| | | align-items: center; |
| | | padding-right: 20px !important; |
| | | } |
| | | .el-menu-item span { |
| | | white-space: normal; |
| | | word-break: break-all; |
| | | line-height: 20px; |
| | | flex: 1; |
| | | overflow: hidden !important; |
| | | text-overflow: ellipsis !important; |
| | | white-space: nowrap !important; |
| | | } |
| | | |
| | | // menu hover |
| | | .submenu-title-noDropdown, |
| | | .el-submenu__title { |
| | | &:hover { |
| | | background-color: rgba(0, 0, 0, 0.06) !important; |
| | | background-color: rgba(0, 0, 0, 0.08) !important; |
| | | } |
| | | } |
| | | |
| | |
| | | min-width: $base-sidebar-width !important; |
| | | |
| | | &:hover { |
| | | background-color: rgba(0, 0, 0, 0.06) !important; |
| | | background-color: rgba(0, 0, 0, 0.08) !important; |
| | | } |
| | | } |
| | | |
| | |
| | | |
| | | .hideSidebar { |
| | | .sidebar-container { |
| | | width: 54px !important; |
| | | width: 70px !important; |
| | | } |
| | | |
| | | .main-container { |
| | | margin-left: 54px; |
| | | margin-left: 70px; |
| | | } |
| | | |
| | | .submenu-title-noDropdown { |
| | |
| | | padding: 0 !important; |
| | | |
| | | .svg-icon { |
| | | margin-left: 20px; |
| | | width: 1.5em; |
| | | height: 1.5em; |
| | | margin-left: 25px; |
| | | } |
| | | } |
| | | } |
| | | |
| | | .el-menu-item.is-active, |
| | | .el-submenu.is-active > .el-submenu__title { |
| | | background-color: transparent !important; |
| | | } |
| | | .el-submenu { |
| | | overflow: hidden; |
| | | |
| | |
| | | padding: 0 !important; |
| | | |
| | | .svg-icon { |
| | | margin-left: 20px; |
| | | width: 1.5em; |
| | | height: 1.5em; |
| | | margin-left: 25px; |
| | | } |
| | | |
| | | } |
| | |
| | | .el-menu--collapse { |
| | | .el-submenu { |
| | | &>.el-submenu__title { |
| | | height: auto; /* æ ¹æ®å
容èªå¨è°æ´é«åº¦ */ |
| | | flex-direction: column; /* æ¹åå¸å±æ¹å为åç´ */ |
| | | align-items: center; /* å±
ä¸å¯¹é½ */ |
| | | margin-bottom: 10px; |
| | | &>span { |
| | | height: 0; |
| | | width: 0; |
| | | overflow: hidden; |
| | | visibility: hidden; |
| | | display: inline-block; |
| | | display: block !important; |
| | | visibility: visible !important; |
| | | white-space: normal; /* å
许æ¢è¡ */ |
| | | text-align: center; /* ææ¬å±
ä¸å¯¹é½ */ |
| | | line-height: normal; |
| | | } |
| | | } |
| | | } |
| | |
| | | pageSizes: { |
| | | type: Array, |
| | | default() { |
| | | return [10, 20, 30, 50] |
| | | return [10, 20, 30, 50, 100] |
| | | } |
| | | }, |
| | | // ç§»å¨ç«¯é¡µç æé®çæ°é端é»è®¤å¼5 |
| | |
| | | |
| | | <el-table-column v-for="(item, index) in column" :key="index" :column-key="item.columnKey" |
| | | :filter-method="item.filterHandler" :filter-multiple="item.filterMultiple" :filtered-value="item.filteredValue" |
| | | :filters="item.filters" :fixed="item.fixed" :label="item.label" :min-width="item.minWidth" :prop="item.prop" |
| | | :show-overflow-tooltip="item.dataType === 'action' || item.dataType === 'slot' ? false : true" |
| | | :filters="item.filters" :fixed="item.fixed" :label="item.label" :prop="item.prop" |
| | | :show-overflow-tooltip="item.dataType === 'action' || item.dataType === 'slot' ? false : true" |
| | | :min-width="item.dataType == 'action' ? btnWidth : item.width" |
| | | :sortable="item.sortable ? true : false" :type="item.type" :width="item.dataType == 'action' ? btnWidth : item.width" align="center"> |
| | | <!-- <div class="123" v-if="item.type == ''"> --> |
| | | <template v-if="item.hasOwnProperty('colunmTemplate')" :slot="item.colunmTemplate" slot-scope="scope"> |
| | |
| | | |
| | | <!-- æé® --> |
| | | <div v-else-if="item.dataType == 'action'" |
| | | :style="`width:${getWidth(item.operation, scope.row)}`"> |
| | | :style="`min-width:${getWidth(item.operation, scope.row)}`"> |
| | | <template v-for="(o, key) in item.operation"> |
| | | <el-button v-show="o.type != 'upload'" size="mini" v-if="o.showHide ? o.showHide(scope.row) : true" |
| | | :disabled="o.disabled ? o.disabled(scope.row) : false" :icon="iconFn(o)" :plain="o.plain" |
| | |
| | | {{ o.name }} |
| | | </el-button> |
| | | <el-upload :action="javaApi + o.url + '?id=' + (o.uploadIdFun ? o.uploadIdFun(scope.row) : scope.row.id)" |
| | | size="mini" ref="upload" :multiple="o.multiple ? o.multiple : false" :limit="1" |
| | | :key="uploadKeys[scope.$index]" |
| | | ref="uploadRef" |
| | | size="mini" :multiple="o.multiple ? o.multiple : false" :limit="1" |
| | | :disabled="o.disabled ? o.disabled(scope.row) : false" :accept="o.accept |
| | | ? o.accept |
| | | : '.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar' |
| | | " v-if="o.type == 'upload'" style="display: inline-block; width: 50px" |
| | | v-show="o.showHide ? o.showHide(scope.row) : true" :headers="uploadHeader" :on-error="onError" |
| | | :on-exceed="onExceed" :on-success="handleSuccessUp" :show-file-list="false" :key="key"> |
| | | v-show="o.showHide ? o.showHide(scope.row) : true" :headers="uploadHeader" |
| | | :before-upload="(file) => beforeUpload(file, scope.$index)" |
| | | :on-change="(file, fileList) => handleChange(file, fileList, scope.$index)" |
| | | :on-error="(error, file, fileList) => onError(error, file, fileList, scope.$index)" |
| | | :on-success="(response, file, fileList) => handleSuccessUp(response, file, fileList, scope.$index)" |
| | | :on-exceed="onExceed" :show-file-list="false"> |
| | | <el-button :size="o.size ? o.size : 'small'" type="text" |
| | | :disabled="o.disabled ? o.disabled(scope.row) : false">{{ o.name }}</el-button> |
| | | </el-upload> |
| | |
| | | name: "ZTTable", |
| | | filters: { |
| | | typeFn(val, row) { |
| | | // console.log(val, row, '11111111'); |
| | | if (typeof val === "function") { |
| | | return val(row); |
| | | } else return val; |
| | |
| | | return { |
| | | spanList: [], |
| | | btnWidth: "120px", |
| | | uploadRefs: [], |
| | | currentFiles: {}, // ç¨äºå卿¯è¡çå½åæä»¶ |
| | | uploadKeys: {} // ç¨äºå¨æéç½®ç»ä»¶ |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.calculateSpanInfo(); |
| | | this.$nextTick(() => { |
| | | this.$refs.multipleTable.doLayout(); |
| | | }); |
| | | this.tableData.forEach((_, index) => { |
| | | if (this.$refs.uploadRef) { |
| | | this.$refs.uploadRef[index] = this.$refs.uploadRef[index] || {}; |
| | | } |
| | | }); |
| | | }) |
| | | }, |
| | | watch: { |
| | | tableData: { |
| | | handler() { |
| | | // å½è¡¨æ ¼æ°æ®ååæ¶ï¼åå§å uploadKeys |
| | | this.tableData.forEach((_, index) => { |
| | | this.$set(this.uploadKeys, index, Date.now()); |
| | | }); |
| | | }, |
| | | immediate: true |
| | | } |
| | | }, |
| | | methods: { |
| | | getWidth(row, row0) { |
| | |
| | | count += a.name.length; |
| | | } |
| | | }); |
| | | this.btnWidth = count * 15 + 50 + "px"; |
| | | return count * 15 + 50 + "px"; |
| | | this.btnWidth = count * 15 + 60 + "px"; |
| | | return count * 15 + 60 + "px"; |
| | | }, |
| | | getTitleWidth(row) { |
| | | if (row.label.includes('æ¶é´') || row.label.includes('ç¼å·') || row.label.includes('æ ·ååç§°') || row.label.includes('é¶ä»¶')) { |
| | | return 160 |
| | | } else if (row.label.includes('æä½')) { |
| | | return row.width |
| | | } else { |
| | | const span = document.createElement('span'); |
| | | span.innerText = row.label; |
| | | document.body.appendChild(span); |
| | | const width = `${span.offsetWidth + 50}px`; |
| | | document.body.removeChild(span); |
| | | |
| | | return width; |
| | | } |
| | | }, |
| | | iconFn(row) { |
| | | if (row.name === "ç¼è¾" || row.name === "ä¿®æ¹") { |
| | | return "el-icon-edit"; |
| | | } else if (row.name === "å é¤") { |
| | | return "el-icon-delete"; |
| | | } else if (row.name === "æ¥ç") { |
| | | return "el-icon-view"; |
| | | } else { |
| | | return row.icon; |
| | | } |
| | | // if (typeof (val) === 'function') { |
| | | // return val(row); |
| | | // } else return val; |
| | | }, |
| | | formatType(val, format) { |
| | | if (typeof format === "function") { |
| | |
| | | setCurrent(row) { |
| | | this.$refs.multipleTable.setCurrentRow(); |
| | | }, |
| | | handleSuccessUp(response, label) { |
| | | if (typeof label === "string") { |
| | | if (response.code == 200) { |
| | | this.upData[label] = response.data.url; |
| | | handleSuccessUp(response, file, fileList, index) { |
| | | if (response.code == 200) { |
| | | // æ¸
餿件åè¡¨å¹¶æ´æ°å½åæä»¶ |
| | | if (this.uploadRefs[index]) { |
| | | this.uploadRefs[index].clearFiles(); |
| | | } |
| | | this.currentFiles[index] = file; |
| | | this.$message.success("ä¸ä¼ æå"); |
| | | // éç½®ç»ä»¶ç¶æ |
| | | this.resetUploadComponent(index); |
| | | |
| | | } else { |
| | | if (response.code == 200) { |
| | | this.$message.success("ä¸ä¼ æå"); |
| | | } |
| | | this.$message.error(response.message); |
| | | } |
| | | }, |
| | | onError(err, file, fileList) { |
| | | this.$message.error("ä¸ä¼ 失败"); |
| | | this.$refs.upload.clearFiles(); |
| | | this.uploading = false; |
| | | resetUploadComponent(index) { |
| | | // 卿æ¹å key æ¥å¼ºå¶éç½®ç»ä»¶ |
| | | this.uploadKeys[index] = Date.now(); // ä½¿ç¨æ¶é´æ³ä½ä¸ºæ°ç key |
| | | }, |
| | | handleChange(file, fileList, index) { |
| | | // 妿æä»¶æ°éè¶
è¿éå¶ï¼ç§»é¤ææ©çæä»¶ |
| | | if (fileList.length > 1) { |
| | | // ç§»é¤ææ©çæä»¶ |
| | | const earliestFile = fileList[0]; |
| | | this.uploadRefs[index].handleRemove(earliestFile); |
| | | } |
| | | |
| | | // æ´æ°å½åæä»¶ |
| | | this.currentFiles[index] = file; |
| | | }, |
| | | beforeUpload (file, index) { |
| | | this.currentFiles[index] = {} |
| | | if (file.size > 1024 * 1024 * 10) { |
| | | this.$message.error('ä¸ä¼ æä»¶ä¸è¶
è¿10M'); |
| | | // this.$refs.upload.clearFiles() |
| | | return false; |
| | | } else { |
| | | return true; |
| | | } |
| | | }, |
| | | onError(error, file, fileList, index) { |
| | | this.$message.error('æä»¶ä¸ä¼ 失败ï¼è¯·éè¯'); |
| | | |
| | | // æ¸
餿件å表 |
| | | if (this.uploadRefs[index]) { |
| | | this.uploadRefs[index].clearFiles(); |
| | | } |
| | | }, |
| | | onExceed() { |
| | | this.$message.warning("è¶
åºæä»¶ä¸ªæ°"); |
| | |
| | | }; |
| | | } |
| | | } |
| | | // // ç¹æ®çåå¹¶è¡ |
| | | // if ( |
| | | // this.data.spanConfig != undefined && |
| | | // this.data.spanConfig.special && |
| | | // this.data.spanConfig.special.main && |
| | | // this.data.spanConfig.special.rows && |
| | | // this.data.spanConfig.special.rows.length > 0 |
| | | // ) { |
| | | // let i = null; |
| | | // let obj = this.data.spanConfig.special.rows.find((item, index) => { |
| | | // i = index; |
| | | // return item.index == columnIndex; |
| | | // }); |
| | | // if (obj) { |
| | | // const _row = this.specialSpanList[i].arr[rowIndex]; |
| | | // const _col = _row > 0 ? 1 : 0; |
| | | // return { |
| | | // rowspan: _row, |
| | | // colspan: _col, |
| | | // }; |
| | | // } |
| | | // } |
| | | }, |
| | | }, |
| | | }; |
| | |
| | | text-align: center; |
| | | } |
| | | |
| | | .link { |
| | | color: rgb(64, 158, 255); |
| | | cursor: pointer; |
| | | } |
| | | >>>.cell { |
| | | padding: 0 !important; |
| | | } |
| | | |
| | | .cell { |
| | | white-space: nowrap; |
| | | overflow: hidden; |
| | |
| | | padding-left: 10px !important; |
| | | } |
| | | |
| | | .link { |
| | | color: rgb(64, 158, 255); |
| | | cursor: pointer; |
| | | } |
| | | |
| | | >>>.el-table__body-wrapper::-webkit-scrollbar { |
| | | height: 10px; |
| | | /* 设置æ»å¨æ¡å®½åº¦ */ |
| | | } |
| | | </style> |
| | | <style> |
| | | .lims-table .highlight-warning-row-border td:first-child { |
| | | border-left: 4px solid #ffcd29; |
| | | } |
| | |
| | | .lims-table .highlight-warning-row-border td:last-child { |
| | | border-right: 4px solid #ffcd29; |
| | | } |
| | | |
| | | /* .lims-table .highlight-danger-row-border td { |
| | | border-top: 2px solid red; |
| | | border-bottom: 2px solid red; |
| | | } */ |
| | | |
| | | .lims-table .highlight-danger-row-border td:first-child { |
| | | border-left: 4px solid #f56c6c; |
| | |
| | | // 渲æç« |
| | | drawStamps(x, y, index) { |
| | | var img = new Image(); |
| | | console.log(this.stampsName) |
| | | // 设置å¾çæº |
| | | img.src = require("@/assets/stamps/" + this.stampsName + ".png"); // æ¿æ¢ä¸ºä½ çå¾ç龿¥ |
| | | let that = this |
| | |
| | | :legend="legend2" |
| | | :lineColors="lineColors" |
| | | :series="echartsSeries2" |
| | | :tooltip="tooltip" |
| | | :tooltip="tooltip1" |
| | | :xAxis="xAxis" |
| | | :yAxis="yAxis2" |
| | | style="height: 40vh;"></Echarts> |
| | |
| | | |
| | | <script> |
| | | import Echarts from "./echarts.vue"; |
| | | import {getRawSupplierCompare} from "@/api/statisticalCharts/dataAnalysis"; |
| | | |
| | | export default { |
| | | name: "DataComparison", |
| | |
| | | type: 'shadow' |
| | | } |
| | | }, |
| | | tooltip1: { |
| | | trigger: 'axis', |
| | | axisPointer: { |
| | | type: 'shadow' |
| | | }, |
| | | formatter: (params) => { |
| | | // params æ¯ä¸ä¸ªæ°ç»ï¼å
å«å½åé¼ æ æ¬åçææç³»åçæ°æ® |
| | | return params.map(param => { |
| | | const value = param.value; // è·åå½åæ°æ®ç¹çå¼ |
| | | const name = param.seriesName; // è·åç³»ååç§° |
| | | return `${name}: ${Math.round(value)}%`; // æ ¼å¼å为ç¾åæ¯å½¢å¼ |
| | | }).join('<br>'); // æ¯ä¸ªç³»åå ä¸è¡ |
| | | } |
| | | }, |
| | | xAxis: [{ |
| | | type: 'category', |
| | | data: ['1', '2', '3', '4', '5'] |
| | |
| | | yAxis2: [{ |
| | | type: 'value', |
| | | min: 0, |
| | | max: 1, |
| | | max: 100, |
| | | axisLabel: { |
| | | formatter: '{value}%' // 卿¯ä¸ªå»åº¦å¼åæ·»å ç¾åæ¯ç¬¦å· |
| | | } |
| | | }], |
| | | echartsSeries2: [ |
| | | { |
| | |
| | | label: { |
| | | show: true, |
| | | position: 'top', |
| | | formatter: (params) => Math.round(params.value * 1000) / 10 + '%' |
| | | formatter: (params) => params.value + '%' |
| | | }, |
| | | data: [], |
| | | }, |
| | |
| | | label: { |
| | | show: true, |
| | | position: 'top', |
| | | formatter: (params) => Math.round(params.value * 1000) / 10 + '%' |
| | | formatter: (params) => params.value + '%' |
| | | }, |
| | | data: [], |
| | | } |
| | |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | getInfo () { |
| | | this.localData = this.comparisonData.localData === null ? ['', '', '', '', '','','', '', ''] : this.comparisonData.localData |
| | | this.localData = this.localData.map((number, index) => index === 7 ? `${Math.round(number * 100)}%` : number) |
| | | this.echartsSeries3[0].data = this.localData.slice(0, 5) |
| | | this.localULC = this.comparisonData.localULC |
| | | this.localLCL = this.comparisonData.localLCL |
| | | this.localAverage = this.comparisonData.localAverage |
| | | this.localRange = this.comparisonData.localRange |
| | | getInfo() { |
| | | const { localData, localULC, localLCL, localAverage, localRange } = this.comparisonData; |
| | | // åå§å localDataï¼ç¡®ä¿æé»è®¤å¼ |
| | | this.localData = localData === null |
| | | ? ['', '', '', '', '', '', '', '', ''] |
| | | : localData.map((number, index) => index === 7 ? `${Math.round(number * 100)}%` : number); |
| | | // æ´æ°å¾è¡¨æ°æ® |
| | | this.echartsSeries3[0].data = this.localData.slice(0, 5); |
| | | this.localULC = localULC; |
| | | this.localLCL = localLCL; |
| | | this.localAverage = localAverage; |
| | | this.localRange = localRange; |
| | | }, |
| | | getInfo1 () { |
| | | this.echartsSeries1[0].data = [] |
| | | this.supplierData = this.comparisonData1.supplierData === null ? ['', '', '', '', '','','', '', ''] : this.comparisonData1.supplierData |
| | | this.localData = this.comparisonData1.localData === null ? ['', '', '', '', '','','', '', ''] : this.comparisonData1.localData |
| | | this.localData = this.localData.map((number, index) => index === 7 ? `${Math.round(number * 100)}%` : number) |
| | | this.echartsSeries3[0].data = this.localData.slice(0, 5) |
| | | this.echartsSeries[0].data = this.supplierData |
| | | this.echartsSeries[1].data = this.localData |
| | | this.absoluteDeviation = this.comparisonData1.absoluteDeviation === null ? ['', '', '', '', '','','', '', ''] : this.comparisonData1.absoluteDeviation |
| | | this.echartsSeries2[1].data = this.absoluteDeviation |
| | | this.absoluteDeviation = this.absoluteDeviation.map(number => `${Math.round(number * 100)}%`) // ç»å¯¹åå·®ç¾åæ¯è½¬æ¢ |
| | | this.average = this.comparisonData1.average === null ? ['', '', '', '', '','','', '', ''] : this.comparisonData1.average |
| | | this.echartsSeries2[0].data = this.average |
| | | this.average = this.average.map(number => `${Math.round(number * 100)}%`) // å¹³åå¼ç¾åæ¯è½¬æ¢ |
| | | this.supplierULC = this.comparisonData1.supplierULC === null ? ['', '', '', '', ''] : this.comparisonData1.supplierULC |
| | | this.echartsSeries1[0].data.push(this.supplierULC[0]) // æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.supplierLCL = this.comparisonData1.supplierLCL === null ? ['', '', '', '', ''] : this.comparisonData1.supplierLCL |
| | | this.echartsSeries1[1].data.push(this.supplierLCL[0]) // æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.supplierAverage = this.comparisonData1.supplierAverage === null ? ['', '', '', '', ''] : this.comparisonData1.supplierAverage |
| | | this.echartsSeries1[2].data.push(this.supplierAverage[0]) // æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.supplierRange = this.comparisonData1.supplierRange === null ? ['', '', '', '', ''] : this.comparisonData1.supplierRange |
| | | this.localULC = this.comparisonData1.localULC |
| | | this.echartsSeries1[0].data.push(this.localULC[0]) // æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.localLCL = this.comparisonData1.localLCL |
| | | this.echartsSeries1[1].data.push(this.localLCL[0]) // æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.localAverage = this.comparisonData1.localAverage |
| | | this.echartsSeries1[2].data.push(this.localAverage[0]) // æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.localRange = this.comparisonData1.localRange |
| | | getInfo1() { |
| | | const { |
| | | supplierData, |
| | | localData, |
| | | absoluteDeviation, |
| | | average, |
| | | supplierULC, |
| | | supplierLCL, |
| | | supplierAverage, |
| | | supplierRange, |
| | | localULC, |
| | | localLCL, |
| | | localAverage, |
| | | localRange, |
| | | } = this.comparisonData1; |
| | | // è¾
å©å½æ°ï¼å¤çç©ºæ°æ®å¹¶è½¬æ¢ç¾åæ¯ |
| | | const processPercentageData = (data, defaultValue = ['', '', '', '', '', '', '', '', '']) => |
| | | data === null ? defaultValue : data.map((number, index) => index === 7 ? `${Math.round(number * 100)}%` : number); |
| | | // è¾
å©å½æ°ï¼å¤ç空æ°å¼åæ°æ® |
| | | const processNumericData = (data, defaultValue = ['', '', '', '', '']) => |
| | | data === null ? defaultValue : data; |
| | | // åå§åæ°æ® |
| | | this.supplierData = processPercentageData(supplierData); |
| | | this.localData = processPercentageData(localData); |
| | | this.absoluteDeviation = processPercentageData(absoluteDeviation).map(number => `${Math.round(number * 100)}%`); |
| | | this.average = processPercentageData(average).map(number => `${Math.round(number * 100)}%`); |
| | | // æ´æ°å¾è¡¨æ°æ® |
| | | this.echartsSeries1[0].data = []; |
| | | this.echartsSeries3[0].data = this.localData.slice(0, 5); |
| | | this.echartsSeries[0].data = this.supplierData; |
| | | this.echartsSeries[1].data = this.localData; |
| | | this.echartsSeries2[1].data = this.comparisonData1.absoluteDeviation.map(value => value * 100); |
| | | this.echartsSeries2[0].data = this.comparisonData1.average.map(value => value * 100); |
| | | // å¤çä¾åºå忬å°çæ åå·®å¯¹æ¯æ°æ® |
| | | this.supplierULC = processNumericData(supplierULC); |
| | | this.supplierLCL = processNumericData(supplierLCL); |
| | | this.supplierAverage = processNumericData(supplierAverage); |
| | | this.supplierRange = processNumericData(supplierRange); |
| | | this.localULC = processNumericData(localULC); |
| | | this.localLCL = processNumericData(localLCL); |
| | | this.localAverage = processNumericData(localAverage); |
| | | this.localRange = processNumericData(localRange); |
| | | // æ´æ°æµéæ°æ®æ åå·®å¯¹æ¯æ±ç¶å¾æ°æ® |
| | | this.echartsSeries1[0].data.push(this.supplierULC[0], this.localULC[0]); |
| | | this.echartsSeries1[1].data.push(this.supplierLCL[0], this.localLCL[0]); |
| | | this.echartsSeries1[2].data.push(this.supplierAverage[0], this.localAverage[0]); |
| | | }, |
| | | submitForm () { |
| | | this.$refs['supplierForm'].validate((valid) => { |
| | |
| | | itemNames: this.selectRow.itemNames, |
| | | supplierDataList: Object.values(this.supplierForm) |
| | | } |
| | | this.$axios.post(this.$api.dataAnalysis.getRawSupplierCompare, params, { |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | }, |
| | | noQs: true |
| | | }).then(res => { |
| | | getRawSupplierCompare(params).then(res => { |
| | | this.comparisonData1 = res.data |
| | | this.getInfo1() |
| | | }) |
| | |
| | | |
| | | <style scoped> |
| | | .title { |
| | | height: 60px; |
| | | line-height: 60px; |
| | | height: 40px; |
| | | line-height: 40px; |
| | | } |
| | | .container { |
| | | width: calc(100% - 20px); |
| | |
| | | deep:true, |
| | | handler(){ |
| | | this.isLoding = false |
| | | console.log(this.isLoding) |
| | | } |
| | | } |
| | | }, |
| | |
| | | onScroll(){}, |
| | | scrollFn() { |
| | | let content = this.$refs.content |
| | | // console.log(22222,content.scrollTop + content.clientHeight+1,content.scrollHeight) |
| | | if (content.scrollTop + content.clientHeight+2 >= content.scrollHeight) { |
| | | // console.log(1111,this.finishLoding) |
| | | if(!this.finishLoding){ |
| | | this.loadMore() |
| | | }else{ |
| | |
| | | <img src="@/assets/logo/ZTTlogo.png" /> |
| | | </div> |
| | | <div class="center-menu"> |
| | | <span class="label">LIMSå®éªå®¤ç®¡çç³»ç»</span> |
| | | <span class="label">è£
å¤LIMSå®éªå®¤ç®¡çç³»ç»</span> |
| | | </div> |
| | | <div class="right-menu"> |
| | | <div class="avatar-wrapper"> |
| | |
| | | |
| | | <el-divider/> |
| | | |
| | | <el-button size="small" type="primary" plain icon="el-icon-document-add" @click="saveSetting">ä¿åé
ç½®</el-button> |
| | | <el-button size="small" plain icon="el-icon-refresh" @click="resetSetting">éç½®é
ç½®</el-button> |
| | | <el-button size="small" type="primary" plain @click="saveSetting">ä¿åé
ç½®</el-button> |
| | | <el-button size="small" plain @click="resetSetting">éç½®é
ç½®</el-button> |
| | | </div> |
| | | </div> |
| | | </el-drawer> |
| | |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | ::v-deep .el-submenu__title i { |
| | | color: #ffffff !important; |
| | | } |
| | | </style> |
| | |
| | | import Vue from "vue"; |
| | | |
| | | import Cookies from "js-cookie"; |
| | | |
| | | import Element from "element-ui"; |
| | | import "./assets/styles/element-variables.scss"; |
| | | |
| | |
| | | Vue.prototype.HaveJson = (val) => { |
| | | return JSON.parse(JSON.stringify(val)); |
| | | }; |
| | | Vue.prototype.javaApi = "http://114.132.189.42:7012"; |
| | | Vue.prototype.javaApi = "http://192.168.21.53:8001/lims"; |
| | | Vue.prototype.checkPermi = checkPermi; |
| | | Vue.prototype.uploadHeader = { |
| | | Authorization: "Bearer " + getToken(), |
| | |
| | | */ |
| | | |
| | | Vue.use(Element, { |
| | | size: Cookies.get("size") || "medium", // set element-ui default size |
| | | size: localStorage.getItem("size") || "medium", // set element-ui default size |
| | | }); |
| | | |
| | | Vue.config.productionTip = false; |
| | |
| | | |
| | | NProgress.configure({ showSpinner: false }) |
| | | |
| | | const whiteList = ['/login', '/register', '/callbacklccpn'] |
| | | const whiteList = ['/login', '/register', '/thirdpartylogin', '/logindemo', '/callbacklccpn'] |
| | | |
| | | const isWhiteList = (path) => { |
| | | return whiteList.some(pattern => isPathMatch(pattern, path)) |
| | |
| | | NProgress.start() |
| | | if (getToken()) { |
| | | to.meta.title && store.dispatch('settings/setTitle', to.meta.title) |
| | | console.log(to.path) |
| | | /* has token*/ |
| | | if (to.path === '/login') { |
| | | next({ path: '/' }) |
| | |
| | | permissions: ["business:order"], |
| | | children: [ |
| | | { |
| | | // åææä¸å |
| | | path: "customsInspection", |
| | | // åææä¸å-è¿è¡ä¸å |
| | | path: "customsInspectionOrder", |
| | | component: () => |
| | | import("@/views/business/materialOrder/customsInspection"), |
| | | name: "CustomsInspection", |
| | | import("@/views/business/materialOrder/customsInspectionOrder"), |
| | | name: "CustomsInspectionOrder", |
| | | meta: { |
| | | title: "åææä¸å详æ
", |
| | | title: "è¿è¡åææä¸å", |
| | | activeMenu: "/business/materialOrder", |
| | | keepAlive: true |
| | | }, |
| | | }, |
| | | { |
| | | // åææä¸å-æ¥ç详æ
|
| | | path: "customsInspectionView", |
| | | component: () => |
| | | import("@/views/business/materialOrder/customsInspectionView"), |
| | | name: "CustomsInspectionView", |
| | | meta: { |
| | | title: "æ¥çåææä¸å详æ
", |
| | | activeMenu: "/business/materialOrder", |
| | | keepAlive: true |
| | | }, |
| | |
| | | path: "copperOrder", |
| | | component: () => import("@/views/business/materialOrder/copperOrder"), |
| | | name: "CopperOrder", |
| | | meta: { title: "éææä¸å", activeMenu: "/business/materialOrder",keepAlive: true }, |
| | | meta: { title: "è¿è¡éææä¸å", activeMenu: "/business/materialOrder",keepAlive: true }, |
| | | }, |
| | | { |
| | | // éææä¸å-æ¥ç详æ
|
| | | path: "copperView", |
| | | component: () => import("@/views/business/materialOrder/copperView"), |
| | | name: "CopperView", |
| | | meta: { title: "æ¥çéææä¸å详æ
", activeMenu: "/business/materialOrder",keepAlive: true }, |
| | | }, |
| | | ], |
| | | }, |
| | |
| | | permissions: ["business:productOrder"], |
| | | children: [ |
| | | { |
| | | // æåä¸å详æ
|
| | | path: "add", |
| | | // æ¥çæåä¸å详æ
|
| | | path: "addView", |
| | | component: () => |
| | | import("@/views/business/productOrder/components/add.vue"), |
| | | name: "Add", |
| | | meta: { title: "æåä¸å详æ
", activeMenu: "/business/productOrder",keepAlive: true }, |
| | | import("@/views/business/productOrder/components/addView.vue"), |
| | | name: "AddView", |
| | | meta: { title: "æ¥çæåä¸å详æ
", activeMenu: "/business/productOrder",keepAlive: true }, |
| | | }, |
| | | { |
| | | // è¿è¡ä¸å-æåä¸å |
| | | path: "addOrder", |
| | | component: () => |
| | | import("@/views/business/productOrder/components/addOrder.vue"), |
| | | name: "AddOrder", |
| | | meta: { title: "è¿è¡æåä¸å", activeMenu: "/business/productOrder",keepAlive: true }, |
| | | }, |
| | | ], |
| | | }, |
| | |
| | | avatar: (state) => state.user.avatar, |
| | | name: (state) => state.user.name, |
| | | nickName: (state) => state.user.nickName, |
| | | nameEn: (state) => state.user.nameEn, |
| | | userName: (state) => state.user.userName, |
| | | userId: (state) => state.user.id, |
| | | introduction: (state) => state.user.introduction, |
| | | roles: (state) => state.user.roles, |
| | |
| | | import Cookies from 'js-cookie' |
| | | |
| | | const state = { |
| | | sidebar: { |
| | | opened: Cookies.get('sidebarStatus') ? !!+Cookies.get('sidebarStatus') : true, |
| | | opened: localStorage.getItem('sidebarStatus') ? !!+localStorage.getItem('sidebarStatus') : true, |
| | | withoutAnimation: false, |
| | | hide: false |
| | | }, |
| | | device: 'desktop', |
| | | size: Cookies.get('size') || 'medium' |
| | | size: localStorage.getItem('size') || 'medium' |
| | | } |
| | | |
| | | const mutations = { |
| | |
| | | state.sidebar.opened = !state.sidebar.opened |
| | | state.sidebar.withoutAnimation = false |
| | | if (state.sidebar.opened) { |
| | | Cookies.set('sidebarStatus', 1) |
| | | localStorage.setItem('sidebarStatus', 1) |
| | | } else { |
| | | Cookies.set('sidebarStatus', 0) |
| | | localStorage.setItem('sidebarStatus', 0) |
| | | } |
| | | }, |
| | | CLOSE_SIDEBAR: (state, withoutAnimation) => { |
| | | Cookies.set('sidebarStatus', 0) |
| | | localStorage.setItem('sidebarStatus', 0) |
| | | state.sidebar.opened = false |
| | | state.sidebar.withoutAnimation = withoutAnimation |
| | | }, |
| | |
| | | }, |
| | | SET_SIZE: (state, size) => { |
| | | state.size = size |
| | | Cookies.set('size', size) |
| | | localStorage.setItem('size', size) |
| | | }, |
| | | SET_SIDEBAR_HIDE: (state, status) => { |
| | | state.sidebar.hide = status |
| | |
| | | name: "", |
| | | avatar: "", |
| | | nickName: "", |
| | | nameEn: "", |
| | | userName: "", |
| | | roles: [], |
| | | permissions: [], |
| | | }, |
| | |
| | | }, |
| | | SET_NICKNAME: (state, nickName) => { |
| | | state.nickName = nickName; |
| | | }, |
| | | SET_NAMEEN: (state, nameEn) => { |
| | | state.nameEn = nameEn; |
| | | }, |
| | | SET_USERNAME: (state, userName) => { |
| | | state.userName = userName; |
| | | }, |
| | | SET_ROLES: (state, roles) => { |
| | | state.roles = roles; |
| | |
| | | commit("SET_NAME", user.userName); |
| | | commit("SET_AVATAR", avatar); |
| | | commit("SET_NICKNAME", user.nickName); |
| | | commit("SET_NAMEEN", user.nameEn); |
| | | commit("SET_USERNAME", user.userName); |
| | | resolve(res); |
| | | }) |
| | | .catch((error) => { |
| | |
| | | } |
| | | |
| | | export function setToken(token) { |
| | | localStorage.setItem(TokenKey, token) |
| | | return localStorage.setItem(TokenKey, token) |
| | | } |
| | | |
| | | export function removeToken() { |
| | | localStorage.removeItem(TokenKey) |
| | | return localStorage.removeItem(TokenKey) |
| | | } |
| | |
| | | return format |
| | | } |
| | | return '' |
| | | } |
| | | |
| | | /** |
| | | * è·åå¹´ææ¥ 26å·+1 |
| | | * @param date |
| | | * @returns {string} |
| | | */ |
| | | export function getYearAndMonthAndDaysZTZB(date = new Date()) { |
| | | let year = date.getFullYear(); |
| | | let month = date.getMonth(); |
| | | let days = date.getDate(); |
| | | |
| | | // 夿æ¯å¦æ¯26å· |
| | | if (days === 26) { |
| | | month++; |
| | | if (month > 11) { |
| | | month = 0; |
| | | year++; |
| | | } |
| | | } |
| | | |
| | | month += 1; |
| | | month = month < 10 ? '0' + month + '-' : month + '-'; |
| | | year = year + '-'; |
| | | days = days < 10 ? '0' + days : days; |
| | | |
| | | return (year + month + days); |
| | | } |
| | |
| | | * åå
¸è¯·æ±ï¼æ¹æ³ç¾å为function(dictMeta: DictMeta): Promise |
| | | */ |
| | | request: (dictMeta) => { |
| | | console.log(`load dict ${dictMeta.type}`) |
| | | return Promise.resolve([]) |
| | | }, |
| | | /** |
| | |
| | | let min = null; |
| | | if (val && val.length > 0) { |
| | | val = val.filter((item) => item != null && item !== ""); |
| | | // console.log(val) |
| | | if (val.length > 0) { |
| | | min = Math.min(...val); |
| | | } |
| | |
| | | fouList.forEach((item) => { |
| | | f = f.replace(new RegExp(item, "g"), ""); |
| | | }); |
| | | // console.log('f',f) |
| | | let arr = f.split(",").filter((item) => { |
| | | return ( |
| | | item && /[a-zA-Z]/.test(item) && item != "undefined" && item != "null" |
| | |
| | | <template> |
| | | <div> |
| | | <div style=" |
| | | display: flex; |
| | | justify-content: flex-end; |
| | | margin-right: 20px; |
| | | margin-bottom: 20px; |
| | | "> |
| | | <div style="display: flex;justify-content: flex-end;margin-bottom: 10px;"> |
| | | <el-button size="small" type="primary" @click="searchList">å·æ°</el-button> |
| | | <el-button icon="el-icon-plus" size="small" type="primary" @click="addOrUpdateStore('add')">æ·»å </el-button> |
| | | <el-button icon="el-icon-download" size="small" @click="importExcel">导åºexcel</el-button> |
| | | </div> |
| | | <div class="table"> |
| | | <limsTable :column="tableColumn" :height="'calc(100vh - 20em)'" :table-data="storageTableData" |
| | | :table-loading="tableLoading" style="padding: 0 10px;margin-bottom: 16px" :page="page" @pagination="pagination"> |
| | | :table-loading="tableLoading" :page="page" @pagination="pagination"> |
| | | </limsTable> |
| | | </div> |
| | | |
| | |
| | | width: 250px; |
| | | height: 100%; |
| | | background: #fff; |
| | | margin-right: 10px; |
| | | border-radius: 16px; |
| | | box-sizing: border-box; |
| | | padding: 10px 16px; |
| | |
| | | background: #fff; |
| | | width: calc(100% - 15em); |
| | | height: 100%; |
| | | border-radius: 16px; |
| | | box-sizing: border-box; |
| | | padding: 10px 16px; |
| | | padding: 0 20px 0 10px; |
| | | } |
| | | .purchase-page { |
| | | display: flex; |
| | |
| | | <el-input v-model="searchForm.supplierName" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getTableData">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="getTableData">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div> |
| | | <el-form :model="entity" ref="entity" size="small" :inline="true"> |
| | | <el-form-item label="人ååç§°"> |
| | | <el-input v-model="entity.name" clearable></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" @click="currentPage= 1,list=[],finishLoding = false,keyMap = {},refreshTable()">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div class="search_box"> |
| | | <div class="search_item"> |
| | | <span class="search_label">人ååç§°</span> |
| | | <el-input v-model="entity.name" clearable @keyup.enter.native="currentPage= 1,list=[],finishLoding = false,keyMap = {},refreshTable()"></el-input> |
| | | </div> |
| | | <div class="search_button"> |
| | | <el-button size="mini" type="primary" @click="currentPage= 1,list=[],finishLoding = false,keyMap = {},refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button @click="refresh" size="mini">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="table" v-loading="loading"> |
| | | <scroll-pagination @load="refreshTable" :finishLoding="finishLoding" :list="list" v-if="list.length>0||loading"> |
| | |
| | | line-height: 20px; |
| | | color: #fff; |
| | | } |
| | | .search_box { |
| | | display: flex; |
| | | } |
| | | .search_item { |
| | | margin-bottom: 18px; |
| | | margin-right: 10px; |
| | | display: flex; |
| | | align-items: center; |
| | | line-height: 32px; |
| | | } |
| | | .search_label { |
| | | width: 88px; |
| | | font-size: 14px; |
| | | font-weight: 700; |
| | | color: #606266; |
| | | } |
| | | .search_button { |
| | | line-height: 30px; |
| | | } |
| | | </style> |
| | |
| | | }, |
| | | // è·åè´è´£äººä¿¡æ¯æ¥å£ |
| | | getUserList() { |
| | | selectUserCondition().then(res => { |
| | | selectUserCondition({type: 2}).then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | |
| | | <el-row style="margin: 15px 0"> |
| | | <el-form> |
| | | <el-row> |
| | | <el-col :span="5"> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å¹è®æ¥æ:"> |
| | | <el-date-picker v-model="trainingForm.openingTime" format="yyyy-MM-dd" :disabled="currentRow.state !== 3" |
| | | placeholder="éæ©æ¥æ" size="small" value-format="yyyy-MM-dd" |
| | |
| | | </el-table> |
| | | </div> |
| | | <el-dialog :visible.sync="selectUserDia" title="éæ©ç¨æ·" width="70%"> |
| | | <div class="search" style="margin-bottom: 9px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">ç¨æ·åï¼</div> |
| | | <div class="search_input"> |
| | | <div> |
| | | <el-form :model="addUserTableInfo" ref="addUserTableInfo" size="small" :inline="true" label-position="left" label-width="100"> |
| | | <el-form-item label="ç¨æ·å" prop="name"> |
| | | <el-input |
| | | v-model="addUserTableInfo.name" |
| | | clearable |
| | | placeholder="请è¾å
¥" |
| | | size="small" |
| | | @keyup.enter.native="selectUserList" |
| | | @input="selectUserList" |
| | | ></el-input> |
| | | </div> |
| | | </div> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div v-if="selectUserDia" class="body" style="height: 60vh;"> |
| | | <lims-table :tableData="tableData1" :column="column1" |
| | | :isSelection="true" :handleSelectionChange="selectMethod" |
| | | @pagination="pagination1" :height="'calc(100vh - 290px)'" |
| | | :page="page1" :tableLoading="tableLoading1"></lims-table> |
| | | height="500" :tableLoading="tableLoading1"></lims-table> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="selectUserDia = false">å æ¶</el-button> |
| | |
| | | import { |
| | | newPersonnelAddedToTrainingRecords, |
| | | outOfFocusPreservation, trainingAndAssessmentRecordsAdded, trainingAndAssessmentRecordsEvaluate, |
| | | trainingAndAssessmentRecordsPage |
| | | trainingAndAssessmentRecordsPage, deleteTrainingAndAssessmentRecords |
| | | } from "@/api/cnas/personal/personalTraining"; |
| | | |
| | | export default { |
| | |
| | | if (params == 0) { |
| | | return 'å¯ç¨' |
| | | } else { |
| | | return '' |
| | | return 'åç¨' |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | |
| | | }, |
| | | addUserTableInfo: { |
| | | name: null, |
| | | type: 2 |
| | | }, |
| | | multipleSelection: [], |
| | | userList: [], |
| | |
| | | addPerson() { |
| | | this.isSelectedList = this.trainingTableData.map(item => item.userId) |
| | | this.selectUserDia = true; |
| | | this.selectUserList() |
| | | }, |
| | | selectUserList () { |
| | | this.tableLoading1 = true |
| | | selectUserCondition({...this.addUserTableInfo}).then(res => { |
| | | this.tableData1 = res.data.records |
| | | this.page1.total = res.data.total |
| | | this.tableLoading1 = false |
| | | this.tableData1 = res.data |
| | | }).catch(err => { |
| | | this.tableLoading1 = false |
| | | }) |
| | | }, |
| | | pagination1 (page) { |
| | | this.page1.size = page.limit |
| | | this.selectUserList() |
| | | }, |
| | | // è¡¨æ ¼éæ©æ¹æ³ |
| | | selectMethod(val) { |
| | |
| | | }, |
| | | batchDelete() { |
| | | if (this.multipleSelection.length > 0) { |
| | | let ids = this.multipleSelection.map(item => item.trainingRecordId) |
| | | let ids = this.multipleSelection.map(item => item.trainingRecordId).join(',') |
| | | this.$confirm('æ¯å¦ç¡®è®¤å é¤æéæ©çæ°æ®?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | let formData = new FormData() |
| | | formData.append('ids', ids) |
| | | deleteTrainingAndAssessmentRecords(formData).then(res => { |
| | | deleteTrainingAndAssessmentRecords({ids: ids}).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('å 餿å'); |
| | | this.getInfo() |
| | |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | .el-divider { |
| | | margin: 0 1em 1em 0; |
| | | } |
| | | |
| | | .form__input_label { |
| | | width: 90px; |
| | | margin-right: 6px; |
| | | color: #606266; |
| | | } |
| | | |
| | | .form__input_label2 { |
| | | width: 210px; |
| | | margin-right: 6px; |
| | | color: #606266; |
| | | } |
| | | .search_thing { |
| | | display: flex; |
| | | align-items: center |
| | | } |
| | | .search_label { |
| | | width: 120px; |
| | | } |
| | | .pagination { |
| | | display: flex; |
| | | justify-content: space-between |
| | | } |
| | | |
| | | .items_center { |
| | | float: left; |
| | |
| | | width: 50%; |
| | | float: right; |
| | | margin-bottom: 1em; |
| | | } |
| | | |
| | | .search { |
| | | width: 180px; |
| | | padding: 0 16px; |
| | | } |
| | | </style> |
| | |
| | | * @desc è·åç¨æ·ä¿¡æ¯ |
| | | */ |
| | | async getUserList() { |
| | | selectUserCondition().then((res) => { |
| | | selectUserCondition({type: 2}).then((res) => { |
| | | this.userList = res.data; |
| | | }) |
| | | }, |
| | |
| | | * @desc è·åç¨æ·ä¿¡æ¯ |
| | | */ |
| | | async getUserList() { |
| | | selectUserCondition().then((res) => { |
| | | selectUserCondition({type: 2}).then((res) => { |
| | | this.userList = res.data; |
| | | }) |
| | | }, |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | >>>.el-table__body-wrapper::-webkit-scrollbar { |
| | | height: 14px; |
| | | /* 设置æ»å¨æ¡å®½åº¦ */ |
| | | } |
| | | .node_i { |
| | | color: orange; |
| | | font-size: 18px; |
| | |
| | | <!-- å²ä½èè´£ --> |
| | | <template> |
| | | <div class="view"> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form ref="page" size="small" :inline="true"> |
| | | <el-form-item label="åå·¥"> |
| | | <el-input v-model="userName" clearable placeholder="请è¾å
¥åå·¥" size="small" style="width: 20vh;"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 50px;font-size: 14px;font-weight: 700;color: #606266;">åå·¥</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="userName" |
| | | @keyup.enter.native="refreshTable"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="refreshTable">æ¥è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="addPost">æ°å¢</el-button> |
| | | <!-- <el-button size="small" type="primary">导åºexcel</el-button>--> |
| | | </div> |
| | |
| | | }, |
| | | // è·åè´è´£äººä¿¡æ¯æ¥å£ |
| | | getUserList() { |
| | | selectUserCondition().then(res => { |
| | | selectUserCondition({type: 2}).then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | |
| | | <!-- 人åè½å --> |
| | | <template> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form ref="page" size="small" :inline="true"> |
| | | <el-form-item label="å§å"> |
| | | <el-input v-model="userName" placeholder="请è¾å
¥å§å" size="small" clearable></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" type="primary" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 48px;font-size: 14px;font-weight: 700;color: #606266;">å§å</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="userName" |
| | | @keyup.enter.native="refreshTable"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button v-if="!isDepartment" size="small" type="primary" @click="addAppointPost('add')">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-col :span="12"> |
| | | <el-form-item prop="confirmOperatingPersonnelId" label="确认人ï¼"> |
| | | <el-select v-model="form.confirmOperatingPersonnelId" clearable :disabled="operationType === 'view' || operationType === 'confirm'" |
| | | filterable size="small" style="width: 50%;"> |
| | | filterable size="small"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item prop="confirmDate" label="确认æ¶é´ï¼"> |
| | | <el-date-picker v-model="form.confirmDate" |
| | | format="yyyy-MM-dd" |
| | | :disabled="operationType === 'view' || operationType === 'confirm'" |
| | | placeholder="éæ©æ¥æ" |
| | | size="small" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | type="date"></el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-form> |
| | |
| | | { |
| | | label: 'å²ä½', |
| | | prop: 'postName', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'å§å', |
| | | prop: 'userName', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'å¦å', |
| | | prop: 'academicDegree', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'ä¸ä¸', |
| | | prop: 'major', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'èç§°', |
| | | prop: 'professionalTitle', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | dataType: 'slot', |
| | | label: 'å²ä½èè´£', |
| | | prop: 'jobResponsibilities', |
| | | minWidth: '200px', |
| | | width: '400', |
| | | slot: 'jobResponsibilities' |
| | | }, { |
| | | dataType: 'tag', |
| | | label: '综åè¯ä»·', |
| | | minWidth: '140px', |
| | | width: '140px', |
| | | prop: 'comprehensiveAssessment', |
| | | formatData: (params) => { |
| | | if (params == 'Qualified this position') { |
| | |
| | | }, { |
| | | label: '确认人', |
| | | prop: 'confirmOperatingPersonnelName', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'ç¡®è®¤æ¥æ', |
| | | prop: 'confirmDate', |
| | | minWidth: '160' |
| | | width: '160' |
| | | }, { |
| | | dataType: 'action', |
| | | minWidth: '220', |
| | | label: 'æä½', |
| | | fixed: 'right', |
| | | operation: [ |
| | |
| | | responsibleOptions: [], |
| | | rules: { |
| | | confirmOperatingPersonnelId: [{ required: true, message: 'è¯·éæ©ç¡®è®¤äºº', trigger: 'change' }], |
| | | confirmDate: [{ required: true, message: 'è¯·éæ©ç¡®è®¤æ¶é´', trigger: 'change' }], |
| | | userId: [{ required: true, message: 'è¯·éæ©äººå', trigger: 'change' }], |
| | | academicDegree: [{ required: true, message: '请è¾å
¥å¦åæ¥æ ¸ç»æ', trigger: 'blur' }], |
| | | academicConformNot: [{ required: true, message: 'è¯·éæ©å¦å符åä¸å¦', trigger: 'change' }], |
| | |
| | | this.dialogVisible = false; |
| | | }, |
| | | getUserList(){ |
| | | selectUserCondition().then(res => { |
| | | selectUserCondition({type: 2}).then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | >>>.el-table__body-wrapper::-webkit-scrollbar { |
| | | height: 12px; |
| | | /* 设置æ»å¨æ¡å®½åº¦ */ |
| | | } |
| | | |
| | | >>>.el-form-item { |
| | | margin-bottom: 3px; |
| | | } |
| | |
| | | <template> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="entity" ref="entity" size="small" :inline="true"> |
| | | <el-form-item label="人ååç§°"> |
| | | <el-input v-model="entity.name" clearable></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" style="margin-left: 10px" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">人ååç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.name" |
| | | @keyup.enter.native="refreshTable"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleDown">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="openSelectUserDia">æ°å»º</el-button> |
| | | </div> |
| | |
| | | </div> |
| | | <div v-if="selectUserDia" class="body" style="height: 60vh;"> |
| | | <lims-table :tableData="tableData1" :column="column1" :isSelection="true" :handleSelectionChange="selectMethod" |
| | | height="560" :tableLoading="tableLoading1"></lims-table> |
| | | height="520" :tableLoading="tableLoading1"></lims-table> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="selectUserDia = false">å æ¶</el-button> |
| | |
| | | <div class="title"> |
| | | <span style="font-weight: bold">年度计å</span> |
| | | </div> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="page" ref="page" size="small" :inline="true"> |
| | | <el-form-item label="ç¼å¶äºº"> |
| | | <el-input v-model="page.compilerName" clearable></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" type="primary" @click="getYearPlanList(departId)">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">ç¼å¶äºº</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="page.compilerName" |
| | | @keyup.enter.native="getYearPlanList(departId)"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="getYearPlanList(departId)">æ¥è¯¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="uploadDia = true, getUserList()">导å
¥</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | <div class="title"> |
| | | <span style="font-weight: bold">年度计åæç»</span> |
| | | </div> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="inDetailForm" ref="inDetailForm" size="small" :inline="true"> |
| | | <el-form-item label="å¹è®è®²å¸"> |
| | | <el-input v-model="inDetailForm.trainingLecturerName" class="search" clearable placeholder="请è¾å
¥" |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="å¹è®æ¥æ"> |
| | | <el-date-picker v-model="inDetailForm.trainingDate" clearable format="yyyy-MM-dd" placeholder="éæ©æ¥æ" |
| | | size="small" type="date" value-format="yyyy-MM-dd"></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" type="primary" @click="searchTable">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">å¹è®è®²å¸</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="inDetailForm.trainingLecturerName" |
| | | @keyup.enter.native="searchTable"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="mini" type="primary" @click="searchTable">æ¥è¯¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button v-if="isDepartment && currentChangeRow && isOperation" size="small" |
| | | @click="batchDelete">æ¹éå é¤</el-button> |
| | | @click="batchDelete">æ¹éå é¤</el-button> |
| | | <el-button v-if="isDepartment && currentChangeRow && isOperation" size="small" type="primary" |
| | | @click="addTrainingPlan('add')">æ°å¢</el-button> |
| | | @click="addTrainingPlan('add')">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="inDetailPlanTableData" :column="inDetailPlanColumn" |
| | |
| | | <!-- 奿©è®°å½ --> |
| | | <template> |
| | | <div> |
| | | <div class="view"> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="search" ref="page" size="small" :inline="true"> |
| | | <el-form-item label="å§å"> |
| | | <el-input v-model="search.userName" clearable placeholder="请è¾å
¥å
³é®å" size="small" |
| | | style="width: 20vh;"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="奿©æ¥æ"> |
| | | <el-date-picker v-model="search.searchTimeList" :picker-options="pickerOptions" align="right" clearable |
| | | end-placeholder="ç»ææ¥æ" format="yyyy-MM-dd" range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" |
| | | style="width: 100%" type="daterange" unlink-panels value-format="yyyy-MM-dd 00:00:00"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" type="primary" @click="getPersonnelTraining(departId)">æ¥è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleDown">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="addRow">æ°å¢</el-button> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 48px;font-size: 14px;font-weight: 700;color: #606266;">å§å</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="search.userName" |
| | | @keyup.enter.native="getPersonnelTraining(departId)"></el-input> |
| | | </div> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">奿©æ¥æ</span> |
| | | <el-date-picker v-model="search.searchTimeList" :picker-options="pickerOptions" align="right" clearable |
| | | @change="getPersonnelTraining(departId)" |
| | | end-placeholder="ç»ææ¥æ" format="yyyy-MM-dd" range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" |
| | | style="width: 100%" type="daterange" unlink-panels value-format="yyyy-MM-dd 00:00:00"> |
| | | </el-date-picker> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="mini" type="primary" @click="getPersonnelTraining(departId)">æ¥è¯¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleDown">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="addRow">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | |
| | | }, |
| | | // è·åè´è´£äººä¿¡æ¯æ¥å£ |
| | | getUserList() { |
| | | selectUserCondition().then(res => { |
| | | selectUserCondition({type: 2}).then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | |
| | | } |
| | | }; |
| | | </script> |
| | | <style scoped> |
| | | .dateTime >>>.el-form-item__content { |
| | | width: 260px; |
| | | } |
| | | </style> |
| | |
| | | <div class="title"> |
| | | <span style="font-weight: bold">年度计å</span> |
| | | </div> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="trainingPagination" ref="trainingPagination" size="small" :inline="true"> |
| | | <el-form-item label="å§å"> |
| | | <el-input v-model="trainingPagination.userName" class="search" clearable placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 48px;font-size: 14px;font-weight: 700;color: #606266;">å§å</span> |
| | | <el-input v-model="trainingPagination.userName" class="search" |
| | | @keyup.enter.native="getPersonnelTraining(departId)" |
| | | clearable placeholder="请è¾å
¥" size="small"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="getPersonnelTraining(departId)">æ¥è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="trainingTableData" :column="trainingColumn" |
| | | ref="trainingTableData" |
| | |
| | | clearable |
| | | format="yyyy" |
| | | placeholder="鿩年" |
| | | @change="queryPersonnelDetailsPage(currentChangeRow.userId)" |
| | | size="small" |
| | | type="year" |
| | | value-format="yyyy"> |
| | |
| | | label: 'å¹è®å
容', |
| | | prop: 'trainingContent' |
| | | }, { |
| | | label: 'å¹è®è¯¾æ¶', |
| | | prop: 'educationBackground' |
| | | }, { |
| | | label: '课æ¶', |
| | | prop: 'classHour' |
| | | }, { |
| | |
| | | this.getPersonnelTraining(this.departId); |
| | | }, |
| | | methods: { |
| | | // exportExcel() { |
| | | // this.outLoading = true; |
| | | // const name = this.isDepartment ? 'departmentId' : 'userId'; |
| | | // this.$axios.get(this.$api.personal.personTrackRecordExport + `&${name}=` + this.departId, { responseType: 'blob' }).then(res => { |
| | | // this.outLoading = false; |
| | | // this.$message.success('å¯¼åºæå'); |
| | | // const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | // const url = URL.createObjectURL(blob); |
| | | // const link = document.createElement('a'); |
| | | // link.href = url; |
| | | // link.download = 'å¹è®è®°å½.xlsx'; |
| | | // link.click(); |
| | | // }).catch(err => { |
| | | // this.outLoading = false; |
| | | // }) |
| | | // }, |
| | | // æ¥è¯¢ |
| | | refreshTable() { |
| | | this.getPersonnelTraining(this.departId); |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="text-align: right; margin-bottom: 20px"> |
| | | <el-button size="small" type="primary" @click="goAdd">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="text-align: right; margin-bottom: 10px"> |
| | | <el-button size="small" type="primary" @click="goAdd">æ°å¢</el-button> |
| | | </div> |
| | | <div class="table"> |
| | | <el-table v-loading="tableListLoading" :data="tableList" |
| | | height="630" style="width: 100%" border :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }"> |
| | | <el-table-column align="center" label="åºå·" type="index" width="60"></el-table-column> |
| | | <el-table-column label="è¯æ ·åç§°" prop="sampleName" show-overflow-tooltip width="120"></el-table-column> |
| | | <el-table-column label="å§æç¼å·" prop="entrustCode" show-overflow-tooltip width="120"></el-table-column> |
| | | <el-table-column label="å§ææ¶é´" prop="commissionDate" width="120"></el-table-column> |
| | | <el-table-column label="åå·" prop="modelNo"></el-table-column> |
| | | <el-table-column label="å§æåä½" prop="commissionUnit" show-overflow-tooltip width="120"></el-table-column> |
| | | <el-table-column label="ç产åä½" prop="production" show-overflow-tooltip width="120"></el-table-column> |
| | | height="630" border :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }"> |
| | | <el-table-column align="center" label="åºå·" type="index"></el-table-column> |
| | | <el-table-column label="è¯æ ·åç§°" prop="sampleName" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="å§æç¼å·" prop="entrustCode" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="å§ææ¶é´" prop="commissionDate" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="åå·" prop="modelNo" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="å§æåä½" prop="commissionUnit" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="ç产åä½" prop="production" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="å§æäºº" prop="commissionUser"></el-table-column> |
| | | <el-table-column label="æ ·åæ°é" prop="quantity"></el-table-column> |
| | | <el-table-column label="æ ·åç¶æ" prop="sampleStatus"></el-table-column> |
| | |
| | | <span v-if="scope.row.isLeave === 0">å¦</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ ·åå¤çæ¹å¼" prop="processing"> |
| | | <el-table-column label="æ ·åå¤çæ¹å¼" prop="processing" width="150"> |
| | | <template slot-scope="scope"> |
| | | <span v-if="scope.row.processing === 1">å®éªå®¤å¤ç</span> |
| | | <span v-if="scope.row.processing === 0">å§æåä½åå</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æä½" width="240" fixed="right"> |
| | | <el-table-column align="center" label="æä½" width="240"> |
| | | <template slot-scope="scope"> |
| | | <el-button size="mini" type="text" @click="goUpdate(scope.row)">ç¼è¾</el-button> |
| | | <el-button size="mini" type="text" @click="handleLook(scope.row)">æ¥ç</el-button> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div style="display: flex;justify-content: space-between;align-items: flex-start"> |
| | | <el-form :model="queryParams0" ref="queryParams0" size="small" :inline="true"> |
| | | <el-form-item label="å¹´æ" prop="month"> |
| | | <el-date-picker v-model="queryParams0.month" type="month" placeholder="éæ©æ" format="yyyy-MM" |
| | | value-format="yyyy-MM" size="small" @change="refreshTable()"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <el-button size="small" type="primary" @click="handleAdd0">æ°å¢</el-button> |
| | | </div> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData0" :column="column0" :tableLoading="tableLoading" |
| | | key="tableData0" :height="'calc(100vh - 240px)'" :page="page0" @pagination="pagination0"></lims-table> |
| | | </div> |
| | | <el-dialog title="详æ
" :visible.sync="editDialogVisible" width="70%"> |
| | | <el-button size="small" type="primary" @click="handleAdd('add')" style="margin-bottom: 10px">æ°å¢</el-button> |
| | | <lims-table :tableData="tableData" :column="column" :tableLoading="tableLoading" |
| | | key="tableData" :height="'calc(100vh - 290px)'"> |
| | | </lims-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="editDialogVisible = false">åæ¶</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!-- æ°å¢æ ·å --> |
| | | <el-dialog title="æ°å¢" :visible.sync="addDialogVisible" width="400px" @close="closeAddDialogVisible"> |
| | | <el-form ref="addInfo" :model="addInfo" :rules="rules" label-width="120px"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="æ ·ååç§°" prop="sampleName"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.sampleName"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="æ ·åç¼å·" prop="sampleCode"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.sampleCode"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="便 ·åä½" prop="sampleSupplier"> |
| | | <el-select v-model="addInfo.sampleSupplier" size="small"> |
| | | <el-option :label="item.company" :value="item.company" v-for="(item, index) in customPageList" |
| | | :key="item.id"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="æ°é" prop="num"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.num"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="å¤çæ¹å¼" prop="dealMethod"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.dealMethod"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="æ¶é´" prop="dealTime"> |
| | | <el-date-picker v-model="addInfo.dealTime" type="date" size="small" placeholder="éæ©æ¥æ" format="yyyy-MM-dd" |
| | | value-format="yyyy-MM-dd" style="width: 100%;"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeAddDialogVisible">å æ¶</el-button> |
| | | <el-button type="primary" @click="submitAdd" :loading="addLoading">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!-- æ°å¢åå² --> |
| | | <el-dialog title="æ°å¢" :visible.sync="addDialogVisibleDeal" width="400px" @close="closeDiaDeal"> |
| | | <el-form ref="addInfoDeal" :model="addInfoDeal" :rules="rulesDeal" label-width="80px"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="æä»½" prop="month"> |
| | | <el-date-picker v-model="addInfoDeal.month" type="month" size="small" placeholder="éæ©æä»½" format="yyyy-MM" |
| | | value-format="yyyy-MM" style="width: 100%;"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeDiaDeal">å æ¶</el-button> |
| | | <el-button type="primary" @click="submitAddDeal" :loading="addLoading">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!-- 详æ
/ä¸è½½/å®¡æ ¸/æ¹å --> |
| | | <el-dialog :title="title0" :visible.sync="lookDialogVisible" width="400px" :class="{ downPdf: title0 == 'ä¸è½½' }" |
| | | :modal="title0 != 'ä¸è½½'" top="5vh"> |
| | | <span>æ¯å¦éè¿{{title0}}ï¼</span> |
| | | <span slot="footer" class="dialog-footer" v-if="title0 == 'å®¡æ ¸' || title0 == 'æ¹å'"> |
| | | <el-button @click="submitCheck('ä¸éè¿')" :loading="noCheckLoading">ä¸éè¿</el-button> |
| | | <el-button type="primary" @click="submitCheck('éè¿')" :loading="checkLoading">é è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import filePreview from "@/components/Preview/filePreview.vue"; |
| | | import { selectCustomPageList } from "@/api/system/customer"; |
| | | import { |
| | | doProcessDeal, |
| | | addProcessDeal, |
| | | submitProcessTotaldeal, |
| | | checkProcessTotaldeal, |
| | | ratifyProcessTotaldeal, |
| | | delProcessDeal, |
| | | pageProcessTotaldeal, getProcessDeal, addProcessTotaldeal, |
| | | exportProcessTotaldeal |
| | | } from "@/api/cnas/process/sampleDisposal"; |
| | | export default { |
| | | name: 'SampleDisposal', |
| | | components: { |
| | | limsTable, |
| | | filePreview, |
| | | }, |
| | | data() { |
| | | return { |
| | | title: 'æ°å¢', |
| | | addDialogVisible: false, |
| | | addLoading: false, |
| | | outLoading: false, |
| | | editDialogVisible: false, |
| | | queryParams: {}, |
| | | submitState: '', |
| | | lookDialogVisible: false, |
| | | title0: 'æ¥ç', |
| | | noCheckLoading: false, |
| | | checkLoading: false, |
| | | // åå²å表 |
| | | addInfo: {},//æ°å¢æ ·å |
| | | addInfoDeal: { |
| | | month: '' |
| | | },//æ°å¢æ ·å |
| | | addDialogVisibleDeal: false, |
| | | rules: { |
| | | sampleName: [{ required: true, message: 'è¯·å¡«åæ ·ååç§°', trigger: 'blur' }], |
| | | sampleCode: [{ required: true, message: 'è¯·å¡«åæ ·åç¼å·', trigger: 'blur' }], |
| | | sampleSupplier: [{ required: true, message: 'è¯·éæ©ä¾æ ·åä½', trigger: 'change' }], |
| | | num: [{ required: true, message: 'è¯·å¡«åæ°é', trigger: 'blur' }], |
| | | dealMethod: [{ required: true, message: '请填åå¤çæ¹å¼', trigger: 'blur' }], |
| | | dealTime: [{ required: true, message: 'è¯·éæ©æ¶é´', trigger: 'change' }], |
| | | }, |
| | | rulesDeal: { |
| | | month: [{ required: true, message: 'è¯·éæ©æä»½', trigger: 'change' }], |
| | | }, |
| | | customPageList: [], |
| | | currentInfo: { |
| | | arr: [] |
| | | },//æ¥çç详æ
|
| | | outPower: false, |
| | | addPower: false, |
| | | tableData: [], |
| | | column: [ |
| | | { label: "æ ·ååç§°", prop: "sampleName" }, |
| | | { label: "æ ·åç¼å·", prop: "sampleCode" }, |
| | | { label: "便 ·åä½", prop: "sampleSupplier" }, |
| | | { label: "æ°é", prop: "num" }, |
| | | { label: "å¤çæ¹å¼", prop: "dealMethod" }, |
| | | { label: "æ¶é´", prop: "dealTime" }, |
| | | { |
| | | dataType: "action", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | | name: "ç¼è¾", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleAdd('edit',row); |
| | | }, |
| | | disabled: (row) => { |
| | | return this.submitState === 'å·²æäº¤' |
| | | } |
| | | }, |
| | | { |
| | | name: "å é¤", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleDelete(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return this.submitState === 'å·²æäº¤' |
| | | } |
| | | }, |
| | | ], |
| | | }, |
| | | ], |
| | | tableLoading: false, |
| | | queryParams0: {}, |
| | | tableData0: [], |
| | | column0: [ |
| | | { label: "æä»½", prop: "month" }, |
| | | { label: "æäº¤äºº", prop: "submitUserName" }, |
| | | { |
| | | dataType: 'tag', |
| | | label: 'æäº¤ç¶æ', |
| | | prop: 'submitState', |
| | | formatData: (params) => { |
| | | return params |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 'å¾
æäº¤') { |
| | | return 'danger'; |
| | | } else if (params === 'å·²æäº¤') { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | }, |
| | | { label: "å®¡æ ¸äºº", prop: "examineUserName" }, |
| | | { |
| | | dataType: 'tag', |
| | | label: 'å®¡æ ¸ç¶æ', |
| | | prop: 'examineState', |
| | | formatData: (params) => { |
| | | return params |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 'ä¸éè¿') { |
| | | return 'danger'; |
| | | } else if (params === 'éè¿') { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | }, |
| | | { label: "æ¹å人", prop: "ratifyUserName" }, |
| | | { |
| | | dataType: 'tag', |
| | | label: 'æ¹åç¶æ', |
| | | prop: 'ratifyState', |
| | | formatData: (params) => { |
| | | return params |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 'ä¸éè¿') { |
| | | return 'danger'; |
| | | } else if (params === 'éè¿') { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | }, |
| | | { |
| | | dataType: "action", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | | name: "æ¥ç", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleLook(row); |
| | | }, |
| | | }, |
| | | { |
| | | name: "ä¸è½½", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleDown0(row); |
| | | } |
| | | }, |
| | | { |
| | | name: "æäº¤", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleSubmit(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return !!row.submitState && row.submitState != 'å¾
æäº¤' |
| | | } |
| | | }, |
| | | { |
| | | name: "å®¡æ ¸", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleCheck(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return row.examineState == 'éè¿' || row.submitState == 'å¾
æäº¤' |
| | | } |
| | | }, |
| | | { |
| | | name: "æ¹å", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleApproval(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return row.ratifyState == 'éè¿' || row.submitState == 'å¾
æäº¤' |
| | | } |
| | | }, |
| | | ], |
| | | }, |
| | | ], |
| | | page0: { |
| | | total: 0, |
| | | size: 20, |
| | | current: 1, |
| | | }, |
| | | operationType: '' |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.getList0() |
| | | }, |
| | | methods: { |
| | | // è·åéæ ·åä½å表 |
| | | getCustomPageList() { |
| | | selectCustomPageList({ |
| | | current: -1, |
| | | size: -1 |
| | | }).then(res => { |
| | | this.customPageList = res.data.records |
| | | }).catch(err => { }); |
| | | }, |
| | | handleDown() { }, |
| | | refresh() { |
| | | this.queryParams0 = {}; |
| | | this.page0.current = 1; |
| | | this.getList0(); |
| | | }, |
| | | refreshTable() { |
| | | this.page0.current = 1; |
| | | this.getList0(); |
| | | }, |
| | | // æ¥è¯¢å
¨é¨è®°å½ |
| | | getList0() { |
| | | this.tableLoading = true; |
| | | let param = { ...this.queryParams0, ...this.page0 }; |
| | | delete param.total; |
| | | pageProcessTotaldeal({ ...param }) |
| | | .then((res) => { |
| | | this.tableLoading = false; |
| | | if (res.code === 200) { |
| | | this.tableData0 = res.data.records; |
| | | this.page0.total = res.data.total; |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | this.tableLoading = false; |
| | | }); |
| | | }, |
| | | pagination0({ page, limit }) { |
| | | this.page0.current = page; |
| | | this.page0.size = limit; |
| | | this.getList0(); |
| | | }, |
| | | // æå¼æ°å¢åå²çé¢ |
| | | handleAdd0() { |
| | | this.addDialogVisibleDeal = true |
| | | this.addInfoDeal.month = '' |
| | | }, |
| | | closeAddDialogVisible() { |
| | | this.$refs['addInfo'].resetFields(); |
| | | this.addDialogVisible = false |
| | | }, |
| | | // æäº¤æ°å¢-åå² |
| | | submitAddDeal () { |
| | | this.$refs.addInfoDeal.validate(valid => { |
| | | if (valid) { |
| | | // æ°å¢ |
| | | this.addLoading = true |
| | | addProcessTotaldeal({ |
| | | ...this.addInfoDeal |
| | | }).then(res => { |
| | | this.addLoading = false |
| | | this.addDialogVisibleDeal = false |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'æ°å¢æå!' |
| | | }); |
| | | this.getList0() |
| | | }).catch(err => { |
| | | this.addLoading = false |
| | | }); |
| | | } |
| | | }) |
| | | }, |
| | | closeDiaDeal() { |
| | | this.$refs['addInfoDeal'].resetFields(); |
| | | this.addDialogVisibleDeal = false |
| | | }, |
| | | // æäº¤ |
| | | handleSubmit(row) { |
| | | this.$confirm('æ¯å¦æäº¤ ' + row.month + ' æä»½çæ°æ®', 'æäº¤', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | submitProcessTotaldeal({ |
| | | id: row.id |
| | | }).then(res => { |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'æäº¤æå!' |
| | | }); |
| | | this.refreshTable() |
| | | }).catch(err => { }); |
| | | }) |
| | | }, |
| | | // æ¥ç |
| | | handleLook(row) { |
| | | this.queryParams.id = row.id |
| | | this.submitState = row.submitState |
| | | this.$nextTick(() => { |
| | | this.editDialogVisible = true |
| | | this.getList(); |
| | | }) |
| | | }, |
| | | getList() { |
| | | this.tableLoading = true; |
| | | let param = { ...this.queryParams }; |
| | | getProcessDeal({ ...param }).then((res) => { |
| | | this.tableLoading = false; |
| | | if (res.code === 200) { |
| | | this.tableData = res.data; |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | this.tableLoading = false; |
| | | }); |
| | | }, |
| | | // æå¼æ°å¢è¯¦æ
å¼¹æ¡ |
| | | handleAdd(type, row) { |
| | | this.addDialogVisible = true |
| | | this.getCustomPageList() |
| | | this.operationType = type |
| | | if (row) { |
| | | this.addInfo = {...row} |
| | | } |
| | | }, |
| | | // æäº¤-详æ
|
| | | submitAdd() { |
| | | this.$refs.addInfo.validate(valid => { |
| | | if (valid) { |
| | | this.addLoading = true |
| | | addProcessDeal({ |
| | | totaldealId: this.queryParams.id, |
| | | ...this.addInfo |
| | | }).then(res => { |
| | | this.addLoading = false |
| | | this.addDialogVisible = false |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'æ°å¢æå!' |
| | | }); |
| | | this.getList() |
| | | }).catch(err => { |
| | | this.addLoading = false |
| | | }); |
| | | } |
| | | }) |
| | | }, |
| | | // æäº¤ä¿®æ¹è¯¦æ
|
| | | handleEdit() { |
| | | if (type === 'submit') { |
| | | doProcessDeal({ |
| | | id: row.id, |
| | | ...row |
| | | }).then(res => { |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'ç¼è¾æå!' |
| | | }); |
| | | this.getList(); |
| | | }).catch(err => { }); |
| | | } |
| | | }, |
| | | // å®¡æ ¸ |
| | | handleCheck(row) { |
| | | this.title0 = 'å®¡æ ¸' |
| | | this.lookDialogVisible = true |
| | | this.currentInfo = row |
| | | this.queryParams.id = row.id |
| | | }, |
| | | // æ¹å |
| | | handleApproval(row) { |
| | | this.title0 = 'æ¹å' |
| | | this.lookDialogVisible = true |
| | | this.currentInfo = row |
| | | this.queryParams.id = row.id |
| | | }, |
| | | // æäº¤å®¡æ ¸/æ¹å |
| | | submitCheck(state) { |
| | | if (state == 'éè¿') { |
| | | this.checkLoading = true |
| | | } else { |
| | | this.noCheckLoading = true |
| | | } |
| | | if (this.title0 == 'å®¡æ ¸') { |
| | | checkProcessTotaldeal({ |
| | | id: this.currentInfo.id, |
| | | state: state |
| | | }).then(res => { |
| | | this.checkLoading = false |
| | | this.noCheckLoading = false |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'æä½æå!' |
| | | }); |
| | | this.refreshTable() |
| | | this.lookDialogVisible = false |
| | | }).catch(err => { }); |
| | | } else if (this.title0 == 'æ¹å') { |
| | | ratifyProcessTotaldeal({ |
| | | id: this.currentInfo.id, |
| | | state: state |
| | | }).then(res => { |
| | | this.checkLoading = false |
| | | this.noCheckLoading = false |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'æä½æå!' |
| | | }); |
| | | this.refreshTable() |
| | | this.lookDialogVisible = false |
| | | }).catch(err => { }); |
| | | } |
| | | }, |
| | | // 导åºè¯¦æ
|
| | | handleDown0(row) { |
| | | exportProcessTotaldeal({ id: row.id }).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/msword' }); |
| | | this.$download.saveAs(blob, 'æ ·åå¤ç' + '.docx'); |
| | | }) |
| | | }, |
| | | handleDelete(row) { |
| | | this.$confirm("æ¯å¦å é¤è¯¥æ¡æ°æ®?", "æç¤º", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning", |
| | | }).then(() => { |
| | | delProcessDeal({ id: row.id }).then((res) => { |
| | | this.$message.success("å 餿å"); |
| | | this.getList(); |
| | | }); |
| | | }).catch(() => { }); |
| | | }, |
| | | }, |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | >>>.el-dialog__body { |
| | | padding-top: 10px; |
| | | } |
| | | </style> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div style="display: flex;justify-content: space-between;align-items: flex-start"> |
| | | <el-form :model="queryParams0" ref="queryParams0" size="small" :inline="true"> |
| | | <el-form-item label="æ¶æ ·æ¥æ" prop="receiveDate"> |
| | | <el-date-picker v-model="queryParams0.receiveDate" type="date" placeholder="éæ©æ¥æ" format="yyyy-MM-dd" |
| | | value-format="yyyy-MM-dd" size="small" @change="refreshTable()"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <el-button size="small" @click="handleDown0">导åº</el-button> |
| | | </div> |
| | | |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData0" :column="column0" :tableLoading="tableLoading0" |
| | | key="tableData0" |
| | | :height="'calc(100vh - 240px)'" :page="page0" @pagination="pagination0"> |
| | | <div slot="action" slot-scope="scope"> |
| | | <el-button type="text" @click="handleAdd(scope.row)">ç¼è¾</el-button> |
| | | <el-button type="text" @click="delRow(scope.row)"> |
| | | <span style="color: #F56C6C">å é¤</span> |
| | | </el-button> |
| | | </div> |
| | | </lims-table> |
| | | </div> |
| | | <!-- æ°å¢æ ·å --> |
| | | <el-dialog :title="title" :visible.sync="addDialogVisible" width="400px"> |
| | | <el-row> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ¶æ ·æ¥æï¼</div> |
| | | <div class="search_input"> |
| | | <el-date-picker v-model="addInfo.receiveDate" type="date" size="small" placeholder="éæ©æ¥æ" format="yyyy-MM-dd" |
| | | value-format="yyyy-MM-dd" style="width: 100%;"> |
| | | </el-date-picker> |
| | | </div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ ·ååç§°ï¼</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.sampleName"></el-input></div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ ·åç¼å·ï¼</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.sampleCode"></el-input></div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ°éï¼</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.num"></el-input> |
| | | </div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ¥æ ·åä½ï¼</div> |
| | | <div class="search_input"> |
| | | <el-select v-model="addInfo.sampleSupplier" size="small"> |
| | | <el-option :label="item.company" :value="item.company" v-for="(item, index) in customPageList" |
| | | :key="item.id"></el-option> |
| | | </el-select> |
| | | </div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">çæ ·æ¥æï¼</div> |
| | | <div class="search_input"> |
| | | <el-date-picker v-model="addInfo.leaveDate" type="date" size="small" placeholder="éæ©æ¥æ" format="yyyy-MM-dd" |
| | | value-format="yyyy-MM-dd" style="width: 100%;"> |
| | | </el-date-picker> |
| | | </div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ ·åç¶æï¼</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.sampleState"></el-input></div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">å¤çæ¥æï¼</div> |
| | | <div class="search_input"> |
| | | <el-date-picker v-model="addInfo.dealTime" type="date" size="small" placeholder="éæ©æ¥æ" format="yyyy-MM-dd" |
| | | value-format="yyyy-MM-dd" style="width: 100%;"> |
| | | </el-date-picker> |
| | | </div> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addDialogVisible = false">å æ¶</el-button> |
| | | <el-button type="primary" @click="submitAdd" :loading="addLoading">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!-- 详æ
/ä¸è½½/å®¡æ ¸/æ¹å --> |
| | | <el-dialog :title="title0" :visible.sync="lookDialogVisible" width="800px" :class="{ downPdf: title0 == 'ä¸è½½' }" |
| | | :modal="title0 != 'ä¸è½½'" top="5vh"> |
| | | <filePreview v-if="lookDialogVisible" :fileUrl="javaApi + '/word/' + currentInfo.url" :currentFile="{}" |
| | | style="max-height: 70vh;overflow-y: auto;" /> |
| | | <span slot="footer" class="dialog-footer" v-if="title0 == 'å®¡æ ¸' || title0 == 'æ¹å'"> |
| | | <el-button @click="submitCheck('ä¸éè¿')" :loading="noCheckLoading">ä¸éè¿</el-button> |
| | | <el-button type="primary" @click="submitCheck('éè¿')" :loading="checkLoading">é è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import filePreview from "@/components/Preview/filePreview.vue"; |
| | | import { selectCustomPageList } from "@/api/system/customer"; |
| | | import { |
| | | pageProcessSample, |
| | | delProcessSample, |
| | | addProcessSample, |
| | | exportProcessSample |
| | | } from "@/api/cnas/process/sampleDisposal"; |
| | | export default { |
| | | name: 'SampleReceipt', |
| | | components: { |
| | | limsTable, |
| | | filePreview, |
| | | }, |
| | | data() { |
| | | return { |
| | | activeName: 'å¡«å', |
| | | title: 'æ°å¢', |
| | | addDialogVisible: false, |
| | | addLoading: false, |
| | | outLoading: false, |
| | | editDialogVisible: false, |
| | | lookDialogVisible: false, |
| | | title0: 'æ¥ç', |
| | | noCheckLoading: false, |
| | | checkLoading: false, |
| | | // åå²å表 |
| | | addInfo: {},//æ°å¢æ ·å |
| | | customPageList: [], |
| | | currentInfo: { |
| | | arr: [] |
| | | },//æ¥çç详æ
|
| | | queryParams0: { |
| | | receiveDate: '' |
| | | }, |
| | | tableLoading0: false, |
| | | tableData0: [], |
| | | column0: [ |
| | | { |
| | | label: "æ¶æ ·æ¥æ", |
| | | prop: "receiveDate", |
| | | }, |
| | | { |
| | | label: "æ ·åç¼å·", |
| | | prop: "sampleCode", |
| | | }, |
| | | { |
| | | label: "æ ·ååç§°", |
| | | prop: "sampleName", |
| | | }, |
| | | { |
| | | label: "æ ·åæ°é", |
| | | prop: "num", |
| | | }, |
| | | { |
| | | label: "æ¥æ ·åä½", |
| | | prop: "sampleSupplier", |
| | | }, |
| | | { |
| | | label: "çæ ·æ¥æ", |
| | | prop: "leaveDate", |
| | | }, |
| | | { |
| | | label: "æ ·åç¶æ", |
| | | prop: "sampleState", |
| | | }, |
| | | { |
| | | label: "éæ ·ç¾æ¶/å¤çæ¥æ", |
| | | prop: "dealTime", |
| | | }, |
| | | { |
| | | dataType: "slot", |
| | | slot: "action", |
| | | label: "æä½", |
| | | } |
| | | ], |
| | | page0: { |
| | | total: 0, |
| | | size: 10, |
| | | current: 0, |
| | | }, |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.getList0() |
| | | }, |
| | | methods: { |
| | | // è·åéæ ·åä½å表 |
| | | getCustomPageList() { |
| | | selectCustomPageList({ |
| | | current: -1, |
| | | size: -1 |
| | | }).then(res => { |
| | | this.customPageList = res.data.records |
| | | }).catch(err => { }); |
| | | }, |
| | | refresh() { |
| | | this.queryParams0 = {}; |
| | | this.page0.current = 1; |
| | | this.getList0(); |
| | | }, |
| | | refreshTable() { |
| | | this.page0.current = 1; |
| | | this.getList0(); |
| | | }, |
| | | // æ¥è¯¢è¡¨æ ¼æ°æ® |
| | | getList0() { |
| | | this.tableLoading0 = true; |
| | | let param = { ...this.queryParams0, ...this.page0 }; |
| | | delete param.total; |
| | | pageProcessSample({ ...param }) |
| | | .then((res) => { |
| | | this.tableLoading0 = false; |
| | | if (res.code === 200) { |
| | | this.tableData0 = res.data.records; |
| | | this.page0.total = res.data.total; |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | this.tableLoading0 = false; |
| | | }); |
| | | }, |
| | | pagination0({ page, limit }) { |
| | | this.page0.current = page; |
| | | this.page0.size = limit; |
| | | this.getList0(); |
| | | }, |
| | | // æå¼ç¼è¾å¼¹æ¡ |
| | | handleAdd(row) { |
| | | this.addInfo = this.HaveJson(row) |
| | | this.title = 'ç¼è¾' |
| | | this.addDialogVisible = true |
| | | this.getCustomPageList() |
| | | }, |
| | | delRow(row) { |
| | | this.$confirm("æ¯å¦å é¤è¯¥æ¡æ°æ®?", "æç¤º", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning", |
| | | }) |
| | | .then(() => { |
| | | delProcessSample({ id: row.id }).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success("å 餿å"); |
| | | this.refreshTable(); |
| | | } |
| | | }).catch(err => { }); |
| | | }) |
| | | .catch(() => { }); |
| | | }, |
| | | // æäº¤æ°å¢ |
| | | submitAdd() { |
| | | // ç¼è¾ |
| | | this.addLoading = true |
| | | addProcessSample({ |
| | | ...this.addInfo |
| | | }).then(res => { |
| | | this.addLoading = false |
| | | this.addDialogVisible = false |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'ç¼è¾æå!' |
| | | }); |
| | | this.page0.current = 1; |
| | | this.refreshTable(); |
| | | }).catch(err => { }); |
| | | }, |
| | | // 导åºè¯¦æ
|
| | | handleDown0() { |
| | | exportProcessSample({ receiveDate: this.queryParams0.receiveDate }).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/msword' }); |
| | | this.$download.saveAs(blob, 'æ ·åæ¥æ¶' + '.docx'); |
| | | }) |
| | | }, |
| | | }, |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .search_thing { |
| | | width: 350px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 110px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 110px); |
| | | } |
| | | |
| | | .downPdf { |
| | | opacity: 0 !important; |
| | | } |
| | | |
| | | .tables td { |
| | | height: 40px; |
| | | width: 100px; |
| | | text-align: center; |
| | | font-size: 14px; |
| | | word-wrap: break-word; |
| | | white-space: normal; |
| | | } |
| | | |
| | | .user-info .el-button { |
| | | margin: 0; |
| | | } |
| | | |
| | | >>>.el-tabs__content { |
| | | height: 100%; |
| | | } |
| | | </style> |
| | |
| | | <el-upload ref='upload' |
| | | :action="fileAction" |
| | | :auto-upload="true" |
| | | :before-upload="fileBeforeUpload" :data="{detailsEvaluateId: info.detailsEvaluateId}" |
| | | :before-upload="fileBeforeUpload" :data="{qualityMonitorDetailsId: info.qualityMonitorDetailsId}" |
| | | :headers="uploadHeader" :on-error="onError" |
| | | :on-success="handleSuccessUp" |
| | | :show-file-list="false" |
| | |
| | | // æ¥è¯¢éä»¶å表 |
| | | searchTableList () { |
| | | this.tableLoading = true |
| | | getEvaluateFileList({detailsEvaluateId:this.info.detailsEvaluateId}).then(res => { |
| | | getEvaluateFileList({qualityMonitorDetailsId:this.info.qualityMonitorDetailsId}).then(res => { |
| | | this.tableLoading = false |
| | | if (res.code === 200){ |
| | | this.tableData = res.data |
| | |
| | | <template> |
| | | <!--è´¨éçæ§-宿½æµç¨é¡µé¢--> |
| | | <div> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="formDia" title="宿½" |
| | | width="60%" @close="closeCarryOutDia"> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeCarryOutDia">å æ¶</el-button> |
| | | <el-button v-if="currentStep !== 2" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 0" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == ratifyUserId" :loading="editLoad" @click="handleEdit(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == ratifyUserId" :loading="editLoad" type="primary" @click="handleEdit(1)">é |
| | | è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | |
| | | getQualityMonitorRatify |
| | | } from "@/api/cnas/process/ensureResults/qualityMonitor"; |
| | | import { selectUserCondition } from "@/api/business/inspectionTask"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'carryOutDialog', |
| | |
| | | personList: [], |
| | | editLoad: false, |
| | | isCarryOut: false, // æ¯å¦ä¸ºå®æ½ |
| | | ratifyUserId: '' |
| | | }; |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | |
| | | searchInfo(row) { |
| | | getQualityMonitorRatify({ qualityMonitorDetailsId: row.qualityMonitorDetailsId }).then(res => { |
| | | // ædetailsRatifyIdå说ææäº¤è¿å®æ½ä¿¡æ¯ |
| | | if (res.data.detailsRatifyId) { |
| | | if (res.data.ratifyUserId) { |
| | | // æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ |
| | | if (res.data.isFinish == 0) { |
| | | if (res.data.isFinish != 1) { |
| | | this.currentStep = 1 |
| | | } else if (res.data.isFinish == 1) { |
| | | this.currentStep = 2 |
| | |
| | | this.currentStep = 0 |
| | | } |
| | | this.form = res.data |
| | | this.ratifyUserId = res.data.ratifyUserId |
| | | }).catch(err => { |
| | | console.log('err---', err); |
| | | }) |
| | | }, |
| | | // æäº¤ |
| | | handleEdit() { |
| | | if (!this.form.ratifyUserId) { |
| | | this.$message.warning('è¯·éæ©æ¹å人') |
| | | return |
| | | } |
| | | handleEdit(isFinish) { |
| | | this.editLoad = true |
| | | if (this.currentStep == 0) { |
| | | this.addInfo() |
| | | } else { |
| | | this.editInfo() |
| | | this.editInfo(isFinish) |
| | | } |
| | | }, |
| | | // æäº¤å®æ½ |
| | |
| | | }) |
| | | }, |
| | | // æäº¤æ¹å |
| | | editInfo() { |
| | | editInfo(isFinish) { |
| | | this.form.isFinish = isFinish |
| | | addQualityMonitorRatifyOpinion(this.form).then(res => { |
| | | this.editLoad = false |
| | | this.$message.success('æä½æå') |
| | |
| | | :visible.sync="formDia" |
| | | title="è´¨éçæ§è¯ä»·" |
| | | width="60%" @close="closeEvaDia"> |
| | | <div style="text-align: right"> |
| | | <el-button size="small" type="primary" @click="viewTestRecord" :disabled="currentStep === 0">éä»¶ä¸ä¼ </el-button> |
| | | </div> |
| | | <el-steps :active="currentStep" align-center finish-status="success"> |
| | | <el-step title="çæ§è®¡å宿½æ
åµ" @click.native="setStep(0)"></el-step> |
| | | <el-step title="çæ§ç»æè¯ä»·" @click.native="setStep(1)"></el-step> |
| | |
| | | <!-- 7.7è´¨éçæ§è®¡å--> |
| | | <div class="app-container"> |
| | | <div class="table-card"> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="yearForm" ref="yearForm" size="small" :inline="true"> |
| | | <el-form-item label="计ååç§°" prop="monitorName"> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">计ååç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="yearForm.monitorName" |
| | | @keyup.enter.native="getYearPlanList"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="clearYear">é ç½®</el-button> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getYearPlanList">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | @keyup.enter.native="getYearPlanList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="getYearPlanList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="clearYear">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="leadInto">导å
¥</el-button> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="yearTableData" :column="yearColumnData" :page="yearPage" :tableLoading="yearLoading" |
| | | height="40vh" @pagination="pagination" :rowClick="rowClick" key="yearTableData"></lims-table> |
| | | :height="'calc(100vh - 34em)'" @pagination="pagination" :rowClick="rowClick" key="yearTableData"></lims-table> |
| | | </div> |
| | | <div style="margin-top: 20px"> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="yearDetailForm" ref="yearDetailForm" size="small" :inline="true"> |
| | | <el-form-item label="çæ§ç®ç" prop="monitorPurpose"> |
| | | <el-input v-model="yearDetailForm.monitorPurpose" placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="çæ§é¡¹ç®" prop="monitorProject"> |
| | | <el-input v-model="yearDetailForm.monitorProject" placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="clearDetail">é ç½®</el-button> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getYearDetailPlanList">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">çæ§ç®ç</span> |
| | | <el-input v-model="yearDetailForm.monitorPurpose" placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getYearDetailPlanList"></el-input> |
| | | </div> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">çæ§é¡¹ç®</span> |
| | | <el-input v-model="yearDetailForm.monitorProject" placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getYearDetailPlanList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="getYearDetailPlanList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="clearDetail">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="exportSignatureTemplate">导åºç¾å模æ¿</el-button> |
| | | <el-button size="small" type="primary" @click="showDialog('add')">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="yearDetailTableData" :column="yearDetailColumnData" :page="yearDetailPage" |
| | | :tableLoading="yearDetailLoading" height="40vh" @pagination="pagination1" |
| | | :tableLoading="yearDetailLoading" :height="'calc(100vh - 34em)'" @pagination="pagination1" ref="yearDetailTableData" |
| | | key="yearDetailTableData"></lims-table> |
| | | </div> |
| | | <!--æ°å¢ä¿®æ¹å¼¹æ¡--> |
| | |
| | | @closeDia="closeDia"></detail-form-dialog> |
| | | <!--宿½æµç¨å¼¹æ¡--> |
| | | <carry-out-dialog v-if="carryOutDia" ref="carryOutDia" :qualityMonitorId="qualityMonitorId" |
| | | @closeDia="closeCarryOutDia"></carry-out-dialog> |
| | | @closeCarryOutDia="closeCarryOutDia"></carry-out-dialog> |
| | | <!--è¯ä»·æµç¨å¼¹æ¡--> |
| | | <evaluate-dialog v-if="evaluateDialog" ref="evaluateDialog" @closeEvaDia="closeEvaDia"></evaluate-dialog> |
| | | <el-dialog :visible.sync="examineDialog" title="å®¡æ ¸" width="30%" @close="closeExamineDia"> |
| | |
| | | </el-dialog> |
| | | <el-dialog :visible.sync="downloadDialog" title="导åº" width="600px"> |
| | | <span> |
| | | <el-button plain type="primary" :disabled="!download.qualityMonitorDetailsId" |
| | | <el-button plain type="primary" :disabled="download.detailsRatifyStatus !== 3" |
| | | @click="controlDown">宿½è®¡å导åº</el-button> |
| | | <el-button plain type="primary" :disabled="!download.qualityMonitorDetailsId" |
| | | <el-button plain type="primary" :disabled="!download.finishReportUrl" |
| | | @click="finishReportExport">宿æ¥å导åº</el-button> |
| | | <el-button plain type="primary" :disabled="download.evaluateStatus !== 3" |
| | | @click="processingDown">è¯ä»·å¯¼åº</el-button> |
| | | </span> |
| | | <span slot="footer" class="dialog-footer"> |
| | |
| | | <el-button :loading="uploading1" type="primary" @click="submitUpload1()">ä¸ ä¼ </el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <view-record v-if="ViewRecord" ref="ViewRecord"></view-record> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | } from "@/api/cnas/process/ensureResults/qualityMonitor"; |
| | | import { selectUserCondition } from "@/api/performance/class"; |
| | | import { mapGetters } from "vuex"; |
| | | import ViewRecord from "./components/ViewRecord.vue"; |
| | | |
| | | export default { |
| | | name: 'EnsureResultsValidity', |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | | components: { limsTable, filePreview, EvaluateDialog, CarryOutDialog, DetailFormDialog }, |
| | | components: {ViewRecord, limsTable, filePreview, EvaluateDialog, CarryOutDialog, DetailFormDialog }, |
| | | data() { |
| | | // è¿éåæ¾æ°æ® |
| | | return { |
| | | ViewRecord: false, |
| | | examineUserId: '', |
| | | responsibleOptions: [], |
| | | yearForm: { |
| | |
| | | { |
| | | label: '计ååç§°', |
| | | prop: 'monitorName', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | }, { |
| | | label: 'ç¼å¶äºº', |
| | | prop: 'writeName', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'ç¼å¶æ¥æ', |
| | | prop: 'writeTime', |
| | | minWidth: '160' |
| | | width: '160' |
| | | }, { |
| | | dataType: 'tag', |
| | | label: 'å®¡æ ¸ç¶æ', |
| | | prop: 'examineStatus', |
| | | minWidth: '100', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'ä¸éè¿'; |
| | |
| | | }, { |
| | | label: 'å®¡æ ¸å
容', |
| | | prop: 'examineRemark', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'å®¡æ ¸äºº', |
| | | prop: 'examineName', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'å®¡æ ¸æ¥æ', |
| | | prop: 'examineTime', |
| | | minWidth: '160' |
| | | width: '160' |
| | | }, { |
| | | dataType: 'tag', |
| | | label: 'æ¹åç¶æ', |
| | | prop: 'ratifyStatus', |
| | | minWidth: '100', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return '䏿¹å'; |
| | |
| | | }, { |
| | | label: 'æ¹åå
容', |
| | | prop: 'ratifyRemark', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'æ¹å人', |
| | | prop: 'ratifyName', |
| | | minWidth: '100' |
| | | width: '100' |
| | | }, { |
| | | label: 'æ¹åæ¥æ', |
| | | prop: 'ratifyTime', |
| | | minWidth: '160' |
| | | width: '160' |
| | | }, { |
| | | dataType: 'action', |
| | | minWidth: '190', |
| | | label: 'æä½', |
| | | fixed: 'right', |
| | | operation: [ |
| | |
| | | }, { |
| | | label: '计åå¼å±æ¶é´', |
| | | prop: 'plannedTime', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | }, { |
| | | label: 'çæ§é¡¹ç®', |
| | | prop: 'monitorProject', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | }, { |
| | | label: 'åå åä½ï¼äººåï¼', |
| | | prop: 'participant', |
| | | minWidth: '150px' |
| | | width: '190px' |
| | | }, { |
| | | label: 'é¢ç®ï¼å
ï¼', |
| | | prop: 'budget', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | }, { |
| | | label: 'ç»ç»äººå', |
| | | prop: 'organization', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | }, { |
| | | label: 'çæ§æ¹å¼', |
| | | prop: 'monitorWay', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | },{ |
| | | dataType: 'tag', |
| | | label: '宿½ç¶æ', |
| | | prop: 'detailsRatifyStatus', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'æªå¼å§'; |
| | | } else if (params === 1) { |
| | | return 'å¾
è¯ä»·'; |
| | | } else if (params === 2) { |
| | | return '䏿¹å'; |
| | | } else if (params === 3) { |
| | | return 'å·²æ¹å'; |
| | | } else { |
| | | return null; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 0) { |
| | | return ''; |
| | | } else if (params === 1) { |
| | | return 'warning'; |
| | | } else if (params === 2) { |
| | | return 'danger'; |
| | | } else if (params === 3) { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | },{ |
| | | dataType: 'tag', |
| | | label: 'æ¥åç¶æ', |
| | | prop: 'reportStatus', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'æªå¼å§'; |
| | | } else if (params === 1) { |
| | | return 'å¾
è¯ä»·'; |
| | | } else if (params === 2) { |
| | | return '䏿¹å'; |
| | | } else if (params === 3) { |
| | | return 'å·²æ¹å'; |
| | | } else { |
| | | return null; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 0) { |
| | | return ''; |
| | | } else if (params === 1) { |
| | | return 'warning'; |
| | | } else if (params === 2) { |
| | | return 'danger'; |
| | | } else if (params === 3) { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | },{ |
| | | dataType: 'tag', |
| | | label: 'è¯ä»·ç¶æ', |
| | | prop: 'evaluateStatus', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'æªå¼å§'; |
| | | } else if (params === 1) { |
| | | return 'å¾
è¯ä»·'; |
| | | } else if (params === 2) { |
| | | return 'å¾
æ¹å'; |
| | | } else if (params === 3) { |
| | | return 'å·²æ¹å'; |
| | | } else { |
| | | return null; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 0) { |
| | | return ''; |
| | | } else if (params === 1) { |
| | | return 'warning'; |
| | | } else if (params === 2) { |
| | | return 'info'; |
| | | } else if (params === 3) { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | }, { |
| | | dataType: 'action', |
| | | width: '280', |
| | | label: 'æä½', |
| | | fixed: 'right', |
| | | operation: [ |
| | |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.evaluate(row) |
| | | } |
| | | }, |
| | | { |
| | | name: 'éä»¶ä¸ä¼ ', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.viewTestRecord(row) |
| | | } |
| | | }, |
| | | { |
| | |
| | | this.yearDetailLoading = false |
| | | this.yearDetailTableData = res.data.records |
| | | this.yearDetailPage.total = res.data.total |
| | | this.$refs.yearDetailTableData.$refs.multipleTable.doLayout() |
| | | }).catch(err => { |
| | | console.log('err---', err); |
| | | this.yearDetailLoading = false |
| | |
| | | this.evaluateDialog = false |
| | | this.getYearDetailPlanList() |
| | | }, |
| | | // éä»¶ä¸ä¼ |
| | | viewTestRecord (row) { |
| | | this.ViewRecord = true |
| | | this.$nextTick(() => { |
| | | this.$refs.ViewRecord.openDia(row) |
| | | }) |
| | | }, |
| | | // æå¼å¯¼åºå¼¹æ¡ |
| | | downLoadPost(row) { |
| | | this.downloadDialog = true |
| | |
| | | const blob = new Blob([res], { type: 'application/msword' }); |
| | | this.$download.saveAs(blob, 'è´¨éçæ§å®æ½è®¡å.docx') |
| | | }) |
| | | }, |
| | | // 宿æ¥åå¯¼åº |
| | | finishReportExport() { |
| | | let url = this.download.finishReportUrl; |
| | | const link = document.createElement('a'); |
| | | link.href = this.javaApi +'/word/' + url; |
| | | link.target = '_blank'; |
| | | document.body.appendChild(link); |
| | | link.click(); |
| | | }, |
| | | // å¤çåå¯¼åº |
| | | processingDown() { |
| | |
| | | selectUserCondition().then((res) => { |
| | | this.responsibleOptions = res.data; |
| | | }) |
| | | }, |
| | | exportSignatureTemplate() { |
| | | let url = 'è´¨éçæ§è®°å½ç¾å模æ¿.docx'; |
| | | const link = document.createElement('a'); |
| | | link.href = this.javaApi +'/word/' + url; |
| | | link.target = '_blank'; |
| | | document.body.appendChild(link); |
| | | link.click(); |
| | | } |
| | | }, |
| | | // ç¨äºä¸ä¼ æä»¶çä¿¡æ¯ |
| | |
| | | <el-date-picker |
| | | v-model="form.superviseTime" |
| | | clearable |
| | | format="yyyy-MM" |
| | | format="yyyy.M" |
| | | placeholder="éæ©æ¥æ" |
| | | size="small" |
| | | style="width: 100%" |
| | | type="month" |
| | | value-format="yyyy-MM"> |
| | | value-format="yyyy.M"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | <p><span class="required-span">* </span>被çç£äººï¼</p> |
| | | </td> |
| | | <td class="td-info"> |
| | | <!-- <el-select v-if="currentStep === 0" v-model="form.supervisedUserId" clearable--> |
| | | <!-- filterable--> |
| | | <!-- placeholder="è¯·éæ©" size="small">--> |
| | | <!-- <el-option v-for="(item,i) in supervisedUserList" :key="i" :label="item.label" :value="item.value">--> |
| | | <!-- </el-option>--> |
| | | <!-- </el-select>--> |
| | | <span class="td-info1"> {{ form.supervisedUserName }}</span> |
| | | </td> |
| | | <td class="td-title"> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeProcessingDia">å æ¶</el-button> |
| | | <el-button v-if="currentStep !== 2" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 0 && userId == supervisedUserId" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == approverUserId" :loading="editLoad" @click="handleEdit(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == approverUserId" :loading="editLoad" type="primary" @click="handleEdit(1)">é |
| | | è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | |
| | | getSuperviseDetailAccording |
| | | } from "@/api/cnas/process/ensureResults/qualitySupervise"; |
| | | import {selectUserCondition} from "@/api/business/inspectionTask"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'processingSheet', |
| | |
| | | editLoad: false, |
| | | personList: [], |
| | | supervisedUserList: [], |
| | | supervisedUserId: '', |
| | | approverUserId: '' |
| | | }; |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | openDia (row) { |
| | | this.formDia = true |
| | | this.searchInfo(row) |
| | | this.form.superviseDetailsId = row.superviseDetailsId |
| | | this.supervisedUserId = row.supervisedUserId |
| | | this.searchInfo(row) |
| | | this.form.approveId = row.approveId |
| | | this.getAuthorizedPerson() // è·å人åå表 |
| | | // this.getSupervisedUserList() // è·åå½åé¨é¨äººå |
| | | }, |
| | | // æ¥è¯¢çæ§è®¡å详æ
宿½ä¿¡æ¯ |
| | | searchInfo (row) { |
| | | this.form.qualityMonitorDetailsId = row.qualityMonitorDetailsId |
| | | getSuperviseDetailAccording({superviseDetailsId: row.superviseDetailsId}).then(res => { |
| | | getSuperviseDetailAccording({superviseDetailsId: this.form.superviseDetailsId}).then(res => { |
| | | this.form.supervisedUserId = res.data.supervisedUserId |
| | | this.form.supervisedUserName = res.data.supervisedUserName |
| | | if (res.data.superviseDetailsAccordingId === null) { |
| | | this.currentStep = 0 |
| | | } else { |
| | | this.form = res.data |
| | | if (res.data.isFinish === 0) { |
| | | if (res.data.approverUserId) { |
| | | this.currentStep = 1 |
| | | } |
| | | } else { |
| | | if (res.data.approverUserId) { |
| | | // æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ |
| | | if (res.data.isFinish != 1) { |
| | | this.currentStep = 1 |
| | | } else if (res.data.isFinish == 1) { |
| | | this.currentStep = 2 |
| | | } |
| | | } else { |
| | | this.currentStep = 0 |
| | | } |
| | | this.form = res.data |
| | | this.form.superviseDetailsId = row.superviseDetailsId |
| | | this.approverUserId = res.data.approverUserId |
| | | }).catch(err => { |
| | | console.log('err---', err); |
| | | }) |
| | | }, |
| | | // æäº¤ |
| | | handleEdit () { |
| | | handleEdit (isFinish) { |
| | | if (this.currentStep === 0) { |
| | | if (this.form.findWay === null) { |
| | | this.$message.warning('è¯·éæ©ä¸ç¬¦åå·¥ä½åç°éå¾') |
| | |
| | | this.$message.warning('è¯·éæ©æ¯å¦éè¦éåçº æ£æªæ½') |
| | | return |
| | | } |
| | | if (!this.form.approverUserId) { |
| | | this.$message.warning('è¯·éæ©æ¹å人') |
| | | return |
| | | } |
| | | } |
| | | this.editLoad = true |
| | | this.form.flowType = this.currentStep |
| | |
| | | this.editLoad = false |
| | | }) |
| | | } else { |
| | | this.form.isFinish = isFinish |
| | | approverEquipSuperviseDetailAccording(this.form).then(res => { |
| | | this.editLoad = false |
| | | this.$message.success('æ¹åæå') |
| | |
| | | this.personList = data; |
| | | }); |
| | | }, |
| | | // getSupervisedUserList () { |
| | | // this.$axios.get(this.$api.user.selectDepartmentLimsUserList).then(res => { |
| | | // let data = [] |
| | | // res.data.forEach(a => { |
| | | // data.push({ |
| | | // label: a.name, |
| | | // value: a.id |
| | | // }) |
| | | // }) |
| | | // this.supervisedUserList = data |
| | | // }) |
| | | // }, |
| | | } |
| | | }; |
| | | </script> |
| | |
| | | <p><span class="required-span">* </span>çç£åï¼</p> |
| | | </td> |
| | | <td colspan="2"> |
| | | <el-select v-if="currentStep === 0" @change="usePersonName" v-model="form.supervisorId" placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | | <el-option v-for="item in recordUserList" :key="item.userId" :label="item.userName" :value="item.userId"></el-option> |
| | | <el-select v-if="currentStep === 0" @change="usePersonName" v-model="form.supervisor" placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | | <el-option v-for="item in recordUserList" :key="item.userName" :label="item.userName" :value="item.userName"></el-option> |
| | | </el-select> |
| | | <span v-else class="td-info"> {{ form.supervisor }}</span> |
| | | </td> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeRecordsDia">å æ¶</el-button> |
| | | <el-button v-if="currentStep !== 2" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 0 && userId == supervisedUserId" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == ratifyUserId" :loading="editLoad" @click="handleEdit(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == ratifyUserId" :loading="editLoad" type="primary" @click="handleEdit(1)">é |
| | | è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | |
| | | getSuperviseDetailRecord |
| | | } from "@/api/cnas/process/ensureResults/qualitySupervise"; |
| | | import {selectUserCondition} from "@/api/business/inspectionTask"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'recordsDialog', |
| | |
| | | editLoad: false, |
| | | personList: [], |
| | | recordUserList: [], |
| | | supervisedUserId: '', |
| | | ratifyUserId: '', |
| | | }; |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | openDia(row) { |
| | | this.formDia = true |
| | | this.supervisedUserId = row.supervisedUserId |
| | | this.searchInfo(row) |
| | | this.getAuthorizedPerson() |
| | | }, |
| | |
| | | searchInfo (row) { |
| | | getSuperviseDetailRecord({superviseDetailsId: row.superviseDetailsId}).then(res => { |
| | | // æsuperviseDetailsRecordId说ææäº¤è¿è®°å½ |
| | | if (res.data.superviseDetailsRecordId) { |
| | | if (res.data.ratifyUserId) { |
| | | // æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ |
| | | if (res.data.isFinish === 0) { |
| | | if (res.data.isFinish != 1) { |
| | | this.currentStep = 1 |
| | | } else if (res.data.isFinish === 1) { |
| | | } else if (res.data.isFinish == 1) { |
| | | this.currentStep = 2 |
| | | } |
| | | } else { |
| | |
| | | } |
| | | this.form = res.data |
| | | this.form.superviseDetailsId = row.superviseDetailsId |
| | | this.ratifyUserId = res.data.ratifyUserId |
| | | this.getRecordUser() |
| | | }).catch(err => { |
| | | console.log('err---', err); |
| | | }) |
| | | }, |
| | | // æäº¤æµç¨ |
| | | handleEdit () { |
| | | handleEdit (isFinish) { |
| | | if (!this.form.testMember || !this.form.supervisor || !this.form.testItem || !this.form.sampleNumber |
| | | || !this.form.testDate) { |
| | | this.$message.warning('请填å宿´') |
| | |
| | | if (this.currentStep === 0) { |
| | | this.addInfo() |
| | | } else { |
| | | this.editInfo() |
| | | this.editInfo(isFinish) |
| | | } |
| | | }, |
| | | // æäº¤è®°å½ |
| | | addInfo () { |
| | | if (!this.form.ratifyUserId) { |
| | | this.$message.warning('è¯·éæ©ä¸ä¸æ¥æ¹å人') |
| | | return |
| | | } |
| | | this.editLoad = true |
| | | addSuperviseDetailRecord(this.form).then(res => { |
| | | this.editLoad = false |
| | |
| | | }) |
| | | }, |
| | | // æäº¤æ¹å |
| | | editInfo () { |
| | | editInfo (isFinish) { |
| | | if (!this.form.ratifyOpinion) { |
| | | this.$message.warning('请填åå®¡æ¹æè§') |
| | | return |
| | |
| | | return |
| | | } |
| | | this.editLoad = true |
| | | this.form.isFinish = isFinish |
| | | addSuperviseRecordOpinion(this.form).then(res => { |
| | | this.editLoad = false |
| | | this.$message.success('æä½æå') |
| | |
| | | <span v-if="currentStep !== 0" class="td-info1"> {{ form.raiseResult }}</span> |
| | | </td> |
| | | </tr> |
| | | <!-- <tr v-if="showStep === 0">--> |
| | | <!-- <td v-if="currentStep === 0" class="td-title">--> |
| | | <!-- <p><span class="required-span">* </span>è¯·éæ©ä¸ä¸æ¥è´è´£äººï¼</p>--> |
| | | <!-- </td>--> |
| | | <!-- <td v-if="currentStep === 0" class="td-info" colspan="3">--> |
| | | <!-- <el-select v-model="form.causeUserId" clearable filterable--> |
| | | <!-- placeholder="è¯·éæ©" size="small">--> |
| | | <!-- <el-option v-for="(item,i) in personList" :key="i" :label="item.label" :value="item.value">--> |
| | | <!-- </el-option>--> |
| | | <!-- </el-select>--> |
| | | <!-- </td>--> |
| | | <!-- </tr>--> |
| | | <tr v-if="currentStep !== 0"> |
| | | <td class="td-title"> |
| | | <p>æåºäººï¼</p> |
| | |
| | | {{form.causeTime}} |
| | | </td> |
| | | </tr> |
| | | <!-- <tr v-if="showStep === 0">--> |
| | | <!-- <td v-if="currentStep === 0" class="td-title">--> |
| | | <!-- <p><span class="required-span">* </span>è¯·éæ©ä¸ä¸æ¥è´è´£äººï¼</p>--> |
| | | <!-- </td>--> |
| | | <!-- <td v-if="currentStep === 0" class="td-info" colspan="3">--> |
| | | <!-- <el-select v-model="form.correctUserId" clearable filterable--> |
| | | <!-- placeholder="è¯·éæ©" size="small">--> |
| | | <!-- <el-option v-for="(item,i) in personList" :key="i" :label="item.label" :value="item.value">--> |
| | | <!-- </el-option>--> |
| | | <!-- </el-select>--> |
| | | <!-- </td>--> |
| | | <!-- </tr>--> |
| | | <tr> |
| | | <td class="td-title"> |
| | | <p><span class="required-span">* </span>çº æ£æªæ½ï¼</p> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeRectifyDia">å æ¶</el-button> |
| | | <el-button v-if="currentStep !== 2" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 0 && userId == supervisedUserId" :loading="editLoad" type="primary" @click="handleEdit">æ 交</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == approverUserId" :loading="editLoad" @click="handleEdit(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == approverUserId" :loading="editLoad" type="primary" @click="handleEdit(1)">é |
| | | è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | |
| | | } from "@/api/cnas/process/ensureResults/qualitySupervise"; |
| | | import {selectUserCondition} from "@/api/business/inspectionTask"; |
| | | import {getThisYearTrainingDetailed} from "@/api/cnas/systemManagement/correctiveAction"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'rectifyDialog', |
| | |
| | | return { |
| | | formDia: false, |
| | | currentStep: 0, |
| | | showStep: 0, |
| | | form: { |
| | | superviseDetailsId: '', |
| | | raiseResult: '', |
| | |
| | | editLoad: false, |
| | | personList: [], |
| | | yearTrainingDetailed: [], |
| | | supervisedUserId: '', |
| | | approverUserId: '' |
| | | }; |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | |
| | | this.searchInfo(row) |
| | | this.form.superviseDetailsId = row.superviseDetailsId |
| | | this.form.approveId = row.approveId |
| | | this.supervisedUserId = row.supervisedUserId |
| | | this.getAuthorizedPerson() // è·å人åå表 |
| | | this.getYearTrainingDetailed() // è·åå¹è®è®¡å |
| | | }, |
| | |
| | | searchInfo (row) { |
| | | this.form.qualityMonitorDetailsId = row.qualityMonitorDetailsId |
| | | getSuperviseDetailCorrect({superviseDetailsId: row.superviseDetailsId}).then(res => { |
| | | if (res.data.superviseDetailsCorrectId === null) { |
| | | this.showStep = 0 |
| | | this.currentStep = 0 |
| | | } else { |
| | | this.form = res.data |
| | | if (res.data.isFinish === 0) { |
| | | if (res.data.approverUserId) { |
| | | this.showStep = 1 |
| | | this.currentStep = 1 |
| | | } |
| | | } else { |
| | | if (res.data.approverUserId) { |
| | | // æ¯å¦ç»æ0:æªç»æ, 1:å·²ç»æ |
| | | if (res.data.isFinish != 1) { |
| | | this.currentStep = 1 |
| | | } else if (res.data.isFinish == 1) { |
| | | this.currentStep = 2 |
| | | this.showStep = 1 |
| | | } |
| | | } else { |
| | | this.currentStep = 0 |
| | | } |
| | | this.form = res.data |
| | | this.approverUserId = res.data.approverUserId |
| | | }).catch(err => { |
| | | console.log('err---', err); |
| | | }) |
| | | }, |
| | | // æäº¤ |
| | | handleEdit () { |
| | | handleEdit (isFinish) { |
| | | if (this.currentStep === 0) { |
| | | if (!this.form.raiseResult) { |
| | | this.$message.warning('请填åä¸åæ ¼æè¿°') |
| | |
| | | this.editLoad = false |
| | | }) |
| | | } else { |
| | | this.form.isFinish = isFinish |
| | | approveEquipSuperviseDetailCorrect(this.form).then(res => { |
| | | this.editLoad = false |
| | | this.$message.success('æ¹åæå') |
| | |
| | | <!-- 7.7è´¨éçç£è®¡å--> |
| | | <div class="app-container"> |
| | | <div class="table-card"> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="yearForm" ref="yearForm" size="small" :inline="true"> |
| | | <el-form-item label="计ååç§°" prop="superviseName"> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">计ååç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="yearForm.superviseName" |
| | | @keyup.enter.native="getYearPlanList"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="clearYear">é ç½®</el-button> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getYearPlanList">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | @keyup.enter.native="getYearPlanList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="getYearPlanList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="clearYear">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="record">导å
¥</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | height="40vh" @pagination="pagination" :rowClick="rowClick" key="yearTableData"></lims-table> |
| | | </div> |
| | | <div style="margin-top: 20px"> |
| | | <div style="display: flex;justify-content: space-between;"> |
| | | <el-form :model="yearDetailForm" ref="yearDetailForm" size="small" :inline="true"> |
| | | <el-form-item> |
| | | <el-radio-group v-model="yearDetailForm.causeType" @change="getYearDetailPlanList" size="small"> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <el-radio-group v-model="yearDetailForm.causeType" @change="getYearDetailPlan" size="small"> |
| | | <el-radio-button :label="1">宿çç£</el-radio-button> |
| | | <el-radio-button :label="2">卿çç£</el-radio-button> |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | <el-form-item label="çæ§ç®ç" prop="supervisePurpose"> |
| | | <el-input v-model="yearDetailForm.supervisePurpose" placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="çæ§é¡¹ç®" prop="superviseProject"> |
| | | <el-input v-model="yearDetailForm.superviseProject" placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="clearDetail">é ç½®</el-button> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getYearDetailPlanList">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | </div> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">çæ§ç®ç</span> |
| | | <el-input v-model="yearDetailForm.supervisePurpose" placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getYearDetailPlan"></el-input> |
| | | </div> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">çæ§é¡¹ç®</span> |
| | | <el-input v-model="yearDetailForm.superviseProject" placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getYearDetailPlan"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="getYearDetailPlan">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="clearDetail">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="showDialog('add')">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="yearDetailTableData" :column="yearDetailColumnData" :page="yearDetailPage" |
| | | :tableLoading="yearDetailLoading" height="40vh" @pagination="pagination1" |
| | | key="yearDetailTableData"></lims-table> |
| | | :tableLoading="yearDetailLoading" height="40vh" @pagination="pagination1" key="yearDetailColumnData"></lims-table> |
| | | </div> |
| | | <!--æ°å¢ä¿®æ¹å¼¹æ¡--> |
| | | <detail-form-dialog v-if="formDia" ref="formDia" :superviseId="superviseId" |
| | |
| | | @closeProcessingDia="closeProcessingDia"></processing-sheet> |
| | | <!--çº æ£å¤çæµç¨å¼¹æ¡--> |
| | | <rectify-dialog-new v-if="rectifyDia" ref="rectifyDia" :superviseId="superviseId" |
| | | @closeProcessingDia="closeRectifyDia"></rectify-dialog-new> |
| | | @closeRectifyDia="closeRectifyDia"></rectify-dialog-new> |
| | | <el-dialog :visible.sync="ratifyDialog" title="æ¹å" width="30%" @close="closeRatifyDia"> |
| | | <span> |
| | | æ¹å夿³¨ï¼ |
| | |
| | | </el-dialog> |
| | | <el-dialog :visible.sync="downloadDialog" title="导åº" width="600px"> |
| | | <span> |
| | | <el-button plain type="primary" @click="controlDown">è®°å½å导åº</el-button> |
| | | <el-button plain type="primary" @click="processingDown">å¤çå导åº</el-button> |
| | | <el-button plain type="primary" @click="supervisoryDown">çº æ£å导åº</el-button> |
| | | <el-button plain type="primary" :disabled="download.recordStatus !== 3" @click="controlDown">è®°å½å导åº</el-button> |
| | | <el-button plain type="primary" :disabled="download.accordingStatus !== 3" @click="processingDown">å¤çå导åº</el-button> |
| | | <el-button plain type="primary" :disabled="download.correctStatus !== 3" @click="supervisoryDown">çº æ£å导åº</el-button> |
| | | </span> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="downloadDialog = false">å æ¶</el-button> |
| | |
| | | { |
| | | label: '计ååç§°', |
| | | prop: 'superviseName', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | }, { |
| | | label: 'ç¼å¶äºº', |
| | | prop: 'writeUserName', |
| | | minWidth: '100' |
| | | }, { |
| | | label: 'ç¼å¶æ¥æ', |
| | | prop: 'writeTime', |
| | | minWidth: '160' |
| | | width: '160' |
| | | }, { |
| | | dataType: 'tag', |
| | | label: 'æ¹åç¶æ', |
| | | prop: 'ratifyStatus', |
| | | minWidth: '100', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return '䏿¹å'; |
| | |
| | | }, { |
| | | label: 'æ¹åå
容', |
| | | prop: 'ratifyRemark', |
| | | minWidth: '100' |
| | | }, { |
| | | label: 'æ¹å人', |
| | | prop: 'ratifyUserName', |
| | | minWidth: '100' |
| | | }, { |
| | | label: 'æ¹åæ¥æ', |
| | | prop: 'ratifyTime', |
| | | minWidth: '160' |
| | | width: '160' |
| | | }, { |
| | | dataType: 'action', |
| | | label: 'æä½', |
| | | fixed: 'right', |
| | | operation: [ |
| | | { |
| | | name: 'æ¹å', |
| | |
| | | { |
| | | label: 'çç£æ¥æ', |
| | | prop: 'superviseTime', |
| | | minWidth: '150px' |
| | | width: '120px' |
| | | }, { |
| | | label: 'çç£ç®ç', |
| | | prop: 'supervisePurpose', |
| | | minWidth: '150px', |
| | | showOverflowTooltip: true, |
| | | width: '180px', |
| | | }, { |
| | | label: 'çæ§é¡¹ç®', |
| | | prop: 'superviseProject', |
| | | minWidth: '150px' |
| | | width: '180px' |
| | | }, { |
| | | label: '被çç£äººå', |
| | | prop: 'supervisee', |
| | | minWidth: '150px' |
| | | width: '120px' |
| | | }, { |
| | | label: 'çç£åå ', |
| | | prop: 'superviseReason', |
| | | minWidth: '150px' |
| | | width: '150px' |
| | | },{ |
| | | dataType: 'tag', |
| | | label: 'è®°å½ç¶æ', |
| | | prop: 'recordStatus', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'æªå¼å§'; |
| | | } else if (params === 1) { |
| | | return 'å¾
è¯ä»·'; |
| | | } else if (params === 2) { |
| | | return '䏿¹å'; |
| | | } else if (params === 3) { |
| | | return 'å·²æ¹å'; |
| | | } else { |
| | | return null; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 0) { |
| | | return ''; |
| | | } else if (params === 1) { |
| | | return 'warning'; |
| | | } else if (params === 2) { |
| | | return 'danger'; |
| | | } else if (params === 3) { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | },{ |
| | | dataType: 'tag', |
| | | label: 'æ§å¶ç¶æ', |
| | | prop: 'accordingStatus', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'æªå¼å§'; |
| | | } else if (params === 1) { |
| | | return 'å¾
è¯ä»·'; |
| | | } else if (params === 2) { |
| | | return '䏿¹å'; |
| | | } else if (params === 3) { |
| | | return 'å·²æ¹å'; |
| | | } else { |
| | | return null; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 0) { |
| | | return ''; |
| | | } else if (params === 1) { |
| | | return 'warning'; |
| | | } else if (params === 2) { |
| | | return 'danger'; |
| | | } else if (params === 3) { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | },{ |
| | | dataType: 'tag', |
| | | label: 'çº æ£ç¶æ', |
| | | prop: 'correctStatus', |
| | | width: '100', |
| | | formatData: (params) => { |
| | | if (params === 0) { |
| | | return 'æªå¼å§'; |
| | | } else if (params === 1) { |
| | | return 'å¾
è¯ä»·'; |
| | | } else if (params === 2) { |
| | | return '䏿¹å'; |
| | | } else if (params === 3) { |
| | | return 'å·²æ¹å'; |
| | | } else { |
| | | return null; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params === 0) { |
| | | return ''; |
| | | } else if (params === 1) { |
| | | return 'warning'; |
| | | } else if (params === 2) { |
| | | return 'danger'; |
| | | } else if (params === 3) { |
| | | return 'success'; |
| | | } else { |
| | | return null; |
| | | } |
| | | } |
| | | }, { |
| | | label: '夿³¨', |
| | | prop: 'remark', |
| | | minWidth: '150px' |
| | | }, { |
| | | dataType: 'action', |
| | | label: 'æä½', |
| | | fixed: 'right', |
| | | label: 'æä½', |
| | | operation: [ |
| | | { |
| | | name: 'ç¼è¾', |
| | |
| | | size: 20, |
| | | total: 0 |
| | | }, |
| | | currentScrollPosition: 0, |
| | | superviseId: '', |
| | | formDia: false, |
| | | recordsDia: false, |
| | |
| | | pagination({ page, limit }) { |
| | | this.yearPage.current = page; |
| | | this.yearPage.size = limit; |
| | | this.getYearPlanList(); |
| | | }, |
| | | pagination1({ page, limit }) { |
| | | this.yearDetailPage.current = page; |
| | | this.yearDetailPage.size = limit; |
| | | this.getYearPlanList(); |
| | | }, |
| | | // 导å
¥æµç¨ |
| | |
| | | // 年度计åè¡¨æ ¼ï¼ç¹å»è¡æ°æ®åå·æ°è¯¦æ
|
| | | rowClick(row) { |
| | | this.superviseId = row.superviseId |
| | | this.getYearDetailPlan() |
| | | }, |
| | | getYearDetailPlan () { |
| | | this.yearDetailPage.current = 1 |
| | | this.yearDetailPage.size = 20 |
| | | this.getYearDetailPlanList() |
| | | }, |
| | | // è·å年度æç»è¡¨ |
| | |
| | | this.yearDetailLoading = false |
| | | }) |
| | | }, |
| | | pagination1(page) { |
| | | this.yearDetailPage.size = page.limit; |
| | | this.getYearDetailPlanList(); |
| | | }, |
| | | // éç½®æç»è¡¨ |
| | | clearDetail() { |
| | | this.yearDetailForm = { |
| | | supervisePurpose: '', |
| | | superviseProject: '' |
| | | } |
| | | this.yearDetailForm.supervisePurpose = '' |
| | | this.yearDetailForm.superviseProject = '' |
| | | this.getYearDetailPlanList() |
| | | }, |
| | | // æå¼å¹´åº¦æç»æ°å¢ãä¿®æ¹å¼¹æ¡ |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="æ åæ¹æ³" prop="methodName"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.methodName"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">æ åæ¹æ³</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.methodName" |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="openFormDia('add')">æ° å¢</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | <style scoped> |
| | | .search { |
| | | background-color: #fff; |
| | | height: 80px; |
| | | height: 46px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 350px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 110px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 110px); |
| | | } |
| | | |
| | | .table { |
| | | margin-top: 10px; |
| | | background-color: #fff; |
| | | width: calc(100% - 40px); |
| | | height: calc(100% - 60px - 80px - 10px - 40px); |
| | | padding: 20px; |
| | | justify-content: space-between; |
| | | } |
| | | </style> |
| | | |
| | | <template> |
| | | <div class="standard_method"> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ åç¼å·ï¼</div> |
| | | <div class="search_input"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.code" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryParams" size="small" :inline="true"> |
| | | <el-form-item label="æ åç¼å·" prop="code"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.code" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ååç§°" prop="name"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.name" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ ååç§°ï¼</div> |
| | | <div class="search_input"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.name" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </div> |
| | | <div class="btn"> |
| | | <!-- <el-button size="small" @click="$refs.ValueTable.openUpload()" v-if="inPower"> |
| | | <i class="el-icon-upload2" style="color: #3a7bfa"></i> |
| | | <span style="color: #3a7bfa">导å
¥</span></el-button> --> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="openAdd" v-if="addPower">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="tableData" :column="column" :page="page" :tableLoading="tableLoading" |
| | | :height="'calc(100vh - 250px)'" style="padding: 20px; padding-top: 0" @pagination="pagination"></lims-table> |
| | | :height="'calc(100vh - 250px)'" @pagination="pagination"></lims-table> |
| | | <!-- æ°å¢/ç¼è¾ --> |
| | | <el-dialog :title="title" :visible.sync="addDlog" width="500px"> |
| | | <el-form :model="addForm" ref="addForm" :rules="addRules" label-position="right" label-width="120px"> |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="æ åæ¹æ³" prop="methodName"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.methodName"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">æ åæ¹æ³</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.methodName" |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="openFormDia('add')">æ° å¢</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="æ åå·" prop="standardNo" v-if="tabIndex === '0'"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.standardNo"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="åæ¡£åç§°" prop="archivedName" v-if="tabIndex === '1'"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.archivedName"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;" v-if="tabIndex === '0'"> |
| | | <span style="width: 68px;font-size: 14px;font-weight: 700;color: #606266;">æ åå·</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.standardNo" |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </div> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;" v-if="tabIndex === '1'"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">åæ¡£åç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.archivedName" |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="openApprovalDialog1">建 档</el-button> |
| | | <el-upload ref='upload' :action="action" :before-upload="beforeUpload" :headers="uploadHeader" :on-error="onError" |
| | | :on-success="handleSuccessUp" :show-file-list="false" |
| | | accept='.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar' |
| | | style="display: inline-block; margin-left: 10px;"> |
| | | :on-success="handleSuccessUp" :show-file-list="false" |
| | | accept='.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar' |
| | | style="display: inline-block; margin-left: 10px;"> |
| | | <el-button :loading="upLoading" size="small" type="primary">导å
¥</el-button> |
| | | </el-upload> |
| | | <el-button size="small" style="margin-left: 10px;" type="primary" @click="openFormDia">æ° å¢</el-button> |
| | |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="年份" prop="laboratoryName"> |
| | | <el-input v-model="searchForm.distributionYear" clearable size="small"></el-input> |
| | | <el-date-picker |
| | | v-model="searchForm.distributionYear" |
| | | value-format="yyyy" |
| | | format="yyyy" |
| | | clearable |
| | | @change="searchList" |
| | | type="year" |
| | | placeholder="鿩年"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="åçé¨é¨" prop="occurrenceDepartment"> |
| | | <el-input v-model="searchForm.occurrenceDepartment" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">åçé¨é¨</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.occurrenceDepartment" |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | | <limsTable :column="tableColumn" :height="'calc(100vh - 19em)'" :table-data="tableData" |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true"> |
| | | <el-form-item label="æ£éªæ¥åç¼å·" prop="insReportCode"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.insReportCode" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 128px;font-size: 14px;font-weight: 700;color: #606266;">æ£éªæ¥åç¼å·</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.insReportCode" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading" v-if="outPower">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="openAdd" v-if="addPower">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="column" :tableLoading="tableLoading" :height="'calc(100vh - 270px)'" |
| | | :page="page" @pagination="pagination" :isSelection="true" |
| | | :handleSelectionChange="handleSelectionChange"></lims-table> |
| | | :page="page" @pagination="pagination"></lims-table> |
| | | </div> |
| | | <el-dialog :title="title" :visible.sync="addDialogVisible" width="400px" top="6vh"> |
| | | <el-row> |
| | |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">ç¾æ¶äººï¼</div> |
| | | <div class="search_input"> |
| | | <el-select v-model="addInfo.signatory" placeholder="è¯·éæ©" size="small" style="width: 100%;" multiple> |
| | | <el-option v-for="item in personList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="addInfo.signatory"></el-input></div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-bottom: 16px;"> |
| | |
| | | personList: [], |
| | | title: 'æ°å¢', |
| | | addDialogVisible: false, |
| | | addInfo: { |
| | | signatory: [] |
| | | }, |
| | | addInfo: {}, |
| | | addLoading: false, |
| | | mutilSelect: [], |
| | | queryParams: {}, |
| | | queryParams: { |
| | | insReportCode: '' |
| | | }, |
| | | tableData: [], |
| | | column: [ |
| | | { label: "æ£éªæ¥åç¼å·", prop: "insReportCode" }, |
| | |
| | | { label: "åéæ¹å¼", prop: "method" }, |
| | | { label: "å鿥æ", prop: "sendTime" }, |
| | | { label: "åé人", prop: "sendUserName" }, |
| | | { label: "ç¾æ¶äºº", prop: "signatoryName" }, |
| | | { label: "ç¾æ¶äºº", prop: "signatory" }, |
| | | { label: "夿³¨", prop: "remark" }, |
| | | { |
| | | dataType: "action", |
| | |
| | | ], |
| | | page: { |
| | | total: 0, |
| | | size: 10, |
| | | size: 20, |
| | | current: 0, |
| | | }, |
| | | tableLoading: false, |
| | |
| | | }, |
| | | methods: { |
| | | handleDown() { |
| | | if (this.mutilSelect.length == 0) { |
| | | this.$message.warning('è¯·éæ©è¦å¯¼åºçæ°æ®') |
| | | return |
| | | } |
| | | this.outLoading = true |
| | | exportProcessReport({ ids: this.mutilSelect.map(m => m.id) }).then(res => { |
| | | exportProcessReport(this.queryParams).then(res => { |
| | | this.outLoading = false |
| | | this.$download.saveAs(res.data, "æ¥åç»æ"); |
| | | const blob = new Blob([res], { type: 'application/msword' }); |
| | | this.$download.saveAs(blob, 'æ¥åç»æ' + '.docx'); |
| | | }) |
| | | }, |
| | | openAdd() { |
| | | this.title = 'æ°å¢' |
| | | this.addInfo = { |
| | | signatory: [] |
| | | } |
| | | this.addInfo = {} |
| | | this.addDialogVisible = true; |
| | | }, |
| | | getList() { |
| | |
| | | this.page.current = 1; |
| | | this.getList(); |
| | | }, |
| | | handleSelectionChange(val) { |
| | | this.mutilSelect = val |
| | | }, |
| | | getAuthorizedPerson() { |
| | | selectUserCondition().then(res => { |
| | | let data = [] |
| | |
| | | delete this.addInfo.createTime |
| | | delete this.addInfo.createUser |
| | | delete this.addInfo.updateTime |
| | | delete this.addInfo.signatoryUrl |
| | | delete this.addInfo.updateUserer |
| | | delete this.addInfo.sendUserName |
| | | let addInfo = this.HaveJson(this.addInfo) |
| | | addInfo.signatory = addInfo.signatory.join(',') |
| | | if (this.title == 'æ°å¢') { |
| | | addProcessReport(addInfo).then(res => { |
| | | addProcessReport(this.addInfo).then(res => { |
| | | this.addLoading = false |
| | | this.addDialogVisible = false |
| | | this.$message({ |
| | |
| | | this.refreshTable() |
| | | }).catch(err => { }) |
| | | } else { |
| | | doProcessReport(addInfo).then(res => { |
| | | doProcessReport(this.addInfo).then(res => { |
| | | this.addLoading = false |
| | | this.addDialogVisible = false |
| | | this.$message({ |
| | |
| | | this.title = 'ä¿®æ¹' |
| | | this.addInfo = row |
| | | console.log(this.addInfo) |
| | | this.addInfo.signatory = this.addInfo.signatory ? this.addInfo.signatory.split(',').map(m => Number(m)) : [] |
| | | this.addDialogVisible = true; |
| | | }, |
| | | handleChangeTask(list) { |
| | | this.mutilSelect = list |
| | | }, |
| | | handleDelete(row) { |
| | | this.$confirm("æ¯å¦å é¤è¯¥æ¡æ°æ®?", "æç¤º", { |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true"> |
| | | <el-form-item label="æ¥ååç§°" prop="reportName"> |
| | | <el-input v-model="queryParams.reportName" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">æ¥ååç§°</span> |
| | | <el-input v-model="queryParams.reportName" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="display: flex;align-items: center;"> |
| | | <div style="line-height: 30px;"> |
| | | <el-button :loading="outLoading" size="small" type="primary" style="margin-right: 10px" @click="handleDown0">导åº</el-button> |
| | | <el-upload ref='upload' :action="action" :headers="uploadHeader" :on-change="beforeUpload" :on-error="onError" |
| | | :on-success="handleSuccessUp" :show-file-list="false" |
| | | :on-success="handleSuccessUp" :show-file-list="false" style="display: inline-block;" |
| | | accept='.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar'> |
| | | <el-button :loading="upLoading" size="small" type="primary">导å
¥</el-button></el-upload> |
| | | </div> |
| | |
| | | <el-col :span="6" style="padding-left: 20px;text-align: left;">æ°éé
ç½®</el-col> |
| | | <el-col :span="18" style="text-align: right;"> |
| | | <el-button size="small" type="primary" @click="fileConfiguration">æä»¶é
ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="addItem">æ£éªé¡¹æ°å¢</el-button> |
| | | <el-button size="small" @click="$parent.closeDataVue()"> |
| | | <span style="color: #3A7BFA;">è¿å</span> |
| | | </el-button> |
| | |
| | | <div class="table"> |
| | | <el-table :data="tableList.slice((page.current - 1) * page.size,page.current * page.size)" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | tooltip-effect="dark" height="100%" :span-method="spanMethod"> |
| | | tooltip-effect="dark" height="100%"> |
| | | <el-table-column type="index" label="åºå·" align="center" width="65"></el-table-column> |
| | | <el-table-column prop="deviceName" align="center" min-width="100" label="设å¤åç§°"></el-table-column> |
| | | <el-table-column prop="fileType" align="center" label="æä»¶åç¼"></el-table-column> |
| | | <el-table-column prop="collectUrl" align="center" min-width="100" show-overflow-tooltip |
| | | label="ééå°å"></el-table-column> |
| | | <el-table-column prop="storageUrl" align="center" min-width="100" show-overflow-tooltip |
| | | label="åå¨å°å"></el-table-column> |
| | | <el-table-column prop="ip" align="center" label="IPå°å" min-width="100"></el-table-column> |
| | | <el-table-column prop="sample" align="center" label="æ£éªå¯¹è±¡" show-overflow-tooltip |
| | | min-width="150"></el-table-column> |
| | | <el-table-column prop="inspectionItemClass" align="center" label="æ£éªé¡¹åç±»" min-width="120"></el-table-column> |
| | |
| | | </el-row> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog title="æ°éé
ç½®" :visible.sync="dialogVisible4" width="400px"> |
| | | <el-dialog title="æä»¶é
ç½®" :visible.sync="dialogVisible4" width="400px"> |
| | | <div class="search_thing" style="margin-bottom: 14px;"> |
| | | <div class="search_label"> |
| | | <span style="color:red;margin-right: 4px;">*</span>IPï¼ |
| | |
| | | </el-row> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog title="æ·»å æ£éªé¡¹" :visible.sync="dialogVisible5" width="1000px"> |
| | | <lims-table :tableData="tableData5" :column="column5" |
| | | :isSelection="true" :handleSelectionChange="selectMethod" |
| | | height="540" :page="page5" :tableLoading="tableLoading5" |
| | | @pagination="pagination5"></lims-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="dialogVisible5 = false">å æ¶</el-button> |
| | | <el-button type="primary" @click="submitForm5" :loading="loading5">ä¿ å</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | queryDataAcquisitionConfiguration, |
| | | saveDataAcquisitionConfiguration, |
| | | deleteDataAcquisitionConfiguration, |
| | | getDeviceById, |
| | | saveDeviceFileConfiguration, |
| | | queryProductConfiguration, |
| | | getNoConfigProduct, |
| | | } from '@/api/cnas/resourceDemand/device.js' |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | export default { |
| | | name: "dataAcquisitionConfig", |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | | components: {}, |
| | | components: {limsTable}, |
| | | props: { |
| | | deviceId: { |
| | | type: Number, |
| | | default: () => [] |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.init(); |
| | | }, |
| | | data() { |
| | | // è¿éåæ¾æ°æ® |
| | |
| | | ] |
| | | } |
| | | }, |
| | | deleteList: [] |
| | | deleteList: [], |
| | | tableData5: [], |
| | | column5: [ |
| | | {label: 'æ ·ååç§°', prop: 'sample'}, |
| | | {label: 'æ£éªé¡¹åç±»', prop: 'inspectionItemClass'}, |
| | | {label: 'æ£éªé¡¹', prop: 'inspectionItem'}, |
| | | {label: 'æ£éªå项', prop: 'inspectionItemSubclass'}, |
| | | ], |
| | | page5: { |
| | | total:0, |
| | | size:20, |
| | | current:1 |
| | | }, |
| | | tableLoading5: false, |
| | | dialogVisible5: false, |
| | | loading5: false, |
| | | multipleSelection: [] |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.init(); |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | getIndexWithAlphabet(index) { |
| | | const alphabet = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'; |
| | | const letterIndex = index % 26; |
| | | return alphabet.charAt(letterIndex) + (index + 1); |
| | | }, |
| | | rowspan(spanArr, position, spanName) { |
| | | this.tableList.forEach((item, index) => { |
| | | if (index === 0) { |
| | | spanArr.push(1); |
| | | position = 0; |
| | | } else { |
| | | if ( |
| | | this.tableList[index][spanName] === |
| | | this.tableList[index - 1][spanName] |
| | | ) { |
| | | spanArr[position] += 1; |
| | | spanArr.push(0); |
| | | } else { |
| | | spanArr.push(1); |
| | | position = index; |
| | | } |
| | | } |
| | | }); |
| | | }, |
| | | spanMethod({ row, column, rowIndex, columnIndex }) { |
| | | // ä¸è¬çåå¹¶è¡ |
| | | if ( |
| | | this.spanConfig != undefined && |
| | | this.spanConfig.rows && |
| | | this.spanConfig.rows.length > 0 |
| | | ) { |
| | | let i = null; |
| | | let obj = this.spanConfig.rows.find((item, index) => { |
| | | i = index; |
| | | return item.index == columnIndex; |
| | | }); |
| | | if (obj) { |
| | | const _row = this.spanList[i].arr[rowIndex]; |
| | | const _col = _row > 0 ? 1 : 0; |
| | | return { |
| | | rowspan: _row, |
| | | colspan: _col |
| | | }; |
| | | } |
| | | } |
| | | // ç¹æ®çåå¹¶è¡ |
| | | if ( |
| | | this.spanConfig != undefined && |
| | | this.spanConfig.special && |
| | | this.spanConfig.special.main && |
| | | this.spanConfig.special.rows && |
| | | this.spanConfig.special.rows.length > 0 |
| | | ) { |
| | | let i = null; |
| | | let obj = this.spanConfig.special.rows.find((item, index) => { |
| | | i = index; |
| | | return item.index == columnIndex; |
| | | }); |
| | | if (obj) { |
| | | const _row = this.specialSpanList[i].arr[rowIndex]; |
| | | const _col = _row > 0 ? 1 : 0; |
| | | return { |
| | | rowspan: _row, |
| | | colspan: _col |
| | | }; |
| | | } |
| | | } |
| | | }, |
| | | fileConfiguration() { |
| | | this.dialogVisible4 = true; |
| | | if (this.tableList[0]) { |
| | | this.$set(this.configForm, "fileType", this.tableList[0].fileType); |
| | | this.$set(this.configForm, "collectUrl", this.tableList[0].collectUrl); |
| | | this.$set(this.configForm, "storageUrl", this.tableList[0].storageUrl); |
| | | this.$set(this.configForm, "ip", this.tableList[0].ip); |
| | | this.$set( |
| | | this.configForm, |
| | | "entrustCode", |
| | | this.tableList[0].entrustCode |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "sampleCode", |
| | | this.tableList[0].sampleCode |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "dbFileName", |
| | | this.tableList[0].dbFileName |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "fiberOpticRibbon", |
| | | this.tableList[0].fiberOpticRibbon |
| | | ) |
| | | } |
| | | }, |
| | | // æ¥è¯¢å表 |
| | | init() { |
| | | queryDataAcquisitionConfiguration({ deviceId: this.deviceId, isDevice: false }).then(res => { |
| | | queryDataAcquisitionConfiguration({ deviceId: this.deviceId }).then(res => { |
| | | this.tableList = res.data; |
| | | this.tableList.forEach(i => { |
| | | let isIncludes = false |
| | |
| | | if (!isIncludes && i.formula) { |
| | | i.formula = i.formula.slice(1, -1) |
| | | } |
| | | i.sample = i.sample |
| | | .replace(/"/g, "") |
| | | .replace(/],/g, "ï¼") |
| | | .replace(/\[/g, "") |
| | | .replace(/]/g, ""); |
| | | }); |
| | | if (this.tableList[0]) { |
| | | this.$set(this.configForm, "fileType", this.tableList[0].fileType); |
| | | this.$set( |
| | | this.configForm, |
| | | "collectUrl", |
| | | this.tableList[0].collectUrl |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "storageUrl", |
| | | this.tableList[0].storageUrl |
| | | ); |
| | | this.$set(this.configForm, "ip", this.tableList[0].ip); |
| | | this.$set( |
| | | this.configForm, |
| | | "entrustCode", |
| | | this.tableList[0].entrustCode |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "sampleCode", |
| | | this.tableList[0].sampleCode |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "dbFileName", |
| | | this.tableList[0].dbFileName |
| | | ); |
| | | this.$set( |
| | | this.configForm, |
| | | "fiberOpticRibbon", |
| | | this.tableList[0].fiberOpticRibbon |
| | | ) |
| | | } |
| | | // ä¸è¬çåå¹¶è¡ |
| | | if ( |
| | | this.spanConfig != undefined && |
| | | this.spanConfig.rows && |
| | | this.spanConfig.rows.length > 0 |
| | | ) { |
| | | this.spanList = []; |
| | | this.spanConfig.rows.forEach((item, index) => { |
| | | this.spanList.push({ |
| | | arr: [], |
| | | position: 0 |
| | | }); |
| | | this.rowspan( |
| | | this.spanList[index].arr, |
| | | this.spanList[index].position, |
| | | item.name |
| | | ); |
| | | }); |
| | | } |
| | | // ç¹æ®çåå¹¶è¡ |
| | | if ( |
| | | this.spanConfig != undefined && |
| | | this.spanConfig.special && |
| | | this.spanConfig.special.main && |
| | | this.spanConfig.special.rows && |
| | | this.spanConfig.special.rows.length > 0 |
| | | ) { |
| | | this.specialSpanList = []; |
| | | this.spanConfig.special.rows.forEach((item, index) => { |
| | | this.specialSpanList.push({ |
| | | arr: [], |
| | | position: 0 |
| | | }); |
| | | this.rowspan( |
| | | this.specialSpanList[index].arr, |
| | | this.specialSpanList[index].position, |
| | | this.spanConfig.special.main |
| | | ); |
| | | }); |
| | | } |
| | | |
| | | }); |
| | | }, |
| | | getIndexWithAlphabet(index) { |
| | | const alphabet = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'; |
| | | const letterIndex = index % 26; |
| | | return alphabet.charAt(letterIndex) + (index + 1); |
| | | }, |
| | | // æå¼æ°å¢æ£éªé¡¹å¼¹æ¡ |
| | | addItem () { |
| | | this.dialogVisible5 = true; |
| | | this.getList5() |
| | | }, |
| | | getList5() { |
| | | this.tableLoading5 = true; |
| | | getNoConfigProduct({deviceId: this.deviceId, ...this.page5 }).then(res => { |
| | | this.tableLoading5 = false; |
| | | this.tableData5 = res.data.records |
| | | this.page5.total = res.data.total |
| | | }).catch(err => { |
| | | this.tableLoading5 = false; |
| | | }) |
| | | }, |
| | | pagination5 (page) { |
| | | this.page5.size = page.limit |
| | | this.getList5() |
| | | }, |
| | | // è¡¨æ ¼éæ©æ¹æ³ |
| | | selectMethod(val) { |
| | | this.multipleSelection = val |
| | | }, |
| | | // æäº¤æ°å¢æ£éªé¡¹ |
| | | submitForm5 () { |
| | | this.loading5 = true; |
| | | saveDataAcquisitionConfiguration({ |
| | | deviceId: this.deviceId, |
| | | dataConfigList: this.multipleSelection, |
| | | }).then(res => { |
| | | this.loading5 = false; |
| | | this.dialogVisible5 = false; |
| | | this.init(); |
| | | this.$message.success("æ·»å æå"); |
| | | }).catch(err => { |
| | | this.loading5 = false; |
| | | }) |
| | | }, |
| | | // æå¼æä»¶é
ç½®å¼¹æ¡ |
| | | fileConfiguration() { |
| | | this.dialogVisible4 = true; |
| | | this.getInfo() |
| | | }, |
| | | // æ¥è¯¢æä»¶é
ç½®ä¿¡æ¯ |
| | | getInfo() { |
| | | getDeviceById({deviceId: this.deviceId}).then(res => { |
| | | this.$set(this.configForm, "fileType", res.data.fileType); |
| | | this.$set(this.configForm, "collectUrl", res.data.collectUrl); |
| | | this.$set(this.configForm, "storageUrl", res.data.storageUrl); |
| | | this.$set(this.configForm, "ip", res.data.ip); |
| | | this.$set(this.configForm, "entrustCode", res.data.entrustCode); |
| | | this.$set(this.configForm, "sampleCode", res.data.sampleCode); |
| | | this.$set(this.configForm, "dbFileName", res.data.dbFileName); |
| | | this.$set(this.configForm, "fiberOpticRibbon", res.data.fiberOpticRibbon) |
| | | }) |
| | | }, |
| | | // æäº¤æä»¶é
ç½® |
| | | submitForm4() { |
| | | const obj = Object.assign({ |
| | | deviceId: this.deviceId, |
| | |
| | | collectUrl: this.configForm.collectUrl, |
| | | storageUrl: this.configForm.storageUrl, |
| | | ip: this.configForm.ip, |
| | | isDevice: true, |
| | | entrustCode: this.configForm.entrustCode, |
| | | sampleCode: this.configForm.sampleCode, |
| | | dbFileName: this.configForm.dbFileName, |
| | | fiberOpticRibbon: this.configForm.fiberOpticRibbon |
| | | }); |
| | | this.upLoad4 = true; |
| | | saveDataAcquisitionConfiguration({ deviceId: this.deviceId, ...obj }).then(res => { |
| | | saveDeviceFileConfiguration({ deviceId: this.deviceId, ...obj }).then(res => { |
| | | if (res.code == 200) { |
| | | // this.tableList = res.data; |
| | | this.dialogVisible4 = false; |
| | | this.init(); |
| | | this.$message.success("æä½æå"); |
| | |
| | | this.upLoad4 = false; |
| | | }); |
| | | }, |
| | | // æå¼æ°éé
ç½®å¼¹æ¡ |
| | | dataConfig(row) { |
| | | this.configForm = { |
| | | deviceId: row.deviceId, |
| | |
| | | inspectionItemClass: row.inspectionItemClass, |
| | | }; |
| | | this.dialogVisible3 = true; |
| | | queryDataAcquisitionConfiguration({ |
| | | queryProductConfiguration({ |
| | | deviceId: this.deviceId, |
| | | inspectionItem: row.inspectionItem.trim(), |
| | | isDevice: true, |
| | |
| | | } |
| | | }); |
| | | }, |
| | | // æäº¤æ°éé
ç½® |
| | | submitForm3() { |
| | | this.$refs.configForm.validate(valid => { |
| | | // è¡¨åæ ¡éª |
| | |
| | | </div> |
| | | <div style="margin: 10px 0"> |
| | | <el-table ref="yearTable" :data="examinePlanDetailsList" id="templateParamTable" row-key="deviceId" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border height="500px" style="width: 100% ;"> |
| | | v-loading="yearTableLoading" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border height="560px"> |
| | | <el-table-column label="设å¤åç§°" min-width="190" prop="deviceName"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.deviceName" clearable size="small"></el-input> |
| | |
| | | planId: '', |
| | | examinePlanDetailsList: [], |
| | | }, |
| | | operationType: '' |
| | | operationType: '', |
| | | yearTableLoading: false |
| | | } |
| | | }, |
| | | mounted() { |
| | |
| | | planYear: '', |
| | | examinePlanDetailsList: [], |
| | | } |
| | | this.examinePlanDetailsList = [] |
| | | } else { |
| | | this.getRowInfo(row) |
| | | } |
| | |
| | | this.getUserList() |
| | | }, |
| | | getRowInfo(row) { |
| | | this.yearTableLoading = true |
| | | getDeviceExaminePlan({ planId: row.planId }).then(res => { |
| | | this.yearTableLoading = false |
| | | if (res.code == 200) { |
| | | this.examinePlanDetailsList = res.data.examinePlanDetailsList |
| | | this.form.planName = res.data.planName |
| | | this.form.planYear = res.data.planYear |
| | | this.form.planId = res.data.planId |
| | | } |
| | | }).catch(error => { |
| | | this.yearTableLoading = false |
| | | }) |
| | | }, |
| | | // æ·»å è®¾å¤ |
| | |
| | | </el-date-picker> |
| | | </div> |
| | | <div style="margin: 10px 0"> |
| | | <el-table id="templateParamTable" ref="yearTable" :data="calibrationPlanDetailList" height="300px" |
| | | <el-table id="templateParamTable" ref="yearTable" :data="calibrationPlanDetailList" height="560px" |
| | | v-loading="yearTableLoading" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | row-key="deviceId" style="width: 100% ;"> |
| | | <el-table-column label="设å¤åç§°ååå·" min-width="190" prop="deviceName"> |
| | |
| | | planId: '', |
| | | calibrationPlanDetailList: [], |
| | | }, |
| | | operationType: '' |
| | | operationType: '', |
| | | yearTableLoading: false |
| | | } |
| | | }, |
| | | mounted() { |
| | |
| | | this.form = { |
| | | planName: '', |
| | | planYear: '', |
| | | examinePlanDetailsList: [], |
| | | calibrationPlanDetailList: [], |
| | | } |
| | | this.calibrationPlanDetailList = [] |
| | | } else { |
| | | this.getRowInfo(row) |
| | | } |
| | | this.applicationForm = true |
| | | }, |
| | | getRowInfo(row) { |
| | | this.yearTableLoading = true |
| | | getDeviceCalibrationPlan({ planId: row.planId }).then(res => { |
| | | this.yearTableLoading = false |
| | | if (res.code == 200) { |
| | | this.calibrationPlanDetailList = res.data.calibrationPlanDetailList |
| | | this.form.planName = res.data.planName |
| | | this.form.planYear = res.data.planYear |
| | | this.form.planId = res.data.planId |
| | | } |
| | | }).catch(err => { |
| | | this.yearTableLoading = false |
| | | }) |
| | | }, |
| | | // æ·»å è®¾å¤ |
| | |
| | | }, |
| | | changeMachineName() { |
| | | this.selectionRows.map(val => { |
| | | // å° val.nextCalibrationDate 转æ¢ä¸º Date 对象并åå» 5 天 |
| | | let nextCalibrationDate = val.nextCalibrationDate ? new Date(val.nextCalibrationDate) : null; |
| | | if (nextCalibrationDate) { |
| | | nextCalibrationDate.setDate(nextCalibrationDate.getDate() - 5); // åå» 5 天 |
| | | } |
| | | this.calibrationPlanDetailList.push({ |
| | | deviceId: val.id, deviceName: val.label, deviceNumber: val.value, |
| | | specificationModel: val.specificationModel, verificationCycles: val.calibrationDate, lastDate: val.lastCalibrationDate.substring(0, 10), planDate: val.nextCalibrationDate.substring(0, 10) |
| | | specificationModel: val.specificationModel, |
| | | verificationCycles: val.calibrationDate, |
| | | lastDate: val.lastCalibrationDate && val.lastCalibrationDate.substring(0, 10), |
| | | planDate: nextCalibrationDate ? formatDate(nextCalibrationDate) : null, |
| | | verificationUnit: val.calibrationServices, |
| | | deviceAmount: 1 |
| | | }) |
| | | }) |
| | | this.addEquipDia = false |
| | |
| | | }, |
| | | }, |
| | | } |
| | | // æ ¼å¼åæ¥æä¸º YYYY-MM-DD æ ¼å¼ |
| | | function formatDate(date) { |
| | | const year = date.getFullYear(); |
| | | const month = String(date.getMonth() + 1).padStart(2, '0'); // æä»½ä»0å¼å§ï¼éè¦+1 |
| | | const day = String(date.getDate()).padStart(2, '0'); |
| | | return `${year}-${month}-${day}`; |
| | | } |
| | | </script> |
| | | |
| | | <style scoped></style> |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æµç¨ç¼å·ï¼</div> |
| | | <div><el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.processNumber" |
| | | @keyup.enter.native="refreshTable()"></el-input></div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px;"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </div> |
| | | <div class="btns"> |
| | | <el-form :model="queryParams" ref="queryParams" size="small" :inline="true"> |
| | | <el-form-item label="æµç¨ç¼å·"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.processNumber" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="mini" type="primary" @click="refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="add">æ°å¢</el-button> |
| | | <!-- <el-button size="small" type="primary" @click="handleDown" :loading="outLoading">导åº</el-button>--> |
| | | </div> |
| | | </div> |
| | | <div class="tables" style="margin-top: 10px;"> |
| | | <div class="tables"> |
| | | <lims-table :tableData="tableData" :column="column" :tableLoading="tableLoading" :height="'calc(100vh - 290px)'" |
| | | :page="page" @pagination="pagination"></lims-table> |
| | | <!-- <ValueTable ref="ValueTable" :url="$api.deviceBorrow.deviceBorrowPage" |
| | | :delUrl="$api.deviceBorrow.deleteDeviceBorrow" :componentData="componentData" :key="upIndex" /> --> |
| | | </div> |
| | | <el-dialog title="仪å¨è®¾å¤é¢(å)ç¨ç»è®°" top="5vh" :visible.sync="dialogVisible" width="60%"> |
| | | <el-steps :active="currentStep" finish-status="success" align-center> |
| | |
| | | <el-col :span="12"> |
| | | <el-form-item label="å½è¿äººï¼" prop="rebackUser" |
| | | :rules="[{ required: currentStep === 1, message: '请è¾å
¥å½è¿äºº', trigger: 'change' }]"> |
| | | <!-- <el-input v-model="form.rebackUser" size="small" :disabled="currentStep !== 1"></el-input> --> |
| | | <el-select v-model="form.rebackUser" filterable placeholder="è¯·éæ©" clearable size="small" |
| | | style="width: 50%;" :disabled="currentStep !== 1"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.name"> |
| | |
| | | <el-col :span="12"> |
| | | <el-form-item label="设å¤è´è´£äººï¼" prop="deviceUser" |
| | | :rules="[{ required: currentStep === 1, message: 'è¯·éæ©è®¾å¤è´è´£äºº', trigger: 'change' }]"> |
| | | <!-- <el-input v-model="form.deviceUser" size="small" :disabled="currentStep !== 1"></el-input> --> |
| | | <el-select v-model="form.deviceUser" filterable placeholder="è¯·éæ©" clearable size="small" |
| | | style="width: 50%;" :disabled="currentStep !== 1"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.name"> |
| | |
| | | <el-input type="textarea" v-model="form.note" :disabled="currentStep !== 1" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | |
| | | </el-row> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | h4 { |
| | | font-weight: 400; |
| | | font-size: 16px; |
| | | .search { |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | margin: 10px 0; |
| | | } |
| | | |
| | | h4 .line { |
| | | display: inline-block; |
| | | width: 3px; |
| | | height: 16px; |
| | | background: #3A7BFA; |
| | | margin-right: 4px; |
| | | } |
| | | |
| | | .tables { |
| | | width: 100%; |
| | | height: calc(100vh - 15em); |
| | | } |
| | | |
| | | .search { |
| | | background-color: #fff; |
| | | display: flex; |
| | | align-items: center; |
| | | position: relative; |
| | | margin-top: 10px; |
| | | } |
| | | |
| | | .search_thing { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 40px; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 70px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 120px); |
| | | } |
| | | |
| | | .btns { |
| | | position: absolute; |
| | | right: 0px; |
| | | top: 50%; |
| | | transform: translate(0, -50%); |
| | | } |
| | | |
| | | .btns_thing { |
| | | position: absolute; |
| | | right: 230px; |
| | | top: 50%; |
| | | transform: translate(0, -50%); |
| | | } |
| | | |
| | | .form .search_label { |
| | | width: 120px; |
| | | } |
| | | |
| | | .el-radio { |
| | | margin-right: 10px; |
| | | } |
| | | |
| | | .el-radio-group { |
| | | width: 100%; |
| | | display: flex; |
| | | margin-top: 12px; |
| | | } |
| | | </style> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="search.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="search.total" layout="->,total, sizes, prev, pager, next, jumper" style="margin-right: 5%;" |
| | | @size-change="handleSizeChange" @current-change="handleCurrentChange"> |
| | | :total="search.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | @size-change="handleSizeChange" @current-change="handleCurrentChange" background> |
| | | </el-pagination> |
| | | </div> |
| | | <!-- æ ¡å项ç®ç»´æ¤ --> |
| | |
| | | </el-row> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="resetForm">å æ¶</el-button> |
| | | <el-button v-if="currentStep === 0" :loading="submitFormLoading" type="primary" @click="submitCheck">ç¡® |
| | | <el-button v-if="currentStep === 0 && checkChargerUserId == userId" :loading="submitFormLoading" type="primary" @click="submitCheck">ç¡® |
| | | å®</el-button> |
| | | <el-button v-if="currentStep === 1" :loading="submitFormLoading" @click="examine(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1" :loading="submitFormLoading" type="primary" @click="examine(1)">é |
| | | <el-button v-if="currentStep === 1 && userId == reviewUserId" :loading="submitFormLoading" @click="examine(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == reviewUserId" :loading="submitFormLoading" type="primary" @click="examine(1)">é |
| | | è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | |
| | | deviceScopeSearch, |
| | | } from '@/api/cnas/resourceDemand/device.js' |
| | | import { selectUserCondition } from "@/api/performance/class"; |
| | | import {mapGetters} from "vuex"; |
| | | export default { |
| | | name: "check-record", |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | |
| | | determine: '', |
| | | remark: '', |
| | | planDetailsId: '', |
| | | checkerUserId: '', |
| | | reviewUserId: '', |
| | | }, |
| | | currentStep: 0, |
| | | distributionDetailList: [ |
| | |
| | | equipOptions: [], |
| | | submitFormLoading: false, |
| | | userList: [], |
| | | reviewUserId: '', |
| | | checkChargerUserId: '', |
| | | } |
| | | }, |
| | | mounted() { |
| | | |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | openDialog(row) { |
| | | this.dialogVisible = true |
| | | this.form.planDetailsId = row.planDetailsId |
| | | this.checkChargerUserId = row.checkChargerUserId |
| | | this.getEquipOptions() |
| | | this.getUserList() |
| | | this.searchInfo() |
| | |
| | | this.form = { ...res.data } |
| | | this.form.planDetailsId = planDetailsId |
| | | this.recordDetailList = this.form.recordDetailList || [] |
| | | if (!this.form.checkerUserId) { |
| | | if (!this.form.reviewUserId) { |
| | | this.currentStep = 0 |
| | | } else { |
| | | this.currentStep = 1 |
| | |
| | | if (this.form.reviewStatus === 1) { |
| | | this.currentStep = 2 |
| | | } |
| | | this.reviewUserId = this.form.reviewUserId |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | |
| | | <!-- è®¾å¤æ»è§ --> |
| | | <style scoped> |
| | | .title { |
| | | height: 60px; |
| | | line-height: 60px; |
| | | } |
| | | |
| | | .search { |
| | | background-color: #fff; |
| | | height: 50px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 350px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 110px; |
| | | font-size: 14px; |
| | | text-align: left; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 110px); |
| | | } |
| | | |
| | | .table { |
| | | background-color: #fff; |
| | | height: calc(100vh - 17em); |
| | | /* padding: 10px; */ |
| | | overflow-y: auto; |
| | | } |
| | | |
| | | .card { |
| | | list-style-type: none; |
| | | display: grid; |
| | | grid-template-columns: repeat(auto-fit, 330px); |
| | | justify-content: start; |
| | | grid-gap: 16px; |
| | | min-height: 300px; |
| | | padding-left: 0; |
| | | } |
| | | |
| | | .card li { |
| | | width: 330px; |
| | | height: 165px; |
| | | border-radius: 8px 8px 8px 8px; |
| | | border: 1px solid #EEEEEE; |
| | | margin: 0 !important; |
| | | display: flex; |
| | | align-items: center; |
| | | box-sizing: border-box; |
| | | padding: 16px; |
| | | font-size: 14px; |
| | | color: #666666; |
| | | position: relative; |
| | | overflow: hidden; |
| | | } |
| | | |
| | | .card li .img { |
| | | width: 90px; |
| | | height: 90px; |
| | | border-radius: 16px; |
| | | margin-right: 10px; |
| | | } |
| | | |
| | | .list-left .list-left-info { |
| | | line-height: 36px; |
| | | display: flex; |
| | | } |
| | | |
| | | .text-truncate { |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | white-space: nowrap |
| | | } |
| | | |
| | | .circles { |
| | | position: absolute; |
| | | width: 70px; |
| | | height: 70px; |
| | | right: 0; |
| | | top: 0; |
| | | z-index: 0; |
| | | } |
| | | |
| | | .circles .circle { |
| | | border-radius: 50%; |
| | | opacity: 0.2; |
| | | } |
| | | |
| | | .circle0, |
| | | .circle1, |
| | | .circle2 { |
| | | width: 60px; |
| | | height: 60px; |
| | | position: absolute; |
| | | } |
| | | |
| | | .circle3 { |
| | | width: 16px; |
| | | height: 16px; |
| | | position: absolute; |
| | | } |
| | | |
| | | .circle0 { |
| | | bottom: 6px; |
| | | left: 0; |
| | | } |
| | | |
| | | .circle1 { |
| | | bottom: 0; |
| | | right: -30px; |
| | | } |
| | | |
| | | .circle2 { |
| | | left: 0; |
| | | top: -30px; |
| | | } |
| | | |
| | | .circle3 { |
| | | top: 0; |
| | | right: 0; |
| | | } |
| | | |
| | | .success .circle { |
| | | background: #34BD66; |
| | | } |
| | | |
| | | .danger .circle { |
| | | background: #FF3838; |
| | | } |
| | | |
| | | .warning .circle { |
| | | background: #FBB247; |
| | | } |
| | | |
| | | .info .circle { |
| | | background: #909399; |
| | | } |
| | | |
| | | .el-form-item { |
| | | margin-top: 11px; |
| | | margin-bottom: 11px; |
| | | } |
| | | </style> |
| | | |
| | | <template> |
| | | <div class="role_manage"> |
| | | <div> |
| | | <el-form :model="entity" inline label-position="right" label-width="80px"> |
| | | <el-form-item label="ç¶æ:"> |
| | | <el-select v-model="entity.deviceStatus" placeholder="å
¨é¨" size="small" clearable> |
| | | <div style="display: flex;justify-content: space-between;margin-top: 10px;"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 48px;font-size: 14px;font-weight: 700;color: #606266;">ç¶æ</span> |
| | | <el-select v-model="entity.deviceStatus" placeholder="å
¨é¨" |
| | | @change="currentPage = 1, keyMap = {}, list = [], finishLoding = false, refreshTable()" |
| | | size="small" clearable> |
| | | <el-option v-for="item in options" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="设å¤åç§°:"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.deviceName"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" type="primary" |
| | | @click="currentPage = 1, keyMap = {}, list = [], finishLoding = false, refreshTable()">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">设å¤åç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.deviceName" |
| | | @keyup.enter.native="currentPage = 1, keyMap = {}, list = [], finishLoding = false, refreshTable()"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="mini" type="primary" @click="currentPage = 1, keyMap = {}, list = [], finishLoding = false, refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <div class="table" v-loading="loading"> |
| | | <scroll-pagination @load="refreshTable()" :finishLoding="finishLoding" :list="list" |
| | |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | .table { |
| | | background-color: #fff; |
| | | height: calc(100vh - 17em); |
| | | /* padding: 10px; */ |
| | | overflow-y: auto; |
| | | } |
| | | |
| | | .card { |
| | | list-style-type: none; |
| | | display: grid; |
| | | grid-template-columns: repeat(auto-fit, 330px); |
| | | justify-content: start; |
| | | grid-gap: 16px; |
| | | min-height: 300px; |
| | | padding-left: 0; |
| | | } |
| | | |
| | | .card li { |
| | | width: 330px; |
| | | height: 165px; |
| | | border-radius: 8px 8px 8px 8px; |
| | | border: 1px solid #EEEEEE; |
| | | margin: 0 !important; |
| | | display: flex; |
| | | align-items: center; |
| | | box-sizing: border-box; |
| | | padding: 16px; |
| | | font-size: 14px; |
| | | color: #666666; |
| | | position: relative; |
| | | overflow: hidden; |
| | | } |
| | | |
| | | .card li .img { |
| | | width: 90px; |
| | | height: 90px; |
| | | border-radius: 16px; |
| | | margin-right: 10px; |
| | | } |
| | | |
| | | .list-left .list-left-info { |
| | | line-height: 36px; |
| | | display: flex; |
| | | } |
| | | |
| | | .text-truncate { |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | | white-space: nowrap |
| | | } |
| | | |
| | | .circles { |
| | | position: absolute; |
| | | width: 70px; |
| | | height: 70px; |
| | | right: 0; |
| | | top: 0; |
| | | z-index: 0; |
| | | } |
| | | |
| | | .circles .circle { |
| | | border-radius: 50%; |
| | | opacity: 0.2; |
| | | } |
| | | |
| | | .circle0, |
| | | .circle1, |
| | | .circle2 { |
| | | width: 60px; |
| | | height: 60px; |
| | | position: absolute; |
| | | } |
| | | |
| | | .circle3 { |
| | | width: 16px; |
| | | height: 16px; |
| | | position: absolute; |
| | | } |
| | | |
| | | .circle0 { |
| | | bottom: 6px; |
| | | left: 0; |
| | | } |
| | | |
| | | .circle1 { |
| | | bottom: 0; |
| | | right: -30px; |
| | | } |
| | | |
| | | .circle2 { |
| | | left: 0; |
| | | top: -30px; |
| | | } |
| | | |
| | | .circle3 { |
| | | top: 0; |
| | | right: 0; |
| | | } |
| | | |
| | | .success .circle { |
| | | background: #34BD66; |
| | | } |
| | | |
| | | .danger .circle { |
| | | background: #FF3838; |
| | | } |
| | | |
| | | .warning .circle { |
| | | background: #FBB247; |
| | | } |
| | | |
| | | .info .circle { |
| | | background: #909399; |
| | | } |
| | | |
| | | .el-form-item { |
| | | margin-top: 11px; |
| | | margin-bottom: 11px; |
| | | } |
| | | </style> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | <div> |
| | | <div> |
| | | <div style="margin: 10px 0;display: flex;align-items: center;justify-content: space-between;"> |
| | | <span>年度计å表</span> |
| | | <div class="title"> |
| | | <span style="font-weight: bold">年度计å表</span> |
| | | </div> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="getYearTableData">å·æ°</el-button> |
| | | <el-button style="margin-right: 10px" size="small" type="primary" @click="addYearPlan('add')">æ°å¢</el-button> |
| | | <el-button size="small" type="primary" @click="addYearPlan('add')">æ°å¢</el-button> |
| | | <!-- <el-button size="small" type="primary" @click="record">导å
¥</el-button>--> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <el-table ref="yearTable" v-loading="yearTableDataLoading" :data="yearTableData" height="calc(60vh - 20em)" |
| | | <el-table ref="yearTable" v-loading="yearTableDataLoading" |
| | | :data="yearTableData" height="calc(60vh - 16em)" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | highlight-current-row style="width: 100% ;" @current-change="currentChange"> |
| | | highlight-current-row @current-change="currentChange"> |
| | | <!-- è¡¨æ ¼å --> |
| | | <el-table-column align="center" header-align="center" label="åºå·" prop="prop" type="index" |
| | | width="70"></el-table-column> |
| | | <el-table-column label="年份" min-width="80" prop="planYear"></el-table-column> |
| | | <el-table-column label="计ååç§°" min-width="180" prop="planName"></el-table-column> |
| | | <el-table-column label="计ååç§°" min-width="180" prop="planName" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="ç¼å¶äºº" min-width="100" prop="writeName"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¥æ" min-width="150" prop="writeTime"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¥æ" min-width="160" prop="writeTime"></el-table-column> |
| | | <el-table-column label="æ¹åç¶æ" min-width="100" prop="ratifyStatus"> |
| | | <template slot-scope="scope"> |
| | | <el-tag v-if="scope.row.ratifyStatus === 1" type="success">æ¹å</el-tag> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination.total" layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange"> |
| | | background :total="pagination.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | @size-change="handleSizeChange" @current-change="handleCurrentChange"> |
| | | </el-pagination> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <span>年度计åæç»è¡¨</span> |
| | | <div class="title"> |
| | | <div class="title-search"> |
| | | <span style="width: 120px;font-size: 14px">设å¤åç§°ååå·ï¼</span> |
| | | <el-input v-model="searchForm.deviceName" clearable size="small" |
| | | style="margin-right: 10px;width: 220px"></el-input> |
| | | <span style="width: 80px;font-size: 14px">仪å¨ç¼å·ï¼</span> |
| | | <el-input v-model="searchForm.deviceNumber" clearable size="small" |
| | | style="margin-right: 10px;width: 220px"></el-input> |
| | | <el-button size="small" type="primary" @click="getYearTableDetailData(currentRow)">æ¥ è¯¢</el-button> |
| | | <el-button size="small" @click="reset">é ç½®</el-button> |
| | | <span style="font-weight: bold">年度计åæç»è¡¨</span> |
| | | </div> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="设å¤åç§°ååå·" prop="deviceName"> |
| | | <el-input v-model="searchForm.deviceName" clearable |
| | | @keyup.enter.native="getYearTableDetailData(currentRow)" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="仪å¨ç¼å·" prop="deviceNumber"> |
| | | <el-input v-model="searchForm.deviceNumber" |
| | | @keyup.enter.native="getYearTableDetailData(currentRow)" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="getYearTableDetailData(currentRow)">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="reset">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="handleForm('add')">æ°å¢</el-button> |
| | |
| | | <div> |
| | | <el-table ref="yearTableDetailData" v-loading="yearTableDetailDataLoading" :data="yearTableDetailData" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | height="calc(60vh - 20em)" style="width: 100% ;"> |
| | | :height="'calc(100vh - 34em)'" style="width: 100% ;"> |
| | | <!-- è¡¨æ ¼å --> |
| | | <el-table-column align="center" header-align="center" label="åºå·" prop="prop" type="index" |
| | | width="70"></el-table-column> |
| | | <el-table-column label="设å¤åç§°ååå·" min-width="180" prop="deviceName"></el-table-column> |
| | | <el-table-column label="设å¤åç§°ååå·" min-width="180" prop="deviceName" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="è®¾å¤æ°é" min-width="180" prop="deviceAmount"></el-table-column> |
| | | <el-table-column label="仪å¨ç¼å·" min-width="150" prop="deviceNumber"></el-table-column> |
| | | <el-table-column label="æ£å®åä½" min-width="150" prop="verificationUnit"> </el-table-column> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | background :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | | </div> |
| | |
| | | |
| | | <style scoped> |
| | | .title { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | position: relative; |
| | | font-size: 16px; |
| | | color: #333; |
| | | font-weight: 400; |
| | | padding-left: 10px; |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | .title-search { |
| | | .title::before { |
| | | position: absolute; |
| | | left: 0; |
| | | top: 4px; |
| | | content: ''; |
| | | width: 4px; |
| | | height: 16px; |
| | | background-color: #3A7BFA; |
| | | border-radius: 2px; |
| | | } |
| | | .search { |
| | | height: 46px; |
| | | display: flex; |
| | | align-items: center; |
| | | margin: 10px 0; |
| | | justify-content: space-between; |
| | | } |
| | | </style> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="resetForm">å æ¶</el-button> |
| | | <el-button v-if="currentStep === 0" :loading="submitFormLoading" type="primary" @click="submitCheck">ç¡® |
| | | <el-button v-if="currentStep === 0 && userId == checkChargerUserId" :loading="submitFormLoading" type="primary" @click="submitCheck">ç¡® |
| | | å®</el-button> |
| | | <el-button v-if="currentStep === 1" :loading="submitFormLoading" @click="examine(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1" :loading="submitFormLoading" type="primary" @click="examine(1)">é |
| | | <el-button v-if="currentStep === 1 && userId == reviewUserId" :loading="submitFormLoading" @click="examine(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="currentStep === 1 && userId == reviewUserId" :loading="submitFormLoading" type="primary" @click="examine(1)">é |
| | | è¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | |
| | | addExamineRecordContrast, |
| | | } from '@/api/cnas/resourceDemand/device.js' |
| | | import { selectUserCondition } from "@/api/business/inspectionTask"; |
| | | import {mapGetters} from "vuex"; |
| | | export default { |
| | | name: "equipment-check", |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | |
| | | equipOptions: [], |
| | | recordContrastDetailsList: [], |
| | | userList: [], |
| | | checkChargerUserId: '', |
| | | reviewUserId: '' |
| | | } |
| | | }, |
| | | mounted() { |
| | | |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | openDialog(row) { |
| | | this.dialogVisible = true |
| | | this.form.planDetailsId = row.planDetailsId |
| | | this.checkChargerUserId = row.checkChargerUserId |
| | | this.getEquipOptions() |
| | | this.getUserList() |
| | | this.searchInfo() |
| | |
| | | if (this.form.reviewStatus === 1) { |
| | | this.currentStep = 2 |
| | | } |
| | | this.reviewUserId = this.form.reviewUserId |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <el-button size="small" type="primary" @click="refreshTableList">å·æ°</el-button> |
| | | <el-button size="small" type="primary" @click="openDia('add')">æ° å»º</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="openHandleOut">导 åº</el-button> |
| | | </div> |
| | | <div> |
| | | <lims-table :tableData="tableData" :column="column" |
| | | height="calc(100vh - 20em)" @pagination="pagination" |
| | | :page="page" :tableLoading="tableLoading"></lims-table> |
| | | </div> |
| | | <el-dialog :visible.sync="dialogVisible" title="仪å¨è®¾å¤ä½¿ç¨ç»´æ¤ä¿å
»è¡¨" width="55%"> |
| | | <el-form ref="form" :model="form" label-width="130px" :rules="rules"> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="ç»´æ¤æ¥æ:" prop="maintenanceDate"> |
| | | <el-date-picker v-model="form.maintenanceDate" :disabled="operationType === 'view'" |
| | | format="yyyy-MM-dd" size="small" placeholder="éæ©æ¥æ" style="width:100%" |
| | | type="date" value-format="yyyy-MM-dd"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="ç»´æ¤å
容:" prop="maintenanceContentArr"> |
| | | <el-checkbox-group v-model="form.maintenanceContentArr" :disabled="operationType === 'view'"> |
| | | <el-checkbox v-for="city in qualificationList" :key="city.label" :label="city.label" |
| | | :value="city.label"></el-checkbox> |
| | | </el-checkbox-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="ç»´æ¤äºº:" prop="maintenanceUserId"> |
| | | <el-select v-model="form.maintenanceUserId" |
| | | clearable filterable |
| | | placeholder="è¯·éæ©" size="small" style="width: 100%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="夿³¨:" prop="remark"> |
| | | <el-input v-model="form.remark" :disabled="operationType === 'view'" size="small" |
| | | style="width: 100%;"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeDia">å æ¶</el-button> |
| | | <el-button v-if="operationType !== 'view'" type="primary" @click="saveRecord" :loading="buttonLoading">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { |
| | | addDeviceMaintenance, |
| | | deleteDeviceMaintenance, exportDeviceMaintenance, |
| | | selectDeviceMaintenancePage |
| | | } from "@/api/cnas/resourceDemand/device"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import {selectUserCondition} from "@/api/system/user"; |
| | | |
| | | export default { |
| | | name: '', |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | | components: {limsTable}, |
| | | props: { |
| | | clickNodeVal: { |
| | | type: Object, |
| | | default: () => { |
| | | return {}; |
| | | } |
| | | }, |
| | | }, |
| | | data() { |
| | | // è¿éåæ¾æ°æ® |
| | | return { |
| | | search: { |
| | | maintenanceDate: '', |
| | | }, |
| | | outLoading: false, |
| | | tableData: [], |
| | | tableLoading: false, |
| | | page: { |
| | | total: 0, |
| | | size: 20, |
| | | current: 1 |
| | | }, |
| | | column: [ |
| | | { label: 'ç»´æ¤æ¥æ', prop: 'maintenanceDate' }, |
| | | { label: 'ç»´æ¤å
容', prop: 'maintenanceContent' }, |
| | | { label: 'ç»´æ¤äºº', prop: 'maintenanceUserName' }, |
| | | { label: '夿³¨', prop: 'remark' }, |
| | | { |
| | | dataType: 'action', |
| | | label: 'æä½', |
| | | operation: [ |
| | | { |
| | | name: 'ç¼è¾', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.openDia('edit', row); |
| | | }, |
| | | }, |
| | | { |
| | | name: 'å é¤', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.handleDeleteClick(row); |
| | | }, |
| | | }, |
| | | ] |
| | | } |
| | | ], |
| | | dialogVisible: false, |
| | | form: { |
| | | id: '', |
| | | deviceId: '', |
| | | maintenanceDate: '', |
| | | maintenanceContentArr: [], |
| | | maintenanceContent: '', |
| | | maintenanceUserId: '', |
| | | remark: '', |
| | | }, |
| | | operationType: '', |
| | | buttonLoading: false, |
| | | qualificationList: [], |
| | | rules: { |
| | | maintenanceDate: [{ required: true, message: 'è¯·éæ©ç»´æ¤æ¥æ', trigger: 'change' }], |
| | | maintenanceContentArr: [{ required: true, message: 'è¯·éæ©ç»´æ¤å
容', trigger: 'change' }], |
| | | maintenanceUserId: [{ required: true, message: 'è¯·éæ©ç»´æ¤äºº', trigger: 'change' }], |
| | | }, |
| | | responsibleOptions: [], |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.refreshTableList() |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | // ç¹å»å·æ° |
| | | refreshTableList () { |
| | | this.page.current = 1; |
| | | this.getTableList() |
| | | }, |
| | | // å页忢 |
| | | pagination(page) { |
| | | this.page.size = page.limit |
| | | this.getTableList() |
| | | }, |
| | | getTableList () { |
| | | this.tableLoading = true |
| | | selectDeviceMaintenancePage({ |
| | | deviceId: this.clickNodeVal.value, |
| | | ...this.page |
| | | }).then(res => { |
| | | this.tableLoading = false |
| | | this.tableData = res.data.records |
| | | this.page.total = res.data.total |
| | | }).catch(err => { |
| | | this.tableLoading = false |
| | | }) |
| | | }, |
| | | // æå¼æä½å¼¹æ¡ |
| | | openDia (type, row) { |
| | | this.operationType = type |
| | | this.dialogVisible = true |
| | | this.$nextTick(() => { |
| | | this.$refs['form'].resetFields() |
| | | this.form.id = '' |
| | | if (this.operationType === 'edit') { |
| | | this.form = {...row} |
| | | this.$set(this.form, 'maintenanceContentArr', this.form.maintenanceContent.split(',')) |
| | | } |
| | | }) |
| | | this.getDictS() |
| | | this.getUserList() |
| | | }, |
| | | // æ¥è¯¢ç»´æ¤å
容鿩æ¡å
容 |
| | | getDictS () { |
| | | // å®ä¹å®éªå®¤åç§°ä¸ç»´æ¤å
容类åçæ å°å
³ç³» |
| | | const labTypeMapping = { |
| | | 'èå室': 'aging_maintenance_content', |
| | | 'èåå®éªå®¤': 'aging_maintenance_content', |
| | | 'çµæ§è½å®éªå®¤': 'electrical_maintenance_content', |
| | | 'ç¯å¢å®éªå®¤': 'environmental_maintenance_content', |
| | | 'çç§å®éªå®¤': 'burn_maintenance_content', |
| | | 'æ··ç¼å®éªå®¤': 'mixing_maintenance_content', |
| | | 'æ£æµä¸å¿çµæ§è½å®éªå®¤': 'center_electrical_maintenance_content', |
| | | 'ææ¸©äº': 'temperature2_maintenance_content', |
| | | 'ææ¸©ä¸': 'temperature1_maintenance_content', |
| | | 'åå¦å®éªå®¤': 'chemistry_maintenance_content', |
| | | 'å¶æ ·å®¤': 'sample_maintenance_content', |
| | | '使¸©å®éªå®¤': 'hypothermia_maintenance_content', |
| | | }; |
| | | // è·åå½åèç¹çå®éªå®¤åç§° |
| | | const name = this.clickNodeVal.parent.label; |
| | | // æ ¹æ®æ å°å
³ç³»è·å对åºçç±»å |
| | | const type = labTypeMapping[name]; |
| | | this.getDicts(type).then((response) => { |
| | | this.qualificationList = response.data.map((m) => { |
| | | return { |
| | | label: m.dictLabel, |
| | | value: m.dictValue, |
| | | }; |
| | | }); |
| | | }); |
| | | }, |
| | | openHandleOut () { |
| | | this.outLoading = true |
| | | exportDeviceMaintenance({ |
| | | deviceId: this.clickNodeVal.value |
| | | }).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | this.$download.saveAs(blob, '设å¤ç»´æ¤ä¿å
».doc') |
| | | }) |
| | | |
| | | }, |
| | | handleDeleteClick(row) { |
| | | this.$confirm('æ¤æä½å°æ°¸ä¹
å é¤è¯¥æä»¶, æ¯å¦ç»§ç»?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | deleteDeviceMaintenance({ id: row.id }).then(res => { |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'å 餿å!' |
| | | }); |
| | | this.refreshTableList() |
| | | }) |
| | | }).catch(() => { |
| | | this.$message({ |
| | | type: 'info', |
| | | message: '已忶å é¤' |
| | | }); |
| | | }); |
| | | }, |
| | | // æäº¤æ°å¢åä¿å |
| | | saveRecord () { |
| | | this.$refs.form.validate((valid) => { |
| | | if (valid) { |
| | | this.buttonLoading = true; |
| | | this.form.maintenanceContent = this.form.maintenanceContentArr.join(',') |
| | | this.form.deviceId = this.clickNodeVal.value |
| | | addDeviceMaintenance(this.form).then(res => { |
| | | this.buttonLoading = false; |
| | | this.$message.success('æ°å¢æå') |
| | | this.closeDia() |
| | | this.getTableList() |
| | | }).catch(err => { |
| | | this.buttonLoading = false; |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | closeDia () { |
| | | this.$refs['form'].resetFields(); |
| | | this.dialogVisible = false |
| | | this.refreshTableList() |
| | | }, |
| | | // è·åè´è´£äººä¿¡æ¯æ¥å£ |
| | | getUserList() { |
| | | selectUserCondition({type: 2}).then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | | }) |
| | | }, |
| | | }, |
| | | watch: { |
| | | // çå¬ç¹å»el-treeçæ°æ®ï¼è¿è¡æ°æ®å·æ° |
| | | clickNodeVal(newVal) { |
| | | if (newVal.value) { |
| | | this.refreshTableList(); |
| | | } |
| | | }, |
| | | } |
| | | }; |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .search { |
| | | height: 46px; |
| | | text-align: right; |
| | | margin-top: 10px; |
| | | } |
| | | </style> |
| | |
| | | width="70"></el-table-column> |
| | | <el-table-column label="年份" min-width="80" prop="planYear"></el-table-column> |
| | | <el-table-column label="ç¼å¶äºº" min-width="120" prop="compiler"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¶é´" min-width="150" prop="datePreparation"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¶é´" min-width="160" prop="datePreparation"></el-table-column> |
| | | <el-table-column label="å®¡æ ¸äºº" min-width="150" prop="audit"></el-table-column> |
| | | <el-table-column label="å®¡æ ¸æ¶é´" min-width="180" prop="auditDate"></el-table-column> |
| | | <el-table-column label="å®¡æ ¸ç¶æ" min-width="180" prop="status"> |
| | |
| | | </template> |
| | | </el-table-column> |
| | | <!-- æä½æé® --> |
| | | <el-table-column align="center" fixed="right" label="æä½" min-width="240"> |
| | | <el-table-column align="center" fixed="right" label="æä½" min-width="260"> |
| | | <template slot-scope="scope"> |
| | | <el-button :disabled="scope.row.status === 1" size="small" type="text" |
| | | @click="handleForm('edit', scope.row)">ç¼è¾</el-button> |
| | | <el-button size="small" type="text" @click="handleForm('view', scope.row)">æ¥ç</el-button> |
| | | <el-button :disabled="scope.row.status === 1" size="small" type="text" |
| | | @click="tellApprove(scope.row.maintenancePlanId)">å®¡æ ¸éç¥</el-button> |
| | | <el-button :disabled="scope.row.status === 1 || userId != scope.row.auditId" size="small" type="text" |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="applicationForm" |
| | | title="设å¤ä¿å
»è®¡å表" width="80%" @close="closeDialog"> |
| | | <div style="display: flex;align-items: center;"> |
| | | <el-button v-if="operationType !== 'check'" size="small" type="primary" @click="addTableRow">æ·»å </el-button> |
| | | <span style="width: 60px">年份ï¼</span> |
| | | <el-button v-if="operationType === 'edit' || operationType === 'add'" size="small" type="primary" @click="addTableRow">æ·»å </el-button> |
| | | <span style="width: 60px;margin-left: 10px">年份ï¼</span> |
| | | <el-date-picker v-model="form.planYear" type="year" value-format="yyyy" clearable size="small" format="yyyy" |
| | | placeholder="鿩年"> |
| | | placeholder="鿩年" :disabled="operationType !== 'edit' && operationType !== 'add'"> |
| | | </el-date-picker> |
| | | </div> |
| | | <div style="margin: 10px 0"> |
| | | <el-table ref="yearTable" :data="deviceMaintenancePlanDetails" id="templateParamTable" row-key="deviceId" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | height="300px" border style="width: 100% ;"> |
| | | height="560px" style="width: 100% ;"> |
| | | <el-table-column align="center" header-align="center" label="åºå·" type="index" width="60"></el-table-column> |
| | | <el-table-column label="设å¤åç§°" min-width="170" prop="deviceName"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.deviceName" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.deviceName" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="设å¤ç¼å·" min-width="140" prop="deviceNumber"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.deviceNumber" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.deviceNumber" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="å½å±å®éªå®¤" min-width="120" prop="storagePoint"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.storagePoint" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.storagePoint" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="ä¿å
Ȍ
³é®é¨ä½" min-width="120" prop="maintenanceSite"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.maintenanceSite" :disabled="operationType === 'check'" clearable size="small" |
| | | <el-input v-model="scope.row.maintenanceSite" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable size="small" |
| | | type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="ä¿å
Ȍ
容" min-width="120" prop="maintenanceContent"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.maintenanceContent" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.maintenanceContent" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="ä¿å
»å¨æ" min-width="90" prop="maintenanceIntervals"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.maintenanceIntervals" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.maintenanceIntervals" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column fixed="right" label="æä½" width="80" align="center" v-if="operationType !== 'check'"> |
| | | <el-table-column label="æä½" width="80" align="center" v-if="operationType === 'edit' || operationType === 'add'"> |
| | | <template slot-scope="scope"> |
| | | <el-button style="color: #f56c6c" type="text" @click="deleteRow(scope.$index)">å é¤</el-button> |
| | | </template> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeDialog">å æ¶</el-button> |
| | | <el-button v-if="operationType !== 'check'" :loading="submitFormLoading" type="primary" @click="submitForm">ç¡® |
| | | <el-button v-if="operationType === 'edit' || operationType === 'add'" :loading="submitFormLoading" type="primary" @click="submitForm">ç¡® |
| | | 认</el-button> |
| | | <el-button v-if="operationType === 'check'" :loading="submitFormLoading" type="primary" |
| | | @click="checkStatus(0)">ä¸éè¿</el-button> |
| | |
| | | </el-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addEquipDia = false">å æ¶</el-button> |
| | | <el-button v-if="operationType !== 'check'" :loading="submitFormLoading" type="primary" |
| | | <el-button v-if="operationType === 'edit' || operationType === 'add'" :loading="submitFormLoading" type="primary" |
| | | @click="changeMachineName">ç¡® |
| | | 认</el-button> |
| | | </span> |
| | |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1" background> |
| | | </el-pagination> |
| | | </div> |
| | | </div> |
| | |
| | | <div> |
| | | <div> |
| | | <div style="margin: 10px 0;display: flex;align-items: center;justify-content: space-between;"> |
| | | <span>年度计å表</span> |
| | | <div class="title"> |
| | | <span style="font-weight: bold">年度计å表</span> |
| | | </div> |
| | | <div style="display: flex;align-items: center;"> |
| | | <el-button style="margin-right: 10px" size="small" type="primary" @click="getYearTableData">å·æ°</el-button> |
| | | <el-button style="margin-right: 10px" size="small" type="primary" @click="addYearPlan('add')">æ°å¢</el-button> |
| | | <el-button size="small" type="primary" @click="getYearTableData">å·æ°</el-button> |
| | | <el-button size="small" type="primary" @click="addYearPlan('add')">æ°å¢</el-button> |
| | | <!-- <el-upload ref="upload" :action="action"--> |
| | | <!-- :before-upload="beforeUpload" :headers="uploadHeader" :on-error="onError"--> |
| | | <!-- :on-success="handleSuccessUp" :show-file-list="false" accept='.xls,.xlsx'>--> |
| | |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <el-table ref="yearTable" v-loading="yearTableDataLoading" :data="yearTableData" height="calc(60vh - 20em)" |
| | | <el-table ref="yearTable" v-loading="yearTableDataLoading" :data="yearTableData" |
| | | height="calc(60vh - 16em)" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | highlight-current-row style="width: 100% ;" @current-change="currentChange"> |
| | | highlight-current-row @current-change="currentChange"> |
| | | <!-- è¡¨æ ¼å --> |
| | | <el-table-column align="center" header-align="center" label="åºå·" prop="prop" type="index" |
| | | width="70"></el-table-column> |
| | | <el-table-column label="年份" min-width="80" prop="planYear"></el-table-column> |
| | | <el-table-column label="计ååç§°" min-width="180" prop="planName"></el-table-column> |
| | | <el-table-column label="计ååç§°" min-width="180" prop="planName" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="ç¼å¶äºº" min-width="100" prop="writeName"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¥æ" min-width="150" prop="writeTime"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¥æ" min-width="160" prop="writeTime"></el-table-column> |
| | | <el-table-column label="æ¹åç¶æ" min-width="100" prop="ratifyStatus"> |
| | | <template slot-scope="scope"> |
| | | <el-tag v-if="scope.row.ratifyStatus === 1" type="success">æ¹å</el-tag> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination.total" layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange"> |
| | | background :total="pagination.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | @size-change="handleSizeChange" @current-change="handleCurrentChange"> |
| | | </el-pagination> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <span>年度计åæç»è¡¨</span> |
| | | <div class="title"> |
| | | <div class="title-search"> |
| | | <span style="width: 120px;font-size: 14px">设å¤ç¼å·ï¼</span> |
| | | <el-input v-model="searchForm.deviceNumber" clearable size="small" |
| | | style="margin-right: 10px;width: 220px"></el-input> |
| | | <span style="width: 80px;font-size: 14px">设å¤åç§°ï¼</span> |
| | | <el-input v-model="searchForm.deviceName" clearable size="small" |
| | | style="margin-right: 10px;width: 220px"></el-input> |
| | | <el-button size="small" type="primary" @click="getYearTableDetailData(currentRow)">æ¥ è¯¢</el-button> |
| | | <el-button size="small" @click="reset">é ç½®</el-button> |
| | | <span style="font-weight: bold">年度计åæç»è¡¨</span> |
| | | </div> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="设å¤ç¼å·" prop="deviceNumber"> |
| | | <el-input v-model="searchForm.deviceNumber" clearable size="small" |
| | | @keyup.enter.native="getYearTableDetailData(currentRow)"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="设å¤åç§°" prop="deviceName"> |
| | | <el-input v-model="searchForm.deviceName" clearable size="small" |
| | | @keyup.enter.native="getYearTableDetailData(currentRow)"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="getYearTableDetailData(currentRow)">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="reset">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="handleForm('add')">æ°å¢</el-button> |
| | |
| | | <div> |
| | | <el-table ref="yearTableDetailData" v-loading="yearTableDetailDataLoading" :data="yearTableDetailData" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | height="calc(60vh - 20em)" style="width: 100% ;"> |
| | | :height="'calc(100vh - 34em)'" style="width: 100% ;"> |
| | | <!-- è¡¨æ ¼å --> |
| | | <el-table-column align="center" header-align="center" label="åºå·" prop="prop" type="index" |
| | | width="70"></el-table-column> |
| | | <el-table-column label="设å¤ç¼å·" min-width="180" prop="deviceNumber"></el-table-column> |
| | | <el-table-column label="设å¤åç§°" min-width="180" prop="deviceName"></el-table-column> |
| | | <el-table-column label="设å¤åç§°" min-width="180" prop="deviceName" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="æ ¸æ¥æ¶é´" min-width="150" prop="checkTime"></el-table-column> |
| | | <el-table-column label="æ ¸æ¥ææ " min-width="150" prop="checkIndex"> </el-table-column> |
| | | <el-table-column label="æ ¸æ¥æ¹æ³" min-width="150" prop="checkMethod"></el-table-column> |
| | | <el-table-column label="ç»æå¦ä½å¤å®" min-width="150" prop="howResults"></el-table-column> |
| | | <el-table-column label="æ ¸æ¥è´è´£äºº" min-width="150" prop="checkChargerUser"></el-table-column> |
| | | <el-table-column label="è®°å½ç¶æ" min-width="100" prop="recordStatus"> |
| | | <template slot-scope="scope"> |
| | | <el-tag type="" v-if="scope.row.recordStatus === 0" disable-transitions>æªå¼å§</el-tag> |
| | | <el-tag type="warning" v-if="scope.row.recordStatus === 1" disable-transitions>å¾
æ¹å</el-tag> |
| | | <el-tag type="success" v-if="scope.row.recordStatus === 2" disable-transitions>éè¿</el-tag> |
| | | <el-tag type="danger" v-if="scope.row.recordStatus === 3" disable-transitions>ä¸éè¿</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="对æ¯ç¶æ" min-width="100" prop="recordContrastStatus"> |
| | | <template slot-scope="scope"> |
| | | <el-tag type="" v-if="scope.row.recordContrastStatus === 0" disable-transitions>æªå¼å§</el-tag> |
| | | <el-tag type="warning" v-if="scope.row.recordContrastStatus === 1" disable-transitions>å¾
æ¹å</el-tag> |
| | | <el-tag type="success" v-if="scope.row.recordContrastStatus === 2" disable-transitions>éè¿</el-tag> |
| | | <el-tag type="danger" v-if="scope.row.recordContrastStatus === 3" disable-transitions>ä¸éè¿</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="夿³¨" min-width="150" prop="remark"></el-table-column> |
| | | <!-- æä½æé® --> |
| | | <el-table-column align="center" fixed="right" label="æä½" min-width="260"> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .title { |
| | | .search { |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | } |
| | | .title { |
| | | position: relative; |
| | | font-size: 16px; |
| | | color: #333; |
| | | font-weight: 400; |
| | | padding-left: 10px; |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | .title-search { |
| | | display: flex; |
| | | align-items: center; |
| | | margin: 10px 0; |
| | | .title::before { |
| | | position: absolute; |
| | | left: 0; |
| | | top: 4px; |
| | | content: ''; |
| | | width: 4px; |
| | | height: 16px; |
| | | background-color: #3A7BFA; |
| | | border-radius: 2px; |
| | | } |
| | | </style> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px;"> |
| | | <el-button size="small" @click="resetSearch">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="getTableList(clickNodeVal.value)">æ¥ è¯¢</el-button> |
| | | <el-button size="mini" type="primary" @click="getTableList(clickNodeVal.value)">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearch">éç½®</el-button> |
| | | </div> |
| | | <div class="btns"> |
| | | <el-button size="small" type="primary" @click="dialogVisible = true, addRecode()">æ°å»º</el-button> |
| | |
| | | <el-col :span="8"> |
| | | <div class="form-item"> |
| | | <label>设å¤åç§°</label> |
| | | <!-- <p>{{ Mdata.deviceName }}</p> --> |
| | | <!-- <p>{{ Mdata.deviceName }}</p> --> |
| | | <el-tooltip class="item" :content="Mdata.deviceName"> |
| | | <span class="text-ellipsis">{{ Mdata.deviceName }}</span> |
| | | </el-tooltip> |
| | |
| | | <el-table-column prop="quantity" label="份æ°" min-width="80" /> |
| | | <el-table-column prop="pageCount" label="页ç " min-width="80" /> |
| | | <el-table-column prop="provider" label="æä¾è
" min-width="150" /> |
| | | <el-table-column prop="provideDate" label="彿¡£æ¥æ" min-width="150" /> |
| | | <el-table-column prop="provideDate" label="彿¡£æ¥æ" min-width="170" /> |
| | | <el-table-column prop="comments" label="夿³¨" min-width="150" /> |
| | | <el-table-column fixed="right" label="æä½" min-width="180"> |
| | | <el-table-column fixed="right" label="æä½" min-width="180" align="center"> |
| | | <template slot-scope="scope"> |
| | | <el-button type="text" size="small" @click="handleAttachmentClick(scope.row)">ä¸è½½éä»¶</el-button> |
| | | <el-button type="text" size="small" @click="handleViewClick(scope.row)">ç¼è¾</el-button> |
| | |
| | | .page-header { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | margin-top: 10px; |
| | | } |
| | | |
| | | h4 { |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | <!-- 设å¤å·¥å
·æç» --> |
| | | <template> |
| | | <div class="role_manage"> |
| | | <div class="search" v-show="!showData"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">ç¶æï¼</div> |
| | | <el-select v-model="queryParams.deviceStatus" placeholder="å
¨é¨" size="small"> |
| | | <el-option v-for="item in deviceStatusList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">设å¤åç§°ï¼</div> |
| | | <div class="search_input"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.deviceName" |
| | | @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">è§æ ¼åå·ï¼</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="queryParams.specificationModel" @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | </div> |
| | | <div style="padding-left: 30px;"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | <el-button size="small" type="primary" @click="dialogVisible2 = true">æ° å¢</el-button> |
| | | <el-button size="small" type="primary" @click="handleDownOne">导 åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="search" v-show="!showData"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryParams" size="small" :inline="true"> |
| | | <el-form-item label="ç¶æ" prop="deviceStatus" class="form-item"> |
| | | <el-select v-model="queryParams.deviceStatus" clearable |
| | | placeholder="å
¨é¨" size="small" @change="refreshTable"> |
| | | <el-option v-for="item in deviceStatusList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="设å¤åç§°" prop="deviceName"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.deviceName" |
| | | @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="è§æ ¼åå·" prop="specificationModel"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="queryParams.specificationModel" @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="dialogVisible2 = true">æ°å¢</el-button> |
| | | <el-button size="small" type="primary" @click="handleDownOne">导åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table" v-show="!showData"> |
| | | <lims-table :tableData="tableData" :column="column" :tableLoading="tableLoading" :height="'calc(100vh - 320px)'" |
| | | <lims-table :tableData="tableData" :column="column" :tableLoading="tableLoading" :height="'calc(100vh - 300px)'" |
| | | :page="page" @pagination="pagination"></lims-table> |
| | | </div> |
| | | <el-dialog :title="isUp ? '设å¤è¯¦æ
' : 'æ¡£æ¡ä¿®è®¢'" :visible.sync="dialogVisible" width="70%" top="5vh" |
| | |
| | | labelPosition: 'right', |
| | | dialogVisible: false, |
| | | dialogVisible2: false, |
| | | addPower: false, |
| | | showData: false, // æ°éé
ç½®é¡µé¢ |
| | | tableList: [], |
| | | addDia: true, |
| | | addPower: true, |
| | | //设å¤ç±»åå表 |
| | | equipmentList: [], |
| | | // è´è´£äººå表 |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .role_manage { |
| | | width: 100%; |
| | | height: 100%; |
| | | } |
| | | |
| | | .title { |
| | | line-height: 15px; |
| | | } |
| | | |
| | | .search { |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | margin-top: 10px; |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | margin-top: 10px; |
| | | } |
| | | |
| | | .search_thing { |
| | |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 80px); |
| | | } |
| | | |
| | | .table { |
| | | margin-top: 12px; |
| | | background-color: #fff; |
| | | height: calc(100vh - 17em); |
| | | height: calc(100vh - 16em); |
| | | } |
| | | |
| | | .el-form-item { |
| | | margin-bottom: 16px; |
| | | } |
| | | |
| | | .picName { |
| | | overflow: hidden; |
| | | text-overflow: ellipsis; |
| | |
| | | word-break: break-all; |
| | | width: 120px; |
| | | } |
| | | .form-item >>>.el-form-item__content { |
| | | width: 120px; |
| | | } |
| | | </style> |
| | |
| | | </el-table> |
| | | <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="1" |
| | | :page-sizes="[10, 20, 30, 50, 100]" :page-size="search.size" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="search.total"> |
| | | :total="search.total" background> |
| | | </el-pagination> |
| | | <el-dialog :visible.sync="dialogVisible" title="åæ§ç³è¯·" width="60%"> |
| | | <div style="height: 60vh; overflow-y: auto; overflow-x: hidden;"> |
| | |
| | | <el-table-column label="年份" min-width="80" prop="planYear"></el-table-column> |
| | | <el-table-column label="æä»¶åç§°" min-width="120" prop="compiler"></el-table-column> |
| | | <el-table-column label="ç¼å¶äºº" min-width="150" prop="compiler"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¶é´" min-width="150" prop="datePreparation"></el-table-column> |
| | | <el-table-column label="ç¼å¶æ¶é´" min-width="160" prop="datePreparation"></el-table-column> |
| | | <el-table-column label="æ¹å人" min-width="180" prop="audit"></el-table-column> |
| | | <el-table-column label="æ¹åç¶æ" min-width="180" prop="status"> |
| | | <template slot-scope="scope"> |
| | |
| | | </el-table-column> |
| | | <el-table-column label="æ¹åæ¶é´" min-width="180" prop="auditDate"></el-table-column> |
| | | <!-- æä½æé® --> |
| | | <el-table-column align="center" fixed="right" label="æä½" min-width="240"> |
| | | <el-table-column align="center" fixed="right" label="æä½" min-width="270"> |
| | | <template slot-scope="scope"> |
| | | <el-button :disabled="scope.row.status === 1" size="small" type="text" |
| | | @click="handleForm('edit', scope.row)">ç¼è¾</el-button> |
| | | <el-button size="small" type="text" @click="handleForm('view', scope.row)">æ¥ç</el-button> |
| | | <el-button :disabled="scope.row.status === 1" size="small" type="text" |
| | | @click="tellApprove(scope.row.traceabilityManagementId)">æ¹åéç¥</el-button> |
| | | <el-button :disabled="scope.row.status === 1 || userId != scope.row.auditId" size="small" type="text" |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="applicationForm" |
| | | title="仪å¨è®¾å¤é弿º¯æºç®¡çæ»ä½è®¡å" width="80%" @close="closeDialog"> |
| | | <div style="display: flex;align-items: center;"> |
| | | <el-button v-if="operationType !== 'check'" size="small" type="primary" @click="addTableRow">æ·»å </el-button> |
| | | <span style="width: 60px">年份ï¼</span> |
| | | <el-button v-if="operationType === 'edit' || operationType === 'add'" size="small" type="primary" @click="addTableRow">æ·»å </el-button> |
| | | <span style="width: 60px;margin-left: 10px">年份ï¼</span> |
| | | <el-date-picker v-model="form.planYear" type="year" value-format="yyyy" clearable size="small" format="yyyy" |
| | | placeholder="鿩年"> |
| | | placeholder="鿩年" :disabled="operationType !== 'edit' && operationType !== 'add'"> |
| | | </el-date-picker> |
| | | </div> |
| | | <div style="margin: 10px 0"> |
| | | <el-table ref="yearTable" :data="deviceTraceabilityManagementDetails" height="300px" id="templateParamTable" |
| | | <el-table ref="yearTable" :data="deviceTraceabilityManagementDetails" height="560px" id="templateParamTable" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | row-key="deviceId" style="width: 100% ;"> |
| | | row-key="deviceId" v-loading="yearTableLoading"> |
| | | <el-table-column align="center" header-align="center" label="åºå·" type="index" width="60"></el-table-column> |
| | | <el-table-column label="设å¤åç§°" min-width="170" prop="deviceId"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.deviceName" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.deviceName" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="åå·" min-width="140" prop="specificationModel"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.specificationModel" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.specificationModel" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="设å¤ç¼å·" min-width="140" prop="managementNumber"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.managementNumber" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.managementNumber" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="ææ¯ææ åæ°" min-width="150" prop="technicalIndexParameters"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.technicalIndexParameters" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.technicalIndexParameters" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="ææ¯ææ è¦æ±" min-width="150" prop="technicalRequirements"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.technicalRequirements" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.technicalRequirements" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ£å®å¨æ" min-width="120" prop="verificationCycle"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.verificationCycle" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.verificationCycle" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ£å®åä½" min-width="90" prop="verificationUnit"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.verificationUnit" :disabled="operationType === 'check'" clearable |
| | | <el-input v-model="scope.row.verificationUnit" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="夿³¨" min-width="90" prop="remark"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.remark" :disabled="operationType === 'check'" clearable size="small" |
| | | <el-input v-model="scope.row.remark" :disabled="operationType !== 'edit' && operationType !== 'add'" clearable size="small" |
| | | type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column fixed="right" label="æä½" width="80" align="center" v-if="operationType !== 'check'"> |
| | | <el-table-column label="æä½" width="80" align="center" v-if="operationType === 'edit' || operationType === 'add'"> |
| | | <template slot-scope="scope"> |
| | | <el-button style="color: #f56c6c" type="text" @click="deleteRow(scope.$index)">å é¤</el-button> |
| | | </template> |
| | |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeDialog">å æ¶</el-button> |
| | | <el-button v-if="operationType !== 'check'" :loading="submitFormLoading" type="primary" @click="submitForm">ç¡® |
| | | <el-button v-if="operationType === 'edit' || operationType === 'add'" :loading="submitFormLoading" type="primary" @click="submitForm">ç¡® |
| | | 认</el-button> |
| | | <el-button v-if="operationType === 'check'" :loading="submitFormLoading" type="primary" |
| | | @click="checkStatus(0)">ä¸éè¿</el-button> |
| | |
| | | </el-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addEquipDia = false">å æ¶</el-button> |
| | | <el-button v-if="operationType !== 'check'" :loading="submitFormLoading" type="primary" |
| | | <el-button v-if="operationType === 'edit' || operationType === 'add'" :loading="submitFormLoading" type="primary" |
| | | @click="changeMachineName">ç¡® |
| | | 认</el-button> |
| | | </span> |
| | |
| | | notificationLoading: false, |
| | | auditId: '', |
| | | traceabilityManagementId: '', |
| | | yearTableLoading: false |
| | | } |
| | | }, |
| | | mounted() { |
| | |
| | | this.form = { |
| | | planYear: '', |
| | | deviceTraceabilityManagementDetails: [] |
| | | }, |
| | | this.deviceTraceabilityManagementDetails = [] |
| | | } |
| | | this.deviceTraceabilityManagementDetails = [] |
| | | if (row) { |
| | | this.traceabilityManagementId = row.traceabilityManagementId |
| | | this.yearTableLoading = true |
| | | getTraceabilityManagementDetail({ traceabilityManagementId: this.traceabilityManagementId }).then(res => { |
| | | this.yearTableLoading = false |
| | | if (res.code === 200) { |
| | | this.form = res.data |
| | | this.deviceTraceabilityManagementDetails = this.form.deviceTraceabilityManagementDetails |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | | this.yearTableLoading = false |
| | | }) |
| | | } |
| | | }, |
| | |
| | | changeMachineName() { |
| | | this.deviceTraceabilityManagementDetails = [] |
| | | this.selectionRows.map(val => { |
| | | this.deviceTraceabilityManagementDetails.push({ deviceId: val.id, managementNumber: val.value, deviceName: val.label, specificationModel: val.specificationModel }) |
| | | this.deviceTraceabilityManagementDetails.push({ |
| | | deviceId: val.id, |
| | | managementNumber: val.value, |
| | | deviceName: val.label, |
| | | specificationModel: val.specificationModel, |
| | | verificationUnit: val.calibrationServices, |
| | | verificationCycle: val.calibrationDate |
| | | }) |
| | | }) |
| | | this.addEquipDia = false |
| | | this.rowDrop() |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ ·åç¼å·ï¼</div> |
| | | <el-input v-model="search.sampleCode" clearable placeholder="请è¾å
¥" size="small" style="width: 60%;" |
| | | @keyup.enter.native="getTableList(clickNodeVal.value)"></el-input> |
| | | <div class="search_label">管çç¼å·ï¼</div> |
| | | <el-input v-model="search.managementNumber" clearable placeholder="请è¾å
¥" size="small" style="width: 60%;" |
| | | @keyup.enter.native="getTableList(clickNodeVal.value)"></el-input> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px;"> |
| | | <el-button size="small" @click="resetSearch">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="getTableList(clickNodeVal.value)">æ¥ è¯¢</el-button> |
| | | </div> |
| | | <div class="btns" v-if="isMenuList != 1"> |
| | | <el-form :model="search" ref="search" size="small" :inline="true"> |
| | | <el-form-item label="æ ·åç¼å·"> |
| | | <el-input v-model="search.sampleCode" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getTableList(clickNodeVal.value)"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="管çç¼å·"> |
| | | <el-input v-model="search.managementNumber" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getTableList(clickNodeVal.value)"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="mini" type="primary" @click="getTableList(clickNodeVal.value)">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearch">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="dialogVisible = true, openAdd()">æ° å»º</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="openHandleOut">导 åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="tables" style="margin-top: 10px;"> |
| | | <div> |
| | | <el-table ref="Recordtable" :data="formParamList" height="calc(100vh - 20em)" |
| | | v-loading="tableLoading" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border> |
| | | <!-- è¡¨æ ¼å --> |
| | | <el-table-column label="åºå·" type="index" width="120"> |
| | | <el-table-column label="åºå·" type="index" width="70" align="center"> |
| | | <template v-slot="scope"> |
| | | <span>{{ (search.current - 1) * search.size + scope.$index + 1 }}</span> |
| | | </template> |
| | |
| | | </template> |
| | | </el-table-column> |
| | | <!-- <el-table-column label="å¼å¸¸æ
åµ" min-width="120" prop="abnormal" />--> |
| | | <el-table-column label="使ç¨å¼å§æ¥æ" min-width="150" prop="useStartDate" /> |
| | | <el-table-column label="使ç¨ç»ææ¥æ" min-width="150" prop="useEndDate" /> |
| | | <el-table-column label="使ç¨å¼å§æ¥æ" min-width="170" prop="useStartDate" /> |
| | | <el-table-column label="使ç¨ç»ææ¥æ" min-width="170" prop="useEndDate" /> |
| | | <el-table-column label="使ç¨äºº" min-width="120" prop="usePerson" /> |
| | | <el-table-column label="夿³¨" min-width="120" prop="remark" /> |
| | | <!-- æä½æé® --> |
| | |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="search.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="search.total" layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange"> |
| | | @current-change="handleCurrentChange" background> |
| | | </el-pagination> |
| | | </div> |
| | | <el-dialog :visible.sync="dialogVisible" title="仪å¨è®¾å¤ä½¿ç¨è®°å½è¡¨" top="5vh" width="55%"> |
| | |
| | | dialogVisible: false, |
| | | operationType: '', |
| | | formParamList: [], |
| | | tableLoading: false |
| | | } |
| | | }, |
| | | mounted() { |
| | |
| | | if (deviceId === undefined) { |
| | | deviceId = '' |
| | | } |
| | | this.tableLoading = true |
| | | await deviceRecordPage({ |
| | | deviceId: deviceId, |
| | | ...this.search |
| | | }).then(res => { |
| | | this.tableLoading = false |
| | | if (res.code == 200) { |
| | | this.formParamList = res.data.records |
| | | this.search.total = res.data.total |
| | | } |
| | | }).catch(err => { |
| | | this.tableLoading = false |
| | | }) |
| | | }, |
| | | // æå¼å¯¼åºå¼¹æ¡éæ©ç¼å¶äººãæ¹å人 |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .tables { |
| | | width: 100%; |
| | | height: calc(100vh - 15em); |
| | | } |
| | | |
| | | .el-from { |
| | | max-width: 400px; |
| | | margin: 0 auto; |
| | | } |
| | | |
| | | .form-row { |
| | | .search { |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | .el-input { |
| | | width: calc(100% - 120px); |
| | | /* ç¡®ä¿è¾å
¥æ¡å®½åº¦ä¸è´ */ |
| | | } |
| | | |
| | | .form-row .el-form-item { |
| | | flex: 1; |
| | | /* æ¯ä¸ªè¡¨åé¡¹å æ®ç¸åæ¯ä¾çç©ºé´ */ |
| | | margin-right: 100px; |
| | | /* å¯éï¼ä¸ºå³ä¾§å
ç´ æ·»å é´è· */ |
| | | } |
| | | |
| | | /* ç§»é¤æåä¸ä¸ªå
ç´ çå³è¾¹è· */ |
| | | .form-row .el-form-item:last-child { |
| | | margin-right: 0; |
| | | |
| | | } |
| | | |
| | | .search { |
| | | background-color: #fff; |
| | | margin-top: 10px; |
| | | display: flex; |
| | | align-items: center; |
| | | position: relative; |
| | | } |
| | | |
| | | .search_thing { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 40px; |
| | | |
| | | } |
| | | |
| | | .search_label { |
| | | width: 140px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | margin-right: 10px; |
| | | } |
| | | |
| | | .btns { |
| | | position: absolute; |
| | | right: 0px; |
| | | top: 50%; |
| | | transform: translate(0, -50%); |
| | | } |
| | | </style> |
| | |
| | | size="mini" |
| | | type="date" |
| | | value-format="yyyy-MM-dd"/> |
| | | <el-button size="mini" type="primary" @click="ValidateAndQuery">æ¥ è¯¢</el-button> |
| | | <el-button size="mini" type="primary" @click="ValidateAndQuery">æ¥è¯¢</el-button> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <el-row :gutter="10" style="width: 100%;"> |
| | | <el-col :span="20" style="display: flex;flex-wrap: wrap;"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æµç¨ç¼å·ï¼</div> |
| | | <div class="search_input"> |
| | | <el-input v-model="search.processNumber" clearable placeholder="请è¾å
¥" size="small" style="width: 100%" |
| | | @keyup.enter.native="getDeviceStatePage(clickNodeVal.value)"></el-input> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 20px;"> |
| | | <el-button size="small" @click="resetSearch">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="getDeviceStatePage(clickNodeVal.value)">æ¥ è¯¢</el-button> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="4"> |
| | | <div class="btns"> |
| | | <el-button size="small" type="primary" @click="dialogVisible = true">æ°å»º</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleDown">导åºExcel</el-button> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | | <el-form :model="search" ref="search" size="small" :inline="true"> |
| | | <el-form-item label="æµç¨ç¼å·"> |
| | | <el-input v-model="search.processNumber" clearable placeholder="请è¾å
¥" size="small" style="width: 100%" |
| | | @keyup.enter.native="getDeviceStatePage(clickNodeVal.value)"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="mini" type="primary" @click="getDeviceStatePage(clickNodeVal.value)">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearch">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="dialogVisible = true">æ°å»º</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleDown">导åºExcel</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <el-table :data="tableDatalist" height="calc(100vh - 20em)" style="width: 100% ;" |
| | |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="search.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="search.total" layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange"> |
| | | @current-change="handleCurrentChange" background> |
| | | </el-pagination> |
| | | </div> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="dialogVisible" title="è®¾å¤æ
åµ" |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .dialog-content { |
| | | max-height: 70vh; |
| | | /* 设置æå¤§é«åº¦ */ |
| | | overflow-y: auto; |
| | | /* å¯ç¨åç´æ»å¨ */ |
| | | } |
| | | |
| | | h4 { |
| | | font-weight: 400; |
| | | font-size: 16px; |
| | | margin: 10px 0; |
| | | } |
| | | |
| | | /* |
| | | ä¿åæäº¤æé®æ ·å¼ |
| | | */ |
| | | h4 .title { |
| | | width: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | h4 .title .line { |
| | | display: inline-block; |
| | | width: 3px; |
| | | height: 16px; |
| | | background: #3A7BFA; |
| | | margin-right: 4px; |
| | | } |
| | | |
| | | .tables { |
| | | width: 100%; |
| | | height: calc(100vh - 15em); |
| | | } |
| | | |
| | | .el-from { |
| | | max-width: 400px; |
| | | margin: 0 auto; |
| | | } |
| | | |
| | | .form-row { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | |
| | | .form-row .el-form-item { |
| | | flex: 1; |
| | | /* æ¯ä¸ªè¡¨åé¡¹å æ®ç¸åæ¯ä¾çç©ºé´ */ |
| | | margin-right: 100px; |
| | | /* å¯éï¼ä¸ºå³ä¾§å
ç´ æ·»å é´è· */ |
| | | } |
| | | |
| | | /* ç§»é¤æåä¸ä¸ªå
ç´ çå³è¾¹è· */ |
| | | .form-row .el-form-item:last-child { |
| | | margin-right: 0; |
| | | |
| | | } |
| | | |
| | | .search { |
| | | background-color: #fff; |
| | | margin: 10px 0; |
| | | height: 46px; |
| | | display: flex; |
| | | align-items: center; |
| | | position: relative; |
| | | } |
| | | |
| | | .search_thing { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 40px; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 70px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: 70%; |
| | | } |
| | | |
| | | .btns { |
| | | position: absolute; |
| | | right: 0; |
| | | top: 50%; |
| | | transform: translate(0, -50%); |
| | | } |
| | | |
| | | .form .search_label { |
| | | width: 120px; |
| | | justify-content: space-between; |
| | | margin-top: 10px; |
| | | } |
| | | </style> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <el-button size="small" type="primary" @click="refreshTableList">å· æ°</el-button> |
| | | <el-button size="small" type="primary" @click="openDia('add')">æ° å¢</el-button> |
| | | </div> |
| | | <div> |
| | | <lims-table :tableData="tableData" :column="column" |
| | | height="calc(100vh - 20em)" @pagination="pagination" |
| | | :page="page" :tableLoading="tableLoading"></lims-table> |
| | | </div> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="usageTableDia" |
| | | title="设å¤ä¿å
»è®¡å表" width="80%" @close="closeDialog"> |
| | | <div style="display: flex;align-items: center;"> |
| | | <el-button size="small" type="primary" @click="addTableRow" v-if="operationType !== 'check'">æ·»å </el-button> |
| | | <span style="width: 60px;margin-left: 10px">年份ï¼</span> |
| | | <el-date-picker v-model="form.impowerYear" type="year" value-format="yyyy" clearable size="small" format="yyyy" |
| | | placeholder="鿩年" :disabled="operationType === 'check'"> |
| | | </el-date-picker> |
| | | </div> |
| | | <div style="margin: 10px 0"> |
| | | <el-table ref="deviceImpowerDetails" :data="deviceImpowerDetails" id="templateParamTable" row-key="deviceId" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | height="560px" style="width: 100% ;"> |
| | | <el-table-column align="center" header-align="center" label="åºå·" type="index" width="60"></el-table-column> |
| | | <el-table-column label="设å¤åç§°" min-width="170" prop="deviceName"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.deviceName" clearable |
| | | size="small" :disabled="operationType === 'check'"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="设å¤ç¼å·" min-width="140" prop="managementNumber"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.managementNumber" clearable |
| | | size="small" :disabled="operationType === 'check'"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="è§æ ¼åå·" min-width="120" prop="specificationModel"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.specificationModel" clearable |
| | | size="small" :disabled="operationType === 'check'"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ£æµé¡¹ç®" min-width="120" prop="inspectionItem<"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.inspectionItem" clearable size="small" |
| | | :disabled="operationType === 'check'"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="被ææäºº" min-width="160" prop="delegatee"> |
| | | <template slot-scope="scope"> |
| | | <el-select v-model="scope.row.delegatedUserArr" |
| | | clearable filterable multiple |
| | | :disabled="operationType === 'check'" |
| | | placeholder="è¯·éæ©" size="small" style="width: 100%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æä½" width="80" align="center" v-if="operationType !== 'check'"> |
| | | <template slot-scope="scope"> |
| | | <el-button style="color: #f56c6c" type="text" @click="deleteRow(scope.$index)">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeDialog">å æ¶</el-button> |
| | | <el-button v-if="operationType !== 'check'" :loading="submitFormLoading" type="primary" @click="submitForm">确认</el-button> |
| | | <el-button v-if="operationType === 'check'" :loading="submitFormLoading" type="primary" |
| | | @click="checkStatus(0)">ä¸éè¿</el-button> |
| | | <el-button v-if="operationType === 'check'" :loading="submitFormLoading" type="primary" |
| | | @click="checkStatus(1)">éè¿</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="addEquipDia" title="æ·»å 设å¤" |
| | | width="50%"> |
| | | <div style="display: flex;align-items: center;"> |
| | | <span style="width: 90px;margin-left: 10px">被ææäººï¼</span> |
| | | <el-select v-model="delegatedUser" clearable filterable multiple |
| | | placeholder="è¯·éæ©" size="small" style="width: 100%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.name" :label="item.name" :value="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <el-table ref="multipleTable" :data="equipOptions" tooltip-effect="dark" height="500" style="width: 100%" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | @selection-change="handleSelectionChange"> |
| | | <el-table-column type="selection" width="55"></el-table-column> |
| | | <el-table-column label="设å¤åç§°" prop="label" width="190"></el-table-column> |
| | | <el-table-column prop="value" label="设å¤ç¼å·" width="130"></el-table-column> |
| | | <el-table-column prop="storagePoint" label="å½å±å®éªå®¤"></el-table-column> |
| | | </el-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addEquipDia = false">å æ¶</el-button> |
| | | <el-button :loading="submitFormLoading" type="primary" @click="changeMachineName">确认</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :visible.sync="notificationDia" title="æäº¤å®¡æ ¸" width="30%" @close="closeNotificationDia"> |
| | | <span style="margin-top: 10px;display: inline-block"> |
| | | è¯·éæ©å®¡æ ¸äººï¼ |
| | | <el-select v-model="auditId" clearable filterable size="small" style="width: 90%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </span> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button :loading="notificationLoading" @click="closeNotificationDia">å æ¶</el-button> |
| | | <el-button :loading="notificationLoading" type="primary" @click="notification">æ 交</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import { |
| | | addImpower, |
| | | deleteImpower, deviceScopeSearch, getImpowerDetail, reviewImpowerStatus, |
| | | selectDeviceImpowerByPage, submitReviewImpowerStatus, updateImpower, exportDeviceImpower |
| | | } from "@/api/cnas/resourceDemand/device"; |
| | | import {selectUserCondition} from "@/api/system/user"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: '', |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | | components: {limsTable}, |
| | | props: { |
| | | clickNodeVal: { |
| | | type: Object, |
| | | default: () => { |
| | | } |
| | | } |
| | | }, |
| | | data() { |
| | | // è¿éåæ¾æ°æ® |
| | | return { |
| | | outLoading: false, |
| | | tableData: [], |
| | | tableLoading: false, |
| | | page: { |
| | | total: 0, |
| | | size: 20, |
| | | current: 1 |
| | | }, |
| | | column: [ |
| | | { label: '计å年份', prop: 'impowerYear' }, |
| | | { label: 'ç¼å¶äºº', prop: 'compiler' }, |
| | | { label: 'ç¼å¶æ¶é´', prop: 'datePreparation' }, |
| | | { label: 'ææäºº', prop: 'audit' }, |
| | | { label: 'æææ¥æ', prop: 'auditDate' }, |
| | | { |
| | | dataType: 'tag', |
| | | label: 'ææç¶æ', |
| | | prop: 'status', |
| | | formatData: (params) => { |
| | | if (params === 1) { |
| | | return 'å·²ææ' |
| | | } else if (params == 0) { |
| | | return 'æªææ' |
| | | } else { |
| | | return null |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params == 1) { |
| | | return 'success' |
| | | } else if (params === 0) { |
| | | return 'danger' |
| | | } else { |
| | | return null |
| | | } |
| | | } |
| | | }, |
| | | { |
| | | dataType: 'action', |
| | | label: 'æä½', |
| | | operation: [ |
| | | { |
| | | name: 'ç¼è¾', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.openDia('edit', row); |
| | | }, |
| | | disabled: (row) => { |
| | | return row.status === 1; |
| | | }, |
| | | }, |
| | | { |
| | | name: 'å®¡æ ¸éç¥', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.tellApprove(row.impowerId); |
| | | }, |
| | | disabled: (row) => { |
| | | return row.status === 1; |
| | | }, |
| | | }, |
| | | { |
| | | name: 'å®¡æ ¸', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.openDia('check', row); |
| | | }, |
| | | disabled: (row) => { |
| | | return row.status === 1 || this.userId !== row.auditId; |
| | | }, |
| | | }, |
| | | { |
| | | name: '导åº', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.openHandleOut(row); |
| | | } |
| | | }, |
| | | { |
| | | name: 'å é¤', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.handleDeleteClick(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return row.status === 1; |
| | | }, |
| | | }, |
| | | ] |
| | | } |
| | | ], |
| | | responsibleOptions: [], |
| | | operationType: '', |
| | | usageTableDia: false, |
| | | deviceImpowerDetails: [], |
| | | submitFormLoading: false, |
| | | addEquipDia: false, |
| | | equipOptions: [], |
| | | selectionRows: [], |
| | | form: { |
| | | impowerYear: '' |
| | | }, |
| | | delegatedUser: [], |
| | | impowerId: '', |
| | | notificationDia: false, |
| | | auditId: '', |
| | | notificationLoading: false, |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.refreshTableList() |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | // ç¹å»å·æ° |
| | | refreshTableList () { |
| | | this.page.current = 1; |
| | | this.getTableList() |
| | | }, |
| | | // å页忢 |
| | | pagination(page) { |
| | | this.page.size = page.limit |
| | | this.getTableList() |
| | | }, |
| | | getTableList () { |
| | | this.tableLoading = true |
| | | selectDeviceImpowerByPage({ |
| | | ...this.page |
| | | }).then(res => { |
| | | this.tableLoading = false |
| | | this.tableData = res.data.records |
| | | this.page.total = res.data.total |
| | | }).catch(err => { |
| | | this.tableLoading = false |
| | | }) |
| | | }, |
| | | // æå¼æäº¤æ¹åå¼¹æ¡ |
| | | tellApprove(impowerId) { |
| | | this.getUserList() |
| | | this.notificationDia = true |
| | | this.impowerId = impowerId |
| | | }, |
| | | // æäº¤æ¹åéç¥ |
| | | notification() { |
| | | if (!this.auditId) { |
| | | this.$message.warning('è¯·éæ©å®¡æ ¸äºº') |
| | | return |
| | | } |
| | | this.notificationLoading = true |
| | | submitReviewImpowerStatus({ |
| | | auditId: this.auditId, |
| | | impowerId: this.impowerId, |
| | | }).then(res => { |
| | | this.notificationLoading = false |
| | | if (res.code == 200) { |
| | | this.closeNotificationDia() |
| | | this.refreshTableList() |
| | | } |
| | | }).catch(err => { |
| | | this.notificationLoading = false |
| | | }) |
| | | }, |
| | | // å
³éæäº¤æ¹åå¼¹æ¡ |
| | | closeNotificationDia() { |
| | | this.notificationDia = false |
| | | this.auditId = '' |
| | | }, |
| | | // æå¼æä½å¼¹æ¡ |
| | | openDia (type, row) { |
| | | this.operationType = type |
| | | this.usageTableDia = true |
| | | this.form = { |
| | | impowerYear: '', |
| | | deviceImpowerDetails: [], |
| | | } |
| | | this.deviceImpowerDetails = [] |
| | | if (row) { |
| | | this.impowerId = row.impowerId |
| | | getImpowerDetail({ impowerId: this.impowerId }).then(res => { |
| | | if (res.code === 200) { |
| | | this.form = res.data |
| | | this.deviceImpowerDetails = this.form.deviceImpowerDetails |
| | | this.deviceImpowerDetails.forEach(item => { |
| | | this.$set(item, 'delegatedUserArr', item.delegatedUser.split(',')) |
| | | }) |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | | }) |
| | | } |
| | | this.getEquipOptions() |
| | | this.getUserList() |
| | | }, |
| | | closeDialog () { |
| | | this.usageTableDia = false |
| | | this.getTableList() |
| | | }, |
| | | // æ·»å è®¾å¤ |
| | | addTableRow() { |
| | | this.addEquipDia = true |
| | | this.delegatedUser = this.responsibleOptions.map((item) => item.name); |
| | | this.getEquipOptions() |
| | | }, |
| | | // å é¤è¡¨æ ¼è¡ |
| | | deleteRow(index) { |
| | | this.deviceImpowerDetails.splice(index, 1) |
| | | }, |
| | | // æäº¤æ°å¢åä¿®æ¹ |
| | | submitForm() { |
| | | this.form.deviceImpowerDetails = this.HaveJson(this.deviceImpowerDetails) |
| | | this.form.deviceImpowerDetails.forEach((item) => { |
| | | item.delegatedUser = item.delegatedUserArr.join(',') |
| | | }) |
| | | this.submitFormLoading = true |
| | | if (this.operationType === 'add') { |
| | | addImpower(this.form).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('æ°å¢æå') |
| | | this.usageTableDia = false |
| | | this.refreshTableList() |
| | | } |
| | | this.submitFormLoading = false |
| | | }).catch(err => { |
| | | this.submitFormLoading = false |
| | | }) |
| | | } else { |
| | | updateImpower(this.form).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('ä¿®æ¹æå') |
| | | this.usageTableDia = false |
| | | this.refreshTableList() |
| | | } |
| | | this.submitFormLoading = false |
| | | }).catch(err => { |
| | | this.submitFormLoading = false |
| | | }) |
| | | } |
| | | }, |
| | | // æäº¤å®¡æ ¸ |
| | | checkStatus(status) { |
| | | const params = { |
| | | status: status, |
| | | impowerId: this.impowerId |
| | | } |
| | | reviewImpowerStatus(params).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('å®¡æ ¸æå') |
| | | this.usageTableDia = false |
| | | this.refreshTableList() |
| | | } |
| | | this.submitFormLoading = false |
| | | }).catch(err => { |
| | | this.submitFormLoading = false |
| | | }) |
| | | }, |
| | | handleSelectionChange(selection) { |
| | | this.selectionRows = selection |
| | | }, |
| | | // èµå¼ä»ªå¨ç¼å· |
| | | changeMachineName() { |
| | | this.deviceMaintenancePlanDetails = [] |
| | | this.selectionRows.map(val => { |
| | | this.deviceImpowerDetails.push({ deviceId: val.id, deviceName: val.label, managementNumber: val.value, specificationModel: val.specificationModel, delegatedUserArr: this.delegatedUser }) |
| | | }) |
| | | this.addEquipDia = false |
| | | }, |
| | | // è·åææè®¾å¤ |
| | | getEquipOptions() { |
| | | this.equipOptions = [] |
| | | deviceScopeSearch({ status: 0 }).then(res => { |
| | | if (res.code === 200 && res.data) { |
| | | this.equipOptions = res.data.map(m => { |
| | | m.value = m.managementNumber |
| | | m.label = m.deviceName |
| | | m.storagePoint = m.storagePoint |
| | | return m |
| | | }) |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | | }) |
| | | }, |
| | | openHandleOut (row) { |
| | | exportDeviceImpower({ impowerId: row.impowerId }).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/msword' }); |
| | | this.$download.saveAs(blob, '设å¤ä½¿ç¨ææè¡¨' + '.docx') |
| | | }) |
| | | }, |
| | | handleDeleteClick(row) { |
| | | this.$confirm('æ¤æä½å°æ°¸ä¹
å é¤è¯¥æä»¶, æ¯å¦ç»§ç»?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | deleteImpower({ impowerId: row.impowerId }).then(res => { |
| | | this.$message({ |
| | | type: 'success', |
| | | message: 'å 餿å!' |
| | | }); |
| | | this.refreshTableList() |
| | | }) |
| | | }).catch(() => { |
| | | this.$message({ |
| | | type: 'info', |
| | | message: '已忶å é¤' |
| | | }); |
| | | }); |
| | | }, |
| | | // è·åè´è´£äººä¿¡æ¯æ¥å£ |
| | | getUserList() { |
| | | selectUserCondition({type: 2}).then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | | }) |
| | | }, |
| | | }, |
| | | watch: { |
| | | // çå¬ç¹å»el-treeçæ°æ®ï¼è¿è¡æ°æ®å·æ° |
| | | clickNodeVal(newVal) { |
| | | if (newVal.value) { |
| | | this.refreshTableList(); |
| | | } |
| | | }, |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | }; |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .search { |
| | | height: 46px; |
| | | text-align: right; |
| | | margin-top: 10px; |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <div> |
| | | <div> |
| | | <div class="title"> |
| | | <div class="title-search"> |
| | | <span style="width: 80px;font-size: 14px">åä½åç§°ï¼</span> |
| | | <el-input v-model="searchForm.unitName" clearable size="small" |
| | | style="margin-right: 10px;width: 220px"></el-input> |
| | | <el-button size="small" type="primary" @click="getYearTableDetailData">æ¥ è¯¢</el-button> |
| | | <el-button size="small" @click="reset">é ç½®</el-button> |
| | | <div style="display: flex;justify-content: space-between;margin-top: 10px;"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">åä½åç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.unitName" |
| | | @keyup.enter.native="getYearTableDetailData"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="getYearTableDetailData">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="reset">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="handleForm('')">æ°å¢</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="pagination1.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" |
| | | :total="pagination1.total" layout="->,total, sizes, prev, pager, next, jumper" background |
| | | @size-change="handleSizeChange1" @current-change="handleCurrentChange1"> |
| | | </el-pagination> |
| | | </div> |
| | |
| | | |
| | | <style scoped> |
| | | .title { |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | align-items: center; |
| | | } |
| | | |
| | | .title-search { |
| | | display: flex; |
| | | align-items: center; |
| | | margin: 10px 0; |
| | | margin-top: 10px; |
| | | } |
| | | </style> |
| | |
| | | <quantity-value-traceability-plan v-if="menuListActiveName == 'é弿º¯æºè®¡å'" |
| | | :clickNodeVal="clickNodeVal"></quantity-value-traceability-plan> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="设å¤ä½¿ç¨ææ" name="设å¤ä½¿ç¨ææ"> |
| | | <usage-authorization v-if="menuListActiveName == '设å¤ä½¿ç¨ææ'" |
| | | :clickNodeVal="clickNodeVal"></usage-authorization> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="å©ç¨å¤é¨ä»ªå¨è®¾å¤" name="å©ç¨å¤é¨ä»ªå¨è®¾å¤"> |
| | | <using-external-instruments v-if="menuListActiveName == 'å©ç¨å¤é¨ä»ªå¨è®¾å¤'" :clickNodeVal="clickNodeVal"></using-external-instruments> |
| | | </el-tab-pane> |
| | |
| | | <el-tab-pane label="è®¾å¤æ ¡å" name="è®¾å¤æ ¡å"> |
| | | <calibration v-if="tabListActiveName == 'è®¾å¤æ ¡å'" :clickNodeVal="clickNodeVal" /> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="设å¤ç»´æ¤" name="设å¤ç»´æ¤"> |
| | | <maintenance v-if="tabListActiveName == '设å¤ç»´æ¤'" :clickNodeVal="clickNodeVal" /> |
| | | <el-tab-pane label="设å¤ç»´æ¤ä¿å
»" name="设å¤ç»´æ¤ä¿å
»"> |
| | | <equipmentMaintenance v-if="tabListActiveName == '设å¤ç»´æ¤ä¿å
»'" :clickNodeVal="clickNodeVal" /> |
| | | </el-tab-pane> |
| | | <el-tab-pane label="设å¤åç¨" name="设å¤åç¨"> |
| | | <borrow v-if="tabListActiveName == '设å¤åç¨'" :clickNodeVal="clickNodeVal" /> |
| | |
| | | import files from "./component/files.vue"; |
| | | import calibration from "./component/calibration.vue"; |
| | | import check from "./component/check.vue"; |
| | | import maintenance from "./component/maintenance.vue"; |
| | | import borrow from "./component/borrow.vue"; |
| | | import fault from "./component/fault.vue"; |
| | | import record from "./component/record.vue"; |
| | |
| | | import EquipmentMaintenancePlan from "./component/equipmentMaintenancePlan.vue"; |
| | | import EquipmentAcceptance from "./component/equipmentAcceptance.vue"; |
| | | import QuantityValueTraceabilityPlan from "./component/quantityValueTraceabilityPlan.vue"; |
| | | import equipmentMaintenance from "./component/equipmentMaintenance.vue"; |
| | | import usageAuthorization from "./component/usageAuthorization.vue"; |
| | | import { |
| | | treeDevice, |
| | | } from '@/api/cnas/resourceDemand/device.js' |
| | |
| | | files, |
| | | calibration, |
| | | check, |
| | | maintenance, |
| | | borrow, |
| | | fault, |
| | | record, |
| | |
| | | management, |
| | | overview, |
| | | resourceReservation, |
| | | operationInstruction |
| | | operationInstruction, |
| | | equipmentMaintenance, |
| | | usageAuthorization, |
| | | }, |
| | | data() { |
| | | return { |
| | |
| | | |
| | | >>>.el-tabs__content { |
| | | padding-top: 0; |
| | | max-height: 95%; /* æ ¹æ®éæ±è°æ´é«åº¦ */ |
| | | overflow-y: auto; /* åç´æ¹åè¶
åºæ¶æ¾ç¤ºæ»å¨æ¡ */ |
| | | } |
| | | |
| | | >>>.single-line-ellipsis { |
| | |
| | | addForeignRegister, |
| | | updateForeignRegister |
| | | } from '@/api/cnas/resourceDemand/foreignRegister/foreignRegister' |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'Personnel-management-dia', |
| | |
| | | mounted() { |
| | | |
| | | }, |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | // æå¼å¼¹æ¡ |
| | |
| | | if (type !== 'add') { |
| | | this.searchInfo(row) |
| | | } else { |
| | | this.form.accompanyingId = JSON.parse(localStorage.getItem("user")).userId |
| | | this.form.accompanyingId = this.userId |
| | | this.form.area = 'è£
å¤çµç¼è¯éªå®¤' |
| | | this.form.reason = 'åè§å®éªå®¤' |
| | | this.form.accompanyingId = 64 |
| | | this.form.approveId = 65 |
| | | this.form.confidentiality = '符å' |
| | | } |
| | | }, |
| | | // æ¥è¯¢è¯¦æ
|
| | |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="æ¥æ" prop="registerDate"> |
| | | <el-date-picker v-model="searchForm.registerDate" clearable format="yyyy-MM-dd" placeholder="éæ©æ¥æ" |
| | | size="small" style="width: 100%" type="date" value-format="yyyy-MM-dd"> |
| | | @change="searchList" size="small" style="width: 100%" type="date" value-format="yyyy-MM-dd"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-col :span="12"> |
| | | <div class="header"> |
| | | <div>è¯éªåºå</div> |
| | | <div> |
| | | åç§°ï¼ |
| | | <el-input v-model="search.testAreaName" clearable size="small" style="width: 120px"></el-input> |
| | | <el-button size="small" type="primary" @click="initData">æ¥è¯¢</el-button> |
| | | <el-button size="small" type="primary" @click="clickAdd">æ° å¢</el-button> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 48px;font-size: 14px;font-weight: 700;color: #606266;">åç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="search.testAreaName" |
| | | @keyup.enter.native="initData"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="mini" type="primary" @click="initData">æ¥è¯¢</el-button> |
| | | <el-button size="mini" type="primary" @click="clickAdd">æ° å¢</el-button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <el-table :data="tableData" height="calc(100vh - 18em)" highlight-current-row style="width: 100%" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | @row-click="clickRow"> |
| | | <el-table-column label="åºå·" type="index" width="60" align="center"></el-table-column> |
| | | <el-table-column label="æåº¦æ¶é´" min-width="180" prop="monthDate"></el-table-column> |
| | | <el-table-column label="æåº¦æ¶é´" min-width="100" prop="monthDate"></el-table-column> |
| | | <el-table-column label="è¯éªåºååç§°" min-width="180" prop="testAreaName"></el-table-column> |
| | | <el-table-column label="ç¡®è®¤ç¶æ" min-width="180" prop="isAffirm"> |
| | | <template slot-scope="scope"> |
| | | <el-tag type="danger" v-if="scope.row.isAffirm == 0">æªç¡®è®¤</el-tag> |
| | | <el-tag type="success" v-if="scope.row.isAffirm == 1">已确认</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="å¢è¡¥ä¿¡æ¯" min-width="180" prop="subjoin"></el-table-column> |
| | | <el-table-column label="è®°å½å" min-width="120" prop="registrarUserName"></el-table-column> |
| | | <el-table-column label="温度åºé´" min-width="100" prop="temperatureSection"></el-table-column> |
| | | <el-table-column label="湿度åºé´" min-width="100" prop="humiditySection"></el-table-column> |
| | | <el-table-column fixed="right" label="æä½" min-width="180" align="center"> |
| | | <template v-slot="scope"> |
| | | <el-button size="small" type="text" @click="downLoadPost(scope.row)">导åº</el-button> |
| | | <el-button size="small" type="text" @click="edit(scope.row)">ç¼è¾</el-button> |
| | | <el-button :disabled="scope.row.isAffirm === '1'" size="small" type="text" |
| | | @click="openApprovalDialog(scope.row)">确认</el-button> |
| | | <el-button size="small" type="text" @click="deleteRowFun(scope.row)">å é¤</el-button> |
| | | <!-- <el-button size="small" type="text" @click="edit(scope.row)">ç¼è¾</el-button>--> |
| | | <el-button size="small" type="text" |
| | | @click="openApprovalDialog(scope.row)">è®°å½åç»å®</el-button> |
| | | <!-- <el-button size="small" type="text" @click="deleteRowFun(scope.row)">å é¤</el-button>--> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | å¢</el-button> |
| | | </div> |
| | | </div> |
| | | <el-table :data="tableData1" height="calc(100vh - 18em)" style="width: 100%" |
| | | <el-table :data="tableData1" height="calc(100vh - 18em)" style="width: 100%" :row-class-name="tableRowClassName"> |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border> |
| | | <el-table-column label="åºå·" type="index" width="60" align="center"></el-table-column> |
| | | <el-table-column label="æ¥æ" min-width="100" prop="recordDate"></el-table-column> |
| | |
| | | <el-button type="primary" :loading="submitLoading" @click="addPowerSupplyStability1">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :visible.sync="approvalDialog" title="确认" width="30%" @close="subjoin = ''"> |
| | | <span> |
| | | å¢è¡¥ä¿¡æ¯ï¼ |
| | | <el-input v-model="subjoin" type="textarea"></el-input> |
| | | </span> |
| | | <el-dialog :visible.sync="approvalDialog" title="è®°å½åç»å®" width="30%" @open="openDialog"> |
| | | <el-form ref="recordForm" :model="recordForm"> |
| | | <el-form-item label="è®°å½å: "> |
| | | <el-select v-model="recordForm.registrarUserId" clearable filterable placeholder="è¯·éæ©" size="small" |
| | | style="width: 80%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button :loading="approvalLoading" @click="subjoin = '', approvalDialog = false">ä¸ç¡®è®¤</el-button> |
| | | <el-button :loading="approvalLoading" type="primary" @click="handleApproval">确 认</el-button> |
| | | <el-button :loading="approvalLoading" @click="approvalDialog = false">åæ¶</el-button> |
| | | <el-button :loading="approvalLoading" type="primary" @click="handleApproval">ä¿å</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | |
| | | responsibleOptions: [], |
| | | approvalDialog: false, |
| | | approvalLoading: false, |
| | | subjoin: '', |
| | | approvalRow: {}, |
| | | recordForm: { |
| | | registrarUserId: '' |
| | | } |
| | | } |
| | | }, |
| | | mounted() { |
| | |
| | | openApprovalDialog(row) { |
| | | this.approvalDialog = true |
| | | this.approvalRow = row |
| | | this.recordForm.registrarUserId = row.registrarUserId |
| | | }, |
| | | handleApproval() { |
| | | this.approvalLoading = true |
| | | const params = { |
| | | dateId: this.approvalRow.dateId, |
| | | subjoin: this.subjoin, |
| | | registrarUserId: this.recordForm.registrarUserId |
| | | } |
| | | affirmFeTempHumDate(params).then(res => { |
| | | this.approvalLoading = false |
| | |
| | | }, |
| | | clickRow(row) { |
| | | this.saveRow = row |
| | | this.search1.current = 1 |
| | | this.initData1(row.dateId) |
| | | }, |
| | | edit(row) { |
| | |
| | | } |
| | | }); |
| | | }, |
| | | // å¤ææ¸©æ¹¿åº¦åºé´åè² |
| | | tableRowClassName({row, rowIndex}) { |
| | | if (row.isIssue == 1) { |
| | | return 'warning-row'; |
| | | } |
| | | return ''; |
| | | }, |
| | | handleSizeChange(val) { |
| | | this.search.size = val; |
| | | this.initData(); |
| | |
| | | }, |
| | | handleSizeChange1(val) { |
| | | this.search1.size = val; |
| | | this.initData1(); |
| | | this.initData1(this.saveRow.dateId); |
| | | }, |
| | | handleCurrentChange1(val) { |
| | | this.search1.current = val; |
| | | this.initData1(); |
| | | this.initData1(this.saveRow.dateId); |
| | | }, |
| | | clickAdd() { |
| | | this.dialogVisible = true |
| | |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | >>>.warning-row { |
| | | background: #eea7ae; |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="searchForm" ref="searchForm" size="small" :inline="true"> |
| | | <el-form-item label="夿³¨" prop="remark"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.remark"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 48px;font-size: 14px;font-weight: 700;color: #606266;">夿³¨</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="searchForm.remark" |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" @click="openFormDia('add')">æ° å¢</el-button> |
| | | </div> |
| | | |
| | | </div> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="tableColumn" :height="'calc(100vh - 250px)'" @pagination="pagination" |
| | |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="small" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button size="mini" type="primary" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | @keyup.enter.native="searchList"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="form" ref="form" size="small" :inline="true"> |
| | | <el-form-item label="ç©è´¨åç§°"> |
| | | <el-input v-model="form.name"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button @click="reset">é ç½®</el-button> |
| | | <el-button type="primary" @click="getTableData">æ¥ è¯¢</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">ç©è´¨åç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="form.name" |
| | | @keyup.enter.native="getTableData"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" @click="getTableData" size="mini">æ¥è¯¢</el-button> |
| | | <el-button @click="reset" size="mini">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button icon="el-icon-plus" size="small" type="primary" @click="openDialog">æ·»å éªæ¶</el-button> |
| | | <el-button size="small" type="primary" @click="exportExcel">导åº</el-button> |
| | | </div> |
| | |
| | | }, |
| | | methods: { |
| | | getTableData() { |
| | | this.tableLoading = true |
| | | getPageAcceptance({...this.form, ...this.page}).then(res => { |
| | | this.tableLoading = false |
| | | this.tableData = res.data.records; |
| | | this.page.total = res.data.total; |
| | | }).catch(error => { |
| | | this.tableLoading = false |
| | | }) |
| | | }, |
| | | openDialog() { |
| | |
| | | <el-input v-model="searchForm.raiseResult" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm1.fileName" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <template> |
| | | <!-- æä»¶åæ§ç³è¯· --> |
| | | <div> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true"> |
| | | <el-form-item label="ç³è¯·æä»¶ç¼å·" prop="laboratoryName"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.documentCode" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 128px;font-size: 14px;font-weight: 700;color: #606266;">ç³è¯·æä»¶ç¼å·</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.documentCode" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" icon="el-icon-plus" |
| | | @click="addDialogVisible = true, addInfo = {}, file = null">æä»¶åæ§ç³è¯·</el-button> |
| | | </div> |
| | |
| | | delete param.total; |
| | | pageManageDocumentControlled({ ...param }) |
| | | .then((res) => { |
| | | console.log('res',res) |
| | | this.tableLoading = false; |
| | | if (res.code === 200) { |
| | | this.tableData = res.data.records; |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .search { |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 350px; |
| | | display: flex; |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <template> |
| | | <!-- æä»¶åæ´ç³è¯· --> |
| | | <div> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true"> |
| | | <el-form-item label="ç³è¯·æä»¶ç¼å·" prop="code"> |
| | | <el-input v-model="queryParams.code" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 128px;font-size: 14px;font-weight: 700;color: #606266;">ç³è¯·æä»¶ç¼å·</span> |
| | | <el-input v-model="queryParams.code" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" icon="el-icon-plus" |
| | | @click="addDialogVisible = true, addInfo = {}, currentFile = {}, title = 'æä»¶åæ´ç³è¯·', file = null">æä»¶åæ´ç³è¯·</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleOut">导åº</el-button> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æä»¶ç¶æ" prop="state"> |
| | | <el-select v-model="queryParams.state" size="small" @change="refreshTable()"> |
| | | <el-select v-model="queryParams.state" size="small" @change="refreshTable()" clearable> |
| | | <el-option :label="item.label" :value="item.value" v-for="(item, index) in fileState" |
| | | :key="index"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <template> |
| | | <!-- æä»¶ä½åºç³è¯· --> |
| | | <div> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true"> |
| | | <el-form-item label="æä»¶ç¼å·" prop="documentCode"> |
| | | <el-input v-model="queryParams.documentCode" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div style="display: flex;"> |
| | | <div style="margin-bottom: 18px;margin-right: 10px;display: flex;align-items: center;line-height: 32px;"> |
| | | <span style="width: 88px;font-size: 14px;font-weight: 700;color: #606266;">æä»¶ç¼å·</span> |
| | | <el-input v-model="queryParams.documentCode" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <div style="line-height: 30px;"> |
| | | <el-button size="small" type="primary" icon="el-icon-plus" |
| | | @click="addDialogVisible = true, addInfo = {}, file = null">æä»¶ä½åºç³è¯·</el-button> |
| | | @click="addDialogVisible = true, addInfo = {}">æä»¶ä½åºç³è¯·</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleOut">导åº</el-button> |
| | | </div> |
| | | </div> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-button size="small" type="primary" @click="openAdd('æ°å¢')">æ°å¢</el-button> |
| | | <el-upload :action="action" :multiple="false" :show-file-list="false" accept='.doc,.docx' |
| | | :headers="uploadHeader" :on-change="beforeUpload" :on-error="onError" ref='upload' |
| | | :on-success="handleSuccessUp" style="display:inline-block;margin-left: 20px;"> |
| | | :on-success="handleSuccessUp" style="display: inline-block;margin: 0 8px"> |
| | | <el-button type="primary" size="small">导å
¥</el-button></el-upload> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading" |
| | | style="display:inline-block;margin-left: 20px;">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading">导åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-button size="small" type="primary" @click="openAdd">æ°å¢</el-button> |
| | | <el-upload :action="action" :multiple="false" :show-file-list="false" accept='.doc,.docx' |
| | | :headers="uploadHeader" :on-change="beforeUpload" :on-error="onError" ref='upload' |
| | | :on-success="handleSuccessUp" style="display:inline-block;margin-left: 20px;"> |
| | | :on-success="handleSuccessUp" style="display:inline-block;margin: 0 8px;"> |
| | | <el-button type="primary" size="small">导å
¥</el-button></el-upload> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading" |
| | | style="display:inline-block;margin-left: 20px;">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading">导åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-button size="small" type="primary" @click="openAdd">æ°å¢</el-button> |
| | | <el-upload :action="action" :multiple="false" :show-file-list="false" accept='.doc,.docx' |
| | | :headers="uploadHeader" :on-change="beforeUpload" :on-error="onError" ref='upload' |
| | | :on-success="handleSuccessUp" style="display:inline-block;margin-left: 20px;"> |
| | | :on-success="handleSuccessUp" style="display:inline-block;margin: 0 8px;"> |
| | | <el-button type="primary" size="small">导å
¥</el-button></el-upload> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading" |
| | | style="display:inline-block;margin-left: 20px;">导åº</el-button> |
| | | <el-button size="small" type="primary" @click="handleDown" :loading="outLoading">导åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | |
| | | methods: { |
| | | // æ°å¢ |
| | | openAdd() { |
| | | // this.$refs.ValueTable.openAddDia(this.$api.manageRecordIssueRecycle.addManageRecordIssueRecycle); |
| | | this.addInfo = {} |
| | | this.title = 'æ°å¢' |
| | | this.addDialogVisible = true; |
| | |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable(1)">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh(1)">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable(1)">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh(1)">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.department" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.meetingDate" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.purposes" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.raiseResult" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.purpose" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.purpose" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.judgingLocation" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.place" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-input v-model="searchForm.place" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="searchList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetSearchForm">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="searchList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetSearchForm">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | {label: 'æ£éªé¡¹', prop: 'inspectionItem', width: 160}, |
| | | {label: 'æ£éªå项', prop: 'inspectionItemSubclass', width: 160}, |
| | | { label: 'æ¶è´¹æ å(å
/次)', prop: 'rates' }, |
| | | { label: 'åç»ç³»æ°', prop: 'manHourGroup' }, |
| | | ], |
| | | viewInfoDia: false, |
| | | tableLoading: false, |
| | |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="entity" ref="entity" size="small" :inline="true"> |
| | | <el-form-item label="å§æç¼å·" prop="entrustCode"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.entrustCode" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·ååç§°" prop="sample"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.sample" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | { label: 'ä¸åæ¶é´', prop: 'createTime', width: 150 }, |
| | | { label: 'å§æç¼å·', prop: 'entrustCode', width: 160 }, |
| | | { label: 'æ ·ååç§°', prop: 'sample', width: 160 }, |
| | | { label: 'æ ·åæ°é', prop: 'sampleNum' }, |
| | | { label: 'å§æåä½', prop: 'company' }, |
| | | { |
| | | label: "ä¸åç±»å", |
| | | prop: "typeSource", |
| | | width: "100px", |
| | | dataType: "tag", |
| | | formatData: (params) => { |
| | | if (params == 0) { |
| | | return "æåä¸å"; |
| | | } else if(params == 1) { |
| | | return "åææä¸å"; |
| | | } else { |
| | | return null |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params == 0) { |
| | | return "warning"; |
| | | } else if(params == 1) { |
| | | return "info"; |
| | | } else { |
| | | return "null"; |
| | | } |
| | | }, |
| | | }, |
| | | { label: 'å§æäºº', prop: 'prepareUser' }, |
| | | { label: 'ç产åä½', prop: 'production' }, |
| | | { label: 'å·¥ç¨åç§°', prop: 'engineering' }, |
| | | { label: 'å·¥æ¶', prop: 'cost' }, |
| | | { label: 'æ»ä»·', prop: 'totalPrice' }, |
| | | { |
| | | dataType: "action", |
| | | fixed: "right", |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div class="page_total"> |
| | |
| | | case 0: |
| | | // åææ |
| | | this.$router.push({ |
| | | path: "/materialOrder/customsInspection", query: { |
| | | path: "/materialOrder/customsInspectionView", query: { |
| | | customsInspection: row, |
| | | active: this.activeFace, |
| | | currentId: this.currentId, |
| | |
| | | case null: |
| | | // æå |
| | | this.$router.push({ |
| | | path: "/productOrder/add", query: { |
| | | path: "/productOrder/addView", query: { |
| | | examine: this.examine, |
| | | active: this.activeFace, |
| | | currentId: this.currentId |
| | |
| | | case 1: |
| | | // éæ |
| | | this.$router.push({ |
| | | path: "/materialOrder/copperOrder", query: { |
| | | path: "/materialOrder/CopperView", query: { |
| | | active: this.activeFace, |
| | | currentId: this.currentId |
| | | } |
| | |
| | | // æ¥çæ¥å |
| | | handleIssued(row) { |
| | | // todo: æ¥çæ¥åç»ä»¶ |
| | | console.log(this.javaApi) |
| | | this.currentInfo = row; |
| | | let fileName = row.url |
| | | let fileType = "docx" |
| | |
| | | <style scoped> |
| | | .page_total { |
| | | margin-bottom: 10px; |
| | | display: flex; |
| | | } |
| | | .page_total span:last-child { |
| | | color: #3a7bfa; |
| | | font-size: 23px; |
| | | font-weight: 400; |
| | | } |
| | | </style> |
| | |
| | | </el-radio-group> |
| | | </div> |
| | | <div style="display: flex;align-items: center;"> |
| | | <span v-if="typeSource == '1'"> 夿µæ¬¡æ°ï¼</span> |
| | | <el-select v-if="typeSource == '1'" v-model="retestTag" placeholder="è¯·éæ©" size="small" |
| | | <span> 夿µæ¬¡æ°ï¼</span> |
| | | <el-select v-model="retestTag" placeholder="è¯·éæ©" size="small" |
| | | @change="m => handleChangeCableTag(currentSample.id, 4, 'cableTag', m)"> |
| | | <el-option v-for="item in unPassNumList" :key="item.retestTag" :label="item.retestTag" |
| | | :value="item.retestTag"> |
| | |
| | | verifyPlan |
| | | } from "@/api/business/inspectionTask"; |
| | | import { getUserNow, saveUnqualifiedContext } from "@/api/business/rawMaterialOrder"; |
| | | import InspectionWorker from '@/workers/InspectionWorker.worker'; |
| | | import DataWorker from '@/workers/DataWorker.worker'; |
| | | export default { |
| | | props: ['sonLaboratory', 'orderId', 'state', 'inspectorList', 'typeSource', 'unPassCheck', 'rawMaterialTag'], |
| | | props: ['sonLaboratory', 'orderId', 'state', 'inspectorList', 'typeSource', 'unPassCheck', 'rawMaterialTag','cableTag', 'repetitionTag'], |
| | | components: { |
| | | AddUnPass, |
| | | UnPassDialog |
| | |
| | | getDataTypeId: '', |
| | | getDataType: null, |
| | | unPassDialog: false, // ä¸åæ ¼å¤çå¼¹æ¡ |
| | | retestTag: '', // 夿µæ¬¡æ° |
| | | retestTag: '1', // 夿µæ¬¡æ° |
| | | addCheck: false, // æå®å®¡æ ¸äººåå¼¹æ¡ |
| | | checkUser: '', |
| | | type: '', |
| | |
| | | } |
| | | } |
| | | }) |
| | | await this.determineWhetherToCollectData()//æ¯å¦éè¦æ°é |
| | | // await this.determineWhetherToCollectData()//æ¯å¦éè¦æ°é |
| | | if (this.currentSample.index == undefined) this.currentSample['index'] = 1 |
| | | let bushing = this.currentSample.bushing |
| | | this.getTableLists();//å¤ç模æ¿åè¡¨ä¿¡æ¯ |
| | |
| | | this.stopWorker(); // ç¡®ä¿ä¹åç Worker 已忢 |
| | | } |
| | | // å建 Worker å®ä¾ |
| | | this.worker = new Worker('/static/js/worker.js'); |
| | | this.worker = new InspectionWorker(); |
| | | if (this.worker0) { |
| | | this.stopWorker(); // ç¡®ä¿ä¹åç Worker 已忢 |
| | | } |
| | | // å建 Worker å®ä¾ |
| | | this.worker0 = new Worker('/static/js/worker0.js'); |
| | | this.worker0 = new DataWorker(); |
| | | }, |
| | | // 忢å¤çº¿ç¨ |
| | | stopWorker() { |
| | |
| | | laboratory: this.sonLaboratory, |
| | | retestTag: this.retestTag, |
| | | rawMaterialTag: this.rawMaterialTag, |
| | | repetitionTag: this.repetitionTag, |
| | | cableTag: this.cableTag, |
| | | } |
| | | let res = getInsProductUnqualifiedRetest(params) |
| | | let res = await getInsProductUnqualifiedRetest(params) |
| | | console.log('res---', res) |
| | | if (res.code === 200 && res.data.length > 0) { |
| | | this.tableLoading = false; |
| | | this.scrollInit() |
| | |
| | | } |
| | | }) |
| | | // 以䏿¯æ ·å¼å¤çé»è¾ |
| | | set = Array.sort(set) |
| | | // set = Array.sort(set) |
| | | set = [...set] |
| | | set.forEach(b => { |
| | | let arr = [] |
| | | a.template.forEach(c => { |
| | |
| | | }, 200) |
| | | }, |
| | | // æ¯å¦éè¦æ°é |
| | | async determineWhetherToCollectData() { |
| | | let res = determineWhetherToCollectData({ managementNumber: '' }) |
| | | this.isGet = res.data |
| | | }, |
| | | // async determineWhetherToCollectData() { |
| | | // let res = determineWhetherToCollectData({ managementNumber: '' }) |
| | | // this.isGet = res.data |
| | | // }, |
| | | // æ ¹æ®åç«¯ä¼ åæ´æ°é¡µé¢æ°æ® param => this.tableList[0].insProductResult |
| | | getCurrentInsProduct(pId) { |
| | | if (!this.tableList[0].insProductResult) { |
| | |
| | | <template> |
| | | <div class="ins-order-plan-main"> |
| | | <div class="app-container"> |
| | | <div style="height: 100%"> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">å§æç¼å·ï¼</div> |
| | | <div class="search_input"> |
| | | <el-form :model="queryParams" ref="queryParams" size="small" :inline="true"> |
| | | <el-form-item label="å§æç¼å·" prop="entrustCode"> |
| | | <el-input v-model="queryParams.entrustCode" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ£éªç¶æï¼</div> |
| | | <div class="search_input"> |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ£éªç¶æ" prop="insState"> |
| | | <el-select v-model="queryParams.insState" size="small" style="width: 100%" @change="refreshTable()"> |
| | | <el-option v-for="(a, i) in dict.type.inspection_task_state" :key="i" :label="a.label" |
| | | :value="a.value"></el-option> |
| | | :value="a.value"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="mini" type="primary" @click="refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="center" v-loading="tableLoading"> |
| | | <div class="center-options"> |
| | | <div style="display: flex; align-items: center"> |
| | | <span style="font-size: 14px">è¯éªå®¤ç§ç±»:</span> |
| | | <ul class="tab"> |
| | | <li v-for="(m, i) in tabList" :key="i" :class="{ active: i == tabIndex }" @click="handleTab(m, i)"> |
| | | {{ m.label.replace("è¯éªå®¤", "") }} |
| | | </li> |
| | | </ul> |
| | | <div> |
| | | <el-checkbox v-model="alone" class="view-self-checkbox" |
| | | @change="changeCheckBox"><span>æçä»»å¡</span></el-checkbox> |
| | | </div> |
| | | </div> |
| | | <div class="center-title"> |
| | | <span>æ»è®¡ä»»å¡æ°é:</span> |
| | | <span>{{ page.total }}</span> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="center"> |
| | | <div class="center-options"> |
| | | <el-row> |
| | | <el-col :span="21"> |
| | | <div style="display: flex; align-items: center"> |
| | | <span style="font-size: 14px">è¯éªå®¤ç§ç±»:</span> |
| | | <ul class="tab"> |
| | | <li v-for="(m, i) in tabList" :key="i" :class="{ active: i == tabIndex }" @click="handleTab(m, i)"> |
| | | {{ m.label.replace("è¯éªå®¤", "") }} |
| | | </li> |
| | | </ul> |
| | | <div> |
| | | <el-checkbox v-model="alone" class="view-self-checkbox" |
| | | @change="changeCheckBox"><span>æçä»»å¡</span></el-checkbox> |
| | | </div> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="3"> |
| | | <div class="center-title"> |
| | | <span>æ»è®¡ä»»å¡æ°é:</span> |
| | | <span>{{ page.total }}</span> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <lims-table :tableData="tableData" :column="column" :page="page" :tableLoading="tableLoading" |
| | | <lims-table :tableData="tableData" :column="column" :page="page" |
| | | :rowClassName="rowClassName" :height="'calc(100vh - 300px)'" @pagination="pagination" |
| | | key="tableData0"></lims-table> |
| | | key="tableData0"> |
| | | <div slot="action" slot-scope="scope"> |
| | | <el-button size="small" type="text" @click="handleDataLook(scope.row)">æ°æ®æ¥ç</el-button> |
| | | <el-button type="text" size="small" |
| | | :disabled="(scope.row.userName == null || scope.row.insState == 3 || scope.row.insState == 5) && checkPermi(['update:product:onPlan'])" |
| | | @click="editInspection(scope.row)">ä¿®æ¹æ£éªå¼</el-button> |
| | | <el-button type="text" size="small" :disabled="( |
| | | scope.row.userName == null || |
| | | scope.row.insState == 3 || |
| | | scope.row.insState == 5 || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)) |
| | | )" |
| | | @click="handleInspection(scope.row)">æ£éª</el-button> |
| | | <el-button type="text" size="small" :disabled="( |
| | | scope.row.userName == null || |
| | | scope.row.insState == 5 || |
| | | scope.row.insState == 3 || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)) |
| | | )" |
| | | @click="handleConnect(scope.row)">交æ¥</el-button> |
| | | <el-button type="text" size="small" @click="viewInspectInfo(scope.row)">åå§è®°å½</el-button> |
| | | <el-popover placement="bottom" trigger="hover" style="margin-left: 6px" :disabled="(scope.row.insState != 3 || scope.row.userName == null ||(scope.row.userName && !scope.row.userName.includes(nickName)))"> |
| | | <template #reference> |
| | | <el-button link type="text" size="small" :disabled="(scope.row.insState != 3 || scope.row.userName == null || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)))">æ´å¤</el-button> |
| | | </template> |
| | | <div> |
| | | <el-button :disabled="(scope.row.insState != 3 || scope.row.userName == null || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)))" style="margin-left: 10px" type="text" size="small" @click="download(scope.row)">ä¸è½½æ¥å</el-button> |
| | | <el-upload ref='upload' |
| | | :action="javaApi + '/insReport/inReport'" |
| | | :before-upload="beforeUpload" |
| | | :data="{id: scope.row.insReportId}" |
| | | :headers="uploadHeader" :on-error="onError" |
| | | :on-success="handleSuccessUp" |
| | | :show-file-list="false" |
| | | style="display: inline;margin: 0 6px" |
| | | accept='.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar'> |
| | | <el-button :disabled="(scope.row.insState != 3 || scope.row.userName == null || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)))" size="small" type="text">ä¸ä¼ </el-button> |
| | | </el-upload> |
| | | <el-button :disabled="(scope.row.insState != 3 || scope.row.userName == null || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)))" type="text" size="small" @click="handleRestore(scope.row)">è¿å</el-button> |
| | | <el-button :disabled="(scope.row.insState != 3 || scope.row.userName == null || |
| | | (scope.row.userName && !scope.row.userName.includes(nickName)))" type="text" size="small" @click="handleIssued(scope.row)">æ¥çæ¥å</el-button> |
| | | </div> |
| | | </el-popover> |
| | | </div> |
| | | </lims-table> |
| | | </div> |
| | | </div> |
| | | <el-dialog :visible.sync="claimVisible" title="æç¤º" width="400px"> |
| | |
| | | </el-form> |
| | | </div> |
| | | <lims-table :tableData="lookTableData" :column="lookColumn" :page="lookPage" :tableLoading="lookTableLoading" |
| | | :height="'60vh'" @pagination="lookPagination" key="tableData1"></lims-table> |
| | | :height="'60vh'" @pagination="lookPagination" key="tableData1" :key="upIndex"></lims-table> |
| | | </div> |
| | | </el-dialog> |
| | | <el-dialog :visible.sync="bindDialogVisible" title="æ£éªé¡¹ç»å®" width="600px"> |
| | |
| | | <viewManHourDia ref="viewManHourDia"></viewManHourDia> |
| | | <!--ä¸åæ ¼å¤æµæ¥çå¼¹æ¡--> |
| | | <un-pass-retest-result v-if="retestVisible" :retestInfo="retestInfo" :retestVisible="retestVisible" @closeRetestLook="closeRetestLook"></un-pass-retest-result> |
| | | <!--æ¥åæ¥ç--> |
| | | <el-dialog title="æ¥åæ¥ç" :visible.sync="issuedVisible" width="80vw" :modal-append-to-body="false" |
| | | :fullscreen="fullscreen"> |
| | | <div class="full-screen"> |
| | | <i class="el-icon-full-screen" style="cursor: pointer;font-size: 18px" @click="fullscreen = true;" |
| | | v-if="!fullscreen"></i> |
| | | <img src="@/assets/images/no-full.svg" alt="" v-else style="cursor: pointer;" @click="fullscreen = false;"> |
| | | </div> |
| | | <div style="height: 80vh;" v-if="issuedVisible"> |
| | | <onlyoffice ref="onlyoffice" :options="option" style="width: 100%;height: 100%;" /> |
| | | </div> |
| | | </el-dialog> |
| | | <el-dialog title="æ¥çéä»¶" :visible.sync="lookDialogVisible" width="800px" top="5vh" fullscreen> |
| | | <filePreview v-if="lookDialogVisible" :fileUrl="javaApi + '/word/' + currentInfo.tempUrlPdf" :currentFile="{}" |
| | | style="max-height: 90vh;overflow-y: auto;" /> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { getYearAndMonthAndDays } from "@/utils/date"; |
| | | |
| | | import EditInspectionItem from "./components/EditInspectionItem.vue"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import viewManHourDia from "./components/viewManHourDia.vue" |
| | |
| | | } from "@/api/business/inspectionTask.js"; |
| | | import { mapGetters } from "vuex"; |
| | | import {getRetestResult} from "@/api/business/rawMaterialOrder"; |
| | | import {upReportUrl} from "@/api/business/insReport"; |
| | | import onlyoffice from "@/components/Onlyoffice/onlyoffice.vue"; |
| | | import filePreview from "@/components/Preview/filePreview.vue"; |
| | | export default { |
| | | name: 'InspectionTask', |
| | | components: { |
| | | filePreview, onlyoffice, |
| | | EditInspectionItem, |
| | | limsTable, |
| | | viewManHourDia, |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | issuedVisible: false, |
| | | fullscreen: false, |
| | | lookDialogVisible: false, |
| | | option: null, |
| | | InspectionKey: 1, |
| | | bindDialogVisible: false, |
| | | bindAddDialogVisible: false, |
| | |
| | | { label: "æ£éªå¼å§æ¶é´", prop: "insTime", width: "140px" }, |
| | | { label: "çç±", prop: "verifyTell", width: "140px" }, |
| | | { |
| | | dataType: "action", |
| | | fixed: "right", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | | name: "æ°æ®æ¥ç", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleDataLook(row); |
| | | }, |
| | | }, |
| | | { |
| | | name: "ä¿®æ¹æ£éªå¼", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.editInspection(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return (row.userName == null || row.insState == 3 || row.insState == 5) && this.checkPermi(['update:product:onPlan']) |
| | | }, |
| | | }, |
| | | // { |
| | | // name: "æ¥çå·¥æ¶", |
| | | // type: "text", |
| | | // clickFun: (row) => { |
| | | // this.viewManHour(row); |
| | | // }, |
| | | // showHide: (row) => { |
| | | // return this.checkPermi(['get:working:hours:byOrder']) |
| | | // }, |
| | | // }, |
| | | { |
| | | name: "æ£éª", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleInspection(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return ( |
| | | row.userName == null || |
| | | row.insState == 3 || |
| | | row.insState == 5 || |
| | | (row.userName && !row.userName.includes(this.nickName)) |
| | | ); |
| | | }, |
| | | }, |
| | | { |
| | | name: "交æ¥", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleConnect(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return ( |
| | | row.userName == null || |
| | | row.insState == 5 || |
| | | row.insState == 3 || |
| | | (row.userName && !row.userName.includes(this.nickName)) |
| | | ); |
| | | }, |
| | | }, |
| | | { |
| | | name: "åå§è®°å½", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.viewInspectInfo(row); |
| | | }, |
| | | }, |
| | | ], |
| | | }, |
| | | dataType: "slot", |
| | | slot: "action", |
| | | width: '340px', |
| | | label: "æä½" |
| | | } |
| | | ], |
| | | page: { |
| | | total: 0, |
| | |
| | | lookTableLoading: false, |
| | | // æ°æ®æ¥çç¸å
³å段---ç»æ |
| | | retestVisible: false, |
| | | upIndex: 0 |
| | | }; |
| | | }, |
| | | mounted() { |
| | |
| | | }, |
| | | activated() { |
| | | this.getAuthorizedPerson(); |
| | | this.queryParams.userId = this.userId; |
| | | this.currentTime = getYearAndMonthAndDays(); |
| | | this.getDicts("urgency_level").then((response) => { |
| | | this.urgencyLevel = this.dictToValue(response.data); |
| | |
| | | if (res.code === 200) { |
| | | this.lookTableData = res.data.records; |
| | | this.lookPage.total = res.data.total; |
| | | this.upIndex++ |
| | | this.dataDialogVisible = true; |
| | | } |
| | | }) |
| | |
| | | this.page.current = 1; |
| | | this.queryParams.typeSource = this.tabIndex; |
| | | this.getList(); |
| | | }, |
| | | // ä¸è½½æ¥å |
| | | download(row) { |
| | | let url = (row.urlS===null||row.urlS==='')?row.url:row.urlS |
| | | const link = document.createElement('a'); |
| | | link.href = this.javaApi + url; |
| | | link.target = '_blank'; |
| | | document.body.appendChild(link); |
| | | link.click(); |
| | | }, |
| | | // è¿åæä½ |
| | | handleRestore(row) { |
| | | this.$confirm('æ¯å¦è¿åå½åæ¥å?', "è¦å", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(() => { |
| | | upReportUrl({ id: row.insReportId }).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('è¿åæå') |
| | | this.refreshTable() |
| | | } |
| | | }) |
| | | }).catch(() => { }) |
| | | |
| | | }, |
| | | // æ¥çæ¥å |
| | | handleIssued(row) { |
| | | console.log('================') |
| | | // todo: æ¥çæ¥åç»ä»¶ |
| | | this.currentInfo = row; |
| | | let fileName = row.url |
| | | let fileType = "docx" |
| | | if (row.tempUrlPdf != null || row.tempUrlPdf === '') { |
| | | fileName = row.tempUrlPdf |
| | | fileType = "pdf" |
| | | } |
| | | fileName = fileName.replace('/word/','') |
| | | const userName = this.nickName |
| | | this.option = { |
| | | url: this.javaApi + "/word/" + fileName, |
| | | isEdit: false, |
| | | fileType: fileType, |
| | | title: fileName, |
| | | lang: 'zh-CN', |
| | | isPrint: false, |
| | | user_id: 1, |
| | | user_name: userName, |
| | | editUrl: this.javaApi + "/insReport/onlyOffice/save?fileName=" + fileName |
| | | } |
| | | this.issuedVisible = true; |
| | | }, |
| | | // æ¥ç产ä¸é¾ä¿¡æ¯ |
| | | openInfoDialog(row) { |
| | |
| | | case 0: |
| | | // åææ |
| | | this.$router.push({ |
| | | path: "/materialOrder/customsInspection", query: { |
| | | path: "/materialOrder/customsInspectionView", query: { |
| | | customsInspection: row, |
| | | active: this.activeFace, |
| | | currentId: this.currentId, |
| | |
| | | case null: |
| | | // æå |
| | | this.$router.push({ |
| | | path: "/productOrder/add", query: { |
| | | path: "/productOrder/addView", query: { |
| | | examine: this.examine, |
| | | active: this.activeFace, |
| | | currentId: this.currentId |
| | |
| | | case 1: |
| | | // éæ |
| | | this.$router.push({ |
| | | path: "/materialOrder/copperOrder", query: { |
| | | path: "/materialOrder/CopperView", query: { |
| | | active: this.activeFace, |
| | | currentId: this.currentId |
| | | } |
| | |
| | | this.bindCurrentInfo = row; |
| | | getBindingProductByProductId({ productId: row.insProductId }) |
| | | .then((res) => { |
| | | // console.log(res) |
| | | this.bindTableData = res.data; |
| | | this.bindDialogVisible = true; |
| | | }) |
| | |
| | | productId: this.bindCurrentInfo.insProductId, |
| | | }) |
| | | .then((res) => { |
| | | // console.log(res) |
| | | this.bindAddTableData = res.data; |
| | | this.bindAddDialogVisible = true; |
| | | }) |
| | |
| | | }); |
| | | }); |
| | | }, |
| | | beforeUpload (file) { |
| | | if (file.size > 1024 * 1024 * 10) { |
| | | this.$message.error('ä¸ä¼ æä»¶ä¸è¶
è¿10M'); |
| | | this.$refs.upload.clearFiles() |
| | | return false; |
| | | } else { |
| | | return true; |
| | | } |
| | | }, |
| | | onError(error, file, fileList, index) { |
| | | this.$message.error('æä»¶ä¸ä¼ 失败ï¼è¯·éè¯'); |
| | | }, |
| | | onExceed() { |
| | | this.$message.warning("è¶
åºæä»¶ä¸ªæ°"); |
| | | }, |
| | | handleSuccessUp(response) { |
| | | if (response.code == 200) { |
| | | this.$refs.upload.clearFiles() |
| | | this.$message.success("ä¸ä¼ æå"); |
| | | this.refreshTable() |
| | | } else { |
| | | this.$message.error(response.message); |
| | | } |
| | | }, |
| | | }, |
| | | }; |
| | | </script> |
| | | <style scoped> |
| | | .search { |
| | | background-color: #fff; |
| | | height: 40px; |
| | | display: flex; |
| | | align-items: center; |
| | | margin-top: 20px; |
| | | } |
| | | |
| | | .search_thing { |
| | | display: flex; |
| | | align-items: center; |
| | |
| | | |
| | | .search_input { |
| | | width: calc(100% - 120px); |
| | | } |
| | | |
| | | .ins-order-plan-main .search { |
| | | width: 100%; |
| | | height: 40px; |
| | | background-color: #fff; |
| | | border-radius: 3px; |
| | | } |
| | | |
| | | .ins-order-plan-main .center { |
| | | background-color: #fff; |
| | | border-radius: 3px; |
| | | padding: 20px; |
| | | padding-top: 0px; |
| | | } |
| | | |
| | | .tab { |
| | |
| | | border-color: #3a7bfa; |
| | | color: #3a7bfa; |
| | | } |
| | | |
| | | .center .center-options .center-title { |
| | | width: 100%; |
| | | .center-options { |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: right; |
| | | justify-content: space-between; |
| | | } |
| | | |
| | | .center .center-options .center-title span:last-child { |
| | |
| | | |
| | | .view-self-checkbox { |
| | | margin-left: 50px; |
| | | } |
| | | </style> |
| | | <style> |
| | | .ins-order-plan-main .el-form-item__label { |
| | | color: #000; |
| | | } |
| | | </style> |
| | |
| | | <el-button :loading="reviewLoading" type="primary" @click="upInsReview(1)">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!-- æ·»å ä¸åæ ¼å¤æµå¼¹æ¡--> |
| | | <add-un-pass v-if="addUnPassDialog" ref="addUnPassDialog" :addUnPassDialog="addUnPassDialog" |
| | | @resetAddUnPass="resetAddUnPass"></add-un-pass> |
| | | <!-- ä¸åæ ¼å¤çå¼¹æ¡--> |
| | | <UnPassDialog v-if="unPassDialog" ref="unPassDialog" :orderId="orderId" :unPassDialog="unPassDialog" |
| | | @resetForm="resetForm"></UnPassDialog> |
| | | <!-- ä¸åæ ¼å¤æµå¼¹æ¡--> |
| | | <InspectionWord v-if="unPassCheck" :inspectorList="inspectorList" :orderId="orderId" |
| | | :cableTag="temCableTag" :repetitionTag="repetitionTag" |
| | | :rawMaterialTag="rawMaterialTag" :sonLaboratory="sonLaboratory" :state="state" :typeSource="typeSource" |
| | | :unPassCheck="unPassCheck" @closeUnPassCheckDialog="closeUnPassCheckDialog" @refreshView="refreshView" /> |
| | | <!-- è¿è´§éªè¯å¼¹æ¡--> |
| | | <purchase-verification v-if="purchaseDialog" ref="purchaseDialog" :orderId="orderId" |
| | | :purchaseDialog="purchaseDialog" @resetPurchaseDialog="resetPurchaseDialog"></purchase-verification> |
| | | <!--æ¥çå·¥æ¶å¼¹æ¡--> |
| | |
| | | delfile, |
| | | inspectionOrderDetailsTaskSwitching |
| | | } from "@/api/business/inspectionTask.js"; |
| | | import InspectionWorker from '../../../InspectionWorker.worker'; |
| | | import DataWorker from '../../../DataWorker.worker'; |
| | | import InspectionWorker from '@/workers/InspectionWorker.worker'; |
| | | import DataWorker from '../../../workers/DataWorker.worker'; |
| | | import html2canvas from "html2canvas"; |
| | | import { mapGetters } from "vuex"; |
| | | import viewManHourDia from "@/views/business/inspectionTask/components/viewManHourDia.vue"; |
| | |
| | | id: this.currentSample.id, |
| | | type: this.type, |
| | | laboratory: this.sonLaboratory, |
| | | cableTag: "", |
| | | cableTag: this.temCableTag, |
| | | rawMaterialTag: this.rawMaterialTag, |
| | | repetitionTag: this.repetitionTag, |
| | | }; |
| | | this.$nextTick(() => { |
| | | this.$refs.addUnPassDialog.getInsOrder(info); |
| | |
| | | this.dataAcquisitionInfo = {}; |
| | | this.getData = []; |
| | | for (let i in this.objectOrder(data)) { |
| | | console.log("i---", i); |
| | | let obj = {}; |
| | | if (i.includes("@")) { |
| | | obj = { |
| | |
| | | }, |
| | | // ä¿åæ¹¿åº¦ãæ¸©åº¦æ°æ® |
| | | subOtherForm(m, type) { |
| | | console.log("m---", m); |
| | | write({ |
| | | [type]: type === "remark" ? m : Number(m), |
| | | id: this.insOrder.id, |
| | |
| | | this.comparisonList = this.dictToValue(response.data); |
| | | }); |
| | | }, |
| | | // è·åæ£éªå¼ä¸ºä¸ææ¶ç䏿å表 |
| | | // selectEnumByCategoryOfSelect(val) { |
| | | // this.enumList = []; |
| | | // if (val === undefined || val === null) { |
| | | // return; |
| | | // } |
| | | // this.$axios |
| | | // .post(this.$api.enums.selectEnumByCategory, { |
| | | // category: val, |
| | | // }) |
| | | // .then((res) => { |
| | | // this.enumList = res.data; |
| | | // }); |
| | | // }, |
| | | tableRowClassName({ row, rowIndex }) { |
| | | row.index = rowIndex + 1; |
| | | }, |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div v-loading="loading" class="inspection" style="background-color: rgb(245, 247, 251);"> |
| | | <el-row class="title"> |
| | | <el-col :span="8" style="text-align: left"> |
| | | <el-form :inline="true" :model="otherForm" class="form-inline" label-width="50px" |
| | | style="text-align: right; padding-top: 0; display: inline"> |
| | | <el-form-item label="温度:" style="margin-bottom: 0"> |
| | | <el-input v-model="otherForm.temperature" :disabled="state > 1" placeholder="" size="small" |
| | | style="width: 90px; line-height: 60px" @change="(m) => subOtherForm(m, 'temperature')"></el-input> |
| | | <span style="margin-left: 4px">â</span> |
| | | </el-form-item> |
| | | <el-form-item label="湿度:" style="margin-bottom: 0"> |
| | | <el-input v-model="otherForm.humidity" :disabled="state > 1" placeholder="" size="small" |
| | | style="width: 90px; line-height: 60px" @change="(m) => subOtherForm(m, 'humidity')"></el-input> |
| | | <span style="margin-left: 4px">%</span> |
| | | </el-form-item> |
| | | </el-form> |
| | | </el-col> |
| | | <el-col :span="16" style="text-align: right"> |
| | | <el-button size="small" type="primary" @click="refreshView">å·æ°</el-button> |
| | | <el-button v-if="typeSource == 1" size="small" type="primary" @click="openPurchase">è¿è´§éªè¯</el-button> |
| | | <el-button v-if="state == 1 && typeSource == 1" size="small" type="primary" |
| | | @click="openUnPassDialog('add')">ä¸åæ ¼å¤ç</el-button> |
| | | <el-button size="small" type="primary" @click="sampleVisible = true; uploadSample();">æ ·å忢</el-button> |
| | | <!-- <el-button v-if="state == 1" size="small" type="primary" @click="taskVisible = true">ä»»å¡åæ¢</el-button>--> |
| | | <el-button v-if="state == 1" size="small" type="primary" @click="addVerifyDia = true">æäº¤</el-button> |
| | | <!-- 夿 ¸ --> |
| | | <el-button v-if="state == 2" size="medium" type="primary" @click="openAddCheck">éè¿</el-button> |
| | | <el-button v-if="state == 2" size="medium" @click="upInsReview(0)">ä¸éè¿</el-button> |
| | | <el-button type="primary" size="small" @click="exportTable('myTable')">ä¸è½½åå§è®°å½</el-button> |
| | | <el-button size="small" @click="goback">è¿å</el-button> |
| | | </el-col> |
| | | </el-row> |
| | | <div class="search"> |
| | | <el-form :inline="true" :model="searchForm" class="form-inline" label-position="right" label-width="100px"> |
| | | <el-form-item label="å§æç¼å·:"> |
| | | <el-input v-model="insOrder.entrustCode" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·åç¼å·:"> |
| | | <el-tooltip :content="currentSample.sampleCode" :disabled="!currentSample.sampleCode"> |
| | | <el-input v-model="currentSample.sampleCode" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-tooltip> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·ååç§°:"> |
| | | <el-input v-model="currentSample.sample" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·åæ°é:"> |
| | | <el-input v-model="sampleProduct.length" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·ååå·:"> |
| | | <el-input v-model="currentSample.model" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ä¸åæ¶é´:"> |
| | | <el-input v-model="insOrder.sendTime" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ç´§æ¥ç¨åº¦:"> |
| | | <el-input v-model="insOrder.typeName" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="çº¦å®æ¶é´:"> |
| | | <el-input v-model="insOrder.appointed" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item v-if="typeSource === 1" label="æ½æ£æ°é:"> |
| | | <el-input v-model="insOrder.testQuantity" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item v-if="typeSource === 1" label="åå®¶å¯åº¦:"> |
| | | <el-input v-model="supplierDensity" clearable disabled placeholder="请è¾å
¥" size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="å½åæ ·å使°:" label-width="120px"> |
| | | <el-tag v-if="currentKey">{{ `NO.${currentKey}` }}</el-tag> |
| | | </el-form-item> |
| | | <el-form-item label="夿³¨:"> |
| | | <!-- <span style="color:red">{{ insOrder.remark?insOrder.remark:'-' }}</span>--> |
| | | <el-input v-model="insOrder.remark" :disabled="state != 1" clearable placeholder="请è¾å
¥" size="small" |
| | | @blur="subOtherForm(insOrder.remark, 'remark')"></el-input> |
| | | <!-- <el-tag v-if="currentKey">{{ insOrder.remark }}</el-tag> --> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="center"> |
| | | <div class="search" style=" |
| | | text-align: left; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: space-between; |
| | | "> |
| | | <div style="display: flex; align-items: center"> |
| | | <span v-if="tableList.length > 0">æ£éªæ¨¡æ¿ï¼</span> |
| | | <el-radio-group v-model="currentTable" size="small"> |
| | | <el-radio-button v-for="(item, index) in tableLists" :key="index" :label="item.templateId" size="small">{{ |
| | | item.templateName }}</el-radio-button> |
| | | </el-radio-group> |
| | | </div> |
| | | <div style="display: flex; align-items: center"> |
| | | <el-button v-if="state == 1" size="small" type="primary" @click="openAddUnpass">æ°å¢ä¸åæ ¼å¤æµ</el-button> |
| | | <el-button v-if="state == 1" size="small" type="primary" @click="unpassCheck">ä¸åæ ¼å¤æµ</el-button> |
| | | <el-button v-if="state > 1" size="small" type="primary" @click="viewUnpassCheck">æ¥çä¸åæ ¼å¤æµ</el-button> |
| | | <span v-if="cableTagList.length > 0"> çµç¼é
ç½®ï¼</span> |
| | | <el-select v-if="cableTagList.length > 0" v-model="currentTab" clearable placeholder="è¯·éæ©" size="small" |
| | | @change="(m) => handleChangeCableTag(currentSample.id, 0, 'cableTag', m) |
| | | " @focus="getCableTag(currentSample.id)"> |
| | | <el-option v-for="item in cableTagList" :key="item.cableTag" :label="item.cableTag" :value="item.cableTag"> |
| | | <span style="float: left">{{ item.cableTag }}</span> |
| | | <el-tag v-if="item.status == 0" size="small" style="float: right; margin-top: 5px" |
| | | type="danger">æªæ£</el-tag> |
| | | <el-tag v-if="item.status == 1" size="small" style="float: right; margin-top: 5px" |
| | | type="warning">æ£éªä¸</el-tag> |
| | | <el-tag v-if="item.status == 2" size="small" style="float: right; margin-top: 5px" |
| | | type="success">å·²æ£</el-tag> |
| | | </el-option> |
| | | </el-select> |
| | | <span v-if="repetitionTagList.length > 0"> é夿£éªé¡¹ï¼</span> |
| | | <el-select v-if="repetitionTagList.length > 0" v-model="repetitionTag" clearable placeholder="è¯·éæ©" |
| | | size="small" @change="(m) => |
| | | handleChangeCableTag(currentSample.id, 0, 'repetitionTag', m) |
| | | " @focus="getRepetitionTag(currentSample.id)"> |
| | | <el-option v-for="item in repetitionTagList" :key="item.repetitionTag" :label="item.radius" |
| | | :value="item.repetitionTag"> |
| | | <span style="float: left">{{ item.radius }}</span> |
| | | <el-tag v-if="item.status == 0" size="small" style="float: right; margin-top: 5px" |
| | | type="danger">æªæ£</el-tag> |
| | | <el-tag v-if="item.status == 1" size="small" style="float: right; margin-top: 5px" |
| | | type="warning">æ£éªä¸</el-tag> |
| | | <el-tag v-if="item.status == 2" size="small" style="float: right; margin-top: 5px" |
| | | type="success">å·²æ£</el-tag> |
| | | </el-option> |
| | | </el-select> |
| | | <span v-if="typeSource == '1'"> å¾
æ£éªæ°éï¼</span> |
| | | <el-select v-if="typeSource == '1'" v-model="rawMaterialTag" placeholder="è¯·éæ©" size="small" @change="(m) => handleChangeCableTag(currentSample.id, 4, 'cableTag', m) |
| | | " @focus="getRawMaterialTag(currentSample.id)"> |
| | | <el-option v-for="item in rawMaterialTagList" :key="item.rawMaterialTag" :label="item.rawMaterialTag" |
| | | :value="item.rawMaterialTag"> |
| | | <span style="float: left">{{ item.rawMaterialTag }}</span> |
| | | <el-tag v-if="item.status == 0" size="small" style="float: right; margin-top: 5px" |
| | | type="danger">æªæ£</el-tag> |
| | | <el-tag v-if="item.status == 1" size="small" style="float: right; margin-top: 5px" |
| | | type="warning">æ£éªä¸</el-tag> |
| | | <el-tag v-if="item.status == 2" size="small" style="float: right; margin-top: 5px" |
| | | type="success">å·²æ£</el-tag> |
| | | </el-option> |
| | | </el-select> |
| | | <el-button :loading="dataAcquisitionLoading" v-if="state == 1" size="small" type="primary" |
| | | @click="getDataAcquisitionDevice">æ°æ®éé</el-button> |
| | | <el-button :type="dataAcquisitionEidtAble ? '' : 'primary'" v-if="state == 1" size="small" |
| | | @click="dataAcquisitionEidtAble = !dataAcquisitionEidtAble">{{ dataAcquisitionEidtAble ? "å
³éç¼è¾" : "ç¼è¾æ°é" |
| | | }}</el-button> |
| | | </div> |
| | | </div> |
| | | <!-- å¸¸è§æ£éªåå§è®°å½ --> |
| | | <div id="nav" v-loading="tableLoading" class="center-box"> |
| | | <template v-if=" |
| | | tableLists.find((m) => m.templateId == currentTable)"> |
| | | <table v-for="(item, index) in tableList" :key="index + currentTable + currentSample.id" border="1" |
| | | cellpadding="10" class="tables" id="myTable"> |
| | | <tbody> |
| | | <tr style="white-space: nowrap"> |
| | | å§æç¼å·ï¼{{ |
| | | insOrder.entrustCode |
| | | }} |
| | | </tr> |
| | | <tr v-for="(m, i) in item.arr" :key="i"> |
| | | <td v-for="(n, j) in m" v-if="n.v.mc == undefined || Object.keys(n.v.mc).length === 4" |
| | | :id="item.templateId + '-' + n.i + '-' + n.r + '-' + n.c" :key="j" |
| | | :colspan="n.v.mc && n.v.mc.cs ? n.v.mc.cs : 1" :rowspan="n.v.mc && n.v.mc.rs ? n.v.mc.rs : 1" :style="`background:${n.v.bg ? n.v.bg : ''};color:${n.v.fc |
| | | };font-size:${n.v.fs}px;width:${handleWidth( |
| | | n |
| | | )}px !important;height:${item.style.rowlen[n.r]}px;font-wight:${n.v.bl ? 'bold' : '' |
| | | };`"> |
| | | <div :class="`content-h-${n.v.ht} content-v-${n.v.vt}`" :style="`width:${handleWidth(n)}px !important;min-height:${item.style.rowlen[n.r] |
| | | }px;`" class="content"> |
| | | <template v-if=" |
| | | n.v.ps != undefined && |
| | | typeof n.v.ps.value === 'string' && |
| | | n.v.ps.value.includes('æ£éªå¼') && |
| | | state == 1 |
| | | "> |
| | | <el-input v-if="getInspectionValueType(n.i) == 1" |
| | | :key="'abc-' + '000' + index + '000' + i + '000' + j" v-model="n.v.v" :disabled="(getInspectionItemType(n.i) == 1 && |
| | | !dataAcquisitionEidtAble) || |
| | | (n.u != userId && n.u != undefined && n.u != '') |
| | | " class="table_input" @change="(m) => |
| | | changeInput( |
| | | m, |
| | | `${item.templateId}-${n.r}-${n.c}-${n.i}`, |
| | | n, |
| | | 'getDataType' |
| | | ) |
| | | " @input="handleInput(n)" @mousewheel.native.prevent @keydown.enter=" |
| | | changeInput( |
| | | '', |
| | | `${item.templateId}-${n.r}-${n.c}-${n.i}`, |
| | | n, |
| | | 'getDataType' |
| | | ) |
| | | "> |
| | | </el-input> |
| | | <el-input v-else-if="getInspectionValueType(n.i) == 2" v-model="n.v.v" :disabled="getInspectionItemType(n.i) == 1 || |
| | | (n.u != userId && n.u != undefined && n.u != '') |
| | | " class="table_input" type="textarea" @change="(m) => |
| | | changeInput( |
| | | m, |
| | | `${item.templateId}-${n.r}-${n.c}-${n.i}`, |
| | | n, |
| | | 'getDataType' |
| | | ) |
| | | " /> |
| | | <!-- <el-select v-else-if="getInspectionValueType(n.i) == 5" v-model="n.v.v" :disabled="state > 1 || |
| | | getInspectionItemType(n.i) == 1 || |
| | | (n.u != userId && n.u != undefined && n.u != '') |
| | | " class="table_input" @change="(m) => |
| | | changeInput( |
| | | m, |
| | | `${item.templateId}-${n.r}-${n.c}-${n.i}`, |
| | | n, |
| | | 'getDataType' |
| | | ) |
| | | " @visible-change="(e) => getDic(e, n.i)"> |
| | | <el-option v-for="(e, i) in enumList" :key="i" :label="e.label" :value="e.value"></el-option> |
| | | </el-select> --> |
| | | <span v-else-if="getInspectionValueType(n.i) == 4" |
| | | :style="`font-family:${n.v.ff} !important;`">/</span> |
| | | </template> |
| | | <template v-else-if="n.v.ps != undefined && n.v.ps.value === 'ç»è®º'"> |
| | | <el-select v-if=" |
| | | (getInspectionValueType(n.i) == 2 || |
| | | getInspectionValueType(n.i) == 5) && |
| | | state == 1 |
| | | " v-model="n.v.v" class="table_input" @change="(m) => |
| | | changeInput( |
| | | m, |
| | | `${item.templateId}-${n.r}-${n.c}-${n.i}`, |
| | | n, |
| | | 'getDataType', |
| | | 'changeSelect' |
| | | ) |
| | | "> |
| | | <el-option :value="1" label="åæ ¼"></el-option> |
| | | <el-option :value="0" label="ä¸åæ ¼"></el-option> |
| | | <el-option :value="3" label="ä¸å¤å®"></el-option> |
| | | <el-option :value="2" label="å¾
å®"></el-option> |
| | | </el-select> |
| | | <template v-if="state > 1"> |
| | | <span v-if="n.v.v === 1" :style="`font-family:${n.v.ff} !important;color: green;`">åæ ¼</span> |
| | | <span v-else-if="n.v.v === 0" :style="`font-family:${n.v.ff} !important;color: red;`">ä¸åæ ¼</span> |
| | | <span v-else-if="n.v.v === 3" |
| | | :style="`font-family:${n.v.ff} !important;color: #3A7BFA;`">ä¸å¤å®</span> |
| | | <span v-else :style="`font-family:${n.v.ff} !important;`">å¾
å®</span> |
| | | </template> |
| | | <template v-if="getInspectionValueType(n.i) != 2 && |
| | | state == 1"> |
| | | <span v-if="n.v.v === 1" :style="`font-family:${n.v.ff} !important;color: green;`">åæ ¼</span> |
| | | <span v-else-if="n.v.v === 0" :style="`font-family:${n.v.ff} !important;color: red;`">ä¸åæ ¼</span> |
| | | <span v-else-if="n.v.v === 3" |
| | | :style="`font-family:${n.v.ff} !important;color: #3A7BFA;`">ä¸å¤å®</span> |
| | | <span v-else :style="`font-family:${n.v.ff} !important;`">å¾
å®</span> |
| | | </template> |
| | | </template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && |
| | | n.v.ps.value === '设å¤ç¼ç ' && |
| | | state == 1 |
| | | "> |
| | | <span>{{ n.v.v }}</span> |
| | | </template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && n.v.ps.value === '设å¤åç§°' |
| | | "> |
| | | <el-select v-model="n.v.v" :disabled="state > 1" class="table_input" filterable multiple |
| | | placeholder="设å¤" remote @change="(val) => changeEquip(val, n)" |
| | | @visible-change="(e) => getEquipOptions(e, n.i)"> |
| | | <el-option v-for="item in equipOptions" :key="item.value" :label="item.label" |
| | | :value="item.value"> |
| | | {{ item.label + "--" + item.value }} |
| | | </el-option> |
| | | </el-select> |
| | | </template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && |
| | | n.v.ps.value === 'è¦æ±å¼' && |
| | | state == 1 |
| | | "> |
| | | <span :style="`font-family:${n.v.ff} !important;`">{{ |
| | | getTell(n.i) |
| | | }}</span> |
| | | </template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && |
| | | n.v.ps.value === '计ç®å¼' && |
| | | state == 1 |
| | | "><span :style="`font-family:${n.v.ff} !important;`">{{ |
| | | toFixed(n.v.v, n.v.ct) |
| | | }}</span></template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && |
| | | n.v.ps.value === 'æç»å¼' && |
| | | state == 1 |
| | | "> |
| | | <span :style="`font-family:${n.v.ff} !important;`">{{ |
| | | toFixed(n.v.v, n.v.ct) |
| | | }}</span> |
| | | </template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && n.v.ps.value === 'æ ·åç¼å·' |
| | | "> |
| | | <div :title="currentSample.sampleCode" style=" |
| | | display: flex; |
| | | flex-wrap: nowrap; |
| | | align-items: center; |
| | | width: 100%; |
| | | "> |
| | | <i class="el-icon-caret-left table_caret" style="width: 16px" @click="caretSample(-1)"></i> |
| | | <div |
| | | :style="`font-family:${n.v.ff} !important;overflow: hidden;white-space: nowrap;width: calc(100% - 32px);`"> |
| | | {{ currentSample.sampleCode }} |
| | | </div> |
| | | <i class="el-icon-caret-right table_caret" style="width: 16px" @click="caretSample(1)"></i> |
| | | </div> |
| | | </template> |
| | | <template v-else-if=" |
| | | n.v.ps != undefined && n.v.ps.value === 'æ ·ååå·' |
| | | "> |
| | | <div v-if=" |
| | | currentSample.model !== undefined && |
| | | currentSample.model !== null |
| | | " :style="`font-family:${n.v.ff} !important;`"> |
| | | {{ currentSample.model }} |
| | | </div> |
| | | </template> |
| | | <span v-else :style="`font-family:${n.v.ff} !important;`" v-html="getValue(n.v)"></span> |
| | | </div> |
| | | </td> |
| | | </tr> |
| | | </tbody> |
| | | </table> |
| | | </template> |
| | | </div> |
| | | <el-upload v-if="state == 1" ref="upload" :action="action" :before-upload="beforeUpload" :data="{ |
| | | orderId: id, |
| | | }" :headers="uploadHeader" :on-error="onError" :on-success="handleSuccessUp" :show-file-list="false" |
| | | accept=".jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar" |
| | | style="width: 80px !important;margin-top: 10px;"> |
| | | <el-button v-if="state == 1" size="small" type="primary">éä»¶ä¸ä¼ </el-button></el-upload> |
| | | <lims-table :tableData="tableData" :column="column" :page="page" :tableLoading="tableLoading" |
| | | :height="'calc(100vh - 290px)'" @pagination="pagination" style="height: 100%; margin-top: 16px"></lims-table> |
| | | </div> |
| | | <el-drawer :size="550" :visible.sync="sampleVisible" title="æ ·å忢"> |
| | | <el-table v-if="sampleVisible" ref="productTable" :current-row-key="currentKey" :data="sampleProduct" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | :row-class-name="tableRowClassName" :row-key="(record) => record.index" border class="el-table" height="100%" |
| | | highlight-current-row tooltip-effect="dark" @row-click="handleChangeSample"> |
| | | <el-table-column :key="Math.random()" align="center" label="åºå·" type="index" width="70px"> |
| | | </el-table-column> |
| | | <el-table-column label="æ ·åç¼å·" min-width="100px" prop="sampleCode" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="æ ·ååå·" min-width="100px" prop="model" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="æ£æµç¶æ" prop="insState" show-overflow-tooltip width="100px"> |
| | | <template slot-scope="scope"> |
| | | <el-tag v-for="(item, i) in typeList" v-if="item.value == scope.row.insState" :key="i" :type="item.type" |
| | | size="medium" style="margin-right: 5px">{{ item.label }}</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æ¯å¦çæ ·" prop="isLeave" show-overflow-tooltip width="95px"> |
| | | <template slot-scope="scope"> |
| | | <span>{{ scope.row.isLeave == 0 ? "å¦" : "æ¯" }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <!-- æ£éªå伿ä¸ä¸ªæ¯å¦æé
奿 ·ååæ®µæ§å¶æ¾ç¤º --> |
| | | <el-table-column v-if="insOrder.mating > 0" label="é
奿 ·ååå·" min-width="130px" prop="joinModel" |
| | | show-overflow-tooltip></el-table-column> |
| | | <el-table-column v-if="insOrder.mating > 0" label="é
奿 ·ååç§°" min-width="130px" prop="joinName" |
| | | show-overflow-tooltip></el-table-column> |
| | | <el-table-column v-if="insOrder.mating > 0" label="é
奿 ·åæ°é" min-width="130px" prop="joinNum" |
| | | show-overflow-tooltip></el-table-column> |
| | | </el-table> |
| | | </el-drawer> |
| | | <el-drawer :size="500" :visible.sync="taskVisible" title="ä»»å¡åæ¢"> |
| | | <lims-table :tableData="tableData0" :column="column0" :page="page0" :tableLoading="tableLoading0" |
| | | :height="'calc(100vh - 90px)'" :currentChange="handleChangeTask"></lims-table> |
| | | </el-drawer> |
| | | <el-dialog :visible.sync="reviewDia" title="æ£éªå¤æ ¸" width="500px"> |
| | | <div v-if="reviewDia" class="body" style="display: flex; padding: 10px"> |
| | | <div class="search_label" style="width: 150px"> |
| | | <span class="required-span">* </span>ä¸éè¿ççç±ï¼ |
| | | </div> |
| | | <div class="search_input" style="width: 100%"> |
| | | <el-input v-model="noReason" :autosize="{ minRows: 4 }" clearable size="small" type="textarea"></el-input> |
| | | </div> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="reviewDia = false">å æ¶</el-button> |
| | | <el-button :loading="reviewLoading" type="primary" @click="handleReviewDia">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :visible.sync="addVerifyDia" title="æå®å¤æ ¸äººå" width="400px"> |
| | | <div class="body" style="display: flex; padding: 10px; align-items: center"> |
| | | <div class="search_label" style="width: 150px"> |
| | | <span class="required-span">*</span>夿 ¸äºº |
| | | </div> |
| | | <div class="search_input" style="width: 100%"> |
| | | <el-select v-model="verifyUser" clearable filterable placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | | <el-option v-for="(item, i) in personList" :key="i" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="addVerifyDia = false">å æ¶</el-button> |
| | | <el-button :loading="submitLoading" type="primary" @click="submit()">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :show-close="false" |
| | | :visible.sync="dataGetDia" title="æ°æ®éé" width="80%"> |
| | | <div> |
| | | <table border="1" cellpadding="10" class="thermal-table"> |
| | | <tr> |
| | | <td style="width: 120px">æ£éªé¡¹åç±»</td> |
| | | <td style="width: 120px">æ£éªé¡¹</td> |
| | | <td style="width: 120px">æ£éªå项</td> |
| | | <td>æ°éæ°æ®</td> |
| | | </tr> |
| | | <template v-for="(item, index) in getData"> |
| | | <tr> |
| | | <td :rowspan="item.child.length">{{ item.sortName }}</td> |
| | | <td :rowspan="item.child.length">{{ item.faName }}</td> |
| | | <td>{{ item.child[0].name }}</td> |
| | | <td style="text-align: left"> |
| | | <el-select v-if="item.child[0].isShowSelect" v-model="item.child[0].getDataIndex1" |
| | | :multiple-limit="item.child[0].maxNum" clearable filterable multiple placeholder="è¯·éæ©" |
| | | @change="setData(item)"> |
| | | <el-option v-for="(item, index) in item.child[0].arr" :key="index" :filter-method="filterMethod" |
| | | :label="index + 1 + '^' + item.result" :value="index + '^' + item.result"> |
| | | <span>{{ |
| | | "åºå·ï¼" + |
| | | (index + 1) + |
| | | "ï¼" + |
| | | "ç»æï¼" + |
| | | item.result + |
| | | "ï¼" + |
| | | "å度ï¼" + |
| | | item.thickness + |
| | | "ï¼" + |
| | | "æ¶é´ï¼" + |
| | | item.mergedDateTime |
| | | }}</span> |
| | | </el-option> |
| | | </el-select> |
| | | <el-checkbox-group v-if="!item.child[0].isShowSelect" v-model="item.child[0].getDataIndex1" |
| | | :max="item.child[0].maxNum"> |
| | | <el-checkbox v-for="(n, j) in item.child[0].arr" :key="j" :label="j + '^' + n">{{ n }}</el-checkbox> |
| | | </el-checkbox-group> |
| | | </td> |
| | | </tr> |
| | | <tr v-for="(m, i) in item.child" v-show="i > 0" :key="i + 'bbbbbbbbbbbbbb'"> |
| | | <td>{{ m.name }}</td> |
| | | <td style="text-align: left"> |
| | | <el-select v-if="m.isShowSelect" v-model="m.getDataIndex1" :multiple-limit="m.maxNum" clearable |
| | | filterable multiple placeholder="è¯·éæ©"> |
| | | <el-option v-for="(item, index1) in m.arr" :key="index1" :label="index + 1 + '^' + item.result" |
| | | :value="index1 + '^' + item.result"> |
| | | <span>{{ |
| | | "åºå·ï¼" + |
| | | (index1 + 1) + |
| | | "ï¼" + |
| | | "ç»æï¼" + |
| | | item.result + |
| | | "ï¼" + |
| | | "å度ï¼" + |
| | | item.thickness + |
| | | "ï¼" + |
| | | "æ¶é´ï¼" + |
| | | item.mergedDateTime |
| | | }}</span> |
| | | </el-option> |
| | | </el-select> |
| | | <el-checkbox-group v-if="!m.isShowSelect" v-model="m.getDataIndex1" :max="m.maxNum"> |
| | | <el-checkbox v-for="(n, j) in m.arr" :key="j" :label="j + '^' + n">{{ n }}</el-checkbox> |
| | | </el-checkbox-group> |
| | | </td> |
| | | </tr> |
| | | </template> |
| | | </table> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="dataGetDia = false">å æ¶</el-button> |
| | | <el-button :loading="getDataIndexLoading" type="primary" @click="submitDataGet()">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :close-on-click-modal="false" :visible.sync="addCheck" title="æå®æ¥åå®¡æ ¸äººå" width="400px" |
| | | @close="closeAddVerifyDia"> |
| | | <div class="body" style="display: flex; padding: 10px; align-items: center"> |
| | | <div class="search_label" style="width: 150px"> |
| | | <span class="required-span">*</span>å®¡æ ¸äººï¼ |
| | | </div> |
| | | <div class="search_input" style="width: 100%"> |
| | | <el-select v-model="checkUser" clearable filterable placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | | <el-option v-for="(item, i) in personList" :key="i" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="closeAddVerifyDia">å æ¶</el-button> |
| | | <el-button :loading="reviewLoading" type="primary" @click="upInsReview(1)">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!-- æ·»å ä¸åæ ¼å¤æµå¼¹æ¡--> |
| | | <add-un-pass v-if="addUnPassDialog" ref="addUnPassDialog" :addUnPassDialog="addUnPassDialog" |
| | | @resetAddUnPass="resetAddUnPass"></add-un-pass> |
| | | <!-- ä¸åæ ¼å¤çå¼¹æ¡--> |
| | | <UnPassDialog v-if="unPassDialog" ref="unPassDialog" :orderId="orderId" :unPassDialog="unPassDialog" |
| | | @resetForm="resetForm"></UnPassDialog> |
| | | <!-- ä¸åæ ¼å¤æµå¼¹æ¡--> |
| | | <InspectionWord v-if="unPassCheck" :inspectorList="inspectorList" :orderId="orderId" |
| | | :rawMaterialTag="rawMaterialTag" :sonLaboratory="sonLaboratory" :state="state" :typeSource="typeSource" |
| | | :unPassCheck="unPassCheck" @closeUnPassCheckDialog="closeUnPassCheckDialog" @refreshView="refreshView" /> |
| | | <!-- è¿è´§éªè¯å¼¹æ¡--> |
| | | <purchase-verification v-if="purchaseDialog" ref="purchaseDialog" :orderId="orderId" |
| | | :purchaseDialog="purchaseDialog" @resetPurchaseDialog="resetPurchaseDialog"></purchase-verification> |
| | | <!--æ¥çå·¥æ¶å¼¹æ¡--> |
| | | <viewManHourDia ref="viewManHourDia" @submit="openAddVerifyDia"></viewManHourDia> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import excelFunction from "@/utils/excelFountion"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import UnPassDialog from "../unpass/components/unPassDialog.vue"; |
| | | import AddUnPass from "../unpass/components/addUnPass.vue"; |
| | | import InspectionWord from "../inspectionTask/components/InspectionWord.vue"; |
| | | import PurchaseVerification from "../unpass/components/PurchaseVerification.vue"; |
| | | import { |
| | | doInsOrder, |
| | | getCableTag, |
| | | getRepetitionTag, |
| | | getRawMaterialTag, |
| | | dataCollection, |
| | | write, |
| | | getInsProduct, |
| | | search, |
| | | verifyPlan, |
| | | checkSubmitPlan, |
| | | submitPlan, |
| | | saveInsContext, |
| | | selectUserCondition, |
| | | downFile, |
| | | getFileList, |
| | | delfile, |
| | | inspectionOrderDetailsTaskSwitching |
| | | } from "@/api/business/inspectionTask.js"; |
| | | import InspectionWorker from '@/workers/InspectionWorker.worker'; |
| | | import DataWorker from '../../../workers/DataWorker.worker'; |
| | | import html2canvas from "html2canvas"; |
| | | import { mapGetters } from "vuex"; |
| | | import viewManHourDia from "@/views/business/inspectionTask/components/viewManHourDia.vue"; |
| | | export default { |
| | | name: 'InspectionView', |
| | | components: { |
| | | viewManHourDia, |
| | | PurchaseVerification, |
| | | AddUnPass, |
| | | limsTable, |
| | | UnPassDialog, |
| | | InspectionWord, |
| | | }, |
| | | data() { |
| | | return { |
| | | sonLaboratory: null, |
| | | orderId: null, |
| | | state: null, |
| | | inspectorList: null, |
| | | typeSource: null, |
| | | sagData: [], |
| | | sagForm: { |
| | | sampleCode: null, |
| | | model: null, |
| | | inspection: null, |
| | | methodName: null, |
| | | tensileForce: null, |
| | | spanLength: null, |
| | | load: null, |
| | | }, |
| | | dataGetDia: false, |
| | | fileAdd: false, |
| | | sampleVisible: false, |
| | | taskVisible: false, |
| | | submitLoading: false, |
| | | searchForm: { |
| | | sampleName: null, |
| | | state: null, |
| | | }, |
| | | id: null, |
| | | changeType: null, |
| | | insOrder: {}, |
| | | sampleProduct: [], |
| | | supplierDensity: "", // åå®¶å¯åº¦ |
| | | typeList: [], |
| | | urgentList: [], |
| | | currentSample: {}, //å½åæ ·åä¿¡æ¯ |
| | | tableList: [], |
| | | loading: false, |
| | | ps: {}, |
| | | param: {}, |
| | | currentKey: 1, |
| | | currentKey0: 1, |
| | | currentKey1: 1, |
| | | currentKey2: 1, |
| | | comparisonList: [], |
| | | excelMethodList: [], |
| | | equipOptions: [], |
| | | reviewLoading: false, |
| | | reviewDia: false, |
| | | noReason: "", |
| | | tableWidth: 1000, |
| | | currentTable: null, |
| | | tableLists: [], |
| | | widthList: [], |
| | | addVerifyDia: false, |
| | | verifyUser: null, |
| | | personList: [], |
| | | enumList: [], |
| | | tableLoading: false, |
| | | upLoading: false, |
| | | temptList: null, |
| | | currentTab: null, |
| | | wareForm: { |
| | | inspectionItem: 1, |
| | | inspectionItemSubclass: "20(常温)", |
| | | }, |
| | | otherForm: { |
| | | humidity: null, |
| | | temperature: null, |
| | | }, |
| | | equipForm: { |
| | | value0: null, |
| | | code0: null, |
| | | value1: null, |
| | | code1: null, |
| | | }, |
| | | result: null, |
| | | worker: null, |
| | | worker0: null, |
| | | wareLength: [], |
| | | dataAcquisitionInfo: {}, |
| | | dataAcquisitionInfoNew: {}, |
| | | dataAcquisitionEidtAble: false, |
| | | dataAcquisitionLoading: false, |
| | | collected: false, |
| | | temDataAcquisition: false, |
| | | getData: [ |
| | | { |
| | | faName: "æ³¢é¿éå è¡°å", |
| | | child: [ |
| | | { |
| | | name: "1285nm~1330nm", |
| | | arr: [12, 13, 14, 15], |
| | | }, |
| | | { |
| | | name: "1525nm~1575nm", |
| | | arr: [12, 13, 14, 15], |
| | | }, |
| | | ], |
| | | }, |
| | | { |
| | | faName: "æªè³æ³¢é¿", |
| | | child: [ |
| | | { |
| | | name: "æªè³æ³¢é¿", |
| | | arr: [12, 13, 14, 15], |
| | | }, |
| | | ], |
| | | }, |
| | | ], |
| | | getDataIndex: [], |
| | | getDataIndexLoading: false, |
| | | getDataTypeId: "", |
| | | getDataType: null, |
| | | unPassDialog: false, // ä¸åæ ¼å¤çå¼¹æ¡ |
| | | cableTagList: [], |
| | | rawMaterialTag: "", // æ¹æ¬¡ |
| | | rawMaterialTagList: [], // æ¹æ¬¡é项 |
| | | addCheck: false, // æå®å®¡æ ¸äººåå¼¹æ¡ |
| | | checkUser: "", |
| | | addUnPassDialog: false, |
| | | type: "", |
| | | retestTag: "", |
| | | unPassCheck: false, |
| | | unPassTableList: [], |
| | | unPassTableLoading: false, |
| | | purchaseDialog: false, // è¿è´§éªè¯åå§è®°å½å¼¹æ¡ |
| | | temCableTag: "", |
| | | repetitionTagList: [], |
| | | repetitionTag: "", |
| | | // æä»¶å表ç¸å
³--å¼å§ |
| | | tableData: [], |
| | | column: [ |
| | | { |
| | | label: "ç±»å", prop: "type", dataType: "tag", |
| | | formatData: (params) => { |
| | | if (params == 1) { |
| | | return 'å¾ç' |
| | | } else { |
| | | return 'æä»¶' |
| | | } |
| | | } |
| | | }, |
| | | { label: "éä»¶åç§°", prop: "fileName" }, |
| | | { label: "ä¸ä¼ 人", prop: "name" }, |
| | | { label: "ä¸ä¼ æ¶é´", prop: "createTime" }, |
| | | { |
| | | dataType: "action", |
| | | fixed: "right", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | | name: "ä¸è½½", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleDown(row); |
| | | }, |
| | | }, |
| | | { |
| | | name: "å é¤", |
| | | type: "text", |
| | | clickFun: (row) => { |
| | | this.handleDelete(row); |
| | | }, |
| | | disabled: (row) => { |
| | | return this.state != 1; |
| | | }, |
| | | }, |
| | | ], |
| | | }, |
| | | ], |
| | | page: { |
| | | total: 0, |
| | | size: 10, |
| | | current: 0, |
| | | }, |
| | | tableLoading: false, |
| | | // æä»¶å表ç¸å
³--ç»æ |
| | | // ä»»å¡åæ¢å表--å¼å§ |
| | | tableData0: [], |
| | | column0: [ |
| | | { label: "å§æç¼å·", prop: "entrustCode", width: '160px' }, |
| | | { label: "æ£éªå¯¹è±¡", prop: "sampleType", width: '140px' }, |
| | | { |
| | | label: "ç´§æ¥ç¨åº¦", prop: "type", dataType: "tag", |
| | | formatData: (params) => { |
| | | return this.urgentList.find(m => m.value == params).label |
| | | }, |
| | | formatType: (params) => { |
| | | return this.urgentList.find(m => m.value == params).type |
| | | } |
| | | }, |
| | | { |
| | | label: "ç¶æ", prop: "insState", dataType: "tag", |
| | | formatData: (params) => { |
| | | return this.typeList.find(m => m.value == params).label |
| | | }, |
| | | formatType: (params) => { |
| | | return this.typeList.find(m => m.value == params).type |
| | | } |
| | | }, |
| | | { label: "çº¦å®æ¶é´", prop: "appointed", width: '140px' }, |
| | | { label: "ä¸åæ¶é´", prop: "sendTime", width: '140px' }, |
| | | ], |
| | | page0: { |
| | | total: 0, |
| | | size: -1, |
| | | current: -1, |
| | | }, |
| | | tableLoading0: false, |
| | | // ä»»å¡åæ¢å表--ç»æ |
| | | }; |
| | | }, |
| | | // ç¨äºä¸ä¼ æä»¶çä¿¡æ¯ |
| | | computed: { |
| | | ...mapGetters(["userId"]), |
| | | action() { |
| | | return this.javaApi + "/insOrderPlan/uploadFile"; |
| | | }, |
| | | }, |
| | | created() { |
| | | let { sonLaboratory, orderId, state, inspectorList, typeSource } = |
| | | this.$route.query; |
| | | this.sonLaboratory = sonLaboratory; |
| | | this.orderId = orderId; |
| | | this.id = this.orderId; |
| | | this.state = state; |
| | | this.inspectorList = inspectorList; |
| | | this.typeSource = typeSource; |
| | | }, |
| | | mounted() { |
| | | this.getTypeDicts(); // è·åç´§æ¥ç¨åº¦ä¸ææ¡é项 |
| | | this.getInsStateDicts(); |
| | | this.getComparisonList(); |
| | | this.getAuthorizedPerson(); |
| | | this.startWorker(); |
| | | // this.getList0() // ä»»å¡åæ¢ |
| | | this.scrollInit(); |
| | | }, |
| | | activated() { |
| | | this.getTypeDicts(); // è·åç´§æ¥ç¨åº¦ä¸ææ¡é项 |
| | | this.getInsStateDicts(); |
| | | this.getComparisonList(); |
| | | this.getAuthorizedPerson(); |
| | | this.startWorker(); |
| | | // this.getList0() // ä»»å¡åæ¢ |
| | | this.scrollInit(); |
| | | }, |
| | | watch: { |
| | | // çå¬ä»»å¡idï¼è·åä»»å¡ä¿¡æ¯ |
| | | id(val) { |
| | | this.refreshView() |
| | | }, |
| | | // çå¬å½å模æ¿åå |
| | | currentTable(val1, val0) { |
| | | if (val0 != null && val1 != val0) { |
| | | if (this.changeType && this.changeType > 0) { |
| | | // 妿æ¯å
纤ãå
纤带ï¼å䏿§è¡ä¸é¢æä½ |
| | | return; |
| | | } |
| | | this.tableLists.forEach(async (m, i) => { |
| | | if (m.templateId == val1) { |
| | | let list = await this.getCurrentProduct(this.currentSample.id, 0); |
| | | this.currentSample.insProduct = this.HaveJson(list); //èµå¼å½åæ ·åçæ£éªé¡¹ |
| | | this.param = {}; //åå§åä¼ å°å端çåæ° |
| | | this.currentSample.insProduct.forEach((a, j) => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | | comValue: [], |
| | | resValue: null, |
| | | equipValue: [], |
| | | equipName: [], |
| | | insResult: null, |
| | | }; |
| | | }); |
| | | // å»é模æ¿ï¼è¿åæå ä¸ªæ¨¡æ¿ |
| | | const mySet1 = new Set(); |
| | | this.tableLists = this.currentSample.insProduct.filter((m) => { |
| | | let num0 = mySet1.size; |
| | | if (m.templateId != null && m.template != null) { |
| | | try { |
| | | mySet1.add( |
| | | JSON.stringify({ |
| | | template: m.template, |
| | | templateId: m.templateId, |
| | | }) |
| | | ); |
| | | } catch (error) { |
| | | console.log(222, error); |
| | | } |
| | | } |
| | | let num1 = mySet1.size; |
| | | if (num1 > num0) { |
| | | return m; |
| | | } |
| | | }); |
| | | if (this.tableLists && this.tableLists.length > 0) { |
| | | this.tableList = null; |
| | | this.tableList = this.tableLists.filter( |
| | | (m) => m.templateId == val1 |
| | | ); |
| | | // 对模æ¿è¿è¡å¤ç |
| | | this.handleTableData(); |
| | | } |
| | | } |
| | | }); |
| | | } |
| | | }, |
| | | // ç¹æ®æ£éªé¡¹--çå¬è®¾å¤ä¿¡æ¯æ¹å |
| | | equipForm: { |
| | | deep: true, |
| | | handler(val) { }, |
| | | }, |
| | | }, |
| | | beforeDestroy() { |
| | | // å¨ç»ä»¶éæ¯åç¡®ä¿åæ¢ Workerï¼é¿å
å
åæ³æ¼ |
| | | this.stopWorker(); |
| | | }, |
| | | methods: { |
| | | // æä»¶ç®¡ç--å¼å§ |
| | | getList() { |
| | | this.tableLoading = true; |
| | | let param = { ...this.page }; |
| | | delete param.total; |
| | | getFileList({ insOrderId: this.id, ...param }) |
| | | .then((res) => { |
| | | this.tableLoading = false; |
| | | if (res.code === 200) { |
| | | this.tableData = res.data.records; |
| | | this.page.total = res.data.total; |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | this.tableLoading = false; |
| | | }); |
| | | }, |
| | | pagination({ page, limit }) { |
| | | this.page.current = page; |
| | | this.page.size = limit; |
| | | this.getList(); |
| | | }, |
| | | handleDelete(row) { |
| | | this.$confirm("æ¯å¦å é¤è¯¥æ¡æ°æ®?", "æç¤º", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning", |
| | | }).then(() => { |
| | | delfile({ id: row.id }).then((res) => { |
| | | this.$message.success("å 餿å"); |
| | | this.getList(); |
| | | }); |
| | | }).catch(() => { }); |
| | | }, |
| | | // æä»¶ç®¡ç--ç»æ |
| | | |
| | | // ä»»å¡åæ¢--å¼å§ |
| | | getList0() { |
| | | this.tableLoading0 = true; |
| | | let param = { userId: this.userId, sonLaboratory: this.sonLaboratory, ...this.page0 }; |
| | | delete param.total; |
| | | inspectionOrderDetailsTaskSwitching({ ...param }) |
| | | .then((res) => { |
| | | this.tableLoading0 = false; |
| | | if (res.code === 200) { |
| | | this.tableData0 = res.data.records; |
| | | } |
| | | }) |
| | | .catch((err) => { |
| | | this.tableLoading0 = false; |
| | | }); |
| | | }, |
| | | // ä»»å¡åæ¢--ç»æ |
| | | |
| | | closeAddVerifyDia() { |
| | | this.addCheck = false; |
| | | this.checkUser = ""; |
| | | }, |
| | | // å·æ°é¡µé¢ |
| | | refreshView() { |
| | | this.loading = true; |
| | | doInsOrder({ |
| | | id: this.id, |
| | | laboratory: this.sonLaboratory, |
| | | }).then(async (res) => { |
| | | this.insOrder = res.data.insOrder; |
| | | this.supplierDensity = res.data.supplierDensity; |
| | | this.getList() |
| | | this.urgentList.forEach((m) => { |
| | | if (m.value == this.insOrder.type) { |
| | | this.insOrder.typeName = m.label; |
| | | } |
| | | }); |
| | | this.loading = false; |
| | | if (!res.data.sampleProduct || res.data.sampleProduct.length == 0) { |
| | | this.goback(); |
| | | return this.$message.error("è¯¥ä»»å¡æ²¡ææ ·åä¿¡æ¯"); |
| | | } |
| | | // èµå¼å½åæ ·åå表 |
| | | this.sampleProduct = res.data.sampleProduct; |
| | | this.currentSample = this.HaveJson(this.sampleProduct[0]); |
| | | let insProduct = this.HaveJson(this.currentSample.insProduct); |
| | | // æ¸©åº¦ãæ¹¿åº¦èµå¼ |
| | | this.otherForm = { |
| | | temperature: this.insOrder.temperature |
| | | ? this.insOrder.temperature |
| | | : null, |
| | | humidity: this.insOrder.humidity ? this.insOrder.humidity : null, |
| | | }; |
| | | if (this.typeSource == "1") { |
| | | this.getRawMaterialTag(this.currentSample.id); // åææçæ£éªä»»å¡æ¥è¯¢æ¹æ° |
| | | this.rawMaterialTag = "1"; |
| | | } |
| | | this.getEquipOptions(1); |
| | | // è·åå½åæ ·åçæ£éªé¡¹ |
| | | let list = await this.getCurrentProduct(this.currentSample.id, 0); |
| | | this.currentSample.insProduct = this.HaveJson(list); |
| | | // åå§åä¼ éå°å端çåæ° |
| | | this.param = {}; |
| | | this.changeType = 0; |
| | | this.currentSample.insProduct.forEach((a) => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | | comValue: [], |
| | | resValue: null, |
| | | equipValue: [], |
| | | equipName: [], |
| | | insResult: null, |
| | | }; |
| | | }); |
| | | if (this.currentSample.index == undefined) |
| | | this.currentSample["index"] = 1; |
| | | let bushing = this.currentSample.bushing; |
| | | this.getTableLists(); //å¤ç模æ¿åè¡¨ä¿¡æ¯ |
| | | |
| | | this.currentKey = 1; |
| | | this.getCableTag(this.currentSample.id); // æ¥è¯¢æ¯å¦æè¦å¤æ¬¡æ£éªççµç¼é
ç½® |
| | | this.getRepetitionTag(this.currentSample.id); // æ¥è¯¢æ¯å¦æè¦é夿£éªé¡¹ |
| | | }); |
| | | }, |
| | | closeUnPassCheckDialog() { |
| | | this.unPassCheck = false; |
| | | }, |
| | | // æ¥è¯¢æ¯å¦æè¦å¤æ¬¡æ£éªççµç¼é
ç½® |
| | | getCableTag() { |
| | | getCableTag({ |
| | | id: this.currentSample.id, |
| | | laboratory: this.sonLaboratory, |
| | | }).then((res) => { |
| | | if (res.code === 200 && res.data.length > 0) { |
| | | this.cableTagList = res.data; |
| | | } |
| | | }); |
| | | }, |
| | | // æ¥è¯¢æ¯å¦æè¦é夿£éªé¡¹ |
| | | getRepetitionTag() { |
| | | getRepetitionTag({ |
| | | id: this.currentSample.id, |
| | | laboratory: this.sonLaboratory, |
| | | cableTag: this.temCableTag, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | this.repetitionTagList = res.data; |
| | | } |
| | | }); |
| | | }, |
| | | getRawMaterialTag() { |
| | | getRawMaterialTag({ |
| | | id: this.currentSample.id, |
| | | laboratory: this.sonLaboratory, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | res.data.forEach((item) => { |
| | | this.rawMaterialTagList = res.data; |
| | | }); |
| | | } |
| | | }); |
| | | }, |
| | | // æ·»å éè¦å¤æµçä¸åæ ¼æ£éªé¡¹ |
| | | openAddUnpass() { |
| | | this.addUnPassDialog = true; |
| | | const info = { |
| | | id: this.currentSample.id, |
| | | type: this.type, |
| | | laboratory: this.sonLaboratory, |
| | | cableTag: "", |
| | | rawMaterialTag: this.rawMaterialTag, |
| | | }; |
| | | this.$nextTick(() => { |
| | | this.$refs.addUnPassDialog.getInsOrder(info); |
| | | }); |
| | | }, |
| | | resetAddUnPass() { |
| | | this.addUnPassDialog = false; |
| | | }, |
| | | // è¿è¡ä¸åæ ¼å¤æµ |
| | | unpassCheck() { |
| | | this.unPassCheck = true; |
| | | this.retestTag = "1"; |
| | | }, |
| | | viewUnpassCheck() { |
| | | this.unPassCheck = true; |
| | | this.retestTag = "1"; |
| | | }, |
| | | // æå¼ä¸åæ ¼å¤çå¼¹æ¡ |
| | | openUnPassDialog(type) { |
| | | this.unPassDialog = true; |
| | | this.$nextTick(() => { |
| | | this.$refs.unPassDialog.getInsOrder(type); |
| | | }); |
| | | }, |
| | | // å
³éä¸åæ ¼å¤çå¼¹æ¡ |
| | | resetForm() { |
| | | this.$refs.unPassDialog.$refs["unPassForm"].resetFields(); |
| | | this.unPassDialog = false; |
| | | }, |
| | | // æå¼è¿è´§éªè¯å¼¹æ¡ |
| | | openPurchase() { |
| | | const operationType = this.state == 1 ? "add" : "view"; |
| | | this.purchaseDialog = true; |
| | | const item = { |
| | | id: this.currentSample.id, |
| | | sonLaboratory: this.sonLaboratory, |
| | | cableTag: this.temCableTag, |
| | | rawMaterialTag: this.rawMaterialTag, |
| | | typeSource: this.typeSource, |
| | | }; |
| | | this.$nextTick(() => { |
| | | this.$refs.purchaseDialog.getInsOrder(operationType, item); |
| | | }); |
| | | }, |
| | | resetPurchaseDialog() { |
| | | this.$refs.purchaseDialog.$refs["purchaseForm"].resetFields(); |
| | | this.purchaseDialog = false; |
| | | }, |
| | | // æ°æ®éé |
| | | getDataAcquisitionDevice() { |
| | | let itemIds = []; |
| | | this.currentSample.insProduct.forEach((item) => { |
| | | if (item.inspectionItemType === "1") { |
| | | itemIds.push(item.id); |
| | | } |
| | | }); |
| | | const params = { |
| | | entrustCode: this.insOrder.entrustCode, |
| | | sampleCode: this.currentSample.sampleCode, |
| | | id: this.currentSample.id, |
| | | itemIds: itemIds, |
| | | }; |
| | | this.dataAcquisitionLoading = true; |
| | | dataCollection(params).then((res) => { |
| | | this.dataAcquisitionLoading = false; |
| | | if (res.code != 200) { |
| | | return; |
| | | } |
| | | this.dataAcquisitionInfoNew = this.HaveJson(res.data); |
| | | // 对æ°é忥çå¼è¿è¡å¤ç |
| | | this.handleDataAcquisition(res.data); |
| | | }).catch(err => { |
| | | this.dataAcquisitionLoading = false; |
| | | }); |
| | | }, |
| | | objectOrder(obj) { |
| | | let newkey = Object.keys(obj).sort(); |
| | | let newObj = {}; |
| | | for (let i = 0; i < newkey.length; i++) { |
| | | newObj[newkey[i]] = obj[newkey[i]]; |
| | | } |
| | | return newObj; |
| | | }, |
| | | handleDataAcquisition(data, noDialog) { |
| | | // æ¯å¦å¯ä»¥ç¼è¾æ°éæ°æ® |
| | | if (this.dataAcquisitionEidtAble) { |
| | | this.getDataType = 1; |
| | | } else { |
| | | this.getDataType = 2; |
| | | } |
| | | this.dataAcquisitionInfo = {}; |
| | | this.getData = []; |
| | | for (let i in this.objectOrder(data)) { |
| | | let obj = {}; |
| | | if (i.includes("@")) { |
| | | obj = { |
| | | faName: i.split("@")[0], |
| | | sortName: i.split("@")[1], |
| | | child: [], |
| | | }; |
| | | } else { |
| | | obj = { |
| | | faName: i, |
| | | child: [], |
| | | }; |
| | | } |
| | | // å¾ªç¯æ°éæ°æ® |
| | | for (let j in data[i]) { |
| | | // æ¼æ¥å符串 æ£éªé¡¹åç±»+æ£éªé¡¹+æ£éªå项 |
| | | let str0 = ""; |
| | | if (i.includes("@")) { |
| | | if (i.split("@")[0] == j) { |
| | | str0 = i.split("@")[0] + ","; |
| | | } else { |
| | | str0 = i.split("@")[1] + "," + i.split("@")[0] + "," + j; |
| | | } |
| | | } else { |
| | | if (i == j) { |
| | | str0 = i + ","; |
| | | } else { |
| | | str0 = i + "," + j; |
| | | } |
| | | } |
| | | if ( |
| | | j != "frequency" && |
| | | data[i][j] && |
| | | (!data[i][j].result || typeof data[i][j].result == "string") |
| | | ) { |
| | | // å¤çæ°éä¿¡æ¯æ ¼å¼ |
| | | if (data[i][j].result) { |
| | | this.dataAcquisitionInfo[str0] = { |
| | | value: data[i][j].result, |
| | | frequency: data[i].frequency, |
| | | }; |
| | | } |
| | | let list = this.tableList[0].arr; |
| | | // 循ç¯é¡µé¢å表信æ¯ï¼å¤ææ°éæ°æ®å¯¹åºé¡µé¢å表信æ¯çæ£éªé¡¹æ¯åªä¸ªï¼å¹¶ç»å½åæ£éªé¡¹ç»å®è®¾å¤ä¿¡æ¯ |
| | | list.forEach((item, index) => { |
| | | let num0 = 0; |
| | | let str = ""; |
| | | item.forEach((m) => { |
| | | if ( |
| | | m.v.ps && |
| | | (m.v.ps.value == "æ£éªå项" || |
| | | m.v.ps.value == "æ£éªé¡¹" || |
| | | m.v.ps.value == "æ£éªé¡¹åç±»") |
| | | ) { |
| | | if (m.v.ps && m.v.ps.value == "æ£éªé¡¹åç±»") { |
| | | if (num0 == 0) { |
| | | num0++; |
| | | str = m.v.v + ","; |
| | | } |
| | | } |
| | | if (m.v.ps && m.v.ps.value == "æ£éªé¡¹") { |
| | | if (num0 == 1) { |
| | | str = str + m.v.v + ","; |
| | | num0++; |
| | | } else { |
| | | str = m.v.v + ","; |
| | | num0++; |
| | | } |
| | | } |
| | | if (m.v.ps && m.v.ps.value == "æ£éªå项") { |
| | | str = str + m.v.v; |
| | | } |
| | | } |
| | | // ç»å®è®¾å¤ä¿¡æ¯ |
| | | if ( |
| | | data[i][j].equipName && |
| | | data[i][j].equipValue && |
| | | m.v && |
| | | m.v.ps && |
| | | m.v.ps.value == "设å¤åç§°" && |
| | | str0 == str |
| | | ) { |
| | | if (!m.v.v) { |
| | | // this.changeEquip(data[i][j].equipValue,m,data[i][j].equipName) |
| | | } |
| | | } |
| | | }); |
| | | }); |
| | | } else if ( |
| | | j != "frequency" && |
| | | data[i][j] && |
| | | Array.isArray(data[i][j].result) |
| | | ) { |
| | | // 妿è¿åçæ°éæ°æ®æ¯æ°ç»ï¼åå¤çæ°ç» |
| | | // 以ä¸é»è¾ä¸ºè·åæ¯ä¸ªæ£éªé¡¹å¯è¾å
¥çæ£éªå¼çæå¤§ä¸ªæ° |
| | | let str0 = ""; |
| | | if (i.includes("@")) { |
| | | if (i.split("@")[0] == j) { |
| | | str0 = i.split("@")[0] + ","; |
| | | } else { |
| | | str0 = i.split("@")[1] + "," + i.split("@")[0] + "," + j; |
| | | } |
| | | } else { |
| | | if (i == j) { |
| | | str0 = i + ","; |
| | | } else { |
| | | str0 = i + "," + j; |
| | | } |
| | | } |
| | | let list = this.tableList[0].arr; |
| | | let maxNum = 0; |
| | | list.forEach((item, index) => { |
| | | let num0 = 0; |
| | | let str = ""; |
| | | item.forEach((m) => { |
| | | if ( |
| | | m.v.ps && |
| | | (m.v.ps.value == "æ£éªå项" || |
| | | m.v.ps.value == "æ£éªé¡¹" || |
| | | m.v.ps.value == "æ£éªé¡¹åç±»") |
| | | ) { |
| | | if (m.v.ps && m.v.ps.value == "æ£éªé¡¹åç±»") { |
| | | if (num0 == 0) { |
| | | num0++; |
| | | str = m.v.v + ","; |
| | | } |
| | | } |
| | | if (m.v.ps && m.v.ps.value == "æ£éªé¡¹") { |
| | | if (num0 == 1) { |
| | | str = str + m.v.v + ","; |
| | | num0++; |
| | | } else { |
| | | str = m.v.v + ","; |
| | | num0++; |
| | | } |
| | | } |
| | | if (m.v.ps && m.v.ps.value == "æ£éªå项") { |
| | | str = str + m.v.v; |
| | | } |
| | | let num = 0; |
| | | list[index].forEach((n) => { |
| | | if ( |
| | | n.v.ps && |
| | | n.v.ps.value && |
| | | typeof n.v.ps.value == "string" && |
| | | n.v.ps.value.includes("æ£éªå¼") |
| | | ) { |
| | | num++; |
| | | if (str0 == str) { |
| | | maxNum = num; |
| | | } |
| | | } |
| | | }); |
| | | } |
| | | // ç»å®è®¾å¤ |
| | | if ( |
| | | data[i][j].equipName && |
| | | data[i][j].equipValue && |
| | | m.v && |
| | | m.v.ps && |
| | | m.v.ps.value == "设å¤åç§°" && |
| | | str0 == str |
| | | ) { |
| | | if (!m.v.v) { |
| | | // this.changeEquip(data[i][j].equipValue,m,data[i][j].equipName) |
| | | } |
| | | } |
| | | }); |
| | | }); |
| | | // è·å尿大æ£éªå¼è¾å
¥ä¸ªæ°åéç»æ°æ® |
| | | let obj0 = { |
| | | name: j, |
| | | arr: data[i][j].result, |
| | | maxNum: maxNum, |
| | | equipValue: data[i][j].equipValue, |
| | | value: [], |
| | | }; |
| | | // 妿æ°éè¿åçæ°ç»é¿åº¦å¤§äºæå¤§è¾å
¥ä¸ªæ°ï¼åå°æ°éæ°æ®å¨å¼¹æ¡ä¸å±ç¤ºï¼ç¨æ·éæ©éè¦æå¨éæ©æ°éçä¿¡æ¯ |
| | | if ( |
| | | (data[i][j].result && |
| | | Array.isArray(data[i][j].result) && |
| | | data[i][j].result.length > maxNum && |
| | | noDialog !== "noDialog") || |
| | | (obj0.equipValue === "JCZX-ZB-FF01014" && noDialog !== "noDialog") |
| | | ) { |
| | | obj.child.push(obj0); |
| | | } else { |
| | | this.dataAcquisitionInfo[str0] = { |
| | | value: data[i][j].result, |
| | | }; |
| | | } |
| | | } |
| | | } |
| | | // å¾ªç¯æ°éæ°æ® |
| | | if (obj.child.length > 0) { |
| | | obj.child.forEach((m) => { |
| | | this.$set(m, "getDataIndex1", []); |
| | | // 设å¤éæ©ä¸ºæåæºï¼å°±æ¾ç¤ºå¤éä¸ææ¡ |
| | | if (m.equipValue === "JCZX-ZB-FF01014") { |
| | | this.$set(m, "isShowSelect", true); |
| | | } else { |
| | | this.$set(m, "isShowSelect", false); |
| | | } |
| | | }); |
| | | this.getData.push(obj); |
| | | } |
| | | } |
| | | // 妿å卿°éè¿åçæ°ç»é¿åº¦å¤§äºæå¤§è¾å
¥ä¸ªæ°ï¼åå¼¹åºå¼¹æ¡éæ© |
| | | if (this.getData.length > 0) { |
| | | this.dataGetDia = true; |
| | | } else { |
| | | // 妿é½ä¸åå¨ï¼åï¼è¿å
¥å¤çæ°é线ç¨éå»å¤çæ°æ® |
| | | try { |
| | | // å Worker åéæ¶æ¯ï¼å¼å§å¤çé»è¾ |
| | | this.getDataIndexLoading = false; |
| | | this.dataGetDia = false; |
| | | this.getDataTypeId = ""; |
| | | this.worker0.postMessage( |
| | | JSON.stringify({ |
| | | dataAcquisitionInfo: this.dataAcquisitionInfo, |
| | | list: this.tableList[0].arr, |
| | | }) |
| | | ); |
| | | } catch (error) { |
| | | console.log(1111, error); |
| | | } |
| | | } |
| | | // çå¬ Worker è¿åçç»æ |
| | | this.worker0.onmessage = (event) => { |
| | | let result = JSON.parse(event.data); |
| | | if (result.method == "changeInput") { |
| | | // ééåçæ°æ®ï¼éè¦è¿è¡è®¡ç®ç线ç¨è¿è¡è®¡ç® |
| | | let { list, n } = result.value; |
| | | this.$set(this.tableList[0], "arr", list); |
| | | this.changeInput( |
| | | "", |
| | | `${this.currentSample.insProduct[0].templateId}-${n.r}-${n.c}-${n.i}`, |
| | | n |
| | | ); |
| | | } else if (result.getDataTypeId) { |
| | | // è·åå°æ°éæåä¸é¡¹ï¼æ£éªé¡¹çID |
| | | this.getDataTypeId = result.getDataTypeId; |
| | | } |
| | | }; |
| | | this.dataAcquisitionLoading = false; |
| | | }, |
| | | setData(item) { |
| | | if (item.child.length > 1) { |
| | | let arr1 = []; |
| | | // å¤ä¸ªæ£éªå项çè¯ï¼ç¬¬ä¸ä¸ªæ£éªå项éç第å 个ä¸é¢çå°±èµå¼ç¬¬å 个 |
| | | for (let j = 0; j < item.child.length; j++) { |
| | | let arr = []; |
| | | if (j === 0) { |
| | | for (let k = 0; k < item.child[j].getDataIndex1.length; k++) { |
| | | let val1 = item.child[j].getDataIndex1[k]; |
| | | const index = val1.indexOf("^"); |
| | | if (index > -1) { |
| | | val1 = val1.substring(0, index); |
| | | arr.push(val1); |
| | | } |
| | | } |
| | | arr1 = arr; |
| | | } else { |
| | | this.$set(item.child[j], "getDataIndex1", []); |
| | | arr1.map((a) => { |
| | | const value1 = a + "^" + item.child[j].arr[Number(a)].result; |
| | | item.child[j].getDataIndex1.push(value1); |
| | | }); |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | // æåæºæ°é |
| | | filterMethod(val) { |
| | | console.log("val---", val); |
| | | }, |
| | | // 妿å卿°éè¿åçæ°ç»é¿åº¦å¤§äºæå¤§è¾å
¥ä¸ªæ°ï¼åå¼¹åºå¼¹æ¡éæ©ï¼è¿éæ¯å¼¹æ¡çæäº¤ |
| | | submitDataGet() { |
| | | for (let i = 0; i < this.getData.length; i++) { |
| | | for (let j = 0; j < this.getData[i].child.length; j++) { |
| | | // å¯¹ç¨æ·éæ©çæ°éä¿¡æ¯è¿è¡å¤çï¼èµå¼ |
| | | let arr = []; |
| | | for ( |
| | | let k = 0; |
| | | k < this.getData[i].child[j].getDataIndex1.length; |
| | | k++ |
| | | ) { |
| | | if (this.getData[i].child[j].getDataIndex1[k].includes("^")) { |
| | | const index = |
| | | this.getData[i].child[j].getDataIndex1[k].indexOf("^"); |
| | | if (index > -1) { |
| | | this.getData[i].child[j].getDataIndex1[k] = this.getData[ |
| | | i |
| | | ].child[j].getDataIndex1[k].slice( |
| | | index + 1, |
| | | this.getData[i].child[j].getDataIndex1[k].length |
| | | ); |
| | | } |
| | | } |
| | | arr.push(this.getData[i].child[j].getDataIndex1[k]); |
| | | } |
| | | if (this.getData[i].sortName) { |
| | | this.dataAcquisitionInfoNew[ |
| | | this.getData[i].faName + "@" + this.getData[i].sortName |
| | | ][this.getData[i].child[j].name].result = arr; |
| | | } else { |
| | | this.dataAcquisitionInfoNew[this.getData[i].faName][ |
| | | this.getData[i].child[j].name |
| | | ].result = arr; |
| | | } |
| | | } |
| | | } |
| | | this.getDataIndexLoading = true; |
| | | // èµå¼å®æåéè¦å次è¿å
¥å¤çæ°é线ç¨éå»å¤çæ°æ® |
| | | this.handleDataAcquisition(this.dataAcquisitionInfoNew, "noDialog"); |
| | | }, |
| | | // å¤çº¿ç¨ |
| | | startWorker() { |
| | | if (this.worker) { |
| | | this.stopWorker(); // ç¡®ä¿ä¹åç Worker 已忢 |
| | | } |
| | | // å建 Worker å®ä¾ |
| | | this.worker = new InspectionWorker(); |
| | | if (this.worker0) { |
| | | this.stopWorker(); // ç¡®ä¿ä¹åç Worker 已忢 |
| | | } |
| | | // å建 Worker å®ä¾ |
| | | this.worker0 = new DataWorker(); |
| | | }, |
| | | // 忢å¤çº¿ç¨ |
| | | stopWorker() { |
| | | if (this.worker) { |
| | | this.worker.terminate(); |
| | | this.worker = null; |
| | | } |
| | | if (this.worker0) { |
| | | this.worker0.terminate(); |
| | | this.worker0 = null; |
| | | } |
| | | }, |
| | | // ä¿åæ¹¿åº¦ãæ¸©åº¦æ°æ® |
| | | subOtherForm(m, type) { |
| | | write({ |
| | | [type]: type === "remark" ? m : Number(m), |
| | | id: this.insOrder.id, |
| | | }).then((res) => { |
| | | this.$message.success("ä¿åæå"); |
| | | }); |
| | | }, |
| | | exportTable(tableId) { |
| | | // è·åtableå
ç´ |
| | | var table = document.getElementById(tableId); |
| | | |
| | | // 使ç¨html2canvasåºçæcanvas |
| | | html2canvas(table).then(function (canvas) { |
| | | // å建ä¸ä¸ªå¾çå
ç´ |
| | | var img = canvas.toDataURL("image/png"); |
| | | |
| | | // å建ä¸ä¸ªaæ ç¾æ¨¡æç¹å»è¿è¡ä¸è½½ |
| | | var a = document.createElement("a"); |
| | | a.href = img; |
| | | a.download = "table.png"; |
| | | a.click(); |
| | | }); |
| | | }, |
| | | uploadSample() { |
| | | doInsOrder({ |
| | | id: this.id, |
| | | laboratory: this.sonLaboratory, |
| | | }).then(async (res) => { |
| | | this.sampleProduct = res.data.sampleProduct; |
| | | }); |
| | | }, |
| | | // æ ¹æ®ç±»åãä»»å¡idãå®éªå®¤æ¥è·åæ ·åçæ£éªé¡¹ä¿¡æ¯ |
| | | async getCurrentProduct(id, type, cableTag) { |
| | | if (cableTag === undefined) { |
| | | cableTag = ""; |
| | | } |
| | | this.tableLoading = true; |
| | | type = this.typeSource == "1" ? 5 : type; |
| | | this.type = type; |
| | | let res = await getInsProduct({ |
| | | id: id, |
| | | type: type, |
| | | laboratory: this.sonLaboratory, |
| | | cableTag: (cableTag ? cableTag : this.temCableTag), |
| | | rawMaterialTag: this.rawMaterialTag, |
| | | repetitionTag: this.repetitionTag |
| | | }); |
| | | this.tableLoading = false; |
| | | if (res.data.length > 0) { |
| | | return res.data; |
| | | } |
| | | }, |
| | | // åæ¢æ ·å |
| | | async handleChangeSample(row, column, event) { |
| | | // åå§åæ°æ® |
| | | this.param = {}; |
| | | this.sampleVisible = false; |
| | | // èµå¼æ ·å |
| | | this.currentSample = this.HaveJson(row); |
| | | let list = await this.getCurrentProduct(row.id, 0); |
| | | // èµå¼æ ·åæ£éªé¡¹ |
| | | this.currentSample.insProduct = this.HaveJson(list); |
| | | // åå§ååç«¯ä¼ å |
| | | this.param = {}; |
| | | this.changeType = 0; |
| | | this.currentSample.insProduct.forEach((a, j) => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | | comValue: [], |
| | | resValue: null, |
| | | equipValue: [], |
| | | equipName: [], |
| | | insResult: null, |
| | | }; |
| | | }); |
| | | // å¤ç页é¢åè¡¨æ°æ® |
| | | this.getTableLists(); |
| | | this.currentKey = row.index; |
| | | this.currentTab = null; |
| | | // åå¤çº¿ç¨å»ä¿å页é¢åè¡¨æ°æ®,åç«¯ä¼ å,å½å模æ¿ä¿¡æ¯ |
| | | this.worker.postMessage( |
| | | JSON.stringify({ |
| | | modelType: this.sampleProduct[0].model, |
| | | type: "saveData", |
| | | tableList: this.tableList, |
| | | param: this.param, |
| | | currentTable: this.currentTable, |
| | | }) |
| | | ); |
| | | }, |
| | | async handleChangeCableTag(m, type, num, m2) { |
| | | let cableTag = ""; |
| | | let repetitionTag = ""; |
| | | if (num === "cableTag") { |
| | | cableTag = m2; |
| | | this.temCableTag = cableTag; |
| | | this.getRepetitionTag(); |
| | | } |
| | | if (num === "repetitionTag") { |
| | | repetitionTag = m2; |
| | | this.repetitionTag = repetitionTag; |
| | | } |
| | | if (!m2) { |
| | | type = 0; |
| | | } |
| | | this.changeType = type; |
| | | if (m) { |
| | | let list = await this.getCurrentProduct(m, type, cableTag); |
| | | if (list && list.length > 0) { |
| | | this.param = {}; |
| | | list.forEach((a) => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | | comValue: [], |
| | | resValue: null, |
| | | equipValue: [], |
| | | equipName: [], |
| | | insResult: null, |
| | | }; |
| | | }); |
| | | this.getTableLists0(list); |
| | | this.worker.postMessage( |
| | | JSON.stringify({ |
| | | type: "saveData", |
| | | tableList: this.tableList, |
| | | param: this.param, |
| | | currentTable: this.currentTable, |
| | | bushing: m, |
| | | }) |
| | | ); |
| | | } else { |
| | | this.tableLists = []; |
| | | this.tableList = []; |
| | | this.$message.error("æ£éªé¡¹ä¸ºç©º"); |
| | | } |
| | | } |
| | | }, |
| | | // æ¹åä»»å¡ |
| | | handleChangeTask(row) { |
| | | if (row) this.id = row.id; |
| | | this.taskVisible = false; |
| | | }, |
| | | // åå
¸è·åä¿¡æ¯ |
| | | getTypeDicts() { |
| | | this.getDicts("urgency_level").then((response) => { |
| | | this.urgentList = this.dictToValue(response.data); |
| | | }); |
| | | }, |
| | | // åå
¸è·åä¿¡æ¯ |
| | | getInsStateDicts() { |
| | | this.getDicts("inspection_task_state").then((response) => { |
| | | this.typeList = this.dictToValue(response.data); |
| | | }); |
| | | }, |
| | | // åå
¸è·åä¿¡æ¯ |
| | | getComparisonList() { |
| | | this.getDicts("coordinate_transformation").then((response) => { |
| | | this.comparisonList = this.dictToValue(response.data); |
| | | }); |
| | | }, |
| | | tableRowClassName({ row, rowIndex }) { |
| | | row.index = rowIndex + 1; |
| | | }, |
| | | // å¤ç页é¢åè¡¨æ°æ®--å»é,çææ£éªæ¨¡æ¿åæ¢å表 |
| | | getTableLists() { |
| | | const mySet1 = new Set(); |
| | | this.tableLists = this.currentSample.insProduct.filter((m) => { |
| | | let num0 = mySet1.size; |
| | | if (m.templateId != null && m.template != null) { |
| | | try { |
| | | mySet1.add( |
| | | JSON.stringify({ |
| | | template: m.template, |
| | | templateId: m.templateId, |
| | | }) |
| | | ); |
| | | } catch (error) { |
| | | console.log(222, error); |
| | | } |
| | | } |
| | | let num1 = mySet1.size; |
| | | if (num1 > num0) { |
| | | return m; |
| | | } |
| | | }); |
| | | if (this.tableLists && this.tableLists.length > 0) { |
| | | this.tableList = null; |
| | | this.tableList = [this.tableLists[0]]; |
| | | this.currentTable = this.tableLists[0].templateId; |
| | | // å¤ç页é¢åè¡¨æ°æ® |
| | | this.handleTableData(); |
| | | } |
| | | }, |
| | | // å
纤é
ç½®ç¸å
³æ¨¡æ¿tableå表 |
| | | getTableLists0(list) { |
| | | const mySet1 = new Set(); |
| | | this.tableLists = list.filter((m) => { |
| | | let num0 = mySet1.size; |
| | | if (m.templateId != null && m.template != null) { |
| | | try { |
| | | mySet1.add( |
| | | JSON.stringify({ |
| | | template: m.template, |
| | | templateId: m.templateId, |
| | | }) |
| | | ); |
| | | } catch (error) { |
| | | console.log(333, error); |
| | | } |
| | | } |
| | | let num1 = mySet1.size; |
| | | if (num1 > num0) { |
| | | return m; |
| | | } |
| | | }); |
| | | if (this.tableLists && this.tableLists.length > 0) { |
| | | this.tableList = null; |
| | | this.tableList = [this.tableLists[0]]; |
| | | this.currentTable = this.tableLists[0].templateId; |
| | | this.currentSample.insProduct = this.HaveJson(list); |
| | | // å¤ç页é¢åè¡¨æ°æ® |
| | | this.handleTableData(); |
| | | } |
| | | }, |
| | | // å¤ç页é¢åè¡¨æ°æ® |
| | | handleTableData() { |
| | | this.excelMethodList = []; //excel彿°å表 |
| | | this.widthList = this.tableList[0].style.columnlen; //页é¢å®½åº¦--æ ¹æ®æ¨¡æ¿æ¥ç |
| | | // æ¬æ¬¡å¾ªç¯ä¸»è¦å页颿¸²æå±é¢çå¤ç--åå
æ ¼åå¹¶é¢å¤ç |
| | | this.tableList.forEach((a) => { |
| | | let mcList = a.template.filter( |
| | | (b) => |
| | | b.v.mc != undefined && |
| | | b.v.mc.cs != undefined && |
| | | b.v.mc.rs != undefined |
| | | ); |
| | | let count = 0; |
| | | // å° a.template 转æ¢ä¸º Map 以å éæ¥æ¾ |
| | | let templateMap = new Map(); |
| | | a.template.forEach((item) => { |
| | | templateMap.set(`${item.c}-${item.r}`, item); |
| | | }); |
| | | mcList.forEach((b) => { |
| | | let cs = b.v.mc.cs; |
| | | let rs = b.v.mc.rs; |
| | | for (let i = 0; i < cs; i++) { |
| | | for (let i2 = 0; i2 < rs; i2++) { |
| | | let key = `${b.c + i}-${b.r + i2}`; |
| | | let item = templateMap.get(key); |
| | | if (item) { |
| | | let bb = this.HaveJson(b); |
| | | item.v.v = bb.v.v; |
| | | item.v.ps = bb.v.ps; |
| | | item.v.fc = bb.v.fc; |
| | | item.v.fs = bb.v.fs; |
| | | item.v.ht = bb.v.ht; |
| | | item.mc = count; |
| | | } |
| | | } |
| | | } |
| | | count++; |
| | | }); |
| | | }); |
| | | // æ¬æ¬¡å¾ªç¯ä¸»è¦æ¯æ§å¶åå¹¶,以忧嶿£éªé¡¹ä¿¡æ¯æ¯å¦å±ç¤ºåºæ¥,以便åç»æ£éª |
| | | this.tableList.forEach((a) => { |
| | | let dels = new Set(); //éè¦å é¤çè¡ |
| | | let ids = []; //æææ£éªé¡¹çid |
| | | let set3 = new Set(); |
| | | a.template.forEach((b) => { |
| | | let size1 = set3.size; |
| | | let size2 = set3.add(b.r).size; |
| | | if (size1 < size2) { |
| | | let str = ""; |
| | | let str2 = ""; |
| | | let unit2 = ""; |
| | | let count4 = 0; |
| | | let isThree = 0; |
| | | a.template.forEach((c) => { |
| | | // è·åå° æ£éªé¡¹åç±»+æ£éªé¡¹+æ£éªåé¡¹çæ¼æ¥,å¦ææ¨¡æ¿éçä¿¡æ¯è·æ¥å£è¿åçæ£éªé¡¹ä¿¡æ¯è½å¤å¹é
åå±ç¤ºåºæ¥ |
| | | if (b.r === c.r) { |
| | | if ( |
| | | c.v.ps != undefined && |
| | | c.v.ps.value === "æ£éªé¡¹åç±»" && |
| | | count4 === 0 |
| | | ) { |
| | | // ä¸çº§åç±» |
| | | isThree = 1; |
| | | } else if ( |
| | | c.v.ps != undefined && |
| | | c.v.ps.value === "æ£éªé¡¹" && |
| | | count4 === 0 |
| | | ) { |
| | | // äºçº§åç±» |
| | | isThree = 0; |
| | | } |
| | | if (isThree == 0) { |
| | | if (c.v.ps != undefined && c.v.ps.value === "æ£éªé¡¹") { |
| | | if (count4 === 0) { |
| | | if (c.v.v) { |
| | | c.v.v = c.v.v.replace(/\s*/g, ""); |
| | | } |
| | | str += c.v.v; |
| | | count4 += 1; |
| | | } |
| | | } else if ( |
| | | c.v.ps != undefined && |
| | | c.v.ps.value === "æ£éªå项" |
| | | ) { |
| | | if (count4 === 1) { |
| | | if (c.v.v) { |
| | | c.v.v = c.v.v.replace(/\s*/g, ""); |
| | | } |
| | | str += c.v.v; |
| | | count4 += 1; |
| | | } |
| | | } |
| | | } else if (isThree == 1) { |
| | | if (c.v.ps != undefined && c.v.ps.value === "æ£éªé¡¹åç±»") { |
| | | if (count4 === 0) { |
| | | if (c.v.v) { |
| | | c.v.v = c.v.v.replace(/\s*/g, ""); |
| | | } |
| | | str += c.v.v; |
| | | count4 += 1; |
| | | } |
| | | } else if (c.v.ps != undefined && c.v.ps.value === "æ£éªé¡¹") { |
| | | if (count4 === 1) { |
| | | if (c.v.v) { |
| | | c.v.v = c.v.v.replace(/\s*/g, ""); |
| | | } |
| | | str += c.v.v; |
| | | count4 += 1; |
| | | } |
| | | } else if ( |
| | | c.v.ps != undefined && |
| | | c.v.ps.value === "æ£éªå项" |
| | | ) { |
| | | if (count4 === 2) { |
| | | if (c.v.v) { |
| | | c.v.v = c.v.v.replace(/\s*/g, ""); |
| | | } |
| | | str += c.v.v; |
| | | count4 += 1; |
| | | } |
| | | } |
| | | } |
| | | if (str === "æºæ¢°æ§è½å¹²ææä¼¸å¼ºåº¦(纵å)") { |
| | | if (c.v.ps != undefined && c.v.ps.value === "åä½") { |
| | | if (c.v.v) { |
| | | c.v.v = c.v.v.replace(/\s*/g, ""); |
| | | } |
| | | str2 = str + c.v.v; |
| | | unit2 = c.v.v; |
| | | } |
| | | } |
| | | } |
| | | }); |
| | | if (str != "") { |
| | | let count2 = 0; |
| | | for (let i in this.currentSample.insProduct) { |
| | | let inspectionItemClass = |
| | | this.currentSample.insProduct[i].inspectionItemClass == |
| | | null || |
| | | this.currentSample.insProduct[i].inspectionItemClass == |
| | | undefined |
| | | ? "" |
| | | : this.currentSample.insProduct[i].inspectionItemClass; |
| | | inspectionItemClass = inspectionItemClass.replace(/\s*/g, ""); |
| | | let inspectionItem = |
| | | this.currentSample.insProduct[i].inspectionItem == null || |
| | | this.currentSample.insProduct[i].inspectionItem == undefined |
| | | ? "" |
| | | : this.currentSample.insProduct[i].inspectionItem; |
| | | inspectionItem = inspectionItem.replace(/\s*/g, ""); |
| | | let inspectionItemSubclass = |
| | | this.currentSample.insProduct[i].inspectionItemSubclass == |
| | | null || |
| | | this.currentSample.insProduct[i].inspectionItemSubclass == |
| | | undefined |
| | | ? "" |
| | | : this.currentSample.insProduct[i].inspectionItemSubclass; |
| | | inspectionItemSubclass = inspectionItemSubclass.replace( |
| | | /\s*/g, |
| | | "" |
| | | ); |
| | | if (inspectionItemSubclass === "å¹²ææä¼¸å¼ºåº¦(纵å)") { |
| | | // æ£éªå项为'å¹²ææä¼¸å¼ºåº¦(纵å)'æ¶ï¼æ¨¡çéæ¯ä¸¤ä¸ªè®¡ç®å¼å¯¹åºç¸åçæ£éªå¼å¹¶ä¸è®¡ç®æ¹å¼ä¸åï¼è¦æ ¹æ®ç¸åç'åä½'åç¹æ®ç渲æ |
| | | const unit = this.currentSample.insProduct[i].unit; |
| | | if ( |
| | | (this.currentSample.insProduct[i].templateId === |
| | | a.templateId && |
| | | inspectionItemClass + |
| | | inspectionItem + |
| | | inspectionItemSubclass + |
| | | unit === |
| | | str2) || |
| | | (this.currentSample.insProduct[i].templateId === |
| | | a.templateId && |
| | | !unit2.includes("/") && |
| | | inspectionItemClass + |
| | | inspectionItem + |
| | | inspectionItemSubclass === |
| | | str) |
| | | ) { |
| | | ids.push({ |
| | | r: b.r, |
| | | id: this.currentSample.insProduct[i].id, |
| | | product: this.currentSample.insProduct[i], |
| | | }); |
| | | break; |
| | | } |
| | | } else { |
| | | // 妿ç¸ç,é£ä¹è¯´ææ¾å°äº,并䏿idåèµ·æ¥,åç»æ£éªé¡¹ä¹ä¼å¨é¡µé¢ä¸æ¾ç¤ºåºæ¥ |
| | | if ( |
| | | this.currentSample.insProduct[i].templateId === |
| | | a.templateId && |
| | | inspectionItemClass + |
| | | inspectionItem + |
| | | inspectionItemSubclass === |
| | | str |
| | | ) { |
| | | ids.push({ |
| | | r: b.r, |
| | | id: this.currentSample.insProduct[i].id, |
| | | product: this.currentSample.insProduct[i], |
| | | }); |
| | | break; |
| | | } |
| | | } |
| | | count2++; |
| | | } |
| | | if (count2 == this.currentSample.insProduct.length) { |
| | | dels.add(b.r); |
| | | } |
| | | } |
| | | } |
| | | }); |
| | | // æä½å é¤ |
| | | dels.forEach((del) => { |
| | | for (let b = 0; b < a.template.length; b++) { |
| | | if (a.template[b].r === del) { |
| | | a.template.splice(b, 1); |
| | | b -= 1; |
| | | } |
| | | } |
| | | }); |
| | | // æä½èµå¼--主è¦èµå¼åä½,è¯éªæ¹æ³çä¿¡æ¯ |
| | | ids.forEach((id) => { |
| | | for (let b = 0; b < a.template.length; b++) { |
| | | if (a.template[b].r === id.r) { |
| | | a.template[b].i = id.id; |
| | | if ( |
| | | a.template[b].v.ps != undefined && |
| | | a.template[b].v.ps.value === "åä½" |
| | | ) { |
| | | a.template[b].v.v = id.product.unit; |
| | | } |
| | | if ( |
| | | a.template[b].v.ps != undefined && |
| | | (a.template[b].v.ps.value === "è¯éªæ¹æ³" || |
| | | a.template[b].v.ps.value === "æ£æµæ¹æ³") |
| | | ) { |
| | | a.template[b].v.v = id.product.methodS; |
| | | } |
| | | } |
| | | } |
| | | }); |
| | | let set2 = new Set(); |
| | | // åå¹¶çæ°æ®å¤ç,cs rs 代表åå¹¶çæ°é |
| | | a.template.forEach((b) => { |
| | | let size1 = set2.size; |
| | | let size2 = set2.add(b.mc).size; |
| | | if (b.mc != undefined && size1 < size2) { |
| | | b.v.mc.rs = 0; |
| | | b.v.mc.cs = 0; |
| | | a.template.forEach((c) => { |
| | | if (b.mc === c.mc) { |
| | | if (b.r === c.r) { |
| | | b.v.mc.cs += 1; |
| | | } |
| | | if (b.c === c.c) { |
| | | b.v.mc.rs += 1; |
| | | } |
| | | } |
| | | }); |
| | | } |
| | | }); |
| | | }); |
| | | // æ¬æ¬¡å¾ªç¯ä¸»è¦æ¯å¯¹åç«¯ä¼ åè¿è¡åå§å,æ ·å¼é»è¾ä¿®æ¹ |
| | | this.tableList.forEach((a) => { |
| | | let arrs = []; |
| | | let set = new Set(); |
| | | let count1 = 0; |
| | | let conclusionList = []; //ç»è®ºå表 |
| | | let finalList = []; //æç»å¼å表 |
| | | // ç»è®ºä¸æç»å¼å¨è¿éä¸ä¸å¯¹åº,以ä¸ä¸¤ä¸ªå表é¿åº¦è¯å®æ¯ä¸æ ·ç,妿æä¸ä¸æ ·,é£ä¹å¤åæ¯æ¨¡æ¿é
ç½®å¾é®é¢ |
| | | conclusionList = a.template.filter( |
| | | (n) => n.v.ps != undefined && n.v.ps.value === "ç»è®º" |
| | | ); //ç»è®ºå表 |
| | | finalList = a.template.filter( |
| | | (n) => n.v.ps != undefined && n.v.ps.value === "æç»å¼" |
| | | ); //æç»å¼å表 |
| | | a.template.forEach((b) => { |
| | | if ( |
| | | b.v.ps != undefined && |
| | | b.v.ps.value === "åºå·" && |
| | | (b.v.mc == undefined || Object.keys(b.v.mc).length === 4) |
| | | ) { |
| | | // 对åºå·è¿è¡èµå¼ |
| | | count1++; |
| | | b.v.v = count1; |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === "è¦æ±å¼") { |
| | | // å¯¹è¦æ±å¼è¿è¡èµå¼ |
| | | b.v.v = this.getAsk(b.i); |
| | | } |
| | | // 对页é¢çåç»åç«¯ä¼ åçæ£éªå¼,计ç®å¼,设å¤ç¼ç ,设å¤åç§°,æç»å¼,ç»è®ºè¿è¡åå§å |
| | | if ( |
| | | b.v.ps != undefined && |
| | | typeof b.v.ps.value === "string" && |
| | | b.v.ps.value.includes("æ£éªå¼") |
| | | ) { |
| | | this.$set(b.v, "v", ""); |
| | | // b.v.v = '' |
| | | b.u = ""; |
| | | b.i && this.param[b.i] && this.param[b.i].insValue.push(b); |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === "计ç®å¼") { |
| | | this.$set(b.v, "v", ""); |
| | | // b.v.v = '' |
| | | b.i && this.param[b.i] && this.param[b.i].comValue.push(b); |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === "设å¤ç¼ç ") { |
| | | // b.v.v = '' |
| | | this.$set(b.v, "v", ""); |
| | | b.i && this.param[b.i] && this.param[b.i].equipValue.push(b); |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === "设å¤åç§°") { |
| | | this.$set(b.v, "v", ""); |
| | | // b.v.v = '' |
| | | b.i && this.param[b.i] && this.param[b.i].equipName.push(b); |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === "æç»å¼") { |
| | | // b.v.v = '' |
| | | this.$set(b.v, "v", ""); |
| | | if ( |
| | | b.i !== undefined && |
| | | this.param[b.i] && |
| | | !this.param[b.i].resValue |
| | | ) { |
| | | this.param[b.i].resValue = b; |
| | | } |
| | | } |
| | | if (b.v.ps != undefined && b.v.ps.value === "ç»è®º") { |
| | | if ( |
| | | b.i !== undefined && |
| | | this.param[b.i] && |
| | | !this.param[b.i].insResult |
| | | ) { |
| | | this.param[b.i].insResult = b; |
| | | conclusionList.forEach((n, i) => { |
| | | if (n.r == b.r && n.c == b.c) { |
| | | b.v.f = `(${this.comparisonList.find((j) => j.value == finalList[i].c) |
| | | .label |
| | | }${finalList[i].r + 1})`; |
| | | } |
| | | }); |
| | | } |
| | | } |
| | | set.add(b.r); |
| | | // å¦ææ¨¡æ¿å表ç彿°åå¨,é£ä¹å å
¥å°excel彿°å表éé¢ |
| | | if (b.v.f) { |
| | | this.excelMethodList.push(b); |
| | | } |
| | | }); |
| | | // 以䏿¯æ ·å¼å¤çé»è¾ |
| | | set = [...set] |
| | | // set = set.sort(); |
| | | set.forEach((b) => { |
| | | let arr = []; |
| | | a.template.forEach((c) => { |
| | | if (c.r === b) { |
| | | arr.push(c); |
| | | } |
| | | }); |
| | | arrs.push(arr); |
| | | }); |
| | | a.arr = arrs; |
| | | this.tableWidth = 0; |
| | | for (let i = 0; i < arrs[0].length; i++) { |
| | | this.tableWidth += |
| | | a.style.columnlen[i] === undefined ? 100 : a.style.columnlen[i]; |
| | | } |
| | | }); |
| | | // æ¬æ¬¡å¾ªç¯ä¸»è¦æ¯å¯¹é¡µé¢ååç«¯ä¼ åè¿è¡åå§åèµå¼ |
| | | this.currentSample.insProduct.forEach(async (a) => { |
| | | try { |
| | | // 计ç®å¼èµå¼ |
| | | let comValue = JSON.parse(a.insProductResult.comValue); |
| | | for (var i = 0; i < comValue.length; i++) { |
| | | if ( |
| | | this.param[a.id].comValue.find( |
| | | (m) => m.c == comValue[i].c && m.r == comValue[i].r |
| | | ) |
| | | ) { |
| | | this.param[a.id].comValue.find( |
| | | (m) => m.c == comValue[i].c && m.r == comValue[i].r |
| | | ).v.v = this.toFixed( |
| | | comValue[i].v, |
| | | this.param[a.id].comValue.find( |
| | | (m) => m.c == comValue[i].c && m.r == comValue[i].r |
| | | ).v.ct |
| | | ); |
| | | } else if (!comValue[i].c || !comValue[i].r) { |
| | | this.param[a.id].comValue[i].v.v = this.toFixed( |
| | | comValue[i].v, |
| | | this.param[a.id].comValue[i].v.ct |
| | | ); |
| | | } |
| | | } |
| | | } catch (e) { } |
| | | try { |
| | | // æ£éªå¼èµå¼ |
| | | let insValue = JSON.parse(a.insProductResult.insValue); |
| | | for (let i = 0; i < insValue.length; i++) { |
| | | if ( |
| | | this.param[a.id].insValue.find( |
| | | (m) => m.c == insValue[i].c && m.r == insValue[i].r |
| | | ) |
| | | ) { |
| | | this.param[a.id].insValue.find( |
| | | (m) => m.c == insValue[i].c && m.r == insValue[i].r |
| | | ).v.v = this.toFixed( |
| | | insValue[i].v, |
| | | this.param[a.id].insValue.find( |
| | | (m) => m.c == insValue[i].c && m.r == insValue[i].r |
| | | ).v.ct |
| | | ); |
| | | this.param[a.id].insValue.find( |
| | | (m) => m.c == insValue[i].c && m.r == insValue[i].r |
| | | ).u = insValue[i].u; |
| | | // this.param[a.id].insValue[i].v.v = insValue[i].v |
| | | // this.param[a.id].insValue[i].u = insValue[i].u |
| | | } |
| | | } |
| | | } catch (e) { } |
| | | try { |
| | | // 设å¤ç¼å·èµå¼ |
| | | let equipValue = JSON.parse(a.insProductResult.equipValue); |
| | | for (let i = 0; i < equipValue.length; i++) { |
| | | // æ®é设å¤èµå¼ |
| | | this.param[a.id].equipValue[i].v.v = equipValue[i].v; |
| | | } |
| | | } catch (e) { } |
| | | try { |
| | | // 设å¤åç§°èµå¼ |
| | | let equipName = JSON.parse(a.insProductResult.equipName); |
| | | for (let i = 0; i < equipName.length; i++) { |
| | | equipName[i].v !== "" && |
| | | equipName[i].v.map((val) => { |
| | | const index = this.equipOptions.findIndex( |
| | | (item) => item.value === val |
| | | ); |
| | | if (index > -1) { |
| | | // æ ¹æ®è®¾å¤ç¼ç 转æ¢ä¸ºç¸åºç设å¤åç§° |
| | | val = this.equipOptions[index].deviceName; |
| | | } |
| | | }); |
| | | } |
| | | for (let i = 0; i < equipName.length; i++) { |
| | | // æ®é设å¤åç§°èµå¼ |
| | | this.param[a.id].equipName[i].v.v = equipName[i].v; |
| | | } |
| | | } catch (e) { |
| | | console.log("设å¤åç§°èµå¼----", e); |
| | | } |
| | | try { |
| | | // æç»å¼èµå¼ |
| | | this.param[a.id].resValue.v.v = this.toFixed( |
| | | a.lastValue, |
| | | this.param[a.id].resValue.v.ct |
| | | ); |
| | | // ç»è®ºèµå¼ |
| | | this.param[a.id].insResult.v.v = a.insResult; |
| | | } catch (e) { } |
| | | }); |
| | | // 对excel彿°è¿è¡å¤ç |
| | | this.handleExcelMethod(); |
| | | }, |
| | | // æ£éªå¼è¾å
¥å触åç彿° |
| | | changeInput(m, code, n, getDataType, changeSelect) { |
| | | // 为æ°éå®ä¹ä¸ä¸ªé»è¾åæ° |
| | | if (getDataType == "getDataType") { |
| | | this.getDataType = 2; |
| | | } |
| | | let currentInsItemId = null; //å½åæ£éªé¡¹id |
| | | if (n) { |
| | | currentInsItemId = JSON.parse(JSON.stringify(n.i)); |
| | | // å®ä¹ä¸ä¸ªå½æ°æ¥éªè¯åæ°æ¯å¦ææ |
| | | if (typeof n.v.v == "string") { |
| | | function isValidFraction(fraction) { |
| | | const [numerator, denominator] = fraction.split("/"); // ååå忝 |
| | | return !(!denominator || !numerator); |
| | | } |
| | | const isTrue = isValidFraction(n.v.v); |
| | | if (!isTrue) { |
| | | n.v.v = n.v.v.replace("/", ""); |
| | | } |
| | | } |
| | | } |
| | | try { |
| | | // å Worker åéæ¶æ¯ï¼å¼å§å¤çé»è¾ |
| | | this.worker.postMessage( |
| | | JSON.stringify({ |
| | | code: code, |
| | | tableList: this.tableList, |
| | | excelMethodList: this.excelMethodList, |
| | | comparisonList: this.comparisonList, |
| | | currentSample: this.currentSample, |
| | | PROJECT: this.PROJECT, |
| | | param: this.param, |
| | | currentTable: this.currentTable, |
| | | getDataTypeId: this.getDataTypeId, |
| | | modelType: this.sampleProduct[0].model, |
| | | currentInsItem: n, |
| | | }) |
| | | ); |
| | | } catch (error) { |
| | | console.log(444, error); |
| | | } |
| | | |
| | | // çå¬ Worker è¿åçç»æ |
| | | this.worker.onmessage = (event) => { |
| | | this.result = JSON.parse(event.data); |
| | | switch (this.result.method) { |
| | | case "saveInsContext": |
| | | this.$nextTick(() => { |
| | | // this.$delete(this.tableList[0],'arr') |
| | | this.$set( |
| | | this.tableList[0], |
| | | "arr", |
| | | this.result.value.tableList[0].arr |
| | | ); |
| | | this.param = this.result.value.param; |
| | | if (this.result.value.currentInsItemId) { |
| | | currentInsItemId = this.result.value.currentInsItemId; |
| | | } |
| | | // ç¹æ®å¤çä¸ä¸ç»è®º,伿è¿ç§ç¹æ®æ
åµ |
| | | for (var i in this.param) { |
| | | if ( |
| | | this.param[i].insResult && |
| | | this.param[i].insResult.v && |
| | | this.param[i].insResult.v.v |
| | | ) { |
| | | if (this.param[i].insResult.v.v == "åæ ¼") { |
| | | this.$set(this.param[i].insResult.v, "v", 1); |
| | | } else if (this.param[i].insResult.v.v == "ä¸åæ ¼") { |
| | | this.$set(this.param[i].insResult.v, "v", 0); |
| | | } |
| | | } |
| | | } |
| | | this.saveInsContext(currentInsItemId); |
| | | }); |
| | | break; |
| | | case "tableList": |
| | | this.$nextTick(() => { |
| | | // æ´æ°æ°æ® |
| | | this.$delete(this.tableList[0], "arr"); |
| | | this.$set(this.tableList[0], "arr", this.result.value[0].arr); |
| | | // this.param = this.result.value.param |
| | | if (this.result.value.currentInsItem) { |
| | | currentInsItemId = this.result.value.currentInsItem.i; |
| | | } |
| | | }); |
| | | break; |
| | | case "getCurrentInsProduct": |
| | | // æ´æ°é¡µé¢æ°æ® |
| | | this.getCurrentInsProduct(this.result.value); |
| | | break; |
| | | } |
| | | }; |
| | | // ä¿åæ°æ® |
| | | setTimeout(() => { |
| | | if (changeSelect) { |
| | | this.saveInsContext(currentInsItemId); |
| | | } |
| | | }, 200); |
| | | }, |
| | | // æ ¹æ®åç«¯ä¼ åæ´æ°é¡µé¢æ°æ® param => this.tableList[0].insProductResult |
| | | getCurrentInsProduct(pId) { |
| | | if (!this.tableList[0].insProductResult) { |
| | | this.tableList[0].insProductResult = {}; |
| | | } |
| | | for (let m in this.param[pId]) { |
| | | let value = this.param[pId][m]; |
| | | switch (m) { |
| | | case "comValue": |
| | | // èµå¼è®¡ç®å¼ |
| | | if (value && value.length > 0) { |
| | | this.tableList[0].insProductResult[m] = []; |
| | | value.forEach((a, i) => { |
| | | let obj = { |
| | | v: a.v.v, |
| | | }; |
| | | this.tableList[0].insProductResult[m].push(obj); |
| | | }); |
| | | try { |
| | | this.tableList[0].insProductResult[m] = JSON.stringify( |
| | | this.tableList[0].insProductResult[m] |
| | | ); |
| | | } catch (error) { |
| | | console.log(555, error); |
| | | } |
| | | } |
| | | break; |
| | | // èµå¼æ£éªå¼ |
| | | case "insValue": |
| | | if (value && value.length > 0) { |
| | | this.tableList[0].insProductResult[m] = []; |
| | | value.forEach((a, i) => { |
| | | let obj = { |
| | | v: a.v.v, |
| | | u: a.u, |
| | | }; |
| | | this.tableList[0].insProductResult[m].push(obj); |
| | | }); |
| | | try { |
| | | this.tableList[0].insProductResult[m] = JSON.stringify( |
| | | this.tableList[0].insProductResult[m] |
| | | ); |
| | | } catch (error) { |
| | | console.log(666, error); |
| | | } |
| | | } |
| | | break; |
| | | // èµå¼è®¾å¤ç¼å· |
| | | case "equipValue": |
| | | if (value && value.length > 0) { |
| | | this.tableList[0].insProductResult[m] = []; |
| | | value.forEach((a, i) => { |
| | | let obj = { |
| | | v: a.v.v, |
| | | }; |
| | | this.tableList[0].insProductResult[m].push(obj); |
| | | }); |
| | | try { |
| | | this.tableList[0].insProductResult[m] = JSON.stringify( |
| | | this.tableList[0].insProductResult[m] |
| | | ); |
| | | } catch (error) { |
| | | console.log(777, error); |
| | | } |
| | | } |
| | | break; |
| | | // èµå¼è®¾å¤åç§° |
| | | case "equipName": |
| | | if (value && value.length > 0) { |
| | | this.tableList[0].insProductResult[m] = []; |
| | | value.forEach((a, i) => { |
| | | let obj = { |
| | | v: a.v.v, |
| | | }; |
| | | this.tableList[0].insProductResult[m].push(obj); |
| | | }); |
| | | try { |
| | | this.tableList[0].insProductResult[m] = JSON.stringify( |
| | | this.tableList[0].insProductResult[m] |
| | | ); |
| | | } catch (error) { |
| | | console.log(888, error); |
| | | } |
| | | } |
| | | break; |
| | | // èµå¼æç»å¼ |
| | | case "resValue": |
| | | this.tableList[0].lastValue = value ? value.v.v : ""; |
| | | break; |
| | | // èµå¼ç»è®º |
| | | case "insResult": |
| | | this.tableList[0].insResult = value ? value.v.v : ""; |
| | | break; |
| | | } |
| | | } |
| | | }, |
| | | // 对EXCEL彿°è¿è¡å¤ç |
| | | handleExcelMethod() { |
| | | if (this.excelMethodList.length > 0) { |
| | | this.excelMethodList.map((item) => { |
| | | // å¾å°æ¯ä¸ªå½æ°çåæ°å表 |
| | | item.valueList = excelFunction.changeParameter(item.v.f); |
| | | return item; |
| | | }); |
| | | } |
| | | }, |
| | | getValue(v) { |
| | | // 对页é¢å±ç¤ºæ°æ®è¿è¡å¤ç,@,代表æ¢è¡ |
| | | let str = v.v |
| | | ? v.v |
| | | : v.v === 0 |
| | | ? v.v |
| | | : v.ct && v.ct.s |
| | | ? v.ct.s.length > 0 && |
| | | v.ct.s[0].v |
| | | .replace(new RegExp("\n", "g"), "<br/>") |
| | | .replace(new RegExp("@", "g"), "<br/>") |
| | | : ""; |
| | | // å¯¹æ°æ®ä¿çå°æ°ç¹è¿è¡å¤ç |
| | | if (v.ct && v.ct.fa && v.ct.fa.includes(".") && str) { |
| | | let num = 0; |
| | | let str0 = v.ct.fa.split(".")[1]; |
| | | num = str0.length; |
| | | str = Number(str).toFixed(num); |
| | | } |
| | | if (v.v && typeof v.v == "string" && v.v.includes("@")) { |
| | | str = v.v.replace(new RegExp("@", "g"), "<br/>"); |
| | | } |
| | | return str; |
| | | }, |
| | | // è·åå½åè¾å
¥æ¡ç±»å |
| | | getInspectionValueType(id) { |
| | | for (var a in this.currentSample.insProduct) { |
| | | if (this.currentSample.insProduct[a].id == id) { |
| | | return this.currentSample.insProduct[a].inspectionValueType; |
| | | } |
| | | } |
| | | }, |
| | | // è·åè¦æ±æè¿° |
| | | getTell(id) { |
| | | for (var a in this.currentSample.insProduct) { |
| | | if (this.currentSample.insProduct[a].id == id) { |
| | | return this.currentSample.insProduct[a].tell; |
| | | } |
| | | } |
| | | }, |
| | | // 卿è·ååå
æ ¼å®½åº¦ |
| | | handleWidth(n) { |
| | | let sum = 0; |
| | | if (n.v.mc && n.v.mc.cs && n.v.mc.c != undefined) { |
| | | for (let i = 0; i < n.v.mc.cs; i++) { |
| | | let num = this.widthList[i + n.v.mc.c] |
| | | ? this.widthList[i + n.v.mc.c] |
| | | : 100; |
| | | sum += num; |
| | | } |
| | | } else { |
| | | sum = this.widthList[n.c] ? this.widthList[n.c] : 100; |
| | | } |
| | | return sum; |
| | | }, |
| | | // 对è¾å
¥å¼è¿è¡æ ¼å¼æ ¡éª |
| | | handleInput(n) { |
| | | try { |
| | | n.v.v = n.v.v.replace(/[^\d.^e>ï¼â¥â¤<ï¼æè£èå\-/+]/g, ""); |
| | | n.v.v = n.v.v.replace(/\.{2,}/g, "."); //åªä¿ç第ä¸ä¸ª. æ¸
é¤å¤ä½ç |
| | | n.v.v = n.v.v |
| | | .replace(".", "$#$") |
| | | .replace(/\./g, "") |
| | | .replace("$#$", "."); |
| | | n.v.v = n.v.v.replace(/\/{2,}/g, "/"); //åªä¿ç第ä¸ä¸ª/æ¸
é¤å¤ä½ç |
| | | n.v.v = n.v.v |
| | | .replace("/", "$#$") |
| | | .replace(/\//g, "") |
| | | .replace("$#$", "/"); |
| | | } catch (error) { |
| | | console.log(error); |
| | | } |
| | | }, |
| | | getInspectionItemType(id) { |
| | | for (var a in this.currentSample.insProduct) { |
| | | if (this.currentSample.insProduct[a].id == id) { |
| | | return this.currentSample.insProduct[a].inspectionItemType; |
| | | } |
| | | } |
| | | }, |
| | | // è·åè¦æ±å¼ |
| | | getAsk(id) { |
| | | for (var a in this.currentSample.insProduct) { |
| | | if (this.currentSample.insProduct[a].id == id) { |
| | | return this.currentSample.insProduct[a].ask; |
| | | } |
| | | } |
| | | }, |
| | | // è·åææè®¾å¤ |
| | | getEquipOptions(e, id) { |
| | | if (e) { |
| | | this.equipOptions = []; |
| | | search({ status: 0 }).then((res) => { |
| | | if (res.code === 200 && res.data) { |
| | | this.equipOptions = res.data.map((m) => { |
| | | m.value = m.managementNumber; |
| | | m.label = m.deviceName; |
| | | return m; |
| | | }); |
| | | } |
| | | }) |
| | | .catch((error) => { |
| | | console.error(error); |
| | | }); |
| | | } |
| | | }, |
| | | // getDic(e, id) { |
| | | // if (e) { |
| | | // for (var a in this.currentSample.insProduct) { |
| | | // if (this.currentSample.insProduct[a].id == id) { |
| | | // let str = this.currentSample.insProduct[a].dic; |
| | | // this.selectEnumByCategoryOfSelect(str); |
| | | // return str; |
| | | // } |
| | | // } |
| | | // } |
| | | // }, |
| | | openAddCheck() { |
| | | this.addCheck = true; |
| | | }, |
| | | // 夿 ¸ |
| | | upInsReview(e) { |
| | | if (e == 1) { |
| | | // éè¿ |
| | | this.reviewLoading = true; |
| | | verifyPlan({ |
| | | orderId: this.orderId, |
| | | type: 1, |
| | | laboratory: this.sonLaboratory, |
| | | tell: null, |
| | | userId: this.checkUser, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | this.$message.success("æä½æå"); |
| | | this.goback(); |
| | | this.addCheck = false; |
| | | } |
| | | this.reviewLoading = false; |
| | | }) |
| | | .catch((error) => { |
| | | console.error(error); |
| | | this.reviewLoading = false; |
| | | }); |
| | | } else { |
| | | // ä¸éè¿ |
| | | this.reviewDia = true; |
| | | } |
| | | }, |
| | | handleReviewDia() { |
| | | if (this.noReason) { |
| | | this.reviewLoading = true; |
| | | verifyPlan({ |
| | | orderId: this.orderId, |
| | | type: 0, |
| | | laboratory: this.sonLaboratory, |
| | | tell: this.noReason, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | this.$message.success("æä½æå"); |
| | | this.goback(); |
| | | } |
| | | this.reviewLoading = false; |
| | | }) |
| | | .catch((error) => { |
| | | console.error(error); |
| | | this.reviewLoading = false; |
| | | }); |
| | | } else { |
| | | this.$message.error("æªè¾å
¥ä¸éè¿åå "); |
| | | } |
| | | }, |
| | | // æ¥çå·¥æ¶ |
| | | viewManHour() { |
| | | this.$refs.viewManHourDia.showDialog(this.id, 99); |
| | | }, |
| | | openAddVerifyDia() { |
| | | this.addVerifyDia = true; |
| | | }, |
| | | submit() { |
| | | if (this.verifyUser === null || this.verifyUser === "") { |
| | | this.$message.error("请æå®å¤æ ¸äººå"); |
| | | return; |
| | | } |
| | | if (!this.otherForm.humidity) { |
| | | this.$message.error("请è¾å
¥æ¹¿åº¦"); |
| | | return; |
| | | } |
| | | if (!this.otherForm.temperature) { |
| | | this.$message.error("请è¾å
¥æ¸©åº¦"); |
| | | return; |
| | | } |
| | | this.submitLoading = true; |
| | | checkSubmitPlan({ |
| | | orderId: this.orderId, |
| | | laboratory: this.sonLaboratory, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | if (!res.data || res.data.length == 0) { |
| | | this.submitLoading = true; |
| | | submitPlan({ |
| | | orderId: this.orderId, |
| | | laboratory: this.sonLaboratory, |
| | | verifyUser: this.verifyUser, |
| | | entrustCode: this.insOrder.entrustCode, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | this.$message.success("æä½æå"); |
| | | this.goback(); |
| | | this.submitLoading = false; |
| | | this.addVerifyDia = false; |
| | | } |
| | | }) |
| | | .catch((error) => { |
| | | console.error(error); |
| | | this.submitLoading = false; |
| | | }); |
| | | } else { |
| | | let newData = []; |
| | | const h = this.$createElement; |
| | | for (let i in res.data) { |
| | | const lastChar = res.data[i].slice(-1); |
| | | if (lastChar == "-") { |
| | | res.data[i] = res.data[i].slice(0, -1); |
| | | } |
| | | newData.push( |
| | | h( |
| | | "p", |
| | | { style: "font-size: 14px;color: red;" }, |
| | | Number(i) + 1 + "ã" + res.data[i] |
| | | ) |
| | | ); |
| | | } |
| | | newData.push( |
| | | h( |
| | | "p", |
| | | { |
| | | style: |
| | | "font-size: 16px;color:#000;margin-top:12px;overflow-y: auto;max-height:80vh", |
| | | }, |
| | | "以ä¸é¡¹ç®ä¸åæ ¼ï¼ç¡®å®æäº¤ï¼" |
| | | ) |
| | | ); |
| | | this.$confirm("æç¤º", { |
| | | title: "æç¤º", |
| | | message: h("div", null, newData), |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "", |
| | | }) |
| | | .then(() => { |
| | | this.submitLoading = true; |
| | | submitPlan({ |
| | | orderId: this.orderId, |
| | | laboratory: this.sonLaboratory, |
| | | verifyUser: this.verifyUser, |
| | | }).then((res) => { |
| | | if (res.code === 200) { |
| | | this.$message.success("æä½æå"); |
| | | this.addVerifyDia = false; |
| | | this.goback(); |
| | | } |
| | | this.submitLoading = false; |
| | | }) |
| | | .catch((error) => { |
| | | console.error(error); |
| | | this.submitLoading = false; |
| | | }); |
| | | }) |
| | | .catch(() => { }); |
| | | } |
| | | } |
| | | }) |
| | | .catch((error) => { |
| | | console.error(error); |
| | | this.submitLoading = false; |
| | | }); |
| | | return; |
| | | }, |
| | | // ç»ä¸å¨è¿éä¿åæ°æ® |
| | | saveInsContext(currentInsItemId) { |
| | | try { |
| | | if (this.param) { |
| | | let param = null; |
| | | if (currentInsItemId) { |
| | | param = { [currentInsItemId]: this.param[currentInsItemId] }; |
| | | } else { |
| | | param = this.param; |
| | | } |
| | | saveInsContext({ |
| | | param: JSON.stringify(param), |
| | | currentTable: this.currentTable, |
| | | sampleId: this.currentSample.id, |
| | | orderId: this.orderId, |
| | | sonLaboratory: this.sonLaboratory |
| | | }).then((res) => { |
| | | this.$message.success("å·²ä¿å"); |
| | | }); |
| | | // å Worker åéæ¶æ¯ï¼å¼å§å¤çé»è¾ |
| | | this.worker.postMessage( |
| | | JSON.stringify({ |
| | | modelType: this.sampleProduct[0].model, |
| | | type: "saveData", |
| | | tableList: this.tableList, |
| | | param: this.param, |
| | | currentTable: this.currentTable, |
| | | }) |
| | | ); |
| | | } |
| | | } catch (error) { |
| | | console.log(999, error); |
| | | } |
| | | }, |
| | | // è®¾å¤æ¹å |
| | | changeEquip(val, n, v) { |
| | | try { |
| | | // this.$set(n.v,'v',val) |
| | | this.tableList[0].arr.forEach((item, index) => { |
| | | item.forEach((m, i) => { |
| | | if (this.param[m.i]) { |
| | | this.param[m.i].state = 1; |
| | | } |
| | | // if(m.i==n.i&&m.v.ps&&m.v.ps.value=='设å¤åç§°'&&v){ |
| | | // this.$set(m.v,'v',v) |
| | | // } |
| | | }); |
| | | }); |
| | | for (let i in this.param) { |
| | | if (this.param[i].state != 1) { |
| | | delete this.param[i]; |
| | | } |
| | | } |
| | | // this.equipOptions为设å¤åç§°ä¸ææ¡éé¡¹æ°æ® |
| | | for (let i1 in this.param[n.i].equipName) { |
| | | if ( |
| | | this.param[n.i].equipName[i1].i === n.i && |
| | | this.param[n.i].equipName[i1].r === n.r |
| | | ) { |
| | | this.$delete(this.param[n.i].equipValue[i1].v, "v"); |
| | | // å°æ°ç»èµå¼ç»è®¾å¤ç¼ç |
| | | this.$set(this.param[n.i].equipValue[i1].v, "v", val.join("ï¼")); |
| | | this.$delete(this.param[n.i].equipName[i1].v, "v"); |
| | | // å°æ°ç»èµå¼ç»è®¾å¤ç¼ç |
| | | this.$set(this.param[n.i].equipName[i1].v, "v", val); |
| | | this.tableList[0].arr.forEach((item, index) => { |
| | | item.forEach((m) => { |
| | | if (m.i == n.i && m.v.ps && m.v.ps.value == "设å¤ç¼ç ") { |
| | | this.$set(m.v, "v", val.join("ï¼")); |
| | | } |
| | | if (m.i == n.i && m.v.ps && m.v.ps.value == "设å¤åç§°") { |
| | | this.$set(m.v, "v", val); |
| | | } |
| | | }); |
| | | }); |
| | | } |
| | | } |
| | | // ä¿åæ°æ® |
| | | this.saveInsContext(n.i); |
| | | } catch (e) { |
| | | console.log("changeEquip----", e); |
| | | } |
| | | }, |
| | | getAuthorizedPerson() { |
| | | selectUserCondition({ type: 1 }).then((res) => { |
| | | let data = []; |
| | | res.data.forEach((a) => { |
| | | data.push({ |
| | | label: a.name, |
| | | value: a.id, |
| | | }); |
| | | }); |
| | | this.personList = data; |
| | | }); |
| | | }, |
| | | scrollInit() { |
| | | // è·åè¦ç»å®äºä»¶çå
ç´ |
| | | const nav = document.getElementById("nav"); |
| | | var flag; // é¼ æ æä¸ |
| | | var downX; // é¼ æ ç¹å»çx䏿 |
| | | var scrollLeft; // å½åå
ç´ æ»å¨æ¡çåç§»é |
| | | nav.addEventListener("mousedown", function (event) { |
| | | flag = true; |
| | | downX = event.clientX; // è·åå°ç¹å»çx䏿 |
| | | scrollLeft = this.scrollLeft; // è·åå½åå
ç´ æ»å¨æ¡çåç§»é |
| | | }); |
| | | nav.addEventListener("mousemove", function (event) { |
| | | if (flag) { |
| | | // 夿æ¯å¦æ¯é¼ æ æä¸æ»å¨å
ç´ åºå |
| | | var moveX = event.clientX; // è·åç§»å¨çxè½´ |
| | | var scrollX = moveX - downX; // å½åç§»å¨çxè½´ä¸æ åå»åç¹å»ä¸å»çxè½´ä¸æ å¾å°é¼ æ æ»å¨è·ç¦» |
| | | this.scrollLeft = scrollLeft - scrollX; // é¼ æ æä¸çæ»å¨æ¡åç§»éåå»å½åé¼ æ çæ»å¨è·ç¦» |
| | | } |
| | | }); |
| | | // é¼ æ æ¬èµ·åæ¢æå¨ |
| | | nav.addEventListener("mouseup", function () { |
| | | flag = false; |
| | | }); |
| | | // é¼ æ 离å¼å
ç´ åæ¢æå¨ |
| | | nav.addEventListener("mouseleave", function (event) { |
| | | flag = false; |
| | | }); |
| | | }, |
| | | // 页é¢éé¢åæ¢æ ·å |
| | | async caretSample(num) { |
| | | let index = this.currentKey + num; |
| | | if (index < 1) { |
| | | this.$message.error("å½åæ¯ç¬¬ä¸ä¸ªæ ·å"); |
| | | return; |
| | | } else if (index > this.sampleProduct.length) { |
| | | this.$message.error("å½åæ¯æåä¸ä¸ªæ ·å"); |
| | | return; |
| | | } |
| | | this.currentKey = index; |
| | | this.currentSample = this.HaveJson(this.sampleProduct[index - 1]); |
| | | // è·åæ£éªé¡¹ |
| | | let list = await this.getCurrentProduct(this.currentSample.id, 0); |
| | | this.currentSample.insProduct = this.HaveJson(list); |
| | | // åå§ååç«¯ä¼ å |
| | | this.param = {}; |
| | | this.changeType = 0; |
| | | this.currentSample.insProduct.forEach((a, j) => { |
| | | this.param[a.id] = { |
| | | insValue: [], |
| | | comValue: [], |
| | | resValue: null, |
| | | equipValue: [], |
| | | equipName: [], |
| | | insResult: null, |
| | | }; |
| | | }); |
| | | // 页颿°æ®å¤ç |
| | | this.getTableLists(); |
| | | // æ´æ°å°å¤çº¿ç¨ |
| | | this.worker.postMessage( |
| | | JSON.stringify({ |
| | | modelType: this.sampleProduct[0].model, |
| | | type: "saveData", |
| | | tableList: this.tableList, |
| | | param: this.param, |
| | | currentTable: this.currentTable, |
| | | }) |
| | | ); |
| | | }, |
| | | handleSuccessUp(response) { |
| | | this.upLoading = false; |
| | | if (response.code == 200) { |
| | | this.$message.success("ä¸ä¼ æå"); |
| | | this.getList(); |
| | | } |
| | | }, |
| | | beforeUpload(file) { |
| | | if (file.size > 1024 * 1024 * 10) { |
| | | this.$message.error("ä¸ä¼ æä»¶ä¸è¶
è¿10M"); |
| | | this.$refs.upload.clearFiles(); |
| | | return false; |
| | | } else { |
| | | this.upLoading = true; |
| | | return true; |
| | | } |
| | | }, |
| | | onError(err, file, fileList) { |
| | | this.$message.error("ä¸ä¼ 失败"); |
| | | this.$refs.upload.clearFiles(); |
| | | }, |
| | | handleDown(row) { |
| | | downFile({ id: row.id }).then((res) => { |
| | | this.$download.saveAs(res.data.fileUrl, row.fileName) |
| | | }) |
| | | .catch((error) => { }); |
| | | }, |
| | | /** |
| | | * å°æ°å¼vä¿çct.faä¸'##'åçæå®å°æ°ä½æ°ï¼å¹¶è¿åæ ¼å¼ååçå符串ã |
| | | * |
| | | * @param v è¦æ ¼å¼åçæ°å¼ |
| | | * @param ct å
嫿 ¼å¼åé
ç½®ç对象 |
| | | * @param ct.fa æ ¼å¼åé
ç½®å符串ï¼è¥å
å«'##'åæç
§å
¶åçå
容确å®å°æ°ä½æ° |
| | | * @returns æ ¼å¼ååçå符串æåå§æ°å¼ï¼è¥é
ç½®ä¸ç¬¦åè¦æ±ï¼ |
| | | */ |
| | | toFixed(v, ct) { |
| | | if (v && ct && ct.fa) { |
| | | if (ct.fa.includes(".")) { |
| | | let num = ct.fa.slice(4).length; |
| | | return Number(v).toFixed(num); |
| | | } else { |
| | | return v; |
| | | } |
| | | } else { |
| | | return v; |
| | | } |
| | | }, |
| | | goback() { |
| | | this.$router.go(-1) |
| | | } |
| | | }, |
| | | }; |
| | | </script> |
| | | <style scoped> |
| | | .custom-table .el-table__header-wrapper th { |
| | | background-color: #87ceeb; |
| | | /* åªå¯¹å¸¦æmy-custom-tableç±»çè¡¨æ ¼çæ */ |
| | | color: #fff; |
| | | } |
| | | |
| | | .container { |
| | | overflow: auto; |
| | | /* ç¡®ä¿å®¹å¨è½å
裹浮å¨å
ç´ */ |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | .right-button { |
| | | float: right; |
| | | } |
| | | |
| | | .inspection { |
| | | height: 100%; |
| | | overflow-y: auto; |
| | | } |
| | | |
| | | .inspection::-webkit-scrollbar { |
| | | width: 0; |
| | | } |
| | | |
| | | .title { |
| | | height: 60px; |
| | | line-height: 60px; |
| | | padding: 0 16px; |
| | | } |
| | | |
| | | .search { |
| | | width: 100%; |
| | | background-color: #fff; |
| | | border-radius: 3px; |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | .search .form-inline { |
| | | padding-top: 20px; |
| | | padding-left: 0px; |
| | | text-align: left; |
| | | } |
| | | |
| | | .center { |
| | | width: 100%; |
| | | /* max-height: 580px; */ |
| | | background-color: #fff; |
| | | border-radius: 3px; |
| | | padding: 20px; |
| | | overflow: auto; |
| | | } |
| | | |
| | | .center-box { |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | flex-direction: column; |
| | | flex-wrap: wrap; |
| | | width: 100%; |
| | | overflow-x: auto; |
| | | /* overflow-x: scroll; */ |
| | | cursor: grab; |
| | | } |
| | | |
| | | .center-box:active { |
| | | cursor: grabbing; |
| | | } |
| | | |
| | | .tables { |
| | | table-layout: fixed; |
| | | margin: 5px 5px 16px; |
| | | border-collapse: collapse; |
| | | } |
| | | |
| | | .tables td { |
| | | height: 40px; |
| | | width: 100px; |
| | | text-align: center; |
| | | font-size: 14px; |
| | | word-wrap: break-word; |
| | | white-space: normal; |
| | | } |
| | | |
| | | .thermal-table { |
| | | min-width: calc(100% - 10px); |
| | | margin: 5px 5px 0; |
| | | table-layout: fixed; |
| | | } |
| | | |
| | | .thermal-table td { |
| | | min-width: 70px; |
| | | text-align: center; |
| | | font-size: 14px; |
| | | word-wrap: break-word; |
| | | white-space: normal; |
| | | padding: 5px; |
| | | } |
| | | |
| | | .table-container { |
| | | overflow-x: auto; |
| | | /* ä½¿å®¹å¨æ¯ææ¨ªåæ»å¨ */ |
| | | max-width: 100%; |
| | | /* éå¶å®¹å¨çæå¤§å®½åº¦ */ |
| | | margin-bottom: 16px; |
| | | } |
| | | |
| | | .content { |
| | | display: flex; |
| | | height: 100%; |
| | | align-items: center; |
| | | justify-content: left; |
| | | padding: 5px; |
| | | box-sizing: border-box; |
| | | overflow: hidden; |
| | | user-select: none; |
| | | } |
| | | |
| | | .content * { |
| | | user-select: none; |
| | | } |
| | | |
| | | .content-h-0 { |
| | | justify-content: center; |
| | | } |
| | | |
| | | .content-h-1 { |
| | | justify-content: start; |
| | | } |
| | | |
| | | .content-h-2 { |
| | | justify-content: flex-end; |
| | | } |
| | | |
| | | .content-v-0 { |
| | | align-items: center; |
| | | } |
| | | |
| | | .content-v-1 { |
| | | align-items: start; |
| | | } |
| | | |
| | | .content-v-2 { |
| | | align-items: end; |
| | | } |
| | | |
| | | .table_input { |
| | | width: 100%; |
| | | height: 100%; |
| | | } |
| | | |
| | | .table_input>>>.el-input__inner { |
| | | border-color: rgba(0, 0, 0, 0.5) !important; |
| | | } |
| | | |
| | | .collection { |
| | | width: 50px; |
| | | height: 100%; |
| | | margin-left: 5px; |
| | | border-color: transparent; |
| | | background-color: #409eff; |
| | | color: #fff; |
| | | border-radius: 4px; |
| | | font-size: 12px; |
| | | } |
| | | |
| | | .collection:active { |
| | | opacity: 0.7; |
| | | } |
| | | |
| | | .table_caret { |
| | | font-size: 16px; |
| | | margin: 0 5px; |
| | | color: rgba(0, 0, 0, 0.5); |
| | | } |
| | | |
| | | .table_caret:hover { |
| | | color: #409eff; |
| | | cursor: pointer; |
| | | } |
| | | |
| | | .table_caret:active { |
| | | opacity: 0.8; |
| | | } |
| | | |
| | | >>>input::-webkit-inner-spin-button { |
| | | -webkit-appearance: none !important; |
| | | /* éèå¾®è°æé® */ |
| | | margin: 0 !important; |
| | | /* ç§»é¤å¾®è°æé®çè¾¹è· */ |
| | | } |
| | | |
| | | >>>input[type="number"] { |
| | | -moz-appearance: textfield !important; |
| | | /* é对 Firefox */ |
| | | } |
| | | |
| | | >>>.el-form-item__content { |
| | | display: inline-flex; |
| | | align-items: center; |
| | | } |
| | | </style> |
| | | <style scoped> |
| | | /* .inspection .el-form-item__label { |
| | | color: #000; |
| | | } */ |
| | | |
| | | .inspection .el-drawer__header::before { |
| | | content: ""; |
| | | display: inline-block; |
| | | width: 4px; |
| | | height: 30.24px; |
| | | background: #3a7bfa; |
| | | border-radius: 10px; |
| | | margin-left: 32px; |
| | | margin-right: 8.5px; |
| | | } |
| | | |
| | | .inspection .el-drawer__header { |
| | | color: #303133; |
| | | text-align: left; |
| | | } |
| | | |
| | | .inspection .el-input-group__append { |
| | | padding: 0 14px; |
| | | color: #3a7bfa; |
| | | background-color: #fff; |
| | | height: 100%; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .inspection .center-box .el-input__inner { |
| | | font-size: 12px; |
| | | padding: 0 6px; |
| | | text-align: center; |
| | | } |
| | | |
| | | .inspection .el-textarea__inner { |
| | | padding: 2px; |
| | | } |
| | | |
| | | .inspection .el-textarea__inner::-webkit-scrollbar { |
| | | width: 0; |
| | | } |
| | | |
| | | .inspection .el-select { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .inspection .el-textarea__inner { |
| | | min-height: 100% !important; |
| | | } |
| | | |
| | | .inspection .tables .el-input { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .thermal-table .el-input { |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .custom-dialog .el-dialog__body { |
| | | max-width: 1000px; |
| | | /* 设置æå¤§å®½åº¦ */ |
| | | } |
| | | </style> |
| | |
| | | </el-form> |
| | | </div> |
| | | <div style="margin-bottom: 6px;margin-top: 6px"> |
| | | <el-button v-show="active==1" :disabled="sampleList.length === 2" size="small" type="primary" @click="handleSplitCountNum">æå</el-button> |
| | | <el-button v-show="active==1" :disabled="sampleList.length === 3" size="small" type="primary" @click="handleSplitCountNum">æå</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="height: auto;"> |
| | |
| | | size="small" style="width: 80%;"></el-input-number> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="å¾
æ£é¡¹æ°é" prop="proNum" width="105"></el-table-column> |
| | | <el-table-column align="center" label="å¾
æ£é¡¹æ°é" prop="quantity" width="105"></el-table-column> |
| | | </el-table> |
| | | <el-table ref="productTable" v-loading="getProductLoad" :data="productList" :row-class-name="tableRowClassName" class="el-table" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | |
| | | custom: null, |
| | | company: null, |
| | | userId: null, |
| | | companyId: '', |
| | | type: '0', // ç´§æ¥ç¨åº¦ |
| | | code: null, |
| | | remark: null, // 夿³¨ |
| | | mating: 0, |
| | | sample: null, // æ ·ååç§° |
| | | appointed: '', // çº¦å®æ¶é´ |
| | | buyUnitMeas: '', // åä½ |
| | | updateBatchNo: '', // æ¹æ¬¡å· |
| | | partDetail: '', // è§æ ¼åå· |
| | | buyUnitMeas: null, // åä½ |
| | | updateBatchNo: null, // æ¹æ¬¡å· |
| | | partDetail: null, // è§æ ¼åå· |
| | | declareDate: '', // å°è´§æ¶é´ |
| | | factory: null, |
| | | laboratory: null, |
| | |
| | | processing: 1, |
| | | isLeave: 0, |
| | | orderType: 'è¿åæ£éª', // æ£éªç±»å |
| | | supplierName: '', // ææåå®¶ |
| | | qtyArrived: '', // å°è´§æ°é |
| | | supplierName: null, // ææåå®¶ |
| | | qtyArrived: null, // å°è´§æ°é |
| | | }, |
| | | sample: { |
| | | sampleCode: null, |
| | |
| | | { required: true, message: '请填åè§æ ¼åå·', trigger: 'blur' } |
| | | ], |
| | | declareDate: [ |
| | | { required: true, message: '请填åå°è´§æ¶é´', trigger: 'blur' } |
| | | { required: true, message: '请填åå°è´§æ¶é´', trigger: 'change' } |
| | | ] |
| | | }, |
| | | noNeedCheckDia: false, |
| | |
| | | } |
| | | }) |
| | | this.filters = arr |
| | | } |
| | | } |
| | | }, |
| | | productListSelected: { |
| | | deep: true, |
| | | handler(val) { |
| | | if(val.length>0){ |
| | | for(let i =0 ; i< val.length; i++){ |
| | | if(val[i].inspectionItem.includes('æ¾å¥ç®¡')){ |
| | | this.inspectionItemST = 1 |
| | | break; |
| | | }else{ |
| | | this.inspectionItemST = 0 |
| | | } |
| | | } |
| | | }else{ |
| | | this.inspectionItemST = 0 |
| | | } |
| | | } |
| | | }, |
| | |
| | | this.addObj = { |
| | | ...res.data.insOrder |
| | | } |
| | | this.addObj.qtyArrived = res.data.insOrderTemplate.qtyArrived |
| | | this.addObj.buyUnitMeas = res.data.insOrderTemplate.buyUnitMeas |
| | | this.addObj.updateBatchNo = res.data.insOrderTemplate.updateBatchNo |
| | | this.addObj.supplierName = res.data.insOrderTemplate.supplierName |
| | | this.$set(this.addObj, 'qtyArrived', res.data.insOrderTemplate.qtyArrived) |
| | | this.$set(this.addObj, 'buyUnitMeas', res.data.insOrderTemplate.buyUnitMeas) |
| | | this.$set(this.addObj, 'updateBatchNo', res.data.insOrderTemplate.updateBatchNo) |
| | | this.$set(this.addObj, 'supplierName', res.data.insOrderTemplate.supplierName) |
| | | this.$set(this.addObj, 'declareDate', res.data.insOrderTemplate.declareDate) |
| | | this.addObj.type = String(this.addObj.type) |
| | | this.sampleList = this.HaveJson(res.data.sampleProduct); |
| | | this.getProNum() |
| | |
| | | this.addObj.code = selects.code |
| | | this.addObj.phone = selects.phone |
| | | this.addObj.companyId = selects.departId |
| | | if(this.active==1){ |
| | | this.selectInsOrderTemplateInfo() |
| | | } |
| | | // if(this.active==1){ |
| | | // this.selectInsOrderTemplateInfo() |
| | | // } |
| | | }) |
| | | }, |
| | | getProNum() { |
| | | this.sampleSelectionList.forEach((m, i) => { |
| | | Vue.set(this.sampleSelectionList[i], 'proNum', 1) |
| | | }) |
| | | this.$refs.sampleTable.doLayout() |
| | | }, |
| | | searchFilter() { |
| | |
| | | } |
| | | return 'warning-row'; |
| | | }, |
| | | selectInsOrderTemplateInfo() { |
| | | selectInsOrderTemplate({company: this.addObj.company}).then(res => { |
| | | this.templates = res.data |
| | | }) |
| | | }, |
| | | // selectInsOrderTemplateInfo() { |
| | | // selectInsOrderTemplate({company: this.addObj.company}).then(res => { |
| | | // this.templates = res.data |
| | | // }) |
| | | // }, |
| | | methodChange(val, row) { |
| | | if (val === null || val === '') return |
| | | if (this.sampleList.length > 1) { |
| | |
| | | }) |
| | | // this.searchTemList() |
| | | }, |
| | | // searchTemList () { |
| | | // this.temperatureList = [] |
| | | // this.$axios.post(this.$api.enums.selectEnumByCategory, { |
| | | // category: "çµåæ¸©åº¦å¾ªç¯æ£éª" |
| | | // }).then(res => { |
| | | // if (res.data.length > 0) { |
| | | // this.temperatureEngList = res.data |
| | | // res.data.forEach(item => { |
| | | // this.temperatureList.push(item.label) |
| | | // }) |
| | | // } |
| | | // }) |
| | | // }, |
| | | changeModel() { |
| | | this.sampleList.forEach(a => { |
| | | let obj = this.sampleIds.find(b => b == a.id) |
| | |
| | | >>>.warning-row { |
| | | color: #1890FF; |
| | | } |
| | | .node_i { |
| | | color: orange; |
| | | font-size: 18px; |
| | | } |
| | | </style> |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <!--éåä¸ä¸å--> |
| | | <template> |
| | | <div class="app-container"> |
| | | <div class="header"> |
| | | <div> |
| | | <span>éåä¸ä¸å</span> |
| | | </div> |
| | | <div> |
| | | <el-button v-show="active==1 && addObj.orderType === 'è¿åæ£éª'" :loading="noNeedCheckLoad" size="small" type="primary" @click="noNeedCheck">å
æ£</el-button> |
| | | <el-button v-show="active==1" :loading="saveLoad" size="small" type="primary" @click="save">æäº¤</el-button> |
| | | <el-button size="small" @click="goBack"> |
| | | <span style="color: #3A7BFA;">è¿å</span> |
| | | </el-button> |
| | | </div> |
| | | </div> |
| | | <div class="container"> |
| | | <div class="search"> |
| | | <el-form ref="addObj" :inline="true" :model="addObj" :rules="addObjRules" label-width="90px"> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ ·ååç§°:" prop="sample"> |
| | | <el-input v-model="addObj.sample" readonly size="small" style="width: 208px"> |
| | | <template slot="append"><el-button slot="append" :disabled="active>1" icon="el-icon-search" |
| | | @click="selectStandardTree = true"></el-button></template> |
| | | </el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="å°è´§æ°é:" prop="qtyArrived" required> |
| | | <el-input v-model="addObj.qtyArrived" :disabled="active > 1" class="addObj-info" |
| | | clearable placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="åä½:" prop="buyUnitMeas"> |
| | | <el-input v-model="addObj.buyUnitMeas" :disabled="active > 1" clearable class="addObj-info" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¹æ¬¡å·:" prop="updateBatchNo"> |
| | | <el-input v-model="addObj.updateBatchNo" :disabled="active > 1" class="addObj-info" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ£éªç±»å:"> |
| | | <el-select v-model="addObj.orderType" clearable disabled size="small" style="width: 100%"> |
| | | <el-option v-for="(a, ai) in dict.type.check_type" :key="ai" :label="a.label" :value="a.value"></el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="çº¦å®æ¶é´:" prop="appointed"> |
| | | <el-date-picker |
| | | v-model="addObj.appointed" |
| | | :disabled="active > 1" |
| | | format="yyyy-MM-dd" |
| | | placeholder="éæ©æ¥æ" |
| | | size="small" |
| | | style="width: 100%" |
| | | type="date" |
| | | value-format="yyyy-MM-dd"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="ææåå®¶:" prop="supplierName"> |
| | | <el-input v-model="addObj.supplierName" :disabled="active > 1" class="addObj-info" clearable placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ½æ£æ°é:" prop="testQuantity"> |
| | | <el-input v-model="addObj.testQuantity" :disabled="active > 1" class="addObj-info" clearable placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="è§æ ¼åå·:" placeholder="请填å" prop="partDetail"> |
| | | <el-tooltip :content="addObj.partDetail" :disabled="!addObj.partDetail"> |
| | | <el-input v-model="addObj.partDetail" :disabled="active > 1" clearable class="addObj-info" size="small"></el-input> |
| | | </el-tooltip> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="å°è´§æ¶é´:" prop="declareDate"> |
| | | <el-date-picker |
| | | v-model="addObj.declareDate" |
| | | :disabled="active > 1" |
| | | format="yyyy-MM-dd" |
| | | placeholder="éæ©æ¥æ" |
| | | size="small" |
| | | style="width: 100%" |
| | | type="date" |
| | | value-format="yyyy-MM-dd HH:mm:ss"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="夿³¨:"> |
| | | <el-input v-model="addObj.remark" :autosize="{ minRows: 2, maxRows: 2}" :placeholder="active>1 ? '' : '请è¾å
¥'" :disabled="active>1" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-form> |
| | | </div> |
| | | <div style="display: flex;justify-content: space-between;background-color: #F5F7FB;margin-bottom: 6px"> |
| | | <div v-if="active==1"> |
| | | <el-form :inline="true" :model="addObj1" label-width="90px"> |
| | | <el-form-item label="æ ·ååå·:" style="margin-bottom: 6px;margin-top: 6px"> |
| | | <el-select v-model="model" :placeholder="active>1 ? '' : '请è¾å
¥'" |
| | | allow-create clearable default-first-option filterable |
| | | size="small" |
| | | @change="changeModel"> |
| | | <el-option v-for="item in models" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="æ£éªæ å:" style="margin-bottom: 6px;margin-top: 6px"> |
| | | <el-select v-model="standardMethodListId" :loading="methodLoad" |
| | | :placeholder="active>1 ? '' : '请è¾å
¥'" clearable size="small" |
| | | @change="changeStandardMethodListId" @focus="methodFocus"> |
| | | <el-option v-for="item in methods" :key="item.id" :label="item.code" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div style="margin-bottom: 6px;margin-top: 6px"> |
| | | <el-button v-show="active==1" :disabled="sampleList.length === 3" size="small" type="primary" @click="handleSplitCountNum">æå</el-button> |
| | | </div> |
| | | </div> |
| | | <div style="height: auto;"> |
| | | <el-table ref="sampleTable" :data="sampleList" class="el-table sampleTable" highlight-current-row |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | max-height="400px" tooltip-effect="dark" @selection-change="selectSample" @row-click="rowClick"> |
| | | <el-table-column v-if="active==1" :selectable="selectable" type="selection" width="60"></el-table-column> |
| | | <el-table-column align="center" label="åºå·" type="index" width="65"></el-table-column> |
| | | <el-table-column align="center" label="æ ·ååç§°" min-width="100" prop="sample"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.sample" :readonly="active>1" clearable size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æ ·åç¼å·" min-width="140" prop="sampleCode"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.sampleCode" :readonly="active>1" clearable placeholder="ä¸å¡«ååç³»ç»èªå¨çæ" |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æ ·ååå·" min-width="100" prop="model"> |
| | | <template slot-scope="scope"> |
| | | <el-select v-model="scope.row.model" :disabled="active>1" allow-create default-first-option filterable |
| | | placeholder="æ ·ååå·" size="small" style="width: 100%;" @change="handleChangeModel"> |
| | | <el-option v-for="item in models" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="!(active>1)" align="center" label="åå·åæ°" prop="modelNum" width="130"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.modelNum" :disabled="active>1|| scope.$index !== 0" clearable placeholder="éå¿
å¡«" |
| | | size="small" |
| | | @input="methodChange(scope.row.standardMethodListId, scope.row)"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æ£éªæ å" min-width="100" prop="standardMethodListId"> |
| | | <template slot-scope="scope"> |
| | | <el-select v-model="scope.row.standardMethodListId" :disabled="scope.row.model==null||active>1 || scope.$index !== 0" |
| | | :loading="methodLoad" :readonly="active>1" clearable placeholder="æ£éªæ å" |
| | | size="small" style="width: 100%;" @change="(value)=>methodChange(value, scope.row)" @clear="productList = []" @focus="methodFocus"> |
| | | <el-option v-for="item in methods" :key="item.id" :label="item.code" :value="item.id"> |
| | | </el-option> |
| | | </el-select> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="addObj.mating==1" align="center" label="é
奿 ·ååç§°" prop="joinName" width="140"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.joinName" :autosize="{ minRows: 1, maxRows: 1}" size="small" |
| | | type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="addObj.mating==1" align="center" label="é
奿 ·ååå·" prop="joinModel" width="140"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.joinModel" :autosize="{ minRows: 1, maxRows: 1}" size="small" |
| | | type="textarea"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="addObj.mating==1" align="center" label="é
奿 ·åæ°é" prop="joinNum" width="140"> |
| | | <template slot-scope="scope"> |
| | | <el-input-number v-model="scope.row.joinNum" :controls="false" :max="100" :min="1" :precision="0" |
| | | size="small" style="width: 80%;"></el-input-number> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="å¾
æ£é¡¹æ°é" prop="quantity" width="105"></el-table-column> |
| | | </el-table> |
| | | <el-table ref="productTable" v-loading="getProductLoad" :data="productList" :row-class-name="tableRowClassName" class="el-table" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | max-height="400px" style="margin-bottom: 10px;" tooltip-effect="dark" |
| | | @select="selectOne" @selection-change="selectProduct" @select-all="handleAll"> |
| | | <el-table-column v-if="active==1" :selectable="selectable" type="selection" width="65"></el-table-column> |
| | | <el-table-column label="æ£éªé¡¹åç±»" min-width="140" prop="inspectionItemClass" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="æ£éªé¡¹" min-width="140" prop="inspectionItem" show-overflow-tooltip> |
| | | <template slot="header" slot-scope="scope"> |
| | | <div style="display: flex;align-items: center;flex-direction: column;font-size: 14px"> |
| | | <span>æ£éªé¡¹</span> |
| | | <el-input |
| | | v-if="active==1" |
| | | v-model="inspectionItem" |
| | | placeholder="请è¾å
¥" |
| | | size="mini" |
| | | @input="searchFilterList"/> |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ£éªé¡¹å项" min-width="140" prop="inspectionItemSubclass" |
| | | show-overflow-tooltip> |
| | | <template slot="header" slot-scope="scope"> |
| | | <div style="display: flex;align-items: center;flex-direction: column;font-size: 14px"> |
| | | <span>æ£éªé¡¹å项</span> |
| | | <el-input |
| | | v-if="active==1" |
| | | v-model="inspectionItemSubclass" |
| | | placeholder="请è¾å
¥" |
| | | size="mini" |
| | | @input="searchFilterList"/> |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="è¦æ±å¼" min-width="220px" prop="ask"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-if="active==1&&isAskOnlyRead&&scope.row.inspectionValueType!='5'" v-model="scope.row.ask" :autosize="{ minRows: 1, maxRows: 3}" clearable placeholder="è¦æ±å¼" |
| | | size="small" type="textarea" |
| | | @change="e=>requestChange(e,scope.row,'ask')"></el-input> |
| | | <span v-else> |
| | | <!-- <template v-if="(scope.row.ask.indexOf('D')>-1 |
| | | ||scope.row.ask.indexOf('W')>-1 |
| | | ||scope.row.ask.indexOf('X')>-1 |
| | | ||scope.row.ask.indexOf('RTS')>-1 |
| | | ||scope.row.ask.indexOf('H')>-1 |
| | | ||scope.row.ask.indexOf('L')>-1)&&active==1"> |
| | | <input class="askRts" v-model="scope.row.rts" /><br />{{ scope.row.ask }} |
| | | </template> |
| | | <template v-else>{{ scope.row.ask }}</template> --> |
| | | <template >{{ scope.row.ask }}</template> |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="è¦æ±æè¿°" min-width="220px" prop="tell"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-if="active==1&&isAskOnlyRead" v-model="scope.row.tell" :autosize="{ minRows: 1, maxRows: 3}" clearable placeholder="è¦æ±æè¿°" |
| | | size="small" type="textarea" |
| | | @change="e=>requestChange(e,scope.row,'tell')"></el-input> |
| | | <span v-else> |
| | | <template >{{ scope.row.tell }}</template> |
| | | </span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ¡ä»¶" min-width="140" prop="radius" show-overflow-tooltip></el-table-column> |
| | | <el-table-column label="è¯éªæ¹æ³" min-width="120" prop="methodS" show-overflow-tooltip> |
| | | <template slot="header" slot-scope="scope"> |
| | | <div style="display: flex;align-items: center;flex-direction: column;font-size: 14px"> |
| | | <span>è¯éªæ¹æ³</span> |
| | | <el-input |
| | | v-if="active==1" |
| | | v-model="methodS" |
| | | placeholder="请è¾å
¥" |
| | | size="mini" |
| | | @input="searchFilterList"/> |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="计éåä½" prop="unit" show-overflow-tooltip width="100"></el-table-column> |
| | | <el-table-column label="åä»·" prop="price" show-overflow-tooltip width="100"></el-table-column> |
| | | <!-- <el-table-column prop="manDay" label="é¢è®¡æ¶é´(天)" width="120" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="manHour" label="å·¥æ¶ç³»æ°" width="100" show-overflow-tooltip></el-table-column> --> |
| | | <!-- <el-table-column prop="deviceGroup" label="设å¤ç»" width="120" show-overflow-tooltip></el-table-column> --> |
| | | <el-table-column label="åºé´" min-width="120" prop="section" show-overflow-tooltip></el-table-column> |
| | | <el-table-column :filter-method="filterHandler" :filters="filters" label="åå®éªå®¤" min-width="130" prop="sonLaboratory" |
| | | show-overflow-tooltip></el-table-column> |
| | | </el-table> |
| | | </div> |
| | | </div> |
| | | <el-dialog :visible.sync="selectStandardTree" title="éæ©æ ·å" width="500px"> |
| | | <div v-if="selectStandardTree" v-loading="selectStandardTreeLoading" class="body" style="height: 60vh;overflow-y: auto;user-select: none;"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-input v-model="search" clearable placeholder="è¾å
¥å
³é®åè¿è¡æç´¢" size="small" |
| | | style="margin-bottom: 5px;" suffix-icon="el-icon-search" @blur="searchFilter" @clear="searchFilter" |
| | | @keyup.enter.native="searchFilter"></el-input> |
| | | </el-col> |
| | | </el-row> |
| | | <el-tree ref="tree" :data="list" :default-expanded-keys="expandedKeys" :filter-node-method="filterNode" |
| | | :props="{ children: 'children', label: 'label' }" highlight-current node-key="label" @node-click="handleNodeClick" |
| | | @node-expand="nodeOpen" @node-collapse="nodeClose" @dblclick.native="activeStandardTree"> |
| | | <div slot-scope="{ node, data }" class="custom-tree-node"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <span><i |
| | | :class="`node_i ${data.children != undefined ? (data.code==='[1]'?'el-icon-folder-opened':'el-icon-folder') : 'el-icon-tickets'}`"></i> |
| | | {{ data.code }} {{ data.label }}</span> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | </el-tree> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="selectStandardTree = false">å æ¶</el-button> |
| | | <el-button type="primary" @click="activeStandardTree">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | <!--ç¹æ®å¼å¤çæ¡--> |
| | | <el-dialog :before-close="beforeClose" :close-on-click-modal="false" :close-on-press-escape="false" :show-close="false" |
| | | :visible.sync="bsm1DiaAll" |
| | | min-width="400px" |
| | | title="æ£æµå°ç¹æ®é¡¹ï¼è¯·ä½åºä»¥ä¸éæ©"> |
| | | <div v-for="(item, index) in bsm1DiaList" :key="item.id" class="body" style="max-height: 60vh;"> |
| | | <span>{{item.inspectionItem}}</span> |
| | | <el-row v-if="item.bsm1"> |
| | | <el-col :span="24" class="search_thing" style="height: initial;margin: 5px 0;"> |
| | | <div class="search_label" style="width: 80px;"><span class="required-span">* </span>é项ï¼</div> |
| | | <div class="search_input"> |
| | | <el-radio-group v-model="item.bsm1Val" v-removeAriaHidden @input="upBsmAll(item)"> |
| | | <el-radio v-for="(a, ai) in JSON.parse(item.bsmRow.sectionCopy)" :key="ai" :label="a" style="margin-bottom: 2px;margin-top: 2px;"></el-radio> |
| | | </el-radio-group> |
| | | </div> |
| | | </el-col> |
| | | <el-col :span="24" class="search_thing" style="height: initial;margin: 5px 0;"> |
| | | <div class="search_label" style="width: 80px;">è¦æ±å¼ï¼</div> |
| | | <div class="search_input"> |
| | | <el-radio-group v-model="item.bsm1Val" v-removeAriaHidden @input="upBsmAll(item)"> |
| | | <el-radio v-for="(a, ai) in JSON.parse(item.bsmRow.sectionCopy)" :key="ai" |
| | | :label="a">{{JSON.parse(item.bsmRow.askCopy)[ai]}}</el-radio> |
| | | </el-radio-group> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-row> |
| | | <el-button :loading="saveLoad" type="primary" @click="save1">ç¡® å®</el-button> |
| | | </el-row> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" |
| | | :show-close="false" :visible.sync="bsm3Dia" |
| | | title="åºé´å¼å¡«å" width="800px"> |
| | | <el-table |
| | | :data="editTable" |
| | | height="80vh" style="width: 100%"> |
| | | <!-- inspectionItemList --> |
| | | <el-table-column |
| | | label="æ£éªé¡¹" |
| | | prop="inspectionItemList" |
| | | width="180"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="æ ·åç¼å·" |
| | | prop="sampleCode" |
| | | width="180"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="æ ·ååå·" |
| | | prop="model" |
| | | width="180"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="è¯å«ç¬¦å·" |
| | | prop="symbolItem"> |
| | | </el-table-column> |
| | | <el-table-column |
| | | label="è¯å«ç¬¦å¼" |
| | | prop="value"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.value" placeholder="请è¾å
¥" size="small" @input="inputValueHandler(scope.row,scope.$index)"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-row> |
| | | <el-button @click="bsm3Dia=false">å æ¶</el-button> |
| | | <el-button :loading="saveLoad" type="primary" @click="save0">ç¡® å®</el-button> |
| | | </el-row> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog |
| | | :visible.sync="noNeedCheckDia" |
| | | title="å
æ£æç¤º" |
| | | width="32%"> |
| | | <span>确认å
æ£å½åæ£éªåï¼</span> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button :loading="noNeedCheckLoad" @click="noNeedCheckDia = false">å æ¶</el-button> |
| | | <el-button :loading="noNeedCheckLoad" type="primary" @click="handleNoNeedCheck">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import Vue from 'vue' |
| | | import { |
| | | addRawCopperOrder, |
| | | getInsOrder, |
| | | getUserNow, |
| | | addRawCopperOrderExemptionOrder, |
| | | selectStandardTreeList2, |
| | | selectsStandardMethodByFLSSM, |
| | | selectInsOrderTemplate, |
| | | selectStandardProductList, |
| | | selectStandardMethodEnum |
| | | } from "@/api/business/rawMaterialOrder"; |
| | | |
| | | var validateSixDecimalPositives = (rule, value, callback) => { |
| | | if (value == 0 || value == null) { |
| | | callback(new Error('请è¾å
¥æ£ç¡®çæ°åæå°æ°')) |
| | | } else if (!/^[0-9]+.?[0-9]*$/.test(value)) { |
| | | callback(new Error('请è¾å
¥æ°åæå°æ°')) |
| | | } else { |
| | | callback() |
| | | } |
| | | } |
| | | |
| | | export default { |
| | | name: 'CopperView', |
| | | components: {}, |
| | | dicts: ['check_type', 'urgency_level'], |
| | | data() { |
| | | return { |
| | | active: '', |
| | | currentId: '', |
| | | sampleSelectionList: [],//æ ·åè¡¨æ ¼é䏿°æ® |
| | | editTable:[], |
| | | noNeedCheckLoad: false, // å
æ£æé®loading |
| | | template: null, |
| | | templates: [], |
| | | addObj: { |
| | | testQuantity: null, // æ½æ£æ°é |
| | | custom: null, |
| | | company: null, |
| | | userId: null, |
| | | companyId: '', |
| | | type: '0', // ç´§æ¥ç¨åº¦ |
| | | code: null, |
| | | remark: null, // 夿³¨ |
| | | mating: 0, |
| | | sample: null, // æ ·ååç§° |
| | | appointed: '', // çº¦å®æ¶é´ |
| | | buyUnitMeas: null, // åä½ |
| | | updateBatchNo: null, // æ¹æ¬¡å· |
| | | partDetail: null, // è§æ ¼åå· |
| | | declareDate: '', // å°è´§æ¶é´ |
| | | factory: null, |
| | | laboratory: null, |
| | | sampleType: null, |
| | | sampleNum: 1, |
| | | unit: null, |
| | | model: null, |
| | | method: null, |
| | | phone: null, |
| | | processing: 1, |
| | | isLeave: 0, |
| | | orderType: 'è¿åæ£éª', // æ£éªç±»å |
| | | supplierName: null, // ææåå®¶ |
| | | qtyArrived: null, // å°è´§æ°é |
| | | }, |
| | | sample: { |
| | | sampleCode: null, |
| | | laboratory: null, |
| | | factory: null, |
| | | sampleType: null, |
| | | sample: null, |
| | | model: null, |
| | | modelNum: null, |
| | | sampleNum: 1, |
| | | isLeave: 0, |
| | | unit: null |
| | | }, |
| | | selectStandardTree: false, |
| | | search: null, |
| | | list: [], |
| | | selectStandardTreeLoading: false, |
| | | selectTree: null, |
| | | expandedKeys: [], |
| | | sampleList: [], |
| | | sampleIds: [], |
| | | methodList: [], |
| | | addSampleDia: false, |
| | | count: 1, |
| | | productList: [], |
| | | productList0: [], |
| | | bsm1DiaList: [], |
| | | productIds: [], |
| | | productListSelected: [], |
| | | getProductLoad: false, |
| | | saveLoad: false, |
| | | templateDia: false, |
| | | templateLoading: false, |
| | | templateName: '', |
| | | upLoad: false, |
| | | units: [], |
| | | models: [], |
| | | methods: [], |
| | | methodLoad: false, |
| | | filters: [], |
| | | currentMethod: null, |
| | | isAskOnlyRead: false, |
| | | sampleId: null, |
| | | bsmRow: null, |
| | | bsm1: false, |
| | | bsm1Val: null, |
| | | bsm1DiaAll: false, |
| | | bsm2: false, |
| | | bsm2Val: null, |
| | | bsm2Dia: false, |
| | | bsmRow3: null, |
| | | bsm3Val: null, |
| | | bsm3Dia: false, |
| | | // total: 0, |
| | | RTS: '', |
| | | totalArr: [], |
| | | addObj1: {}, |
| | | model: null, |
| | | standardMethodListId: null, |
| | | symbolList:['RTS'], |
| | | inspectionItem:null, |
| | | inspectionItemSubclass:null, |
| | | methodS:null, |
| | | isBsm2Val2:false, |
| | | isShowInput: false, |
| | | temId: '', |
| | | selectiveEcho: [], // æ£éªä¸åçæ¶åå¾éæ£éªé¡¹ç®,å¦æä½¿ç¨çéæäº¤æ¾ç¤ºæ£éªé¡¹ç®ä¸ºç©º åæ¾å表 |
| | | addObjRules: { // è¡¨åæ ¡éªè§å |
| | | sample: [ |
| | | { required: true, message: 'è¯·éæ©æ ·å', trigger: 'change' } |
| | | ], |
| | | qtyArrived: [ |
| | | { validator: validateSixDecimalPositives, trigger: 'blur' } |
| | | ], |
| | | testQuantity: [ |
| | | { required: true, message: 'è¯·å¡«åæ½æ£æ°é', trigger: 'blur' } |
| | | ], |
| | | supplierName: [ |
| | | { required: true, message: 'è¯·å¡«åææåå®¶', trigger: 'blur' } |
| | | ], |
| | | appointed: [ |
| | | { required: true, message: 'è¯·éæ©çº¦å®æ¶é´', trigger: 'change' } |
| | | ], |
| | | buyUnitMeas: [ |
| | | { required: true, message: '请填ååä½', trigger: 'blur' } |
| | | ], |
| | | updateBatchNo: [ |
| | | { required: true, message: 'è¯·å¡«åæ¹æ¬¡å·', trigger: 'blur' } |
| | | ], |
| | | partDetail: [ |
| | | { required: true, message: '请填åè§æ ¼åå·', trigger: 'blur' } |
| | | ], |
| | | declareDate: [ |
| | | { required: true, message: '请填åå°è´§æ¶é´', trigger: 'change' } |
| | | ] |
| | | }, |
| | | noNeedCheckDia: false, |
| | | } |
| | | }, |
| | | watch: { |
| | | sampleList() { |
| | | this.addObj.method = null |
| | | this.productList = [] |
| | | }, |
| | | productList: { |
| | | deep: true, |
| | | handler(val) { |
| | | if (val && val.length > 0) { |
| | | let arr = []; |
| | | val.forEach(item => { |
| | | if (item.sonLaboratory && !arr.find(a => a.value == item.sonLaboratory)) { |
| | | arr.push({ |
| | | text: item.sonLaboratory, |
| | | value: item.sonLaboratory |
| | | }) |
| | | } |
| | | }) |
| | | this.filters = arr |
| | | } |
| | | } |
| | | }, |
| | | sampleList: { |
| | | deep: true, |
| | | handler(val) { |
| | | this.getTotal() |
| | | } |
| | | }, |
| | | 'addObj.sample'(val) { |
| | | this.model = null |
| | | this.standardMethodListId = null |
| | | }, |
| | | 'addObj.sampleNum'(val) { |
| | | this.model = null |
| | | this.standardMethodListId = null |
| | | } |
| | | }, |
| | | mounted() { |
| | | this.active = this.$route.query.active |
| | | this.currentId = this.$route.query.currentId |
| | | this.getInfoRow(); |
| | | }, |
| | | activated() { |
| | | this.active = this.$route.query.active |
| | | this.currentId = this.$route.query.currentId |
| | | this.getInfoRow(); |
| | | }, |
| | | methods: { |
| | | getInfoRow() { |
| | | this.getUserNowInfo() |
| | | this.selectStandardTreeList() |
| | | this.selectStandardMethods() |
| | | this.getInfo() // è·åæ°æ® |
| | | }, |
| | | // æå |
| | | handleSplitCountNum () { |
| | | this.sample.joinName = null |
| | | this.sample.joinModel = null |
| | | this.sample.joinNum = 1 |
| | | // ä¸¤æ¡æ°æ®ä¿æä¸è´ |
| | | this.sample.sample = this.sampleList[0].sample |
| | | this.sample.model = this.sampleList[0].model |
| | | this.sample.unit = this.sampleList[0].unit |
| | | this.sample.modelNum = this.sampleList[0].modelNum |
| | | this.sample.standardMethodListId = this.sampleList[0].standardMethodListId |
| | | this.sample.insProduct = [] |
| | | this.sample.id = this.count |
| | | this.sample.childSampleList = [] |
| | | this.sample.insulating = null |
| | | this.sample.sheath = null |
| | | this.sampleList.push(this.HaveJson(this.sample)) |
| | | this.sampleList.forEach(item => { |
| | | item.quantity = 1 |
| | | }) |
| | | this.count++ |
| | | }, |
| | | noNeedCheck () { |
| | | this.$refs['addObj'].validate((valid) => { |
| | | if (valid) { |
| | | if (!this.sampleList.every(m => m.standardMethodListId)) { |
| | | this.$message.error('è¯·éæ©æ£éªæ å') |
| | | return |
| | | } |
| | | // æ£éªç±»å为è¿åæ£éªæ¶å¯éæ©å
æ£ï¼ä½ä¸è½éæ©æ£éªé¡¹ |
| | | const sampleList = this.HaveJson(this.sampleList) |
| | | sampleList.forEach(item => { |
| | | item.insProduct = this.productList |
| | | }) |
| | | this.getTotal(sampleList) |
| | | let projectNum = this.totalArr.filter(a => a.state == 1).length |
| | | if (projectNum!=0){ |
| | | this.$message.error('å
æ£ä¸å¯éæ©æ£éªé¡¹') |
| | | return |
| | | } |
| | | this.noNeedCheckDia = true |
| | | } else { |
| | | console.log('error submit!!'); |
| | | return false; |
| | | } |
| | | }); |
| | | }, |
| | | handleNoNeedCheck () { |
| | | const sampleList = this.HaveJson(this.sampleList) |
| | | sampleList.forEach(item => { |
| | | item.insProduct = this.productList |
| | | }) |
| | | this.getTotal(sampleList) |
| | | let projectNum = this.totalArr.filter(a => a.state == 1).length |
| | | if (projectNum!=0){ |
| | | this.$message.error('å
æ£ä¸å¯éæ©æ£éªé¡¹') |
| | | } else { |
| | | let trees = this.selectTree.split(" - ") |
| | | if (trees.length < 3) { |
| | | this.$message.error('æªéæ©å¯¹è±¡') |
| | | return |
| | | } |
| | | this.addObj.factory = trees[0] |
| | | this.addObj.laboratory = trees[1] |
| | | this.addObj.sampleType = trees[2] |
| | | if (trees[3] === undefined || trees[3] === '') { |
| | | this.addObj.sample = trees[2] |
| | | } else { |
| | | this.addObj.sample = trees[3] |
| | | } |
| | | this.addObj.model = (trees[4] == undefined ? null : trees[4]) |
| | | this.noNeedCheckLoad = true |
| | | addRawCopperOrderExemptionOrder({ |
| | | copperInsOrder: this.addObj, |
| | | sampleList: sampleList.map(a => { |
| | | if (a.insProduct.length > 0) { |
| | | a.insProduct.forEach(c => { |
| | | delete c.id |
| | | }) |
| | | } |
| | | if (a.modelNum) { |
| | | // æ ¹æ®xå·å¤æåå·åæ°ä¸æ ·ååå·çæ¼æ¥ä½ç½® |
| | | // ä¾å¦Ã4ï¼å°±ä¸º500MLÃ4ï¼4Ãï¼å°±ä¸º4Ã500ML |
| | | const index = a.modelNum.indexOf('Ã') |
| | | if (index === 0) { |
| | | a.model = a.model + a.modelNum |
| | | } else if (index === -1) { |
| | | a.model = a.model + '-' + a.modelNum |
| | | } else { |
| | | a.model = a.modelNum + a.model |
| | | } |
| | | } else { |
| | | a.model = a.model + ((a.modelNum == null || a.modelNum == '' || a.modelNum == 'null') ? '' : ('-' + a.modelNum)) |
| | | } |
| | | a.insProduct = a.insProduct.filter(b=>b.state === 1) |
| | | return a |
| | | }) |
| | | }).then(res => { |
| | | this.noNeedCheckLoad = false |
| | | this.$message.success('å·²æäº¤') |
| | | this.closeOpenPage() |
| | | }).catch(e=>{ |
| | | this.noNeedCheckLoad = false |
| | | }) |
| | | } |
| | | }, |
| | | // è·åæ°æ® |
| | | getInfo () { |
| | | if (this.active != 1) { |
| | | // æ¥çæµç¨ |
| | | // è¯·æ±æ¥å£ï¼åæ¾æ°æ® |
| | | getInsOrder({orderId: this.currentId}).then(res => { |
| | | this.addObj = { |
| | | ...res.data.insOrder |
| | | } |
| | | this.$set(this.addObj, 'qtyArrived', res.data.insOrderTemplate.qtyArrived) |
| | | this.$set(this.addObj, 'buyUnitMeas', res.data.insOrderTemplate.buyUnitMeas) |
| | | this.$set(this.addObj, 'updateBatchNo', res.data.insOrderTemplate.updateBatchNo) |
| | | this.$set(this.addObj, 'supplierName', res.data.insOrderTemplate.supplierName) |
| | | this.addObj.type = String(this.addObj.type) |
| | | this.sampleList = this.HaveJson(res.data.sampleProduct); |
| | | this.getProNum() |
| | | this.addObj.sampleNum = this.sampleList.length |
| | | this.$nextTick(() => { |
| | | this.$refs.sampleTable.doLayout() |
| | | if (this.sampleList.length > 0) { // æ¥çæ¶å¦æææ ·åé»è®¤éä¸ç¬¬ä¸æ¡ |
| | | this.productList = this.sampleList[0].insProduct |
| | | this.$refs.sampleTable.setCurrentRow(this.sampleList[0], true) |
| | | this.rowClick(this.sampleList[0]) |
| | | } |
| | | }) |
| | | }) |
| | | } |
| | | }, |
| | | //ç¹æ®å¼å¡«åå¤ç |
| | | inputValueHandler(row,index){ |
| | | if(row){ |
| | | const nextIndex = index+1 |
| | | for (let i = nextIndex; i < this.editTable.length; i++) { |
| | | const element = this.editTable[i]; |
| | | if(element.model==row.model&&row.symbolItem==element.symbolItem){ |
| | | this.editTable[i].value = row.value |
| | | } |
| | | } |
| | | } |
| | | }, |
| | | changeProductList0(){ |
| | | this.productList0.forEach(a=>{ |
| | | let obj = this.productList.find(m => m.id == a.id) |
| | | if(obj){ |
| | | a.state = obj.state |
| | | a.section = obj.section |
| | | a.ask = obj.ask |
| | | a.manHour = obj.manHour |
| | | a.price = obj.price |
| | | a.tell = obj.tell |
| | | } |
| | | if(a.state == 0&&a.bsmRow){ |
| | | a = this.HaveJson(a.bsmRow) |
| | | } |
| | | }) |
| | | }, |
| | | searchFilterList () { |
| | | const vtw = { |
| | | inspectionItem: this.inspectionItem, // æ£éªé¡¹ |
| | | inspectionItemSubclass: this.inspectionItemSubclass, // æ£éªé¡¹å项 |
| | | methodS: this.methodS, // è¯éªæ¹æ³ |
| | | } |
| | | const isHaveValue = Object.values(vtw).some(item => { |
| | | return item |
| | | }) |
| | | this.changeProductList0() |
| | | if (isHaveValue) { |
| | | for(let i in vtw) { |
| | | if (vtw[i]) { |
| | | this.productList = this.productList0.filter((item) => { |
| | | return item[i] && item[i].includes(vtw[i]) |
| | | }) |
| | | } |
| | | } |
| | | this.$nextTick(()=>{ |
| | | this.productList.forEach(a => { |
| | | if (a.state == 1) this.toggleSelection(a) |
| | | }) |
| | | }) |
| | | } else { |
| | | // æ²¡ææ¥è¯¢æ¡ä»¶æ¶æ¸²ææææ°æ® |
| | | this.productList = this.productList0 |
| | | this.$nextTick(()=>{ |
| | | this.productList.forEach(a => { |
| | | if (a.state == 1) this.toggleSelection(a) |
| | | }) |
| | | }) |
| | | } |
| | | }, |
| | | containsValue(str) { |
| | | if(str){ |
| | | let symbolItem = '' |
| | | this.symbolList.some(value =>{ |
| | | if(str.includes(value)){ |
| | | symbolItem = value |
| | | return true |
| | | } |
| | | }) |
| | | return symbolItem |
| | | } |
| | | }, |
| | | handleAsk(ask,symbolItem, value) { |
| | | try{ |
| | | let code = [">", "<", "=", "ï¼", "ï¼", "â¥", "â¤", "±"]; |
| | | let code2 = ['+', '*', '/', '-'] |
| | | if (ask.includes('&')) { |
| | | // å¤ä¸ªæ¡ä»¶ |
| | | let arr0 = ask.split('&') |
| | | let arr1 = [] |
| | | arr0.forEach(m => { |
| | | let index = code.findIndex(b => m.includes(b)) |
| | | if (index > -1) { |
| | | let arr = m.split(code[index]).filter(b => !!b) |
| | | let num = eval(this.replaceAll(arr[0], symbolItem, value)) |
| | | m = code[index] + '' + num |
| | | arr1.push(m) |
| | | } |
| | | }) |
| | | return arr1.join('&') |
| | | } else if (ask.includes('ï½') || ask.includes('~')) { |
| | | let arr0 = [] |
| | | if (ask.includes('ï½')) { |
| | | arr0 = ask.split('ï½') |
| | | } else { |
| | | arr0 = ask.split('~') |
| | | } |
| | | // å¤ä¸ªæ¡ä»¶ |
| | | let arr1 = [] |
| | | arr0.forEach(m => { |
| | | m = m.replace(symbolItem, value) |
| | | const index = code2.findIndex(b => m.includes(b)) |
| | | if (index > -1) { |
| | | m = eval(m) |
| | | } |
| | | arr1.push(m) |
| | | }) |
| | | return arr1.join('ï½') |
| | | } else { |
| | | // å个æ¡ä»¶ |
| | | let index = code.findIndex(b => ask.includes(b)) |
| | | if (index > -1) { |
| | | let arr = ask.split(code[index]).filter(b => !!b) |
| | | let num = eval(this.replaceAll(arr[0], symbolItem, value)) |
| | | return code[index] + '' + num |
| | | } |
| | | } |
| | | }catch(e){} |
| | | }, |
| | | handleTell(tell,symbolItem, value){ |
| | | try{ |
| | | let num = this.replaceAll(tell, symbolItem, value) |
| | | return num |
| | | }catch(e){} |
| | | }, |
| | | replaceAll(str,find,value) { |
| | | if (str === undefined) { |
| | | return str |
| | | } |
| | | return str.replaceAll(find, value); |
| | | }, |
| | | save() { |
| | | this.$refs['addObj'].validate((valid) => { |
| | | if (valid) { |
| | | if (!this.sampleList.every(m => m.standardMethodListId)) { |
| | | this.$message.error('è¯·éæ©æ£éªæ å') |
| | | return |
| | | } |
| | | const sampleList = this.HaveJson(this.sampleList) |
| | | sampleList.forEach(item => { |
| | | item.quantity = 1 |
| | | item.insProduct = this.productList |
| | | }) |
| | | this.getTotal(sampleList) |
| | | let projectNum = this.totalArr.filter(a => a.state == 1).length |
| | | if(projectNum==0){ |
| | | this.$confirm('æ£éªé¡¹ç®ä¸ºç©ºï¼æ¯å¦ç¡®è®¤æäº¤?', "æç¤º", { |
| | | confirmButtonText: "ç¡®å®", |
| | | cancelButtonText: "åæ¶", |
| | | type: "warning" |
| | | }).then(() => { |
| | | this.saveMethod(sampleList) |
| | | }).catch(() => {}) |
| | | }else{ |
| | | let isRTS = this.totalArr.find(a => a.ask != null && this.symbolList.find(b=>a.ask.includes(b)) && a.state == 1) |
| | | if (isRTS) { |
| | | this.editTable = this.handleData(sampleList,this.containsValue, 0) |
| | | this.editTable.forEach(item => { |
| | | item.value = item.modelNum |
| | | }) |
| | | this.bsm3Dia = true; |
| | | return |
| | | } |
| | | this.saveMethod(sampleList) |
| | | } |
| | | } else { |
| | | console.log('error submit!!'); |
| | | return false; |
| | | } |
| | | }); |
| | | }, |
| | | save0(){ |
| | | if(this.editTable.every(m=>m.value)){ |
| | | this.sampleList.forEach(item => { |
| | | item.quantity = 1 |
| | | item.insProduct = this.productList |
| | | }) |
| | | let sampleList = this.handleData(this.HaveJson(this.sampleList),this.handleAsk,1) |
| | | sampleList.forEach(a => { |
| | | a.insProduct = a.insProduct.filter(b=>b.state === 1) |
| | | }) |
| | | this.saveMethod(sampleList) |
| | | }else{ |
| | | this.$message.error('请填åè¯å«ç¬¦å¼') |
| | | } |
| | | }, |
| | | handleData(sampleList,calBack,type){ |
| | | let editTable = [] |
| | | sampleList.forEach(item => { |
| | | let obj = { |
| | | sampleCode:item.sampleCode, |
| | | model:item.model, |
| | | symbolList:[], |
| | | sampleId:item.id, |
| | | modelNum:item.modelNum, |
| | | } |
| | | if (item.insProduct && item.insProduct.length > 0) { |
| | | item.insProduct.forEach(a => { |
| | | if (a.state == 1) { |
| | | if(type==0){ |
| | | let str = calBack(a.ask) |
| | | str&&obj.symbolList.push({ |
| | | symbolItem:str, |
| | | inspectionItem:a.inspectionItem, |
| | | }) |
| | | }else if(type==1){ |
| | | let arr = this.editTable.filter(b => b.sampleId == item.id) |
| | | for (var i=0;i<arr.length;i++){ |
| | | if(a.ask){ |
| | | if(a.ask.includes(arr[i].symbolItem)){ |
| | | let ask = calBack(a.ask, arr[i].symbolItem,arr[i].value) |
| | | if (ask) { |
| | | a.ask = ask |
| | | } |
| | | let tell = this.handleAsk(a.tell, arr[i].symbolItem,arr[i].value) |
| | | if (tell) { |
| | | a.tell = tell |
| | | } |
| | | } |
| | | }else{ |
| | | this.$message.error('è¦æ±å¼ä¸ºç©ºï¼éè¦å»æ ååºç»´æ¤ï¼') |
| | | } |
| | | } |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | // å
çº¤å¸¦é¡¹ç® |
| | | if (item.bushing && item.bushing.length > 0) { |
| | | item.bushing.forEach(a => { |
| | | if (a.fiber && a.fiber.length > 0) { |
| | | a.fiber.forEach(b => { |
| | | if (b.productList && b.productList.length > 0) { |
| | | b.productList.forEach(c => { |
| | | if (c.state == 1) { |
| | | if(type==0){ |
| | | let str = calBack(c.ask) |
| | | str&&obj.symbolList.push({ |
| | | symbolItem:str, |
| | | inspectionItem:c.inspectionItem, |
| | | }) |
| | | }else if(type==1){ |
| | | let arr = this.editTable.filter(b => b.sampleId == item.id) |
| | | arr.forEach(f => { |
| | | if(c.ask.includes(f.symbolItem)){ |
| | | let ask = calBack(c.ask, f.symbolItem,f.value) |
| | | if (ask) { |
| | | c.ask = ask |
| | | } |
| | | let tell = this.handleTell(c.tell, f.symbolItem,f.value) |
| | | if (tell) { |
| | | c.tell = tell |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | if (a.fibers && a.fibers.length > 0) { |
| | | a.fibers.forEach(b => { |
| | | if (b.productList && b.productList.length > 0) { |
| | | b.productList.forEach(c => { |
| | | if (c.state == 1) { |
| | | if(type==0){ |
| | | let str = calBack(c.ask) |
| | | str&&obj.symbolList.push({ |
| | | symbolItem:str, |
| | | inspectionItem:c.inspectionItem, |
| | | }) |
| | | }else if(type==1){ |
| | | // let ask = calBack(c.ask, c.rts) |
| | | // if (ask && c.state == 1) { |
| | | // c.ask = csk |
| | | // } |
| | | let arr = this.editTable.filter(b => b.sampleId == item.id) |
| | | arr.forEach(f => { |
| | | if(c.ask.includes(f.symbolItem)){ |
| | | let ask = calBack(c.ask, f.symbolItem,f.value) |
| | | if (ask) { |
| | | c.ask = ask |
| | | } |
| | | let tell = this.handleTell(c.tell, f.symbolItem,f.value) |
| | | if (tell) { |
| | | c.tell = tell |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | if (b.fiber && b.fiber.length > 0) { |
| | | b.fiber.forEach(c => { |
| | | if (c.productList && c.productList.length > 0) { |
| | | c.productList.forEach(d => { |
| | | if (d.state == 1) { |
| | | if(type==0){ |
| | | let str = calBack(d.ask) |
| | | str&&obj.symbolList.push({ |
| | | symbolItem:str, |
| | | inspectionItem:d.inspectionItem, |
| | | }) |
| | | }else if(type==1){ |
| | | // let ask = calBack(d.ask, d.rts) |
| | | // if (ask && d.state == 1) { |
| | | // d.ask = ask |
| | | // } |
| | | let arr = this.editTable.filter(b => b.sampleId == item.id) |
| | | arr.forEach(f => { |
| | | if(d.ask.includes(f.symbolItem)){ |
| | | let ask = calBack(d.ask, f.symbolItem,f.value) |
| | | if (ask) { |
| | | d.ask = ask |
| | | } |
| | | let tell = this.handleTell(d.tell, f.symbolItem,f.value) |
| | | if (tell) { |
| | | d.tell = tell |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | if(type==0){ |
| | | editTable.push(obj) |
| | | } |
| | | }) |
| | | if(type==0){ |
| | | editTable.forEach(a => { |
| | | a.symbolList.forEach(b => { |
| | | let arr = a.symbolList.filter(c => c.symbolItem == b.symbolItem); |
| | | b.inspectionItemList = arr.map(c => c.inspectionItem).join(',') |
| | | }) |
| | | }) |
| | | editTable.forEach(a => { |
| | | let mySet = new Set(); |
| | | a.symbolList = a.symbolList.filter(b =>{ |
| | | let num0 = mySet.size; |
| | | mySet.add(b.symbolItem); |
| | | let num1 = mySet.size; |
| | | if(num0!=num1){ |
| | | return true; |
| | | }else{ |
| | | return false |
| | | } |
| | | }) |
| | | }) |
| | | let editTableNew = [] |
| | | editTable.forEach(a => { |
| | | a.symbolList.forEach(b => { |
| | | let obj = { |
| | | sampleCode:a.sampleCode, |
| | | model:a.model, |
| | | symbolItem:b.symbolItem, |
| | | sampleId:a.sampleId, |
| | | value:null, |
| | | inspectionItemList:b.inspectionItemList, |
| | | modelNum:a.modelNum, |
| | | } |
| | | editTableNew.push(obj) |
| | | }) |
| | | }) |
| | | return editTableNew |
| | | }else{ |
| | | return sampleList |
| | | } |
| | | }, |
| | | saveMethod(sampleList){ |
| | | this.saveLoad = true |
| | | addRawCopperOrder({ |
| | | copperInsOrder: this.addObj, |
| | | sampleList: sampleList.map(a => { |
| | | if (a.insProduct.length > 0) { |
| | | a.insProduct.forEach(c => { |
| | | delete c.id |
| | | }) |
| | | } |
| | | if (a.modelNum) { |
| | | const index = a.modelNum.indexOf('Ã') |
| | | if (index === 0) { |
| | | a.model = a.model + a.modelNum |
| | | } else if (index === -1) { |
| | | a.model = a.model + '-' + a.modelNum |
| | | } else { |
| | | a.model = a.modelNum + a.model |
| | | } |
| | | } else { |
| | | a.model = a.model + ((a.modelNum == null || a.modelNum == '' || a.modelNum == 'null') ? '' : ('-' + a.modelNum)) |
| | | } |
| | | a.insProduct = a.insProduct.filter(b=>b.state === 1) |
| | | return a |
| | | }) |
| | | }).then(res => { |
| | | this.saveLoad = false |
| | | this.$message.success('å·²æäº¤') |
| | | this.bsm3Dia = false; |
| | | this.closeOpenPage() |
| | | }).catch(e=>{ |
| | | this.saveLoad = false |
| | | }) |
| | | }, |
| | | getUserNowInfo() { |
| | | getUserNow().then(res => { |
| | | let selects = res.data |
| | | if (selects == null) return |
| | | this.addObj.userId = selects.id |
| | | this.addObj.company = selects.company |
| | | this.addObj.custom = selects.name |
| | | this.addObj.code = selects.code |
| | | this.addObj.phone = selects.phone |
| | | this.addObj.companyId = selects.departId |
| | | // if(this.active==1){ |
| | | // this.selectInsOrderTemplateInfo() |
| | | // } |
| | | }) |
| | | }, |
| | | getProNum() { |
| | | this.$refs.sampleTable.doLayout() |
| | | }, |
| | | searchFilter() { |
| | | this.$refs.tree.filter(this.search) |
| | | }, |
| | | nodeOpen(data, node, el) { |
| | | $($(el.$el).find('.node_i')[0]).attr('class', 'node_i el-icon-folder-opened') |
| | | }, |
| | | nodeClose(data, node, el) { |
| | | $($(el.$el).find('.node_i')[0]).attr('class', 'node_i el-icon-folder') |
| | | }, |
| | | handleNodeClick(val, node, el) { |
| | | this.selectTree = '' |
| | | this.models = val.children |
| | | this.getNodeParent(node) |
| | | let flag = false |
| | | if (node.level == 3) { |
| | | if(node.data.children.length>0){ |
| | | node.data.children.forEach(a => { |
| | | let key = Object.keys(a) |
| | | if(!key.includes('level')) { |
| | | flag = true |
| | | } |
| | | }) |
| | | |
| | | } |
| | | } |
| | | this.selectTree = this.selectTree.replace(' - ', '') |
| | | if(flag) { |
| | | this.selectTree = ' - - ' + this.selectTree |
| | | } |
| | | let data = this.selectTree.split(' - ') |
| | | let data2 = '' |
| | | for (let index = data.length - 1; index >= 0; index--) { |
| | | data2 += " - " + data[index] |
| | | } |
| | | this.selectTree = data2.replace(' - ', '') |
| | | }, |
| | | getNodeParent(val) { |
| | | if (val.parent != null) { |
| | | if (val.data.children === null) { |
| | | this.selectTree += ' - ' + val.label + ' - ' + '' |
| | | } else { |
| | | this.selectTree += ' - ' + val.label |
| | | } |
| | | this.getNodeParent(val.parent) |
| | | } |
| | | }, |
| | | selectStandardTreeList() { |
| | | this.selectStandardTreeLoading = true |
| | | selectStandardTreeList2().then(res => { |
| | | this.list = res.data |
| | | this.list.forEach(a => { |
| | | this.expandedKeys.push(a.label) |
| | | }) |
| | | this.selectStandardTreeLoading=false |
| | | }) |
| | | }, |
| | | filterNode(value, data) { |
| | | if (!value) return true; |
| | | return data.label.indexOf(value) !== -1; |
| | | }, |
| | | activeStandardTree() { |
| | | let trees = this.selectTree.split(" - ") |
| | | if (trees.length < 3) { |
| | | this.$message.error('æªéæ©å¯¹è±¡') |
| | | return |
| | | } |
| | | this.addObj.factory = trees[0] |
| | | this.addObj.laboratory = trees[1] |
| | | this.addObj.sampleType = trees[2] |
| | | if (trees[3] === undefined || trees[3] === '' || trees[3] === '- ') { |
| | | this.addObj.sample = trees[2] |
| | | } else { |
| | | this.addObj.sample = trees[3] |
| | | } |
| | | this.addObj.model = (trees[4] == undefined ? null : trees[4]) |
| | | this.selectStandardTree = false |
| | | this.sampleList = [] |
| | | for (var i = 0; i < this.addObj.sampleNum; i++) { |
| | | this.sample.joinName = null |
| | | this.sample.joinModel = null |
| | | this.sample.joinNum = 1 |
| | | this.sample.sample = this.addObj.sample |
| | | this.sample.model = this.addObj.model |
| | | this.sample.unit = this.addObj.unit |
| | | this.sample.standardMethodListId = null |
| | | this.sample.insProduct = [] |
| | | this.sample.id = this.count |
| | | this.sample.childSampleList = [] |
| | | this.sample.insulating = null |
| | | this.sample.sheath = null |
| | | this.sampleList.push(this.HaveJson(this.sample)) |
| | | this.count++ |
| | | } |
| | | this.$refs.sampleTable.doLayout() |
| | | // this.selectsStandardMethodByFLSSM() |
| | | }, |
| | | selectsStandardMethodByFLSSM() { |
| | | this.methodLoad = true |
| | | selectsStandardMethodByFLSSM({tree: this.selectTree}).then(res => { |
| | | this.methodLoad = false |
| | | try { |
| | | if (res.data.standardMethodList.length == 0 && this.selectTree.split('-').length == 5) { |
| | | let arr = this.selectTree.split('-') |
| | | let arr0 = arr.slice(0, arr.length - 1) |
| | | let selectTree = arr0.join('-').substring(0, arr0.join('-').length - 1) |
| | | selectsStandardMethodByFLSSM({tree: selectTree}).then(ress => { |
| | | this.methods = ress.data.standardMethodList |
| | | }) |
| | | } else { |
| | | this.methods = res.data.standardMethodList |
| | | } |
| | | } catch (e) {} |
| | | }) |
| | | }, |
| | | addStandardTree() { |
| | | if (this.selectTree == null) return |
| | | this.sampleList = [] |
| | | this.productList = [] |
| | | for (var i = 0; i < this.addObj.sampleNum; i++) { |
| | | this.sample.joinName = null |
| | | this.sample.joinModel = null |
| | | this.sample.joinNum = 1 |
| | | this.sample.sample = this.addObj.sample |
| | | this.sample.model = this.addObj.model |
| | | this.sample.unit = this.addObj.unit |
| | | this.sample.standardMethodListId = null |
| | | this.sample.insProduct = [] |
| | | this.sample.id = parseInt(i+1) |
| | | this.sample.childSampleList = [] |
| | | this.sample.insulating = null |
| | | this.sample.sheath = null |
| | | this.sampleList.push(this.HaveJson(this.sample)) |
| | | // this.count++ |
| | | } |
| | | }, |
| | | selectSample(val) { |
| | | this.sampleIds = [] |
| | | val.forEach(a => { |
| | | this.sampleIds.push(a.id) |
| | | }) |
| | | this.sampleSelectionList = val |
| | | }, |
| | | selectProduct(val) { |
| | | this.productListSelected = val |
| | | this.productIds = [] |
| | | val.forEach(a => { |
| | | this.productIds.push(a.id) |
| | | }) |
| | | }, |
| | | rowClick(row, column, event) { |
| | | this.currentMethod = row |
| | | let obj = this.methods.find(a => a.id == this.currentMethod.standardMethodListId) |
| | | if (obj && obj.code == 'ææ¯è¦æ±') { |
| | | this.isAskOnlyRead = true |
| | | } else { |
| | | this.isAskOnlyRead = false |
| | | } |
| | | this.sampleId = row.id |
| | | if (this.active !== 1) { |
| | | this.sampleIds = [] |
| | | this.sampleSelectionList.forEach(ele=>{ |
| | | if(ele.id == row.id){ |
| | | this.sampleIds.push(row.id) |
| | | } |
| | | }) |
| | | } |
| | | // this.productList = row.insProduct |
| | | if (this.productList !== null) { |
| | | setTimeout(() => { |
| | | this.productList.forEach(a => { |
| | | if (a.state == 1) this.toggleSelection(a) |
| | | }) |
| | | }, 200) |
| | | } |
| | | }, |
| | | toggleSelection(row) { |
| | | this.$refs.productTable.toggleRowSelection(row, true); |
| | | }, |
| | | selectOne(selection, row) { |
| | | this.bsm1DiaList = [] |
| | | row.state = row.state == 1 ? 0 : 1 |
| | | if(row.section === null) { |
| | | row.section = "" |
| | | } |
| | | if (row.sectionCopy === undefined && row.section) { |
| | | if (row.section.indexOf('[') > -1) { |
| | | this.$set(row, 'sectionCopy', row.section) |
| | | } |
| | | } |
| | | if (row.ask.includes('[')) { |
| | | this.$set(row, 'askCopy', row.ask) |
| | | } |
| | | if (row.tell.includes('[')) { |
| | | this.$set(row, 'tellCopy', row.tell) |
| | | } |
| | | // if (row.manHour.includes('[')) { |
| | | // this.$set(row, 'manHourCopy', row.manHour) |
| | | // } |
| | | // if (row.price.includes('[')) { |
| | | // this.$set(row, 'priceCopy', row.price) |
| | | // } |
| | | let arr = this.productList.filter(m=>m.state==1&&row.sectionCopy&&row.sectionCopy.includes(m.sectionCopy)&&m.ask&&m.sectionCopy.indexOf('[')==-1) |
| | | if (row.bsm === '1' && row.sectionCopy !== '' && row.sectionCopy !== null && row.sectionCopy !== undefined && row.state === 1&&arr.length==0) { |
| | | if (row.sectionCopy.indexOf('[') > -1) { |
| | | row.bsmRow = this.HaveJson(row) |
| | | } |
| | | row.bsm1 = true |
| | | this.bsm1DiaList.push(row) |
| | | this.bsm1DiaAll = true |
| | | } else if (row.bsm === '1' && row.sectionCopy !== '' && row.sectionCopy !== null && row.state === 0&&arr.length==0) { |
| | | row.bsm1 = false |
| | | }else if(arr.length>0){ |
| | | try{ |
| | | row.bsmRow = this.HaveJson(row) |
| | | let sectionCopy = arr[0].sectionCopy |
| | | let arr0 = JSON.parse(row.sectionCopy) |
| | | let arr1 = JSON.parse(row.ask) |
| | | // let arr2 = JSON.parse(row.manHour) |
| | | // let arr3 = JSON.parse(row.price) |
| | | let arr4 = JSON.parse(row.tell) |
| | | let index = arr0.indexOf(sectionCopy) |
| | | row.sectionCopy = sectionCopy |
| | | row.ask = arr1[index] |
| | | // row.manHour = arr2[index] |
| | | // row.price = arr3[index] |
| | | row.tell = arr4[index] |
| | | } catch(e) {} |
| | | } |
| | | this.sampleList.map(item => { |
| | | if (this.sampleIds.indexOf(item.id) > -1) { |
| | | item.insProduct.map(m => { |
| | | if (m.id == row.id) { |
| | | m.state = row.state; |
| | | } |
| | | return m; |
| | | }) |
| | | } |
| | | return item |
| | | }) |
| | | this.changeProductList0() |
| | | this.currentMethod.insProduct = this.productList0 |
| | | this.getProNum() |
| | | }, |
| | | permute(nums) { |
| | | const result = []; |
| | | |
| | | function backtrack(temp, nums) { |
| | | if (temp.length === 2) { |
| | | result.push([...temp]); |
| | | return; |
| | | } |
| | | for (let i = 0; i < nums.length; i++) { |
| | | if (temp.includes(nums[i])) continue; |
| | | // é¿å
é夿°å |
| | | if (temp.length > 0 && nums[i] < temp[temp.length - 1]) continue; // è§å®é¡ºåºï¼é¿å
éå¤ç»å |
| | | temp.push(nums[i]); |
| | | backtrack(temp, nums); |
| | | temp.pop(); |
| | | } |
| | | } |
| | | backtrack([], nums); |
| | | return result; |
| | | }, |
| | | tableRowClassName({row, rowIndex}) { |
| | | if (row.state === 0) { |
| | | return ''; |
| | | } |
| | | return 'warning-row'; |
| | | }, |
| | | // selectInsOrderTemplateInfo() { |
| | | // selectInsOrderTemplate({company: this.addObj.company}).then(res => { |
| | | // this.templates = res.data |
| | | // }) |
| | | // }, |
| | | methodChange(val, row) { |
| | | if (val === null || val === '') return |
| | | if (this.sampleList.length > 1) { |
| | | // æä¸¤æ¡æ ·åæ¶ï¼ç¬¬äºæ¡æ ·åä¿¡æ¯åç¬¬ä¸æ¡ä¿æä¸è´ |
| | | this.sampleList.forEach(item => { |
| | | item.standardMethodListId = val |
| | | item.modelNum = row.modelNum |
| | | }) |
| | | } |
| | | this.currentMethod = row |
| | | let obj = this.methods.find(a => a.id == this.currentMethod.standardMethodListId) |
| | | if (obj && obj.code == 'ææ¯è¦æ±') { |
| | | this.isAskOnlyRead = true |
| | | } else { |
| | | this.isAskOnlyRead = false |
| | | } |
| | | this.getProductLoad = true |
| | | let selectTreeList = this.selectTree.split(" - ") |
| | | this.addObj.model&&(selectTreeList[selectTreeList.length - 1] = this.addObj.model) |
| | | selectStandardProductList({ |
| | | model: this.addObj.model?this.addObj.model:row.model, |
| | | modelNum: row.modelNum, |
| | | standardMethodListId: val, |
| | | factory: selectTreeList.join(" - "), |
| | | }).then(res => { |
| | | res.data.forEach(a => { |
| | | a.state = 0 |
| | | }) |
| | | row.insProduct = this.HaveJson(res.data) |
| | | this.getProductLoad = false |
| | | this.productList = row.insProduct |
| | | this.productList0 = JSON.parse(JSON.stringify(this.productList)) |
| | | this.$refs.sampleTable.setCurrentRow(row) |
| | | setTimeout(() => { |
| | | this.productList.forEach(a => { |
| | | if (a.state == 1) this.toggleSelection(a) |
| | | }) |
| | | }, 200) |
| | | }) |
| | | // this.searchTemList() |
| | | }, |
| | | changeModel() { |
| | | this.sampleList.forEach(a => { |
| | | let obj = this.sampleIds.find(b => b == a.id) |
| | | if (obj) { |
| | | a.model = this.model |
| | | } |
| | | }) |
| | | }, |
| | | changeStandardMethodListId() { |
| | | this.sampleList.forEach(a => { |
| | | let obj = this.sampleIds.find(b => b == a.id) |
| | | if (obj) { |
| | | a.standardMethodListId = this.standardMethodListId |
| | | this.methodChange(this.standardMethodListId, a) |
| | | } |
| | | }) |
| | | }, |
| | | methodFocus() { |
| | | this.selectsStandardMethodByFLSSM() |
| | | }, |
| | | handleChangeModel(e) { |
| | | this.productList = [] |
| | | let num = this.selectTree.split('-').length; |
| | | if (num != 5) { |
| | | this.selectTree = this.selectTree + ' - ' + e |
| | | } else { |
| | | let arr = this.selectTree.split('-') |
| | | let arr0 = arr.slice(0, arr.length - 1) |
| | | this.selectTree = arr0.join('-') + '- ' + e |
| | | } |
| | | }, |
| | | // è¦æ±å¼ååæ¶ |
| | | requestChange(e, row,type) { |
| | | //this.currentMethod å½åæ ·åid |
| | | this.sampleList.forEach(item=>{ |
| | | if(item.id == this.currentMethod.id){ |
| | | item.insProduct.forEach(i=>{ |
| | | if(i.id == row.id){ |
| | | i[type] = e |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | }, |
| | | selectStandardMethods() { |
| | | selectStandardMethodEnum().then(res => { |
| | | this.methods = res.data |
| | | }) |
| | | }, |
| | | selectable() { |
| | | if (this.active > 1) { |
| | | return false |
| | | } else { |
| | | return true |
| | | } |
| | | }, |
| | | handleAll(e) { |
| | | if (e.length > 0) { |
| | | this.productList.map(m => { |
| | | if(e.find(a=>a.id == m.id)){ |
| | | m.state = 1 |
| | | } |
| | | return m |
| | | }) |
| | | } else { |
| | | this.productList.map(m => { |
| | | m.state = 0 |
| | | return m |
| | | }) |
| | | } |
| | | this.bsmRow3 = []; |
| | | this.bsm1DiaList = [] |
| | | this.productList.forEach(p => { |
| | | if (p.sectionCopy === undefined && p.section) { |
| | | if (p.section.indexOf('[') > -1) { |
| | | this.$set(p, 'sectionCopy', p.section) |
| | | } |
| | | } |
| | | if (p.ask.includes('[')) { |
| | | this.$set(p, 'askCopy', p.ask) |
| | | } |
| | | if (p.tell.includes('[')) { |
| | | this.$set(p, 'tellCopy', p.tell) |
| | | } |
| | | // if (p.manHour.includes('[')) { |
| | | // this.$set(p, 'manHourCopy', p.manHour) |
| | | // } |
| | | // if (p.price.includes('[')) { |
| | | // this.$set(p, 'priceCopy', p.price) |
| | | // } |
| | | if (p.bsm === '1' && p.sectionCopy !== '' && p.sectionCopy !== null && p.sectionCopy !== undefined && p.state === 1) { |
| | | if (p.sectionCopy.indexOf('[') > -1) { |
| | | p.bsmRow = this.HaveJson(p) |
| | | } |
| | | p.bsm1 = true |
| | | this.bsm1DiaList.push(p) |
| | | this.bsm1DiaAll = true |
| | | } else if (p.bsm === '1' && p.sectionCopy !== '' && p.sectionCopy !== null && p.state === 0) { |
| | | p.bsm1 = false |
| | | } |
| | | }) |
| | | if (e.length > 0) { |
| | | this.sampleList.map(item => { |
| | | if (this.sampleIds.indexOf(item.id) > -1) { |
| | | item.insProduct.map(m => { |
| | | m.state = 1 |
| | | return m; |
| | | }) |
| | | } |
| | | return item |
| | | }) |
| | | } else { |
| | | this.sampleList.map(item => { |
| | | if (this.sampleIds.indexOf(item.id) > -1) { |
| | | item.insProduct.map(m => { |
| | | m.state = 0 |
| | | return m; |
| | | }) |
| | | } |
| | | return item |
| | | }) |
| | | } |
| | | this.changeProductList0() |
| | | this.currentMethod.insProduct = this.productList0 |
| | | this.getProNum() |
| | | this.$nextTick(() => { |
| | | this.$refs.productTable.doLayout() |
| | | }) |
| | | }, |
| | | filterHandler(value, row, column) { |
| | | const property = column['property']; |
| | | return row[property] === value; |
| | | }, |
| | | // å
¨éç¹æ®å¼å¤çæ¡éæ©è¦æ±å¼çåè° |
| | | upBsmAll (item) { |
| | | const i = this.bsm1DiaList.findIndex(obj => obj.id === item.id) |
| | | if (i > -1) { |
| | | // æ¾å°ç¸åºçæ£éªé¡¹èµå¼ |
| | | this.bsm1DiaList[i].bsm1Val = item.bsm1Val |
| | | let sections = this.bsm1DiaList[i].bsmRow.sectionCopy && JSON.parse(this.bsm1DiaList[i].bsmRow.sectionCopy); |
| | | let asks = this.bsm1DiaList[i].bsmRow.askCopy && JSON.parse(this.bsm1DiaList[i].bsmRow.askCopy); |
| | | let tells = this.bsm1DiaList[i].bsmRow.tellCopy && JSON.parse(this.bsm1DiaList[i].bsmRow.tellCopy); |
| | | // let manHours = this.bsm1DiaList[i].bsmRow.manHourCopy && JSON.parse(this.bsm1DiaList[i].bsmRow.manHourCopy); |
| | | // let prices = this.bsm1DiaList[i].bsmRow.priceCopy && JSON.parse(this.bsm1DiaList[i].bsmRow.priceCopy); |
| | | for (var a in sections) { |
| | | if (this.bsm1DiaList[i].bsm1Val === sections[a]) { |
| | | this.productList.forEach(p => { |
| | | // å°éæ©å¥½çè¦æ±å¼èµå¼å°å表é |
| | | if (p.id === this.bsm1DiaList[i].bsmRow.id) { |
| | | p.section = sections[a] |
| | | p.ask = asks[a] |
| | | p.tell = tells[a] |
| | | // p.manHour = manHours[a] |
| | | // p.price = prices[a] |
| | | } |
| | | }) |
| | | break |
| | | } |
| | | } |
| | | } |
| | | this.changeProductList0() |
| | | this.currentMethod.insProduct = this.productList0 |
| | | }, |
| | | save1 () { |
| | | if (this.bsm1DiaList.length > 0) { |
| | | this.bsm1DiaList.forEach(item => { |
| | | if (!item.bsm1Val) { |
| | | throw this.$message.error('ç¹æ®é¡¹ç®å¿
é¡»å¤ç') |
| | | } |
| | | }) |
| | | } |
| | | this.bsm1DiaAll = false |
| | | }, |
| | | beforeClose(done) { |
| | | if (this.bsm1DiaList.length > 0) { |
| | | this.bsm1DiaList.forEach(item => { |
| | | if (!item.bsm1Val) { |
| | | throw this.$message.error('ç¹æ®é¡¹ç®å¿
é¡»å¤ç') |
| | | } |
| | | }) |
| | | } |
| | | done() |
| | | }, |
| | | beforeClose0(done) { |
| | | if (!this.bsm3Val) { |
| | | this.$message.error('RSTå¿
须填å') |
| | | return |
| | | } else { |
| | | if (Array.isArray(this.bsmRow3)) { |
| | | this.bsmRow3.forEach(item => { |
| | | item.rts = this.bsm3Val |
| | | }) |
| | | } else { |
| | | this.bsmRow3.rts = this.bsm3Val |
| | | } |
| | | } |
| | | done() |
| | | }, |
| | | getTotal() { |
| | | this.totalArr = [] |
| | | // this.total = 0; |
| | | this.sampleList.forEach(item => { |
| | | if (item.insProduct && item.insProduct.length > 0) { |
| | | item.insProduct.forEach(a => { |
| | | this.totalArr.push(a) |
| | | }) |
| | | } |
| | | if (item.bushing && item.bushing.length > 0) { |
| | | item.bushing.forEach(a => { |
| | | if (a.fiber && a.fiber.length > 0) { |
| | | a.fiber.forEach(b => { |
| | | if (b.productList && b.productList.length > 0) { |
| | | b.productList.forEach(c => { |
| | | this.totalArr.push(c) |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | if (a.fibers && a.fibers.length > 0) { |
| | | a.fibers.forEach(b => { |
| | | if (b.productList && b.productList.length > 0) { |
| | | b.productList.forEach(c => { |
| | | this.totalArr.push(c) |
| | | }) |
| | | } |
| | | if (b.fiber && b.fiber.length > 0) { |
| | | b.fiber.forEach(c => { |
| | | if (c.productList && c.productList.length > 0) { |
| | | c.productList.forEach(d => { |
| | | this.totalArr.push(d) |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | let mySet = new Set(); |
| | | let arr0 = this.totalArr.filter(item => { |
| | | if (item.state == 1) { |
| | | let num1 = mySet.size |
| | | if (item.manHourGroup === '' || !item.manHourGroup) { |
| | | return true |
| | | } else { |
| | | mySet.add(item.manHourGroup) |
| | | let num2 = mySet.size |
| | | if (num2 > num1) { |
| | | return true |
| | | } else { |
| | | return false |
| | | } |
| | | } |
| | | } |
| | | }) |
| | | // arr0.forEach(item => { |
| | | // this.total += Number(item.price) |
| | | // }) |
| | | |
| | | }, |
| | | goBack () { |
| | | if (this.active == 1) { |
| | | this.$router.go(-1) |
| | | } else { |
| | | this.closeOpenPage() |
| | | } |
| | | }, |
| | | closeOpenPage() { |
| | | this.$router.go(-1) |
| | | this.$tab.closeOpenPage() |
| | | }, |
| | | } |
| | | } |
| | | </script> |
| | | <style scoped> |
| | | .header { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | margin-bottom: 10px; |
| | | } |
| | | >>>.warning-row { |
| | | color: #1890FF; |
| | | } |
| | | .node_i { |
| | | color: orange; |
| | | font-size: 18px; |
| | | } |
| | | </style> |
ÎļþÃû´Ó src/views/business/materialOrder/customsInspection.vue ÐÞ¸Ä |
| | |
| | | <el-select v-show="active==1" v-model="template" placeholder="ä¸å模æ¿" size="small" style="margin-right: 10px;" |
| | | @change="selectInsOrderTemplateByIdList"> |
| | | <el-option v-for="(a, ai) in templates" :key="ai" :label="a.name" :value="a.id"> |
| | | <span style="float: left">{{ a.name }}</span> |
| | | <i class="el-icon-delete" style="float: right; color: #66b1ff; font-size: 16px" |
| | | @click.stop="handleDelete(a)"></i> |
| | | <div style="display: flex; align-items: center; justify-content: space-between;"> |
| | | <span>{{ a.name }}</span> |
| | | <i class="el-icon-delete" |
| | | style="color: #66b1ff; font-size: 16px; cursor: pointer;" |
| | | @click.stop="handleDelete(a)"> |
| | | </i> |
| | | </div> |
| | | </el-option> |
| | | </el-select> |
| | | <el-button v-show="active==1" size="small" @click="templateDia=true"> |
| | |
| | | <el-form ref="addObj" :inline="true" :model="addObj" :rules="addObjRules" label-width="90px"> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="éè´è®¢åå·:"> |
| | | <el-form-item class="addObj-form-item" label="éè´è®¢åå·:" prop="orderNo"> |
| | | <el-input v-model="addObj.orderNo" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="å§æåä½:"> |
| | | <el-form-item class="addObj-form-item" label="å§æåä½:" prop="company"> |
| | | <el-input v-model="addObj.company" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ¶æ¶é´:"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ¶æ¶é´:" prop="receiverDate"> |
| | | <el-date-picker |
| | | v-model="addObj.receiverDate" |
| | | disabled |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="é¶ä»¶å·:"> |
| | | <el-form-item class="addObj-form-item" label="é¶ä»¶å·:" prop="partNo"> |
| | | <el-input v-model="addObj.partNo" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ ·ååç§°:"> |
| | | <el-form-item class="addObj-form-item" label="æ ·ååç§°:" prop="sample"> |
| | | <el-input v-model="addObj.sample" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ ·åæ»æ°:"> |
| | | <el-form-item class="addObj-form-item" label="æ ·åæ»æ°:" prop="qtyArrived"> |
| | | <el-input v-model="addObj.qtyArrived" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ£äºº:"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ£äºº:" prop="declareUser"> |
| | | <el-input v-model="addObj.declareUser" class="addObj-info" clearable disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¹æ¬¡å·:"> |
| | | <el-form-item class="addObj-form-item" label="æ¹æ¬¡å·:" prop="updateBatchNo"> |
| | | <el-input v-model="addObj.updateBatchNo" class="addObj-info" clearable disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="夿³¨:"> |
| | | <el-form-item class="addObj-form-item" label="夿³¨:" prop="remark"> |
| | | <el-input v-model="addObj.remark" :autosize="{ minRows: 2, maxRows: 2}" :disabled="active>1" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </el-form-item> |
| | |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | :show-close="false" :visible.sync="bsm3Dia" |
| | | title="åºé´å¼å¡«å" width="800px"> |
| | | <el-table :data="editTable" height="80vh" style="width: 100%"> |
| | | <el-table :data="editTable" height="80vh" style="width: 100%" :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border> |
| | | <!-- inspectionItemList --> |
| | | <el-table-column label="æ£éªé¡¹" prop="inspectionItemList" width="180"> |
| | | </el-table-column> |
| | |
| | | } from "@/api/business/rawMaterialOrder"; |
| | | |
| | | export default { |
| | | name: "CustomsInspection", |
| | | name: "CustomsInspectionOrder", |
| | | dicts: ['check_type', 'urgency_level'], |
| | | components: {}, |
| | | props: { |
| | |
| | | } |
| | | }, |
| | | watch: { |
| | | sampleList() { |
| | | this.addObj.method = null |
| | | }, |
| | | // sampleList() { |
| | | // this.addObj.method = null |
| | | // this.productList = [] |
| | | // }, |
| | | productList: { |
| | | deep: true, |
| | | handler(val) { |
| | |
| | | this.customsInspection = this.$route.query.customsInspection |
| | | this.getInfo(); |
| | | }, |
| | | getInfo() { |
| | | this.getUserNowList() // è·åå½åç¨æ·ä¿¡æ¯ |
| | | this.selectStandardMethods() // è·åæ£éªæ åä¸ææ¡æ°æ® |
| | | this.getInfo() // è·åæ°æ® |
| | | }, |
| | | // getInfo() { |
| | | // this.getInfo() // è·åæ°æ® |
| | | // }, |
| | | methods: { |
| | | save1 () { |
| | | if (this.bsm1DiaList.length > 0) { |
| | |
| | | }, |
| | | // è·åæ°æ® |
| | | getInfo () { |
| | | this.getUserNowList() // è·åå½åç¨æ·ä¿¡æ¯ |
| | | this.selectStandardMethods() // è·åæ£éªæ åä¸ææ¡æ°æ® |
| | | if (this.active == 2) { |
| | | let orderId = '' |
| | | if (!this.customsInspection.enterOrderId && this.customsInspection.quarterOrderId) { |
copy from src/views/business/materialOrder/customsInspection.vue
copy to src/views/business/materialOrder/customsInspectionView.vue
Îļþ´Ó src/views/business/materialOrder/customsInspection.vue ¸´ÖÆ |
| | |
| | | <el-form ref="addObj" :inline="true" :model="addObj" :rules="addObjRules" label-width="90px"> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="éè´è®¢åå·:"> |
| | | <el-form-item class="addObj-form-item" label="éè´è®¢åå·:" prop="orderNo"> |
| | | <el-input v-model="addObj.orderNo" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="å§æåä½:"> |
| | | <el-form-item class="addObj-form-item" label="å§æåä½:" prop="company"> |
| | | <el-input v-model="addObj.company" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ¶æ¶é´:"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ¶æ¶é´:" prop="receiverDate"> |
| | | <el-date-picker |
| | | v-model="addObj.receiverDate" |
| | | disabled |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="é¶ä»¶å·:"> |
| | | <el-form-item class="addObj-form-item" label="é¶ä»¶å·:" prop="partNo"> |
| | | <el-input v-model="addObj.partNo" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ ·ååç§°:"> |
| | | <el-form-item class="addObj-form-item" label="æ ·ååç§°:" prop="sample"> |
| | | <el-input v-model="addObj.sample" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ ·åæ»æ°:"> |
| | | <el-form-item class="addObj-form-item" label="æ ·åæ»æ°:" prop="qtyArrived"> |
| | | <el-input v-model="addObj.qtyArrived" class="addObj-info" clearable disabled placeholder="" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ£äºº:"> |
| | | <el-form-item class="addObj-form-item" label="æ¥æ£äºº:" prop="declareUser"> |
| | | <el-input v-model="addObj.declareUser" class="addObj-info" clearable disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="æ¹æ¬¡å·:"> |
| | | <el-form-item class="addObj-form-item" label="æ¹æ¬¡å·:" prop="updateBatchNo"> |
| | | <el-input v-model="addObj.updateBatchNo" class="addObj-info" clearable disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item class="addObj-form-item" label="夿³¨:"> |
| | | <el-form-item class="addObj-form-item" label="夿³¨:" prop="remark"> |
| | | <el-input v-model="addObj.remark" :autosize="{ minRows: 2, maxRows: 2}" :disabled="active>1" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </el-form-item> |
| | |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border |
| | | :show-close="false" :visible.sync="bsm3Dia" |
| | | title="åºé´å¼å¡«å" width="800px"> |
| | | <el-table :data="editTable" height="80vh" style="width: 100%"> |
| | | <el-table :data="editTable" height="80vh" style="width: 100%" :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border> |
| | | <!-- inspectionItemList --> |
| | | <el-table-column label="æ£éªé¡¹" prop="inspectionItemList" width="180"> |
| | | </el-table-column> |
| | |
| | | } from "@/api/business/rawMaterialOrder"; |
| | | |
| | | export default { |
| | | name: "CustomsInspection", |
| | | name: "CustomsInspectionView", |
| | | dicts: ['check_type', 'urgency_level'], |
| | | components: {}, |
| | | props: { |
| | |
| | | watch: { |
| | | sampleList() { |
| | | this.addObj.method = null |
| | | this.productList = [] |
| | | }, |
| | | productList: { |
| | | deep: true, |
| | |
| | | this.customsInspection = this.$route.query.customsInspection |
| | | this.getInfo(); |
| | | }, |
| | | getInfo() { |
| | | this.getUserNowList() // è·åå½åç¨æ·ä¿¡æ¯ |
| | | this.selectStandardMethods() // è·åæ£éªæ åä¸ææ¡æ°æ® |
| | | this.getInfo() // è·åæ°æ® |
| | | }, |
| | | // getInfo() { |
| | | // this.getInfo() // è·åæ°æ® |
| | | // }, |
| | | methods: { |
| | | save1 () { |
| | | if (this.bsm1DiaList.length > 0) { |
| | |
| | | }, |
| | | // è·åæ°æ® |
| | | getInfo () { |
| | | this.getUserNowList() // è·åå½åç¨æ·ä¿¡æ¯ |
| | | this.selectStandardMethods() // è·åæ£éªæ åä¸ææ¡æ°æ® |
| | | if (this.active == 2) { |
| | | let orderId = '' |
| | | if (!this.customsInspection.enterOrderId && this.customsInspection.quarterOrderId) { |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="ä¸åæ¶é´" prop="date" v-if="(tabIndex === 2 || tabIndex === 3 || tabIndex === 4) && more"> |
| | | <el-date-picker v-model="entity.date" end-placeholder="ç»ææ¥æ" format="yyyy-MM-dd" placeholder="éæ©æ¥æ" |
| | | <el-date-picker v-model="entity.date" end-placeholder="ç»ææ¥æ" format="yyyy-MM-dd" placeholder="éæ©æ¥æ" @change="goSearch" |
| | | range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" type="daterange" value-format="yyyy-MM-dd"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | <div class="table-tab"> |
| | | <div> |
| | | <ul class="tab"> |
| | | <li :class="{ active: tabIndex === 0 }" @click="handleTab(0)">å¾
ä¸å</li> |
| | | <li :class="{ active: tabIndex === 1 }" @click="handleTab(1)">æ£éªä¸</li> |
| | | <li :class="{ active: tabIndex === 2 }" @click="handleTab(2)">å·²æ£éª</li> |
| | | <li :class="{ active: tabIndex === 4 }" @click="handleTab(4)">å£åº¦æ£éª</li> |
| | | <li :class="{ active: tabIndex === 0 }" v-if="checkPermi(['get:raw:await'])" @click="handleTab(0)">å¾
ä¸å</li> |
| | | <li :class="{ active: tabIndex === 1 }" v-if="checkPermi(['get:raw:testing'])" @click="handleTab(1)">æ£éªä¸</li> |
| | | <li :class="{ active: tabIndex === 2 }" v-if="checkPermi(['get:raw:check'])" @click="handleTab(2)">å·²æ£éª</li> |
| | | <li :class="{ active: tabIndex === 4 }" v-if="checkPermi(['get:raw:quarterCheck'])" @click="handleTab(4)">å£åº¦æ£éª</li> |
| | | <li :class="{ active: tabIndex === 3 }" v-if="checkPermi(['get:Ifs:ByAll'])" @click="handleTab(3)">å
¨é¨</li> |
| | | </ul> |
| | | </div> |
| | | <div> |
| | | <el-button v-show="tabIndex === 3 || tabIndex === 2" :loading="outLoading" size="small" type="primary" |
| | | <el-button v-show="tabIndex === 3" :loading="outLoading" size="small" type="primary" |
| | | @click="handleOut">导åº</el-button> |
| | | <el-button v-if="tabIndex === 0" size="small" type="primary" @click="copper">éææä¸å</el-button> |
| | | <el-button v-if="tabIndex !== 0" size="small" type="primary" @click="openPrint">æ ç¾æå°</el-button> |
| | |
| | | <!--å¾
ä¸å--> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="column" v-if="tabIndex === 0" @pagination="pagination" |
| | | ref="tableData" |
| | | :rowClassName="changeRowClass" :height="'calc(100vh - 290px)'" key="tableData" :page="page" |
| | | :tableLoading="tableLoading"></lims-table> |
| | | ref="tableData" :rowClassName="changeRowClass" :height="'calc(100vh - 290px)'" |
| | | key="tableData" :page="page" :tableLoading="tableLoading"></lims-table> |
| | | </div> |
| | | <!--æ£éªä¸--> |
| | | <div class="table"> |
| | |
| | | disabled: (row) => { |
| | | return row.isQuarter == 0 |
| | | }, |
| | | showHide: (row) => { |
| | | return this.checkPermi([ |
| | | "get:raw:check:operation", |
| | | ]); |
| | | }, |
| | | }, |
| | | { |
| | | name: 'æ°æ®æ¥ç', |
| | |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.handleFileLook(row); |
| | | }, |
| | | } |
| | | }, |
| | | { |
| | | name: 'æ¥åä¸è½½', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.download(row); |
| | | }, |
| | | } |
| | | }, |
| | | { |
| | | name: 'åå§è®°å½', |
| | |
| | | disabled: (row) => { |
| | | return row.inspectStatus != 2 |
| | | }, |
| | | showHide: (row) => { |
| | | return this.checkPermi([ |
| | | "get:raw:check:operation", |
| | | ]); |
| | | }, |
| | | }, |
| | | { |
| | | name: 'å£åº¦æ¤é', |
| | |
| | | }, |
| | | disabled: (row) => { |
| | | return row.quarterOrderId == null || row.quarterReportId != null |
| | | }, |
| | | showHide: (row) => { |
| | | return this.checkPermi([ |
| | | "get:raw:check:operation", |
| | | ]); |
| | | }, |
| | | }, |
| | | ] |
| | |
| | | } |
| | | ], |
| | | more: false, |
| | | tabIndex: 0, |
| | | tabIndex: '', |
| | | multipleSelection: [], |
| | | active: 0, //1ï¼ä¸åï¼2ï¼æ¥ç |
| | | orderType: 0, //0ï¼åææä¸åï¼1ï¼å£åº¦æ£éªä¸å |
| | |
| | | ...mapGetters(['nickName']) |
| | | }, |
| | | mounted() { |
| | | if (this.checkPermi(['get:raw:await'])) { |
| | | this.tabIndex = 0 |
| | | } else { |
| | | this.tabIndex = 2 |
| | | } |
| | | this.refreshTable() |
| | | }, |
| | | activated () { |
| | |
| | | let inspectorList = [] |
| | | inspectorList.push(this.nickName) |
| | | this.InspectInfoDialog = false |
| | | this.$router.push({ |
| | | path: "/inspectionTask/inspection", |
| | | query: { |
| | | sonLaboratory: 'åææ', |
| | | state: 3, |
| | | typeSource: this.insInfo.typeSource, |
| | | orderId: this.insInfo.enterOrderId, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | if (this.checkPermi(['business:inspectionView'])) { |
| | | this.$router.push({ |
| | | name: "InspectionView", |
| | | query: { |
| | | sonLaboratory: 'åææ', |
| | | state: 3, |
| | | typeSource: this.insInfo.typeSource, |
| | | orderId: this.insInfo.enterOrderId, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | } else { |
| | | this.$router.push({ |
| | | path: "/inspectionTask/inspection", |
| | | query: { |
| | | sonLaboratory: 'åææ', |
| | | state: 3, |
| | | typeSource: this.insInfo.typeSource, |
| | | orderId: this.insInfo.enterOrderId, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | } |
| | | }, |
| | | viewInsInfo1() { |
| | | let inspectorList = [] |
| | | inspectorList.push(this.nickName) |
| | | this.InspectInfoDialog = false |
| | | this.$router.push({ |
| | | path: "/inspectionTask/inspection", |
| | | query: { |
| | | sonLaboratory: 'åææ', |
| | | state: 3, |
| | | typeSource: this.insInfo.typeSource, |
| | | orderId: this.insInfo.quarterOrderId, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | if (this.checkPermi(['business:inspectionView'])) { |
| | | this.$router.push({ |
| | | name: "InspectionView", |
| | | query: { |
| | | sonLaboratory: 'åææ', |
| | | state: 3, |
| | | typeSource: this.insInfo.typeSource, |
| | | orderId: this.insInfo.quarterOrderId, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | } else { |
| | | this.$router.push({ |
| | | path: "/inspectionTask/inspection", |
| | | query: { |
| | | sonLaboratory: 'åææ', |
| | | state: 3, |
| | | typeSource: this.insInfo.typeSource, |
| | | orderId: this.insInfo.quarterOrderId, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | } |
| | | }, |
| | | goback() { |
| | | this.state = 0 |
| | |
| | | }, |
| | | // éææä¸å |
| | | copper() { |
| | | this.$router.push("/materialOrder/copperOrder"); |
| | | this.$router.push({ path: "/materialOrder/copperOrder", query: { active: 1 } }); |
| | | }, |
| | | // æå¼æ ç¾æå°å¼¹æ¡ |
| | |
| | | }, |
| | | // ä¸å |
| | | playOrder(row) { |
| | | this.$router.push({ path: "/materialOrder/customsInspection", query: { orderType: 0, customsInspection: row, active: 1 } }); |
| | | this.$router.push({ path: "/materialOrder/customsInspectionOrder", query: { orderType: 0, customsInspection: row, active: 1 } }); |
| | | }, |
| | | // å£åº¦æ£éªä¸å |
| | | playOrderSec(row) { |
| | | this.$router.push({ path: "/materialOrder/customsInspection", query: { orderType: 1, customsInspection: row, active: 1 } }); |
| | | this.$router.push({ path: "/materialOrder/customsInspectionOrder", query: { orderType: 1, customsInspection: row, active: 1 } }); |
| | | }, |
| | | // ç¹å»æ ·ååç§°æ¥ç详æ
|
| | | selectAllByOne(row) { |
| | | if (row.isCopper == 1) { |
| | | this.currentId = row.enterOrderId |
| | | this.$router.push({ path: "/materialOrder/copperOrder", query: { customsInspection: row, active: 2, currentId: this.currentId } }); |
| | | this.$router.push({ path: "/materialOrder/CopperView", query: { customsInspection: row, active: 2, currentId: this.currentId } }); |
| | | } else { |
| | | this.currentId = row.insOrderId |
| | | this.$router.push({ path: "/materialOrder/customsInspection", query: { customsInspection: row, active: 2, currentId: this.currentId } }); |
| | | this.$router.push({ path: "/materialOrder/customsInspectionView", query: { customsInspection: row, active: 2, currentId: this.currentId } }); |
| | | } |
| | | }, |
| | | // æå¼å
æ£å¼¹æ¡ |
| | |
| | | }, |
| | | // å¯¼åº |
| | | handleOut() { |
| | | let entity = this.tabIndex === 3 ? { ...this.entity, isInspect: 2 } : { ...this.entity, state: 2, orderState: 4, } |
| | | delete entity.orderBy |
| | | this.outLoading = true |
| | | rawAllExport({ entity: entity }).then(res => { |
| | | let params = {} |
| | | if (this.multipleSelection.length > 0) { |
| | | params.ids = this.multipleSelection.map(item => item.id).join(','); |
| | | } else { |
| | | params = {...this.entity} |
| | | } |
| | | rawAllExport(params).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | this.$download.saveAs(blob, 'åæææ£æµä¿¡æ¯å¯¼åº.xlsx'); |
| | |
| | | // 忢ä¸åtabè¡¨æ ¼ |
| | | handleTab(m) { |
| | | this.tabIndex = m; |
| | | this.multipleSelection = [] |
| | | this.refreshTable() |
| | | }, |
| | | // è¡¨æ ¼éæ©æ¹æ³ |
| | |
| | | methods: { |
| | | getInfo (id) { |
| | | console.log('id----', id) |
| | | this.$axios.get(this.$api.rawMaterialOrder.getIndustryChain + '?id=' + id).then(res => { |
| | | if (res.code === 200 && res.data !== null) { |
| | | this.infoLIst = JSON.parse(res.data) |
| | | console.log('this.infoLIst----', this.infoLIst) |
| | | } |
| | | }) |
| | | } |
| | | }, |
| | | } |
| | |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æ£éªæ å" min-width="100" prop="standardMethodListId"> |
| | | <el-table-column align="center" label="æ£éªæ å" min-width="100" prop="standardMethodName"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.standardMethodListId" clearable disabled placeholder="ä¸å¡«ååç³»ç»èªå¨çæ" |
| | | <el-input v-model="scope.row.standardMethodName" clearable disabled placeholder="ä¸å¡«ååç³»ç»èªå¨çæ" |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
copy from src/views/business/productOrder/components/add.vue
copy to src/views/business/productOrder/components/addOrder.vue
Îļþ´Ó src/views/business/productOrder/components/add.vue ¸´ÖÆ |
| | |
| | | <el-select v-show="active==1" v-model="template" placeholder="ä¸å模æ¿" size="small" |
| | | @change="selectInsOrderTemplateById"> |
| | | <el-option v-for="(a, ai) in templates" :key="ai" :label="a.name" :value="a.id"> |
| | | <span style="float: left">{{ a.name }}</span> |
| | | <i class="el-icon-delete" style="float: right; color: #66b1ff; font-size: 16px" |
| | | @click.stop="handleDelete(a)"></i> |
| | | <div style="display: flex; align-items: center; justify-content: space-between;"> |
| | | <span>{{ a.name }}</span> |
| | | <i class="el-icon-delete" |
| | | style="color: #66b1ff; font-size: 16px; cursor: pointer;" |
| | | @click.stop="handleDelete(a)"> |
| | | </i> |
| | | </div> |
| | | </el-option> |
| | | </el-select> |
| | | <el-button v-show="active==1" size="small" @click="templateDia=true"> |
| | |
| | | <el-form ref="addObj" :inline="true" :model="addObj" :rules="addObjRules" label-width="108px" label-position="right"> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æç¼å·:"> |
| | | <el-form-item label="å§æç¼å·:" prop="entrustCode"> |
| | | <el-input v-model="addObj.entrustCode" clearable disabled placeholder="ç³»ç»çæ" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å¶å人:"> |
| | | <el-form-item label="å¶å人:" prop="custom"> |
| | | <el-input v-model="addObj.custom" disabled size="small" clearable></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ¥ååéæ¹å¼:"> |
| | | <el-form-item label="æ¥ååéæ¹å¼:" prop="send"> |
| | | <el-radio-group v-model="addObj.send" :disabled="active>1&&tabIndex!=4" size="mini"> |
| | | <el-radio :label="1" border style="margin-right: 0">èªå</el-radio> |
| | | <el-radio :label="0" border>å
¶ä»</el-radio> |
| | |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ ·åå¤çæ¹å¼:"> |
| | | <el-form-item label="æ ·åå¤çæ¹å¼:" prop="processing"> |
| | | <el-radio-group v-model="addObj.processing" :disabled="active>1&&tabIndex!=4" size="mini" style="display: flex; flex-direction: column;"> |
| | | <el-radio :label="0" border style="margin-right: 0">å§æåä½åå</el-radio> |
| | | <el-radio :label="1" border>å®éªå®¤å¤ç</el-radio> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ¯å¦çæ ·:"> |
| | | <el-form-item label="æ¯å¦çæ ·:" prop="isLeave"> |
| | | <el-radio-group v-model="addObj.isLeave" border :disabled="active>1&&tabIndex!=4" size="mini"> |
| | | <el-radio :label="0" border style="margin-right: 0">ä¸çæ ·</el-radio> |
| | | <el-radio :label="1" border>çæ ·</el-radio> |
| | |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æäºº:"> |
| | | <el-form-item label="å§æäºº:" prop="prepareUser"> |
| | | <el-input v-model="addObj.prepareUser" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æäººè±æ:"> |
| | | <el-form-item label="å§æäººè±æ:" prop="prepareUserEn"> |
| | | <el-input v-model="addObj.prepareUserEn" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="夿³¨:"> |
| | | <el-form-item label="夿³¨:" prop="remark"> |
| | | <el-input v-model="addObj.remark" :autosize="{ minRows: 2, maxRows: 2}" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small" style="width: 100%" type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="夿³¨è±æ:"> |
| | | <el-form-item label="夿³¨è±æ:" prop="remarkEn"> |
| | | <el-input v-model="addObj.remarkEn" :autosize="{ minRows: 2, maxRows: 2}" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </el-form-item> |
| | |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ ·ååç§°:"> |
| | | <el-form-item label="æ ·ååç§°:" prop="sampleView"> |
| | | <el-input v-model="addObj.sampleView" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ ·ååç§°è±æ:"> |
| | | <el-form-item label="æ ·ååç§°è±æ:" prop="sampleViewEn"> |
| | | <el-input v-model="addObj.sampleViewEn" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æäººå·¥å·:"> |
| | | <el-form-item label="å§æäººå·¥å·:" prop="prepareCode"> |
| | | <el-input v-model="addObj.prepareCode" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | |
| | | size="small" type="textarea" |
| | | @change="e=>requestChange(e,scope.row,'radius')"> |
| | | </el-input> |
| | | <!-- <el-select v-else-if="scope.row.inspectionItem.includes('髿¸©ååè¯éª') && (active==1||tabIndex==4)" v-model="scope.row.radius" clearable--> |
| | | <!-- placeholder="æ¡ä»¶"--> |
| | | <!-- size="small" @change="e=>requestChange(e,scope.row,'radius')">--> |
| | | <!-- <el-option v-for="(a,i) in JSON.parse(scope.row.radiusList)" :key="i" :label="a" :value="a"></el-option>--> |
| | | <!-- </el-select>--> |
| | | <span v-else>{{scope.row.radius}}</span> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | </el-table-column> |
| | | <el-table-column label="计éåä½" prop="unit" show-overflow-tooltip width="100"></el-table-column> |
| | | <el-table-column label="åä»·" prop="price" show-overflow-tooltip width="100"></el-table-column> |
| | | <!-- <el-table-column prop="manDay" label="é¢è®¡æ¶é´(天)" width="120" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="manHour" label="å·¥æ¶ç³»æ°" width="100" show-overflow-tooltip></el-table-column> --> |
| | | <!-- <el-table-column prop="deviceGroup" label="设å¤ç»" width="120" show-overflow-tooltip></el-table-column> --> |
| | | <el-table-column label="åºé´" min-width="120" prop="section" show-overflow-tooltip></el-table-column> |
| | | <el-table-column :filter-method="filterHandler" :filters="filters" label="åå®éªå®¤" min-width="130" prop="sonLaboratory" |
| | | show-overflow-tooltip></el-table-column> |
| | | <el-table-column v-if="isSpecial&&active==1" |
| | | fixed="right" |
| | | label="æä½" |
| | | width="100"> |
| | | <el-table-column v-if="isSpecial&&active==1" label="æä½" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-button v-if="!scope.row.repetitionTag" size="small" type="text" @click="addProductList(productList,scope.row,scope.$index)">æå
¥è¡</el-button> |
| | | <el-button v-if="!!scope.row.repetitionTag&&scope.row.delete" size="small" type="text" @click="deleteProductList(scope.$index,productList)">å é¤</el-button> |
| | |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'Add', |
| | | name: 'AddOrder', |
| | | components: { |
| | | limsTable, |
| | | cableConfig, |
| | | AuxiliaryWireCore |
| | | }, |
| | | computed:{ |
| | | ...mapGetters(["nickName"]), |
| | | ...mapGetters(["nickName", 'nameEn', 'userName']), |
| | | }, |
| | | dicts: ['check_type1', 'urgency_level', 'form_type', 'sample_status_list'], |
| | | data() { |
| | |
| | | } |
| | | }, |
| | | watch: { |
| | | sampleList() { |
| | | this.addObj.method = null |
| | | this.productList = [] |
| | | }, |
| | | // sampleList() { |
| | | // this.addObj.method = null |
| | | // this.productList = [] |
| | | // }, |
| | | productList: { |
| | | deep: true, |
| | | handler(val) { |
| | |
| | | this.active = this.$route.query.active |
| | | this.tabIndex = this.$route.query.tabIndex |
| | | this.currentId = this.$route.query.currentId |
| | | this.getUserNowData() |
| | | this.getInfo() |
| | | if(this.tabIndex==4&&this.active==2){ |
| | | this.isSpecial = true |
| | | }else{ |
| | | this.isSpecial = false |
| | | } |
| | | }, |
| | | activated() { |
| | | this.active = this.$route.query.active |
| | |
| | | }, |
| | | methods: { |
| | | getInfo() { |
| | | this.getUserNowData() |
| | | this.selectStandardTreeList() |
| | | this.getAuthorizedPerson(); |
| | | this.selectStandardMethods() |
| | | this.getPrepareUser() // å¤å¶å½åè´¦å·äººä¸ºå§æäºº |
| | | if (this.active != 1) { |
| | | // æ¥ç/å®¡æ ¸æµç¨ |
| | | // è¯·æ±æ¥å£ï¼åæ¾æ°æ® |
| | |
| | | }) |
| | | }) |
| | | } |
| | | if(this.tabIndex==4&&this.active==2){ |
| | | this.isSpecial = true |
| | | }else{ |
| | | this.isSpecial = false |
| | | } |
| | | }, |
| | | getPrepareUser () { |
| | | // this.addObj.prepareUser = JSON.parse(localStorage.getItem("user")).name; |
| | | // this.addObj.prepareUserEn = JSON.parse(localStorage.getItem("user")).nameEn |
| | | // this.addObj.prepareCode = JSON.parse(localStorage.getItem("user")).account |
| | | |
| | | }, |
| | | // ç¼è¾è¦æ±å¼è¡¨æ ¼ |
| | | editSpecial () { |
| | |
| | | sampleList.forEach(a => { |
| | | if (a.insProduct.length > 0) { |
| | | a.insProduct.forEach(c => { |
| | | delete c.id |
| | | if (this.tabIndex != 4) { |
| | | delete c.id |
| | | } |
| | | }) |
| | | } |
| | | if (a.endModels) { |
| | |
| | | sampleList.forEach(a => { |
| | | if (a.insProduct.length > 0) { |
| | | a.insProduct.forEach(c => { |
| | | delete c.id |
| | | if (this.tabIndex != 4) { |
| | | delete c.id |
| | | } |
| | | }) |
| | | } |
| | | if (a.endModels) { |
| | |
| | | } |
| | | }, |
| | | saveMethod(sampleList){ |
| | | console.log('sampleList----', sampleList) |
| | | this.saveLoad = true |
| | | if (this.addObj.quarterItemId) { |
| | | this.addObj.quarterItemId = this.addObj.quarterItemId[1] |
| | | } |
| | | if(this.tabIndex==4&&this.active==2){ |
| | | if (this.addObj.createTime) { |
| | | delete this.addObj.createTime |
| | | } |
| | | // éååæäº¤ |
| | | updateInsOrder({insOrder: this.addObj, sampleList: sampleList}).then(res => { |
| | | updateInsOrder({insOrder: this.addObj, sampleProduct: sampleList}).then(res => { |
| | | this.saveLoad = false |
| | | this.$message.success('å·²æäº¤') |
| | | this.bsm3Dia = false; |
| | |
| | | }) |
| | | }, |
| | | getUserNowData() { |
| | | this.addObj.prepareUser = this.nickName |
| | | this.addObj.prepareUserEn = this.nameEn |
| | | this.addObj.prepareCode = this.userName |
| | | getUserNow().then(res => { |
| | | let selects = res.data |
| | | if (selects == null) return |
| | |
| | | if (node.data.code === '[3]') { |
| | | this.sampleViewEn = val.sampleTypeEn |
| | | } else if (node.data.code === '[4]') { |
| | | console.log('node.data---', node.data) |
| | | if (node.data.children!==null && node.data.children.length>0) { |
| | | this.sampleViewEn = val.sampleEn |
| | | } |
| | |
| | | }, |
| | | tableRowClassName({row, rowIndex}) { |
| | | if (row.state == 1) { |
| | | console.log('row.state---', row.state) |
| | | return 'warning-row'; |
| | | } else { |
| | | return ''; |
| | |
| | | >>>.warning-row { |
| | | color: #1890FF; |
| | | } |
| | | .node_i { |
| | | color: orange; |
| | | font-size: 18px; |
| | | } |
| | | </style> |
ÎļþÃû´Ó src/views/business/productOrder/components/add.vue ÐÞ¸Ä |
| | |
| | | <el-form ref="addObj" :inline="true" :model="addObj" :rules="addObjRules" label-width="108px" label-position="right"> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æç¼å·:"> |
| | | <el-form-item label="å§æç¼å·:" prop="entrustCode"> |
| | | <el-input v-model="addObj.entrustCode" clearable disabled placeholder="ç³»ç»çæ" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å¶å人:"> |
| | | <el-form-item label="å¶å人:" prop="custom"> |
| | | <el-input v-model="addObj.custom" disabled size="small" clearable></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ¥ååéæ¹å¼:"> |
| | | <el-form-item label="æ¥ååéæ¹å¼:" prop="send"> |
| | | <el-radio-group v-model="addObj.send" :disabled="active>1&&tabIndex!=4" size="mini"> |
| | | <el-radio :label="1" border style="margin-right: 0">èªå</el-radio> |
| | | <el-radio :label="0" border>å
¶ä»</el-radio> |
| | |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ ·åå¤çæ¹å¼:"> |
| | | <el-form-item label="æ ·åå¤çæ¹å¼:" prop="processing"> |
| | | <el-radio-group v-model="addObj.processing" :disabled="active>1&&tabIndex!=4" size="mini" style="display: flex; flex-direction: column;"> |
| | | <el-radio :label="0" border style="margin-right: 0">å§æåä½åå</el-radio> |
| | | <el-radio :label="1" border>å®éªå®¤å¤ç</el-radio> |
| | |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ¯å¦çæ ·:"> |
| | | <el-form-item label="æ¯å¦çæ ·:" prop="isLeave"> |
| | | <el-radio-group v-model="addObj.isLeave" border :disabled="active>1&&tabIndex!=4" size="mini"> |
| | | <el-radio :label="0" border style="margin-right: 0">ä¸çæ ·</el-radio> |
| | | <el-radio :label="1" border>çæ ·</el-radio> |
| | |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æäºº:"> |
| | | <el-form-item label="å§æäºº:" prop="prepareUser"> |
| | | <el-input v-model="addObj.prepareUser" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æäººè±æ:"> |
| | | <el-form-item label="å§æäººè±æ:" prop="prepareUserEn"> |
| | | <el-input v-model="addObj.prepareUserEn" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="夿³¨:"> |
| | | <el-form-item label="夿³¨:" prop="remark"> |
| | | <el-input v-model="addObj.remark" :autosize="{ minRows: 2, maxRows: 2}" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small" style="width: 100%" type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="夿³¨è±æ:"> |
| | | <el-form-item label="夿³¨è±æ:" prop="remarkEn"> |
| | | <el-input v-model="addObj.remarkEn" :autosize="{ minRows: 2, maxRows: 2}" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small" type="textarea"></el-input> |
| | | </el-form-item> |
| | |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ ·ååç§°:"> |
| | | <el-form-item label="æ ·ååç§°:" prop="sampleView"> |
| | | <el-input v-model="addObj.sampleView" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="æ ·ååç§°è±æ:"> |
| | | <el-form-item label="æ ·ååç§°è±æ:" prop="sampleViewEn"> |
| | | <el-input v-model="addObj.sampleViewEn" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | <el-form-item label="å§æäººå·¥å·:"> |
| | | <el-form-item label="å§æäººå·¥å·:" prop="prepareCode"> |
| | | <el-input v-model="addObj.prepareCode" :disabled="active>1&&tabIndex!=4" :placeholder="active>1 ? '' : '请è¾å
¥'" clearable |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | |
| | | size="small" type="textarea" |
| | | @change="e=>requestChange(e,scope.row,'radius')"> |
| | | </el-input> |
| | | <!-- <el-select v-else-if="scope.row.inspectionItem.includes('髿¸©ååè¯éª') && (active==1||tabIndex==4)" v-model="scope.row.radius" clearable--> |
| | | <!-- placeholder="æ¡ä»¶"--> |
| | | <!-- size="small" @change="e=>requestChange(e,scope.row,'radius')">--> |
| | | <!-- <el-option v-for="(a,i) in JSON.parse(scope.row.radiusList)" :key="i" :label="a" :value="a"></el-option>--> |
| | | <!-- </el-select>--> |
| | | <span v-else>{{scope.row.radius}}</span> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | </el-table-column> |
| | | <el-table-column label="计éåä½" prop="unit" show-overflow-tooltip width="100"></el-table-column> |
| | | <el-table-column label="åä»·" prop="price" show-overflow-tooltip width="100"></el-table-column> |
| | | <!-- <el-table-column prop="manDay" label="é¢è®¡æ¶é´(天)" width="120" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="manHour" label="å·¥æ¶ç³»æ°" width="100" show-overflow-tooltip></el-table-column> --> |
| | | <!-- <el-table-column prop="deviceGroup" label="设å¤ç»" width="120" show-overflow-tooltip></el-table-column> --> |
| | | <el-table-column label="åºé´" min-width="120" prop="section" show-overflow-tooltip></el-table-column> |
| | | <el-table-column :filter-method="filterHandler" :filters="filters" label="åå®éªå®¤" min-width="130" prop="sonLaboratory" |
| | | show-overflow-tooltip></el-table-column> |
| | | <el-table-column v-if="isSpecial&&active==1" |
| | | fixed="right" |
| | | label="æä½" |
| | | width="100"> |
| | | <el-table-column v-if="isSpecial&&active==1" label="æä½" width="100"> |
| | | <template slot-scope="scope"> |
| | | <el-button v-if="!scope.row.repetitionTag" size="small" type="text" @click="addProductList(productList,scope.row,scope.$index)">æå
¥è¡</el-button> |
| | | <el-button v-if="!!scope.row.repetitionTag&&scope.row.delete" size="small" type="text" @click="deleteProductList(scope.$index,productList)">å é¤</el-button> |
| | |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | name: 'Add', |
| | | name: 'AddView', |
| | | components: { |
| | | limsTable, |
| | | cableConfig, |
| | |
| | | }, |
| | | methods: { |
| | | getInfo() { |
| | | this.getUserNowData() |
| | | this.selectStandardTreeList() |
| | | this.getAuthorizedPerson(); |
| | | this.selectStandardMethods() |
| | |
| | | sampleList.forEach(a => { |
| | | if (a.insProduct.length > 0) { |
| | | a.insProduct.forEach(c => { |
| | | delete c.id |
| | | if (this.tabIndex != 4) { |
| | | delete c.id |
| | | } |
| | | }) |
| | | } |
| | | if (a.endModels) { |
| | |
| | | sampleList.forEach(a => { |
| | | if (a.insProduct.length > 0) { |
| | | a.insProduct.forEach(c => { |
| | | delete c.id |
| | | if (this.tabIndex != 4) { |
| | | delete c.id |
| | | } |
| | | }) |
| | | } |
| | | if (a.endModels) { |
| | |
| | | } |
| | | }, |
| | | saveMethod(sampleList){ |
| | | console.log('sampleList----', sampleList) |
| | | this.saveLoad = true |
| | | if (this.addObj.quarterItemId) { |
| | | this.addObj.quarterItemId = this.addObj.quarterItemId[1] |
| | | } |
| | | if(this.tabIndex==4&&this.active==2){ |
| | | if (this.addObj.createTime) { |
| | | delete this.addObj.createTime |
| | | } |
| | | // éååæäº¤ |
| | | updateInsOrder({insOrder: this.addObj, sampleList: sampleList}).then(res => { |
| | | updateInsOrder({insOrder: this.addObj, sampleProduct: sampleList}).then(res => { |
| | | this.saveLoad = false |
| | | this.$message.success('å·²æäº¤') |
| | | this.bsm3Dia = false; |
| | |
| | | if (node.data.code === '[3]') { |
| | | this.sampleViewEn = val.sampleTypeEn |
| | | } else if (node.data.code === '[4]') { |
| | | console.log('node.data---', node.data) |
| | | if (node.data.children!==null && node.data.children.length>0) { |
| | | this.sampleViewEn = val.sampleEn |
| | | } |
| | |
| | | }, |
| | | tableRowClassName({row, rowIndex}) { |
| | | if (row.state == 1) { |
| | | console.log('row.state---', row.state) |
| | | return 'warning-row'; |
| | | } else { |
| | | return ''; |
| | |
| | | >>>.warning-row { |
| | | color: #1890FF; |
| | | } |
| | | .node_i { |
| | | color: orange; |
| | | font-size: 18px; |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <div> |
| | | <div class="search_form"> |
| | | <div v-if="currentTab=='ç»ç¼'"> |
| | | <div v-if="currentTab=='ç»ç¼'" style="display: flex"> |
| | | <el-radio-group v-model="currentTab" size="small" style="margin-right: 20px;" @input="changeTab"> |
| | | <el-radio-button label="ç»ç¼">ç» ç¼</el-radio-button> |
| | | </el-radio-group> |
| | |
| | | }).then(res => { |
| | | if (res.code === 200 && res.data.length > 0) { |
| | | res.data.forEach(item => { |
| | | console.log('item---', item) |
| | | item.sendTime = item.sendTime && item.sendTime.substring(0, 10) |
| | | item.sampleNumber = item.qtyArrived + item.buyUnitMeas |
| | | this.$set(item, 'barcode', item.entrustCode) |
| | |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·ååç§°" prop="sampleName"> |
| | | <el-input v-model="entity.partNo" clearable placeholder="请è¾å
¥" size="small" |
| | | <el-input v-model="entity.sampleName" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·ååå·" prop="sampleModel"> |
| | |
| | | </el-form-item> |
| | | <el-form-item label="ä¸åæ¶é´" prop="createTime" v-if="more"> |
| | | <el-date-picker v-model="entity.createTime" clearable format="yyyy-MM-dd" placeholder="éæ©æ¥æ" size="small" |
| | | @change="refreshTable" |
| | | style="width:100%" type="date" value-format="yyyy-MM-dd HH:mm:ss"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | <el-form-item> |
| | | <el-button :icon="!more ? 'el-icon-arrow-down' : 'el-icon-arrow-up'" style="color: #3A7BFA;" type="text" |
| | | @click="more = !more">{{ !more ? 'æ´å¤' : 'æ¶èµ·' }}</el-button> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | <el-button size="mini" type="primary" @click="refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="table-tab"> |
| | | <div> |
| | | <ul class="tab"> |
| | | <li :class="{ active: tabIndex === 0 }" v-if="checkPermi(['get:insOrder:reviewed'])" @click="handleTab(0)">å¾
å®¡æ ¸</li> |
| | | <li :class="{ active: tabIndex === 1 }" v-if="checkPermi(['get:insOrder:checkout'])" @click="handleTab(1)">æ£éªä¸</li> |
| | | <li :class="{ active: tabIndex === 2 }" v-if="checkPermi(['get:insOrder:customerOrdered'])" @click="handleTab(2)">å§æå·²æ£</li> |
| | | <li :class="{ active: tabIndex === 3 }" v-if="checkPermi(['get:insOrder:spotCheck'])" @click="handleTab(3)">æ½æ ·å·²æ£</li> |
| | | <li :class="{ active: tabIndex === 4 }" v-if="checkPermi(['get:insOrder:sendBack'])" @click="handleTab(4)">éå</li> |
| | | <li :class="{ active: tabIndex === 5 }" v-if="checkPermi(['get:insOrder:revocation'])" @click="handleTab(5)">æ¤é</li> |
| | | <li :class="{ active: tabIndex === 6 }" v-if="checkPermi(['get:insOrder:all'])" @click="handleTab(6)">å
¨é¨</li> |
| | | </ul> |
| | | <div class="container" v-loading="isLoading"> |
| | | <div class="table-tab"> |
| | | <div> |
| | | <ul class="tab"> |
| | | <li :class="{ active: tabIndex === 0 }" v-if="checkPermi(['get:insOrder:reviewed'])" @click="handleTab(0)">å¾
å®¡æ ¸</li> |
| | | <li :class="{ active: tabIndex === 1 }" v-if="checkPermi(['get:insOrder:checkout'])" @click="handleTab(1)">æ£éªä¸</li> |
| | | <li :class="{ active: tabIndex === 2 }" v-if="checkPermi(['get:insOrder:customerOrdered'])" @click="handleTab(2)">å§æå·²æ£</li> |
| | | <li :class="{ active: tabIndex === 3 }" v-if="checkPermi(['get:insOrder:spotCheck'])" @click="handleTab(3)">æ½æ ·å·²æ£</li> |
| | | <li :class="{ active: tabIndex === 4 }" v-if="checkPermi(['get:insOrder:sendBack'])" @click="handleTab(4)">éå</li> |
| | | <li :class="{ active: tabIndex === 5 }" v-if="checkPermi(['get:insOrder:revocation'])" @click="handleTab(5)">æ¤é</li> |
| | | <li :class="{ active: tabIndex === 6 }" v-if="checkPermi(['get:insOrder:all'])" @click="handleTab(6)">å
¨é¨</li> |
| | | </ul> |
| | | </div> |
| | | <div> |
| | | <el-button v-if="tabIndex === 2 || tabIndex === 3 || tabIndex === 6" size="small" |
| | | @click="downLoad">导åº</el-button> |
| | | <el-button v-if="tabIndex === 1" size="small" type="primary" @click="openAddIns">æ·»å æ£éªé¡¹</el-button> |
| | | <el-button size="small" type="primary" @click="openPrint">æ ç¾æå°</el-button> |
| | | <el-button v-if="checkPermi(['add:insOrder'])" size="small" type="primary" @click="playOrder(1)">ä¸å</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <el-button v-if="tabIndex === 2 || tabIndex === 3 || tabIndex === 6" size="small" |
| | | @click="downLoad">导åº</el-button> |
| | | <el-button v-if="tabIndex === 1" size="small" type="primary" @click="openAddIns">æ·»å æ£éªé¡¹</el-button> |
| | | <el-button size="small" type="primary" @click="openPrint">æ ç¾æå°</el-button> |
| | | <el-button v-if="checkPermi(['add:insOrder'])" size="small" type="primary" @click="playOrder(1)">ä¸å</el-button> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="column" :isSelection="true" :handleSelectionChange="selectMethod" |
| | | @pagination="pagination" :height="'calc(100vh - 280px)'" :key="upIndex" :page="page" |
| | | :tableLoading="tableLoading"></lims-table> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="column" :isSelection="true" :handleSelectionChange="selectMethod" |
| | | @pagination="pagination" :height="'calc(100vh - 280px)'" :key="upIndex" :page="page" |
| | | :tableLoading="tableLoading"></lims-table> |
| | | </div> |
| | | <div> |
| | | <!-- å®¡æ ¸ --> |
| | |
| | | @closePrintDialog="closePrintDialog"></print-dialog> |
| | | <!--æ·»å éæ¼æ£éªé¡¹å¼¹æ¡--> |
| | | <add-inspection-dia v-if="addInspectionDia" ref="addInspectionDia"></add-inspection-dia> |
| | | <!-- <Inspection v-if="state>0" :key="InspectionKey" :inspectorList="inspectorList" :orderId="orderId"--> |
| | | <!-- :sonLaboratory="sonLaboratory" :state="state"--> |
| | | <!-- :typeSource="typeSource" @goback="goback" @refreshView="refreshView"/>--> |
| | | <!--ä¿®æ¹æ ·ååå·å¼¹æ¡--> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" |
| | | :visible.sync="dialogVisible" title="ä¿®æ¹æ ·ååå·" width="80%"> |
| | | <el-table ref="sampleTable" :data="sampleList" border highlight-current-row |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" |
| | | max-height="400px" tooltip-effect="dark"> |
| | | <el-table-column align="center" label="åºå·" type="index" width="65"></el-table-column> |
| | | <el-table-column align="center" label="æ ·ååç§°" min-width="100" prop="sample"> </el-table-column> |
| | | <el-table-column align="center" label="æ ·åç¼å·" min-width="100" prop="sampleCode"></el-table-column> |
| | | <el-table-column align="center" label="æ ·ååå·" min-width="60" prop="model"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.model" clearable placeholder="ä¸å¡«ååç³»ç»èªå¨çæ" |
| | | size="small"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column align="center" label="æ£éªæ å" min-width="100" prop="standardMethodName"></el-table-column> |
| | | </el-table> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="dialogVisible = false">å æ¶</el-button> |
| | | <el-button :loading="submitListLoad" type="primary" @click="submitList">ç¡® å®</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | import AddInspectionDia from "@/views/business/productOrder/components/addInspectionDia.vue"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import { |
| | | checkUpdate, delInsOrder, |
| | | checkUpdate, delInsOrder, getSampleByOrderId, |
| | | rawAllInsOrderExport, |
| | | selectInsOrderParameter, selectNoProducts, selectOrderManDay, |
| | | updateInspected, |
| | | updateOrderEntrustCode, updateStatus, upInsOrder, upPlanUser2 |
| | | updateOrderEntrustCode, updateSampleModel, updateStatus, upInsOrder, upPlanUser2 |
| | | } from "@/api/business/productOrder"; |
| | | import { selectUserCondition } from "@/api/performance/class"; |
| | | import { downFile, getFileList, selectSampleAndProductByOrderId } from "@/api/business/rawMaterialOrder"; |
| | |
| | | }, |
| | | data() { |
| | | return { |
| | | isLoading: false, // æ§å¶å è½½ç¶æ |
| | | entity: { |
| | | orderType: '', |
| | | state: '', |
| | |
| | | dataType: "link", |
| | | linkMethod: "selectAllByOne", |
| | | }, |
| | | { label: 'æ ·ååå·', prop: 'sampleModel' }, |
| | | { |
| | | label: "æ ·ååå·", |
| | | prop: "sampleModel", |
| | | width: "160px", |
| | | dataType: "link", |
| | | linkMethod: "editSampleModel", |
| | | }, |
| | | { label: 'æ ·åæ°é', prop: 'sampleNum' }, |
| | | { label: 'æ£éªäºº', prop: 'testingName' }, |
| | | { |
| | |
| | | multipleSelection: [], |
| | | sonLaboratoryList: [], |
| | | printDialog: false, |
| | | addInspectionDia: false |
| | | addInspectionDia: false, |
| | | dialogVisible: false, |
| | | submitListLoad: false, |
| | | sampleList: [] |
| | | } |
| | | }, |
| | | watch: { |
| | |
| | | ...mapGetters(["nickName"]), |
| | | }, |
| | | mounted() { |
| | | if (this.checkPermi(['get:raw:await'])) { |
| | | this.tabIndex = 0 |
| | | } else { |
| | | this.tabIndex = 2 |
| | | } |
| | | this.refreshTable() |
| | | this.getAuthorizedPerson() |
| | | }, |
| | |
| | | } |
| | | } |
| | | const params = { ...this.entity, state: this.tabList[this.tabIndex].value } |
| | | this.tableLoading = true |
| | | this.isLoading = true; // å¼å§å è½½ |
| | | selectInsOrderParameter({...this.page,...params}).then(res => { |
| | | this.isLoading = false; // ç»æå è½½ |
| | | this.upIndex++ |
| | | this.tableLoading = false |
| | | if (res.code === 200) { |
| | |
| | | this.page.total = res.data.total |
| | | } |
| | | }).catch(err => { |
| | | this.tableLoading = false |
| | | this.isLoading = false; // ç»æå è½½ |
| | | }) |
| | | }, |
| | | refresh() { |
| | |
| | | }, |
| | | // 导åºè®°å½ |
| | | downLoad() { |
| | | const params = { ...this.entity, state: this.tabList[this.tabIndex].value } |
| | | let params = {} |
| | | if (this.multipleSelection.length > 0) { |
| | | params.ids = this.multipleSelection.map(item => item.id).join(','); |
| | | } else { |
| | | params = { ...this.entity, state: this.tabList[this.tabIndex].value } |
| | | } |
| | | rawAllInsOrderExport({ ...params }).then(res => { |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | this.$download.saveAs(blob, 'å§ææ£æµä¿¡æ¯å¯¼åº.xlsx'); |
| | |
| | | this.dataDialogVisible = false; |
| | | this.upLoad = false; |
| | | }, |
| | | // 详æ
|
| | | // ç¹å»æ ·ååç§° |
| | | selectAllByOne(row) { |
| | | this.$router.push({ |
| | | path: "/productOrder/add", query: { |
| | | path: "/productOrder/addView", query: { |
| | | examine: 1, |
| | | active: 2, |
| | | currentId: row.id |
| | | currentId: row.id, |
| | | tabIndex: this.tabIndex, |
| | | } |
| | | }); |
| | | }, |
| | | // ä¿®æ¹æ ·ååå· |
| | | editSampleModel (row) { |
| | | if (this.tabIndex !== 1) { |
| | | return |
| | | } |
| | | this.dialogVisible = true |
| | | this.getDataList(row) |
| | | }, |
| | | getDataList(row) { |
| | | this.dialogVisible = true |
| | | getSampleByOrderId({insOrderId: row.id}).then(res => { |
| | | this.sampleList = res.data |
| | | }) |
| | | }, |
| | | // æäº¤æ ·ååå·ä¿®æ¹ |
| | | submitList () { |
| | | this.submitListLoad = true |
| | | updateSampleModel(this.sampleList).then(res => { |
| | | this.submitListLoad = false |
| | | this.dialogVisible = false |
| | | this.$message.success('ä¿®æ¹æå') |
| | | this.refreshTable() |
| | | }).catch(err => { |
| | | this.submitListLoad = false |
| | | }) |
| | | }, |
| | | // æ°æ®æ¥ç |
| | | handleDataLook(row) { |
| | |
| | | }, |
| | | getDeleteList() { |
| | | this.tableLoadingDelete = true |
| | | selectNoProducts({ orderId: this.orderId, revocationInsProductIds: this.revocationInsProductIds }).then(res => { |
| | | selectNoProducts({ orderId: this.orderId, revocationInsProductIds: this.revocationInsProductIds, ...this.pageDelete }).then(res => { |
| | | this.tableLoadingDelete = false |
| | | this.componentDataDelete = res.data.records |
| | | this.pageDelete.total = res.data.total |
| | |
| | | }, |
| | | // ä¸å |
| | | playOrder(num) { |
| | | this.$router.push({ path: "/productOrder/add", query: { examine: 0, active: num, tabIndex: this.tabIndex } }); |
| | | this.$router.push({ path: "/productOrder/addOrder", query: { examine: 0, active: num, tabIndex: this.tabIndex } }); |
| | | }, |
| | | // å®¡æ ¸ |
| | | handleVerify(row) { |
| | | this.$router.push({ path: "/productOrder/add", query: { examine: 1, active: 3, currentId: row.id } }); |
| | | this.$router.push({ path: "/productOrder/addView", query: { examine: 1, active: 3, currentId: row.id } }); |
| | | }, |
| | | handleTab(i) { |
| | | this.tabIndex = i; |
| | | this.multipleSelection = [] |
| | | this.refreshTable() |
| | | }, |
| | | // æ¥çæ£éªæ°æ® |
| | |
| | | inspectorList = row.userName.split(',') |
| | | } |
| | | inspectorList.push(this.nickName) |
| | | this.$router.push({ |
| | | path: "/inspectionTask/inspection", |
| | | query: { |
| | | sonLaboratory: row.sonLaboratory, |
| | | state: 3, |
| | | typeSource: row.typeSource, |
| | | orderId: row.id, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | if (this.checkPermi(['business:inspectionView'])) { |
| | | this.$router.push({ |
| | | name: "InspectionView", |
| | | query: { |
| | | sonLaboratory: row.sonLaboratory, |
| | | state: 3, |
| | | typeSource: row.typeSource, |
| | | orderId: row.id, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | } else { |
| | | this.$router.push({ |
| | | path: "/inspectionTask/inspection", |
| | | query: { |
| | | sonLaboratory: row.sonLaboratory, |
| | | state: 3, |
| | | typeSource: row.typeSource, |
| | | orderId: row.id, |
| | | inspectorList: inspectorList, |
| | | }, |
| | | }) |
| | | } |
| | | }, |
| | | goback() { |
| | | this.state = 0 |
| | |
| | | <template> |
| | | <div class="capacity-scope"> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <el-form :model="entity" ref="entity" size="small" :inline="true"> |
| | | <el-form-item label="ç¼å·" prop="quarterNo" v-show="tabIndex === 0"> |
| | | <div class="search_box"> |
| | | <div class="search_item"> |
| | | <span class="search_label">ç¼å·</span> |
| | | <el-input v-model="entity.quarterNo" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable"> |
| | | @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="search_button"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <el-button v-if="tabIndex === 1" size="small" type="primary" @click="yearSample('add')">å¹´åº¦æ½æ ·</el-button> |
| | | </div> |
| | |
| | | // æ¹æ³éå |
| | | methods: { |
| | | // æ¥è¯¢åè° |
| | | refreshTable(e) { |
| | | refreshTable() { |
| | | if (this.tabIndex === 0) { |
| | | this.getQuarterPageList() |
| | | } else if (this.tabIndex === 1) { |
| | |
| | | // 忢ä¸åtabè¡¨æ ¼ |
| | | handleTab(m, i) { |
| | | this.tabIndex = i; |
| | | if (this.tabIndex === 0) { |
| | | this.componentData.entity.quarterNo = this.entity.quarterNo |
| | | } |
| | | this.refreshTable() |
| | | }, |
| | | closeYearSampleDia() { |
| | |
| | | border-color: #3A7BFA; |
| | | color: #3A7BFA; |
| | | } |
| | | .search_box { |
| | | display: flex; |
| | | } |
| | | .search_item { |
| | | margin-bottom: 18px; |
| | | margin-right: 10px; |
| | | display: flex; |
| | | align-items: center; |
| | | line-height: 32px; |
| | | } |
| | | .search_label { |
| | | width: 52px; |
| | | font-size: 14px; |
| | | font-weight: 700; |
| | | color: #606266; |
| | | } |
| | | .search_button { |
| | | line-height: 30px; |
| | | } |
| | | </style> |
| | |
| | | <el-form-item> |
| | | <el-button v-if="tabIndex === 3 || tabIndex === 4" :icon="!more ? 'el-icon-arrow-down' : 'el-icon-arrow-up'" |
| | | style="color: #3A7BFA;" type="text" @click="more = !more">{{ !more ? 'æ´å¤' : 'æ¶èµ·' }}</el-button> |
| | | <el-button size="mini" icon="el-icon-search" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh()" icon="el-icon-refresh">é ç½®</el-button> |
| | | <el-button size="mini" type="primary" @click="refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh()" >éç½®</el-button> |
| | | </el-form-item> |
| | | </el-row> |
| | | <el-row> |
| | |
| | | </el-form-item> |
| | | <el-form-item label="ä¸åæ¶é´" prop="date" v-if="(tabIndex === 3 || tabIndex === 4) && more"> |
| | | <el-date-picker v-model="componentData.date" end-placeholder="ç»ææ¥æ" format="yyyy-MM-dd" placeholder="éæ©æ¥æ" |
| | | range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" style="width: 100%;" type="daterange" |
| | | range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" style="width: 100%;" type="daterange" @change="refreshTable()" |
| | | value-format="yyyy-MM-dd"> |
| | | </el-date-picker> |
| | | </el-form-item> |
| | |
| | | { label: 'æ¥æ£æ¶é´', prop: 'declareDate' }, |
| | | { |
| | | dataType: 'action', |
| | | fixed: 'right', |
| | | label: 'æä½', |
| | | operation: [ |
| | | { |
| | |
| | | tableData1: [], |
| | | tableLoading1: false, |
| | | column1: [ |
| | | { label: 'å§æç¼å·', prop: 'entrustCode', width: '160px' }, |
| | | { |
| | | dataType: 'tag', |
| | | label: 'æ£éªç¶æ', |
| | |
| | | }, |
| | | { label: '订åå·', prop: 'orderNo' }, |
| | | { label: 'æµè¾¾çéè´æ°é', prop: 'qtyArrived' }, |
| | | { label: 'ä¸åæ¶é´', prop: 'sendTime' }, |
| | | { label: 'æ¥æ£æ¶é´', prop: 'declareDate' }, |
| | | { label: 'æ¹å·', prop: 'updateBatchNo' }, |
| | | { label: 'é¶ä»¶å·', prop: 'partNo' }, |
| | | { label: 'é¶ä»¶æè¿°', prop: 'partDesc' }, |
| | |
| | | } |
| | | } |
| | | }, |
| | | { label: 'å§æç¼å·', prop: 'entrustCode', width: '160px' }, |
| | | { label: 'æ ·ååç§°', prop: 'sampleName' }, |
| | | { label: 'æ ·ååå·', prop: 'sampleModel' }, |
| | | { label: 'æ£éªäºº', prop: 'userName' }, |
| | |
| | | }, |
| | | { label: 'åä½', prop: 'buyUnitMeas' }, |
| | | { label: 'æ¥æ¶æ¶é´', prop: 'receiverDate' }, |
| | | { label: 'æ¥æ£æ¶é´', prop: 'declareDate' }, |
| | | { label: 'ä¸åæ¶é´', prop: 'sendTime' }, |
| | | { |
| | | dataType: 'action', |
| | | fixed: 'right', |
| | |
| | | }, |
| | | // å
¨é¨å¯¼åº |
| | | handleDown() { |
| | | let entity = { ...this.componentData } |
| | | delete entity.orderBy |
| | | this.outLoading = true |
| | | rawAllExport({ |
| | | entity: entity |
| | | ...this.componentData |
| | | }).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | <el-button size="mini" type="primary" @click="refreshTable()">æ¥è¯¢</el-button> |
| | | <el-button :loading="outLoading" size="mini" type="primary" @click="handleDowns">æ¹éä¸è½½</el-button> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div style="text-align: right;margin-bottom: 10px"> |
| | | <el-button :loading="outLoading" size="mini" type="primary" @click="handleDowns">æ¹éä¸è½½</el-button> |
| | | <el-button :loading="outExportLoading" size="mini" type="primary" @click="handleExport">æ¥è¡¨å¯¼åº</el-button> |
| | | </div> |
| | | <div> |
| | | <lims-table :tableData="valueTableData" :column="column" :page="page" :tableLoading="tableLoading" |
| | |
| | | <el-button size="small" style="height: 38px" type="primary">éä»¶ä¸ä¼ </el-button> |
| | | </el-upload> |
| | | </div> |
| | | <lims-table :tableData="tableDataFile" :column="columnFile" height="500px" |
| | | <lims-table :tableData="tableDataFile" :column="columnFile" height="600px" |
| | | key="tableDataFile" :tableLoading="tableLoadingFile"></lims-table> |
| | | </el-dialog> |
| | | </div> |
| | |
| | | ratifyReport, |
| | | sendBackTask, |
| | | upReportUrl, |
| | | writeReport |
| | | writeReport, |
| | | reportAllExport |
| | | } from "@/api/business/insReport"; |
| | | import { mapGetters } from "vuex"; |
| | | import { selectUserCondition } from "@/api/business/inspectionTask"; |
| | |
| | | queryStatus: null, |
| | | code: null, |
| | | typeSource: null, |
| | | orderType: null, |
| | | }, |
| | | page: { |
| | | current: 1, |
| | |
| | | option: null, |
| | | mutiList: [], |
| | | outLoading: false, |
| | | outExportLoading: false, |
| | | inLoading: false, |
| | | addApproverDia: false, // æå®å®¡æ¹äººåå¼¹æ¡ |
| | | approver: '', // 审æ¹äººå |
| | |
| | | // æ¥è¯¢éä»¶æ¥çå表åè° |
| | | getFileList() { |
| | | this.tableLoadingFile = true |
| | | getFileList({ insOrderId: this.filesLookInfo.insOrderId }).then(res => { |
| | | getFileList({ insOrderId: this.filesLookInfo.insOrderId,current: -1, size: -1 }).then(res => { |
| | | this.tableLoadingFile = false |
| | | if (res.code === 200) { |
| | | this.tableDataFile = res.data.records |
| | |
| | | }) |
| | | |
| | | }, |
| | | // æ¥è¡¨å¯¼åº |
| | | handleExport() { |
| | | this.outExportLoading = true |
| | | reportAllExport({ |
| | | ...this.entity |
| | | }).then(res => { |
| | | this.outExportLoading = false |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | this.$download.saveAs(blob, "æ¥åæ¥è¡¨å¯¼åº.xlsx"); |
| | | }) |
| | | }, |
| | | beforeUpload(file) { |
| | | const isZip = file.type === 'application/zip' || file.name.endsWith('.zip'); |
| | | if (!isZip) { |
| | |
| | | case 0: |
| | | // åææ |
| | | this.$router.push({ |
| | | path: "/materialOrder/customsInspection", query: { |
| | | path: "/materialOrder/customsInspectionView", query: { |
| | | customsInspection: row, |
| | | active: this.activeFace, |
| | | currentId: row.insOrderId, |
| | |
| | | case null: |
| | | // æå |
| | | this.$router.push({ |
| | | path: "/productOrder/add", query: { |
| | | path: "/productOrder/addView", query: { |
| | | examine: this.examine, |
| | | active: this.activeFace, |
| | | currentId: row.insOrderId |
| | |
| | | case 1: |
| | | // éæ |
| | | this.$router.push({ |
| | | path: "/materialOrder/copperOrder", query: { |
| | | path: "/materialOrder/CopperView", query: { |
| | | active: this.activeFace, |
| | | currentId: row.insOrderId |
| | | } |
| | |
| | | // æ¹æ³éå |
| | | methods: { |
| | | async getInsOrder(operationType, item) { |
| | | console.log('operationType----', operationType) |
| | | this.operationType = operationType |
| | | this.info = item |
| | | // æ¥è¯¢å·²æäº¤çæ°æ® |
| | |
| | | v-loading="tableLoading" @selection-change="selectProduct" style="margin-bottom: 10px;" |
| | | :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border @select-all="handleAll"> |
| | | <el-table-column type="selection" width="65"></el-table-column> |
| | | <el-table-column prop="inspectionItemClass" label="æ£éªé¡¹åç±»" min-width="140" |
| | | show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="isBinding" label="ç±»å" min-width="140" show-overflow-tooltip> |
| | | <template slot-scope="scope"> |
| | | <el-select v-model="scope.row.isBinding" clearable size="small"> |
| | | <el-option :value="1" label="ç»å®å¼"></el-option> |
| | | <el-option :value="0" label="ä¸åæ ¼å¼"></el-option> |
| | | </el-select> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="inspectionItemClass" label="æ£éªé¡¹åç±»" min-width="140" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="inspectionItem" label="æ£éªé¡¹" min-width="140" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="inspectionItemSubclass" label="æ£éªé¡¹å项" min-width="140" |
| | | show-overflow-tooltip></el-table-column> |
| | |
| | | <el-table-column prop="ask" label="è¦æ±å¼" min-width="220px"></el-table-column> |
| | | <el-table-column prop="lastValue" label="æ£éªç»æ" min-width="140" show-overflow-tooltip></el-table-column> |
| | | <el-table-column prop="insResult" label="ç»æå¤å®" min-width="140" show-overflow-tooltip> |
| | | <template> |
| | | <el-tag type="danger">ä¸åæ ¼</el-tag> |
| | | <template slot-scope="scope"> |
| | | <el-tag type="success" v-if="scope.row.insResult === 1">åæ ¼</el-tag> |
| | | <el-tag type="danger" v-if="scope.row.insResult === 0">ä¸åæ ¼</el-tag> |
| | | <el-tag type="info" v-if="scope.row.insResult === 3">ä¸å¤å®</el-tag> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | |
| | | <script> |
| | | import {addUnqualifiedRetest, getInsProductUnqualified} from '@/api/business/unpass.js' |
| | | import {getInsProduct} from "@/api/business/inspectionTask"; |
| | | export default { |
| | | name: "addUnPass", |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | |
| | | getInsOrder(info) { |
| | | this.tableLoading = true |
| | | try { |
| | | getInsProductUnqualified({ id: info.id, type: info.type, laboratory: info.laboratory, rawMaterialTag: info.rawMaterialTag }).then(res => { |
| | | getInsProduct({ id: info.id, type: info.type, laboratory: info.laboratory, rawMaterialTag: info.rawMaterialTag,repetitionTag: info.repetitionTag,cableTag: info.cableTag }).then(res => { |
| | | if (res.code === 200) { |
| | | this.productList = res.data |
| | | } |
| | |
| | | this.$message.warning('è¯·éæ©éè¦å¤æµçæ£éªé¡¹') |
| | | return |
| | | } |
| | | // æ£æ¥æ¯å¦ææéä¸çè¡é½éæ©äº isBinding |
| | | const hasUnselectedBinding = this.productListSelected.some( |
| | | (row) => row.isBinding === null || row.isBinding === undefined |
| | | ); |
| | | |
| | | if (hasUnselectedBinding) { |
| | | this.$message.error("请确ä¿éä¸çæ°æ®é½éæ©äºç±»åï¼"); |
| | | return; |
| | | } |
| | | this.$confirm('确认æäº¤ä¸åæ ¼å¤æµ?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | |
| | | }); |
| | | }, |
| | | handlePass() { |
| | | const ids = this.productListSelected.map(item => ({ |
| | | id: item.id, |
| | | isBinding: item.isBinding |
| | | })); |
| | | this.handlePassLoading = true |
| | | try { |
| | | addUnqualifiedRetest({ |
| | | ids: this.productIds |
| | | }).then(res => { |
| | | addUnqualifiedRetest(ids).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('æäº¤æå') |
| | | this.$emit('resetAddUnPass') |
| | | } |
| | | this.handlePassLoading = false |
| | | }).catch(e => { |
| | | this.handlePassLoading = false |
| | | }) |
| | | } catch (e) { |
| | | this.handlePassLoading = false |
| | |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="entity" ref="entity" size="small" :inline="true"> |
| | | <el-form-item label="订åç¼å·" prop="no"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.no" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="è§æ ¼åå·" prop="model"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="entity.model" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | tableData: [], |
| | | tableLoading: false, |
| | | column: [ |
| | | { label: 'ç¼å·', prop: 'no' }, |
| | | { |
| | | label: "OAå®¡æ ¸ç¶æ", |
| | | prop: "oaState", |
| | | width: "100px", |
| | | dataType: "tag", |
| | | formatData: (params) => { |
| | | if (params == 1) { |
| | | return "å¾
å®¡æ ¸"; |
| | | } else if(params == 2) { |
| | | return "å®¡æ ¸ä¸"; |
| | | } else if(params == 3) { |
| | | return "éè¿"; |
| | | } else { |
| | | return "驳å"; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params == 1) { |
| | | return "warning"; |
| | | } else if(params == 2) { |
| | | return "info"; |
| | | } else if(params == 3) { |
| | | return "success"; |
| | | } else { |
| | | return "danger"; |
| | | } |
| | | }, |
| | | }, |
| | | { label: 'ç¼å·', prop: 'no', width: "160px", }, |
| | | // { |
| | | // label: "OAå®¡æ ¸ç¶æ", |
| | | // prop: "oaState", |
| | | // width: "100px", |
| | | // dataType: "tag", |
| | | // formatData: (params) => { |
| | | // if (params == 1) { |
| | | // return "å¾
å®¡æ ¸"; |
| | | // } else if(params == 2) { |
| | | // return "å®¡æ ¸ä¸"; |
| | | // } else if(params == 3) { |
| | | // return "éè¿"; |
| | | // } else { |
| | | // return "驳å"; |
| | | // } |
| | | // }, |
| | | // formatType: (params) => { |
| | | // if (params == 1) { |
| | | // return "warning"; |
| | | // } else if(params == 2) { |
| | | // return "info"; |
| | | // } else if(params == 3) { |
| | | // return "success"; |
| | | // } else { |
| | | // return "danger"; |
| | | // } |
| | | // }, |
| | | // }, |
| | | { label: '订åå·', prop: 'orderNo' }, |
| | | { |
| | | label: "é¶ä»¶å·", |
| | |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | tableLoading: false, |
| | | column: [ |
| | | { label: 'ç¼å·', prop: 'no' }, |
| | | { |
| | | label: "OAå®¡æ ¸ç¶æ", |
| | | prop: "oaState", |
| | | width: "100px", |
| | | dataType: "tag", |
| | | formatData: (params) => { |
| | | if (params == 0) { |
| | | return "å¦"; |
| | | } else { |
| | | return "æ¯"; |
| | | } |
| | | }, |
| | | formatType: (params) => { |
| | | if (params == 0) { |
| | | return "danger"; |
| | | } else { |
| | | return "primary"; |
| | | } |
| | | }, |
| | | }, |
| | | // { |
| | | // label: "OAå®¡æ ¸ç¶æ", |
| | | // prop: "oaState", |
| | | // width: "100px", |
| | | // dataType: "tag", |
| | | // formatData: (params) => { |
| | | // if (params == 0) { |
| | | // return "å¦"; |
| | | // } else { |
| | | // return "æ¯"; |
| | | // } |
| | | // }, |
| | | // formatType: (params) => { |
| | | // if (params == 0) { |
| | | // return "danger"; |
| | | // } else { |
| | | // return "primary"; |
| | | // } |
| | | // }, |
| | | // }, |
| | | { |
| | | dataType: 'action', |
| | | fixed: 'right', |
| | |
| | | |
| | | <script> |
| | | import ScrollPagination from '@/components/index/scroll-paging.vue' |
| | | import {calendarWorkByWeek, currentUserWorkHourCount, msgRoll, page} from "@/api/index/report"; |
| | | import { |
| | | calendarWorkByWeek, |
| | | currentUserWorkHourCount, |
| | | msgRoll, |
| | | page, |
| | | triggerModificationStatusToRead |
| | | } from "@/api/index/report"; |
| | | import Echarts from "@/components/echarts/echarts.vue"; |
| | | import {mapGetters} from "vuex"; |
| | | export default { |
| | |
| | | // è·³è½¬é¡µé¢ |
| | | goAddList(m) { |
| | | this.$router.push({name: m.jumpPath, query: { activeName: m.jumpId }}) |
| | | this.changeStatus(m) |
| | | }, |
| | | changeStatus (m) { |
| | | triggerModificationStatusToRead({id: m.id}).then(res => { |
| | | console.log(res.data) |
| | | }) |
| | | }, |
| | | getList(){ |
| | | const key = `_${this.currentPage}` |
| | |
| | | month: month, |
| | | } |
| | | currentUserWorkHourCount(params).then(res => { |
| | | console.log(res) |
| | | this.totalHour = res.data.totalHour |
| | | this.materialPieSeries[0].data[0].value = res.data.subsidiaryHour |
| | | this.materialPieSeries[0].data[1].value = res.data.yieldHour |
| | |
| | | </div> |
| | | <div class="rightForm"> |
| | | <div class="title_big">æ¬¢è¿æ¨ç»å½ï¼</div> |
| | | <div class="title_small">LIMSå®éªå®¤ç®¡çç³»ç»</div> |
| | | <div class="title_small">è£
å¤LIMSå®éªå®¤ç®¡çç³»ç»</div> |
| | | <el-form ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form"> |
| | | <el-form-item prop="username"> |
| | | <el-input v-model="loginForm.username" type="text" auto-complete="off" placeholder="è´¦å·"> |
| | |
| | | <svg-icon slot="prefix" icon-class="password" class="el-input__icon input-icon" /> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item prop="code" v-if="captchaEnabled"> |
| | | <el-input v-model="loginForm.code" auto-complete="off" placeholder="éªè¯ç " style="width: 63%" |
| | | @keyup.enter.native="handleLogin"> |
| | | <svg-icon slot="prefix" icon-class="validCode" class="el-input__icon input-icon" /> |
| | | </el-input> |
| | | <div class="login-code"> |
| | | <img :src="codeUrl" @click="getCode" class="login-code-img" /> |
| | | </div> |
| | | </el-form-item> |
| | | <el-checkbox v-model="loginForm.rememberMe" style="margin:0px 0px 25px 0px;">è®°ä½å¯ç </el-checkbox> |
| | | <!-- <el-form-item prop="code" v-if="captchaEnabled">--> |
| | | <!-- <el-input v-model="loginForm.code" auto-complete="off" placeholder="éªè¯ç " style="width: 63%"--> |
| | | <!-- @keyup.enter.native="handleLogin">--> |
| | | <!-- <svg-icon slot="prefix" icon-class="validCode" class="el-input__icon input-icon" />--> |
| | | <!-- </el-input>--> |
| | | <!-- <div class="login-code">--> |
| | | <!-- <img :src="codeUrl" @click="getCode" class="login-code-img" />--> |
| | | <!-- </div>--> |
| | | <!-- </el-form-item>--> |
| | | <!-- <el-checkbox v-model="loginForm.rememberMe" style="margin:0px 0px 25px 0px;">è®°ä½å¯ç </el-checkbox>--> |
| | | <el-form-item style="width:100%;"> |
| | | <el-button :loading="loading" size="medium" type="primary" style="width:100%;" |
| | | @click.native.prevent="handleLogin"> |
| | |
| | | <router-link class="link-type" :to="'/register'">ç«å³æ³¨å</router-link> |
| | | </div> |
| | | </el-form-item> |
| | | <el-button v-if="false" type="primary" plain @click="goLogin">éå¢éæç»å½</el-button> |
| | | <el-button v-if="true" type="primary" plain @click="goLogin">éå¢éæç»å½</el-button> |
| | | </el-form> |
| | | </div> |
| | | <!-- åºé¨ --> |
| | |
| | | |
| | | <script> |
| | | import { getCodeImg, getSsoAuthUrl } from "@/api/login"; |
| | | import Cookies from "js-cookie"; |
| | | import { encrypt, decrypt } from '@/utils/jsencrypt' |
| | | |
| | | export default { |
| | |
| | | } |
| | | }, |
| | | created() { |
| | | this.getCode(); |
| | | this.getCookie(); |
| | | // this.getCode(); |
| | | // this.getCookie(); |
| | | }, |
| | | methods: { |
| | | async goLogin() { |
| | |
| | | }); |
| | | }, |
| | | getCookie() { |
| | | const username = Cookies.get("username"); |
| | | const password = Cookies.get("password"); |
| | | const rememberMe = Cookies.get('rememberMe') |
| | | const username = localStorage.getItem("username"); |
| | | const password = localStorage.getItem("password"); |
| | | const rememberMe = localStorage.getItem('rememberMe') |
| | | this.loginForm = { |
| | | username: username === undefined ? this.loginForm.username : username, |
| | | password: password === undefined ? this.loginForm.password : decrypt(password), |
| | |
| | | this.$refs.loginForm.validate(valid => { |
| | | if (valid) { |
| | | this.loading = true; |
| | | if (this.loginForm.rememberMe) { |
| | | Cookies.set("username", this.loginForm.username, { expires: 30 }); |
| | | Cookies.set("password", encrypt(this.loginForm.password), { expires: 30 }); |
| | | Cookies.set('rememberMe', this.loginForm.rememberMe, { expires: 30 }); |
| | | } else { |
| | | Cookies.remove("username"); |
| | | Cookies.remove("password"); |
| | | Cookies.remove('rememberMe'); |
| | | } |
| | | // if (this.loginForm.rememberMe) { |
| | | // localStorage.setItem("username", this.loginForm.username, { expires: 30 }); |
| | | // localStorage.setItem("password", encrypt(this.loginForm.password), { expires: 30 }); |
| | | // localStorage.setItem('rememberMe', this.loginForm.rememberMe, { expires: 30 }); |
| | | // } else { |
| | | // localStorage.removeItem("username"); |
| | | // localStorage.removeItem("password"); |
| | | // localStorage.removeItem('rememberMe'); |
| | | // } |
| | | this.$store.dispatch("Login", this.loginForm).then(() => { |
| | | this.$router.push({ path: this.redirect || "/" }).catch(() => { }); |
| | | this.$router.push({ path: "/" }).catch(() => { }); |
| | | }).catch(() => { |
| | | this.loading = false; |
| | | if (this.captchaEnabled) { |
| | | this.getCode(); |
| | | } |
| | | // if (this.captchaEnabled) { |
| | | // this.getCode(); |
| | | // } |
| | | }); |
| | | } |
| | | }); |
| | |
| | | </script> |
| | | |
| | | <style rel="stylesheet/scss" lang="scss"> |
| | | //.login { |
| | | // display: flex; |
| | | // justify-content: center; |
| | | // align-items: center; |
| | | // height: 100%; |
| | | // background-image: url("../assets/images/login-background.jpg"); |
| | | // background-size: cover; |
| | | //} |
| | | .login { |
| | | display: flex; |
| | | justify-content: center; |
| | | align-items: center; |
| | | height: 100%; |
| | | background-image: url("../assets/images/login-background.jpg"); |
| | | background-size: cover; |
| | | } |
| | | .login { |
| | | width: 100vw; |
| | | height: 100vh; |
| | |
| | | ></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | |
| | | </el-form> |
| | |
| | | ></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | <el-button size="mini" type="primary" @click="refreshTable()"> 询</el-button> |
| | | <el-button size="mini" @click="refresh()">éç½®</el-button> |
| | | </div> |
| | | <div class="search_thing btns" style="padding-left: 30px"> |
| | | <el-button size="small" type="primary" v-if="checkPermi(['performance:class:time'])" |
| | |
| | | <template> |
| | | <div class="work-time-config"> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">ç¼å·ï¼</div> |
| | | <div class="search_input"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.number" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryParams" size="small" :inline="true"> |
| | | <el-form-item label="ç¼å·" prop="number"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.number" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="å®éªå®¤" prop="laboratory"> |
| | | <el-select v-model="queryParams.laboratory" placeholder="å
¨é¨" size="small" @change="refreshTable()" clearable> |
| | | <el-option v-for="item in laboratoryList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="é¨é¨" prop="department"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.department" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">å®éªå®¤ï¼</div> |
| | | <el-select v-model="queryParams.laboratory" placeholder="å
¨é¨" size="small" @change="refreshTable()" clearable> |
| | | <el-option v-for="item in laboratoryList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="openAdd('æ°å¢')" |
| | | v-if="checkPermi(['performance:manHour:workTimeConfig:add'])">æ° å¢</el-button> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">é¨é¨ï¼</div> |
| | | <div class="search_input"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.department" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </div> |
| | | <el-button size="small" type="primary" style="position: absolute; right: 50px" @click="openAdd('æ°å¢')" |
| | | v-if="checkPermi(['performance:manHour:workTimeConfig:add'])">æ° å¢</el-button> |
| | | </div> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="column" :tableLoading="tableLoading" :height="'calc(100vh - 290px)'" |
| | |
| | | { label: "夿³¨", prop: "remarks" }, |
| | | { |
| | | dataType: "action", |
| | | fixed: "right", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | |
| | | ], |
| | | page: { |
| | | total: 0, |
| | | size: 10, |
| | | size: 20, |
| | | current: 0, |
| | | }, |
| | | tableLoading: false, |
| | |
| | | }) |
| | | .then(() => { |
| | | deleteAuxiliaryWorkingHours({ id: row.id }).then((res) => { |
| | | console.log('res',res) |
| | | if (res.code == 200){ |
| | | this.$message.success("å 餿å"); |
| | | this.refresh(); |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .work-time-config { |
| | | height: 100%; |
| | | } |
| | | |
| | | .search { |
| | | background-color: #fff; |
| | | height: 80px; |
| | | height: 46px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 250px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 70px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 70px); |
| | | } |
| | | |
| | | .table { |
| | | padding: 10px; |
| | | padding-top: 0; |
| | | justify-content: space-between; |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <!--æ¥å·¥æ¶ç®¡ç--> |
| | | <div class="work-time-management"> |
| | | <div class="search"> |
| | | <div class="search_thing" style="width: 200px"> |
| | | <div class="search_label">ææï¼</div> |
| | | <el-select v-model="entity.weekDay" clearable placeholder="å
¨é¨" size="small" @change="refreshTable()"> |
| | | <el-option v-for="item in weekList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <div class="search_thing" style="width: 390px"> |
| | | <div class="search_label" style="width: 90px">æ¶é´èå´ï¼</div> |
| | | <div class="search_input"> |
| | | <div class="capacity-scope"> |
| | | <div> |
| | | <el-form :model="entity" ref="entity" size="small" :inline="true"> |
| | | <el-form-item label="ææ" prop="weekDay" class="form-item"> |
| | | <el-select v-model="entity.weekDay" clearable placeholder="å
¨é¨" size="small" @change="refreshTable()"> |
| | | <el-option v-for="item in weekList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="æ¶é´èå´" prop="dateTime" class="dateTime"> |
| | | <el-date-picker v-model="entity.dateTime" clearable end-placeholder="ç»ææ¥æ" format="yyyy-MM-dd" |
| | | range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" style="width: 100%" type="daterange" |
| | | value-format="yyyy-MM-dd" @change="refreshTable()"> |
| | | range-separator="è³" size="small" start-placeholder="å¼å§æ¥æ" type="daterange" |
| | | style="width: 100%" |
| | | value-format="yyyy-MM-dd" @change="refreshTable()"> |
| | | </el-date-picker> |
| | | </div> |
| | | </div> |
| | | <!-- 以ä¸è¿ä¸¤ä¸ªä¸ºç»é¿è§è²ç¹æç --> |
| | | <div class="search_thing" style="width: 200px"> |
| | | <div class="search_label">ååï¼</div> |
| | | <el-input v-model="entity.name" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div v-if="currentTable == 'ValueTable1'" class="search_thing" style="width: 250px"> |
| | | <div class="search_label" style="width: 120px">æ ·åç¼å·ï¼</div> |
| | | <el-input v-model="entity.sample" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div v-if="currentTable == 'ValueTable0'" class="search_thing" style="width: 200px"> |
| | | <div class="search_label">ç¶æï¼</div> |
| | | <el-select v-model="entity.state" placeholder="å
¨é¨" size="small" @change="refreshTable()" clearable> |
| | | <el-option v-for="item in stateList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px; width: 100px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </div> |
| | | </el-form-item> |
| | | <el-form-item label="åå" prop="name"> |
| | | <el-input v-model="entity.name" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ç¶æ" prop="state" v-if="currentTable == 'ValueTable0'"> |
| | | <el-select v-model="entity.state" placeholder="å
¨é¨" size="small" @change="refreshTable()" clearable> |
| | | <el-option v-for="item in stateList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="æ ·åç¼å·" prop="sample" v-if="currentTable == 'ValueTable1'"> |
| | | <el-input v-model="entity.sample" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | <div style="display: flex; align-items: center; justify-content: space-between"> |
| | | <div style="display: flex; align-items: center; justify-content: space-between;margin-bottom: 10px"> |
| | | <el-radio-group :key="'111'" v-model="currentTable" size="small" @change="searchList"> |
| | | <el-radio-button label="ValueTable0"> è¾
å©å·¥æ¶ </el-radio-button> |
| | | <el-radio-button label="ValueTable1"> 产éå·¥æ¶ </el-radio-button> |
| | | </el-radio-group> |
| | | <div style="display: flex; align-items: center"> |
| | | <!-- <p style="font-size: 14px; margin-right: 30px">--> |
| | | <!-- æ»å·¥æ¶æ±æ»ï¼<span v-if="totalInfo" style="font-size: 16px; color: #3a7bfa">{{--> |
| | | <!-- totalInfo["产éå·¥æ¶æ±æ»"] + totalInfo["è¾
å©å·¥æ¶æ±æ»"]--> |
| | | <!-- ? Number(--> |
| | | <!-- totalInfo["产éå·¥æ¶æ±æ»"] + totalInfo["è¾
å©å·¥æ¶æ±æ»"]--> |
| | | <!-- ).tofixed(4)--> |
| | | <!-- : 0--> |
| | | <!-- }}</span> 产éå·¥æ¶æ±æ»ï¼<span v-if="totalInfo" style="font-size: 16px; color: #3a7bfa">{{--> |
| | | <!-- totalInfo["产éå·¥æ¶æ±æ»"]--> |
| | | <!-- ? Number(totalInfo["产éå·¥æ¶æ±æ»"]).tofixed(4)--> |
| | | <!-- : 0--> |
| | | <!-- }}</span> è¾
å©å·¥æ¶æ±æ»ï¼<span v-if="totalInfo" style="font-size: 16px; color: #3a7bfa">{{--> |
| | | <!-- totalInfo["è¾
å©å·¥æ¶æ±æ»"]--> |
| | | <!-- ? Number(totalInfo["è¾
å©å·¥æ¶æ±æ»"]).tofixed(4)--> |
| | | <!-- : 0--> |
| | | <!-- }}</span>--> |
| | | <!-- </p>--> |
| | | <el-button v-show="currentTable == 'ValueTable0' && |
| | | checkPermi(['performance:manHour:workTimeManagement:add']) |
| | | " size="small" type="primary" @click="openAdd">å½å
¥æ°æ®</el-button> |
| | |
| | | </div> |
| | | <div class="table"> |
| | | <lims-table :tableData="tableData" :column="column" :page="page" :tableLoading="tableLoading" |
| | | key="tableData" |
| | | :height="'calc(100vh - 350px)'" :isSelection="true" v-if="currentTable == 'ValueTable0'" |
| | | @pagination="pagination" :handleSelectionChange="handleSelectionChange"></lims-table> |
| | | key="tableData" :height="'calc(100vh - 330px)'" |
| | | :isSelection="true" v-if="currentTable == 'ValueTable0'" |
| | | @pagination="pagination" :handleSelectionChange="handleSelectionChange"></lims-table> |
| | | <lims-table :tableData="tableData0" :column="column0" :page="page0" :tableLoading="tableLoading" |
| | | key="tableData0" |
| | | :height="'calc(100vh - 350px)'" v-if="currentTable == 'ValueTable1'" @pagination="pagination0"></lims-table> |
| | | key="tableData0" :height="'calc(100vh - 330px)'" |
| | | v-if="currentTable == 'ValueTable1'" @pagination="pagination0"></lims-table> |
| | | </div> |
| | | <el-dialog :before-close="handleClose" :title="formData.id ? 'ç¼è¾' : 'å½å
¥æ°æ®'" :visible.sync="addVisible" |
| | | width="600px"> |
| | |
| | | <el-input v-model="formData.week" disabled size="small"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="ææ:"> |
| | | <!-- <el-input v-model="formData.weekDay" size="small" disabled></el-input> --> |
| | | <el-select v-model="formData.weekDay" disabled placeholder="è¯·éæ©" size="small"> |
| | | <el-option v-for="item in weekList" :key="item.value" :label="item.label" :value="item.value"> |
| | | </el-option> |
| | |
| | | ], |
| | | page: { |
| | | total: 0, |
| | | size: 10, |
| | | size: 20, |
| | | current: 1, |
| | | }, |
| | | tableLoading: false, |
| | |
| | | ], |
| | | page0: { |
| | | total: 0, |
| | | size: 10, |
| | | size: 20, |
| | | current: 1, |
| | | }, |
| | | shifList: [], |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .work-time-management { |
| | | height: 100%; |
| | | overflow-y: scroll; |
| | | padding: 20px; |
| | | padding-top: 0; |
| | | /* scrollbar-width: none; */ |
| | | .form-item >>>.el-form-item__content { |
| | | width: 120px; |
| | | } |
| | | |
| | | /* .work-time-management::-webkit-scrollbar { |
| | | display: none; |
| | | } */ |
| | | .search { |
| | | background-color: #fff; |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 300px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 70px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 70px); |
| | | .dateTime >>>.el-form-item__content { |
| | | width: 260px; |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <div> |
| | | <div class="capacity-scope"> |
| | | <div> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æ¥æï¼</div> |
| | | <div class="search_input" style="display: flex; align-items: center"> |
| | | <el-date-picker |
| | | v-model="queryParams.month" |
| | | :clearable="false" |
| | | format="yyyy-MM" |
| | | placeholder="éæ©æ" |
| | | size="small" |
| | | style="width: 100%" |
| | | type="month" |
| | | value-format="yyyy-MM" |
| | | @change="refreshTable()" |
| | | > |
| | | </el-date-picker> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_label">åå·¥ï¼</div> |
| | | <el-input |
| | | v-model="queryParams.name" |
| | | clearable |
| | | placeholder="请è¾å
¥" |
| | | size="small" |
| | | @keyup.enter.native="refreshTable()" |
| | | ></el-input> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()" |
| | | >æ¥ è¯¢</el-button |
| | | > |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryParams" size="small" :inline="true"> |
| | | <el-form-item label="æ¥æ" prop="month"> |
| | | <el-date-picker |
| | | v-model="queryParams.month" |
| | | :clearable="false" |
| | | format="yyyy-MM" |
| | | placeholder="éæ©æ" |
| | | size="small" |
| | | style="width: 100%" |
| | | type="month" |
| | | value-format="yyyy-MM" |
| | | @change="refreshTable()" |
| | | > |
| | | </el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item label="åå·¥" prop="name"> |
| | | <el-input |
| | | v-model="queryParams.name" |
| | | clearable |
| | | placeholder="请è¾å
¥" |
| | | size="small" |
| | | @keyup.enter.native="refreshTable()" |
| | | ></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | | <limsTable |
| | | :column="tableColumn" |
| | | :table-data="tableData" |
| | | :table-loading="tableLoading" |
| | | :page="page" |
| | | style="padding: 0 15px" |
| | | :height="'calc(100vh - 290px)'" |
| | | @pagination="pagination" |
| | | > |
| | | </limsTable> |
| | | </div> |
| | | <limsTable |
| | | :column="tableColumn" |
| | | :table-data="tableData" |
| | | :table-loading="tableLoading" |
| | | :page="page" |
| | | :height="'calc(100vh - 290px)'" |
| | | @pagination="pagination" |
| | | > |
| | | </limsTable> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import { getYearAndMonthAndDays } from "@/utils/date"; |
| | | import { getYearAndMonthAndDays, getYearAndMonthAndDaysZTZB } from "@/utils/date"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import { selectAuxiliaryAllByMonth } from "@/api/performance/manHour"; |
| | | export default { |
| | |
| | | data() { |
| | | return { |
| | | queryParams: { |
| | | month: getYearAndMonthAndDays().slice(0, 7), |
| | | month: getYearAndMonthAndDaysZTZB().slice(0, 7), |
| | | name: "", |
| | | departLims: "", |
| | | }, |
| | |
| | | tableLoading: false, |
| | | page: { |
| | | total: 0, |
| | | size: 10, |
| | | size: 20, |
| | | current: 0, |
| | | }, |
| | | }; |
| | |
| | | }, |
| | | refresh() { |
| | | this.queryParams = { |
| | | month: getYearAndMonthAndDays().slice(0, 7), |
| | | month: getYearAndMonthAndDaysZTZB().slice(0, 7), |
| | | name: "", |
| | | departLims: "", |
| | | }; |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .work-time-statistics { |
| | | height: 100%; |
| | | } |
| | | .search { |
| | | background-color: #fff; |
| | | height: 80px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 270px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 60px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 60px); |
| | | } |
| | | .table { |
| | | height: calc(100% - 60px - 80px - 10px - 40px - 25px); |
| | | } |
| | | </style> |
| | |
| | | <template> |
| | | <div class="standard-template"> |
| | | <div class="capacity-scope"> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">模æ¿åç§°ï¼</div> |
| | | <div class="search_input"> |
| | | <div class="search_box"> |
| | | <div class="search_item"> |
| | | <span class="search_label">模æ¿åç§°</span> |
| | | <el-input v-model="queryParams.name" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | @keyup.enter.native="refreshTable()"></el-input> |
| | | </div> |
| | | <div class="search_button"> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px"> |
| | | <el-button size="small" @click="refresh()">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="refreshTable()">æ¥ è¯¢</el-button> |
| | | </div> |
| | | <div class="btn"> |
| | | <div> |
| | | <el-button v-if="checkPermi(['standard:model:add'])" size="small" type="primary" @click="openAdd">æ°å¢</el-button> |
| | | <!-- <el-button |
| | | v-if="checkPermi(['standard:model:copy'])" |
| | | size="small" |
| | | @click="copyTemplate" |
| | | >å¤å¶æ¨¡ç</el-button |
| | | > --> |
| | | </div> |
| | | </div> |
| | | <lims-table :tableData="tableData" :column="column" :page="page" :tableLoading="tableLoading" |
| | | :height="'calc(100vh - 250px)'" style="padding: 20px; padding-top: 0" @pagination="pagination"></lims-table> |
| | | :height="'calc(100vh - 250px)'" @pagination="pagination"></lims-table> |
| | | <el-dialog :before-close="isClose" :close-on-click-modal="false" :close-on-press-escape="false" |
| | | :visible.sync="isShow" title="模æ¿ç¼å¶" width="85%"> |
| | | <div v-if="isShow" style="width: 100%; height: 82vh; overflow: auto"> |
| | |
| | | { label: "模æ¿åç§°", prop: "name" }, |
| | | { label: "夿³¨", prop: "remark" }, |
| | | { label: "åå»ºç¨æ·", prop: "createUserName" }, |
| | | { label: "å建æ¶é´", prop: "createTime" }, |
| | | { label: "å建æ¶é´", prop: "createTime", width: "160" }, |
| | | { label: "æ´æ°ç¨æ·", prop: "updateUserName" }, |
| | | { label: "ä¿®æ¹æ¶é´", prop: "updateTime" }, |
| | | { label: "ä¿®æ¹æ¶é´", prop: "updateTime", width: "160" }, |
| | | { |
| | | dataType: "action", |
| | | fixed: "right", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | |
| | | this.page.size = limit; |
| | | this.getList(); |
| | | }, |
| | | refreshTable(e) { |
| | | refreshTable(event) { |
| | | if (event && typeof event.preventDefault === 'function') { |
| | | event.preventDefault(); // 黿¢é»è®¤è¡ä¸º |
| | | } |
| | | this.page.current = 1; |
| | | this.getList(); |
| | | }, |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | /* >>>.el-dialog__wrapper { |
| | | z-index: 100 !important; |
| | | } */ |
| | | |
| | | .search { |
| | | background-color: #fff; |
| | | height: 80px; |
| | | height: 46px; |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | .search_box { |
| | | display: flex; |
| | | } |
| | | .search_item { |
| | | margin-bottom: 18px; |
| | | margin-right: 10px; |
| | | display: flex; |
| | | align-items: center; |
| | | position: relative; |
| | | line-height: 32px; |
| | | } |
| | | |
| | | .search_thing { |
| | | width: 350px; |
| | | display: flex; |
| | | align-items: center; |
| | | } |
| | | |
| | | .search_label { |
| | | width: 90px; |
| | | width: 88px; |
| | | font-size: 14px; |
| | | text-align: right; |
| | | font-weight: 700; |
| | | color: #606266; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 110px); |
| | | } |
| | | |
| | | .btn { |
| | | position: absolute; |
| | | right: 14px; |
| | | top: 20px; |
| | | .search_button { |
| | | line-height: 26px; |
| | | } |
| | | </style> |
| | |
| | | }; |
| | | }, |
| | | mounted() { |
| | | console.log(22222, this.currentRow); |
| | | this.entity.productListId = this.currentRow.id; |
| | | this.searchTableData(); |
| | | }, |
| | |
| | | >>>.is-disabled .el-textarea__inner { |
| | | background: rgba(0, 0, 0, 0.05) !important; |
| | | } |
| | | |
| | | >>>.el-table__body-wrapper::-webkit-scrollbar { |
| | | height: 14px; |
| | | /* 设置æ»å¨æ¡å®½åº¦ */ |
| | | } |
| | | </style> |
| | | <style scoped> |
| | | .standard .el-tree-node__content { |
¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <div> |
| | | <lims-table :tableData="tableData" :column="column" |
| | | :height="'calc(100vh - 500px)'" @pagination="pagination" |
| | | :rowClick="rowClick" |
| | | :page="page" :tableLoading="tableLoading"></lims-table> |
| | | </div> |
| | | <div> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <div class="inspection-card"> |
| | | <div class="title">æ£éªé¡¹åå·®é¢è¦æ°æ®è¯¦æ
</div> |
| | | <Echarts ref="chart" |
| | | :chartStyle="chartStyle" |
| | | :grid="grid" |
| | | :options="echartsOptions" |
| | | :series="echartsSeries" |
| | | :tooltip="tooltip" |
| | | :xAxis="xAxis" |
| | | :yAxis="yAxis" |
| | | style="height: 40vh;"></Echarts> |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <el-dialog :visible.sync="viewDia" title="æ¥ç详æ
" width="1100px"> |
| | | <lims-table :tableData="tableData1" :column="column1" |
| | | height="570" |
| | | :tableLoading="tableLoading1"></lims-table> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import {selectDeviationWarning, selectDeviationWarningPage} from "@/api/statisticalCharts/dataAnalysis"; |
| | | import Echarts from "@/components/echarts/echarts.vue"; |
| | | |
| | | export default { |
| | | name: '', |
| | | // import å¼å
¥çç»ä»¶éè¦æ³¨å
¥å°å¯¹è±¡ä¸æè½ä½¿ç¨ |
| | | components: {Echarts, limsTable}, |
| | | data() { |
| | | // è¿éåæ¾æ°æ® |
| | | return { |
| | | viewDia: false, |
| | | queryParams: {}, |
| | | tableData: [], |
| | | tableLoading: false, |
| | | column: [ |
| | | { label: 'æ ·åç¼å·', prop: 'sampleCode',width: 150 }, |
| | | { label: 'æ ·ååç§°', prop: 'sampleName'}, |
| | | { label: 'åå·', prop: 'sampleModel',width: 150 }, |
| | | { label: 'ä¾åºååç§°', prop: 'supplierName',width: 150 }, |
| | | { label: 'æ£éªé¡¹åç§°', prop: 'inspectionItemName'}, |
| | | { |
| | | label: "åå·®å¼%", |
| | | prop: "deviationValue", |
| | | width: 150, |
| | | dataType: "tag", |
| | | formatType: (params) => { |
| | | return 'danger' |
| | | }, |
| | | }, |
| | | { label: 'æ£æµæ¶é´', prop: 'detectionTime',width: 160 }, |
| | | { |
| | | dataType: 'action', |
| | | label: 'æä½', |
| | | operation: [ |
| | | { |
| | | name: 'æ¥ç', |
| | | type: 'text', |
| | | clickFun: (row) => { |
| | | this.openDia(row); |
| | | }, |
| | | } |
| | | ] |
| | | } |
| | | ], |
| | | page: { |
| | | total: 0, |
| | | size: 20, |
| | | current: 1 |
| | | }, |
| | | tableData1: [], |
| | | tableLoading1: false, |
| | | column1: [ |
| | | { label: 'æ ·åç¼å·', prop: 'sampleCode'}, |
| | | { label: 'ä¾åºååç§°', prop: 'supplierName'}, |
| | | { |
| | | label: "æ£æµå¼", |
| | | prop: "testValue", |
| | | width: 150, |
| | | dataType: "tag", |
| | | formatType: (params) => { |
| | | if (this.tableData1.find((m) => m.testValue == params).isIssue == 1) { |
| | | return 'danger' |
| | | } else { |
| | | return 'success' |
| | | } |
| | | }, |
| | | }, |
| | | { label: 'æ£æµæ¶é´', prop: 'detectionTime',width: 160 }, |
| | | ], |
| | | chartStyle: { |
| | | width: '100%', |
| | | height: '96%' // 设置å¾è¡¨å®¹å¨çé«åº¦ |
| | | }, |
| | | grid: { |
| | | left: '3%', |
| | | right: '4%', |
| | | bottom: '3%', |
| | | containLabel: true |
| | | }, |
| | | tooltip: {}, |
| | | echartsOptions: {}, |
| | | echartsSeries: [ |
| | | { |
| | | name: 'æ£æµå¼', |
| | | type: 'line', |
| | | smooth: true, |
| | | tooltip: { |
| | | valueFormatter: function (value) { |
| | | return value; |
| | | } |
| | | }, |
| | | label: { |
| | | show: true, |
| | | position: 'top', |
| | | formatter: function (value) { |
| | | return value.value; |
| | | }, |
| | | distance: 14 |
| | | }, |
| | | data: [], |
| | | markArea: {}, |
| | | markPoint: {} |
| | | }, |
| | | ], |
| | | xAxis: [ |
| | | { |
| | | type: 'category', |
| | | data: [], |
| | | boundaryGap: false, |
| | | axisLabel: { |
| | | interval: 0, // å¼ºå¶æ¾ç¤ºæææ ç¾ |
| | | rotate: 0, // ä¸æè½¬ï¼å¯ä»¥æ ¹æ®éè¦è°æ´ï¼ |
| | | formatter: function (value) { |
| | | // æ¯éä¸å®é¿åº¦æ·»å æ¢è¡ç¬¦ |
| | | const maxLength = 9; // æ¯æ®µæå¤§åç¬¦æ° |
| | | let result = ''; |
| | | for (let i = 0; i < value.length; i += maxLength) { |
| | | result += value.substring(i, i + maxLength) + '\n'; |
| | | } |
| | | return result.trim(); // 廿æ«å°¾å¤ä½çæ¢è¡ç¬¦ |
| | | }, |
| | | margin: 10, // æ ç¾ä¸è½´çº¿çè·ç¦» |
| | | }, |
| | | } |
| | | ], |
| | | yAxis: [{ |
| | | type: 'value', |
| | | axisLabel: { |
| | | formatter: '{value}' |
| | | } |
| | | }], |
| | | }; |
| | | }, |
| | | mounted() { |
| | | this.refreshTable() |
| | | }, |
| | | // æ¹æ³éå |
| | | methods: { |
| | | // æ¥è¯¢åè¡¨ä¿¡æ¯ |
| | | refreshTable() { |
| | | this.tableLoading = true |
| | | selectDeviationWarningPage({ ...this.page}).then(res => { |
| | | this.tableLoading = false |
| | | this.tableData = res.data.records |
| | | this.page.total = res.data.total |
| | | }).catch(err => { |
| | | this.tableLoading = false |
| | | }) |
| | | }, |
| | | // æ¥è¯¢æçº¿å¾ä¿¡æ¯ |
| | | rowClick (row) { |
| | | selectDeviationWarning({deviationWarningId: row.deviationWarningId}).then(res => { |
| | | console.log('res---', res) |
| | | if (res.data === null) { |
| | | this.$message.warning('ææ æ°æ®') |
| | | return |
| | | } |
| | | let lineData = [] |
| | | let xAxis = [] |
| | | let markAreas = []; // åå¨ markArea çæ°ç» |
| | | let markPoints = []; |
| | | const sampleCodeCount = {}; |
| | | res.data.forEach((item, index) => { |
| | | lineData.push(item.testValue) |
| | | // æ·»å ç´¢å¼ä»¥ç¡®ä¿å¯ä¸æ§ |
| | | // æ£æ¥æ¯å¦éè¦åºå sampleCode |
| | | if (!sampleCodeCount[item.sampleCode]) { |
| | | sampleCodeCount[item.sampleCode] = 1; // ç¬¬ä¸æ¬¡åºç° |
| | | xAxis.push(item.sampleCode); // ç´æ¥ä½¿ç¨åå§ sampleCode |
| | | } else { |
| | | sampleCodeCount[item.sampleCode]++; // å¢å è®¡æ° |
| | | const uniqueSampleCode = `${item.sampleCode}-${sampleCodeCount[item.sampleCode]}`; |
| | | xAxis.push(uniqueSampleCode); // æ·»å åç¼ä»¥åºå |
| | | } |
| | | |
| | | // 妿 isIssue 为 1ï¼å卿¤ç´¢å¼å¤æ·»å ä¸ä¸ª markArea |
| | | if (item.isIssue == 1) { |
| | | const startColumn = index > 0 ? xAxis[index - 1] : xAxis[index]; // èµ·ç¹ï¼åä¸åæå½åå |
| | | const endColumn = xAxis[index]; // ç»ç¹ï¼å½åå |
| | | |
| | | markAreas.push([ |
| | | { |
| | | xAxis: startColumn, // ä»åä¸åå¼å§ |
| | | }, |
| | | { |
| | | xAxis: endColumn, // å°å½ååç»æ |
| | | } |
| | | ]); |
| | | markPoints.push({ |
| | | name: 'é®é¢ç¹', |
| | | coord: [item.sampleCode, item.testValue], |
| | | value: item.testValue, |
| | | itemStyle: { |
| | | color: 'rgba(255, 173, 177, 0.8)' |
| | | }, |
| | | label: { |
| | | show: true, |
| | | formatter: function(params) { |
| | | return params.value; // èªå®ä¹æ ç¾å
容 |
| | | }, |
| | | color: 'black', // æ ç¾æåé¢è² |
| | | fontSize: 12, |
| | | distance: 5, // è°æ´æ ç¾ä¸æ°æ³¡çè·ç¦» |
| | | padding: [0,0], |
| | | backgroundColor: 'rgba(255, 173, 177, 0.8)', // æ ç¾èæ¯è²åéæåº¦ |
| | | borderRadius: 4 |
| | | } |
| | | }); |
| | | } |
| | | }) |
| | | this.xAxis[0].data = xAxis |
| | | this.echartsSeries[0].data = lineData |
| | | // æ´æ° markArea é
ç½® |
| | | this.echartsSeries[0].markArea = { |
| | | itemStyle: { |
| | | color: 'rgba(255, 173, 177, 0.4)' // è®¾ç½®èæ¯é¢è² |
| | | }, |
| | | data: markAreas // 卿çæç markArea æ°æ® |
| | | }; |
| | | this.echartsSeries[0].markPoint = { |
| | | data: markPoints |
| | | }; |
| | | }) |
| | | }, |
| | | // éç½® |
| | | refresh() { |
| | | // this.resetForm('entity') |
| | | this.refreshTable() |
| | | }, |
| | | // å页忢 |
| | | pagination(page) { |
| | | this.page.size = page.limit |
| | | this.refreshTable() |
| | | }, |
| | | openDia (row) { |
| | | this.viewDia = true |
| | | this.tableLoading1 = true |
| | | selectDeviationWarning({deviationWarningId: row.deviationWarningId}).then(res => { |
| | | this.tableLoading1 = false |
| | | this.tableData1 = res.data |
| | | }).catch(() => { |
| | | this.tableLoading1 = false |
| | | }) |
| | | }, |
| | | } |
| | | }; |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .inspection-card{ |
| | | width: 100%; |
| | | margin-top: 10px; |
| | | } |
| | | </style> |
| | |
| | | v-model="itemParameterForm.inspectionItemSubclass" @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ£éªå¯¹è±¡" prop="sample"> |
| | | <el-form-item label="æ£éªå¯¹è±¡" prop="sample" v-if="radio===0"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="itemParameterForm.sample" @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="æ£éªå¯¹è±¡" prop="specimenName" v-if="radio===1"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="itemParameterForm.specimenName" @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item label="é¶ä»¶å·" prop="partNo" v-if="radio===1"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable |
| | | v-model="itemParameterForm.partNo" @keyup.enter.native="refreshTable()"> |
| | | </el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <!-- æ£éªé¡¹ç®åæ°è¡¨æ ¼--> |
| | |
| | | itemParameterForm: { |
| | | inspectionItem: null, |
| | | inspectionItemSubclass: null, |
| | | sample: null |
| | | sample: null, |
| | | specimenName: null, |
| | | partNo: null |
| | | }, |
| | | radio: 0, |
| | | productLoad: false, |
| | |
| | | total:0, |
| | | size:10, |
| | | current:1, |
| | | partNo: null, |
| | | layout: 'total, prev, pager, next' |
| | | }, |
| | | productableLoading: false, |
| | |
| | | this.diaProduct = true |
| | | this.objectId = row.id |
| | | this.productPage.current = 1 |
| | | this.productPage.partNo = this.itemParameterForm.partNo |
| | | this.getProductList(row) |
| | | }, |
| | | // æ¥è¯¢äº§åç»´æ¤åè¡¨æ°æ® |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12" v-if="editForm.inspectionItemType == 1"> |
| | | <el-form-item label="设å¤ç»å®ï¼" prop="deviceId"> |
| | | <el-select v-model="editForm.deviceId" clearable placeholder="è¯·éæ©" |
| | | size="small" style="width: 100%" multiple filterable> |
| | | <el-option v-for="item in equipOptions" :key="item.value" :label="item.label" :value="item.value"> |
| | | {{item.label + ' - ' + item.managementNumber}} |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="æ£éªå¼ç±»åï¼" prop="inspectionValueType"> |
| | | <el-select v-model="editForm.inspectionValueType" clearable placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="ç¹æ®æ è¯ï¼" prop="bsm"> |
| | | <el-select v-model="editForm.bsm" clearable placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="åå§è®°å½æ¨¡æ¿ï¼" prop="templateId"> |
| | | <el-select v-model="editForm.templateId" clearable placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="æ£éªé¡¹åç±»ï¼" prop="inspectionItemClass"> |
| | | <el-input v-model="editForm.inspectionItemClass" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="æ£éªé¡¹åç±»ENï¼" prop="inspectionItemClassEn"> |
| | | <el-input v-model="editForm.inspectionItemClassEn" clearable size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="è¯éªæ¹æ³ï¼" prop="method"> |
| | | <el-select v-model="editForm.method" clearable multiple placeholder="è¯·éæ©" size="small" style="width: 100%"> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="æ¡ä»¶ï¼" prop="radiusList"> |
| | | <el-select v-model="editForm.radiusList" allow-create default-first-option filterable multiple |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | <el-row> |
| | | <el-col :span="12"> |
| | | <el-form-item label="æ¶è´¹æ å(å
/次)ï¼" prop="rates"> |
| | | <el-input v-model="editForm.rates" clearable size="small"></el-input> |
| | |
| | | upItemParameter |
| | | } from "@/api/structural/capability"; |
| | | import {selectStandardMethods} from "@/api/structural/standardMethod"; |
| | | import {search} from "@/api/business/inspectionTask"; |
| | | |
| | | export default { |
| | | name: "EditForm", |
| | |
| | | method: '', // è¯éªæ¹æ³ |
| | | radiusList: [], // æ¡ä»¶ |
| | | rates: '', // æ¡ä»¶ |
| | | deviceId: [], // è®¾å¤ |
| | | }, |
| | | sampleList: [], // æ£éªå¯¹è±¡ä¸ææ¡ |
| | | laboratoryList: [], // åºæä¸ææ¡ |
| | |
| | | { required: true, message: 'è¯·éæ©åå§è®°å½æ¨¡æ¿', trigger: 'change' } |
| | | ] |
| | | }, |
| | | operationType: '' |
| | | operationType: '', |
| | | equipOptions: [] |
| | | } |
| | | }, |
| | | // æ¹æ³éå |
| | |
| | | openDia (type, row) { |
| | | this.operationType = type |
| | | this.editFormDia = true |
| | | this.getEquipOptions() // è·åææè®¾å¤ |
| | | this.obtainItemParameterList() // åºæç±»å |
| | | this.getStandardTemplate() // åå§è®°å½æ¨¡æ¿ä¸ææ¡ |
| | | this.getSelectStandardMethods() // è¯éªæ¹æ³ |
| | |
| | | } else { |
| | | this.editForm = this.HaveJson(row) |
| | | this.editForm.sample = JSON.parse(this.editForm.sample) |
| | | this.editForm.radiusList = JSON.parse(this.editForm.radiusList) |
| | | this.editForm.radiusList = this.editForm.radiusList && JSON.parse(this.editForm.radiusList) |
| | | this.editForm.method = JSON.parse(this.editForm.method) |
| | | const ids = this.editForm.deviceIds && this.editForm.deviceIds.split(",") || []; |
| | | const numericIds = ids.map(Number); |
| | | this.$set(this.editForm, 'deviceId', numericIds); |
| | | } |
| | | }, |
| | | // æäº¤ç¼è¾ |
| | |
| | | obj.radiusList = JSON.stringify(obj.radiusList) |
| | | } else { |
| | | obj.radiusList = null |
| | | } |
| | | if (obj.deviceId?.length > 0) { |
| | | obj.deviceIds = obj.deviceId.join(',') |
| | | } else { |
| | | obj.deviceIds = null |
| | | } |
| | | if(obj.id){ |
| | | // ä¿®æ¹ |
| | |
| | | this.templateIdList = data |
| | | }) |
| | | }, |
| | | // è·åææè®¾å¤ |
| | | getEquipOptions() { |
| | | this.equipOptions = []; |
| | | search({ status: 0 }).then((res) => { |
| | | if (res.code === 200 && res.data) { |
| | | this.equipOptions = res.data.map((m) => { |
| | | m.value = m.id; |
| | | m.label = m.deviceName; |
| | | m.managementNumber = m.managementNumber; |
| | | return m; |
| | | }); |
| | | } |
| | | }).catch((error) => { |
| | | console.error(error); |
| | | }); |
| | | }, |
| | | }, |
| | | } |
| | | </script> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | { label: "å°æé¢åæ¶é´", prop: "expireTime" }, |
| | | { |
| | | dataType: "action", |
| | | fixed: "right", |
| | | label: "æä½", |
| | | operation: [ |
| | | { |
| | |
| | | @keyup.enter.native="refreshTable"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="refreshTable">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="refreshTable">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | { label: 'å建æ¶é´', prop: 'createTime' }, |
| | | { |
| | | dataType: 'action', |
| | | fixed: 'right', |
| | | label: 'æä½', |
| | | width: '180px', |
| | | operation: [ |
| | | { |
| | | name: 'ç¼è¾', |
| | |
| | | ></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <div class="search"> |
| | | <div> |
| | | <el-form :model="queryParams" ref="queryForm" size="small" :inline="true"> |
| | | <el-form-item label="客æ·åç§°" prop="company"> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.company" |
| | | @keyup.enter.native="getList"></el-input> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="getList">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="refresh">é ç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <div style="display: flex;justify-content: space-between"> |
| | | <div class="search_box"> |
| | | <div class="search_item"> |
| | | <span class="search_label">客æ·åç§°</span> |
| | | <el-input size="small" placeholder="请è¾å
¥" clearable v-model="queryParams.company" |
| | | @keyup.enter.native="getList"></el-input> |
| | | </div> |
| | | <div class="search_button"> |
| | | <el-button type="primary" size="mini" @click="getList">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="refresh">éç½®</el-button> |
| | | </div> |
| | | </div> |
| | | <div> |
| | | <el-button size="small" type="primary" @click="openFormDia('add')" icon="el-icon-plus">æ°å¢</el-button> |
| | |
| | | page: { |
| | | total:0, |
| | | size:20, |
| | | current:0 |
| | | current:1 |
| | | }, |
| | | tableLoading: false, |
| | | // ç¼è¾å®¢æ·å¼¹æ¡ |
| | |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .search { |
| | | height: 46px; |
| | | .search_box { |
| | | display: flex; |
| | | justify-content: space-between; |
| | | } |
| | | .search_item { |
| | | margin-bottom: 18px; |
| | | margin-right: 10px; |
| | | display: flex; |
| | | align-items: center; |
| | | line-height: 32px; |
| | | } |
| | | .search_label { |
| | | width: 88px; |
| | | font-size: 14px; |
| | | font-weight: 700; |
| | | color: #606266; |
| | | } |
| | | .search_button { |
| | | line-height: 30px; |
| | | } |
| | | </style> |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | ></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æç´¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">éç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | |
| | | range-separator="-" start-placeholder="å¼å§æ¥æ" end-placeholder="ç»ææ¥æ"></el-date-picker> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <el-row> |
| | |
| | | @keyup.enter.native="handleQuery" /> |
| | | </el-form-item> |
| | | <el-form-item label="ç¶æ" prop="status"> |
| | | <el-select v-model="queryParams.status" placeholder="ç¨æ·ç¶æ" clearable> |
| | | <el-select v-model="queryParams.status" placeholder="ç¨æ·ç¶æ" clearable @change="handleQuery"> |
| | | <el-option v-for="dict in dict.type.sys_normal_disable" :key="dict.value" :label="dict.label" |
| | | :value="dict.value" /> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">æ¥ è¯¢</el-button> |
| | | <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">é ç½®</el-button> |
| | | <el-button type="primary" size="mini" @click="handleQuery">æ¥è¯¢</el-button> |
| | | <el-button size="mini" @click="resetQuery">éç½®</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | </div> |
| | |
| | | <el-col :span="8" style="height: 70vh;overflow: hidden;" v-if="companiesList.length != 1"> |
| | | <el-input v-model="search2" placeholder="è¾å
¥å
³é®åæç´¢" clearable size="small" @clear="searchFilter2" |
| | | @keyup.enter.native="searchFilter2" prefix-icon="el-icon-search" style="margin-bottom: 20px;width: 90%" /> |
| | | <el-tree :data="datathirdParty" node-key="companyId" :props="defaultProps" @node-click="nodeClick2" |
| | | <el-tree :data="datathirdParty" node-key="companyId" :props="defaultProps1" @node-click="nodeClick2" |
| | | style="height: calc(100% - 42px);" @node-expand="nodeOpen0" :filter-node-method="filterNode2" ref="tree2" |
| | | highlight-current> |
| | | </el-tree> |
| | |
| | | </el-table-column> |
| | | <el-table-column prop="employeeID" label="åå·¥å·"> |
| | | </el-table-column> |
| | | <el-table-column prop="nickName" label="åå·¥å§å"> |
| | | <el-table-column prop="name" label="åå·¥å§å"> |
| | | </el-table-column> |
| | | <el-table-column prop="department" label="é¨é¨" min-width="200"> |
| | | </el-table-column> |
| | |
| | | return { |
| | | // é®ç½©å± |
| | | loading: true, |
| | | multipleSelection: [], |
| | | // é䏿°ç» |
| | | ids: [], |
| | | // éå个ç¦ç¨ |
| | |
| | | defaultProps: { |
| | | children: "children", |
| | | label: "label" |
| | | }, |
| | | defaultProps1: { |
| | | children: "children", |
| | | label: "companyName" |
| | | }, |
| | | // ç¨æ·å¯¼å
¥åæ° |
| | | upload: { |
| | |
| | | }, |
| | | // å¤éæ¡é䏿°æ® |
| | | handleSelectionChange(selection) { |
| | | this.multipleSelection = selection; |
| | | this.ids = selection.map(item => item.userId); |
| | | this.single = selection.length != 1; |
| | | this.multiple = !selection.length; |
| | |
| | | } |
| | | }, |
| | | // è·å䏿¹äººå |
| | | openthirdParty() { |
| | | this.addthirdParty = true; |
| | | this.thirdPartyLoading = true; |
| | | selectCompaniesList().then(res => { |
| | | this.companiesList = this.HaveJson(res.data); |
| | | if (this.companiesList.length == 1) { |
| | | selectSimpleList({ companyId: this.companiesList[0].companyId }).then(res => { |
| | | this.thirdPartyLoading = false; |
| | | this.personListCopy = JSON.parse(JSON.stringify(res.data)) |
| | | this.personList = res.data |
| | | this.$refs.personTable.doLayout() |
| | | }) |
| | | } else { |
| | | this.thirdPartyLoading = false; |
| | | async openthirdParty() { |
| | | try { |
| | | this.addthirdParty = true; |
| | | this.thirdPartyLoading = true; |
| | | |
| | | const companiesResponse = await selectCompaniesList(); |
| | | this.companiesList = this.HaveJson(companiesResponse.data); |
| | | |
| | | if (this.companiesList.length === 1) { |
| | | const personResponse = await selectSimpleList({ companyId: this.companiesList[0].companyId }); |
| | | this.personListCopy = JSON.parse(JSON.stringify(personResponse.data)); |
| | | this.personList = personResponse.data; |
| | | this.$refs.personTable.doLayout(); |
| | | } |
| | | this.datathirdParty = this.tranListToTreeData(res.data, "ROOT"); |
| | | }).catch(() => { |
| | | |
| | | this.datathirdParty = this.tranListToTreeData(this.companiesList, "ROOT"); |
| | | console.log(' this.datathirdParty---', this.datathirdParty) |
| | | } catch (error) { |
| | | console.error("Error fetching third party data:", error); |
| | | } finally { |
| | | this.thirdPartyLoading = false; |
| | | }) |
| | | if (this.componentData.entity.roleId > 10000) this.$message.warning('ç±äºæªéä¸å
·ä½è§è²ï¼æ°å¢ç¨æ·å°æä¸ºé»è®¤è§è²') |
| | | } |
| | | }, |
| | | tranListToTreeData(list, rootValue) { |
| | | const arr = []; |
| | | list.forEach((item) => { |
| | | return list.reduce((arr, item) => { |
| | | if (item.parentCompanyId === rootValue) { |
| | | const children = this.tranListToTreeData(list, item.companyId); |
| | | if (children.length) { |
| | |
| | | } |
| | | arr.push(item); |
| | | } |
| | | }); |
| | | return arr; |
| | | return arr; |
| | | }, []); |
| | | }, |
| | | searchPerson() { |
| | | let arr = JSON.parse(JSON.stringify(this.personListCopy)) |
| | |
| | | } |
| | | }, |
| | | nodeOpen0(data, node, el) { |
| | | this.currentCompaniesList[node.level - nodeOpen01] = data.id |
| | | // this.currentCompaniesList[node.level - nodeOpen01] = data.id |
| | | }, |
| | | filterNode2(value, data) { |
| | | if (!value) return true; |
| | |
| | | addPersonUser({ |
| | | company: arr, |
| | | person: this.multipleSelection, |
| | | roleId: this.componentData.entity.roleId |
| | | // roleId: this.componentData.entity.roleId |
| | | }).then(res => { |
| | | this.$message.success('æä½æå') |
| | | this.multipleSelection = [] |
| | | this.$refs.personTable.clearSelection() |
| | | this.addLoad = false |
| | | this.addthirdParty = false |
| | | this.userSearch2 = '' |
| | | this.getList() |
| | | }).catch(e => { |
| | |
| | | export default { |
| | | data() { |
| | | return { |
| | | SSO: window.location.hash |
| | | } |
| | | }; |
| | | }, |
| | | created() { |
| | | this.initLogin() |
| | | console.log(this.SSO) |
| | | this.initLogin(); |
| | | }, |
| | | methods: { |
| | | initLogin() { |
| | | const code = this.SSO.split('&')[0].split('=')[1] |
| | | console.log(code) |
| | | |
| | | if (code) { |
| | | this.$store.dispatch('LoginBySSO', code).then(() => { |
| | | this.$router.push({ path: '/' }) |
| | | }) |
| | | } |
| | | this.$store.dispatch('LoginBySSO', {code: this.$route.query.code}).then(() => { |
| | | this.$router.push({path: '/'}); |
| | | }); |
| | | } |
| | | } |
| | | } |
| | | }; |
| | | </script> |
| | | <style scoped></style> |
| | | <style scoped></style> |
ÎļþÃû´Ó src/DataWorker.worker.js ÐÞ¸Ä |
| | |
| | | if(i+1==arr[1]){ |
| | | // èµå¼æ°éä¼åæ£éªé¡¹å表 |
| | | arrSpecial.push(n.i) |
| | | setTimeout(()=>{ |
| | | let num0 = 0 |
| | | if(n.v.ct&&n.v.ct.fa&&typeof n.v.ct.fa == 'string'&&n.v.ct.fa.includes('.')){ |
| | | // ä¿ç模æ¿é
ç½®çå°æ°ç¹ä½æ° |
| | | let str0 = n.v.ct.fa.split('.')[1] |
| | | num0 = str0.length |
| | | n.v.v = dataAcquisitionInfo[str].value[i]?Number(dataAcquisitionInfo[str].value[i]).toFixed(num0):dataAcquisitionInfo[str].value[i] |
| | | }else{ |
| | | // ç´æ¥èµå¼ |
| | | n.v.v = dataAcquisitionInfo[str].value[i] |
| | | let num0 = 0 |
| | | if(n.v.ct&&n.v.ct.fa&&typeof n.v.ct.fa == 'string'&&n.v.ct.fa.includes('.')){ |
| | | // ä¿ç模æ¿é
ç½®çå°æ°ç¹ä½æ° |
| | | let str0 = n.v.ct.fa.split('.')[1] |
| | | num0 = str0.length |
| | | n.v.v = dataAcquisitionInfo[str].value[i]?Number(dataAcquisitionInfo[str].value[i]).toFixed(num0):dataAcquisitionInfo[str].value[i] |
| | | }else{ |
| | | // ç´æ¥èµå¼ |
| | | n.v.v = dataAcquisitionInfo[str].value[i] |
| | | } |
| | | // ä¼ éç»ä¸»çº¿ç¨ |
| | | result = { |
| | | method:'changeInput', |
| | | value:{ |
| | | list:list, |
| | | n:n |
| | | } |
| | | // ä¼ éç»ä¸»çº¿ç¨ |
| | | result = { |
| | | method:'changeInput', |
| | | value:{ |
| | | list:list, |
| | | n:n |
| | | } |
| | | } |
| | | self.postMessage(JSON.stringify(result)) |
| | | },2000) |
| | | } |
| | | self.postMessage(JSON.stringify(result)) |
| | | } |
| | | } |
| | | }else{ |
ÎļþÃû´Ó src/InspectionWorker.worker.js ÐÞ¸Ä |
| | |
| | | // å¤çº¿ç¨éé¢éè¦ä¿åçæ°æ® |
| | | import Big from "big.js"; |
| | | |
| | | let code = ""; |
| | | // è¡¨æ ¼æ°æ®ï¼æ¸²æï¼ |
| | | let tableList = null; |
| | |
| | | console.log("error", error); |
| | | } |
| | | } |
| | | |
| | | /* |
| | | * big.js v5.2.2 |
| | | * A small, fast, easy-to-use library for arbitrary-precision decimal arithmetic. |
| | | * Copyright (c) 2018 Michael Mclaughlin <M8ch88l@gmail.com> |
| | | * https://github.com/MikeMcl/big.js/LICENCE |
| | | */ |
| | | (function (GLOBAL) { |
| | | "use strict"; |
| | | var Big, |
| | | /************************************** EDITABLE DEFAULTS *****************************************/ |
| | | |
| | | // The default values below must be integers within the stated ranges. |
| | | |
| | | /* |
| | | * The maximum number of decimal places (DP) of the results of operations involving division: |
| | | * div and sqrt, and pow with negative exponents. |
| | | */ |
| | | DP = 20, // 0 to MAX_DP |
| | | /* |
| | | * The rounding mode (RM) used when rounding to the above decimal places. |
| | | * |
| | | * 0 Towards zero (i.e. truncate, no rounding). (ROUND_DOWN) |
| | | * 1 To nearest neighbour. If equidistant, round up. (ROUND_HALF_UP) |
| | | * 2 To nearest neighbour. If equidistant, to even. (ROUND_HALF_EVEN) |
| | | * 3 Away from zero. (ROUND_UP) |
| | | */ |
| | | RM = 1, // 0, 1, 2 or 3 |
| | | // The maximum value of DP and Big.DP. |
| | | MAX_DP = 1e6, // 0 to 1000000 |
| | | // The maximum magnitude of the exponent argument to the pow method. |
| | | MAX_POWER = 1e6, // 1 to 1000000 |
| | | /* |
| | | * The negative exponent (NE) at and beneath which toString returns exponential notation. |
| | | * (JavaScript numbers: -7) |
| | | * -1000000 is the minimum recommended exponent value of a Big. |
| | | */ |
| | | NE = -7, // 0 to -1000000 |
| | | /* |
| | | * The positive exponent (PE) at and above which toString returns exponential notation. |
| | | * (JavaScript numbers: 21) |
| | | * 1000000 is the maximum recommended exponent value of a Big. |
| | | * (This limit is not enforced or checked.) |
| | | */ |
| | | PE = 21, // 0 to 1000000 |
| | | /**************************************************************************************************/ |
| | | |
| | | // Error messages. |
| | | NAME = "[big.js] ", |
| | | INVALID = NAME + "Invalid ", |
| | | INVALID_DP = INVALID + "decimal places", |
| | | INVALID_RM = INVALID + "rounding mode", |
| | | DIV_BY_ZERO = NAME + "Division by zero", |
| | | // The shared prototype object. |
| | | P = {}, |
| | | UNDEFINED = void 0, |
| | | NUMERIC = /^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i; |
| | | |
| | | /* |
| | | * Create and return a Big constructor. |
| | | * |
| | | */ |
| | | function _Big_() { |
| | | /* |
| | | * The Big constructor and exported function. |
| | | * Create and return a new instance of a Big number object. |
| | | * |
| | | * n {number|string|Big} A numeric value. |
| | | */ |
| | | function Big(n) { |
| | | var x = this; |
| | | |
| | | // Enable constructor usage without new. |
| | | if (!(x instanceof Big)) return n === UNDEFINED ? _Big_() : new Big(n); |
| | | |
| | | // Duplicate. |
| | | if (n instanceof Big) { |
| | | x.s = n.s; |
| | | x.e = n.e; |
| | | x.c = n.c.slice(); |
| | | } else { |
| | | parse(x, n); |
| | | } |
| | | |
| | | /* |
| | | * Retain a reference to this Big constructor, and shadow Big.prototype.constructor which |
| | | * points to Object. |
| | | */ |
| | | x.constructor = Big; |
| | | } |
| | | |
| | | Big.prototype = P; |
| | | Big.DP = DP; |
| | | Big.RM = RM; |
| | | Big.NE = NE; |
| | | Big.PE = PE; |
| | | Big.version = "5.2.2"; |
| | | |
| | | return Big; |
| | | } |
| | | |
| | | /* |
| | | * Parse the number or string value passed to a Big constructor. |
| | | * |
| | | * x {Big} A Big number instance. |
| | | * n {number|string} A numeric value. |
| | | */ |
| | | function parse(x, n) { |
| | | var e, i, nl; |
| | | |
| | | // Minus zero? |
| | | if (n === 0 && 1 / n < 0) n = "-0"; |
| | | else if (!NUMERIC.test((n += ""))) throw Error(INVALID + "number"); |
| | | |
| | | // Determine sign. |
| | | x.s = n.charAt(0) == "-" ? ((n = n.slice(1)), -1) : 1; |
| | | |
| | | // Decimal point? |
| | | if ((e = n.indexOf(".")) > -1) n = n.replace(".", ""); |
| | | |
| | | // Exponential form? |
| | | if ((i = n.search(/e/i)) > 0) { |
| | | // Determine exponent. |
| | | if (e < 0) e = i; |
| | | e += +n.slice(i + 1); |
| | | n = n.substring(0, i); |
| | | } else if (e < 0) { |
| | | // Integer. |
| | | e = n.length; |
| | | } |
| | | |
| | | nl = n.length; |
| | | |
| | | // Determine leading zeros. |
| | | for (i = 0; i < nl && n.charAt(i) == "0"; ) ++i; |
| | | |
| | | if (i == nl) { |
| | | // Zero. |
| | | x.c = [(x.e = 0)]; |
| | | } else { |
| | | // Determine trailing zeros. |
| | | for (; nl > 0 && n.charAt(--nl) == "0"; ); |
| | | x.e = e - i - 1; |
| | | x.c = []; |
| | | |
| | | // Convert string to array of digits without leading/trailing zeros. |
| | | for (e = 0; i <= nl; ) x.c[e++] = +n.charAt(i++); |
| | | } |
| | | |
| | | return x; |
| | | } |
| | | |
| | | /* |
| | | * Round Big x to a maximum of dp decimal places using rounding mode rm. |
| | | * Called by stringify, P.div, P.round and P.sqrt. |
| | | * |
| | | * x {Big} The Big to round. |
| | | * dp {number} Integer, 0 to MAX_DP inclusive. |
| | | * rm {number} 0, 1, 2 or 3 (DOWN, HALF_UP, HALF_EVEN, UP) |
| | | * [more] {boolean} Whether the result of division was truncated. |
| | | */ |
| | | function round(x, dp, rm, more) { |
| | | var xc = x.c, |
| | | i = x.e + dp + 1; |
| | | |
| | | if (i < xc.length) { |
| | | if (rm === 1) { |
| | | // xc[i] is the digit after the digit that may be rounded up. |
| | | more = xc[i] >= 5; |
| | | } else if (rm === 2) { |
| | | more = |
| | | xc[i] > 5 || |
| | | (xc[i] == 5 && |
| | | (more || i < 0 || xc[i + 1] !== UNDEFINED || xc[i - 1] & 1)); |
| | | } else if (rm === 3) { |
| | | more = more || !!xc[0]; |
| | | } else { |
| | | more = false; |
| | | if (rm !== 0) throw Error(INVALID_RM); |
| | | } |
| | | |
| | | if (i < 1) { |
| | | xc.length = 1; |
| | | |
| | | if (more) { |
| | | // 1, 0.1, 0.01, 0.001, 0.0001 etc. |
| | | x.e = -dp; |
| | | xc[0] = 1; |
| | | } else { |
| | | // Zero. |
| | | xc[0] = x.e = 0; |
| | | } |
| | | } else { |
| | | // Remove any digits after the required decimal places. |
| | | xc.length = i--; |
| | | |
| | | // Round up? |
| | | if (more) { |
| | | // Rounding up may mean the previous digit has to be rounded up. |
| | | for (; ++xc[i] > 9; ) { |
| | | xc[i] = 0; |
| | | if (!i--) { |
| | | ++x.e; |
| | | xc.unshift(1); |
| | | } |
| | | } |
| | | } |
| | | |
| | | // Remove trailing zeros. |
| | | for (i = xc.length; !xc[--i]; ) xc.pop(); |
| | | } |
| | | } else if (rm < 0 || rm > 3 || rm !== ~~rm) { |
| | | throw Error(INVALID_RM); |
| | | } |
| | | |
| | | return x; |
| | | } |
| | | |
| | | /* |
| | | * Return a string representing the value of Big x in normal or exponential notation. |
| | | * Handles P.toExponential, P.toFixed, P.toJSON, P.toPrecision, P.toString and P.valueOf. |
| | | * |
| | | * x {Big} |
| | | * id? {number} Caller id. |
| | | * 1 toExponential |
| | | * 2 toFixed |
| | | * 3 toPrecision |
| | | * 4 valueOf |
| | | * n? {number|undefined} Caller's argument. |
| | | * k? {number|undefined} |
| | | */ |
| | | function stringify(x, id, n, k) { |
| | | var e, |
| | | s, |
| | | Big = x.constructor, |
| | | z = !x.c[0]; |
| | | |
| | | if (n !== UNDEFINED) { |
| | | if (n !== ~~n || n < (id == 3) || n > MAX_DP) { |
| | | throw Error(id == 3 ? INVALID + "precision" : INVALID_DP); |
| | | } |
| | | |
| | | x = new Big(x); |
| | | |
| | | // The index of the digit that may be rounded up. |
| | | n = k - x.e; |
| | | |
| | | // Round? |
| | | if (x.c.length > ++k) round(x, n, Big.RM); |
| | | |
| | | // toFixed: recalculate k as x.e may have changed if value rounded up. |
| | | if (id == 2) k = x.e + n + 1; |
| | | |
| | | // Append zeros? |
| | | for (; x.c.length < k; ) x.c.push(0); |
| | | } |
| | | |
| | | e = x.e; |
| | | s = x.c.join(""); |
| | | n = s.length; |
| | | |
| | | // Exponential notation? |
| | | if ( |
| | | id != 2 && |
| | | (id == 1 || (id == 3 && k <= e) || e <= Big.NE || e >= Big.PE) |
| | | ) { |
| | | s = |
| | | s.charAt(0) + |
| | | (n > 1 ? "." + s.slice(1) : "") + |
| | | (e < 0 ? "e" : "e+") + |
| | | e; |
| | | |
| | | // Normal notation. |
| | | } else if (e < 0) { |
| | | for (; ++e; ) s = "0" + s; |
| | | s = "0." + s; |
| | | } else if (e > 0) { |
| | | if (++e > n) for (e -= n; e--; ) s += "0"; |
| | | else if (e < n) s = s.slice(0, e) + "." + s.slice(e); |
| | | } else if (n > 1) { |
| | | s = s.charAt(0) + "." + s.slice(1); |
| | | } |
| | | |
| | | return x.s < 0 && (!z || id == 4) ? "-" + s : s; |
| | | } |
| | | |
| | | // Prototype/instance methods |
| | | |
| | | /* |
| | | * Return a new Big whose value is the absolute value of this Big. |
| | | */ |
| | | P.abs = function () { |
| | | var x = new this.constructor(this); |
| | | x.s = 1; |
| | | return x; |
| | | }; |
| | | |
| | | /* |
| | | * Return 1 if the value of this Big is greater than the value of Big y, |
| | | * -1 if the value of this Big is less than the value of Big y, or |
| | | * 0 if they have the same value. |
| | | */ |
| | | P.cmp = function (y) { |
| | | var isneg, |
| | | x = this, |
| | | xc = x.c, |
| | | yc = (y = new x.constructor(y)).c, |
| | | i = x.s, |
| | | j = y.s, |
| | | k = x.e, |
| | | l = y.e; |
| | | |
| | | // Either zero? |
| | | if (!xc[0] || !yc[0]) return !xc[0] ? (!yc[0] ? 0 : -j) : i; |
| | | |
| | | // Signs differ? |
| | | if (i != j) return i; |
| | | |
| | | isneg = i < 0; |
| | | |
| | | // Compare exponents. |
| | | if (k != l) return (k > l) ^ isneg ? 1 : -1; |
| | | |
| | | j = (k = xc.length) < (l = yc.length) ? k : l; |
| | | |
| | | // Compare digit by digit. |
| | | for (i = -1; ++i < j; ) { |
| | | if (xc[i] != yc[i]) return (xc[i] > yc[i]) ^ isneg ? 1 : -1; |
| | | } |
| | | |
| | | // Compare lengths. |
| | | return k == l ? 0 : (k > l) ^ isneg ? 1 : -1; |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the value of this Big divided by the value of Big y, rounded, |
| | | * if necessary, to a maximum of Big.DP decimal places using rounding mode Big.RM. |
| | | */ |
| | | P.div = function (y) { |
| | | var x = this, |
| | | Big = x.constructor, |
| | | a = x.c, // dividend |
| | | b = (y = new Big(y)).c, // divisor |
| | | k = x.s == y.s ? 1 : -1, |
| | | dp = Big.DP; |
| | | |
| | | if (dp !== ~~dp || dp < 0 || dp > MAX_DP) throw Error(INVALID_DP); |
| | | |
| | | // Divisor is zero? |
| | | if (!b[0]) throw Error(DIV_BY_ZERO); |
| | | |
| | | // Dividend is 0? Return +-0. |
| | | if (!a[0]) return new Big(k * 0); |
| | | |
| | | var bl, |
| | | bt, |
| | | n, |
| | | cmp, |
| | | ri, |
| | | bz = b.slice(), |
| | | ai = (bl = b.length), |
| | | al = a.length, |
| | | r = a.slice(0, bl), // remainder |
| | | rl = r.length, |
| | | q = y, // quotient |
| | | qc = (q.c = []), |
| | | qi = 0, |
| | | d = dp + (q.e = x.e - y.e) + 1; // number of digits of the result |
| | | |
| | | q.s = k; |
| | | k = d < 0 ? 0 : d; |
| | | |
| | | // Create version of divisor with leading zero. |
| | | bz.unshift(0); |
| | | |
| | | // CommunicateAdd zeros to make remainder as long as divisor. |
| | | for (; rl++ < bl; ) r.push(0); |
| | | |
| | | do { |
| | | // n is how many times the divisor goes into current remainder. |
| | | for (n = 0; n < 10; n++) { |
| | | // Compare divisor and remainder. |
| | | if (bl != (rl = r.length)) { |
| | | cmp = bl > rl ? 1 : -1; |
| | | } else { |
| | | for (ri = -1, cmp = 0; ++ri < bl; ) { |
| | | if (b[ri] != r[ri]) { |
| | | cmp = b[ri] > r[ri] ? 1 : -1; |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | |
| | | // If divisor < remainder, subtract divisor from remainder. |
| | | if (cmp < 0) { |
| | | // Remainder can't be more than 1 digit longer than divisor. |
| | | // Equalise lengths using divisor with extra leading zero? |
| | | for (bt = rl == bl ? b : bz; rl; ) { |
| | | if (r[--rl] < bt[rl]) { |
| | | ri = rl; |
| | | for (; ri && !r[--ri]; ) r[ri] = 9; |
| | | --r[ri]; |
| | | r[rl] += 10; |
| | | } |
| | | r[rl] -= bt[rl]; |
| | | } |
| | | |
| | | for (; !r[0]; ) r.shift(); |
| | | } else { |
| | | break; |
| | | } |
| | | } |
| | | |
| | | // CommunicateAdd the digit n to the result array. |
| | | qc[qi++] = cmp ? n : ++n; |
| | | |
| | | // Update the remainder. |
| | | if (r[0] && cmp) r[rl] = a[ai] || 0; |
| | | else r = [a[ai]]; |
| | | } while ((ai++ < al || r[0] !== UNDEFINED) && k--); |
| | | |
| | | // Leading zero? Do not remove if result is simply zero (qi == 1). |
| | | if (!qc[0] && qi != 1) { |
| | | // There can't be more than one zero. |
| | | qc.shift(); |
| | | q.e--; |
| | | } |
| | | |
| | | // Round? |
| | | if (qi > d) round(q, dp, Big.RM, r[0] !== UNDEFINED); |
| | | |
| | | return q; |
| | | }; |
| | | |
| | | /* |
| | | * Return true if the value of this Big is equal to the value of Big y, otherwise return false. |
| | | */ |
| | | P.eq = function (y) { |
| | | return !this.cmp(y); |
| | | }; |
| | | |
| | | /* |
| | | * Return true if the value of this Big is greater than the value of Big y, otherwise return |
| | | * false. |
| | | */ |
| | | P.gt = function (y) { |
| | | return this.cmp(y) > 0; |
| | | }; |
| | | |
| | | /* |
| | | * Return true if the value of this Big is greater than or equal to the value of Big y, otherwise |
| | | * return false. |
| | | */ |
| | | P.gte = function (y) { |
| | | return this.cmp(y) > -1; |
| | | }; |
| | | |
| | | /* |
| | | * Return true if the value of this Big is less than the value of Big y, otherwise return false. |
| | | */ |
| | | P.lt = function (y) { |
| | | return this.cmp(y) < 0; |
| | | }; |
| | | |
| | | /* |
| | | * Return true if the value of this Big is less than or equal to the value of Big y, otherwise |
| | | * return false. |
| | | */ |
| | | P.lte = function (y) { |
| | | return this.cmp(y) < 1; |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the value of this Big minus the value of Big y. |
| | | */ |
| | | P.minus = P.sub = function (y) { |
| | | var i, |
| | | j, |
| | | t, |
| | | xlty, |
| | | x = this, |
| | | Big = x.constructor, |
| | | a = x.s, |
| | | b = (y = new Big(y)).s; |
| | | |
| | | // Signs differ? |
| | | if (a != b) { |
| | | y.s = -b; |
| | | return x.plus(y); |
| | | } |
| | | |
| | | var xc = x.c.slice(), |
| | | xe = x.e, |
| | | yc = y.c, |
| | | ye = y.e; |
| | | |
| | | // Either zero? |
| | | if (!xc[0] || !yc[0]) { |
| | | // y is non-zero? x is non-zero? Or both are zero. |
| | | return yc[0] ? ((y.s = -b), y) : new Big(xc[0] ? x : 0); |
| | | } |
| | | |
| | | // Determine which is the bigger number. Prepend zeros to equalise exponents. |
| | | if ((a = xe - ye)) { |
| | | if ((xlty = a < 0)) { |
| | | a = -a; |
| | | t = xc; |
| | | } else { |
| | | ye = xe; |
| | | t = yc; |
| | | } |
| | | |
| | | t.reverse(); |
| | | for (b = a; b--; ) t.push(0); |
| | | t.reverse(); |
| | | } else { |
| | | // Exponents equal. Check digit by digit. |
| | | j = ((xlty = xc.length < yc.length) ? xc : yc).length; |
| | | |
| | | for (a = b = 0; b < j; b++) { |
| | | if (xc[b] != yc[b]) { |
| | | xlty = xc[b] < yc[b]; |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | |
| | | // x < y? Point xc to the array of the bigger number. |
| | | if (xlty) { |
| | | t = xc; |
| | | xc = yc; |
| | | yc = t; |
| | | y.s = -y.s; |
| | | } |
| | | |
| | | /* |
| | | * Append zeros to xc if shorter. No need to add zeros to yc if shorter as subtraction only |
| | | * needs to start at yc.length. |
| | | */ |
| | | if ((b = (j = yc.length) - (i = xc.length)) > 0) for (; b--; ) xc[i++] = 0; |
| | | |
| | | // Subtract yc from xc. |
| | | for (b = i; j > a; ) { |
| | | if (xc[--j] < yc[j]) { |
| | | for (i = j; i && !xc[--i]; ) xc[i] = 9; |
| | | --xc[i]; |
| | | xc[j] += 10; |
| | | } |
| | | |
| | | xc[j] -= yc[j]; |
| | | } |
| | | |
| | | // Remove trailing zeros. |
| | | for (; xc[--b] === 0; ) xc.pop(); |
| | | |
| | | // Remove leading zeros and adjust exponent accordingly. |
| | | for (; xc[0] === 0; ) { |
| | | xc.shift(); |
| | | --ye; |
| | | } |
| | | |
| | | if (!xc[0]) { |
| | | // n - n = +0 |
| | | y.s = 1; |
| | | |
| | | // Result must be zero. |
| | | xc = [(ye = 0)]; |
| | | } |
| | | |
| | | y.c = xc; |
| | | y.e = ye; |
| | | |
| | | return y; |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the value of this Big modulo the value of Big y. |
| | | */ |
| | | P.mod = function (y) { |
| | | var ygtx, |
| | | x = this, |
| | | Big = x.constructor, |
| | | a = x.s, |
| | | b = (y = new Big(y)).s; |
| | | |
| | | if (!y.c[0]) throw Error(DIV_BY_ZERO); |
| | | |
| | | x.s = y.s = 1; |
| | | ygtx = y.cmp(x) == 1; |
| | | x.s = a; |
| | | y.s = b; |
| | | |
| | | if (ygtx) return new Big(x); |
| | | |
| | | a = Big.DP; |
| | | b = Big.RM; |
| | | Big.DP = Big.RM = 0; |
| | | x = x.div(y); |
| | | Big.DP = a; |
| | | Big.RM = b; |
| | | |
| | | return this.minus(x.times(y)); |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the value of this Big plus the value of Big y. |
| | | */ |
| | | P.plus = P.add = function (y) { |
| | | var t, |
| | | x = this, |
| | | Big = x.constructor, |
| | | a = x.s, |
| | | b = (y = new Big(y)).s; |
| | | |
| | | // Signs differ? |
| | | if (a != b) { |
| | | y.s = -b; |
| | | return x.minus(y); |
| | | } |
| | | |
| | | var xe = x.e, |
| | | xc = x.c, |
| | | ye = y.e, |
| | | yc = y.c; |
| | | |
| | | // Either zero? y is non-zero? x is non-zero? Or both are zero. |
| | | if (!xc[0] || !yc[0]) return yc[0] ? y : new Big(xc[0] ? x : a * 0); |
| | | |
| | | xc = xc.slice(); |
| | | |
| | | // Prepend zeros to equalise exponents. |
| | | // Note: reverse faster than unshifts. |
| | | if ((a = xe - ye)) { |
| | | if (a > 0) { |
| | | ye = xe; |
| | | t = yc; |
| | | } else { |
| | | a = -a; |
| | | t = xc; |
| | | } |
| | | |
| | | t.reverse(); |
| | | for (; a--; ) t.push(0); |
| | | t.reverse(); |
| | | } |
| | | |
| | | // Point xc to the longer array. |
| | | if (xc.length - yc.length < 0) { |
| | | t = yc; |
| | | yc = xc; |
| | | xc = t; |
| | | } |
| | | |
| | | a = yc.length; |
| | | |
| | | // Only start adding at yc.length - 1 as the further digits of xc can be left as they are. |
| | | for (b = 0; a; xc[a] %= 10) b = ((xc[--a] = xc[a] + yc[a] + b) / 10) | 0; |
| | | |
| | | // No need to check for zero, as +x + +y != 0 && -x + -y != 0 |
| | | |
| | | if (b) { |
| | | xc.unshift(b); |
| | | ++ye; |
| | | } |
| | | |
| | | // Remove trailing zeros. |
| | | for (a = xc.length; xc[--a] === 0; ) xc.pop(); |
| | | |
| | | y.c = xc; |
| | | y.e = ye; |
| | | |
| | | return y; |
| | | }; |
| | | |
| | | /* |
| | | * Return a Big whose value is the value of this Big raised to the power n. |
| | | * If n is negative, round to a maximum of Big.DP decimal places using rounding |
| | | * mode Big.RM. |
| | | * |
| | | * n {number} Integer, -MAX_POWER to MAX_POWER inclusive. |
| | | */ |
| | | P.pow = function (n) { |
| | | var x = this, |
| | | one = new x.constructor(1), |
| | | y = one, |
| | | isneg = n < 0; |
| | | |
| | | if (n !== ~~n || n < -MAX_POWER || n > MAX_POWER) |
| | | throw Error(INVALID + "exponent"); |
| | | if (isneg) n = -n; |
| | | |
| | | for (;;) { |
| | | if (n & 1) y = y.times(x); |
| | | n >>= 1; |
| | | if (!n) break; |
| | | x = x.times(x); |
| | | } |
| | | |
| | | return isneg ? one.div(y) : y; |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the value of this Big rounded using rounding mode rm |
| | | * to a maximum of dp decimal places, or, if dp is negative, to an integer which is a |
| | | * multiple of 10**-dp. |
| | | * If dp is not specified, round to 0 decimal places. |
| | | * If rm is not specified, use Big.RM. |
| | | * |
| | | * dp? {number} Integer, -MAX_DP to MAX_DP inclusive. |
| | | * rm? 0, 1, 2 or 3 (ROUND_DOWN, ROUND_HALF_UP, ROUND_HALF_EVEN, ROUND_UP) |
| | | */ |
| | | P.round = function (dp, rm) { |
| | | var Big = this.constructor; |
| | | if (dp === UNDEFINED) dp = 0; |
| | | else if (dp !== ~~dp || dp < -MAX_DP || dp > MAX_DP) |
| | | throw Error(INVALID_DP); |
| | | return round(new Big(this), dp, rm === UNDEFINED ? Big.RM : rm); |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the square root of the value of this Big, rounded, if |
| | | * necessary, to a maximum of Big.DP decimal places using rounding mode Big.RM. |
| | | */ |
| | | P.sqrt = function () { |
| | | var r, |
| | | c, |
| | | t, |
| | | x = this, |
| | | Big = x.constructor, |
| | | s = x.s, |
| | | e = x.e, |
| | | half = new Big(0.5); |
| | | |
| | | // Zero? |
| | | if (!x.c[0]) return new Big(x); |
| | | |
| | | // Negative? |
| | | if (s < 0) throw Error(NAME + "No square root"); |
| | | |
| | | // Estimate. |
| | | s = Math.sqrt(x + ""); |
| | | |
| | | // Math.sqrt underflow/overflow? |
| | | // Re-estimate: pass x coefficient to Math.sqrt as integer, then adjust the result exponent. |
| | | if (s === 0 || s === 1 / 0) { |
| | | c = x.c.join(""); |
| | | if (!((c.length + e) & 1)) c += "0"; |
| | | s = Math.sqrt(c); |
| | | e = (((e + 1) / 2) | 0) - (e < 0 || e & 1); |
| | | r = new Big( |
| | | (s == 1 / 0 |
| | | ? "1e" |
| | | : (s = s.toExponential()).slice(0, s.indexOf("e") + 1)) + e |
| | | ); |
| | | } else { |
| | | r = new Big(s); |
| | | } |
| | | |
| | | e = r.e + (Big.DP += 4); |
| | | |
| | | // Newton-Raphson iteration. |
| | | do { |
| | | t = r; |
| | | r = half.times(t.plus(x.div(t))); |
| | | } while (t.c.slice(0, e).join("") !== r.c.slice(0, e).join("")); |
| | | |
| | | return round(r, (Big.DP -= 4), Big.RM); |
| | | }; |
| | | |
| | | /* |
| | | * Return a new Big whose value is the value of this Big times the value of Big y. |
| | | */ |
| | | P.times = P.mul = function (y) { |
| | | var c, |
| | | x = this, |
| | | Big = x.constructor, |
| | | xc = x.c, |
| | | yc = (y = new Big(y)).c, |
| | | a = xc.length, |
| | | b = yc.length, |
| | | i = x.e, |
| | | j = y.e; |
| | | |
| | | // Determine sign of result. |
| | | y.s = x.s == y.s ? 1 : -1; |
| | | |
| | | // Return signed 0 if either 0. |
| | | if (!xc[0] || !yc[0]) return new Big(y.s * 0); |
| | | |
| | | // Initialise exponent of result as x.e + y.e. |
| | | y.e = i + j; |
| | | |
| | | // If array xc has fewer digits than yc, swap xc and yc, and lengths. |
| | | if (a < b) { |
| | | c = xc; |
| | | xc = yc; |
| | | yc = c; |
| | | j = a; |
| | | a = b; |
| | | b = j; |
| | | } |
| | | |
| | | // Initialise coefficient array of result with zeros. |
| | | for (c = new Array((j = a + b)); j--; ) c[j] = 0; |
| | | |
| | | // Multiply. |
| | | |
| | | // i is initially xc.length. |
| | | for (i = b; i--; ) { |
| | | b = 0; |
| | | |
| | | // a is yc.length. |
| | | for (j = a + i; j > i; ) { |
| | | // Current sum of products at this digit position, plus carry. |
| | | b = c[j] + yc[i] * xc[j - i - 1] + b; |
| | | c[j--] = b % 10; |
| | | |
| | | // carry |
| | | b = (b / 10) | 0; |
| | | } |
| | | |
| | | c[j] = (c[j] + b) % 10; |
| | | } |
| | | |
| | | // Increment result exponent if there is a final carry, otherwise remove leading zero. |
| | | if (b) ++y.e; |
| | | else c.shift(); |
| | | |
| | | // Remove trailing zeros. |
| | | for (i = c.length; !c[--i]; ) c.pop(); |
| | | y.c = c; |
| | | |
| | | return y; |
| | | }; |
| | | |
| | | /* |
| | | * Return a string representing the value of this Big in exponential notation to dp fixed decimal |
| | | * places and rounded using Big.RM. |
| | | * |
| | | * dp? {number} Integer, 0 to MAX_DP inclusive. |
| | | */ |
| | | P.toExponential = function (dp) { |
| | | return stringify(this, 1, dp, dp); |
| | | }; |
| | | |
| | | /* |
| | | * Return a string representing the value of this Big in normal notation to dp fixed decimal |
| | | * places and rounded using Big.RM. |
| | | * |
| | | * dp? {number} Integer, 0 to MAX_DP inclusive. |
| | | * |
| | | * (-0).toFixed(0) is '0', but (-0.1).toFixed(0) is '-0'. |
| | | * (-0).toFixed(1) is '0.0', but (-0.01).toFixed(1) is '-0.0'. |
| | | */ |
| | | P.toFixed = function (dp) { |
| | | return stringify(this, 2, dp, this.e + dp); |
| | | }; |
| | | |
| | | /* |
| | | * Return a string representing the value of this Big rounded to sd significant digits using |
| | | * Big.RM. Use exponential notation if sd is less than the number of digits necessary to represent |
| | | * the integer part of the value in normal notation. |
| | | * |
| | | * sd {number} Integer, 1 to MAX_DP inclusive. |
| | | */ |
| | | P.toPrecision = function (sd) { |
| | | return stringify(this, 3, sd, sd - 1); |
| | | }; |
| | | |
| | | /* |
| | | * Return a string representing the value of this Big. |
| | | * Return exponential notation if this Big has a positive exponent equal to or greater than |
| | | * Big.PE, or a negative exponent equal to or less than Big.NE. |
| | | * Omit the sign for negative zero. |
| | | */ |
| | | P.toString = function () { |
| | | return stringify(this); |
| | | }; |
| | | |
| | | /* |
| | | * Return a string representing the value of this Big. |
| | | * Return exponential notation if this Big has a positive exponent equal to or greater than |
| | | * Big.PE, or a negative exponent equal to or less than Big.NE. |
| | | * Include the sign for negative zero. |
| | | */ |
| | | P.valueOf = P.toJSON = function () { |
| | | return stringify(this, 4); |
| | | }; |
| | | |
| | | // Export |
| | | |
| | | Big = _Big_(); |
| | | |
| | | Big["default"] = Big.Big = Big; |
| | | |
| | | //AMD. |
| | | if (typeof define === "function" && define.amd) { |
| | | define(function () { |
| | | return Big; |
| | | }); |
| | | |
| | | // Node and other CommonJS-like environments that support module.exports. |
| | | } else if (typeof module !== "undefined" && module.exports) { |
| | | module.exports = Big; |
| | | |
| | | //Browser. |
| | | } else { |
| | | GLOBAL.Big = Big; |
| | | } |
| | | })(this); |
| | |
| | | use: { |
| | | loader: "worker-loader", |
| | | options: { |
| | | filename: "[name].[contenthash].worker.js", // æ·»å å
容åå¸å°æä»¶å |
| | | inline: "fallback", |
| | | }, |
| | | }, |