diff --git a/src/api/modular/main/TaskmanageList.js b/src/api/modular/main/TaskmanageList.js index 9dde77b..712ee16 100644 --- a/src/api/modular/main/TaskmanageList.js +++ b/src/api/modular/main/TaskmanageList.js @@ -291,3 +291,38 @@ export function DownloadFileByBC(parameter) { responseType: 'blob' }) } +export function GetProjectList(parameter) { + return axios({ + url: '/TaskManageBC/GetProjectList', + method: 'get', + params: parameter + }) +} +export function CancelTaskBC(parameter) { + return axios({ + url: '/TaskManageBC/CancelTask', + method: 'get', + params: parameter + }) +} +export function DownloadFile(parameter) { + return axios({ + url: '/TaskManageBC/DownloadFile', + method: 'get', + params: parameter + }) +} +export function TransferTask(parameter) { + return axios({ + url: '/TaskManageBC/TransferTask', + method: 'get', + params: parameter + }) +} +export function CreateBookingAndSlot(parameter) { + return axios({ + url: '/TaskManageBC/CreateBookingAndSlot', + method: 'post', + data: parameter + }) +} diff --git a/src/router/generator-routers.js b/src/router/generator-routers.js index 006b10c..124e331 100644 --- a/src/router/generator-routers.js +++ b/src/router/generator-routers.js @@ -39,6 +39,7 @@ const constantRouterComponents = { TaskOriginalLost: () => import('@/views/main/Taskmanage/TaskOriginalLost'), TaskChangeShip: () => import('@/views/main/Taskmanage/TaskChangeShip'), BcFileDetail: () => import('@/views/main/Taskmanage/BcFileDetail'), + BcEditing: () => import('@/views/main/Taskmanage/BcFileDetail/Editing'), BookingDetailTest: () => import('@/views/main/BookingLedger/detail/BookingDetailTest'), BookingCustomerDetail: () => import('@/views/main/BookingCustomerLedger/detail') } @@ -165,6 +166,17 @@ const userAccount = [ }, component: 'BcFileDetail' }, + { + name: 'BcEditing', + path: '/commontaskmanage/BcEditing', + pid: 0, + id: 183183, + meta: { + title: 'BC编辑', + show: false + }, + component: 'BcEditing' + }, { name: 'TaskmanageDetail', path: '/commontaskmanage/TaskmanageDetail', diff --git a/src/views/main/Taskmanage/BcFileDetail/Editing.vue b/src/views/main/Taskmanage/BcFileDetail/Editing.vue new file mode 100644 index 0000000..87ce835 --- /dev/null +++ b/src/views/main/Taskmanage/BcFileDetail/Editing.vue @@ -0,0 +1,855 @@ + + + diff --git a/src/views/main/Taskmanage/TaskmanageList/index.vue b/src/views/main/Taskmanage/TaskmanageList/index.vue index 02b4708..33fe96d 100644 --- a/src/views/main/Taskmanage/TaskmanageList/index.vue +++ b/src/views/main/Taskmanage/TaskmanageList/index.vue @@ -10,7 +10,9 @@ @@ -24,7 +26,8 @@ v-for="(threeLevel, tindex) in levelTree" :key="`0-0-${tindex}`" :title="`${threeLevel.name} (${threeLevel.total})`" - :show-icon="false" /> + :show-icon="false" + /> @@ -36,7 +39,8 @@ class="icon" :icon="levelreLoading ? 'loading' : 'reload'" size="small" - @click="getCurrentTotalStat"> + @click="getCurrentTotalStat" + > 点击重新加载 @@ -55,7 +59,8 @@ :xl="5.5" :key="findex" v-show="(findex < 4 && !advanced) || advanced" - class="from-label"> + class="from-label" + > + @selectFirst="getSelectFirst" + > @@ -91,10 +97,22 @@
@@ -124,7 +144,8 @@ ok-text="是" cancel-text="否" @confirm="SendEmailFun" - @cancel="cancelFun"> + @cancel="cancelFun" + > 批量转发 + @cancel="cancelFun" + > 批量下载 @@ -142,7 +164,8 @@ ok-text="是" cancel-text="否" @confirm="laraPaperCalc" - @cancel="cancelFun"> + @cancel="cancelFun" + > 页数计算 @@ -152,7 +175,8 @@ ok-text="是" cancel-text="否" @confirm="copyPrintFun" - @cancel="cancelFun"> + @cancel="cancelFun" + > COPY打印 + @cancel="cancelFun" + > COPY下载 + @cancel="cancelFun" + > 正本下载 + @cancel="cancelFun" + > LARA登记 - LARA记录 + LARA记录 @@ -246,7 +283,8 @@ :confirmLoading="sendEmailModelconfirm" :maskClosable="false" @ok="handleSendEmail" - @cancel="handleSendEmailCancel"> + @cancel="handleSendEmailCancel" + > + :wrapperCol="wrapperCol" + > @@ -274,7 +313,8 @@ md: { span: 5 } }" :wrapperCol="wrapperCol" - @cancel="handlePaperCalcCancel"> + @cancel="handlePaperCalcCancel" + >
@@ -310,7 +350,8 @@ @click="FnCilckTemplateType(item.id)" class="items" :span="11" - :offset="index % 2 == 0 ? 0 : 1"> + :offset="index % 2 == 0 ? 0 : 1" + > ·{{ item.displayName }} @@ -323,7 +364,8 @@ :formAllData="formMoreData" type="from" @ok="submitForm" - v-if="formMoreData"> + v-if="formMoreData" + > + v-if="formMoreTableData" + >
时间{{ bcFile.executeTime }}
@@ -360,7 +403,8 @@ style="width:450px" :not-found-content="null" show-search - @search="gettruckIdData"> + @search="gettruckIdData" + > {{ item.shortName }} @@ -424,7 +468,7 @@ export default { this.GetPrintData('truckBill', printType) } }, - '$route': { + $route: { deep: true, handler(nD, oD) { if (nD.name === 'Taskmanage_list') { @@ -436,7 +480,7 @@ export default { } }) GetTaskManagePage({ pkId: this.saveNeedCar }) - .then((res) => { + .then(res => { if (res.success) { this.$set(this.gridOptions.data, index, res.data.items[0]) this.$forceUpdate() @@ -444,7 +488,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) } @@ -584,14 +628,14 @@ export default { }, methods: { handleCopy() { - this.$message.success('复制成功'); + this.$message.success('复制成功') const text = this.$refs.bcBox.innerText - var cInput = document.createElement('input'); - cInput.value = text; - document.body.appendChild(cInput); - cInput.select(); // 选取文本框内容 - document.execCommand('copy'); - document.body.removeChild(cInput); + var cInput = document.createElement('input') + cInput.value = text + document.body.appendChild(cInput) + cInput.select() // 选取文本框内容 + document.execCommand('copy') + document.body.removeChild(cInput) }, Changeyardid(e) { this.truckIdData.forEach(item => { @@ -653,7 +697,7 @@ export default { return option.componentOptions.children[0].text.indexOf(value) >= 0 }, gettruckIdData(name, type) { - DjyCustomerQuerytDjyCustomerInfo({ queryType: 'fleet', queryItem: name }).then((res) => { + DjyCustomerQuerytDjyCustomerInfo({ queryType: 'fleet', queryItem: name }).then(res => { this.truckIdData = res.data }) }, @@ -666,7 +710,7 @@ export default { } const fun = this.emnuCompleteApi(form.label) if (fun) { - this.getFromSelectData(this.emnuCompleteApi(form.label), query).then((data) => { + this.getFromSelectData(this.emnuCompleteApi(form.label), query).then(data => { if (['CUSTOMERNAME', 'FORWARDER', 'CUSTOMSER', 'AGENTID', 'TRUCKER'].includes(form.label)) { this.$refs[`fromlabel-${form.label}`][0].$data.dataSourceList = data.rows } else { @@ -709,7 +753,7 @@ export default { }, getFromSelectData(func, ...args) { return new Promise((resolve, reject) => { - func(...args).then((res) => { + func(...args).then(res => { if (res.code === 200) { resolve(res.data) } else { @@ -754,7 +798,7 @@ export default { DjyUserConfigAdd({ type: 'task_list_cond', configJson: JSON.stringify(arr) - }).then((res) => { + }).then(res => { this.$message.success('保存成功') this.$refs.setForm.handleCancel() Object.keys(this.$refs).map((label, index) => { @@ -767,7 +811,7 @@ export default { }) }, getFormData(isReset = false) { - DjyUserConfigGet({ type: 'task_list_cond' }).then((res) => { + DjyUserConfigGet({ type: 'task_list_cond' }).then(res => { this.setFormData(res.data) }) }, @@ -784,7 +828,7 @@ export default { const query = { typeArr: ['task_list_cond', 'task_list_column', 'task_list_page'] } - DjyUserConfigMulti(this.$qs.stringify(query, { arrayFormat: 'repeat' })).then((res) => { + DjyUserConfigMulti(this.$qs.stringify(query, { arrayFormat: 'repeat' })).then(res => { const $data = {} res.data.map((item, index) => { switch (item.type) { @@ -855,7 +899,7 @@ export default { } else { this.formBtnCol = 24 - len * 4 } - this.formData.forEach((item) => { + this.formData.forEach(item => { if (item.label === 'taskType') { item.data = this.taskTypeList } @@ -911,7 +955,7 @@ export default { DjyUserConfigAdd({ type: 'task_list_column', configJson: JSON.stringify(data) - }).then((res) => { + }).then(res => { this.$refs.setForm.handleCancel() }) }, @@ -920,7 +964,7 @@ export default { this.$message.success(`搜索文件中...`) const printType = this.PrintType == 4 ? 20 : 10 TaskManageTruckGetInfoByTaskId({ taskPkId: this.pkIdArr[0] }) - .then((res) => { + .then(res => { if (res.data.succ) { TaskManageTruckPrint({ taskPKId: res.data.ext.pK_ID, @@ -928,7 +972,7 @@ export default { cateCode: 'truckBill', type: this.PrintType, printType - }).then((res) => { + }).then(res => { if (!res.success) { this.$message.error(res.message) } else { @@ -959,7 +1003,7 @@ export default { } this.spinning = true - TaskManageTruckPrintTemplateWithHistoryList(Data).then((res) => { + TaskManageTruckPrintTemplateWithHistoryList(Data).then(res => { console.log(res.data) if (res.data.length == 1) { this.FnCilckTemplateType(res.data[0].id) @@ -998,7 +1042,7 @@ export default { this.$message.error('请选择数据') return false } - TaskManageTruckSendDispatchBatchByTask(pkIdArr).then((res) => { + TaskManageTruckSendDispatchBatchByTask(pkIdArr).then(res => { if (res.data.succ) { this.$message.success('派车成功') } else { @@ -1039,7 +1083,7 @@ export default { this.$message.error('请选择数据') return false } - TaskManageTruckCancelDispatchBatchByTask(pkIdArr).then((res) => { + TaskManageTruckCancelDispatchBatchByTask(pkIdArr).then(res => { if (res.data.succ) { this.$message.success('取消派车成功') } else { @@ -1201,7 +1245,7 @@ export default { GetParaInfo({ ParaType: typeString }) - .then((res) => { + .then(res => { if (res.success) { if (type === 'status') { this.statusList = res.data.rows @@ -1216,7 +1260,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1234,7 +1278,7 @@ export default { GetCurrentTotalStat({ isReCalc: false }) - .then((res) => { + .then(res => { this.levelLoading = false this.levelreLoading = false if (res.success) { @@ -1260,7 +1304,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1331,7 +1375,7 @@ export default { pageNo: currentPage, pageSize: pageSize }) - .then((res) => { + .then(res => { if (res.success) { const _data = res.data.items.map((item, index) => { item.row_id = (currentPage - 1) * pageSize + index @@ -1346,7 +1390,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1425,8 +1469,10 @@ export default { } }) } else if (data.taskType === 'BC') { - // 订舱详情编辑 - this.$router.push({ path: '/commontaskmanage/BcFileDetail', query: { taskPKId: data.pkId } }) + // BC详情 + // this.$router.push({ path: '/commontaskmanage/BcFileDetail', query: { taskPKId: data.pkId } }) + // BC编辑 + this.$router.push({ path: '/commontaskmanage/BcEditing', query: { taskPKId: data.pkId } }) } else { // 订舱详情查看 this.$router.push({ path: '/commontaskmanage/BookingDetails', query: { taskPKId: data.pkId } }) @@ -1444,7 +1490,7 @@ export default { }) return res[0].name }, - cancelFun() { }, + cancelFun() {}, // 取消 removeFun() { const select = this.$refs.xGrid.getCheckboxRecords() @@ -1457,7 +1503,7 @@ export default { return false } CancelTask(pkIdArr) - .then((res) => { + .then(res => { if (res.success) { this.$message.success('取消任务成功') this.bcFileFlag = true @@ -1467,7 +1513,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1483,7 +1529,7 @@ export default { return false } CompleteTask(pkIdArr) - .then((res) => { + .then(res => { if (res.success) { this.$message.success('已完成任务') this.bcFileFlag = true @@ -1493,7 +1539,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1508,7 +1554,7 @@ export default { this.$message.error('请选择数据') return false } - pkIdArr.map((item) => { + pkIdArr.map(item => { const name = select[pkIdArr.indexOf(item)].taskTitle this.DownloadTaskAttach(item, name) }) @@ -1517,7 +1563,7 @@ export default { DownloadTaskAttach({ taskPKId: id }) - .then((res) => { + .then(res => { if (res.message) { // this.showdownLoadErr = true this.downLoadErrTip = `${name}下载失败:${res.message}` @@ -1535,7 +1581,7 @@ export default { URL.revokeObjectURL(link.href) // 释放URL对象 document.body.removeChild(link) }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1552,14 +1598,14 @@ export default { } const query = this.$qs.stringify({ PKIds: pkIdArr }, { arrayFormat: 'repeat' }) ManualReCompareBC(query) - .then((res) => { + .then(res => { if (res.success) { this.$message.success('重新比对完成') } else { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1578,14 +1624,14 @@ export default { this.sendEmailVisible = true }, handleSendEmail() { - this.$refs.sendForm.validate((valid) => { + this.$refs.sendForm.validate(valid => { if (valid) { console.log(this.sendEmailForm.email) SendTelexEmail({ taskPKId: this.sendEmailPkIds[0], toMail: this.sendEmailForm.email }) - .then((res) => { + .then(res => { if (res.success) { this.$message.success('转发成功') this.handleSendEmailCancel() @@ -1593,7 +1639,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) } else { @@ -1618,7 +1664,7 @@ export default { } const query = this.$qs.stringify({ PKIds: pkIdArr }, { arrayFormat: 'repeat' }) LaraPaperCalc(query) - .then((res) => { + .then(res => { if (res.success) { this.paperCalcRes = res.data this.paperCalcExtras = res.extras || '' @@ -1627,7 +1673,7 @@ export default { this.$message.error(res.message) } }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1653,7 +1699,7 @@ export default { PrintBatch({ PKIds: pkIdArr }) - .then((res) => { + .then(res => { // 接口暂时报错 if (res.message) { const downLoadErrTip = `COPY打印失败:${res.message}` @@ -1670,7 +1716,7 @@ export default { URL.revokeObjectURL(link.href) // 释放URL对象 document.body.removeChild(link) }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1693,7 +1739,7 @@ export default { DownloadAttach({ PKIds: pkIdArr }) - .then((res) => { + .then(res => { // 暂时报错 接口404 文档中也没有 等更新 if (res.message) { const downLoadErrTip = `COPY下载失败:${res.message}` @@ -1710,7 +1756,7 @@ export default { URL.revokeObjectURL(link.href) // 释放URL对象 document.body.removeChild(link) }) - .catch((err) => { + .catch(err => { console.log(err) }) }, @@ -1727,7 +1773,7 @@ export default { DownloadOriginalTask({ PKIds: pkIdArr }) - .then((res) => { + .then(res => { // 接口调用成功,但是无下载数据???? if (res.message) { const downLoadErrTip = `正本下载失败:${res.message}` @@ -1744,7 +1790,7 @@ export default { URL.revokeObjectURL(link.href) // 释放URL对象 document.body.removeChild(link) }) - .catch((err) => { + .catch(err => { console.log(err) }) },