Browse Source

采购收货完善拒收接口增加关闭接口。

master_hella_20240701
liuchen864 6 months ago
parent
commit
c1b2ce0403
  1. 7
      src/api/wms/purchasereceiptJobMain/index.ts
  2. 2
      src/locales/en-US.ts
  3. 2
      src/locales/zh-CN.ts
  4. 24
      src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptJobMain/index.vue
  5. 7
      src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptJobMain/purchasereceiptJobMain.data.ts

7
src/api/wms/purchasereceiptJobMain/index.ts

@ -123,4 +123,9 @@ export const abandonPurchasereceiptJobMainSpare = (id: number) => {
// 承接采购收货任务主 // 承接采购收货任务主
export const acceptPurchasereceiptJobMain = (id: number) => { export const acceptPurchasereceiptJobMain = (id: number) => {
return request.put({ url: '/wms/purchasereceipt-job-main/accept?id=' + id }) return request.put({ url: '/wms/purchasereceipt-job-main/accept?id=' + id })
} }
// 拒收采购收货任务主
export const refusalPurchasereceiptJobMain = (id: number) => {
return request.put({ url: '/wms/purchasereceipt-job-main/refusal?id=' + id })
}

2
src/locales/en-US.ts

@ -56,6 +56,7 @@ export default {
copySuccess: 'Copy Success', copySuccess: 'Copy Success',
copyError: 'Copy Error', copyError: 'Copy Error',
closeSuccess: 'Close Success', closeSuccess: 'Close Success',
refusalSuccess: 'Refusal Success',
reAddSuccess: 'ReAdd Success', reAddSuccess: 'ReAdd Success',
submitSuccess: 'Submit Success', submitSuccess: 'Submit Success',
agreeSuccess: 'Agree Success', agreeSuccess: 'Agree Success',
@ -66,6 +67,7 @@ export default {
giveupSuccess: 'Giveup Success', giveupSuccess: 'Giveup Success',
dealwithSuccess: 'Dealwith Success', dealwithSuccess: 'Dealwith Success',
confirmColse: 'Confirm Close?', confirmColse: 'Confirm Close?',
confirmRefusal: 'Confirm Refusal?',
confirmReAdd: 'Confirm ReAdd?', confirmReAdd: 'Confirm ReAdd?',
confirmAgree: 'Confirm Agree?', confirmAgree: 'Confirm Agree?',
confirmRefused: 'Confirm Refused?', confirmRefused: 'Confirm Refused?',

2
src/locales/zh-CN.ts

@ -56,6 +56,7 @@ export default {
copySuccess: '复制成功', copySuccess: '复制成功',
copyError: '复制失败', copyError: '复制失败',
closeSuccess: '关闭成功', closeSuccess: '关闭成功',
refusalSuccess: '拒收成功',
reAddSuccess: '重新添加成功', reAddSuccess: '重新添加成功',
submitSuccess: '提交成功', submitSuccess: '提交成功',
agreeSuccess: '审批通过成功', agreeSuccess: '审批通过成功',
@ -66,6 +67,7 @@ export default {
acceptSuccess: '承接成功', acceptSuccess: '承接成功',
giveupSuccess: '放弃成功', giveupSuccess: '放弃成功',
confirmColse: '确认关闭吗?', confirmColse: '确认关闭吗?',
confirmRefusal: '确认拒收吗?',
confirmReAdd: '确认重新添加吗?', confirmReAdd: '确认重新添加吗?',
confirmAgree: '确认审批通过吗?', confirmAgree: '确认审批通过吗?',
confirmRefused: '确认审批驳回吗?', confirmRefused: '确认审批驳回吗?',

24
src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptJobMain/index.vue

@ -90,12 +90,8 @@
> >
<iframe height="600px" width="100%" :src="qualityReport" frameborder="0"></iframe> <iframe height="600px" width="100%" :src="qualityReport" frameborder="0"></iframe>
</el-dialog> </el-dialog>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import download from '@/utils/download' import download from '@/utils/download'
import { PurchasereceiptJobMain, import { PurchasereceiptJobMain,
@ -217,17 +213,17 @@ const butttondata = (row,$index) => {
} }
return [ return [
// defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), // // defaultButtons.mainListJobAccBtn({hide:isShowMainButton(row,['1'])}), //
// defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-job-main:close'}), // defaultButtons.mainListJobCloBtn({hide:isShowMainButton(row,['1']),hasPermi:'wms:purchasereceipt-job-main:close'}), //
// defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), // // defaultButtons.mainListJobAbaBtn({hide:isShowMainButton(row,['2'])}), //
// defaultButtons.mainListJobExeBtn({hide:isShowMainButton(row,['2'])}), // // defaultButtons.mainListJobExeBtn({hide:isShowMainButton(row,['2'])}), //
{ {
label: '拒收', label: '拒收',
name: 'mainJobClo', name: 'mainJobRefusal',
hide: isShowMainButton(row, ['1']), hide: isShowMainButton(row, ['1']),
type: 'primary', type: 'primary',
icon: '', icon: '',
color: '', color: '',
hasPermi: 'wms:purchasereceipt-job-main:close', hasPermi: 'wms:purchasereceipt-job-main:refusal',
link: true // link: true //
}, },
defaultButtons.mainListPlanCheckQualityReportBtn({}), // defaultButtons.mainListPlanCheckQualityReportBtn({}), //
@ -244,9 +240,11 @@ const buttonTableClick = async (val, row) => {
handleClose(row.masterId) handleClose(row.masterId)
} else if (val == 'mainJobAcc') { // } else if (val == 'mainJobAcc') { //
console.log('列表-操作按钮事件-承接') console.log('列表-操作按钮事件-承接')
}else if(val == 'mainPlanCheckQualityReport'){ } else if(val == 'mainPlanCheckQualityReport'){
// //
checkQualityReport(row) checkQualityReport(row)
} else if(val == 'mainJobRefusal'){
handleRefusal(row.masterId)
} }
} }
// //
@ -267,6 +265,16 @@ const handleClose = async (id: number) => {
} catch {} } catch {}
} }
/** 拒收按钮操作 */
const handleRefusal = async (id: number) => {
try {
await message.confirm(t('common.confirmRefusal'))
await PurchasereceiptJobMainApi.refusalPurchasereceiptJobMain(id)
message.success(t('common.refusalSuccess'))
await getList()
} catch {}
}
// //
const detailParenPackingRef = ref() const detailParenPackingRef = ref()
const { tableObject: packingDetatableData, tableMethods: packDetatableMethods } = useTable({ const { tableObject: packingDetatableData, tableMethods: packDetatableMethods } = useTable({

7
src/views/wms/purchasereceiptManage/purchasereceipt/purchasereceiptJobMain/purchasereceiptJobMain.data.ts

@ -1,6 +1,7 @@
import type { CrudSchema } from '@/hooks/web/useCrudSchemas' import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
import { dateFormatter,dateFormatter2 } from '@/utils/formatTime' import { dateFormatter,dateFormatter2 } from '@/utils/formatTime'
import { fa } from 'element-plus/es/locale' import { fa } from 'element-plus/es/locale'
import { DICT_TYPE } from '@/utils/dict'
/** /**
* @returns {Array} * @returns {Array}
@ -609,7 +610,7 @@ export const PurchasereceiptJobMain = useCrudSchemas(reactive<CrudSchema[]>([
isDetail: false, isDetail: false,
isForm: false, isForm: false,
table: { table: {
width: 180, width: 200,
fixed: 'right' fixed: 'right'
}, },
}, },
@ -1108,7 +1109,7 @@ export const PurchasereceiptJobDetail = useCrudSchemas(reactive<CrudSchema[]>([
isDetail: false, isDetail: false,
isForm: false , isForm: false ,
table: { table: {
width: 150, width: 180,
fixed: 'right' fixed: 'right'
}, },
isTableForm:true, isTableForm:true,
@ -1605,4 +1606,4 @@ export const PurchasereceiptJobDetailPackingNumber = useCrudSchemas(reactive<Cru
valueFormat: 'x', valueFormat: 'x',
} }
}, },
])) ]))

Loading…
Cancel
Save