diff --git a/src/api/desk/notice.js b/src/api/desk/notice.js index 4c7e7eae..d38961a4 100644 --- a/src/api/desk/notice.js +++ b/src/api/desk/notice.js @@ -9,7 +9,7 @@ export const getList = (current, size, params) => { current, size, }, - cryptoToken: true, + cryptoToken: false, }); }; @@ -20,7 +20,7 @@ export const remove = ids => { params: { ids, }, - cryptoToken: true, + cryptoToken: false, }); }; @@ -29,7 +29,7 @@ export const add = row => { url: '/logpm-basic/notice/submit', method: 'post', data: row, - cryptoToken: true, + cryptoToken: false, }); }; @@ -38,7 +38,7 @@ export const update = row => { url: '/logpm-basic/notice/submit', method: 'post', data: row, - cryptoToken: true, + cryptoToken: false, }); }; @@ -49,6 +49,6 @@ export const getNotice = id => { params: { id, }, - cryptoToken: true, + cryptoToken: false, }); }; diff --git a/src/option/basicdata/ThreePartyMallManagement.js b/src/option/basicdata/ThreePartyMallManagement.js index ae72f58e..9c2a1964 100644 --- a/src/option/basicdata/ThreePartyMallManagement.js +++ b/src/option/basicdata/ThreePartyMallManagement.js @@ -47,6 +47,17 @@ export const columnList = [ sortable: true, head: false, }, + { + prop: 'brandName', + label: '品牌', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, { prop: 'typeServiceNameS', label: '配送类型', diff --git a/src/option/distribution/distrilbutionBillLading.js b/src/option/distribution/distrilbutionBillLading.js index 3208ce27..b5d5cd0e 100644 --- a/src/option/distribution/distrilbutionBillLading.js +++ b/src/option/distribution/distrilbutionBillLading.js @@ -321,17 +321,17 @@ export default { sortable: true, head: false, }, - { - prop: 'inventoryQuantity', - label: '添加数量', - type: 6, - values: '', - width: '100', - checkarr: [], - fixed: false, - sortable: true, - head: false, - }, + // { + // prop: 'inventoryQuantity', + // label: '添加数量', + // type: 6, + // values: '', + // width: '100', + // checkarr: [], + // fixed: false, + // sortable: true, + // head: false, + // }, ], column: [ { diff --git a/src/option/reportforms/DeliveryDetailsVtwo.js b/src/option/reportforms/DeliveryDetailsVtwo.js index 5a4f0b40..65bdfe7f 100644 --- a/src/option/reportforms/DeliveryDetailsVtwo.js +++ b/src/option/reportforms/DeliveryDetailsVtwo.js @@ -62,7 +62,7 @@ export const columnList = [ { prop: 'brand', label: '品牌', - type: 1, + type: 2, values: '', width: '150', checkarr: [], diff --git a/src/option/reportforms/DeliveryStatisticsReport.js b/src/option/reportforms/DeliveryStatisticsReport.js index 105e6c43..7a830e9f 100644 --- a/src/option/reportforms/DeliveryStatisticsReport.js +++ b/src/option/reportforms/DeliveryStatisticsReport.js @@ -85,6 +85,17 @@ export const columnList = [ sortable: true, head: false, }, + { + prop: 'signOnTimeRate', + label: '签收及时率', + type: 6, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, { prop: 'planStockNum', label: '预约库存品数量', @@ -144,6 +155,18 @@ export const columnList = [ sortable: true, head: false, }, + { + prop: 'reviewOnTimeRate', + label: '复核及时率', + type: 6, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { prop: 'exceptionNum', label: '异常数', diff --git a/src/option/storagecost/Transferwarehousestatistics.js b/src/option/storagecost/Transferwarehousestatistics.js index c8e3a6fd..3df85bc0 100644 --- a/src/option/storagecost/Transferwarehousestatistics.js +++ b/src/option/storagecost/Transferwarehousestatistics.js @@ -17,7 +17,7 @@ export const columnList = [ { prop: 'a1', label: '中转仓', - type: 2, + type: 1, values: '', width: '150', checkarr: [], @@ -27,8 +27,8 @@ export const columnList = [ }, { prop: 'a2', - label: '中转作业结算时间', - type: 2, + label: '目的仓', + type: 1, values: '', width: '150', checkarr: [], @@ -38,7 +38,7 @@ export const columnList = [ }, { prop: 'a3', - label: '月中转入库件数', + label: '中转作业出账时间', type: 1, values: '', width: '150', @@ -49,7 +49,7 @@ export const columnList = [ }, { prop: 'a4', - label: '月中转入库收入', + label: '月中转入库件数', type: 1, values: '', width: '150', @@ -60,7 +60,7 @@ export const columnList = [ }, { prop: 'a5', - label: '月中转出库件数', + label: '月中转入库收入', type: 1, values: '', width: '150', @@ -71,8 +71,19 @@ export const columnList = [ }, { prop: 'a6', + label: '月中转出库件数', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { + prop: 'a7', label: '月中转出库收入', - type: 3, + type: 1, values: '', width: '150', checkarr: [], @@ -91,6 +102,72 @@ export const columnList = [ sortable: true, head: false, }, + { + prop: 'a7', + label: '结算状态', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { + prop: 'a7', + label: '已结算金额', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { + prop: 'a7', + label: '待结算金额', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { + prop: 'a7', + label: '结算人', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { + prop: 'a7', + label: '结算时间', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, + { + prop: 'a7', + label: '异常金额', + type: 1, + values: '', + width: '150', + checkarr: [], + fixed: false, + sortable: true, + head: false, + }, { prop: 'createUserName', label: '操作', diff --git a/src/utils/util.js b/src/utils/util.js index 17c35515..3c995e9b 100644 --- a/src/utils/util.js +++ b/src/utils/util.js @@ -2,6 +2,7 @@ import { validatenull } from './validate'; import sha256 from 'crypto-js/sha256'; import Base64 from 'crypto-js/enc-base64'; import store from '@/store/index'; +import { getToken } from '@/utils/auth'; import { nextTick } from 'vue'; import dayjs from 'dayjs'; //表单序列化 @@ -955,3 +956,16 @@ export const handleFilterData = (data, renderData, { inputQuery, selectQuery, ti export const ChecksWhetherTheWarehouseIsSelected = () => { return localStorage.getItem('WarehouseName') ? true : false; }; +/** + * 文件上传地址 + */ +export const FileUpload = () => { + return '/api/blade-resource/oss/endpoint/put-file'; +}; + +/** + * 文件上传headers + */ +export const headers = () => { + return { 'Blade-Auth': 'Bearer ' + getToken() }; +}; diff --git a/src/views/cost/storagecost/Transferwarehousestatistics.vue b/src/views/cost/storagecost/Transferwarehousestatistics.vue index 0fb8fd1a..7762a1ba 100644 --- a/src/views/cost/storagecost/Transferwarehousestatistics.vue +++ b/src/views/cost/storagecost/Transferwarehousestatistics.vue @@ -91,9 +91,11 @@ > <template #default="slotProps"> <template v-if="slotProps.scope.column.label === '操作'"> - <div class="ElBtnClass"> - <el-button @click="view(slotProps.scope)">查看</el-button> - </div> + <!-- <div class="ElBtnClass"> + <el-text @click="abnormalinformation(slotProps.scope.row)">异常信息</el-text> + <el-text @click="view(slotProps.scope.row)">结算信息</el-text> + <el-text @click="view(slotProps.scope.row)">明细</el-text> + </div> --> </template> </template> </tablecmt> @@ -118,6 +120,78 @@ </div> </el-row> </div> + + <el-dialog + v-model="Abnormalsettlement.dialogVisible" + title="结算信息" + width="60%" + class="el_Abnormalsettlement" + > + <el-tabs class="demo-tabs" v-model="Abnormalsettlement.activeName1"> + <el-tab-pane label="费用信息" name="费用信息"> + <h3>结算单号:XXXXXXXXXXXX</h3> + <h3>结算状态:已结算</h3> + <div class="el_money"> + <span>总费用:<b>199999</b></span> + <span>待结算费用:<b>2232</b></span> + <span>已结算费用:<b>23423</b></span> + <span>异常费用:<b>124124</b></span> + </div> + <el-form + :model="Abnormalsettlement.form" + label-width="auto" + :rules="Abnormalsettlement.rules" + ref="ruleFormRef" + > + <el-form-item label="异常费用:" prop="money"> + <el-input-number + v-model="Abnormalsettlement.form.money" + :controls="false" + :value-on-clear="0" + :precision="2" + :step="1" + placeholder="此处填写要登记的异常金额,正数表示异常增款,负数表示异常减款" + /> + </el-form-item> + <el-form-item label="异常备注:" prop="textarea2"> + <el-input + v-model="Abnormalsettlement.form.textarea2" + :autosize="{ minRows: 4, maxRows: 4 }" + type="textarea" + placeholder="请输入异常备注" + /> + </el-form-item> + <el-form-item label="异常图片:" prop="fileList"> + <el-upload + list-type="picture-card" + v-model:file-list="Abnormalsettlement.form.fileList" + drag + :action="FileUpload()" + multiple + :limit="10" + :on-preview="handlePictureCardPreview" + :before-upload="beforeAvatarUpload" + :on-remove="handleRemove" + :headers="headers()" + > + <el-icon><Plus /></el-icon> + </el-upload> + <!-- 图片预览 --> + <el-dialog v-model="Abnormalsettlement.dialogurl" class="el_imgdialog"> + <img w-full :src="Abnormalsettlement.url" /> + </el-dialog> + </el-form-item> + </el-form> + </el-tab-pane> + </el-tabs> + <el-tabs class="demo-tabs" v-model="Abnormalsettlement.activeName2"> + <el-tab-pane label="异常记录" name="异常记录"> </el-tab-pane> + </el-tabs> + <template #footer> + <el-button @click="Abnormalsettlement.dialogVisible = false">关闭</el-button> + <el-button type="primary" @click="AbnormalsettlementSubmit"> 确定 </el-button> + </template> + </el-dialog> </basic-container> <!-- 列表配置显示 --> <edittablehead @@ -132,19 +206,58 @@ import { ref, reactive, toRefs, computed, onMounted, nextTick, watch } from 'vue'; import { columnList } from '@/option/storagecost/Transferwarehousestatistics.js'; import { $_getMyWarehouseList } from '@/api/storagecost/index.js'; +import { compressImageBlob } from '@/components/IMGcompressor/imgcompressor.js'; import { getDictionaryBiz } from '@/api/system/dict'; //字典 import { processRowProperty, setNodeHeight } from '@/utils/util'; import { ElMessageBox, ElMessage } from 'element-plus'; -import { downloadXls } from '@/utils/util'; +import { downloadXls, FileUpload, headers } from '@/utils/util'; +import { getToken } from '@/utils/auth'; import { useStore } from 'vuex'; import dayjs from 'dayjs'; +const ruleFormRef = ref(null); const $router = useRouter(); //跳转 const $useStore = useStore(); //权限 const $route = useRoute(); //获取地址栏参数 const queryTop = ref({}); const warehouseList = ref([]); const monthList = ref([]); +const validateFileList = (rule, value, callback) => { + if (!value.length) { + callback(new Error('至少上传一张图片')); + } else { + callback(); + } +}; +const Abnormalsettlement = ref({ + dialogVisible: false, + activeName1: '费用信息', + activeName2: '异常记录', + url: '', + dialogurl: false, + form: { + money: null, + fileList: [], //图片列表 + }, + rules: { + money: [ + { + required: true, + message: '此处填写要登记的异常金额,正数表示异常增款,负数表示异常减款', + trigger: ['change', 'blur'], + }, + ], + textarea2: [ + { + required: true, + message: '请填写备注', + trigger: ['change', 'blur'], + }, + ], + fileList: [{ validator: validateFileList, trigger: 'change' }], + }, +}); const details = reactive({ + fileList: [], /** 是否开启搜索 */ search: false, /** 表格搜索条件 */ @@ -183,7 +296,7 @@ const details = reactive({ columnList, /** 列表数据 */ - data: [], + data: [{}], /** 页面loading */ loadingObj: { /** 列表加载loading */ @@ -314,6 +427,25 @@ const searchHide = () => { const _node = document.querySelector('.tableNode'); setNodeHeight(_node, '', true); }; + +// 上传图片规则 +const beforeAvatarUpload = async rawFile => { + console.log(rawFile, '图片上传前回调'); + const allowedTypes = ['image/png', 'image/jpeg', 'image/gif', 'image/webp', 'image/svg+xml']; + if (!allowedTypes.includes(rawFile.type)) { + ElMessage.error('只能上传格式为PNG/JPG/GIF/WebP/SVG的图片!'); + return false; + } + const res = await compressImageBlob(rawFile); + return res; +}; +const handlePictureCardPreview = uploadFile => { + console.log(uploadFile, '预览'); + Abnormalsettlement.value.url = uploadFile.response.data.link; + console.log(Abnormalsettlement.value.url, 'url'); + + Abnormalsettlement.value.dialogurl = true; +}; // 字典公共函数 function updateDictionary(targetArray, dictionaryType) { getDictionaryBiz(dictionaryType).then(res => { @@ -348,9 +480,7 @@ const MyWarehouseList = () => { }); }; // 页面初始化 -const onLoad = () => { - -}; +const onLoad = () => {}; const PageOnload = () => { onLoad(); //获取列表参数 MyWarehouseList(); //获取仓库 @@ -359,7 +489,21 @@ const PageOnload = () => { //页面初始化方法 PageOnload(); -// 页面初始化方法 +// 异常信息 +const abnormalinformation = () => { + Abnormalsettlement.value.dialogVisible = true; +}; +// 提交 +const AbnormalsettlementSubmit = async () => { + await ruleFormRef.value.validate((valid, fields) => { + if (valid) { + console.log('submit!'); + } else { + console.log('error submit!', fields); + ElMessage.error('表单校验未通过,请检查输入'); + } + }); +}; </script> <style scoped lang="scss"> @@ -387,4 +531,48 @@ PageOnload(); display: flex; flex-direction: column; } +:deep(.el_Abnormalsettlement) { + .el-tabs__header { + margin-bottom: 0; + } + .el_money { + display: flex; + justify-content: space-between; + height: 30px; + align-items: center; + span { + font-weight: bold; + b { + text-decoration: underline; + color: #f44336; + } + } + } + img { + object-fit: inherit; + } + .el-form-item { + padding: 0; + margin: 15px 0; + } + .el-form-item__content { + width: 100%; + .el-textarea { + width: 100%; + } + } + .el-input-number { + width: 100%; + } + .el_imgdialog { + img { + width: 100%; + } + } + .el-upload-dragger { + display: flex; + align-items: center; + justify-content: center; + } +} </style> diff --git a/src/views/reportforms/DeliveryStatisticsReport.vue b/src/views/reportforms/DeliveryStatisticsReport.vue index 400cadd9..ebe52d6b 100644 --- a/src/views/reportforms/DeliveryStatisticsReport.vue +++ b/src/views/reportforms/DeliveryStatisticsReport.vue @@ -106,7 +106,7 @@ <template #default="slotProps"> <template v-if=" - ['审核率', '签收率', '库存品签收率', '计划准确率'].includes( + ['审核率', '签收率', '库存品签收率', '计划准确率','签收及时率','复核及时率'].includes( slotProps.scope.column.label ) " @@ -457,10 +457,14 @@ const onLoad = async () => { item.signRate = parsePercentage(item.signRate); item.signStockRate = parsePercentage(item.signStockRate); item.planAccuracy = parsePercentage(item.planAccuracy); + item.signOnTimeRate = parsePercentage(item.signOnTimeRate); + item.reviewOnTimeRate = parsePercentage(item.reviewOnTimeRate); } + details.data = data.records; details.page.total = data.total; + console.log(details.data,'details.data'); } catch (e) { console.error(e); } finally { @@ -483,6 +487,10 @@ const getRateValue = (label, row) => { return row.signStockRate; case '计划准确率': return row.planAccuracy; + case '签收及时率': + return row.signOnTimeRate; + case '复核及时率': + return row.reviewOnTimeRate; default: return 0; }