This commit is contained in:
chenjianan
2019-03-26 13:45:16 +08:00
4 changed files with 47 additions and 48 deletions

View File

@@ -49,14 +49,14 @@ export function getTable(stepNumber, a, b, c, d, e, f, g, i, j, k, l, m, pageCur
}) })
} }
export function getTable2(stepNumber, a, b, c, d, e, g, i) { export function getTable2(stepNumber) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '车间生产管理工艺_零件工序_查询数据_已编制工序的全部零件及工序', name: '车间生产管理工艺_加工进度查询_查询',
param: '项目流水号_check=' + stepNumber + '=string&项目流水号=' + a + '=string&机床流水号_check=' + b + '=string&机床流水号=' + c + '=string&组件流水号_check=' + d + '=string&组件流水号=' + e + '=string&零件图号_check=1=string&零件图号=' + g + '=string&是否查询全部数据=1=string&单件是否外协=' + i + '=string&考核状态=6=int' param: '工艺计划流水号=' + stepNumber
} }
}) })
} }

View File

@@ -47,14 +47,14 @@ export function getTable(stepNumber, a, b, c, d, e, f, g, h, i, j, k, pageCurren
}) })
} }
export function getTable2(stepNumber, a, b, c, d, e, g) { export function getTable2(stepNumber) {
return request({ return request({
url: '', url: '',
method: 'post', method: 'post',
data: { data: {
type: '1', type: '1',
name: '车间生产管理工艺_零件工序_查询数据_已编制工序的全部零件及工序_加工进度修改', name: '车间生产管理工艺_加工进度修改2_查询',
param: '项目流水号_check=' + stepNumber + '=string&项目流水号=' + a + '=string&机床流水号_check=' + b + '=string&机床流水号=' + c + '=string&组件流水号_check=' + d + '=string&组件流水号=' + e + '=string&零件图号_check=1=string&零件图号=' + g + '=string&是否查询全部数据=1=string&单件是否外协=0' param: '工艺计划流水号=' + stepNumber
} }
}) })
} }

View File

@@ -458,6 +458,7 @@ export default {
} else { } else {
this.endTime_check = 1 this.endTime_check = 1
} }
this.num111 = []
this.tableData1 = [] this.tableData1 = []
this.零件图号 = [] this.零件图号 = []
this.零件名称 = [] this.零件名称 = []
@@ -472,6 +473,7 @@ export default {
getTable(this.checkbox_project, this.project, this.checkbox_Machine, this.Machine, this.checkbox_Group, this.Group, this.checkbox_number, this.number, 1, this.startTime_check, this.startTime, this.endTime_check, this.endTime, this.pageCurrent, this.pageSize).then(response => { getTable(this.checkbox_project, this.project, this.checkbox_Machine, this.Machine, this.checkbox_Group, this.Group, this.checkbox_number, this.number, 1, this.startTime_check, this.startTime, this.endTime_check, this.endTime, this.pageCurrent, this.pageSize).then(response => {
this.length = parseInt(response.data.total) this.length = parseInt(response.data.total)
for (let i = 0; i < response.data.rows.length; i++) { // 声明二维数组 for (let i = 0; i < response.data.rows.length; i++) { // 声明二维数组
this.num111.push(response.data.rows[i].工艺计划流水号)
this.零件图号.push(response.data.rows[i].零件图号) this.零件图号.push(response.data.rows[i].零件图号)
this.零件名称.push(response.data.rows[i].零件名称) this.零件名称.push(response.data.rows[i].零件名称)
this.投产数量.push(response.data.rows[i].投产数量) this.投产数量.push(response.data.rows[i].投产数量)
@@ -484,31 +486,28 @@ export default {
} }
if (this.零件图号.length !== 0) { if (this.零件图号.length !== 0) {
for (let i = 0; i < this.零件图号.length; i++) { for (let i = 0; i < this.零件图号.length; i++) {
getTable2(this.checkbox_project, this.project, this.checkbox_Machine, this.Machine, this.checkbox_Group, this.Group, this.零件图号[i], 1).then(response => { getTable2(this.num111[i]).then(response => {
this.liushuihao = response.data[0].工艺计划流水号
for (let k = 0; k < response.data.length; k++) { for (let k = 0; k < response.data.length; k++) {
if (response.data[k].工艺计划流水号 === this.liushuihao) { this.process[i][k] = response.data[k].工艺名称简称
this.process[i][k] = response.data[k].工艺名称简称 this.planDate[i][k] = response.data[k].计划日期_短
this.planDate[i][k] = response.data[k].计划日期_短 this.realDate[i][k] = response.data[k].完成日期_短
this.realDate[i][k] = response.data[k].完成日期_短 if (response.data[k].工艺编号 === 29) {
if (response.data[k].工艺编号 === 29) { response.data[k].员工姓名 = '备料'
response.data[k].员工姓名 = '备料' }
} if (response.data[k].工序间是否外协 === 2) {
if (response.data[k].工序间是否外协 === 2) { response.data[k].员工姓名 = '外协'
response.data[k].员工姓名 = '外协' }
} if (response.data[k].员工姓名 === '超级管理员') {
if (response.data[k].员工姓名 === '超级管理员') { response.data[k].员工姓名 = '无'
response.data[k].员工姓名 = '无' }
} this.worker[i][k] = response.data[k].员工姓名
this.worker[i][k] = response.data[k].员工姓名 if (response.data[k].工序状态 === 5) { // 灰色是已经完成 未入库
if (response.data[k].工序状态 === 5) { // 灰色是已经完成 未入库 this.colorCode[i][k] = 'grey'
this.colorCode[i][k] = 'grey' } else {
} else { this.colorCode[i][k] = response.data[k].进度颜色
this.colorCode[i][k] = response.data[k].进度颜色 }
} if (response.data[k].工序间是否外协 === 2) {
if (response.data[k].工序间是否外协 === 2) { this.colorCode[i][k] = 'lightblue'
this.colorCode[i][k] = 'lightblue'
}
} }
} }
}).then(() => { }).then(() => {

View File

@@ -372,6 +372,7 @@ import { isMachining, handlechange3, getTable8, getTree, fn, dialogtablevisible,
export default { export default {
data() { data() {
return { return {
num111: [], // 零件图号去掉P后修改
Num2: '', Num2: '',
gongyijihualiushuihao: [[]], gongyijihualiushuihao: [[]],
midd: 0, midd: 0,
@@ -557,6 +558,7 @@ export default {
} else { } else {
this.endTime_check = 1 this.endTime_check = 1
} }
this.num111 = []
this.tableData1 = [] this.tableData1 = []
this.零件图号 = [] this.零件图号 = []
this.零件名称 = [] this.零件名称 = []
@@ -577,6 +579,7 @@ export default {
} else { } else {
this.length = parseInt(response.data.total) this.length = parseInt(response.data.total)
for (let i = 0; i < response.data.rows.length; i++) { // 声明二维数组 for (let i = 0; i < response.data.rows.length; i++) { // 声明二维数组
this.num111.push(response.data.rows[i].工艺计划流水号)
this.零件图号.push(response.data.rows[i].零件图号) this.零件图号.push(response.data.rows[i].零件图号)
this.零件名称.push(response.data.rows[i].零件名称) this.零件名称.push(response.data.rows[i].零件名称)
this.投产数量.push(response.data.rows[i].投产数量) this.投产数量.push(response.data.rows[i].投产数量)
@@ -592,25 +595,22 @@ export default {
} }
if (this.零件图号.length !== 0) { if (this.零件图号.length !== 0) {
for (let i = 0; i < this.零件图号.length; i++) { for (let i = 0; i < this.零件图号.length; i++) {
getTable2(this.checkbox_project, this.project, this.checkbox_Machine, this.Machine, this.checkbox_Group, this.Group, this.零件图号[i]).then(response => { getTable2(this.num111[i]).then(response => {
this.liushuihao = response.data[0].工艺计划流水号
for (let k = 0; k < response.data.length; k++) { for (let k = 0; k < response.data.length; k++) {
if (response.data[k].工艺计划流水号 === this.liushuihao) { this.kaoqinbianhao[i][k] = response.data[k].工作者考勤编号
this.kaoqinbianhao[i][k] = response.data[k].作者考勤编 this.gongxuliushuihao[i][k] = response.data[k].序流水
this.gongxuliushuihao[i][k] = response.data[k].流水号 this.gongyijihualiushuihao[i][k] = response.data[k].艺计划流水号
this.gongyijihualiushuihao[i][k] = response.data[k].工艺计划流水号 this.process[i][k] = response.data[k].工艺名称简称
this.process[i][k] = response.data[k].工艺名称简称 this.planDate[i][k] = response.data[k].计划日期_短
this.planDate[i][k] = response.data[k].计划日期_短 this.worker[i][k] = response.data[k].员工姓名
this.worker[i][k] = response.data[k].员工姓名 this.realDate[i][k] = response.data[k].完成日期_短
this.realDate[i][k] = response.data[k].完成日期_短 if (response.data[k].工序状态 === 5) { // 灰色:停产,不允许修改,重新投产
if (response.data[k].工序状态 === 5) { // 灰色:停产,不允许修改,重新投产 this.colorCode[i][k] = 'grey'
this.colorCode[i][k] = 'grey' } else {
} else { this.colorCode[i][k] = response.data[k].进度颜色
this.colorCode[i][k] = response.data[k].进度颜色 }
} if (response.data[k].工序间是否外协 === 2) {
if (response.data[k].工序间是否外协 === 2) { this.colorCode[i][k] = 'lightblue'
this.colorCode[i][k] = 'lightblue'
}
} }
} }
}).then(() => { }).then(() => {