| | |
| | | <div |
| | | class="bodyTopStatus" |
| | | > |
| | | <div style="font-weight: bolder;">工单状态</div> |
| | | <div class="statusItem" :class="{statusItemLight:form.mesorderstus===''}" @click="statusChange('')">全部</div> |
| | | <div class="statusItem" :class="{statusItemLight:form.mesorderstus==='NEW'}" @click="statusChange('NEW')">新订单</div> |
| | | <div class="statusItem" :class="{statusItemLight:form.mesorderstus==='ALLO'}" @click="statusChange('ALLO')">已派发</div> |
| | | <div class="statusItem" :class="{statusItemLight:form.mesorderstus==='START'}" @click="statusChange('START')">开工</div> |
| | | <div class="statusItem" :class="{statusItemLight:form.mesorderstus==='CLOSED'}" @click="statusChange('CLOSED')">完工</div> |
| | | <div style="font-weight: bolder;">工单状态:</div> |
| | | <div class="statusItem" :class="{statusItemLight:true}" @click="statusChange('')">全部</div> |
| | | <div class="statusItem" :class="{statusItemLight1:true}" @click="statusChange('NEW')">新订单</div> |
| | | <div class="statusItem" :class="{statusItemLight2:true}" @click="statusChange('ALLO')">已派发</div> |
| | | <div class="statusItem" :class="{statusItemLight3:true}" @click="statusChange('START')">开工</div> |
| | | <div class="statusItem" :class="{statusItemLight4:true}" @click="statusChange('CLOSED')">完工</div> |
| | | </div> |
| | | |
| | | <div class="bodyTopButtonGroup" style="justify-content: space-between;margin-top: 5px;"> |
| | | <div style="display: flex"> |
| | | <el-button v-waves type="primary" icon="el-icon-circle-plus-outline" @click="add('add')">新增</el-button> |
| | | <el-button v-waves type="success" icon="el-icon-connection" @click="send">派发</el-button> |
| | | <el-button v-waves type="success" icon="el-icon-connection" @click="send();tableDataDetail=[]">派发</el-button> |
| | | </div> |
| | | |
| | | <el-button v-waves type="primary" @click="batchUpdate"><i |
| | | <el-button v-waves type="primary" @click="batchUpdate();tableDataDetail=[]"><i |
| | | class="el-icon-edit" |
| | | style="margin-right: 0;" |
| | | /> 批量绑定 |
| | |
| | | <el-select |
| | | v-model="form.wkshopcode" |
| | | filterable |
| | | multiple |
| | | collapse-tags |
| | | :popper-append-to-body="false" |
| | | style="width: 200px" |
| | | placeholder="请选择" |
| | |
| | | class="bodySearchReset" |
| | | :style="{marginLeft:$store.state.app.sidebar.opened? $store.state.settings.menuIsHorizontal?'15%':'3%':'10%'}" |
| | | > |
| | | <el-button v-waves type="primary" icon="el-icon-search" @click="search">查询</el-button> |
| | | <el-button v-waves type="info" icon="el-icon-refresh" @click="reset">重置</el-button> |
| | | <el-button v-waves type="primary" icon="el-icon-search" @click="search();tableDataDetail=[]">查询</el-button> |
| | | <el-button v-waves type="info" icon="el-icon-refresh" @click="reset();tableDataDetail=[]">重置</el-button> |
| | | </div> |
| | | |
| | | </el-form> |
| | |
| | | border |
| | | :summary-method="getSummaries" |
| | | show-summary |
| | | :row-class-name="tableRowClassName" |
| | | :row-class-name="tableRowClassName2" |
| | | :style="{width: 100+'%',height:isExpandForm?tableHeight:(tableHeight+80)+'px'}" |
| | | highlight-current-row |
| | | :header-cell-style="this.$headerCellStyle" |
| | |
| | | type="selection" |
| | | width="50" |
| | | :selectable="selected" |
| | | class-name="fixed-column" |
| | | /> |
| | | <el-table-column |
| | | prop="rowNum" |
| | | width="50" |
| | | width="80" |
| | | label="序号" |
| | | fixed |
| | | class-name="fixed-column" |
| | | /> |
| | | <el-table-column |
| | | prop="status" |
| | |
| | | label="操作" |
| | | width="160" |
| | | fixed="right" |
| | | class-name="fixed-column" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div class="operationClass"> |
| | |
| | | v-if="mesSetting.workOrder" |
| | | class="el-icon-files" |
| | | style="cursor: pointer;color:#42b983;margin-right: 15px" |
| | | @click="pre(row,1)" |
| | | @click.stop="pre(row,1)" |
| | | /> |
| | | </el-tooltip> |
| | | |
| | |
| | | <i |
| | | class="el-icon-edit-outline" |
| | | :style="{color:$store.state.settings.theme}" |
| | | @click="edit('edit',row)" |
| | | @click.stop="edit('edit',row)" |
| | | /> |
| | | </el-tooltip> |
| | | |
| | | <el-tooltip v-del-tab-index class="item" effect="dark" content="删除" placement="top"> |
| | | <i class="el-icon-delete" :style="{color:$store.state.settings.theme}" @click="del(row)" /> |
| | | <i class="el-icon-delete" :style="{color:$store.state.settings.theme}" @click.stop="del(row)" /> |
| | | </el-tooltip> |
| | | |
| | | <el-tooltip class="item" effect="dark" content="打印工单" placement="top"> |
| | |
| | | :style="{color:$store.state.settings.theme}" |
| | | class="el-icon-printer" |
| | | style="cursor: pointer;margin-right: 15px" |
| | | @click="handlePrint(row.wo_code,row.saleOrderCod,row)" |
| | | @click.stop="handlePrint(row.wo_code,row.saleOrderCod,row)" |
| | | /> |
| | | </el-tooltip> |
| | | |
| | |
| | | class="el-icon-view" |
| | | style="cursor: pointer;" |
| | | :style="{color:$store.state.settings.theme}" |
| | | @click="edit('view',row)" |
| | | @click.stop="edit('view',row)" |
| | | /> |
| | | </el-tooltip> |
| | | |
| | |
| | | align="right" |
| | | layout="total,prev, pager, next,sizes,jumper" |
| | | popper-class="select_bottom" |
| | | @pagination="getMesOrderSearch" |
| | | @pagination="getMesOrderSearch();tableDataDetail=[]" |
| | | /> |
| | | |
| | | <div class="elTableDiv"> |
| | |
| | | v-model="dialogForm.mesqty" |
| | | oninput="value=value.replace(/[^\d]/g,'')" |
| | | style="width: 200px" |
| | | @input="mesqtyInputChange" |
| | | /> |
| | | <!-- oninput="value=value.replace(/[^0-9*.{1}0-9*]/g,'')"--> |
| | | </el-form-item> |
| | |
| | | class="stepSelectedValueClass" |
| | | style="width: 930px;" |
| | | multiple |
| | | filterable |
| | | placeholder="请选择相对应工序" |
| | | @change="stepSelectedValueChange" |
| | | > |
| | |
| | | class="stepSelectedValueClass" |
| | | style="width: 930px;" |
| | | multiple |
| | | filterable |
| | | placeholder="请选择相对应工序" |
| | | @change="val=>stepSelectedValueChangeBatchUpdate(val,index)" |
| | | > |
| | |
| | | tableHeight: 0, |
| | | username: '', |
| | | form: { |
| | | wkshopcode: '', // 车间编码 |
| | | wkshopcode: [], // 车间编码 |
| | | mesorderstus: '', // 工单状态码 |
| | | mesordercode: '', // 工单编号 |
| | | partcode: '', // 产品编码 |
| | |
| | | // }) |
| | | }, |
| | | methods: { |
| | | mesqtyInputChange(val) { |
| | | if (this.stepTableData && this.stepTableData.length > 0) { |
| | | this.stepTableData.forEach(i => { |
| | | i.sumqty = Math.floor(parseFloat(val) * (1 + (parseFloat(i.ratio) / 100))) |
| | | }) |
| | | } |
| | | }, |
| | | statusChange(val) { |
| | | this.tableDataDetail = [] |
| | | this.form.mesorderstus = val |
| | | this.getMesOrderSearch() |
| | | }, |
| | |
| | | tableRowClassName({ row, rowIndex }) { |
| | | return 'custom-row' |
| | | }, |
| | | tableRowClassName2({ row, rowIndex }) { |
| | | if (row.status === 'NEW') { |
| | | return 'custom-row1' |
| | | } |
| | | if (row.status === 'ALLO') { |
| | | return 'custom-row2' |
| | | } |
| | | if (row.status === 'START') { |
| | | return 'custom-row3' |
| | | } |
| | | if (row.status === 'CLOSED') { |
| | | return 'custom-row4' |
| | | } |
| | | }, |
| | | handleRequest() { |
| | | this.getMesOrderSearch().then(res => { |
| | | if (res.code === '200') { |
| | |
| | | // } |
| | | |
| | | const data = { |
| | | wkshopcode: this.form.wkshopcode, |
| | | wkshopcode: this.form.wkshopcode.join(','), |
| | | mesorderstus: this.form.mesorderstus, // 工单状态码 |
| | | mesordercode: this.form.mesordercode, // 工单编号 |
| | | partcode: this.form.partcode, // 产品编码 |
| | |
| | | |
| | | // 重置 |
| | | reset(val) { |
| | | this.form.wkshopcode = '' |
| | | this.form.wkshopcode = [] |
| | | this.form.mesorderstus = '' |
| | | this.form.mesordercode = '' |
| | | this.form.partcode = '' |
| | |
| | | if (this.form.page > 1 && this.tableData.length === 1) { |
| | | this.form.page-- |
| | | } |
| | | this.tableDataDetail = [] |
| | | this.getMesOrderSearch() |
| | | } |
| | | }) |
| | |
| | | return this.$message.error('有序报工情况下,超报比例后道工序不能大于前道工序!') |
| | | } |
| | | } |
| | | console.log(isNaN(this.dialogForm.mesqty - this.dialogForm.mesqtyinit)) |
| | | // console.log(isNaN(this.dialogForm.mesqty - this.dialogForm.mesqtyinit)) |
| | | const data = { |
| | | wostatus: this.dialogForm.mesorderstus, // 工单状态 |
| | | wocode: this.dialogForm.mesordercode, // 工单号 |
| | |
| | | // this.handlePrint() |
| | | this.$message.success(this.operation === 'add' ? '添加成功!' : '保存成功!') |
| | | this.getMesOrderSearch() |
| | | this.tableDataDetail = [] |
| | | this.$store.state.app.buttonIsDisabled = false |
| | | } else { |
| | | this.$message.error(this.operation === 'add' ? '添加失败!' : '保存失败!') |
| | |
| | | getSummaries(param) { |
| | | const { columns, data } = param |
| | | const sums = [] |
| | | const i = 9 |
| | | const i = 13 |
| | | columns.forEach((column, index) => { |
| | | if (index === i) { |
| | | sums[index] = '总数' |
| | |
| | | |
| | | .statusItemLight{ |
| | | font-weight: bolder; |
| | | color: #42b983; |
| | | //color: #42b983; |
| | | color: #000; |
| | | } |
| | | |
| | | .statusItemLight1{ |
| | | font-weight: bolder; |
| | | color: rgba(245, 108, 108, 1); |
| | | } |
| | | .statusItemLight2{ |
| | | font-weight: bolder; |
| | | color: rgba(230, 162, 60, 1); |
| | | } |
| | | .statusItemLight3{ |
| | | font-weight: bolder; |
| | | color: rgba(144, 147, 153, 1); |
| | | } |
| | | .statusItemLight4{ |
| | | font-weight: bolder; |
| | | color: rgba(103, 194, 58, 1); |
| | | } |
| | | |
| | | </style> |
| | |
| | | .el-table .custom-row { |
| | | background: #f8f8fa; |
| | | } |
| | | |
| | | .el-table .custom-row1 { |
| | | background: rgba(245, 108, 108, 0.4); |
| | | } |
| | | |
| | | .el-table .custom-row2 { |
| | | background: rgba(230, 162, 60, 0.4); |
| | | } |
| | | |
| | | .el-table .custom-row3 { |
| | | background: rgba(144, 147, 153, 0.4); |
| | | } |
| | | |
| | | .el-table .custom-row4 { |
| | | background: rgba(103, 194, 58, 0.4); |
| | | } |
| | | |
| | | .el-table .fixed-column { |
| | | background: #f8f8fa; |
| | | } |
| | | |
| | | </style> |
| | | <style> |
| | | .sortable-ghost { |