ruanqi 1 year ago
parent
commit
7725f3567d
  1. 191
      src/views/modules/orderIssure/soIssueNotify/newSoIssueNotify.vue
  2. 120
      src/views/modules/orderIssure/soIssueNotify/searchIssureNotify.vue

191
src/views/modules/orderIssure/soIssueNotify/newSoIssueNotify.vue

@ -52,16 +52,16 @@
<el-input v-model="notifyData.enteredDate" disabled ></el-input>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item :label="'要求发料日期'" >
<el-date-picker
v-model="notifyData.planIssueDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-col>
<!-- <el-col :span="4">-->
<!-- <el-form-item :label="'要求发料日期'" >-->
<!-- <el-date-picker-->
<!-- v-model="notifyData.planIssueDate"-->
<!-- type="date"-->
<!-- value-format="yyyy-MM-dd"-->
<!-- placeholder="选择日期">-->
<!-- </el-date-picker>-->
<!-- </el-form-item>-->
<!-- </el-col>-->
</el-row>
<el-row :gutter="20" v-if="notifyNo!=''">
<el-col :span="24">
@ -105,7 +105,7 @@
width="100"
label="操作">
<template slot-scope="scope">
<a type="text" size="small" @click="enterSOSDetail(scope.row)">选择</a>
<a type="text" size="small" @click="enterSOSDetail(scope.row)">物料</a>
<a type="text" size="small" @click="deleteNotifySOS(scope.row)">删除</a>
</template>
</el-table-column>
@ -145,13 +145,25 @@
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item :label="'操作员'" >
<el-input v-model="seqNoData.operatorId" ></el-input>
<el-form-item :label="'派工日期'" >
<el-date-picker
style="width: 100%"
v-model="seqNoData.startDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="4">
<el-form-item :label="'班次'" >
<el-input v-model="seqNoData.sShiftno" ></el-input>
<el-form-item :label="'到'" >
<el-date-picker
style="width: 100%"
v-model="seqNoData.endDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-col>
</el-row>
@ -199,7 +211,7 @@
<el-button type="primary" @click="seqNoModalFlag = false">关闭</el-button>
</el-footer>
</el-dialog>
<el-dialog title="保存派工单" :close-on-click-modal="false" v-drag :visible.sync="saveSeqNoModalFlag" width="800px">
<el-dialog title="保存派工单" :close-on-click-modal="false" v-drag :visible.sync="saveSeqNoModalFlag" width="750px">
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-row :gutter="20">
<el-col :span="6">
@ -229,14 +241,33 @@
<el-input v-model="notifyOrderData.orderno" disabled ></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-col :span="18">
<el-form-item :label="'物料名称'" >
<el-input v-model="notifyOrderData.seqno" disabled ></el-input>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="6">
<el-form-item :label="'要求发料日期'" >
<el-date-picker
style="width: 165px"
v-model="notifyOrderData.needDate"
type="datetime"
value-format="yyyy-MM-dd HH:mm"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item >
<span slot="label" style="" @click="getBaseList(215)"><a herf="#">库位</a></span>
<el-input v-model="notifyOrderData.locationNo" ></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="'此次领料数量'" >
<el-input v-model="notifyOrderData.issureQty" type="number" ></el-input>
<el-input v-model="notifyOrderData.issureQty" type="number" style="text-align: right" ></el-input>
</el-form-item>
</el-col>
</el-row>
@ -252,12 +283,12 @@
<el-row :gutter="20">
<el-col :span="6">
<el-form-item :label="'生产订单'" >
<el-input v-model="sobomData.orderno" ></el-input>
<el-input v-model="sobomData.orderno" readonly ></el-input>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item :label="'派工单号'" >
<el-input v-model="sobomData.seqno" ></el-input>
<el-input v-model="sobomData.seqno" readonly ></el-input>
</el-form-item>
</el-col>
</el-row>
@ -295,11 +326,11 @@
</div>
<el-footer style="height:40px;margin-top: 10px;text-align:center">
<el-button type="primary" @click="saveMaterialDetail()">保存</el-button>
<el-button type="primary" @click="ToSOS()">重新选择派工单</el-button>
<!-- <el-button type="primary" @click="ToSOS()">重新选择派工单</el-button>-->
<el-button type="primary" @click="materialModalFlag=false">关闭</el-button>
</el-footer>
</el-dialog>
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist>
</div>
</template>
@ -326,20 +357,18 @@
xiadaNotify,
}from "@/api/orderIssure/soIssueNotify.js"
import Chooselist from '@/views/modules/common/Chooselist_eam'
export default {
components: {
Chooselist
},
watch: {
searchData: {
notifyOrderData: {
deep: true,
handler: function (newV, oldV) {
this.searchData.groupID = this.searchData.groupID.toUpperCase()
this.notifyOrderData.locationNo = this.notifyOrderData.locationNo.toUpperCase()
}
},
modalData: {
deep: true,
handler: function (newV, oldV) {
this.modalData.groupID = this.modalData.groupID.toUpperCase()
}
}
},
data () {
return {
@ -386,6 +415,8 @@
qtyrequired:'',
sResourceid:'',
issureQty:'',
locationNo:'',
needDate:'',
},
seqNoData:{
site: this.$store.state.user.site,
@ -395,6 +426,8 @@
sWorkcenterno:'',
operatorId:'',
sShiftno:'',
startDate:'',
endDate:'',
},
seqNoList:[],
height: 200,
@ -502,7 +535,7 @@
columnProp: 'itemDesc',
headerAlign: "center",
align: "left",
columnLabel: '在用',
columnLabel: '工序名称',
columnHidden: false,
columnImage: false,
columnSortable: false,
@ -511,6 +544,44 @@
fixed: '',
columnWidth: 100,
},
{
userId: this.$store.state.user.name,
functionId: 701001002,
serialNumber: '701001002Table1LocationNo',
tableId: "701001002Table1",
tableName: "领料申请派工单子表",
columnProp: 'locationNo',
headerAlign: "center",
align: "left",
columnLabel: '库位编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
},
{
userId: this.$store.state.user.name,
functionId: 701001002,
serialNumber: '701001002Table1NeedDate',
tableId: "701001002Table1",
tableName: "领料申请派工单子表",
columnProp: 'needDate',
headerAlign: "center",
align: "left",
columnLabel: '要求发料时间',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
},
{
userId: this.$store.state.user.name,
functionId: 701001002,
@ -784,7 +855,7 @@
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
columnWidth: 50,
},
{
userId: this.$store.state.user.name,
@ -802,7 +873,7 @@
sortLv: 0,
status: true,
fixed: '',
columnWidth: 120,
columnWidth: 220,
},
{
userId: this.$store.state.user.name,
@ -820,7 +891,7 @@
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
columnWidth: 50,
},
{
userId: this.$store.state.user.name,
@ -838,7 +909,7 @@
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
columnWidth: 50,
},
{
userId: this.$store.state.user.name,
@ -856,7 +927,7 @@
sortLv: 0,
status: true,
fixed: '',
columnWidth: 100,
columnWidth: 60,
},
],
rules:{
@ -922,6 +993,27 @@
},
methods: {
getBaseList (val,type) {
this.tagNo = val
this.$nextTick(() => {
let strVal = ''
if (val === 215) {
strVal = this.notifyOrderData.locationNo
this.$refs.baseList.init(val, strVal)
}
})
},
//
getBaseData (val) {
if (this.tagNo === 215) {
this.notifyOrderData.locationNo = val.location_id
}
},
getUserNotifyNo(){
let inData={
site:this.$store.state.user.site,
@ -996,9 +1088,19 @@
this.notifyOrderData.qtyrequired=row.qtyrequired
this.notifyOrderData.sResourceid=row.sResourceid
this.notifyOrderData.issureQty=''
this.notifyOrderData.needDate=this.dayjs().format("YYYY-MM-DD hh:mm")
this.notifyOrderData.locationNo='';
this.saveSeqNoModalFlag=true
},
saveSOS(){
if(this.notifyOrderData.needDate==null||this.notifyOrderData.needDate==''){
this.$message.warning('请选择时间!')
return false
}
if(this.notifyOrderData.locationNo==null||this.notifyOrderData.locationNo==''){
this.$message.warning('请输入库位!')
return false
}
if(this.notifyOrderData.issureQty==null||this.notifyOrderData.issureQty==''||this.notifyOrderData.issureQty<=0){
this.$message.warning('请填写领取数量!')
return false
@ -1030,6 +1132,8 @@
sOOrderNo:row.orderno,
opsItemNo:row.itemno,
seqNo:row.seqno,
locationNo:row.locationNo,
needDate:row.needDate,
issureQty:row.issureQty,
outWorkOrderFlag:'N',
}
@ -1095,6 +1199,8 @@
sWorkcenterno:'',
operatorId:'',
sShiftno:'',
startDate: this.dayjs().format('YYYY-MM-DD'),
endDate: this.dayjs().format('YYYY-MM-DD'),
}
this.searchSOSRouting()
this.seqNoModalFlag=true;
@ -1122,6 +1228,7 @@
saveMaterialDetail(materialList).then(({data})=>{
if (data.code === 0) {
this.materialModalFlag=false
this.chooseSOSModal();
this.$message.success( '操作成功')
}else {
this.$alert(data.msg, '错误', {
@ -1233,12 +1340,12 @@
})
return false
}
if(this.notifyData.planIssueDate==null||this.notifyData.planIssueDate==''){
this.$alert('请选择要求发料日期!!', '提示', {
confirmButtonText: '确定'
})
return false
}
// if(this.notifyData.planIssueDate==null||this.notifyData.planIssueDate==''){
// this.$alert('!', '', {
// confirmButtonText: ''
// })
// return false
// }
xiadaNotify(this.notifyData).then(({data})=>{
if (data.code === 0) {
this.getUserNotifyNo()

120
src/views/modules/orderIssure/soIssueNotify/searchIssureNotify.vue

@ -250,7 +250,7 @@
columnProp: "notifyNo",
headerAlign: "center",
align: "center",
columnLabel: "发料单号",
columnLabel: "申请单单号",
columnHidden: false,
columnImage: false,
columnSortable: false,
@ -343,40 +343,40 @@
status: true,
fixed: '',
columnWidth: 120
},{
userId: this.$store.state.user.name,
functionId: 701002,
serialNumber: '701002Table1PlanIssueDate',
tableId: "701002Table1",
tableName: "领料申请主表",
columnProp: "planIssueDate",
headerAlign: "center",
align: "left",
columnLabel: "计划领料日期",
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 100
},{
userId: this.$store.state.user.name,
functionId: 701002,
serialNumber: '701002Table1RealIssueDate',
tableId: "701002Table1",
tableName: "领料申请主表",
columnProp: "realIssueDate",
headerAlign: "center",
align: "left",
columnLabel: "实际领料日期",
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 100
// },{
// userId: this.$store.state.user.name,
// functionId: 701002,
// serialNumber: '701002Table1PlanIssueDate',
// tableId: "701002Table1",
// tableName: "",
// columnProp: "planIssueDate",
// headerAlign: "center",
// align: "left",
// columnLabel: "",
// columnHidden: false,
// columnImage: false,
// columnSortable: false,
// sortLv: 0,
// status: true,
// fixed: '',
// columnWidth: 100
// },{
// userId: this.$store.state.user.name,
// functionId: 701002,
// serialNumber: '701002Table1RealIssueDate',
// tableId: "701002Table1",
// tableName: "",
// columnProp: "realIssueDate",
// headerAlign: "center",
// align: "left",
// columnLabel: "",
// columnHidden: false,
// columnImage: false,
// columnSortable: false,
// sortLv: 0,
// status: true,
// fixed: '',
// columnWidth: 100
},{
userId: this.$store.state.user.name,
functionId: 701002,
@ -533,7 +533,46 @@
status: true,
fixed: '',
columnWidth: 120
}, {
},
{
userId: this.$store.state.user.name,
functionId: 701002,
serialNumber: '701002Table2LocationNo',
tableId: "701002Table2",
tableName: "领料申请派工单子表",
columnProp: 'locationNo',
headerAlign: "center",
align: "left",
columnLabel: '库位编码',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
},
{
userId: this.$store.state.user.name,
functionId: 701002,
serialNumber: '701002Table2NeedDate',
tableId: "701002Table2",
tableName: "领料申请派工单子表",
columnProp: 'needDate',
headerAlign: "center",
align: "left",
columnLabel: '要求发料时间',
columnHidden: false,
columnImage: false,
columnSortable: false,
sortLv: 0,
status: true,
fixed: '',
columnWidth: 80,
},
{
userId: this.$store.state.user.name,
functionId: 701002,
serialNumber: '701002Table2IssureQty',
@ -792,6 +831,15 @@
})
},
// watch: {
// searchData: {
// deep: true,
// handler: function (newV, oldV) {
// this.searchData.partNo = this.searchData.partNo.toUpperCase()
// }
// },
// },
methods: {
// S
getBaseList (val, type) {

Loading…
Cancel
Save