123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776 |
- <!-- 成品明细 -->
- <template>
- <div >
- <a-form-model ref="formRef" :model="form">
- <a-table
- ref="table"
- size="middle"
- bordered
- id='sonList'
- :columns="columns"
- rowKey="rowNo"
- :dataSource="form.dataSource"
- :pagination="false"
- :scroll="{ x: 6500, y: 300 }"
- :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
- @change="handleTableChange"
- >
- <span slot="framesCountTitle" class="form-table-heard">
- 框数量
- </span>
- <span slot="leafCountTitle" class="form-table-heard">
- 扇数量
- </span>
- <span slot="inventoryCodeTitle" class="form-table-heard">
- 料品编码
- </span>
- <span slot="quantityTitle" class="form-table-heard">
- 成品主数量
- </span>
- <span slot="unQuantityTitle" class="form-table-heard">
- 成品辅数量
- </span>
-
- <template slot="billingType" slot-scope="text, record, index">
- <a-form-model-item prop="billingType" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.billingType }}</span>
- <a-select v-model="record.billingType" style='width:100%' v-else>
- <a-select-option value='铝合金门窗'> 铝合金门窗</a-select-option>
- <a-select-option value='双开窗'> 双开窗</a-select-option>
- </a-select>
- </a-form-model-item>
- </template>
- <template slot="batch" slot-scope="text, record, index">
- <a-form-model-item prop="batch" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.batch }}</span>
- <a-input placeholder="请输入" v-model="record.batch" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="inventoryCode" slot-scope="text, record, index">
- <a-form-model-item :prop="'dataSource.'+index+'.inventoryCode'" class='sonItem' :rules="rules.inventoryCode">
- <span v-if="title=='订单操作'">{{ record.inventoryCode }}</span>
- <a-input-search placeholder="请输入" v-model="record.inventoryCode" @search="onSearchInven(record)" readOnly v-else></a-input-search>
- </a-form-model-item>
- </template>
- <template slot="quantity" slot-scope="text, record, index">
- <a-form-model-item :prop="'dataSource.'+index+'.quantity'" class='sonItem' :rules="rules.quantity">
- <span v-if="title=='订单操作'">{{ record.quantity }}</span>
- <a-input placeholder="请输入" v-model="record.quantity" @change="changeQuantity(record)" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="unQuantity" slot-scope="text, record, index">
- <a-form-model-item :prop="'dataSource.'+index+'.unQuantity'" class='sonItem' :rules="rules.unQuantity">
- <span v-if="title=='订单操作'">{{ record.unQuantity }}</span>
- <a-input placeholder="请输入" v-model="record.unQuantity" @change="changeUnQuantity(record)" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="quantityExecuteIn" slot-scope="text, record, index">
- <a-form-model-item prop="quantityExecuteIn" class='sonItem'>
- <a-input placeholder="请输入" v-model="record.quantityExecuteIn" v-if="record.allowEditNum=='yes'" @blur="changeQuantityExecuteIn(index,record)"></a-input>
- <span v-else>{{ record.quantityExecuteIn }}</span>
- </a-form-model-item>
- </template>
- <template slot="framesCount" slot-scope="text, record, index">
- <a-form-model-item :prop="'dataSource.'+index+'.framesCount'" class='sonItem' :rules="rules.framesCount">
- <span v-if="title=='订单操作'">{{ record.framesCount }}</span>
- <a-input placeholder="请输入" v-model="record.framesCount" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="leafCount" slot-scope="text, record, index">
- <a-form-model-item :prop="'dataSource.'+index+'.leafCount'" class='sonItem' :rules="rules.leafCount">
- <span v-if="title=='订单操作'">{{ record.leafCount }}</span>
- <a-input placeholder="请输入" v-model="record.leafCount" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="executeInLeaf" slot-scope="text, record, index">
- <a-form-model-item prop="executeInLeaf" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.executeInLeaf }}</span>
- <a-input placeholder="请输入" v-model="record.executeInLeaf" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="executeInFrames" slot-scope="text, record, index">
- <a-form-model-item prop="executeInFrames" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.executeInFrames }}</span>
- <a-input placeholder="请输入" v-model="record.executeInFrames" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="executeOutLeaf" slot-scope="text, record, index">
- <a-form-model-item prop="executeOutLeaf" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.executeOutLeaf }}</span>
- <a-input placeholder="请输入" v-model="record.executeOutLeaf" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="executeOutFrames" slot-scope="text, record, index">
- <a-form-model-item prop="executeOutFrames" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.executeOutFrames }}</span>
- <a-input placeholder="请输入" v-model="record.executeOutFrames" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="model" slot-scope="text, record, index">
- <a-form-model-item prop="model" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.model }}</span>
- <a-input placeholder="请输入" v-model="record.model" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="color" slot-scope="text, record, index">
- <a-form-model-item prop="color" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.color }}</span>
- <a-input placeholder="请输入" v-model="record.color" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="fixedNum" slot-scope="text, record, index">
- <a-form-model-item prop="fixedNum" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.fixedNum }}</span>
- <a-input placeholder="请输入" v-model="record.fixedNum" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="fixedLength" slot-scope="text, record, index">
- <a-form-model-item prop="fixedLength" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.fixedLength }}</span>
- <a-input placeholder="请输入" v-model="record.fixedLength" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="widthHeight" slot-scope="text, record, index">
- <a-form-model-item prop="widthHeight" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.widthHeight }}</span>
- <a-input placeholder="请输入" v-model="record.widthHeight" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="pieces" slot-scope="text, record, index">
- <a-form-model-item prop="pieces" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.pieces }}</span>
- <a-input placeholder="请输入" v-model="record.pieces" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="remarks" slot-scope="text, record, index">
- <a-form-model-item prop="remarks" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.remarks }}</span>
- <a-input placeholder="请输入" v-model="record.remarks" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="meterWeight" slot-scope="text, record, index">
- <a-form-model-item prop="meterWeight" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.meterWeight }}</span>
- <a-input placeholder="请输入" v-model="record.meterWeight" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="decorationLength" slot-scope="text, record, index">
- <a-form-model-item prop="decorationLength" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.decorationLength }}</span>
- <a-input placeholder="请输入" v-model="record.decorationLength" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="windowNo" slot-scope="text, record, index">
- <a-form-model-item prop="windowNo" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.windowNo }}</span>
- <a-input placeholder="请输入" v-model="record.windowNo" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="exclusiveZone" slot-scope="text, record, index">
- <a-form-model-item prop="exclusiveZone" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.exclusiveZone }}</span>
- <a-input placeholder="请输入" v-model="record.exclusiveZone" v-esle></a-input>
- </a-form-model-item>
- </template>
- <template slot="widthLength" slot-scope="text, record, index">
- <a-form-model-item prop="widthLength" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.widthLength }}</span>
- <a-input placeholder="请输入" v-model="record.widthLength" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="height" slot-scope="text, record, index">
- <a-form-model-item prop="height" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.height }}</span>
- <a-input placeholder="请输入" v-model="record.height" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="buildingNumber" slot-scope="text, record, index">
- <a-form-model-item prop="buildingNumber" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.buildingNumber }}</span>
- <a-input placeholder="请输入" v-model="record.buildingNumber" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="framesTang" slot-scope="text, record, index">
- <a-form-model-item prop="framesTang" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.framesTang }}</span>
- <a-input placeholder="请输入" v-model="record.framesTang" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="semiClass" slot-scope="text, record, index">
- <a-form-model-item prop="semiClass" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.semiClass }}</span>
- <a-input placeholder="请输入" v-model="record.semiClass" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="area" slot-scope="text, record, index">
- <a-form-model-item prop="area" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.area }}</span>
- <a-input placeholder="请输入" v-model="record.area" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="cuttingLength" slot-scope="text, record, index">
- <a-form-model-item prop="cuttingLength" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.cuttingLength }}</span>
- <a-input placeholder="请输入" v-model="record.cuttingLength" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="cuttingLeftDown" slot-scope="text, record, index">
- <a-form-model-item prop="cuttingLeftDown" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.cuttingLeftDown }}</span>
- <a-input placeholder="请输入" v-model="record.cuttingLeftDown" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="cuttingRightTop" slot-scope="text, record, index">
- <a-form-model-item prop="cuttingRightTop" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.cuttingRightTop }}</span>
- <a-input placeholder="请输入" v-model="record.cuttingRightTop" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="series" slot-scope="text, record, index">
- <a-form-model-item prop="series" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.series }}</span>
- <a-input placeholder="请输入" v-model="record.series" v-else></a-input>
- </a-form-model-item>
- </template>
- <template slot="glassNumber" slot-scope="text, record, index">
- <a-form-model-item prop="glassNumber" class='sonItem'>
- <span v-if="title=='订单操作'">{{ record.glassNumber }}</span>
- <a-input placeholder="请输入" v-model="record.glassNumber" v-else></a-input>
- </a-form-model-item>
- </template>
- </a-table>
- </a-form-model>
- <inventoryPopup ref="inventoryPopup" @okData="okDataInvent"></inventoryPopup>
- </div>
- </template>
-
- <script>
- import { JeecgListMixin } from '@/mixins/JeecgListMixin'
- import JEllipsis from '@/components/jeecg/JEllipsis'
- import { httpAction ,getAction,postAction,putAction} from '@/api/manage'
- import inventoryPopup from '../../Popup/inventoryPopup.vue'
- import moment from 'moment'
- export default {
- name: 'productDetails', // Tabs 详情
- mixins: [JeecgListMixin],
- components: {
- JEllipsis,
- moment,
- inventoryPopup,
- },
- data() {
- return {
- selectedRowKeys:[],
- selectedRows:[],
- planOrg:'',
- form:{
- dataSource:[],
- },
- disableMixinCreated:'1',
- columns: [
- {
- title: '行号',
- dataIndex: '',
- key: 'rowIndex',
- width: 60,
- align: "center",
- customRender:function (t, r, index) {
- return parseInt(index)+1;
- }
- },
- {
- title: '开票类型',
- align:"center",
- dataIndex: 'billingType',
- ellipsis: true,
- scopedSlots: { customRender: 'billingType' }
- },
- {
- title: '项目编码',
- align:"center",
- dataIndex: 'projectCode',
- ellipsis: true,
- },
- {
- title: '项目名称',
- align:"center",
- dataIndex: 'projectName',
- ellipsis: true,
- },
- {
- title: '批次',
- align:"center",
- dataIndex: 'batch',
- ellipsis: true,
- scopedSlots: { customRender: 'batch' }
- },
- {
- // title: '料品编码',
- align:"center",
- dataIndex: 'inventoryCode',
- ellipsis: true,
- scopedSlots: { customRender: 'inventoryCode' } ,
- slots:{title:'inventoryCodeTitle'},
- },
- {
- title: '料品名称',
- align:"center",
- dataIndex: 'inventoryName',
- ellipsis: true,
- },
- {
- title: '成品计量单位',
- align:"center",
- dataIndex: 'unit',
- ellipsis: true,
- },
- {
- title: '成品辅计量单位',
- align:"center",
- dataIndex: 'auxiliaryUnit',
- ellipsis: true,
- },
- {
- // title: '成品主数量',
- align:"center",
- dataIndex: 'quantity',
- ellipsis: true,
- scopedSlots: { customRender: 'quantity' } ,
- slots:{title:'quantityTitle'},
- },
- {
- // title: '成品辅数量',
- align:"center",
- dataIndex: 'unQuantity',
- ellipsis: true,
- scopedSlots: { customRender: 'unQuantity' } ,
- slots:{title:'unQuantityTitle'},
- },
- {
- title: '税率',
- align:"center",
- dataIndex: 'rate',
- ellipsis: true,
- },
- {
- title: '已入库成品数量',
- align:"center",
- dataIndex: 'quantityExecuteIn',
- ellipsis: true,
- scopedSlots: { customRender: 'quantityExecuteIn' }
- },
- {
- // title: '框数量',
- align:"center",
- dataIndex: 'framesCount',
- ellipsis: true,
- scopedSlots: { customRender: 'framesCount' } ,
- slots:{title:'framesCountTitle'},
- },
- {
- // title: '扇数量',
- align:"center",
- dataIndex: 'leafCount',
- ellipsis: true,
- scopedSlots: { customRender: 'leafCount' } ,
- slots:{title:'leafCountTitle'},
- },
- {
- title: '已入库框数量',
- align:"center",
- dataIndex: 'executeInFrames',
- ellipsis: true,
- // scopedSlots: { customRender: 'executeInFrames' }
- },
- {
- title: '已入库扇数量',
- align:"center",
- dataIndex: 'executeInLeaf',
- ellipsis: true,
- // scopedSlots: { customRender: 'executeInLeaf' } ,
- },
- {
- title: '已出库框数量',
- align:"center",
- dataIndex: 'executeOutFrames',
- ellipsis: true,
- // scopedSlots: { customRender: 'executeOutFrames' }
- },
- {
- title: '已出库扇数量',
- align:"center",
- dataIndex: 'executeOutLeaf',
- ellipsis: true,
- // scopedSlots: { customRender: 'executeOutLeaf' }
- },
- {
- title: '规格',
- align:"center",
- dataIndex: 'specs',
- ellipsis: true,
- }, {
- title: '料品属性',
- align:"center",
- dataIndex: 'attribute',
- ellipsis: true,
- },
- {
- title: '型号',
- align:"center",
- dataIndex: 'model',
- ellipsis: true,
- scopedSlots: { customRender: 'model' }
- },
- {
- title: '颜色',
- align:"center",
- dataIndex: 'color',
- ellipsis: true,
- scopedSlots: { customRender: 'color' }
- },
- {
- title: '支数',
- align:"center",
- dataIndex: 'fixedNum',
- ellipsis: true,
- scopedSlots: { customRender: 'fixedNum' }
- },
- {
- title: '定尺',
- align:"center",
- dataIndex: 'fixedLength',
- ellipsis: true,
- scopedSlots: { customRender: 'fixedLength' }
- },
- {
- title: '宽/高',
- align:"center",
- dataIndex: 'widthHeight',
- ellipsis: true,
- scopedSlots: { customRender: 'widthHeight' }
- },
- {
- title: '片数',
- align:"center",
- dataIndex: 'pieces',
- ellipsis: true,
- scopedSlots: { customRender: 'pieces' }
- },
- {
- title: '备注',
- align:"center",
- dataIndex: 'remarks',
- ellipsis: true,
- scopedSlots: { customRender: 'remarks' }
- },
- {
- title: '米重',
- align:"center",
- dataIndex: 'meterWeight',
- ellipsis: true,
- scopedSlots: { customRender: 'meterWeight' }
- },
- {
- title: '装饰面周长',
- align:"center",
- dataIndex: 'decorationLength',
- ellipsis: true,
- scopedSlots: { customRender: 'decorationLength' }
- },
- {
- title: '窗号',
- align:"center",
- dataIndex: 'windowNo',
- ellipsis: true,
- scopedSlots: { customRender: 'windowNo' }
- },
- {
- title: '专用区',
- align:"center",
- dataIndex: 'exclusiveZone',
- ellipsis: true,
- scopedSlots: { customRender: 'exclusiveZone' }
- },
- {
- title: '宽度/长度',
- align:"center",
- dataIndex: 'widthLength',
- ellipsis: true,
- scopedSlots: { customRender: 'widthLength' }
- },
- {
- title: '高度',
- align:"center",
- dataIndex: 'height',
- ellipsis: true,
- scopedSlots: { customRender: 'height' }
- },
- {
- title: '楼层楼号',
- align:"center",
- dataIndex: 'buildingNumber',
- ellipsis: true,
- scopedSlots: { customRender: 'buildingNumber' }
- },
- {
- title: '樘数(数量)',
- align:"center",
- dataIndex: 'framesTang',
- ellipsis: true,
- scopedSlots: { customRender: 'framesTang' }
- },
-
-
- {
- title: '半成品分类',
- align:"center",
- dataIndex: 'semiClass',
- ellipsis: true,
- scopedSlots: { customRender: 'semiClass' }
- },
- {
- title: '面积',
- align:"center",
- dataIndex: 'area',
- ellipsis: true,
- scopedSlots: { customRender: 'area' }
- },
- {
- title: '切割长度',
- align:"center",
- dataIndex: 'cuttingLength',
- ellipsis: true,
- scopedSlots: { customRender: 'cuttingLength' }
- },
- {
- title: '切割角度左下',
- align:"center",
- dataIndex: 'cuttingLeftDown',
- ellipsis: true,
- scopedSlots: { customRender: 'cuttingLeftDown' }
- },
- {
- title: '切割角度右上',
- align:"center",
- dataIndex: 'cuttingRightTop',
- ellipsis: true,
- scopedSlots: { customRender: 'cuttingRightTop' }
- },
-
- {
- title: '系列',
- align:"center",
- dataIndex: 'series',
- ellipsis: true,
- scopedSlots: { customRender: 'series' }
- },
- {
- title: '玻璃编号',
- align:"center",
- dataIndex: 'glassNumber',
- ellipsis: true,
- scopedSlots: { customRender: 'glassNumber' }
- },
- {
- title: '同步状态',
- align:"center",
- dataIndex: 'sync',
- ellipsis: true,
- },
- {
- title: '同步信息',
- align:"center",
- dataIndex: 'syncInfo',
- ellipsis: true,
- width:460,
- },
- ],
- rules:{
- framesCount:{required:true,message:"不可为空"},
- leafCount:{required:true,message:"不可为空"},
- inventoryCode:{required:true,message:"不可为空"},
- quantity:{required:true,message:"不可为空"},
- unQuantity:{required:true,message:"不可为空"},
- },
- }
- },
- props:{
- title: {
- type: String,
- default:''
- },
- },
-
- created() {},
- methods: {
- onSelectChange(selectedRowKeys, selectionRows) {
- this.selectedRowKeys = selectedRowKeys;
- this.selectedRows = selectionRows;
- },
- addList(projectCode,projectName){
- this.form.dataSource.push({rowNo: this.form.dataSource.length+1,projectCode:projectCode,projectName:projectName})
- },
- //改变主数量计算辅数量
- changeQuantity(record){
- if(record.rate){
- var num = (Number(record.quantity)*Number(record.rate)).toFixed(2)
- this.$set(record,'unQuantity',num)
- }
-
- },
- //改变辅数量计算主数量
- changeUnQuantity(record){
- if(record.rate){
- var numUn = (Number(record.unQuantity)/Number(record.rate)).toFixed(2)
- this.$set(record,'quantity',numUn)
- }
-
- },
- onSearchInven(record){
- if(!this.planOrg||this.planOrg==''){
- this.$message.warning('请选择生产组织!')
- }else{
- this.$refs.inventoryPopup.visible = true
- this.$refs.inventoryPopup.getData(this.planOrg)
- this.$refs.inventoryPopup.record=record
- }
- },
- // 修改已执行数量
- editNum(index){
- this.form.dataSource[index-1].allowEditNum = 'yes'
- this.$forceUpdate();
- },
- changeQuantityExecuteIn(index,record){
- if(Number(record.quantityExecuteIn)>Number(record.quantity)||record.quantityExecuteIn<0){
- this.$message.error('已入库成品数量需大于成品主数量,且大于0!');
- }else{
- this.$confirm({
- content: `是否保存修改后已执行数量?`,
- onOk: () => {
- postAction('/productionOrder/madeProductionOrders/updateFinishedNum',record).then(res=>{
- if(res.success){
- this.$message.success('修改成功')
- this.form.dataSource[index].allowEditNum = ''
- this.$forceUpdate();
- this.selectedRowKeys = []
- this.selectedRows = []
- }else{
- this.$message.error(res.message);
- }
- })
- }
- })
- }
-
- },
- validateList(){
- let flag = null
- this.$refs.formRef.validate(valid =>{
- if(valid){
- flag = true
- }else{
- flag = false
- }
- })
- return flag
- },
- okDataInvent(data,recoerd){
- this.$set(recoerd,'inventoryCode',data.Code)
- this.$set(recoerd,'inventoryName',data.Name)
- this.$set(recoerd,'specs',data.SPECS)
- this.$set(recoerd,'unit',data.unit)
- this.$set(recoerd,'auxiliaryUnit',data.auxiliaryUnit )
- this.$set(recoerd,'attribute',data.Code1 )
- this.$set(recoerd,'inventory',data.ID )
- this.$set(recoerd,'quantity','' )
- this.$set(recoerd,'unQuantity','')
- this.$set(recoerd,'rate',data.rate)
- },
- delectRow(){
- if( this.selectedRowKeys.length==0){
- this.$message.warning('请勾选子表数据!')
- }else{
- this.selectedRowKeys.map(event=>{
- this.form.dataSource = this.form.dataSource.filter( (x)=> {return x.rowNo !== event});
- })
- }
- },
- },
-
- computed: {
- // 合计数据
- // sumInfoSource() {}
- }
- }
- </script>
-
- <style lang="less" scoped>
- /* @import '~@assets/less/common.less' */
- /deep/.ant-input{
- height:29px;
- }
- /deep/.ant-select-selection--single {
- height: 29px;
- }
- /deep/.ant-select{
- font-size: 12px;
- }
- /deep/.ant-form label{
- font-size: 12px;
- }
- /deep/.table-page-search-wrapper .ant-form-inline .ant-form-item{
- margin-bottom:9px
- }
- /deep/.moddle>.ant-card-body{
- padding-bottom:0px;
- padding-top: 12px;
- }
- /deep/.top>.ant-card-body{
- padding-bottom:0px;
- padding-top: 12px;
- }
- /deep/.ant-btn{
- height:28px
- }
- /deep/.ant-modal-body{
- padding-bottom: 0px;
- padding-top: 0px;
- }
- // /deep/.ant-modal-body{
- // background: #f0f2f5;
- // }
- /deep/.ant-modal-content{
- background: #f0f2f5;
- }
- /deep/.ant-card-body .table-operator {
- margin-bottom: 0px;
- }
- /deep/.three>.ant-card-body{
- padding-bottom:12px;
- padding-top: 12px;
- }
- /deep/.bottom>.ant-card-body{
- padding-bottom:0px;
- padding-top: 12px;
- }
- /deep/.ant-calendar-picker{
- min-width: 0px !important;
- }
- /deep/.sonItem {
- margin-bottom:0px !important
- }
- /deep/#sonList>.ant-spin-nested-loading>.ant-spin-container>.ant-table>.ant-table-content>.ant-table-scroll>.ant-table-body>.ant-table-fixed>.ant-table-tbody > tr > td {
- padding: 0px 8px !important;
- }
- .form-table-heard:before {
- content:'*';
- color:red
- }
- /deep/.ant-form-explain, .ant-form-split {
- display: none;
- }
- </style>
-
|