| | |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div class="operationClass"> |
| | | |
| | | <el-tooltip v-del-tab-index class="item" effect="dark" content="SOP预览" placement="top"> |
| | | <i |
| | | v-if="mesSetting.workOrder" |
| | | class="el-icon-files" |
| | | style="cursor: pointer;color:#42b983;margin-right: 15px" |
| | | @click="pre(row,1)" |
| | | /> |
| | | </el-tooltip> |
| | | |
| | | <el-tooltip class="item" effect="dark" content="修改" placement="top"> |
| | | <i |
| | | class="el-icon-edit-outline" |
| | |
| | | show-tooltip-when-overflow |
| | | prop="delive_qty" |
| | | /> |
| | | <!-- <el-table-column--> |
| | | <!-- label="操作"--> |
| | | <!-- width="120"--> |
| | | <!-- fixed="right"--> |
| | | <!-- >--> |
| | | <!-- <template slot-scope="{row}">--> |
| | | <!-- <div class="operationClass">--> |
| | | <!-- <el-tooltip class="item" effect="dark" content="打印工序" placement="top">--> |
| | | <!-- <i--> |
| | | <!-- v-if="tableDataDetail.length!==row.seq"--> |
| | | <!-- class="el-icon-printer"--> |
| | | <!-- :style="{color:$store.state.settings.theme}"--> |
| | | <!-- style="cursor: pointer;margin-right: 15px"--> |
| | | <!-- @click="supplementSmallClick(row)"--> |
| | | <!-- />--> |
| | | <!-- </el-tooltip>--> |
| | | <!-- <el-tooltip class="item" effect="dark" content="补打生产入库条码" placement="top">--> |
| | | <!-- <i--> |
| | | <!-- v-if="tableDataDetail.length===row.seq"--> |
| | | <!-- class=" el-icon-camera"--> |
| | | <!-- :style="{color:$store.state.settings.theme}"--> |
| | | <!-- style="cursor: pointer;margin-right: 15px"--> |
| | | <!-- @click="getProductInHouseLabCode(row.wo_code)"--> |
| | | <!-- />--> |
| | | <!-- </el-tooltip>--> |
| | | <!-- </div>--> |
| | | <!-- </template>--> |
| | | <!-- </el-table-column>--> |
| | | <el-table-column |
| | | label="操作" |
| | | width="120" |
| | | fixed="right" |
| | | > |
| | | <template slot-scope="{row}"> |
| | | <div class="operationClass"> |
| | | <el-tooltip v-del-tab-index class="item" effect="dark" content="SOP预览" placement="top"> |
| | | <i |
| | | v-if="mesSetting.tech" |
| | | class="el-icon-files" |
| | | style="cursor: pointer;color:#42b983;margin-right: 15px" |
| | | @click="pre(row,2)" |
| | | /> |
| | | </el-tooltip> |
| | | <!-- <el-tooltip class="item" effect="dark" content="打印工序" placement="top">--> |
| | | <!-- <i--> |
| | | <!-- v-if="tableDataDetail.length!==row.seq"--> |
| | | <!-- class="el-icon-printer"--> |
| | | <!-- :style="{color:$store.state.settings.theme}"--> |
| | | <!-- style="cursor: pointer;margin-right: 15px"--> |
| | | <!-- @click="supplementSmallClick(row)"--> |
| | | <!-- />--> |
| | | <!-- </el-tooltip>--> |
| | | <!-- <el-tooltip class="item" effect="dark" content="补打生产入库条码" placement="top">--> |
| | | <!-- <i--> |
| | | <!-- v-if="tableDataDetail.length===row.seq"--> |
| | | <!-- class=" el-icon-camera"--> |
| | | <!-- :style="{color:$store.state.settings.theme}"--> |
| | | <!-- style="cursor: pointer;margin-right: 15px"--> |
| | | <!-- @click="getProductInHouseLabCode(row.wo_code)"--> |
| | | <!-- />--> |
| | | <!-- </el-tooltip>--> |
| | | </div> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </div> |
| | | </div> |
| | |
| | | </span> |
| | | </el-dialog> |
| | | |
| | | <!-- 工单sop/工序sop--> |
| | | <el-dialog |
| | | v-el-drag-dialog |
| | | class="sop" |
| | | title="设备SOP预览" |
| | | :visible.sync="SopDialogVisible" |
| | | width="800px" |
| | | :close-on-click-modal="false" |
| | | top="15vh" |
| | | @closed="handleSopClose" |
| | | @close="handleSopClose" |
| | | > |
| | | |
| | | <el-form inline label-width="110px" style="display:flex"> |
| | | <el-form-item label="工单SOP"> |
| | | <el-select |
| | | v-model="dialogSopForm.sop" |
| | | style="width:200px" |
| | | placeholder="请选择" |
| | | filterable |
| | | :popper-append-to-body="false" |
| | | @change="sopChange" |
| | | > |
| | | <el-option |
| | | v-for="item in sopArr" |
| | | :key="item.filepath" |
| | | :label="item.filename" |
| | | :value="item.filepath" |
| | | /> |
| | | </el-select> |
| | | </el-form-item> |
| | | |
| | | <el-form-item label="Sop版本"> |
| | | <el-input v-model="dialogSopForm.v" disabled style="width: 200px" /> |
| | | </el-form-item> |
| | | </el-form> |
| | | |
| | | <el-button |
| | | v-waves |
| | | type="primary" |
| | | style="margin-left: 37px" |
| | | @click="view" |
| | | >预 览/下 载</el-button> |
| | | |
| | | <span slot="footer" class="dialog-footer"> |
| | | <div class="footerButton"> |
| | | <el-button v-waves @click="handleSopClose">取 消</el-button> |
| | | <!-- <el-button--> |
| | | <!-- v-waves--> |
| | | <!-- type="primary"--> |
| | | <!-- :loading="$store.state.app.buttonIsDisabled"--> |
| | | <!-- :disabled="$store.state.app.buttonIsDisabled"--> |
| | | <!-- @click="handleSopConfirm"--> |
| | | <!-- >确 定</el-button>--> |
| | | </div> |
| | | </span> |
| | | </el-dialog> |
| | | |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | import { |
| | | AddMesOrderCodeSearch, |
| | | AddUpdateMesOrder, DeleteMesOrder, |
| | | MesBadOrderSearch, MesOrderDistribution, MesOrderNewStepContent, |
| | | MesOrderSearch, |
| | | MesBadOrderSearch, MesOrderDistribution, MesOrderNewStepContent, MesOrderProcessSopSearch, |
| | | MesOrderSearch, MesOrderSopSearch, |
| | | UpdateMesOrderStepSearch |
| | | } from '@/api/WorkOrder' |
| | | import { PartSelect } from '@/api/ProductModel' |
| | |
| | | import { MesOrderPrintSearch } from '@/api/GridReport' // base on element-ui |
| | | import DateType from '@/components/DateType' |
| | | import { PartSelectRpute, RouteSelectStep } from '@/api/basicSettings' |
| | | import { DeviceSopSearch } from '@/api/DeviceManager' |
| | | export default { |
| | | name: 'WorkOrderList', |
| | | components: { |
| | |
| | | |
| | | sourceType: false, // 工序的数据来源 |
| | | |
| | | mesSetting: JSON.parse(localStorage.getItem('mesSetting')) |
| | | mesSetting: JSON.parse(localStorage.getItem('mesSetting')), |
| | | |
| | | SopDialogVisible: false, |
| | | dialogSopForm: { // 设备SOP表单 |
| | | sop: '', |
| | | v: '' |
| | | }, |
| | | sopArr: [], |
| | | routeCode: '', // 工艺路线code |
| | | partCode: '' |
| | | } |
| | | }, |
| | | watch: { |
| | |
| | | // }) |
| | | }, |
| | | methods: { |
| | | // 弹出框关闭 |
| | | handleSopClose() { |
| | | this.SopDialogVisible = false |
| | | this.dialogSopForm = { // 设备SOP表单 |
| | | sop: '', |
| | | v: '' |
| | | } |
| | | }, |
| | | // 预览 |
| | | view() { |
| | | window.open(process.env.VUE_APP_BASE_API_FILE + this.dialogSopForm.sop) |
| | | }, |
| | | sopChange(val) { |
| | | this.dialogSopForm.v = this.sopArr.find(i => i.filepath === val).version |
| | | }, |
| | | async pre(row, type) { |
| | | if (type === 1) { |
| | | const data = { |
| | | wocode: row.wo_code, |
| | | materielcode: row.partcode |
| | | } |
| | | const { data: res } = await MesOrderSopSearch(data) |
| | | this.sopArr = res |
| | | } |
| | | |
| | | if (type === 2) { |
| | | const data = { |
| | | materielcode: this.partCode, |
| | | routecode: this.routeCode ? this.routeCode : '', |
| | | stepcode: row.step_code |
| | | } |
| | | const { data: res } = await MesOrderProcessSopSearch(data) |
| | | this.sopArr = res |
| | | } |
| | | |
| | | this.SopDialogVisible = true |
| | | }, |
| | | // 工序来源切换 |
| | | sourceTypeChange(val) { |
| | | this.stepTableData = [] |
| | |
| | | }, |
| | | // 行点击事件 |
| | | async rowClick(row, event, column) { |
| | | this.routeCode = row.route_code ? row.route_code : '' |
| | | this.partCode = row.partcode ? row.partcode : '' |
| | | const data = { |
| | | sourceid: row.sourceid, |
| | | sourcewo: row.m_po, |
| | |
| | | padding: 20px 100px !important; |
| | | } |
| | | |
| | | .sop { |
| | | ::v-deep .el-dialog__body { |
| | | padding: 50px 80px !important; |
| | | } |
| | | } |
| | | |
| | | .dialogVisibleSearch ::v-deep .el-dialog__body { |
| | | padding: 20px 20px !important; |
| | | } |