Browse Source

班次选择组件

master
rui_li 4 years ago
parent
commit
92a11836e3
  1. 14
      src/api/yieldReport/com_select_shift.js
  2. 4
      src/api/yieldReport/produce_report_normal.js
  3. 0
      src/icons/svg/icon-ellipsis.svg
  4. 54
      src/views/modules/yieldReport/com_finish_part_roll.vue
  5. 63
      src/views/modules/yieldReport/com_finish_roll.vue
  6. 252
      src/views/modules/yieldReport/com_select_shift.vue
  7. 65
      src/views/modules/yieldReport/not_over_finish_roll.vue
  8. 65
      src/views/modules/yieldReport/otherReport/bulk_inspection.vue

14
src/api/yieldReport/com_select_shift.js

@ -1,14 +1,4 @@
import { createAPI } from '@/utils/httpRequest.js' import { createAPI } from '@/utils/httpRequest.js'
// 获取当前的卷的上机材料的主料
export const getSfdcMaterialByRollNo = data => createAPI('schedule/getSfdcMaterialByRollNo', 'POST', data)
//
export const endTuningAndStartProduce = data => createAPI('schedule/endTuningAndStartProduce', 'POST', data)
//获取选择班次的信息
export const getScheduleShiftWithSelect = data => createAPI('schedule/getScheduleShiftWithSelect', 'POST', data)

4
src/api/yieldReport/produce_report_normal.js

@ -78,6 +78,10 @@ export const getReworkSfdcRollByCon = data => createAPI('schedule/getReworkSfdcR
//switchrollReverse //switchrollReverse
export const switchrollReverse = data => createAPI('schedule/switchrollReverse', 'POST', data) export const switchrollReverse = data => createAPI('schedule/switchrollReverse', 'POST', data)
//查询班次数据
export const getScheduleShiftData = data => createAPI('schedule/getScheduleShiftData', 'POST', data)

0
src/icons/svg/ellipsis.svg → src/icons/svg/icon-ellipsis.svg

54
src/views/modules/yieldReport/com_finish_part_roll.vue

@ -35,7 +35,7 @@
</el-row> </el-row>
<!-- 卷数量统计 班次信息 --> <!-- 卷数量统计 班次信息 -->
<el-form> <el-form>
<fieldset class="customer-fieldset" style="width: 505px;">
<fieldset class="customer-fieldset" style="width: 495px;">
<legend>卷数量统计</legend> <legend>卷数量统计</legend>
<el-form-item class="customer-item"> <el-form-item class="customer-item">
<el-checkbox disabled="disabled" style="margin-top: 15px;" true-label="Y" false-label="N" <el-checkbox disabled="disabled" style="margin-top: 15px;" true-label="Y" false-label="N"
@ -57,7 +57,7 @@
</fieldset> </fieldset>
<!-- 操作员信息和班次信息 --> <!-- 操作员信息和班次信息 -->
<fieldset class="customer-fieldset" <fieldset class="customer-fieldset"
style="margin-left: 510px; margin-top: -70px; ;width: 390px;">
style="margin-left: 500px; margin-top: -70px; ;width: 400px;">
<legend>人员排程班次信息</legend> <legend>人员排程班次信息</legend>
<el-form-item class="customer-item" label="操作员:"> <el-form-item class="customer-item" label="操作员:">
<el-input v-model="operatorData.operatorId" disabled="disabled" style="width: 80px;" ></el-input> <el-input v-model="operatorData.operatorId" disabled="disabled" style="width: 80px;" ></el-input>
@ -71,6 +71,10 @@
<el-form-item class="customer-item" label="班次:"> <el-form-item class="customer-item" label="班次:">
<el-input v-model="pageData.shiftDesc" disabled="disabled" style="width: 80px;"></el-input> <el-input v-model="pageData.shiftDesc" disabled="disabled" style="width: 80px;"></el-input>
</el-form-item> </el-form-item>
<el-button type="info" :disabled="buttonTags.selectShiftFlag" plain @click="selectSchduleShiftModal"
style="margin-left: -10px; margin-top: 10px; height: 20px; padding: 3px 3px;">
<icon-svg name="ellipsis" style="height: 10px; width: 10px;" ></icon-svg>
</el-button>
</fieldset> </fieldset>
</el-form> </el-form>
<!-- 卷生产时间统计产量报告 --> <!-- 卷生产时间统计产量报告 -->
@ -219,8 +223,13 @@
<comExceptionReason ref="comExceptionReason" :close-on-click-modal="false" <comExceptionReason ref="comExceptionReason" :close-on-click-modal="false"
:visible.sync="showExceptionFlag" :visible.sync="showExceptionFlag"
@initExceptionReason = "initExceptionReason"> @initExceptionReason = "initExceptionReason">
</comExceptionReason> </comExceptionReason>
<!-- 班次选择组件 -->
<comSelectShift ref="comSelectShift" :close-on-click-modal="false"
:visible.sync="showShiftFlag"
@initScheduleShift = "initScheduleShift">
</comSelectShift>
</div> </div>
</template> </template>
@ -228,7 +237,8 @@
<script> <script>
/*添加组件*/ /*添加组件*/
import comExceptionReason from "./com_exception_reason";// import comExceptionReason from "./com_exception_reason";//
import {
import comSelectShift from "./com_select_shift";//
import {
getCurrentRollReportedQty, getCurrentRollReportedQty,
countSfdcTimeQty, countSfdcTimeQty,
getScheduleShiftData, getScheduleShiftData,
@ -245,6 +255,7 @@ export default {
return { return {
titleCon: '产量报告', titleCon: '产量报告',
showExceptionFlag: false, showExceptionFlag: false,
showShiftFlag: false,
sfdcTimeList: [], sfdcTimeList: [],
scheduleData: { scheduleData: {
site: this.$store.state.user.site, site: this.$store.state.user.site,
@ -488,10 +499,14 @@ export default {
} }
], ],
dataListLoading: false, dataListLoading: false,
buttonTags:{
selectShiftFlag: true,
},
} }
}, },
components: { components: {
comExceptionReason,/*异常原因的组件*/ comExceptionReason,/*异常原因的组件*/
comSelectShift,/*班次选择的组件*/
}, },
methods: { methods: {
/*初始化页面参数*/ /*初始化页面参数*/
@ -582,6 +597,7 @@ export default {
}); });
//3. //3.
await getScheduleShiftData(this.scheduleData).then(({data}) => { await getScheduleShiftData(this.scheduleData).then(({data}) => {
let specialAuth = 'N';
// //
if(data.code == 500){ if(data.code == 500){
this.pageData.shiftDesc = data.row.shiftDesc;// this.pageData.shiftDesc = data.row.shiftDesc;//
@ -591,6 +607,14 @@ export default {
this.pageData.shiftDesc = data.row.shiftDesc;// this.pageData.shiftDesc = data.row.shiftDesc;//
this.pageData.scheduledDate = data.row.scheduledDate.substring(0, 10);// this.pageData.scheduledDate = data.row.scheduledDate.substring(0, 10);//
this.pageData.shiftNo = data.row.shiftNo; this.pageData.shiftNo = data.row.shiftNo;
//
specialAuth = data.row.specialAuth;
}
//
if("Y" === specialAuth){
this.buttonTags.selectShiftFlag = false;
}else{
this.buttonTags.selectShiftFlag = true;
} }
}); });
//4. //4.
@ -821,7 +845,27 @@ export default {
this.pageData.exceptionReason = exceptionReason; this.pageData.exceptionReason = exceptionReason;
// //
this.finishRollOperation(); this.finishRollOperation();
}
},
/*打开班次选择页面*/
selectSchduleShiftModal(){
//1.
//checkProduceButton('produceMaterialFlag');
//
this.$nextTick(() => {
this.showShiftFlag = true;
this.$refs.comSelectShift.init(this.pageData);
});
},
/*修改页面的班次和排产的时间*/
initScheduleShift(scheduleDate, shiftDesc, username){
//
this.pageData.scheduledDate = scheduleDate.substring(0, 10);
this.pageData.shiftDesc = shiftDesc;
this.pageData.remark = username+"更改了班次."
},
}, },
created() { created() {
// this.factoryList() // this.factoryList()

63
src/views/modules/yieldReport/com_finish_roll.vue

@ -16,7 +16,7 @@
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
<el-form-item class="customer-button"> <el-form-item class="customer-button">
<el-button class="customer-bun-min" type="primary" :disabled="buttonTags.createRollFlag" style="margin-left: 10px; margin-bottom: 5px;">
<el-button class="customer-bun-min" type="primary" style="margin-left: 10px; margin-bottom: 5px;">
列表</el-button> 列表</el-button>
</el-form-item> </el-form-item>
<el-form-item class="customer-button"> <el-form-item class="customer-button">
@ -35,7 +35,7 @@
</el-row> </el-row>
<!-- 卷数量统计 班次信息 --> <!-- 卷数量统计 班次信息 -->
<el-form> <el-form>
<fieldset class="customer-fieldset" style="width: 505px;">
<fieldset class="customer-fieldset" style="width: 495px;">
<legend>卷数量统计</legend> <legend>卷数量统计</legend>
<el-form-item class="customer-item"> <el-form-item class="customer-item">
<el-checkbox disabled="disabled" style="margin-top: 15px;" true-label="Y" false-label="N" <el-checkbox disabled="disabled" style="margin-top: 15px;" true-label="Y" false-label="N"
@ -57,7 +57,7 @@
</fieldset> </fieldset>
<!-- 操作员信息和班次信息 --> <!-- 操作员信息和班次信息 -->
<fieldset class="customer-fieldset" <fieldset class="customer-fieldset"
style="margin-left: 510px; margin-top: -70px; ;width: 390px;">
style="margin-left: 500px; margin-top: -70px; width: 400px;">
<legend>人员排程班次信息</legend> <legend>人员排程班次信息</legend>
<el-form-item class="customer-item" label="操作员:"> <el-form-item class="customer-item" label="操作员:">
<el-input v-model="operatorData.operatorId" disabled="disabled" style="width: 80px;" ></el-input> <el-input v-model="operatorData.operatorId" disabled="disabled" style="width: 80px;" ></el-input>
@ -71,6 +71,11 @@
<el-form-item class="customer-item" label="班次:"> <el-form-item class="customer-item" label="班次:">
<el-input v-model="pageData.shiftDesc" class="customer-input-color-red" readonly="readonly" style="width: 80px;"></el-input> <el-input v-model="pageData.shiftDesc" class="customer-input-color-red" readonly="readonly" style="width: 80px;"></el-input>
</el-form-item> </el-form-item>
<el-button type="info" :disabled="buttonTags.selectShiftFlag" plain @click="selectSchduleShiftModal"
style="margin-left: -10px; margin-top: 10px; height: 20px; padding: 3px 3px;">
<icon-svg name="ellipsis" style="height: 10px; width: 10px;" ></icon-svg>
</el-button>
</fieldset> </fieldset>
</el-form> </el-form>
<!-- 卷生产时间统计产量报告 --> <!-- 卷生产时间统计产量报告 -->
@ -222,6 +227,12 @@
@initExceptionReason = "initExceptionReason"> @initExceptionReason = "initExceptionReason">
</comExceptionReason> </comExceptionReason>
<!-- 班次选择组件 -->
<comSelectShift ref="comSelectShift" :close-on-click-modal="false"
:visible.sync="showShiftFlag"
@initScheduleShift = "initScheduleShift">
</comSelectShift>
</div> </div>
</template> </template>
@ -229,6 +240,7 @@
<script> <script>
/*添加组件*/ /*添加组件*/
import comExceptionReason from "./com_exception_reason";// import comExceptionReason from "./com_exception_reason";//
import comSelectShift from "./com_select_shift";//
import { import {
getCurrentRollReportedQty, getCurrentRollReportedQty,
countSfdcTimeQty, countSfdcTimeQty,
@ -247,6 +259,7 @@ export default {
return { return {
titleCon: '结束卷', titleCon: '结束卷',
showExceptionFlag: false, showExceptionFlag: false,
showShiftFlag: false,
showNumFlag:false, showNumFlag:false,
sfdcTimeList: [], sfdcTimeList: [],
scheduleData: { scheduleData: {
@ -493,23 +506,14 @@ export default {
} }
], ],
buttonTags:{ buttonTags:{
createNewRollFlag: true,
switchRollFlag: true,
separatorRollFlag: true,
finishRollFlag: true,
mergeRollFlag: true,
tuningFlag: true,
produceFlag: true,
defectFlag: true,
toolFlag: true,
materialFlag: true,
downTimeFlag: true
selectShiftFlag: true,
}, },
dataListLoading: false, dataListLoading: false,
} }
}, },
components: { components: {
comExceptionReason,/*异常原因的组件*/ comExceptionReason,/*异常原因的组件*/
comSelectShift,/*班次选择的组件*/
}, },
methods: { methods: {
sORoutingPreviousOperationItemNo(){ sORoutingPreviousOperationItemNo(){
@ -606,6 +610,7 @@ export default {
}); });
//3. //3.
await getScheduleShiftData(this.scheduleData).then(({data}) => { await getScheduleShiftData(this.scheduleData).then(({data}) => {
let specialAuth = 'N';
// //
if(data.code == 500){ if(data.code == 500){
this.pageData.shiftDesc = data.row.shiftDesc;// this.pageData.shiftDesc = data.row.shiftDesc;//
@ -615,6 +620,14 @@ export default {
this.pageData.shiftDesc = data.row.shiftDesc;// this.pageData.shiftDesc = data.row.shiftDesc;//
this.pageData.scheduledDate = data.row.scheduledDate.substring(0, 10);// this.pageData.scheduledDate = data.row.scheduledDate.substring(0, 10);//
this.pageData.shiftNo = data.row.shiftNo; this.pageData.shiftNo = data.row.shiftNo;
//
specialAuth = data.row.specialAuth;
}
//
if("Y" === specialAuth){
this.buttonTags.selectShiftFlag = false;
}else{
this.buttonTags.selectShiftFlag = true;
} }
}); });
//4. //4.
@ -853,7 +866,27 @@ export default {
this.pageData.exceptionReason = exceptionReason; this.pageData.exceptionReason = exceptionReason;
// //
this.finishRollOperation(); this.finishRollOperation();
}
},
/*打开班次选择页面*/
selectSchduleShiftModal(){
//1.
//checkProduceButton('produceMaterialFlag');
//
this.$nextTick(() => {
this.showShiftFlag = true;
this.$refs.comSelectShift.init(this.pageData);
});
},
/*修改页面的班次和排产的时间*/
initScheduleShift(scheduleDate, shiftDesc, username){
//
this.pageData.scheduledDate = scheduleDate.substring(0, 10);
this.pageData.shiftDesc = shiftDesc;
this.pageData.remark = username+"更改了班次."
},
}, },
created() { created() {
// this.factoryList() // this.factoryList()

252
src/views/modules/yieldReport/com_select_shift.vue

@ -1,20 +1,20 @@
<template> <template>
<div class="customer-css"> <div class="customer-css">
<el-dialog :title="titleCon" v-drag v-bind="$attrs" v-on="$listeners" <el-dialog :title="titleCon" v-drag v-bind="$attrs" v-on="$listeners"
width="900px" style="height: 415px;" class="customer-dialog">
<el-form :inline="true" label-position="top" style="height: 265px;"
width="575px" style="height: 360px;" class="customer-dialog">
<el-form :inline="true" label-position="top" style="height: 200px;"
label-width="80px"> label-width="80px">
<!-- 主材料 --> <!-- 主材料 -->
<el-form>
<fieldset class="customer-fieldset" style="">
<el-table height="180" <el-table height="180"
:cell-style="customerCellStyle" :cell-class-name="customerCellClassName"
:data="sfdcMaterialList"
:data="scheduleShiftList"
border border
v-loading="dataListLoading" v-loading="dataListLoading"
style="width: 100%; margin-top: -5px;">
@row-click="setCurrentShiftRow"
@row-dblclick="updateScheduleAndShift"
style="margin-top: 0px;">
<el-table-column <el-table-column
v-for="(item,index) in columnMaterialArray" :key="index"
v-for="(item,index) in columnShiftArray" :key="index"
:sortable="item.columnSortable" :sortable="item.columnSortable"
:prop="item.columnProp" :prop="item.columnProp"
:header-align="item.headerAlign" :header-align="item.headerAlign"
@ -34,45 +34,26 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
</fieldset>
</el-form> </el-form>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="updateScheduleAndShift"> </el-button>
<el-button type="primary" @click="closeDialog">关闭</el-button>
</span>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
<script> <script>
import { import {
getSfdcMaterialByRollNo,
endTuningAndStartProduce,
getScheduleShiftWithSelect,
} from '@/api/yieldReport/com_select_shift.js'; } from '@/api/yieldReport/com_select_shift.js';
export default { export default {
name: "com_select_shift", name: "com_select_shift",
data() { data() {
return { return {
titleCon: '',
scheduleData: {
site: this.$store.state.user.site,
username: this.$store.state.user.name,
seqNo: '',
orderNo: '',
itemNo: 0,
partNo: '',
workCenterDesc: '',
resourceDesc: '',
rollNo: '',
partDesc: '',
planStartTime: '',
planFinishTime: '',
qtyRequiredOriginal: 0,
scheduledDate: '',
shiftNo: '',
preItemDesc: '',
nextItemDesc: '',
nextItemNo: 0,
currentRollFlag: false
},
titleCon: '班次选择',
currentShiftRow: {},
pageData: { pageData: {
site: this.$store.state.user.site, site: this.$store.state.user.site,
username: this.$store.state.user.name, username: this.$store.state.user.name,
@ -82,23 +63,15 @@ export default {
operatorId: '', operatorId: '',
reportDate: '', reportDate: '',
reportTime: '', reportTime: '',
},
operatorData: {
site: this.$store.state.user.site,
username: this.$store.state.user.name,
operatorId: '',
operatorName: '',
status: '',
seqNo: '',
showFlag: false
scheduledDate: '',
}, },
scheduleShiftList: [], scheduleShiftList: [],
columnShiftArray: [ columnShiftArray: [
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
functionId: 5306, functionId: 5306,
serialNumber: '5306MaterialScheduleDate',
tableId: "5306Material",
serialNumber: '5306ShiftScheduleDate',
tableId: "5306Shift",
tableName: "派工单材料", tableName: "派工单材料",
columnProp: "scheduleDate", columnProp: "scheduleDate",
headerAlign: "center", headerAlign: "center",
@ -114,14 +87,14 @@ export default {
}, },
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialReportedBy',
tableId: "5305Material",
functionId: 5306,
serialNumber: '5306ShiftShiftNo',
tableId: "5306Shift",
tableName: "派工单材料", tableName: "派工单材料",
columnProp: "reportedBy",
columnProp: "shiftNo",
headerAlign: "center", headerAlign: "center",
align: "center", align: "center",
columnLabel: "报告人",
columnLabel: "班次",
columnWidth: 60, columnWidth: 60,
columnHidden: false, columnHidden: false,
columnImage: false, columnImage: false,
@ -132,14 +105,14 @@ export default {
}, },
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialRmRollNo',
tableId: "5305Material",
functionId: 5306,
serialNumber: '5306ShiftShiftDesc',
tableId: "5306Shift",
tableName: "派工单材料", tableName: "派工单材料",
columnProp: "rmRollNo",
columnProp: "shiftDesc",
headerAlign: "center", headerAlign: "center",
align: "center", align: "center",
columnLabel: "材料卷号",
columnLabel: "班次描述",
columnWidth: 100, columnWidth: 100,
columnHidden: false, columnHidden: false,
columnImage: false, columnImage: false,
@ -150,14 +123,14 @@ export default {
}, },
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialPartNo',
tableId: "5305Material",
functionId: 5306,
serialNumber: '5306ShiftStartTime',
tableId: "5306Shift",
tableName: "派工单材料", tableName: "派工单材料",
columnProp: "partNo",
columnProp: "startTime",
headerAlign: "center", headerAlign: "center",
align: "center", align: "center",
columnLabel: "零部件编码",
columnLabel: "上班时间",
columnWidth: 100, columnWidth: 100,
columnHidden: false, columnHidden: false,
columnImage: false, columnImage: false,
@ -168,32 +141,14 @@ export default {
}, },
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialStartDate',
tableId: "5305Material",
functionId: 5306,
serialNumber: '5306ShiftEndTime',
tableId: "5306Shift",
tableName: "派工单材料", tableName: "派工单材料",
columnProp: "startDate",
columnProp: "endTime",
headerAlign: "center", headerAlign: "center",
align: "center", align: "center",
columnLabel: "开始使用时间",
columnWidth: 125,
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: false
},
{
userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialTransQty',
tableId: "5305Material",
tableName: "派工单材料",
columnProp: "transQty",
headerAlign: "center",
align: "right",
columnLabel: "数量",
columnLabel: "下班时间",
columnWidth: 80, columnWidth: 80,
columnHidden: false, columnHidden: false,
columnImage: false, columnImage: false,
@ -204,32 +159,14 @@ export default {
}, },
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialNetIssueQty',
tableId: "5305Material",
functionId: 5306,
serialNumber: '5306ShiftNextDayFlag',
tableId: "5306Shift",
tableName: "派工单材料", tableName: "派工单材料",
columnProp: "netIssueQty",
columnProp: "nextDayFlag",
headerAlign: "center", headerAlign: "center",
align: "right", align: "right",
columnLabel: "本卷调机数量",
columnWidth: 100,
columnHidden: true,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: false
},
{
userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialKeyRMFlag',
tableId: "5305Material",
tableName: "派工单材料",
columnProp: "keyRMFlag",
headerAlign: "center",
align: "center",
columnLabel: "是否主材",
columnLabel: "次日",
columnWidth: 80, columnWidth: 80,
columnHidden: false, columnHidden: false,
columnImage: false, columnImage: false,
@ -237,24 +174,6 @@ export default {
sortLv: 0, sortLv: 0,
status: true, status: true,
fixed: false fixed: false
},
{
userId: this.$store.state.user.name,
functionId: 5305,
serialNumber: '5305MaterialSAPBOMItemNo',
tableId: "5305Material",
tableName: "派工单材料",
columnProp: "sAPBOMItemNo",
headerAlign: "center",
align: "center",
columnLabel: "SAP BOM序号",
columnWidth: 100,
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: false
} }
], ],
dataListLoading: false, dataListLoading: false,
@ -262,20 +181,9 @@ export default {
}, },
methods: { methods: {
/*初始化页面参数*/ /*初始化页面参数*/
init(pageData, operatorData) {
init(pageData) {
// //
this.pageData.orderNo = pageData.orderNo;
this.pageData.itemNo = pageData.itemNo;
this.pageData.seqNo = pageData.seqNo;
this.pageData.rollNo = pageData.rollNo;
this.pageData.operatorId = operatorData.operatorId;
//
this.pageData.reportDate = this.dayjs(new Date()).format('YYYY-MM-DD');
this.pageData.reportTime = this.dayjs(new Date()).format('HH:mm:ss');
//
this.operatorData = JSON.parse(JSON.stringify(operatorData));
//
this.titleCon = '卷调机-卷材料结算';
this.pageData = JSON.parse(JSON.stringify(pageData));
// //
this.refreshPageData(); this.refreshPageData();
}, },
@ -287,67 +195,31 @@ export default {
/*刷新当前的页面参数*/ /*刷新当前的页面参数*/
refreshPageData(){ refreshPageData(){
//
this.refreshSfdcMaterialTable();
},
//
refreshSfdcMaterialTable(){
getSfdcMaterialByRollNo(this.pageData).then(({data}) => {
this.sfdcMaterialList = data.rows;
});
//
this.refreshScheduleShiftTable();
}, },
//
endTuningAndStartProduceOperation(){
let requestData = {'pageData': JSON.stringify(this.pageData), 'materialList': JSON.stringify(this.sfdcMaterialList)};
endTuningAndStartProduce(requestData).then(({data}) => {
//
if(data.code == 500){
this.$message.error(data.msg);
}else{
//dialog
this.$emit('closeDialog');
//
this.closeDialog();
}
//
refreshScheduleShiftTable(){
getScheduleShiftWithSelect(this.pageData).then(({data}) => {
this.scheduleShiftList = data.rows;
}); });
}, },
/*检查数据是否有效*/
checkValidQty(row){
//
if(row.netIssueQty == ''){
this.$message.error('材料上本卷耗用数量不能为空!');
row.netIssueQty = 0;//
return false;
}
//
if(row.netIssueQty <= 0){
this.$message.error('材料上本卷耗用数量必须大于0!');
return false;
}
//
if(row.netIssueQty > row.transQty){
this.$message.error('材料上本卷耗用数量大于发料数量!');
row.netIssueQty = 0;//
return false;
}
/*设置当前选择的班次信息*/
setCurrentShiftRow(row, column, event){
this.currentShiftRow = JSON.parse(JSON.stringify(row));
}, },
/*添加定制的css类*/
customerCellClassName({row, column, rowIndex, columnIndex}) {
if(column.property == 'netIssueQty'){
return 'customer-number-cell';
}
//
updateScheduleAndShift(){
//
this.$emit("initScheduleShift", this.currentShiftRow.scheduleDate,
this.currentShiftRow.shiftNo, this.pageData.username);
//
this.closeDialog();
}, },
/*添加定制的cess样式*/
customerCellStyle({row, column, rowIndex, columnIndex}) {
if(column.property == 'netIssueQty'){
return 'padding: 0px 0px;';
}
}
}, },
created() { created() {

65
src/views/modules/yieldReport/not_over_finish_roll.vue

@ -8,7 +8,7 @@
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">
<fieldset class="customer-fieldset" <fieldset class="customer-fieldset"
style="margin-left: 3px; margin-top: -10px; ;width: 550px;">
style="margin-left: 3px; margin-top: -10px; ;width: 560px;">
<legend>人员排程班次信息</legend> <legend>人员排程班次信息</legend>
<el-form-item class="customer-item" :label="'当前时间'"> <el-form-item class="customer-item" :label="'当前时间'">
<el-date-picker disabled="disabled" style="width: 145px;" <el-date-picker disabled="disabled" style="width: 145px;"
@ -30,10 +30,14 @@
<el-form-item class="customer-item" label="班次:"> <el-form-item class="customer-item" label="班次:">
<el-input v-model="pageData.shiftDesc" class="customer-input-color-red" readonly="readonly" style="width: 80px;"></el-input> <el-input v-model="pageData.shiftDesc" class="customer-input-color-red" readonly="readonly" style="width: 80px;"></el-input>
</el-form-item> </el-form-item>
<el-button type="info" :disabled="buttonTags.selectShiftFlag" plain @click="selectSchduleShiftModal"
style="margin-left: -10px; margin-top: 10px; height: 20px; padding: 3px 3px;">
<icon-svg name="ellipsis" style="height: 10px; width: 10px;" ></icon-svg>
</el-button>
</fieldset> </fieldset>
<el-form style="margin-top: -60px;margin-left: 560px">
<el-form style="margin-top: -60px;margin-left: 570px">
<el-form-item class="customer-button"> <el-form-item class="customer-button">
<el-button class="customer-bun-min" type="primary" :disabled="buttonTags.createRollFlag" style="margin-left: 10px; margin-bottom: 5px;">
<el-button class="customer-bun-min" type="primary" style="margin-left: 10px; margin-bottom: 5px;">
列表</el-button> 列表</el-button>
</el-form-item> </el-form-item>
<el-form-item class="customer-button"> <el-form-item class="customer-button">
@ -228,8 +232,13 @@
<comExceptionReason ref="comExceptionReason" :close-on-click-modal="false" <comExceptionReason ref="comExceptionReason" :close-on-click-modal="false"
:visible.sync="showExceptionFlag" :visible.sync="showExceptionFlag"
@initExceptionReason = "initExceptionReason"> @initExceptionReason = "initExceptionReason">
</comExceptionReason> </comExceptionReason>
<!-- 班次选择组件 -->
<comSelectShift ref="comSelectShift" :close-on-click-modal="false"
:visible.sync="showShiftFlag"
@initScheduleShift = "initScheduleShift">
</comSelectShift>
</div> </div>
</template> </template>
@ -237,7 +246,8 @@
<script> <script>
/*添加组件*/ /*添加组件*/
import comExceptionReason from "./com_exception_reason";// import comExceptionReason from "./com_exception_reason";//
import {
import comSelectShift from "./com_select_shift";//
import {
getCurrentRollReportedQty, getCurrentRollReportedQty,
countSfdcTimeQty, countSfdcTimeQty,
getScheduleShiftData, getScheduleShiftData,
@ -254,6 +264,7 @@ export default {
return { return {
titleCon: '结束卷', titleCon: '结束卷',
showExceptionFlag: false, showExceptionFlag: false,
showShiftFlag: false,
showNumFlag: false, showNumFlag: false,
sfdcTimeList: [], sfdcTimeList: [],
scheduleData: { scheduleData: {
@ -501,23 +512,14 @@ export default {
} }
], ],
buttonTags:{ buttonTags:{
createNewRollFlag: true,
switchRollFlag: true,
separatorRollFlag: true,
finishRollFlag: true,
mergeRollFlag: true,
tuningFlag: true,
produceFlag: true,
defectFlag: true,
toolFlag: true,
materialFlag: true,
downTimeFlag: true
selectShiftFlag: true,
}, },
dataListLoading: false, dataListLoading: false,
} }
}, },
components: { components: {
comExceptionReason,/*异常原因的组件*/ comExceptionReason,/*异常原因的组件*/
comSelectShift,/*班次选择的组件*/
}, },
methods: { methods: {
sORoutingPreviousOperationItemNo(){ sORoutingPreviousOperationItemNo(){
@ -616,6 +618,7 @@ export default {
}); });
//3. //3.
await getScheduleShiftData(this.scheduleData).then(({data}) => { await getScheduleShiftData(this.scheduleData).then(({data}) => {
let specialAuth = 'N';
// //
if(data.code == 500){ if(data.code == 500){
this.pageData.shiftDesc = data.row.shiftDesc;// this.pageData.shiftDesc = data.row.shiftDesc;//
@ -625,6 +628,14 @@ export default {
this.pageData.shiftDesc = data.row.shiftDesc;// this.pageData.shiftDesc = data.row.shiftDesc;//
this.pageData.scheduledDate = data.row.scheduledDate.substring(0, 10);// this.pageData.scheduledDate = data.row.scheduledDate.substring(0, 10);//
this.pageData.shiftNo = data.row.shiftNo; this.pageData.shiftNo = data.row.shiftNo;
//
specialAuth = data.row.specialAuth;
}
//
if("Y" === specialAuth){
this.buttonTags.selectShiftFlag = false;
}else{
this.buttonTags.selectShiftFlag = true;
} }
}); });
//4. //4.
@ -869,7 +880,27 @@ export default {
this.pageData.exceptionReason = exceptionReason; this.pageData.exceptionReason = exceptionReason;
// //
this.finishRollOperation(); this.finishRollOperation();
}
},
/*打开班次选择页面*/
selectSchduleShiftModal(){
//1.
//checkProduceButton('produceMaterialFlag');
//
this.$nextTick(() => {
this.showShiftFlag = true;
this.$refs.comSelectShift.init(this.pageData);
});
},
/*修改页面的班次和排产的时间*/
initScheduleShift(scheduleDate, shiftDesc, username){
//
this.pageData.scheduledDate = scheduleDate.substring(0, 10);
this.pageData.shiftDesc = shiftDesc;
this.pageData.remark = username+"更改了班次."
},
}, },
created() { created() {
// this.factoryList() // this.factoryList()

65
src/views/modules/yieldReport/otherReport/bulk_inspection.vue

@ -1,4 +1,5 @@
<template> <template>
<div class="">
<el-dialog <el-dialog
v-drag v-drag
@close="closeDialog" @close="closeDialog"
@ -32,6 +33,10 @@
<el-input style="width: 120px" v-model="shift" readonly> <el-input style="width: 120px" v-model="shift" readonly>
</el-input> </el-input>
</el-form-item> </el-form-item>
<el-button type="info" :disabled="buttonTags.selectShiftFlag" plain @click="selectSchduleShiftModal"
style="margin-left: -10px; margin-top: 20px; height: 20px; padding: 3px 3px;">
<icon-svg name="ellipsis" style="height: 10px; width: 10px;" ></icon-svg>
</el-button>
<el-form-item> <el-form-item>
<!-- <el-button type="primary" style="margin-top: 24px">查询</el-button>--> <!-- <el-button type="primary" style="margin-top: 24px">查询</el-button>-->
</el-form-item> </el-form-item>
@ -71,16 +76,25 @@
<el-button @click="visible = false" type="primary">关闭</el-button> <el-button @click="visible = false" type="primary">关闭</el-button>
</span> </span>
</el-dialog> </el-dialog>
<!-- 班次选择组件 -->
<comSelectShift ref="comSelectShift" :close-on-click-modal="false"
:visible.sync="showShiftFlag"
@initScheduleShift = "initScheduleShift">
</comSelectShift>
</div>
</template> </template>
<script> <script>
/*组件*/
import comSelectShift from "../com_select_shift";//
import { import {
searchFqcSfdcRolls, searchFqcSfdcRolls,
getScheduleDateShift, getScheduleDateShift,
workbenchPostinspection
workbenchPostinspection,
getScheduleShiftData,/*LR 新增查询班次的方法*/
} from "@/api/yieldReport/produce_report_normal.js"; } from "@/api/yieldReport/produce_report_normal.js";
export default { export default {
data() { data() {
return { return {
@ -88,6 +102,7 @@ export default {
repairOrderFlag: '', repairOrderFlag: '',
shift: '', shift: '',
visible: false, visible: false,
showShiftFlag: false,
operatorId: '', operatorId: '',
dataList: [], dataList: [],
site: this.$store.state.user.site, site: this.$store.state.user.site,
@ -108,6 +123,9 @@ export default {
currentDateTime: '' currentDateTime: ''
}, },
dataListLoading: false, dataListLoading: false,
buttonTags:{
selectShiftFlag: true,
},
languageColumnList: [ languageColumnList: [
{ {
userId: this.$store.state.user.name, userId: this.$store.state.user.name,
@ -129,6 +147,9 @@ export default {
], ],
} }
}, },
components: {
comSelectShift,/*班次选择的组件*/
},
mounted() { mounted() {
}, },
@ -147,8 +168,10 @@ export default {
this.scheduleDateShiftDto.site = val.site this.scheduleDateShiftDto.site = val.site
this.operatorId = val.operatorId this.operatorId = val.operatorId
this.scheduleDateShiftDto.resourceId = val.resourceId this.scheduleDateShiftDto.resourceId = val.resourceId
this.scheduleDateShiftDto.currentDateTime = this.dayjs().format("YYYY-MM-DD hh:mm:ss")
this.searchScheduleDateShift()
this.scheduleDateShiftDto.currentDateTime = this.dayjs().format("YYYY-MM-DD HH:mm:ss")
this.searchScheduleDateShift();
//
this.searchScheduleShiftData();
}, },
// //
getDataList() { getDataList() {
@ -207,7 +230,41 @@ export default {
}, },
closeDialog() { closeDialog() {
Object.assign(this.$data.sfdcRolls, this.$options.data.call(this).sfdcRolls); Object.assign(this.$data.sfdcRolls, this.$options.data.call(this).sfdcRolls);
},
searchScheduleShiftData(){
let requestData = {'site': this.site, 'username': this.reportedBy};
getScheduleShiftData(requestData).then(({data}) => {
let specialAuth = data.row.specialAuth;
//
if("Y" === specialAuth){
this.buttonTags.selectShiftFlag = false;
}else{
this.buttonTags.selectShiftFlag = true;
} }
});
},
/*打开班次选择页面*/
selectSchduleShiftModal(){
//1.
//checkProduceButton('produceMaterialFlag');
//
let requestData = {'site': this.site, 'username': this.reportedBy, 'resourceId': this.sfdcRolls.resourceId,
'reportedTime': this.scheduleDateShiftDto.currentDateTime, 'scheduledDate': this.scheduleDateShiftDto.currentDateTime.substring(0, 10)};
//
this.$nextTick(() => {
this.showShiftFlag = true;
this.$refs.comSelectShift.init(requestData);
});
},
/*修改页面的班次和排产的时间*/
initScheduleShift(scheduleDate, shiftDesc, username){
//
this.currentDate = scheduleDate.substring(0, 10);
this.shift = shiftDesc;
},
}, },
created() { created() {

Loading…
Cancel
Save