¶Ô±ÈÐÂÎļþ |
| | |
| | | <template> |
| | | <!--æ¯æå
¨å±ç¼©æ¾--> |
| | | <j-modal |
| | | :visible="visible" |
| | | :title="title" |
| | | switchFullscreen |
| | | :width="1200" |
| | | @ok="handleSubmit" |
| | | @cancel="close" |
| | | style="top: 50px" |
| | | cancelText="å
³é" |
| | | > |
| | | <a-card :bordered="false"> |
| | | <div class="table-page-search-wrapper"> |
| | | <a-form layout="inline" @keyup.enter.native="searchQuery"> |
| | | <a-row :gutter="24"> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="å·¥å
·ç¼ç "> |
| | | <a-input placeholder="请è¾å
¥å·¥å
·ç¼ç ,æ¯ææ¨¡ç³æ¥è¯¢" v-model="queryParam.toolCode"></a-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="æ è®°"> |
| | | <a-input placeholder="请è¾å
¥æ è®°,æ¯ææ¨¡ç³æ¥è¯¢" v-model="queryParam.groupCompanySign"></a-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | <a-col :xl="6" :lg="7" :md="8" :sm="24"> |
| | | <a-form-item label="å·¥å
·ç®ç§°"> |
| | | <a-input placeholder="请è¾å
¥å·¥å
·ç®ç§°" v-model="queryParam.shortCalled"></a-input> |
| | | </a-form-item> |
| | | </a-col> |
| | | |
| | | <a-button type="primary" @click="searchQuery" icon="search">æ¥è¯¢</a-button> |
| | | <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">éç½®</a-button> |
| | | </a-row> |
| | | </a-form> |
| | | </div> |
| | | <!--å·¥å
·å表--> |
| | | <a-table |
| | | ref="table" |
| | | :scroll="scrollTrigger" |
| | | size="middle" |
| | | rowKey="id" |
| | | :columns="columns" |
| | | :dataSource="dataSource" |
| | | :pagination="ipagination" |
| | | :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type:'radio'}" |
| | | :loading="loading" |
| | | @change="handleTableChange" |
| | | > |
| | | </a-table> |
| | | </a-card> |
| | | </j-modal> |
| | | </template> |
| | | |
| | | <script> |
| | | import { filterObj } from '@/utils/util' |
| | | import { getAction } from '@/api/manage' |
| | | import { JeecgListMixin } from '@/mixins/JeecgListMixin' |
| | | |
| | | export default { |
| | | name: 'ChangeClassifyModal', |
| | | mixins: [JeecgListMixin], |
| | | components: {}, |
| | | props: { |
| | | classifyId:{ |
| | | type:String |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | queryParam: {}, |
| | | columns: [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 50, |
| | | align: 'center', |
| | | customRender: function (t, r, index) { |
| | | return parseInt(index) + 1 |
| | | }, |
| | | }, |
| | | { |
| | | title: 'å·¥å
·ç¼ç ', |
| | | align: 'center', |
| | | dataIndex: 'toolCode', |
| | | }, |
| | | { |
| | | title: 'å·¥å
·åç§°', |
| | | align: 'center', |
| | | dataIndex: 'chineseName', |
| | | }, |
| | | { |
| | | title: 'å·¥å
·ç®ç§°', |
| | | align: 'center', |
| | | dataIndex: 'shortCalled', |
| | | }, |
| | | { |
| | | title: 'æ è®°', |
| | | align: 'center', |
| | | dataIndex: 'groupCompanySign', |
| | | }, |
| | | { |
| | | title: 'åºä½å·', |
| | | align: 'center', |
| | | dataIndex: 'positionCode', |
| | | }, |
| | | { |
| | | title: 'åå·/å¾å·', |
| | | align: 'center', |
| | | dataIndex: 'toolModel', |
| | | }, |
| | | { |
| | | title: 'å·¥å
፱Ȍ', |
| | | align: 'center', |
| | | dataIndex: 'applicationTypeName', |
| | | }, |
| | | ], |
| | | selectedRowKeys: [], |
| | | oldSlelectRows: [], |
| | | scrollTrigger: {}, |
| | | dataSource: [], |
| | | selectionRows: [], |
| | | allSelectionRows: [], |
| | | title: 'æ ¹æ®æ¥è¯¢ç»æéæ©å·¥å
·ç¼ç ', |
| | | ipagination: { |
| | | current: 1, |
| | | pageSize: 10, |
| | | pageSizeOptions: ['5', '10', '20'], |
| | | showTotal: (total, range) => { |
| | | return range[0] + '-' + range[1] + ' å
±' + total + 'æ¡' |
| | | }, |
| | | showQuickJumper: true, |
| | | showSizeChanger: true, |
| | | total: 0, |
| | | }, |
| | | isorter: { |
| | | column: 'toolCode', |
| | | order: 'desc', |
| | | }, |
| | | departTree: [], |
| | | visible: false, |
| | | loading: false, |
| | | url: { |
| | | // list: '/base/tooling/list', |
| | | list: '/tms/baseTools/paraCommonToolList', |
| | | }, |
| | | oldId:'' |
| | | } |
| | | }, |
| | | computed: { |
| | | |
| | | }, |
| | | watch: {}, |
| | | created() {}, |
| | | methods: { |
| | | |
| | | |
| | | showModal(oldId) { |
| | | this.oldId = oldId |
| | | this.visible = true |
| | | this.loadData(1) |
| | | }, |
| | | getQueryParams() { |
| | | let param = Object.assign({}, this.queryParam, this.isorter) |
| | | param.field = this.getQueryField() |
| | | param.pageNo = this.ipagination.current |
| | | param.pageSize = this.ipagination.pageSize |
| | | return filterObj(param) |
| | | }, |
| | | //æ¥è¯¢æ¡ä»¶å¤ç |
| | | getQueryField() { |
| | | let str = 'id,' |
| | | for (let a = 0; a < this.columns.length; a++) { |
| | | str += ',' + this.columns[a].dataIndex |
| | | } |
| | | return str |
| | | }, |
| | | async loadData(arg) { |
| | | if (arg === 1) { |
| | | this.ipagination.current = 1 |
| | | } |
| | | let that = this |
| | | this.loading = true |
| | | let params = this.getQueryParams() //æ¥è¯¢æ¡ä»¶ |
| | | params.classifyId = this.classifyId |
| | | await getAction(this.url.list, params).then((res) => { |
| | | if (res.success) { |
| | | this.dataSource = res.result.records |
| | | this.ipagination.total = res.result.total |
| | | } |
| | | if (res.code === 510) { |
| | | this.$message.warning(res.message) |
| | | } |
| | | this.loading = false |
| | | }) |
| | | }, |
| | | searchReset(num) { |
| | | let that = this |
| | | if (num !== 0) { |
| | | that.loadData(1) |
| | | } |
| | | that.selectborrowIds = [] |
| | | }, |
| | | onSelectChange(selectedRowKeys, selectionRows) { |
| | | this.selectedRowKeys = selectedRowKeys; |
| | | this.selectionRows = selectionRows; |
| | | this.selectionRows[0].oldId = this.oldId |
| | | }, |
| | | close() { |
| | | this.searchReset(0) |
| | | this.selectedRowKeys = [] |
| | | this.visible = false |
| | | }, |
| | | handleTableChange(pagination, filters, sorter) { |
| | | //TODO çé |
| | | if (Object.keys(sorter).length > 0) { |
| | | this.isorter.column = sorter.field |
| | | this.isorter.order = 'ascend' === sorter.order ? 'asc' : 'desc' |
| | | } |
| | | this.ipagination = pagination |
| | | this.loadData() |
| | | }, |
| | | handleSubmit() { |
| | | this.$bus.$emit('selectionToolCode', this.selectionRows[0]); |
| | | this.searchReset(0) |
| | | this.close() |
| | | }, |
| | | onSearch() { |
| | | this.loadData(1) |
| | | }, |
| | | searchQuery() { |
| | | this.loadData(1); |
| | | }, |
| | | searchReset() { |
| | | this.queryParam = {} |
| | | this.loadData(1) |
| | | }, |
| | | }, |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | .ant-table-tbody .ant-table-row td { |
| | | padding-top: 10px; |
| | | padding-bottom: 10px; |
| | | } |
| | | |
| | | #components-layout-demo-custom-trigger .trigger { |
| | | font-size: 18px; |
| | | line-height: 64px; |
| | | padding: 0 24px; |
| | | cursor: pointer; |
| | | transition: color 0.3s; |
| | | } |
| | | </style> |
| | |
| | | </div> |
| | | </template> |
| | | <span slot="action" slot-scope="text, record, index"> |
| | | <a @click="handleChangeClassify(record)" v-if="sharpenShow && !disableSubmit">åæ´å·¥å
·åç±»</a> |
| | | <a-divider type="vertical" v-if="sharpenShow && !disableSubmit"/> |
| | | <a-popconfirm title="ç¡®å®å é¤å?" @confirm="() => handleDelete(record, index)" :disabled="disableSubmit"> |
| | | <a>å é¤</a> |
| | | </a-popconfirm> |
| | |
| | | <j-select-tooling-modal ref="toolingModalForm" @ok="modalFormOk" :classifyId="classifyId"></j-select-tooling-modal> |
| | | <j-select-return-list-modal ref="returnModalForm" @ok="modalFormOk" :classifyId="classifyId"></j-select-return-list-modal> |
| | | <j-select-sharpen-list-modal ref="sharpenModalForm" @ok="modalFormOk" :classifyId="classifyId"></j-select-sharpen-list-modal> |
| | | <change-classify-modal ref="changeClassifyModalForm" @ok="modalFormOk" :classifyId="classifyId"></change-classify-modal> |
| | | |
| | | <div id="printArea" style="display: block;"> |
| | | <div v-for="(item, index) in qrList" :key="index" class="qrcode-item"> |
| | |
| | | <script> |
| | | import pick from 'lodash.pick' |
| | | import JSelectToolingModal from '.././inboundOrder/JSelectToolingModal' |
| | | import ChangeClassifyModal from './ChangeClassifyModal' |
| | | import { ajaxGetDictItems } from '@/api/api' |
| | | import moment from 'moment' |
| | | import { getAction, postAction, requestPut } from '@/api/manage' |
| | |
| | | JSelectReturnListModal, |
| | | JSearchSelectTag, |
| | | JSelectSharpenListModal, |
| | | ChangeClassifyModal |
| | | }, |
| | | data() { |
| | | return { |
| | |
| | | align: 'center', |
| | | dataIndex: 'inStorageQuantity', |
| | | scopedSlots: { customRender: 'inStorageQuantity' }, |
| | | }, |
| | | { |
| | | title: 'æ°å·¥å
·ç¼ç ', |
| | | align: 'center', |
| | | dataIndex: 'newToolCode', |
| | | }, |
| | | { |
| | | title: 'æä½', |
| | |
| | | scanStyles: false |
| | | }); |
| | | }); |
| | | }, |
| | | //å磨ååæ´å·¥å
·åç±» |
| | | handleChangeClassify(record){ |
| | | this.$refs.changeClassifyModalForm.showModal(record.id) |
| | | this.$refs.changeClassifyModalForm.title = '鿩工å
·åç±»' |
| | | this.$refs.changeClassifyModalForm.disableSubmit = false |
| | | } |
| | | }, |
| | | watch: {}, |
| | |
| | | } |
| | | //this.ipaginationm.total = this.dataSource.length |
| | | }) |
| | | this.$bus.$on('selectionToolCode', (data) => { |
| | | //getCurrSelected äºä»¶ æ¥æ¶ç»ä»¶ä¼ éçåæ° |
| | | for (let i = 0; i < this.dataSource.length; i++) { |
| | | console.log("1111",this.dataSource.length,data,this.dataSource[i]) |
| | | if(this.dataSource[i].id == data.oldId){ |
| | | this.dataSource[i].newToolCode = data.toolCode |
| | | this.dataSource[i].newToolCodeId = data.toolCodeId |
| | | this.dataSource[i].goodsShelvesId = data.positionCode |
| | | this.$set(this.dataSource[i],'newToolClassify',data.toolCode) |
| | | } |
| | | } |
| | | // å¼ºå¶æ´æ°è§å¾ |
| | | this.$forceUpdate(); |
| | | //this.ipaginationm.total = this.dataSource.length |
| | | }) |
| | | }, |
| | | } |
| | | </script> |
| | |
| | | onSelectChange(selectedRowKeys, selectionRows) { |
| | | this.selectedRowKeys = selectedRowKeys; |
| | | this.selectionRows = selectionRows; |
| | | const toolCode = this.selectionRows[0].toolCode |
| | | const toolCode = this.selectionRows[0].toolCodeId |
| | | //éè¿idæ¥è¯¢ç®¡çåæ°ååæ°æ°æ® |
| | | getAction(this.url.queryParaByToolCode, { toolCode: toolCode,paraTypeFlag:this.paraTypeFlag}).then((res) => { |
| | | if (res.success) { |
| | |
| | | dataIndex: 'supplierId', |
| | | }, |
| | | { |
| | | title:'åç£¨ç¶æ', |
| | | align:"center", |
| | | dataIndex: 'sharpeningStatus_dictText' |
| | | }, |
| | | { |
| | | title:'å磨æ¶é´', |
| | | align:"center", |
| | | dataIndex: 'sharpeningTime' |