11 changed files with 3601 additions and 0 deletions
-
13src/api/scheduleReport/com_die_cutting_report.js
-
11src/api/scheduleReport/com_fqc_report.js
-
7src/api/scheduleReport/com_scan_material.js
-
7src/api/scheduleReport/com_separate_roll.js
-
4src/api/scheduleReport/produce_order.js
-
1208src/views/modules/scheduleReport/com_die_cutting_report.vue
-
987src/views/modules/scheduleReport/com_fqc_report.vue
-
223src/views/modules/scheduleReport/com_scan_material.vue
-
318src/views/modules/scheduleReport/com_separate_roll.vue
-
146src/views/modules/scheduleReport/print_roll_label.js
-
677src/views/modules/scheduleReport/produce_order.vue
@ -0,0 +1,13 @@ |
|||||
|
import { createAPI } from '@/utils/httpRequest.js' |
||||
|
|
||||
|
// 获取派工单信息
|
||||
|
export const getScheduleDataBySeqNo = data => createAPI('schedule/getScheduleDataBySeqNo', 'POST', data) |
||||
|
|
||||
|
// 获取当前上机卷信息
|
||||
|
export const getCurrentRollOpsBySeqNo = data => createAPI('schedule/getCurrentRollOpsBySeqNo', 'POST', data) |
||||
|
|
||||
|
// 获取当前派工单的上机卷记录
|
||||
|
export const getSfdcRollOpsByCon = data => createAPI('schedule/getSfdcRollOpsByCon', 'POST', data) |
||||
|
|
||||
|
// 获取当前上机卷信息
|
||||
|
export const getSoFinalRollsByCon = data => createAPI('schedule/getSoFinalRollsByCon', 'POST', data) |
||||
@ -0,0 +1,11 @@ |
|||||
|
import { createAPI } from '@/utils/httpRequest.js' |
||||
|
|
||||
|
// 获取派工单信息
|
||||
|
export const getScheduleDataBySeqNo = data => createAPI('schedule/getScheduleDataBySeqNo', 'POST', data) |
||||
|
|
||||
|
// 获取当前上机卷信息
|
||||
|
export const getSoFinalRollsByCon = data => createAPI('schedule/getSoFinalRollsByCon', 'POST', data) |
||||
|
|
||||
|
// 检验当前的卷信息
|
||||
|
export const scanFinalRollNo = data => createAPI('schedule/scanFinalRollNo', 'POST', data) |
||||
|
|
||||
@ -0,0 +1,7 @@ |
|||||
|
import { createAPI } from '@/utils/httpRequest.js' |
||||
|
|
||||
|
// 查询材料卷信息
|
||||
|
export const getRmRollData = data => createAPI('schedule/getRmRollData', 'POST', data) |
||||
|
|
||||
|
// 材料下机操作
|
||||
|
export const scanRmRollNo = data => createAPI('schedule/scanRmRollNo', 'POST', data) |
||||
@ -0,0 +1,7 @@ |
|||||
|
import { createAPI } from '@/utils/httpRequest.js' |
||||
|
|
||||
|
//获取当前派工单的标准卷数量
|
||||
|
export const getSeqStandardRollQty = data => createAPI('schedule/getSeqStandardRollQty', 'POST', data) |
||||
|
|
||||
|
// 执行创建分卷的操作
|
||||
|
export const createSeparateRoll = data => createAPI('schedule/createSeparateRoll', 'POST', data) |
||||
@ -0,0 +1,4 @@ |
|||||
|
import { createAPI } from '@/utils/httpRequest.js' |
||||
|
|
||||
|
// 获取
|
||||
|
export const getProduceScheduleList = data => createAPI('schedule/getProduceScheduleData', 'POST', data) |
||||
1208
src/views/modules/scheduleReport/com_die_cutting_report.vue
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -0,0 +1,987 @@ |
|||||
|
<script src="print_roll_label.js"></script> |
||||
|
<template> |
||||
|
<div class="produce-report customer-css"> |
||||
|
<el-dialog v-drag |
||||
|
width="900px" class="customer-dialog" :visible.sync="visible" |
||||
|
:title="titleCon" v-bind="$attrs" v-on="$listeners"> |
||||
|
<el-form :inline="true" label-position="top" style="height: 507px;" |
||||
|
label-width="80px"> |
||||
|
<!-- 第一行信息 --> |
||||
|
<el-form style="margin-top: -10px;"> |
||||
|
<el-form-item :label=labels.orderNo class="customer-item"> |
||||
|
<el-input v-model="scheduleData.orderNo" :readonly="true" style="width: 130px;"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label=labels.partNo class="customer-item"> |
||||
|
<el-input v-model="scheduleData.partNo" :readonly="true" style="width: 130px;"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label=labels.partDesc class="customer-item"> |
||||
|
<el-input v-model="scheduleData.partDesc" :readonly="true" style="width: 200px;"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label=labels.seqNo class="customer-item"> |
||||
|
<el-input v-model="scheduleData.seqNo" :readonly="true" style="width: 80px;"></el-input> |
||||
|
</el-form-item> |
||||
|
<!-- <el-form-item :label="''" style="margin-left: -5px;" class="customer-item"> |
||||
|
<el-checkbox style="margin-left: 30px; margin-top: 20px;" true-label="true" false-label="false" |
||||
|
v-model="scheduleData.currentRollFlag">{{ labels.onlyCurrentRoll }} |
||||
|
</el-checkbox> |
||||
|
</el-form-item>--> |
||||
|
</el-form> |
||||
|
|
||||
|
<!-- 第四行菜单 --> |
||||
|
<fieldset class="customer-fieldset" style="width: 880px;"> |
||||
|
<legend class="customer-legend">{{ labels.rollButtons }}</legend> |
||||
|
<el-form> |
||||
|
<el-form-item class="customer-roll-css" style="width: 130px; font-size: 16px; color: #387877;"> |
||||
|
<el-input v-model="searchData.rollNo" ref="rollNo" style="width: 180px" |
||||
|
@keyup.enter.native="scanFinalRollNoFun"> |
||||
|
</el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item> |
||||
|
<el-button class="customer-bun-mid" type="primary" @click="refreshPageData" |
||||
|
style="margin-left: 200px; margin-top: 0px; margin-bottom: 5px;"> |
||||
|
{{ buttons.refreshButton }} |
||||
|
</el-button> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
</fieldset> |
||||
|
|
||||
|
<!-- 列表展示区域 --> |
||||
|
<fieldset class="customer-fieldset" style="margin-bottom: 10px; width: 880px; height: 400px;"> |
||||
|
<legend class="customer-legend">{{ labels.listDesc }}</legend> |
||||
|
<el-tabs v-model="activeTable" style="margin-top: -3px; width: 870px; height: 375px;" |
||||
|
type="border-card" @tab-click="tabClick" class="customer-tab"> |
||||
|
<!-- 下机记录 --> |
||||
|
<el-tab-pane :label=labels.rollList name="sfdc_roll"> |
||||
|
<el-table |
||||
|
height="350" |
||||
|
:data="soFinalRollList" |
||||
|
border |
||||
|
v-loading="dataListLoading" |
||||
|
highlight-current-row |
||||
|
@current-change="setSfdcRoll" |
||||
|
style="width: 100%;"> |
||||
|
<el-table-column |
||||
|
v-for="(item,index) in columnRollArray" :key="index" |
||||
|
:sortable="item.columnSortable" |
||||
|
:prop="item.columnProp" |
||||
|
:header-align="item.headerAlign" |
||||
|
:show-overflow-tooltip="item.showOverflowTooltip" |
||||
|
:align="item.align" |
||||
|
:fixed="item.fixed==''?false:item.fixed" |
||||
|
:min-width="item.columnWidth" |
||||
|
:label="item.columnLabel"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span> |
||||
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
||||
|
style="width: 100px; height: 80px"/></span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column |
||||
|
fixed="left" |
||||
|
header-align="center" |
||||
|
align="center" |
||||
|
width="150" |
||||
|
:label=labels.rollListOperation> |
||||
|
<template slot-scope="scope"> |
||||
|
<!-- <a class="customer-a" v-if="operatorData.operatorName != ''" |
||||
|
@click="printSfdcFlowLabel(scope.row)" |
||||
|
>{{ labels.rollListPrint }}</a>--> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-tab-pane> |
||||
|
</el-tabs> |
||||
|
</fieldset> |
||||
|
</el-form> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { |
||||
|
getScheduleDataBySeqNo, |
||||
|
getSoFinalRollsByCon, |
||||
|
scanFinalRollNo, |
||||
|
} from "@/api/scheduleReport/com_fqc_report.js"; |
||||
|
/*打印标签专用的js*/ |
||||
|
import { |
||||
|
printSfdcLabel, |
||||
|
} from "@/views/modules/scheduleReport/print_roll_label.js" |
||||
|
|
||||
|
import comScanMaterial from './com_scan_material' /* 扫描卷的组件 */ |
||||
|
import comSeparateRoll from "./com_separate_roll"; |
||||
|
|
||||
|
var functionId = 'C10000004'; |
||||
|
export default { |
||||
|
data() { |
||||
|
return { |
||||
|
titleCon: '', |
||||
|
visible: false, |
||||
|
activeTable: 'sfdc_roll', |
||||
|
soFinalRollList: [], |
||||
|
columnRollArray: [ |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 5303, |
||||
|
serialNumber: '5303RollFinalRollNo', |
||||
|
tableId: "5303Roll", |
||||
|
tableName: "下机卷", |
||||
|
columnProp: "finalRollNo", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "卷号", |
||||
|
columnWidth: 100, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 5303, |
||||
|
serialNumber: '5303RollCreatedDate', |
||||
|
tableId: "5303Roll", |
||||
|
tableName: "下机卷", |
||||
|
columnProp: "createdDate", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "创建时间", |
||||
|
columnWidth: 125, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 5303, |
||||
|
serialNumber: '5303RollCreatedBy', |
||||
|
tableId: "5303Roll", |
||||
|
tableName: "下机卷", |
||||
|
columnProp: "createdBy", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "创建人", |
||||
|
columnWidth: 90, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 5303, |
||||
|
serialNumber: '5303RollRollQty', |
||||
|
tableId: "5303Roll", |
||||
|
tableName: "下机卷", |
||||
|
columnProp: "rollQty", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "卷数量", |
||||
|
columnWidth: 55, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
], |
||||
|
searchData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
username: this.$store.state.user.name, |
||||
|
seqNo: '', |
||||
|
orderNo: '', |
||||
|
itemNo: 0, |
||||
|
resourceId: '', |
||||
|
partNo: '', |
||||
|
workCenterNo: '', |
||||
|
rollNo: '', |
||||
|
functionName: '', |
||||
|
statusCode: 1, |
||||
|
}, |
||||
|
scheduleData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
username: this.$store.state.user.name, |
||||
|
seqNo: '', |
||||
|
orderNo: '', |
||||
|
itemNo: 0, |
||||
|
partNo: '', |
||||
|
workCenterNo: '', |
||||
|
rollNo: '', |
||||
|
partDesc: '', |
||||
|
functionName: '', |
||||
|
currentRollFlag: false, |
||||
|
statusCode: 1, |
||||
|
}, |
||||
|
currentRollOps: { |
||||
|
site: this.$store.state.user.site, |
||||
|
seqNo: '', |
||||
|
rollNo: '', |
||||
|
finishedFlag: '', |
||||
|
}, |
||||
|
dataListLoading: false, |
||||
|
buttons: { |
||||
|
scanMaterialButton: '扫描材料卷', |
||||
|
separateRoll: '创建分卷', |
||||
|
refreshButton: '刷新', |
||||
|
}, |
||||
|
buttonList: [ |
||||
|
{ |
||||
|
functionId: functionId, |
||||
|
languageValue: '扫描材料卷', |
||||
|
objectId: 'scanMaterialButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '切换卷', |
||||
|
objectId: 'switchRoll', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '创建分卷', |
||||
|
objectId: 'separateRoll', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '结束卷', |
||||
|
objectId: 'finishRoll', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '合并卷', |
||||
|
objectId: 'mergeRoll', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '结单', |
||||
|
objectId: 'finishSchedule', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '刷新', |
||||
|
objectId: 'refreshButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '切换用户', |
||||
|
objectId: 'switchOperator', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '开始调机', |
||||
|
objectId: 'startTuning', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '开始生产', |
||||
|
objectId: 'startProduce', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '报告不良', |
||||
|
objectId: 'reportDefect', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '刀模板', |
||||
|
objectId: 'toolButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '材料', |
||||
|
objectId: 'materialButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '报告其他停机', |
||||
|
objectId: 'downTime', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '其他操作', |
||||
|
objectId: 'otherOperation', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '产量报告', |
||||
|
objectId: 'preReport', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '删除卷', |
||||
|
objectId: 'deleteRoll', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '未生产下机拆卷', |
||||
|
objectId: 'notProduce', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
} |
||||
|
], |
||||
|
labels: { |
||||
|
componentTitle: '机台工作台', |
||||
|
orderNo: '订单号', |
||||
|
partNo: '物料编码', |
||||
|
partDesc: '物料名称/规则', |
||||
|
seqNo: '派工单号', |
||||
|
needDate: '要求完工日期', |
||||
|
planStartDate: '刷新', |
||||
|
lotSize: '原始派工单需求数量', |
||||
|
scheduledDate: ' 排产日期', |
||||
|
rollButtons: '卷操作', |
||||
|
listDesc: '列表信息', |
||||
|
rollList: '扫描卷', |
||||
|
scanButtons: '扫描', |
||||
|
rollListDelete: '删除卷', |
||||
|
rollListPrint: '打印卷标签', |
||||
|
toolListOperation: '操作', |
||||
|
materialListOperation: '操作', |
||||
|
rollListOperation: '操作', |
||||
|
noneRollNo: '!', |
||||
|
sureDeleteRoll: '确定要删除', |
||||
|
currentRollNo: '当前卷?', |
||||
|
confirmLabel: '确定', |
||||
|
cancelLabel: '取消', |
||||
|
sureLabel: '吗?', |
||||
|
rollSplit: '创建分卷', |
||||
|
scannerMaterial: '扫描材料', |
||||
|
materialMalformed: '材料异常处理', |
||||
|
}, |
||||
|
labelsList: [ |
||||
|
{ |
||||
|
functionId: functionId, |
||||
|
languageValue: '机台工作台', |
||||
|
objectId: 'componentTitle', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '订单号', |
||||
|
objectId: 'orderNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '物料编码', |
||||
|
objectId: 'partNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '物料名称/规则', |
||||
|
objectId: 'partDesc', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '派工单号', |
||||
|
objectId: 'seqNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '要求完工日期', |
||||
|
objectId: 'needDate', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '要求开工日期', |
||||
|
objectId: 'planStartDate', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '原始派工单需求数量', |
||||
|
objectId: 'lotSize', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '排产日期', |
||||
|
objectId: 'scheduledDate', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '班次', |
||||
|
objectId: 'shiftNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '前道工序', |
||||
|
objectId: 'preItemNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '后道工序', |
||||
|
objectId: 'nextItemNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '仅显示当前卷信息', |
||||
|
objectId: 'onlyCurrentRoll', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '卷操作', |
||||
|
objectId: 'rollButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '列表信息', |
||||
|
objectId: 'listDesc', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '时间', |
||||
|
objectId: 'timeList', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '刀模板记录', |
||||
|
objectId: 'toolList', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '材料', |
||||
|
objectId: 'materialList', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '生产卷操作信息', |
||||
|
objectId: 'rollopsList', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '不良记录', |
||||
|
objectId: 'defectList', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '扫描卷', |
||||
|
objectId: 'rollList', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '生产调机', |
||||
|
objectId: 'produceButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '不良', |
||||
|
objectId: 'defectButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '扫描', |
||||
|
objectId: 'scanButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '停机', |
||||
|
objectId: 'downTimeButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '其他操作', |
||||
|
objectId: 'otherButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '刀模替换', |
||||
|
objectId: 'toolListReplace', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '结束使用', |
||||
|
objectId: 'toolListFinish', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '不良', |
||||
|
objectId: 'defectButtons', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '换料', |
||||
|
objectId: 'materialListReplace', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '下料', |
||||
|
objectId: 'materialListCutting', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '生产结束', |
||||
|
objectId: 'materialListFinish', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '重打开', |
||||
|
objectId: 'rollListReopen', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '删除卷', |
||||
|
objectId: 'rollListDelete', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '打印卷标签', |
||||
|
objectId: 'rollListPrint', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '操作', |
||||
|
objectId: 'toolListOperation', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '操作', |
||||
|
objectId: 'materialListOperation', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '操作', |
||||
|
objectId: 'rollListOperation', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '!', |
||||
|
objectId: 'noneRollNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确定要删除', |
||||
|
objectId: 'sureDeleteRoll', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '当前卷?', |
||||
|
objectId: 'currentRollNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确定', |
||||
|
objectId: 'confirmLabel', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '取消', |
||||
|
objectId: 'cancelLabel', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '请先选择派工单!', |
||||
|
objectId: 'pleaseSelectSeqNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确实要创建一个新卷吗?', |
||||
|
objectId: 'sureCreateNewRoll', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '参与无法合并卷!', |
||||
|
objectId: 'noRollCantMerge', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确实要重新打开卷', |
||||
|
objectId: 'sureReopenSfdcRoll', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '吗?', |
||||
|
objectId: 'sureLabel', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确实要删除该卷吗?', |
||||
|
objectId: 'sureDeleteCurrentRoll', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确实要结束该工具的使用吗?', |
||||
|
objectId: 'sureEndThisToolUsed', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, |
||||
|
], |
||||
|
queryButton: { |
||||
|
functionId: functionId, |
||||
|
table_id: '*', |
||||
|
languageCode: this.$i18n.locale, |
||||
|
objectType: 'button' |
||||
|
}, |
||||
|
queryLabel: { |
||||
|
functionId: functionId, |
||||
|
table_id: '*', |
||||
|
languageCode: this.$i18n.locale, |
||||
|
objectType: 'label' |
||||
|
}, |
||||
|
} |
||||
|
}, |
||||
|
components: { |
||||
|
comScanMaterial, /* 扫描卷的组件 */ |
||||
|
comSeparateRoll, /* 创建分卷 */ |
||||
|
}, |
||||
|
methods: { |
||||
|
|
||||
|
init(seqNo) { |
||||
|
//判断是否关闭所有的页面按钮 |
||||
|
this.scheduleData.seqNo = seqNo; |
||||
|
this.currentRollOps.seqNo = seqNo; |
||||
|
this.soFinalRollList = []; |
||||
|
//设置table页签 |
||||
|
this.activeTable = 'sfdc_roll'; |
||||
|
//自动获取焦点 |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs.rollNo.focus(); |
||||
|
}); |
||||
|
//刷新当前派工单的信息 |
||||
|
this.refreshPageData(); |
||||
|
//打开显示 |
||||
|
this.visible = true; |
||||
|
}, |
||||
|
|
||||
|
//刷新页面的数据 |
||||
|
async refreshPageData() { |
||||
|
await getScheduleDataBySeqNo(this.scheduleData.seqNo).then(({data}) => { |
||||
|
this.scheduleData.seqNo = data.row.seqNo; |
||||
|
this.scheduleData.orderNo = data.row.orderNo; |
||||
|
this.scheduleData.itemNo = data.row.itemNo; |
||||
|
this.scheduleData.resourceId = data.row.resourceId; |
||||
|
this.scheduleData.partNo = data.row.partNo; |
||||
|
this.scheduleData.partDesc = data.row.partDesc; |
||||
|
this.scheduleData.scheduledDate = data.row.scheduledDate; |
||||
|
this.scheduleData.workCenterNo = data.row.workCenterNo; |
||||
|
this.scheduleData.closedFlag = data.row.closedFlag; |
||||
|
this.scheduleData.statusCode = 1; |
||||
|
this.searchData.orderNo = data.row.orderNo; |
||||
|
this.searchData.seqNo = data.row.seqNo; |
||||
|
//设置弹窗的标题 |
||||
|
this.titleCon = this.labels.componentTitle + ' - ' + data.row.itemDesc; |
||||
|
}) |
||||
|
//刷新当前页签的table的内容 |
||||
|
await this.refreshCurrentTabTable(); |
||||
|
}, |
||||
|
|
||||
|
//设置当前的夏季卷 |
||||
|
setSfdcRoll(row) { |
||||
|
this.currentSfdcRollRow = row; |
||||
|
}, |
||||
|
|
||||
|
/*fqc检查卷号的数据*/ |
||||
|
scanFinalRollNoFun() { |
||||
|
//判断null和空字符串 |
||||
|
if (this.searchData.rollNo == null || this.searchData.rollNo == '') { |
||||
|
this.$message.error('卷号不能为空!'); |
||||
|
return false; |
||||
|
} else { |
||||
|
this.searchData.rollNo = this.searchData.rollNo.trim(); |
||||
|
} |
||||
|
|
||||
|
// 查询卷信息 |
||||
|
scanFinalRollNo(this.searchData).then(({data}) => { |
||||
|
if (data.code == 200){ |
||||
|
this.getSoFinalList(); |
||||
|
this.searchData.rollNo = ''; |
||||
|
}else{ |
||||
|
this.$message.error(data.msg); |
||||
|
this.searchData.rollNo = ''; |
||||
|
return false; |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
// 获取派工单的信息 |
||||
|
getScheduleDataBySeqNo() { |
||||
|
getScheduleDataBySeqNo(this.scheduleData.seqNo).then(({data}) => { |
||||
|
this.scheduleData.seqNo = data.row.seqNo; |
||||
|
this.scheduleData.orderNo = data.row.orderNo; |
||||
|
this.scheduleData.itemNo = data.row.itemNo; |
||||
|
this.scheduleData.partNo = data.row.partNo; |
||||
|
this.scheduleData.partDesc = data.row.partDesc; |
||||
|
this.scheduleData.scheduledDate = data.row.scheduledDate; |
||||
|
this.scheduleData.workCenterNo = data.row.workCenterNo; |
||||
|
}); |
||||
|
}, |
||||
|
//列表表格选择替换 |
||||
|
tabClick(tab, event) { |
||||
|
//刷新列表数据 |
||||
|
this.refreshCurrentTabTable(); |
||||
|
}, |
||||
|
|
||||
|
getSoFinalList() { |
||||
|
getSoFinalRollsByCon(this.searchData).then(({data}) => { |
||||
|
this.soFinalRollList = data.rows; |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
//刷新页签的table数据 |
||||
|
async refreshCurrentTabTable() { |
||||
|
//设置查询的数据 |
||||
|
this.searchData = JSON.parse(JSON.stringify(this.scheduleData)); |
||||
|
//判断是否按照当前卷来查询 |
||||
|
if (this.scheduleData.currentRollFlag) { |
||||
|
//设置相关的卷号 判断是否存在卷 |
||||
|
this.searchData.rollNo = this.currentRollOps.rollNo; |
||||
|
} else { |
||||
|
this.searchData.rollNo = ''; |
||||
|
} |
||||
|
|
||||
|
//区分不同的页签刷新不同的列表数据 |
||||
|
if (this.activeTable == 'sfdc_roll') { |
||||
|
this.getSoFinalList(); |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
/*结束卷操作*/ |
||||
|
finishRollModal() { |
||||
|
//1.首先调用菜单判断方式 看看是否可以结束卷 |
||||
|
//checkProduceButton('finishRollFlag'); |
||||
|
//打开结束卷的页面 |
||||
|
this.$nextTick(() => { |
||||
|
this.showFinishFlag = true; |
||||
|
this.$refs.comFinishRoll.init(this.scheduleData) |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*开始调机modal*/ |
||||
|
startProduceModal() { |
||||
|
//1.首先调用菜单判断方式 看看是否可以结束卷 |
||||
|
//checkProduceButton('startProduceFlag'); |
||||
|
//打开开始生产的页面 |
||||
|
this.$nextTick(() => { |
||||
|
this.showProduceFlag = true; |
||||
|
this.$refs.comStartProduce.init(this.scheduleData) |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*材料结束生产的modal*/ |
||||
|
finishMaterialModal(materialRow) { |
||||
|
this.$nextTick(() => { |
||||
|
this.showMaterialFlag = true; |
||||
|
this.$refs.comProduceMaterial.init(this.scheduleData) |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*提醒是否删除的提示*/ |
||||
|
warnDeleteSfdcRollsConfirm(sfdcRollRow) { |
||||
|
this.$confirm(this.labels.sureDeleteCurrentRoll, '提示', { |
||||
|
confirmButtonText: this.labels.confirmLabel, |
||||
|
celButtonText: this.labels.cancelLabel, |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
//执行重新打开sfdcRolls记录的操作 |
||||
|
this.deleteSfdcRollsOperation(sfdcRollRow); |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*执行删除sfdcRolls的数据功能*/ |
||||
|
deleteSfdcRollsOperation(sfdcRollRow) { |
||||
|
let sfdcRoll = { |
||||
|
'site': this.scheduleData.site, 'orderNo': this.scheduleData.orderNo, |
||||
|
'itemNo': this.scheduleData.itemNo, 'seqNo': this.scheduleData.seqNo, |
||||
|
'rollNo': sfdcRollRow.rollNo, 'oriRollNo': sfdcRollRow.oriRollNo, 'operatorId': this.scheduleData.operatorId |
||||
|
}; |
||||
|
//执行删除卷的操作 |
||||
|
deleteSfdcRolls(sfdcRoll).then(({data}) => { |
||||
|
//判断是否成功 |
||||
|
if (data.code == 500) { |
||||
|
this.$message.error(data.msg); |
||||
|
} else { |
||||
|
this.$message.success(data.resultMap.resultMsg); |
||||
|
//刷新报工的页面 |
||||
|
this.refreshPageData(); |
||||
|
} |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*结束使用 工具确认功能*/ |
||||
|
warnFinishToolConfirm(toolRow) { |
||||
|
this.$confirm(this.labels.sureEndThisToolUsed, '提示', { |
||||
|
confirmButtonText: this.labels.confirmLabel, |
||||
|
celButtonText: this.labels.cancelLabel, |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
//执行结束使用工具的的操作 |
||||
|
this.finishToolOperation(toolRow); |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*执行删除sfdcRolls的数据功能*/ |
||||
|
finishToolOperation(toolRow) { |
||||
|
let toolData = { |
||||
|
'site': this.scheduleData.site, 'orderNo': this.scheduleData.orderNo, |
||||
|
'itemNo': this.scheduleData.itemNo, 'seqNo': this.scheduleData.seqNo, |
||||
|
'histSeqNo': toolRow.histSeqNo, 'toolInstanceId': toolRow.toolInstanceId |
||||
|
}; |
||||
|
//执行删除卷的操作 |
||||
|
processFinishTool(toolData).then(({data}) => { |
||||
|
//判断是否成功 |
||||
|
if (data.code == 500) { |
||||
|
this.$message.error(data.msg); |
||||
|
} else { |
||||
|
this.$message.success(data.msg); |
||||
|
//刷新报工的页面 |
||||
|
this.refreshPageData(); |
||||
|
} |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*结束使用 材料确认功能*/ |
||||
|
warnFinishMaterialWithNoRemainderConfirm(materialRow) { |
||||
|
this.$confirm(this.labels.sureEndThisToolUsed, '提示', { |
||||
|
confirmButtonText: this.labels.confirmLabel, |
||||
|
celButtonText: this.labels.cancelLabel, |
||||
|
type: 'warning' |
||||
|
}).then(() => { |
||||
|
//执行结束使用材料的的操作 |
||||
|
this.finishMaterialWithNoRemainderOperation(materialRow); |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
/*执行结束使用 材料的数据功能*/ |
||||
|
finishMaterialWithNoRemainderOperation(materialRow) { |
||||
|
let materialData = { |
||||
|
'site': this.scheduleData.site, 'orderNo': this.scheduleData.orderNo, |
||||
|
'itemNo': this.scheduleData.itemNo, 'seqNo': this.scheduleData.seqNo, |
||||
|
'histSeqNo': materialRow.histSeqNo, 'rollNo': materialRow.rollNo |
||||
|
}; |
||||
|
//执行结束使用材料卷且无剩余的操作 |
||||
|
finishMaterialWithNoRemainder(materialData).then(({data}) => { |
||||
|
//判断是否成功 |
||||
|
if (data.code == 500) { |
||||
|
this.$message.error(data.msg); |
||||
|
} else { |
||||
|
this.$message.success(data.msg); |
||||
|
//刷新报工的页面 |
||||
|
this.refreshPageData(); |
||||
|
} |
||||
|
}); |
||||
|
}, |
||||
|
}, |
||||
|
|
||||
|
created() { |
||||
|
// this.factoryList() |
||||
|
// this.getLanguageList() |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
<style scoped lang="scss"> |
||||
|
/deep/ .customer-tab .el-tabs__content { |
||||
|
padding: 0px !important; |
||||
|
} |
||||
|
|
||||
|
/*当前按钮的通用样式*/ |
||||
|
.customer-css .customer-bun-mid { |
||||
|
width: 60px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.customer-css .customer-bun-min { |
||||
|
width: 50px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
.customer-css .customer-bun-max { |
||||
|
width: 80px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
/*当前按钮的通用样式*/ |
||||
|
.customer-css .el-button--medium { |
||||
|
padding: 5px 5px; |
||||
|
} |
||||
|
|
||||
|
.customer-css .customer-roll-css span { |
||||
|
margin-left: 15px; |
||||
|
font-size: 16px; |
||||
|
color: #387877; |
||||
|
} |
||||
|
|
||||
|
/*定制组件的样式*/ |
||||
|
.customer-css /deep/ .el-dialog { |
||||
|
top: 6vh !important; |
||||
|
margin-top: 0px !important; |
||||
|
margin-bottom: 10px; |
||||
|
} |
||||
|
|
||||
|
/*自定义当前el-input的样式 */ |
||||
|
.customer-item .el-input { |
||||
|
margin-right: 25px; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
</style> |
||||
@ -0,0 +1,223 @@ |
|||||
|
<template> |
||||
|
<div class="customer-css"> |
||||
|
<el-dialog :title="titleCon" v-drag v-bind="$attrs" v-on="$listeners" |
||||
|
:visible.sync="visible" |
||||
|
width="200px" style="height: 460px;" class="customer-dialog"> |
||||
|
<el-container style="height: 160px;"> |
||||
|
<el-form :inline="true" label-position="top" label-width="80px"> |
||||
|
<!-- 材料卷号和BOM序号 --> |
||||
|
<el-row> |
||||
|
<el-col :span="16"> |
||||
|
<el-form-item label="卷号:"> |
||||
|
<el-input v-model="pageData.rmRollNo" ref="rmRollNo" style="width: 180px" |
||||
|
@keyup.enter.native="checkRmRollNo"> |
||||
|
</el-input> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="16"> |
||||
|
<el-form-item label="物料编码:"> |
||||
|
<el-input v-model="pageData.rmPartNo" |
||||
|
style="width: 180px;" disabled class="customer-color"> |
||||
|
</el-input> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="16"> |
||||
|
<el-form-item label="数量"> |
||||
|
<el-input v-model="pageData.rollQty" |
||||
|
style="width: 180px;" disabled class="customer-color"> |
||||
|
</el-input> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</el-container> |
||||
|
<span slot="footer" class="dialog-footer"> |
||||
|
<el-button type="primary" @click="scanRmRollNoFun">{{ buttons.confirmButton }}</el-button> |
||||
|
<el-button type="primary" @click="closeDialog">{{ buttons.closeButton }}</el-button> |
||||
|
</span> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { |
||||
|
getRmRollData, |
||||
|
scanRmRollNo, |
||||
|
} from "@/api/scheduleReport/com_scan_material.js"; |
||||
|
|
||||
|
var functionId = 'C10000002'; |
||||
|
|
||||
|
export default { |
||||
|
data() { |
||||
|
return { |
||||
|
titleCon: '扫描材料', |
||||
|
visible: false, |
||||
|
scheduleData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
username: this.$store.state.user.name, |
||||
|
seqNo: '', |
||||
|
orderNo: '', |
||||
|
itemNo: 0, |
||||
|
partNo: '', |
||||
|
workCenterNo: '', |
||||
|
rollNo: '', |
||||
|
partDesc: '', |
||||
|
scheduledDate: '', |
||||
|
functionName: '', |
||||
|
currentRollFlag: false |
||||
|
}, |
||||
|
pageData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
username: this.$store.state.user.name, |
||||
|
seqNo: '', |
||||
|
orderNo: '', |
||||
|
itemNo: 0, |
||||
|
rollNo: '', |
||||
|
rmRollNo: '', |
||||
|
rmPartNo: '', |
||||
|
rollQty: 0, |
||||
|
closedFlag: 'N' |
||||
|
}, |
||||
|
dataListLoading: false, |
||||
|
buttons: { |
||||
|
confirmButton: '确定', |
||||
|
closeButton: '关闭', |
||||
|
}, |
||||
|
buttonList: [ |
||||
|
{ |
||||
|
functionId: functionId, |
||||
|
languageValue: '确定', |
||||
|
objectId: 'confirmButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '关闭', |
||||
|
objectId: 'closeButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, |
||||
|
], |
||||
|
queryButton: { |
||||
|
functionId: functionId, |
||||
|
table_id: '*', |
||||
|
languageCode: this.$i18n.locale, |
||||
|
objectType: 'button' |
||||
|
}, |
||||
|
labels: { |
||||
|
titleCon: '扫描材料', |
||||
|
}, |
||||
|
labelsList: [ |
||||
|
{ |
||||
|
functionId: functionId, |
||||
|
languageValue: '扫描材料', |
||||
|
objectId: 'titleCon', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '材料卷号:', |
||||
|
objectId: 'rmRollNo', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '卷数量:', |
||||
|
objectId: 'rollQty', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, |
||||
|
], |
||||
|
queryLabel: { |
||||
|
functionId: functionId, |
||||
|
table_id: '*', |
||||
|
languageCode: this.$i18n.locale, |
||||
|
objectType: 'label' |
||||
|
}, |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
|
||||
|
//初始化页面的参数 |
||||
|
init(scheduleData) { |
||||
|
//初始化参数 |
||||
|
this.scheduleData = JSON.parse(JSON.stringify(scheduleData));; |
||||
|
//设置页面的参数 |
||||
|
this.pageData.orderNo = scheduleData.orderNo; |
||||
|
this.pageData.itemNo = scheduleData.itemNo; |
||||
|
this.pageData.seqNo = scheduleData.seqNo; |
||||
|
this.pageData.rollQty = 0; |
||||
|
this.pageData.rmRollNo = ''; |
||||
|
this.pageData.rollNo = ''; |
||||
|
this.pageData.rmPartNo = ''; |
||||
|
this.visible = true; |
||||
|
//自动获取焦点 |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs.rmRollNo.focus(); |
||||
|
}); |
||||
|
//重置标题 |
||||
|
this.titleCon = this.labels.titleCon; |
||||
|
}, |
||||
|
|
||||
|
/*关闭modal*/ |
||||
|
closeDialog(){ |
||||
|
this.visible = false; |
||||
|
//刷新报工的页面 |
||||
|
this.$emit('refreshPageData'); |
||||
|
}, |
||||
|
|
||||
|
/*检查材料卷号的数据*/ |
||||
|
checkRmRollNo() { |
||||
|
//判断null和空字符串 |
||||
|
if (this.pageData.rmRollNo == null || this.pageData.rmRollNo == '') { |
||||
|
this.$message.error('卷号不能为空!'); |
||||
|
return false; |
||||
|
} else { |
||||
|
this.pageData.rmRollNo = this.pageData.rmRollNo.trim(); |
||||
|
} |
||||
|
this.pageData.rollNo = this.pageData.rmRollNo; |
||||
|
|
||||
|
// 查询卷信息 |
||||
|
getRmRollData(this.pageData).then(({data}) => { |
||||
|
if (data.code == 200){ |
||||
|
this.pageData.rollQty = data.row.rollQty; |
||||
|
this.pageData.rmPartNo = data.row.partNo; |
||||
|
}else{ |
||||
|
this.$message.error(data.msg); |
||||
|
return false; |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
/*扫描材料上机*/ |
||||
|
scanRmRollNoFun(){ |
||||
|
// 查询卷信息 |
||||
|
scanRmRollNo(this.pageData).then(({data}) => { |
||||
|
if (data.code == 200){ |
||||
|
this.$message.success(data.msg); |
||||
|
//关闭弹窗 |
||||
|
this.closeDialog(); |
||||
|
}else{ |
||||
|
this.$message.error(data.msg); |
||||
|
return false; |
||||
|
} |
||||
|
}) |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
}, |
||||
|
created() { |
||||
|
// this.factoryList() |
||||
|
// this.getLanguageList() |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped lang="scss"> |
||||
|
|
||||
|
|
||||
|
</style> |
||||
@ -0,0 +1,318 @@ |
|||||
|
<template> |
||||
|
<div class="customer-css"> |
||||
|
<el-dialog :title="titleCon" v-drag v-bind="$attrs" v-on="$listeners" |
||||
|
:visible.sync="visible" |
||||
|
width="200px" style="height: 680px;" class="customer-dialog"> |
||||
|
<el-form :inline="true" label-position="top" style="height: 100px;" |
||||
|
label-width="80px"> |
||||
|
<!-- 半成品卷卷号 --> |
||||
|
<el-row> |
||||
|
<el-col :span="24" style="margin-top: -5px;"> |
||||
|
<el-form-item :label=labels.rollQty> |
||||
|
<el-input ref="rollQty" v-model="pageData.rollQty" style="width: 180px;" ></el-input> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24" style="margin-top: -5px;"> |
||||
|
<el-form-item :label=labels.rollNums> |
||||
|
<el-input v-model="pageData.rollNums" style="width: 180px;" ></el-input> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
<span slot="footer" class="dialog-footer"> |
||||
|
<el-button type="primary" @click="createSeparateRollFun">{{ buttons.confirmButton }}</el-button> |
||||
|
<el-button type="primary" @click="closeDialog">{{ buttons.closeButton }}</el-button> |
||||
|
</span> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import { |
||||
|
getSeqStandardRollQty, |
||||
|
createSeparateRoll,/*执行创建分卷的操作*/ |
||||
|
} from '@/api/scheduleReport/com_separate_roll.js'; |
||||
|
|
||||
|
/*打印标签专用的js*/ |
||||
|
import { |
||||
|
printSfdcLabel, |
||||
|
} from "@/views/modules/scheduleReport/print_roll_label.js"; |
||||
|
|
||||
|
var functionId = 'C10000003'; |
||||
|
|
||||
|
export default { |
||||
|
data() { |
||||
|
return { |
||||
|
titleCon: '创建分卷', |
||||
|
visible: false, |
||||
|
scheduleData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
username: this.$store.state.user.name, |
||||
|
seqNo: '', |
||||
|
orderNo: '', |
||||
|
itemNo: 0, |
||||
|
partNo: '', |
||||
|
workCenterNo: '', |
||||
|
rollNo: '', |
||||
|
functionName: '', |
||||
|
currentRollFlag: false |
||||
|
}, |
||||
|
pageData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
username: this.$store.state.user.name, |
||||
|
orderNo: '', |
||||
|
itemNo: '', |
||||
|
seqNo: '', |
||||
|
rollNo: '', |
||||
|
reportDate: '', |
||||
|
reportTime: '', |
||||
|
rollQty: 0, |
||||
|
standardRollQty: 0, |
||||
|
rollNums: 1 |
||||
|
}, |
||||
|
buttons: { |
||||
|
confirmButton: '确定', |
||||
|
closeButton: '关闭', |
||||
|
}, |
||||
|
buttonList: [ |
||||
|
{ |
||||
|
functionId: functionId, |
||||
|
languageValue: '确定', |
||||
|
objectId: 'confirmButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '关闭', |
||||
|
objectId: 'closeButton', |
||||
|
objectType: 'button', |
||||
|
tableId: '*' |
||||
|
}, |
||||
|
], |
||||
|
queryButton: { |
||||
|
functionId: functionId, |
||||
|
table_id: '*', |
||||
|
languageCode: this.$i18n.locale, |
||||
|
objectType: 'button' |
||||
|
}, |
||||
|
labels: { |
||||
|
titleCon: '创建分卷', |
||||
|
rollQty: '良品数量:', |
||||
|
rollNums: '卷数:', |
||||
|
confirmLabel: '确认', |
||||
|
cancelLabel: '取消', |
||||
|
}, |
||||
|
labelsList: [ |
||||
|
{ |
||||
|
functionId: functionId, |
||||
|
languageValue: '创建分卷', |
||||
|
objectId: 'titleCon', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '当前时间:', |
||||
|
objectId: 'currentTime', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '良品数量:', |
||||
|
objectId: 'rollQty', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '卷数:', |
||||
|
objectId: 'rollNums', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '良品数量必须是正整数!', |
||||
|
objectId: 'approvedQtyMustBeInteger', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '卷数必须是正整数!', |
||||
|
objectId: 'rollQtyMustBeInteger', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '良品数量必须大于零且是整数!', |
||||
|
objectId: 'approvedQtyMustMoreTanZeroAndBeInteger', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '卷数必须大于零且是整数!', |
||||
|
objectId: 'rollQtyMustMoreTanZeroAndBeInteger', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '请先切换人员!', |
||||
|
objectId: 'pleaseSwitchOperator', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '确认', |
||||
|
objectId: 'confirmLabel', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, { |
||||
|
functionId: functionId, |
||||
|
languageValue: '取消', |
||||
|
objectId: 'cancelLabel', |
||||
|
objectType: 'label', |
||||
|
tableId: '*' |
||||
|
}, |
||||
|
], |
||||
|
queryLabel: { |
||||
|
functionId: functionId, |
||||
|
table_id: '*', |
||||
|
languageCode: this.$i18n.locale, |
||||
|
objectType: 'label' |
||||
|
}, |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
//页面初始化是的方法 |
||||
|
init(scheduleData) { |
||||
|
//初始化参数 |
||||
|
this.scheduleData = scheduleData; |
||||
|
//设置参数 |
||||
|
this.pageData.orderNo = scheduleData.orderNo; |
||||
|
this.pageData.itemNo = scheduleData.itemNo; |
||||
|
this.pageData.seqNo = scheduleData.seqNo; |
||||
|
//调用方法 获取标准卷的数量 |
||||
|
this.getSeqStandardRollQtyFun(); |
||||
|
//清空参数 |
||||
|
this.pageData.rollNums = 1; |
||||
|
this.visible = true; |
||||
|
//获取焦点 |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs.rollQty.focus(); |
||||
|
}); |
||||
|
this.titleCon = this.labels.titleCon;//重置标题 |
||||
|
}, |
||||
|
|
||||
|
//调用方法 获取标准卷的数量 |
||||
|
getSeqStandardRollQtyFun() { |
||||
|
// 获取标准卷的数量 |
||||
|
getSeqStandardRollQty(this.pageData).then(({data}) => { |
||||
|
if (data.code == 200) { |
||||
|
this.pageData.standardRollQty = data.standardRollQty; |
||||
|
this.pageData.rollQty = data.standardRollQty; |
||||
|
}else{ |
||||
|
this.$message.error(data.msg); |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
/*关闭modal*/ |
||||
|
closeDialog(){ |
||||
|
//刷新报工的页面 |
||||
|
this.$emit('refreshPageData'); |
||||
|
//关闭当前的页面 |
||||
|
this.visible = false; |
||||
|
}, |
||||
|
|
||||
|
/*检查材料卷号的数据*/ |
||||
|
checkValidQty() { |
||||
|
//获取当前是的数量 |
||||
|
let rollQty = parseFloat(this.pageData.rollQty); |
||||
|
//判断是否可以修改 |
||||
|
if (rollQty <= 0 || !Number.isInteger(rollQty)){ |
||||
|
this.$message.error('卷数量无效!'); |
||||
|
return false; |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
/*检查材料卷号的数据*/ |
||||
|
checkRollNums() { |
||||
|
//获取当前是的数量 |
||||
|
let rollNums = parseFloat(this.pageData.rollNums); |
||||
|
//判断是否是正整数 |
||||
|
if (rollNums <= 0 || !Number.isInteger(rollNums)){ |
||||
|
this.$message.error('卷数量无效!'); |
||||
|
return false; |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
//检查创建 |
||||
|
createSeparateRollFun() { |
||||
|
//获取当前是的数量 |
||||
|
let rollQty = parseInt(this.pageData.rollQty); |
||||
|
//判断是否可以修改 |
||||
|
if (rollQty <= 0 || !Number.isInteger(rollQty)){ |
||||
|
this.$message.error('卷数量无效!'); |
||||
|
return false; |
||||
|
} |
||||
|
|
||||
|
//判断是否是尾数卷 |
||||
|
if(rollQty < this.pageData.standardRollQty){ |
||||
|
let rollNums = parseInt(this.pageData.rollNums); |
||||
|
if(rollNums > 1){ |
||||
|
this.$message.error('当前的工单得尾数卷只能有一卷!'); |
||||
|
return false; |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
//获取当前是的数量 |
||||
|
let rollNums = parseFloat(this.pageData.rollNums); |
||||
|
//判断是否是正整数 |
||||
|
if (rollNums <= 0 || !Number.isInteger(rollNums)){ |
||||
|
this.$message.error('当前卷数无效!'); |
||||
|
return false; |
||||
|
} |
||||
|
//校验是否继续 |
||||
|
createSeparateRoll(this.pageData).then(({data}) => { |
||||
|
//判断是否成功 |
||||
|
if (data.code == 200) { |
||||
|
this.$message.success(data.msg); |
||||
|
//this.closeDialog(); |
||||
|
//清空卷数 重置数据量 |
||||
|
this.pageData.rollQty = this.pageData.standardRollQty; |
||||
|
this.pageData.rollNums = 1; |
||||
|
} else { |
||||
|
this.$message.error(data.msg); |
||||
|
} |
||||
|
}); |
||||
|
}, |
||||
|
|
||||
|
}, |
||||
|
created() { |
||||
|
// this.factoryList() |
||||
|
// this.getLanguageList() |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
</script> |
||||
|
|
||||
|
<style scoped lang="scss"> |
||||
|
/*调节页面button和input的上下间距*/ |
||||
|
.customer-css .customer-button{ |
||||
|
margin-top: 25px; |
||||
|
} |
||||
|
|
||||
|
/*调节fieldset下的样式*/ |
||||
|
.customer-fieldset .customer-item{ |
||||
|
margin-top: -15px; |
||||
|
} |
||||
|
|
||||
|
/*fieldset下table的样式*/ |
||||
|
.customer-fieldset /deep/ .el-table__header th.is-leaf{ |
||||
|
line-height: 16px; |
||||
|
} |
||||
|
|
||||
|
/deep/ .customer-tab .el-tabs__content{ |
||||
|
padding: 0px !important; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
@ -0,0 +1,146 @@ |
|||||
|
/*调用js打印标签*/ |
||||
|
import getLodop from '@/utils/LodopFuncs.js' |
||||
|
import { createAPI } from "@/utils/httpRequest.js"; |
||||
|
/*打印材料卷标签*/ |
||||
|
export function printMaterialLabel(printList) { |
||||
|
const LODOP = getLodop() |
||||
|
if (LODOP) { |
||||
|
LODOP.SET_SHOW_MODE("LANGUAGE",1); |
||||
|
//循环调用打印机
|
||||
|
for(let i = 0; i < printList.length; i++){ |
||||
|
let printData = printList[i]; |
||||
|
LODOP.NewPage(); |
||||
|
LODOP.SET_PRINT_PAGESIZE(0,700,600,""); |
||||
|
LODOP.ADD_PRINT_LINE(5,5,6,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(25,5,26,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(42,5,43,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(59,5,60,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(84,5,85,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(119,5,120,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(136,5,137,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(153,5,154,185,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(170,5,171,185,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(187,5,188,185,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(205,5,204,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(220,5,221,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(220,5,5,6,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(220,254,5,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(220,65,25,66,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(120,135,136,136,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(120,174,136,175,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(204,186,136,187,0,1); |
||||
|
LODOP.ADD_PRINT_TEXT(7,91,90,15,"原材料标签"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontName","黑体"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",12); |
||||
|
LODOP.ADD_PRINT_TEXT(28,7,60,15,"卷序号"); |
||||
|
LODOP.ADD_PRINT_TEXT(45,7,60,15,"料号"); |
||||
|
LODOP.ADD_PRINT_TEXT(65,7,60,20,"厂商"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",11); |
||||
|
LODOP.ADD_PRINT_TEXT(95,7,70,30,"品名规格"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",10); |
||||
|
LODOP.ADD_PRINT_TEXT(122,7,60,15,"数量"); |
||||
|
LODOP.ADD_PRINT_TEXT(139,7,60,15,"单位"); |
||||
|
LODOP.ADD_PRINT_TEXT(156,7,60,15,"入库日期"); |
||||
|
LODOP.ADD_PRINT_TEXT(173,7,60,15,"有效期"); |
||||
|
LODOP.ADD_PRINT_TEXT(190,7,60,15,"入库人员"); |
||||
|
LODOP.ADD_PRINT_TEXT(206,7,60,15,"校验签章"); |
||||
|
LODOP.ADD_PRINT_TEXT(122,137,38,20,"库位"); |
||||
|
LODOP.ADD_PRINT_TEXT(27,70,150,20, printData.rollNo); |
||||
|
LODOP.ADD_PRINT_TEXT(45,115,100,20, printData.partNo); |
||||
|
LODOP.ADD_PRINT_TEXT(66,70,190,15, printData.supplierDesc); |
||||
|
LODOP.ADD_PRINT_TEXT(88,70,187,35, printData.partDesc +' '+ printData.spec); |
||||
|
LODOP.ADD_PRINT_TEXT(122,69,65,20, printData.rollQty); |
||||
|
LODOP.ADD_PRINT_TEXT(121,176,83,20,printData.locationId); |
||||
|
LODOP.ADD_PRINT_TEXT(138,130,50,20, printData.umid); |
||||
|
LODOP.ADD_PRINT_TEXT(155,100,80,17, printData.rollDate); |
||||
|
LODOP.ADD_PRINT_TEXT(174,100,80,20, printData.expiredDate); |
||||
|
LODOP.ADD_PRINT_BARCODE(137,187,100,75,"QRCode", printData.rollNo); |
||||
|
LODOP.ADD_PRINT_TEXT(189,120,90,17, printData.createdBy); |
||||
|
} |
||||
|
//LODOP.PRINT_DESIGN();
|
||||
|
//LODOP.PREVIEW();
|
||||
|
LODOP.PRINT(); |
||||
|
|
||||
|
console.log("原材料标签打印成功! 数量为: "+printList.length+"张。") |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
/*打印流程标签*/ |
||||
|
export function printSfdcLabel(printList) { |
||||
|
const LODOP = getLodop() |
||||
|
if (LODOP) { |
||||
|
LODOP.SET_SHOW_MODE("LANGUAGE",1); |
||||
|
//循环调用打印机
|
||||
|
for(let i = 0; i < printList.length; i++){ |
||||
|
let printData = printList[i]; |
||||
|
LODOP.NewPage(); |
||||
|
LODOP.SET_PRINT_PAGESIZE(0,700,600,""); |
||||
|
LODOP.ADD_PRINT_LINE(5,5,6,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(25,5,26,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(40,5,41,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(55,5,56,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(90,5,91,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(105,5,106,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(120,5,121,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(135,5,136,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(152,5,153,185,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(169,5,170,185,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(187,5,186,185,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(203,5,204,254,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(218,6,219,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(218,5,5,6,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(218,254,5,255,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(185,65,25,66,0,1); |
||||
|
LODOP.ADD_PRINT_LINE(203,186,136,187,0,1); |
||||
|
//区分判断 显示不同的表
|
||||
|
if (printData.nextItemDesc === '仓库'){ |
||||
|
LODOP.ADD_PRINT_TEXT(7,96,90,15,"物料明细表"); |
||||
|
}else{ |
||||
|
LODOP.ADD_PRINT_TEXT(7,97,90,15,"流程标签"); |
||||
|
} |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontName","黑体"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",12); |
||||
|
LODOP.ADD_PRINT_TEXT(27,7,60,15,"卷号"); |
||||
|
LODOP.ADD_PRINT_TEXT(42,7,60,15,"料号"); |
||||
|
LODOP.ADD_PRINT_TEXT(65,8,70,25,"品名规格"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",10); |
||||
|
LODOP.ADD_PRINT_TEXT(92,5,60,17,"客户料号"); |
||||
|
LODOP.ADD_PRINT_TEXT(107,7,60,15,"客户名称"); |
||||
|
LODOP.ADD_PRINT_TEXT(123,7,60,17,"创建人/日期"); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",7); |
||||
|
LODOP.ADD_PRINT_TEXT(138,7,60,15,"数量"); |
||||
|
LODOP.ADD_PRINT_TEXT(154,7,50,15,"工序"); |
||||
|
LODOP.ADD_PRINT_TEXT(172,7,47,20,"下道"); |
||||
|
LODOP.ADD_PRINT_TEXT(27,70,150,15, printData.rollNo); |
||||
|
LODOP.ADD_PRINT_TEXT(42,115,100,15, printData.partNo); |
||||
|
LODOP.ADD_PRINT_TEXT(55,70,185,35, printData.partDesc); |
||||
|
LODOP.ADD_PRINT_TEXT(92,70,185,15, printData.customerPartNo); |
||||
|
LODOP.ADD_PRINT_TEXT(107,70,180,15, printData.customerName); |
||||
|
LODOP.ADD_PRINT_TEXT(122,70,45,15, printData.createdBy); |
||||
|
LODOP.ADD_PRINT_TEXT(122,135,130,15, printData.createdDate); |
||||
|
LODOP.ADD_PRINT_TEXT(137,79,70,15, printData.rollQty); |
||||
|
LODOP.ADD_PRINT_TEXT(155,70,115,15, printData.itemDesc); |
||||
|
LODOP.SET_PRINT_STYLEA(0,"FontSize",8); |
||||
|
LODOP.ADD_PRINT_TEXT(171,70,115,15, printData.nextItemDesc); |
||||
|
LODOP.ADD_PRINT_BARCODE(138,188,100,75,"QRCode", printData.rollNo); |
||||
|
if (printData.customerName === '伊连特' && printData.customerName != ''){ |
||||
|
LODOP.ADD_PRINT_IMAGE(187,10,23,16, "<img src='/static/img/sfdc_ul.jpg'/>"); |
||||
|
LODOP.SET_PRINT_STYLEA(0, "Stretch", 1);//(不变形)原比例扩展缩放模式
|
||||
|
//设置
|
||||
|
LODOP.ADD_PRINT_TEXT(188,50,100,20, printData.ul); |
||||
|
LODOP.ADD_PRINT_TEXT(205,11, 120, 15, "Factory ID: YR"); |
||||
|
} |
||||
|
} |
||||
|
//LODOP.PRINT_DESIGN();
|
||||
|
//LODOP.PREVIEW();
|
||||
|
LODOP.PRINT(); |
||||
|
|
||||
|
console.log("流转标签打印成功!数量:"+printList.length+"张。"); |
||||
|
} |
||||
|
} |
||||
|
|
||||
|
|
||||
|
// 打印数据
|
||||
|
export const getRollInfList = data => createAPI(`/schedule/getRollInfList`,'POST',data) |
||||
|
|
||||
|
|
||||
@ -0,0 +1,677 @@ |
|||||
|
<template> |
||||
|
<div class="customer-css"> |
||||
|
<!-- 菜单按钮区域 --> |
||||
|
<fieldset class="customer-field" style="width: 675px; padding: 0.35em 0.75em 0.425em;"> |
||||
|
<!-- 查询产品 --> |
||||
|
<el-form :inline="true" label-position="top" label-width="100px" style="margin-top: 5px;"> |
||||
|
<el-form-item label="工站:"> |
||||
|
<el-select v-model="searchData.itemNo"> |
||||
|
<el-option value="-1" label="全部"></el-option> |
||||
|
<el-option value="10" label="模切工站"></el-option> |
||||
|
<el-option value="20" label="FQC工站"></el-option> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="工单号:"> |
||||
|
<el-input v-model="searchData.orderNo" style="width: 120px" @keyup.enter.native="refreshPageTables"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label="' '" > |
||||
|
<el-button type="primary" @click="refreshPageTables()" class="customer-bun-mid" |
||||
|
style="margin-left: 10px; margin-bottom: 5px;">{{ buttons.searchButton }} |
||||
|
</el-button> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label="' '"> |
||||
|
<el-button type="primary" @click="dieCuttingReportModal" class="customer-bun-mid" |
||||
|
:disabled="reportButton.dieCuttingButton" |
||||
|
style="margin-left: 10px; margin-bottom: 5px;">{{ buttons.dieCuttingButton }} |
||||
|
</el-button> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label="' '"> |
||||
|
<el-button type="primary" @click="fqcReportModal()" class="customer-bun-mid" |
||||
|
:disabled="reportButton.fqcReportButton" |
||||
|
style="margin-left: 10px; margin-bottom: 5px;">{{ buttons.fqcReportButton }} |
||||
|
</el-button> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
</fieldset> |
||||
|
|
||||
|
<!-- 工单主表信息 --> |
||||
|
<el-main style="margin-left: -20px; margin-top: -20px; width: 104%;"> |
||||
|
<el-table @row-click="setCurrentRow" |
||||
|
:height="height" |
||||
|
highlight-current-row |
||||
|
:data="produceScheduleList" |
||||
|
border |
||||
|
v-loading="dataListLoading" |
||||
|
style="width: 100%;"> |
||||
|
<el-table-column |
||||
|
v-for="(item,index) in columnList" :key="index" |
||||
|
:sortable="item.columnSortable" |
||||
|
:prop="item.columnProp" |
||||
|
:header-align="item.headerAlign" |
||||
|
:show-overflow-tooltip="item.showOverflowTooltip" |
||||
|
:align="item.align" |
||||
|
:fixed="item.fixed==''?false:item.fixed" |
||||
|
:min-width="item.columnWidth" |
||||
|
:label="item.columnLabel"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span> |
||||
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
||||
|
style="width: 100px; height: 80px"/></span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-main> |
||||
|
|
||||
|
<!--列表的组件--> |
||||
|
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist> |
||||
|
|
||||
|
<!-- 动态列 --> |
||||
|
<column v-if="visible" ref="column" @refreshData="getTableUserColumn" v-drag></column> |
||||
|
<!-- 模切报工的组件 --> |
||||
|
<comDieCuttingReport :close-on-click-modal="false" ref="comDieCuttingReport"> |
||||
|
</comDieCuttingReport> |
||||
|
<!-- fqc报工的组件 --> |
||||
|
<comFqcReport :close-on-click-modal="false" ref="comFqcReport"> |
||||
|
</comFqcReport> |
||||
|
|
||||
|
|
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
|
||||
|
import { |
||||
|
getProduceScheduleList, |
||||
|
reportCheck, |
||||
|
getUserSpecialSecurity, |
||||
|
closeOrOpenProduceOrder, |
||||
|
pauseOrOpenProduceOrder, |
||||
|
costRollUpProduceOrder, |
||||
|
manualProduceOrder, |
||||
|
repairSOFlagProduceOrder, |
||||
|
workbenchCancelallops, |
||||
|
getShopOrder, |
||||
|
getScheduleMultiReportSpecialAuth,/* 获取派工单的特殊权限 */ |
||||
|
} from '@/api/scheduleReport/produce_order.js' |
||||
|
|
||||
|
/* 动态表头 */ |
||||
|
import { |
||||
|
saveTableDefaultList, |
||||
|
getTableDefaultListLanguage, |
||||
|
getTableUserListLanguage, |
||||
|
removerDefault, |
||||
|
removerUser |
||||
|
} from '@/api/table.js' |
||||
|
|
||||
|
/* 引入组件 */ |
||||
|
import Chooselist from '@/views/modules/common/Chooselist'/* 列表组件 */ |
||||
|
import column from '@/views/modules/common/column' |
||||
|
import comDieCuttingReport from './com_die_cutting_report' /* 模切报工的组件 */ |
||||
|
import comFqcReport from './com_fqc_report' /* 模切报工的组件 */ |
||||
|
var functionId = '600001'; |
||||
|
|
||||
|
export default { |
||||
|
data() { |
||||
|
return { |
||||
|
height: 800, |
||||
|
authEdit: false, |
||||
|
authAdd: false, |
||||
|
authDelete: false, |
||||
|
menuId: this.$route.meta.menuId, |
||||
|
menuShow: false, |
||||
|
visible: false, |
||||
|
searchData: { |
||||
|
site: this.$store.state.user.site, |
||||
|
itemNo: '', |
||||
|
orderNo: '', |
||||
|
status: 1, |
||||
|
username: this.$store.state.user.name, |
||||
|
searchFlag: true, |
||||
|
exportFlag: "N", |
||||
|
}, |
||||
|
currentRow: {}, |
||||
|
produceScheduleList: [], |
||||
|
dataListLoading: false, |
||||
|
columnList: [ |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceOrderNo', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'orderNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '生产订单号', |
||||
|
columnWidth: 120, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceItemNo', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'itemNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '工序号', |
||||
|
columnWidth: 80, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceItemDesc', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'itemDesc', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '工序描述', |
||||
|
columnWidth: 80, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceQtyRequired', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'qtyRequired', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '需求数量', |
||||
|
columnWidth: 60, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceQtyReported', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'qtyReported', |
||||
|
headerAlign: 'center', |
||||
|
align: 'right', |
||||
|
columnLabel: '已报告数量', |
||||
|
columnWidth: 100, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProducePartNo', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'partNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '产品编码', |
||||
|
columnWidth: 120, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: true, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProducePartDesc', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'partDesc', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '产品名称', |
||||
|
columnWidth: 180, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceRemark', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'remark', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '备注', |
||||
|
columnWidth: 180, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceScheduledDate', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'scheduledDate', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '排产日期', |
||||
|
columnWidth: 120, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceShiftNo', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'shiftNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '班次', |
||||
|
columnWidth: 80, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: functionId, |
||||
|
serialNumber: '600001ProduceCustomerName', |
||||
|
tableId: '600001Produce', |
||||
|
tableName: '待生产工单', |
||||
|
columnProp: 'customerName', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '客户名称', |
||||
|
columnWidth: 180, |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '' |
||||
|
}, |
||||
|
], |
||||
|
reportButton: { |
||||
|
dieCuttingButton: true, |
||||
|
fqcReportButton: true, |
||||
|
}, |
||||
|
queryTable: { |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: this.$route.meta.menuId, |
||||
|
tableId: '600001Produce', |
||||
|
languageCode: this.$i18n.locale |
||||
|
}, |
||||
|
// 用户table 查询参数 |
||||
|
userColumnList: [], |
||||
|
buttons: { |
||||
|
searchButton: '查询', |
||||
|
dieCuttingButton: '模切工站', |
||||
|
fqcReportButton: 'FQC报工', |
||||
|
}, |
||||
|
// 导出 start |
||||
|
exportList: [], |
||||
|
exportName: "生产工单", |
||||
|
exportHeader: [], |
||||
|
exportFooter: [], |
||||
|
exportDefaultValue: "", |
||||
|
// 导出 end |
||||
|
} |
||||
|
}, |
||||
|
components: { |
||||
|
Chooselist, /* 选择的组件 */ |
||||
|
column,/* 动态列 */ |
||||
|
comDieCuttingReport, /* 模切工站页面的组件 */ |
||||
|
comFqcReport,/* fqc工站的组件*/ |
||||
|
}, |
||||
|
mounted() { |
||||
|
this.$nextTick(() => { |
||||
|
this.height = window.innerHeight - 190 |
||||
|
}) |
||||
|
}, |
||||
|
methods: { |
||||
|
/* 查询派工单 */ |
||||
|
getProduceScheduleList() { |
||||
|
// 开始真的查询; |
||||
|
this.searchData.searchFlag = true |
||||
|
getProduceScheduleList(this.searchData).then(({data}) => { |
||||
|
// 设置查询数据 |
||||
|
this.produceScheduleList = data.rows |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
/* 刷新页面table */ |
||||
|
refreshPageTables() { |
||||
|
this.currentRow = {} |
||||
|
this.getProduceScheduleList() |
||||
|
}, |
||||
|
/* 设置选中行的参数 */ |
||||
|
setCurrentRow(row, column, event) { |
||||
|
this.currentRow = JSON.parse(JSON.stringify(row)); |
||||
|
//区分当前的工序数据 |
||||
|
if(10 === this.currentRow.itemNo){ |
||||
|
this.reportButton.dieCuttingButton = false; |
||||
|
this.reportButton.fqcReportButton = true; |
||||
|
}else if(20 === this.currentRow.itemNo){ |
||||
|
this.reportButton.dieCuttingButton = true; |
||||
|
this.reportButton.fqcReportButton = false; |
||||
|
} |
||||
|
}, |
||||
|
// 切换报工modal |
||||
|
dieCuttingReportModal() { |
||||
|
// 首先判断是否选择好派工单 |
||||
|
if (JSON.stringify(this.currentRow) == '{}') { |
||||
|
this.$message.error('请先选择好工单!') |
||||
|
return false |
||||
|
} |
||||
|
// 打开操作员切换功能 |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs.comDieCuttingReport.init(this.currentRow.seqNo) |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
// 打开分切报工的 |
||||
|
fqcReportModal() { |
||||
|
// 首先判断是否选择好派工单 |
||||
|
if (JSON.stringify(this.currentRow) == '{}') { |
||||
|
this.$message.error('请先选择好工单!') |
||||
|
return false |
||||
|
} |
||||
|
this.$nextTick(() => { |
||||
|
// 打开分切报工功能 |
||||
|
this.$refs.comFqcReport.init(this.currentRow.seqNo); |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
// 结束派工单后刷新页面 |
||||
|
processFinishScheduleOperation() { |
||||
|
// 刷新当前页面的数据 |
||||
|
this.refreshPageTables() |
||||
|
}, |
||||
|
|
||||
|
/* 列表方法的回调 */ |
||||
|
getBaseData(val) { |
||||
|
if (this.tagNo === 88) { |
||||
|
this.searchData.resourceId = val.ResourceID |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
// 获取基础数据列表 |
||||
|
getBaseList(val) { |
||||
|
this.tagNo = val |
||||
|
this.$nextTick(() => { |
||||
|
let strVal = '' |
||||
|
if (val === 88) { |
||||
|
strVal = this.searchData.resourceId |
||||
|
} |
||||
|
this.$refs.baseList.init(val, strVal, " AND WorkCenterNo <> 'FQC'") |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
// 打开页面设置 |
||||
|
userSetting() { |
||||
|
this.visible = true |
||||
|
let queryTable = { |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: this.$route.meta.menuId, |
||||
|
tableId: '600001Produce', |
||||
|
languageCode: this.$i18n.locale |
||||
|
} |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs.column.init(queryTable) |
||||
|
}) |
||||
|
}, |
||||
|
// 获取 用户保存的 格式列 |
||||
|
getTableUserColumn() { |
||||
|
getTableUserListLanguage(this.queryTableUser).then(({data}) => { |
||||
|
if (data && data.code == 0 && data.rows.length > 0) { |
||||
|
// this.columnList = [] |
||||
|
this.columnList = data.rows |
||||
|
} else { |
||||
|
this.getColumnList() |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 保存 默认配置 列 |
||||
|
async saveColumnList() { |
||||
|
// 删除所有的该页面下保存的数据 |
||||
|
if (this.userColumnList) { |
||||
|
// 删除 user自定义的数据 |
||||
|
await removerUser(this.queryTable) |
||||
|
} |
||||
|
// 删除默认配置 |
||||
|
await removerDefault(this.queryTable) |
||||
|
// 保存页面 table属性 |
||||
|
let sumColumnList = this.columnList// concat(this.columnList1); |
||||
|
sumColumnList = sumColumnList.map(item => { |
||||
|
return item = { |
||||
|
tableId: item.tableId, |
||||
|
tableName: item.tableName, |
||||
|
columnProp: item.columnProp, |
||||
|
columnLabel: item.columnLabel, |
||||
|
columnHidden: item.columnHidden, |
||||
|
columnImage: item.columnImage, |
||||
|
columnSortable: item.columnSortable, |
||||
|
columnWidth: item.columnWidth, |
||||
|
format: item.format, |
||||
|
functionId: this.$route.meta.menuId, |
||||
|
sortLv: item.sortLv, |
||||
|
status: true, |
||||
|
fixed: item.fixed, |
||||
|
serialNumber: item.serialNumber, |
||||
|
columnType: item.columnType, |
||||
|
align: item.align |
||||
|
} |
||||
|
}) |
||||
|
|
||||
|
await saveTableDefaultList(sumColumnList) |
||||
|
// 保存页面 button label title 属性 |
||||
|
/* let buttons = this.buttonList.map(item => { |
||||
|
return item = { |
||||
|
functionId: this.$route.meta.menuId, |
||||
|
languageValue: item.languageValue, |
||||
|
objectId: item.objectId, |
||||
|
objectType: item.objectType, |
||||
|
tableId: item.tableId |
||||
|
} |
||||
|
}) |
||||
|
await saveButtonList(buttons) */ |
||||
|
this.getFunctionButtonList() |
||||
|
this.getColumnList() |
||||
|
}, |
||||
|
// 获取 tableDefault 列 |
||||
|
getColumnList() { |
||||
|
getTableDefaultListLanguage(this.queryTable).then(({data}) => { |
||||
|
if (data && data.code == 0) { |
||||
|
// this.showDefault = false |
||||
|
this.columnList = data.rows |
||||
|
} else { |
||||
|
// this.showDefault = true |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
|
||||
|
|
||||
|
fields() { |
||||
|
let json = "{" |
||||
|
this.columnList.forEach((item, index) => { |
||||
|
if (index == this.columnList.length - 1) { |
||||
|
json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" |
||||
|
} else { |
||||
|
json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + "," |
||||
|
} |
||||
|
}) |
||||
|
json += "}" |
||||
|
let s = eval("(" + json + ")") |
||||
|
return s |
||||
|
}, |
||||
|
|
||||
|
//导出excel |
||||
|
async createExportData() { |
||||
|
// 开始真的查询; |
||||
|
this.searchData.searchFlag = true; |
||||
|
this.searchData.exportFlag = "Y"; |
||||
|
await getProduceScheduleList(this.searchData).then(({data}) => { |
||||
|
// 设置查询数据 |
||||
|
this.exportList = data.rows |
||||
|
}) |
||||
|
//重置判断是否是导出的sql |
||||
|
this.searchData.exportFlag = "N"; |
||||
|
return this.exportList; |
||||
|
}, |
||||
|
startDownload() { |
||||
|
// this.exportData = this.dataList |
||||
|
|
||||
|
}, |
||||
|
finishDownload() { |
||||
|
|
||||
|
}, |
||||
|
|
||||
|
}, |
||||
|
created() { |
||||
|
// 不查询 |
||||
|
getProduceScheduleList(this.searchData).then(({data}) => { |
||||
|
// 设置查询数据 |
||||
|
this.searchData.searchFlag = false; |
||||
|
this.searchData.exportFlag = 'N'; |
||||
|
this.produceScheduleList = data.rows |
||||
|
}) |
||||
|
|
||||
|
|
||||
|
// 获取动态表头的信息 |
||||
|
//this.getTableUserColumn() |
||||
|
} |
||||
|
|
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style> |
||||
|
.el-textarea__inner { |
||||
|
padding: 5px 5px; |
||||
|
} |
||||
|
|
||||
|
</style> |
||||
|
|
||||
|
<!--当前页面的标签样式--> |
||||
|
<style scoped lang="scss"> |
||||
|
|
||||
|
/*针对el-card*/ |
||||
|
.customer-card .el-form-item__content { |
||||
|
margin-top: -15px; |
||||
|
} |
||||
|
|
||||
|
.customer-card .el-form-item { |
||||
|
height: 22px; |
||||
|
} |
||||
|
|
||||
|
.customer-border .el-form-item__content { |
||||
|
margin-top: -30px; |
||||
|
} |
||||
|
|
||||
|
/*全局年与日类型 宽度*/ |
||||
|
div.el-time-width { |
||||
|
width: 110px !important; |
||||
|
} |
||||
|
|
||||
|
/* 全局时间右边框*/ |
||||
|
.customer-css input.el-input__inner { |
||||
|
height: 22px !important; |
||||
|
padding-right: 0px !important; |
||||
|
} |
||||
|
|
||||
|
/* 控制el-card标签的数据*/ |
||||
|
div.customer-el-card { |
||||
|
margin-left: 110px; |
||||
|
margin-top: -15px; |
||||
|
height: 20px; |
||||
|
width: 60px; |
||||
|
} |
||||
|
|
||||
|
/* 颜色控制 */ |
||||
|
div.customer-el-card-pink { |
||||
|
background: #FF00FF; |
||||
|
} |
||||
|
|
||||
|
div.customer-el-card-orange { |
||||
|
background: #FFD700; |
||||
|
} |
||||
|
|
||||
|
div.customer-el-card-blue { |
||||
|
background: #0000CD; |
||||
|
} |
||||
|
|
||||
|
/*清掉样式*/ |
||||
|
.el-radio + .el-radio { |
||||
|
margin-left: 0px; |
||||
|
} |
||||
|
|
||||
|
/*当前按钮的通用样式*/ |
||||
|
.customer-css .customer-bun-mid { |
||||
|
width: 65px; |
||||
|
text-align: center; |
||||
|
} |
||||
|
|
||||
|
/*当前按钮的通用样式*/ |
||||
|
.customer-css .el-button--medium { |
||||
|
padding: 5px 5px; |
||||
|
} |
||||
|
|
||||
|
/*添加主菜单和明细菜单的样式*/ |
||||
|
.customer-css .customer-dropdown .el-button--primary { |
||||
|
padding: 2px; |
||||
|
font-size: 12px; |
||||
|
} |
||||
|
|
||||
|
.el-dropdown-menu--medium .el-dropdown-menu__item { |
||||
|
line-height: 18px; |
||||
|
padding: 0 17px; |
||||
|
font-size: 12px; |
||||
|
} |
||||
|
|
||||
|
hr { |
||||
|
margin-top: 0px; |
||||
|
} |
||||
|
|
||||
|
|
||||
|
/*控制上下间距*/ |
||||
|
</style> |
||||
Write
Preview
Loading…
Cancel
Save
Reference in new issue