Browse Source

0412 新看板

master
ruanqi 3 years ago
parent
commit
c33347f1c2
  1. 6
      src/api/production/generateReport.js
  2. 5
      src/assets/scss/rq.scss
  3. 14
      src/views/modules/production/scheduleForSOTask.vue
  4. 31
      src/views/modules/production/scheduleForShopOrder.vue
  5. 252
      src/views/modules/production/transFerPrint.vue
  6. 3
      src/views/modules/sys/menu-add-or-update.vue
  7. 6
      src/views/modules/sys/menu.vue

6
src/api/production/generateReport.js

@ -27,3 +27,9 @@ export const startSeqNo= data => createAPI(`dailyPlan/startSeqNo`, 'post', data)
export const circulationSchedule= data => createAPI(`dailyPlan/circulationSchedule`, 'post', data); export const circulationSchedule= data => createAPI(`dailyPlan/circulationSchedule`, 'post', data);
export const closeSchedule= data => createAPI(`dailyPlan/closeSchedule`, 'post', data); export const closeSchedule= data => createAPI(`dailyPlan/closeSchedule`, 'post', data);
export const searchLastApproveQty= data => createAPI(`dailyPlan/searchLastApproveQty`, 'post', data);
export const transFerSearch= data => createAPI(`dailyPlan/transFerSearch`, 'post', data);
export const getTransPrintData= data => createAPI(`dailyPlan/getTransPrintData`, 'post', data);

5
src/assets/scss/rq.scss

@ -40,3 +40,8 @@
.el-table .cell, .el-table th div, .el-table--border td:first-child .cell, .el-table--border th:first-child .cell { .el-table .cell, .el-table th div, .el-table--border td:first-child .cell, .el-table--border th:first-child .cell {
padding-left: 0px; padding-left: 0px;
} }
.rq .el-table .cell {
line-height: 20px;
font-size: 12px;
height: 20px;
}

14
src/views/modules/production/scheduleForSOTask.vue

@ -269,7 +269,7 @@
<el-button type="primary" @click="saveSchedule()">保存</el-button> <el-button type="primary" @click="saveSchedule()">保存</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="inputTable ">
<div class="rq ">
<el-table <el-table
height="200" height="200"
:data="schedulingModalTableData" :data="schedulingModalTableData"
@ -596,12 +596,12 @@
}) })
return false return false
} }
if(this.schedulingModalData.qtyToSchedule<this.schedulingModalData.sumQty){
this.$alert('实际派工数量大于可派工数量!', '错误', {
confirmButtonText: '确定'
})
return false
}
// if(this.schedulingModalData.qtyToSchedule<this.schedulingModalData.sumQty){
// this.$alert('', '', {
// confirmButtonText: ''
// })
// return false
// }
let flag=false; let flag=false;
for (let i = 0; i <this.schedulingModalTableData.length; i++) { for (let i = 0; i <this.schedulingModalTableData.length; i++) {
if(''==this.schedulingModalTableData[i].scheduleQty||this.schedulingModalTableData[i].scheduleQty==null){ if(''==this.schedulingModalTableData[i].scheduleQty||this.schedulingModalTableData[i].scheduleQty==null){

31
src/views/modules/production/scheduleForShopOrder.vue

@ -253,7 +253,7 @@
label="产出单位"> label="产出单位">
</el-table-column> </el-table-column>
</el-table> </el-table>
<el-dialog title="派工" :close-on-click-modal="false" v-drag :visible.sync="scheduledModalFlag" width="720px">
<el-dialog title="派工" :close-on-click-modal="false" v-drag :visible.sync="scheduledModalFlag" width="850px">
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;"> <el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item label="订单号:"> <el-form-item label="订单号:">
<el-input v-model="schedulingModalData.orderNo" disabled style="width: 120px"></el-input> <el-input v-model="schedulingModalData.orderNo" disabled style="width: 120px"></el-input>
@ -270,6 +270,9 @@
<el-form-item label="待派工数:"> <el-form-item label="待派工数:">
<el-input v-model="schedulingModalData.qtyToSchedule" disabled style="width: 120px"></el-input> <el-input v-model="schedulingModalData.qtyToSchedule" disabled style="width: 120px"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="可派工数:">
<el-input v-model="schedulingModalData.qty1" disabled style="width: 120px"></el-input>
</el-form-item>
</el-form> </el-form>
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;"> <el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item label="产品编码:"> <el-form-item label="产品编码:">
@ -287,6 +290,9 @@
<el-form-item label="加工中心:"> <el-form-item label="加工中心:">
<el-input v-model="schedulingModalData.workCenterNo" disabled style="width: 120px"></el-input> <el-input v-model="schedulingModalData.workCenterNo" disabled style="width: 120px"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="上工序报工数:">
<el-input v-model="schedulingModalData.lastApproveQty" disabled style="width: 120px"></el-input>
</el-form-item>
</el-form> </el-form>
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;"> <el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item label="派工机台:"> <el-form-item label="派工机台:">
@ -323,11 +329,12 @@
<el-button type="primary" @click="saveSchedule()">保存</el-button> <el-button type="primary" @click="saveSchedule()">保存</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="inputTable ">
<div class="rq ">
<el-table <el-table
height="200" height="200"
:data="schedulingModalTableData" :data="schedulingModalTableData"
border border
:row-style="{height: '25px'}"
style="width: 100%"> style="width: 100%">
<el-table-column <el-table-column
prop="scheduleDate" prop="scheduleDate"
@ -431,6 +438,9 @@
getAvailableResourceList, getAvailableResourceList,
scheduleForShopOrder, scheduleForShopOrder,
} from "@/api/production.js" } from "@/api/production.js"
import {
searchLastApproveQty,
} from '@/api/production/generateReport.js'
import Chooselist from '@/views/modules/common/Chooselist' import Chooselist from '@/views/modules/common/Chooselist'
export default { export default {
name: 'searchDailyPlan', name: 'searchDailyPlan',
@ -501,6 +511,8 @@
sumQty: '', sumQty: '',
operatorId:'', operatorId:'',
efficiency:'', efficiency:'',
qty1:'',
lastApproveQty:'',
}, },
scheduledModalFlag: false, scheduledModalFlag: false,
availableResourceList: [], availableResourceList: [],
@ -585,10 +597,23 @@
shiftNo: '', shiftNo: '',
operatorId:'', operatorId:'',
sumQty: 0, sumQty: 0,
lastApproveQty:null,
qty1:'',
} }
this.schedulingModalTableData = [] this.schedulingModalTableData = []
this.getAvailableResourceList(row) this.getAvailableResourceList(row)
this.getWorkCenterOperatorList(row); this.getWorkCenterOperatorList(row);
let inData={
site:row.site,
orderNo:row.orderNo,
itemNo:row.itemNo,
}
searchLastApproveQty(inData).then(({data}) => {
if(data.code===0&&data.row.lastApproveQty!=null) {
this.schedulingModalData.lastApproveQty = data.row.lastApproveQty;
this.schedulingModalData.qty1 = data.row.lastApproveQty-row.scheduledQty;
}
})
this.scheduledModalFlag = true this.scheduledModalFlag = true
}, },
addPlans () { addPlans () {
@ -656,7 +681,7 @@
}) })
return false return false
} }
if(this.schedulingModalData.qtyToSchedule<this.schedulingModalData.sumQty){
if(this.schedulingModalData.qty1<this.schedulingModalData.sumQty&&this.schedulingModalData.lastApproveQty!=null){
this.$alert('实际派工数量大于可派工数量!', '错误', { this.$alert('实际派工数量大于可派工数量!', '错误', {
confirmButtonText: '确定' confirmButtonText: '确定'
}) })

252
src/views/modules/production/transFerPrint.vue

@ -0,0 +1,252 @@
<template>
<div class="mod-config">
<el-form :inline="true" label-position="top" label-width="100px" >
<el-form-item :label="'报工日期:'">
<el-date-picker
style="width: 130px"
v-model="searchData.startDate"
value-format="yyyy-MM-dd"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
<el-form-item :label="'至: '">
<el-date-picker
style="width: 130px"
v-model="searchData.endDate"
type="date"
value-format="yyyy-MM-dd"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
<el-form-item >
<span slot="label" style="" @click="getBaseList(5)"><a herf="#">物料编码</a></span>
<el-input v-model="searchData.partNo" style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="'生产订单号:'">
<el-input v-model="searchData.orderNo" style="width: 120px"></el-input>
</el-form-item>
<el-form-item :label="' '">
<el-button @click="search()" style="margin-left: 0px;margin-top:0px" type="primary">查询</el-button>
</el-form-item>
</el-form>
<el-table
:height="height"
:data="tableData"
border
style="width: 100%">
<el-table-column
prop=""
header-align="center"
align="center"
min-width="60"
label="操作">
<template slot-scope="scope" class="foo_container">
<a type="text" size="small" @click="printStock(scope.row)">打印标签</a>
</template>
</el-table-column>
<el-table-column
prop="transNo"
header-align="center"
align="left"
min-width="80"
style="font-size: 20px"
label="入库通知单号">
</el-table-column>
<el-table-column
prop="orderNo"
header-align="center"
align="left"
min-width="65"
style="font-size: 20px"
label="生产订单号">
</el-table-column>
<el-table-column
prop="site"
header-align="center"
align="left"
min-width="65"
style="font-size: 20px"
label="工厂编号">
</el-table-column>
<el-table-column
prop="transDate"
header-align="center"
align="left"
min-width="105"
label="报工日期">
</el-table-column>
<el-table-column
prop="partNo"
header-align="center"
align="left"
min-width="105"
label="产品编号">
</el-table-column>
<el-table-column
prop="partDesc"
header-align="center"
align="left"
min-width="180"
label="产品名称">
</el-table-column>
<el-table-column
prop="transQty"
header-align="center"
align="right"
min-width="60"
label="通知单数量">
</el-table-column>
<el-table-column
prop="seqNo"
header-align="center"
align="right"
min-width="45"
label="派工单号">
</el-table-column>
</el-table>
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist>
</div>
</template>
<script>
import {
transFerSearch,
getTransPrintData
} from '@/api/production/generateReport.js'
import Chooselist from '@/views/modules/common/Chooselist'
import {
printTransNoLabel,
} from "@/views/modules/production/print_transNo_label.js"
export default {
name: 'soscheduleRouting',
components: {
Chooselist
},
data () {
return {
site: this.$store.state.user.site,
operatorType: 0,
height: 200,
tableData: [],
date1: '',
searchData: {
orderNo: '',
partNo: '',
site: this.$store.state.user.site,
startDate:new Date(),
endDate:'',
seqNo:'',
},
photoUrl:'',
sopData:{
site:'',
partNo:'',
},
partDescription:'',
fileTitle:'',
fileName:'',
num:1,
currentData:'',
photoDatas:[],
uploadImg:[],
showviewer: false,
url: '',
height2:600,
}
},
mounted () {
this.$nextTick(() => {
this.height = window.innerHeight - 210
this.height2 = window.innerHeight -100
})
},
methods: {
// S
getBaseList (val,type) {
this.tagNo = val
this.$nextTick(() => {
let strVal = ''
if (val === 5) {
strVal = this.searchData.partNo
}
this.$refs.baseList.init(val, strVal)
})
},
/* 列表方法的回调 */
getBaseData (val) {
if (this.tagNo === 5) {
this.searchData.partNo = val.PartNo
}
},
search () {
transFerSearch(this.searchData).then(({data}) => {
this.tableData = data.rows
})
},
createExportData () {
return this.tableData
},
startDownload () {
// this.exportData = this.dataList
},
finishDownload () {
},
getStrDate () {
let dd = new Date()
let Y = dd.getFullYear()
let M = (dd.getMonth() + 1) < 10 ? '0' + (dd.getMonth() + 1) : (dd.getMonth() + 1)// 100
let D = dd.getDate() < 10 ? '0' + dd.getDate() : dd.getDate()// 100
let H = dd.getHours() < 10 ? '0' + dd.getHours() : dd.getHours()
let MM = dd.getMinutes() < 10 ? '0' + dd.getMinutes() : dd.getMinutes()
let S = dd.getSeconds() < 10 ? '0' + dd.getSeconds() : dd.getSeconds()
return Y + M + D + H + MM + S
},
printStock(row){
let inData={
transNo:row.transNo,
site:row.site
}
getTransPrintData(inData).then(({data}) => {
if (data.code == 0) {
let inList=[];
inList.push(data.row)
printTransNoLabel(inList);
} else {
this.$alert(data.msg, '错误', {
confirmButtonText: '确定'
})
}
})
},
},
created () {
}
}
</script>
<style scoped>
.input_left{
text-align: left;
}
.input_reight{
text-align: right;
}
/deep/ input::-webkit-inner-spin-button {
-webkit-appearance: none !important;
}
input[type='number'] {
-moz-appearance: textfield !important;
}
</style>

3
src/views/modules/sys/menu-add-or-update.vue

@ -4,6 +4,7 @@
width="465px" width="465px"
:title="!dataForm.id ? '新增' : '修改'" :title="!dataForm.id ? '新增' : '修改'"
:close-on-click-modal="false" :close-on-click-modal="false"
v-drag
:visible.sync="visible"> :visible.sync="visible">
<el-form :model="dataForm" :rules="dataRule" ref="dataForm" @keyup.enter.native="dataFormSubmit()" label-width="80px"> <el-form :model="dataForm" :rules="dataRule" ref="dataForm" @keyup.enter.native="dataFormSubmit()" label-width="80px">
<el-form-item label="类型" prop="type"> <el-form-item label="类型" prop="type">
@ -12,7 +13,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
<el-form-item :label="dataForm.typeList[dataForm.type] + '编号'" prop="menuId"> <el-form-item :label="dataForm.typeList[dataForm.type] + '编号'" prop="menuId">
<el-input :readonly="dataForm.id?true:false" style="width: 349px;" v-model="dataForm.menuId" :placeholder="dataForm.typeList[dataForm.type] + '编号'"></el-input>
<el-input readonly style="width: 349px;" v-model="dataForm.menuId" :placeholder="dataForm.typeList[dataForm.type] + '编号'"></el-input>
</el-form-item> </el-form-item>
<el-form-item :label="dataForm.typeList[dataForm.type] + '名称'" prop="name"> <el-form-item :label="dataForm.typeList[dataForm.type] + '名称'" prop="name">
<el-input style="width: 349px;" v-model="dataForm.name" :placeholder="dataForm.typeList[dataForm.type] + '名称'"></el-input> <el-input style="width: 349px;" v-model="dataForm.name" :placeholder="dataForm.typeList[dataForm.type] + '名称'"></el-input>

6
src/views/modules/sys/menu.vue

@ -18,11 +18,11 @@
label="名称" > label="名称" >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="parentName"
prop="menuType"
header-align="center" header-align="center"
align="center" align="center"
width="120"
label="上级菜单">
width="100"
label="菜单类型">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
header-align="center" header-align="center"

Loading…
Cancel
Save