| | |
| | | </a-form-model> |
| | | </a-spin> |
| | | |
| | | <a-button v-show="selectBorrowTool" type="primary" :style="{ marginBottom: '8px' }" @click="selectOutBoundTool">选择出库工具</a-button> |
| | | <a-button v-show="selectBorrowTool" type="primary" :style="{ marginBottom: '8px' }" @click="selectBorrowOutBoundTool">选择出库工具</a-button> |
| | | <a-button v-show="selectSharpenTool" type="primary" :style="{ marginBottom: '8px' }" @click="selectSharpenOutBoundTool">选择刃磨工具</a-button> |
| | | <a-table |
| | | ref="table" |
| | | size="middle" |
| | |
| | | <div :key="col.dataIndex"> |
| | | <a-input-number |
| | | v-if="col.dataIndex === 'outboundQuantity'" |
| | | :disabled="record.quantity <= 1" |
| | | :disabled="record.accuracyClass === '1'" |
| | | :value="text" |
| | | @change="(e) => handleChange(e, record.key, col, index)" |
| | | :min="1" |
| | | /> |
| | | <a-input-number |
| | | v-if="col.dataIndex === 'ratedLife'" |
| | | :disabled="record.accuracyClass != '1'" |
| | | :value="text" |
| | | @change="(e) => handleChange(e, record.key, col, index)" |
| | | :min="1" |
| | | /> |
| | | <a-input-number |
| | | v-if="col.dataIndex === 'useLife'" |
| | | :disabled="record.accuracyClass != '1'" |
| | | :value="text" |
| | | @change="(e) => handleChange(e, record.key, col, index)" |
| | | :min="1" |
| | |
| | | <a-button @click="handleOk" :disabled="isDisabled" type="primary">出库</a-button> |
| | | </template> |
| | | |
| | | <j-select-outbound-tool-modal ref="selectOutBoundToolModal"></j-select-outbound-tool-modal> |
| | | <j-select-borrow-outbound-tool-modal ref="selectBorrowOutBoundToolModal"></j-select-borrow-outbound-tool-modal> |
| | | <j-select-sharpen-outbound-tool-modal ref="selectSharpenOutBoundToolModal"></j-select-sharpen-outbound-tool-modal> |
| | | </j-modal> |
| | | |
| | | </template> |
| | |
| | | |
| | | import { validateDuplicateValue } from '@/utils/util' |
| | | import OutboundDetailList from '../../OutboundDetailList.vue' |
| | | import JSelectOutboundToolModal from './JSelectOutboundToolModal.vue' |
| | | import JSelectBorrowOutboundToolModal from './JSelectBorrowOutboundToolModal.vue' |
| | | import JSelectSharpenOutboundToolModal from './JSelectSharpenOutboundToolModal.vue' |
| | | import { postAction } from '../../../../api/manage' |
| | | import title from 'ant-design-vue/lib/skeleton/Title' |
| | | |
| | |
| | | name: "OutboundOrderModal", |
| | | components: { |
| | | OutboundDetailList, |
| | | JSelectOutboundToolModal |
| | | JSelectBorrowOutboundToolModal, |
| | | JSelectSharpenOutboundToolModal |
| | | }, |
| | | data () { |
| | | return { |
| | |
| | | isDisabled: false, |
| | | addShow: true, |
| | | selectBorrowTool: false, |
| | | selectSharpenTool: false, |
| | | model:{ |
| | | }, |
| | | labelCol: { |
| | |
| | | align:"center", |
| | | dataIndex: 'outboundLocation' |
| | | }, |
| | | { |
| | | title:'额定寿命', |
| | | align:"center", |
| | | dataIndex: 'ratedLife', |
| | | scopedSlots: { customRender: 'ratedLife' }, |
| | | }, |
| | | { |
| | | title:'使用寿命', |
| | | align:"center", |
| | | dataIndex: 'useLife', |
| | | scopedSlots: { customRender: 'useLife' }, |
| | | }, |
| | | // { |
| | | // title:'出库状态;1.未出库;2.部分出库;3.出库完成', |
| | | // align:"center", |
| | |
| | | for (let i = 0; i < data.length; i++) { |
| | | this.dataSource.push({ |
| | | id: data[i].id, |
| | | toolLedgerDetailId: data[i].toolLedgerDetailId, |
| | | toolCode:data[i].toolCode, |
| | | toolNum:data[i].toolNum, |
| | | toolId: data[i].toolId, |
| | |
| | | outboundQuantity: data[i].quantity, |
| | | storageLocation: data[i].warehouseId, |
| | | warehouseName: data[i].warehouseName, |
| | | outboundLocation: data[i].positionCode |
| | | outboundLocation: data[i].positionCode, |
| | | accuracyClass:data[i].accuracyClass |
| | | }) |
| | | } |
| | | this.ipagination.total = this.dataSource.length |
| | |
| | | handleTypeChange(value) { |
| | | if (value === '1') { |
| | | this.selectBorrowTool = true |
| | | this.selectSharpenTool = false |
| | | this.dataSource = [] |
| | | } |
| | | if (value === '2') { |
| | | this.selectBorrowTool = false |
| | | this.selectSharpenTool = false |
| | | this.dataSource = [] |
| | | } |
| | | if (value === '3') { |
| | | this.selectBorrowTool = false |
| | | this.selectSharpenTool = false |
| | | this.dataSource = [] |
| | | } |
| | | if (value === '4') { |
| | | this.selectBorrowTool = false |
| | | this.selectSharpenTool = true |
| | | this.dataSource = [] |
| | | } |
| | | }, |
| | | handleDelete(record, index) { |
| | |
| | | this.dataSource = temp |
| | | } |
| | | }, |
| | | selectOutBoundTool() { |
| | | selectBorrowOutBoundTool() { |
| | | console.log(this.dataSource) |
| | | let ids = this.dataSource.map(item => item.id).join(',') |
| | | this.$refs.selectOutBoundToolModal.showModal(ids, this.classifyId) |
| | | this.$refs.selectBorrowOutBoundToolModal.showModal(ids, this.classifyId) |
| | | }, |
| | | selectSharpenOutBoundTool() { |
| | | console.log(this.dataSource) |
| | | let ids = this.dataSource.map(item => item.id).join(',') |
| | | this.$refs.selectSharpenOutBoundToolModal.showModal(ids, this.classifyId) |
| | | }, |
| | | add (nodeSelected) { |
| | | this.addShow = false |
| | |
| | | } |
| | | const params = this.dataSource.map(item => { |
| | | return { |
| | | toolLedgerDetailId: item.id, |
| | | toolLedgerDetailId: item.toolLedgerDetailId, |
| | | toolCode: item.toolCode, |
| | | toolId: item.toolId, |
| | | outboundQuantity: item.outboundQuantity, |
| | | outStorehouseType: this.model.outStorehouseType, |
| | | storageLocation: item.storageLocation |
| | | storageLocation: item.storageLocation, |
| | | ratedLife:item.ratedLife, |
| | | useLife:item.useLife |
| | | } |
| | | }) |
| | | console.log(params) |
| | | this.confirmLoading = true; |
| | | postAction(this.url.outbound, params).then((res)=>{ |
| | | if(res.success){ |