Browse Source

plm字段权限

master
ruanqi 2 years ago
parent
commit
535612eaa6
  1. 18
      src/api/sampleManagement/technicalSpecificationList.js
  2. 5
      src/assets/scss/rq.scss
  3. 421
      src/views/modules/sampleManagement/technicalSpecificationDetail/com_bm_inkFormulation.vue
  4. 20
      src/views/modules/sampleManagement/technicalSpecificationDetail/com_bm_inkMixing.vue
  5. 436
      src/views/modules/sampleManagement/technicalSpecificationDetail/com_bm_lamination.vue
  6. 26
      src/views/modules/sampleManagement/technicalSpecificationDetail/technicalSpecificationDetail.vue

18
src/api/sampleManagement/technicalSpecificationList.js

@ -50,3 +50,21 @@ export const saveBMPrintOtherColor= data => createAPI(`/technicalSpecification/s
export const deleteBMPrintOtherColor= data => createAPI(`/technicalSpecification/deleteBMPrintOtherColor`,'post',data)
export const searchBMPropertiesHeaderForBM= data => createAPI(`/technicalSpecification/searchBMPropertiesHeaderForBM`,'post',data)
export const searchBMInkMixingDetail= data => createAPI(`/technicalSpecification/searchBMInkMixingDetail`,'post',data)
export const updateBMInkMixingDetail= data => createAPI(`/technicalSpecification/updateBMInkMixingDetail`,'post',data)
export const searchBMInkMixingColor= data => createAPI(`/technicalSpecification/searchBMInkMixingColor`,'post',data)
export const saveBMInkMixingColor= data => createAPI(`/technicalSpecification/saveBMInkMixingColor`,'post',data)
export const deleteBMInkMixingColor= data => createAPI(`/technicalSpecification/deleteBMInkMixingColor`,'post',data)
export const searchBMInkFormulationDetail= data => createAPI(`/technicalSpecification/searchBMInkFormulationDetail`,'post',data)
export const updateBMInkFormulationDetail= data => createAPI(`/technicalSpecification/updateBMInkFormulationDetail`,'post',data)
export const searchBMInkFormulationColor= data => createAPI(`/technicalSpecification/searchBMInkFormulationColor`,'post',data)
export const saveBMInkFormulationColor= data => createAPI(`/technicalSpecification/saveBMInkFormulationColor`,'post',data)
export const deleteBMInkFormulationColor= data => createAPI(`/technicalSpecification/deleteBMInkFormulationColor`,'post',data)
export const searchBMLaminationDetail= data => createAPI(`/technicalSpecification/searchBMLaminationDetail`,'post',data)
export const updateBMLaminationDetail= data => createAPI(`/technicalSpecification/updateBMLaminationDetail`,'post',data)
export const searchBMLaminationCut= data => createAPI(`/technicalSpecification/searchBMLaminationCut`,'post',data)
export const saveBMLaminationCut= data => createAPI(`/technicalSpecification/saveBMLaminationCut`,'post',data)
export const deleteBMLaminationCut= data => createAPI(`/technicalSpecification/deleteBMLaminationCut`,'post',data)

5
src/assets/scss/rq.scss

@ -50,3 +50,8 @@
overflow: hidden;
float: right;
}
//多级标头的颜色
.el-table thead.is-group th {
background: #17B3A3;
}

421
src/views/modules/sampleManagement/technicalSpecificationDetail/com_bm_inkFormulation.vue

@ -0,0 +1,421 @@
<template>
<div class="mod-config">
<el-form label-position="top" style="margin-top: 1px; margin-left: 0px;" v-if="searchData.buNo==='DBE'">
<el-form-item >
<el-button type="primary" @click="colorSearch()" >刷新</el-button>
<el-button type="primary" @click="newColor()" v-if="!ifDisableFlag">新增</el-button>
</el-form-item>
<el-table
height="400"
:data="colorTable"
border
style="width: 100%">
<el-table-column
prop=""
header-align="center"
align="center"
min-width="30"
v-if="!ifDisableFlag"
label="操作">
<template slot-scope="scope">
<a type="text" size="small" @click="updateColor(scope.row)">编辑</a>
<a type="text" size="small" @click="deleteColor(scope.row)">删除</a>
</template>
</el-table-column>
<el-table-column
prop="order"
header-align="center"
align="left"
min-width="40"
label="色序">
</el-table-column>
<el-table-column label="Printing/印刷" header-align="center">
<el-table-column
prop="hardness"
header-align="center"
align="left"
min-width="60"
label="刮胶硬度">
</el-table-column>
<el-table-column
prop="tartness"
header-align="center"
align="left"
min-width="60"
label="刮胶锋利度">
</el-table-column>
<el-table-column
prop="printingSide"
header-align="center"
align="left"
min-width="60"
label="印刷面(正反面)">
</el-table-column>
</el-table-column>
<el-table-column label="UV Dring/UV烘干" header-align="center">
<el-table-column
prop="energy"
header-align="center"
align="left"
min-width="60"
label="能量区间">
</el-table-column>
<el-table-column
prop="drySpeed"
header-align="center"
align="right"
min-width="60"
label="传输带速度">
</el-table-column>
</el-table-column>
<el-table-column label="自然干燥" header-align="center">
<el-table-column
prop="dryTime"
header-align="center"
align="right"
min-width="60"
label="干燥时间(分钟)">
</el-table-column>
</el-table-column>
<el-table-column label="Oven Dring/烘箱干燥" header-align="center">
<el-table-column
prop="dryTemp"
header-align="center"
align="right"
min-width="60"
label="干燥温度(摄氏度)">
</el-table-column>
<el-table-column
prop="dryTime2"
header-align="center"
align="right"
min-width="60"
label="干燥时间(分钟)">
</el-table-column>
</el-table-column>
</el-table>
<el-row :gutter="20">
<el-col :span="24"><div class="grid-content bg-purple">
<el-form-item :label="'备注/Remarks'">
<el-input
type="textarea"
v-model="dataForm.remarks "
:rows="3"
resize='none'
maxlength="120"
show-word-limit
:disabled="ifDisableFlag"
style="height: 60px" >
</el-input>
</el-form-item>
</div></el-col>
</el-row>
<el-row :gutter="20" style="margin-top: 60px">
<el-col :span="6"><div class="grid-content bg-purple">
<el-form-item :label="'标签尺寸/Label Size'">
<el-input v-model="dataForm.labelSize" :disabled="ifDisableFlag" ></el-input>
</el-form-item>
</div></el-col>
<el-col :span="6"><div class="grid-content bg-purple">
<el-form-item :label="'主材/QPA'">
<el-input v-model="dataForm.qpa" :disabled="ifDisableFlag" ></el-input>
</el-form-item>
</div></el-col>
</el-row>
<el-row :gutter="20" style="">
<el-col :span="6"><div class="grid-content bg-purple">
<el-form-item :label="'横排数/No.of Cross'">
<el-input v-model="dataForm.cross" :disabled="ifDisableFlag" type="number" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')"></el-input>
</el-form-item>
</div></el-col>
<el-col :span="6"><div class="grid-content bg-purple">
<el-form-item :label="'横向跳距/HP'">
<el-input v-model="dataForm.hp" :disabled="ifDisableFlag" type="number" ></el-input>
</el-form-item>
</div></el-col>
<el-col :span="6"><div class="grid-content bg-purple">
<el-form-item :label="'纵列数/No.of Row'" >
<el-input v-model="dataForm.row" :disabled="ifDisableFlag" type="number" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')"></el-input>
</el-form-item>
</div></el-col>
<el-col :span="6"><div class="grid-content bg-purple">
<el-form-item :label="'纵向跳距/VP'" >
<el-input v-model="dataForm.vp" :disabled="ifDisableFlag" type="number" ></el-input>
</el-form-item>
</div></el-col>
</el-row>
<el-row :gutter="20" >
<el-col :span="24"><div class="grid-content bg-purple">
<el-form-item :label="'Action'">
<el-input
type="textarea"
v-model="dataForm.action "
:rows="3"
resize='none'
maxlength="120"
show-word-limit
:disabled="ifDisableFlag"
style="height: 60px" >
</el-input>
</el-form-item>
</div></el-col>
</el-row>
</el-form>
<el-form label-position="top" style="margin-top:60px; margin-left: 0px;text-align:center">
<el-button type="primary" @click="saveData()" v-if="searchData.buNo==='DBE'" >保存</el-button>
</el-form>
<el-dialog title="颜色信息" :close-on-click-modal="false" v-drag :visible.sync="colorFlag" width="600px">
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item :label="'色序'">
<el-input v-model="colorData.order" type="number" style="width: 130px" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')" ></el-input>
</el-form-item>
<el-form-item :label="'刮胶硬度'">
<el-input v-model="colorData.hardness" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'刮胶锋利度'">
<el-input v-model="colorData.tartness" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'印刷面(正反面)'">
<el-input v-model="colorData.printingSide" style="width: 130px" ></el-input>
</el-form-item>
</el-form>
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item :label="'能量区间'">
<el-input v-model="colorData.energy" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'传输带速度'">
<el-input v-model="colorData.drySpeed" type="number" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'自然干燥时间(分钟)'">
<el-input v-model="colorData.dryTime" type="number" style="width: 130px" ></el-input>
</el-form-item>
</el-form>
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item :label="'干燥温度(摄氏度)'">
<el-input v-model="colorData.dryTemp" type="number" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'烘箱干燥时间(分钟)'">
<el-input v-model="colorData.dryTime2" type="number" style="width: 130px" ></el-input>
</el-form-item>
</el-form>
<el-footer style="height:40px;margin-top: 10px;text-align:center">
<el-button type="primary" @click="colorSave()">保存</el-button>
<el-button type="primary" @click="colorFlag = false">取消</el-button>
</el-footer>
</el-dialog>
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist>
</div>
</template>
<script>
import {
searchBMInkFormulationDetail,
updateBMInkFormulationDetail,
searchBMInkFormulationColor,
saveBMInkFormulationColor,
deleteBMInkFormulationColor,
} from "@/api/sampleManagement/technicalSpecificationList.js"
import Chooselist from '@/views/modules/common/Chooselist'
export default {
components: {
Chooselist
},
data() {
return {
searchData: {
site: '',
username: this.$store.state.user.name,
codeNo: '',
buNo:'',
},
ifDisableFlag:false,
dataForm:{
site: '',
codeNo:'',
labelSize:'',
qpa:'',
cross:'',
hp:'',
row:'',
VP:'',
action:'',
remarks:'',
},
colorTable:[],
colorData:{
id:'',
site: '',
codeNo:'',
order:'',
hardness:'',
tartness:'',
printingSide:'',
energy:'',
drySpeed:'',
dryTime:'',
dryTemp:'',
dryTime2:'',
updateBy:'',
updateDate:'',
},
colorFlag:false,
}
},
methods: {
// S
getBaseList (val, type) {
this.tagNo = val
this.tagNo1 = type
this.$nextTick(() => {
let strVal = ''
if (val === 1013) {
if(type==1) {
strVal = this.dataForm.partType
}
}
this.$refs.baseList.init(val, strVal)
})
},
/* 列表方法的回调 */
getBaseData (val) {
if (this.tagNo === 1013) {
if(this.tagNo1==1) {
this.dataForm.partType = val.Base_id
this.dataForm.partTypeDesc = val.Base_desc
}
}
},
//
init(inData) {
if(this.dataForm.codeNo!=null&&this.dataForm.codeNo!=''){
return false;
}
//
this.searchData = JSON.parse(JSON.stringify(inData));
//
this.searchTable();
this.colorSearch();
},
searchTable(){
searchBMInkFormulationDetail(this.searchData).then(({data}) => {
if(data.rows.length>0){
this.dataForm = data.rows[0];
}else {
this.dataForm.site=this.searchData.site
this.dataForm.codeNo=this.searchData.codeNo
}
});
},
saveData(){
this.$confirm("是否保存信息?", '保存提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(() => {
updateBMInkFormulationDetail(this.dataForm).then(({data}) => {
if (data && data.code === 0) {
this.$message.success( '操作成功')
} else {
this.$message.error(data.msg)
}
})
}).catch(() => {
return
})
},
newColor(){
if(this.searchData.codeNo==''){
this.$message.success('数据错误,请关闭页面重试!')
return false;
}
let number=1;
for (let i = 0; i <this.colorTable.length ; i++) {
if(number<=this.colorTable[i].order){
number=Number(this.colorTable[i].order)+1
}
}
this.colorData={
id:0,
site: this.searchData.site,
codeNo:this.searchData.codeNo,
order:number,
hardness:'',
tartness:'',
printingSide:'',
energy:'',
drySpeed:'',
dryTime:'',
dryTemp:'',
dryTime2:'',
updateBy:'',
updateDate:'',
}
this.colorFlag=true;
},
updateColor(row){
this.colorData=JSON.parse(JSON.stringify(row))
this.colorFlag=true;
},
colorSearch(){
searchBMInkFormulationColor(this.searchData).then(({data}) => {
this.colorTable = data.rows
});
},
colorSave(){
this.$confirm("是否保存信息?", '保存提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(() => {
saveBMInkFormulationColor(this.colorData).then(({data}) => {
if (data && data.code === 0) {
this.colorSearch();
this.colorFlag=false
this.$message.success( '操作成功')
} else {
this.$message.error(data.msg)
}
})
}).catch(() => {
})
},
deleteColor(row){
this.$confirm(`是否删除这条信息?`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteBMInkFormulationColor(row).then(({data}) => {
if (data && data.code === 0) {
this.colorSearch();
this.$message({
message: '操作成功',
type: 'success',
duration: 1500,
onClose: () => {}
})
} else {
this.$alert(data.msg, '错误', {
confirmButtonText: '确定'
})
}
})
}).catch(() => {
})
},
},
}
</script>
<style scoped>
</style>

20
src/views/modules/sampleManagement/technicalSpecificationDetail/com_bm_inkMixing.vue

@ -196,11 +196,11 @@
<script>
import {
searchBMPrepressDetail,
updateBMPrepressDetail,
searchBMPrepressColor,
saveBMPrepressColor,
deleteBMPrepressColor,
searchBMInkMixingDetail,
updateBMInkMixingDetail,
searchBMInkMixingColor,
saveBMInkMixingColor,
deleteBMInkMixingColor,
} from "@/api/sampleManagement/technicalSpecificationList.js"
import Chooselist from '@/views/modules/common/Chooselist'
export default {
@ -284,7 +284,7 @@
},
searchTable(){
searchBMPrepressDetail(this.searchData).then(({data}) => {
searchBMInkMixingDetail(this.searchData).then(({data}) => {
if(data.rows.length>0){
this.dataForm = data.rows[0];
}else {
@ -298,7 +298,7 @@
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(() => {
updateBMPrepressDetail(this.dataForm).then(({data}) => {
updateBMInkMixingDetail(this.dataForm).then(({data}) => {
if (data && data.code === 0) {
this.$message.success( '操作成功')
} else {
@ -345,7 +345,7 @@
},
colorSearch(){
searchBMPrepressColor(this.searchData).then(({data}) => {
searchBMInkMixingColor(this.searchData).then(({data}) => {
this.colorTable = data.rows
});
},
@ -354,7 +354,7 @@
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(() => {
saveBMPrepressColor(this.colorData).then(({data}) => {
saveBMInkMixingColor(this.colorData).then(({data}) => {
if (data && data.code === 0) {
this.colorSearch();
this.colorFlag=false
@ -373,7 +373,7 @@
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteBMPrepressColor(row).then(({data}) => {
deleteBMInkMixingColor(row).then(({data}) => {
if (data && data.code === 0) {
this.colorSearch();
this.$message({

436
src/views/modules/sampleManagement/technicalSpecificationDetail/com_bm_lamination.vue

@ -0,0 +1,436 @@
<template>
<div class="mod-config">
<el-form label-position="top" style="margin-top: 1px; margin-left: 0px;" v-if="searchData.buNo==='DBE'||searchData.buNo==='SS'">
<el-form-item >
<el-button type="primary" @click="cutSearch()" >刷新</el-button>
<el-button type="primary" @click="newCut()" v-if="!ifDisableFlag">新增</el-button>
</el-form-item>
<el-table
height="400"
:data="cutTable"
border
style="width: 100%">
<el-table-column
prop=""
header-align="center"
align="center"
min-width="30"
v-if="!ifDisableFlag"
label="操作">
<template slot-scope="scope">
<a type="text" size="small" @click="updateCut(scope.row)">编辑</a>
<a type="text" size="small" @click="deleteCut(scope.row)">删除</a>
</template>
</el-table-column>
<el-table-column
v-for="(item,index) in columnList" :key="index"
:prop="item.columnProp"
header-align="center"
:align="item.align"
:min-width="item.columnWidth"
:label="item.columnLabel">
</el-table-column>
</el-table>
<el-row :gutter="20" >
<el-col :span="24"><div class="grid-content bg-purple">
<el-form-item :label="'Action'">
<el-input
type="textarea"
v-model="dataForm.action "
:rows="3"
resize='none'
maxlength="120"
show-word-limit
:disabled="ifDisableFlag"
style="height: 60px" >
</el-input>
</el-form-item>
</div></el-col>
</el-row>
<el-row :gutter="20" style="margin-top: 60px" v-if="searchData.buNo==='DBE'">
<el-col :span="24"><div class="grid-content bg-purple">
<el-form-item :label="'备注/Remarks'">
<el-input
type="textarea"
v-model="dataForm.remark "
:rows="3"
resize='none'
maxlength="120"
show-word-limit
:disabled="ifDisableFlag"
style="height: 60px" >
</el-input>
</el-form-item>
</div></el-col>
</el-row>
</el-form>
<el-form label-position="top" style="margin-top:60px; margin-left: 0px;text-align:center">
<el-button type="primary" @click="saveData()" v-if="searchData.buNo==='DBE'||searchData.buNo==='SS'" >保存</el-button>
</el-form>
<el-dialog title="编辑信息" :close-on-click-modal="false" v-drag :visible.sync="cutFlag" width="600px">
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item :label="'次序'">
<el-input v-model="cutData.order" type="number" style="width: 130px" onkeyup="value=value.replace(/^(0+)|[^\d]+/g,'')" ></el-input>
</el-form-item>
<el-form-item :label="'工段'">
<el-input v-model="cutData.station" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'制程状态'">
<el-input v-model="cutData.processStep" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'手动/自动覆合机'">
<el-input v-model="cutData.machine" style="width: 130px" ></el-input>
</el-form-item>
</el-form>
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;">
<el-form-item :label="'材料复合类型'">
<el-input v-model="cutData.laminationType" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'原材料号'">
<el-input v-model="cutData.rmPartNo" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'原材料号2'" v-if="searchData.buNo==='DBE'">
<el-input v-model="cutData.rmPartNo2" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'覆合面'">
<el-input v-model="cutData.laminationSide" style="width: 130px" ></el-input>
</el-form-item>
</el-form>
<el-form :inline="true" label-position="top" style="margin-left: 7px;margin-top: -5px;" v-if="searchData.buNo=='DBE'">
<el-form-item :label="'膜的型号'">
<el-input v-model="cutData.filmPartNo" style="width: 130px" ></el-input>
</el-form-item>
<el-form-item :label="'备注'">
<el-input v-model="cutData.remarks" style="width: 276px" ></el-input>
</el-form-item>
</el-form>
<el-footer style="height:40px;margin-top: 10px;text-align:center">
<el-button type="primary" @click="cutSave()">保存</el-button>
<el-button type="primary" @click="cutFlag = false">取消</el-button>
</el-footer>
</el-dialog>
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist>
</div>
</template>
<script>
import {
searchBMLaminationDetail,
updateBMLaminationDetail,
searchBMLaminationCut,
saveBMLaminationCut,
deleteBMLaminationCut,
} from "@/api/sampleManagement/technicalSpecificationList.js"
import Chooselist from '@/views/modules/common/Chooselist'
export default {
components: {
Chooselist
},
data() {
return {
searchData: {
site: '',
username: this.$store.state.user.name,
codeNo: '',
buNo:'',
},
ifDisableFlag:false,
dataForm:{
site: '',
codeNo:'',
remark:'',
action:'',
},
cutTable:[],
cutData:{
id:'',
site: '',
codeNo:'',
order:'',
station:'',
processStep:'',
machine:'',
laminationType:'',
rmPartNo:'',
rmPartNo2:'',
laminationSide:'',
filmPartNo:'',
remarks:'',
updateBy:'',
updateDate:'',
},
columnList:[],
columnList1:[
{
columnProp: "order",
align: "right",
columnLabel: "次序",
columnWidth: 30
},
{
columnProp: "station",
align: "left",
columnLabel: "工段",
columnWidth: 60
},
{
columnProp: "processStep",
align: "left",
columnLabel: "制程状态",
columnWidth: 60
},
{
columnProp: "machine",
align: "left",
columnLabel: "手动/自动覆合机",
columnWidth: 60
},
{
columnProp: "laminationType",
align: "left",
columnLabel: "材料复合类型",
columnWidth: 60
},
{
columnProp: "rmPartNo",
align: "left",
columnLabel: "原材料号",
columnWidth: 60
},
{
columnProp: "laminationSide",
align: "left",
columnLabel: "覆合面",
columnWidth: 60
},
],
columnList2:[
{
columnProp: "order",
align: "right",
columnLabel: "次序",
columnWidth: 30
},
{
columnProp: "station",
align: "left",
columnLabel: "工段",
columnWidth: 60
},
{
columnProp: "processStep",
align: "left",
columnLabel: "制程状态",
columnWidth: 60
},
{
columnProp: "machine",
align: "left",
columnLabel: "手动/自动覆合机",
columnWidth: 60
},
{
columnProp: "laminationType",
align: "left",
columnLabel: "材料复合类型",
columnWidth: 60
},
{
columnProp: "rmPartNo",
align: "left",
columnLabel: "原材料号",
columnWidth: 60
},
{
columnProp: "rmPartNo2",
align: "left",
columnLabel: "原材料号2",
columnWidth: 60
},
{
columnProp: "filmPartNo",
align: "left",
columnLabel: "膜的型号",
columnWidth: 60
},
{
columnProp: "laminationSide",
align: "left",
columnLabel: "覆合面",
columnWidth: 60
},
{
columnProp: "remarks",
align: "left",
columnLabel: "备注",
columnWidth: 60
},
],
cutFlag:false,
}
},
methods: {
// S
getBaseList (val, type) {
this.tagNo = val
this.tagNo1 = type
this.$nextTick(() => {
let strVal = ''
if (val === 1013) {
if(type==1) {
strVal = this.dataForm.partType
}
}
this.$refs.baseList.init(val, strVal)
})
},
/* 列表方法的回调 */
getBaseData (val) {
if (this.tagNo === 1013) {
if(this.tagNo1==1) {
this.dataForm.partType = val.Base_id
this.dataForm.partTypeDesc = val.Base_desc
}
}
},
//
init(inData) {
if(this.dataForm.codeNo!=null&&this.dataForm.codeNo!=''){
return false;
}
//
this.searchData = JSON.parse(JSON.stringify(inData));
if(this.searchData.buNo==='SS'){
this.columnList=JSON.parse(JSON.stringify(this.columnList1));
}
if(this.searchData.buNo==='DBE'){
this.columnList=JSON.parse(JSON.stringify(this.columnList2));
}
//
this.searchTable();
this.cutSearch();
},
searchTable(){
searchBMLaminationDetail(this.searchData).then(({data}) => {
if(data.rows.length>0){
this.dataForm = data.rows[0];
}else {
this.dataForm.site=this.searchData.site
this.dataForm.codeNo=this.searchData.codeNo
}
});
},
saveData(){
this.$confirm("是否保存信息?", '保存提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(() => {
updateBMLaminationDetail(this.dataForm).then(({data}) => {
if (data && data.code === 0) {
this.$message.success( '操作成功')
} else {
this.$message.error(data.msg)
}
})
}).catch(() => {
return
})
},
newCut(){
if(this.searchData.codeNo==''){
this.$message.success('数据错误,请关闭页面重试!')
return false;
}
let number=1;
for (let i = 0; i <this.cutTable.length ; i++) {
if(number<=this.cutTable[i].order){
number=Number(this.cutTable[i].order)+1
}
}
this.cutData={
id:0,
site: this.searchData.site,
codeNo:this.searchData.codeNo,
order:number,
station:'',
processStep:'',
machine:'',
laminationType:'',
rmPartNo:'',
rmPartNo2:'',
laminationSide:'',
filmPartNo:'',
remarks:'',
updateBy:'',
updateDate:'',
}
this.cutFlag=true;
},
updateCut(row){
this.cutData=JSON.parse(JSON.stringify(row))
this.cutFlag=true;
},
cutSearch(){
searchBMLaminationCut(this.searchData).then(({data}) => {
this.cutTable = data.rows
});
},
cutSave(){
this.$confirm("是否保存信息?", '保存提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
}).then(() => {
saveBMLaminationCut(this.cutData).then(({data}) => {
if (data && data.code === 0) {
this.cutSearch();
this.cutFlag=false
this.$message.success( '操作成功')
} else {
this.$message.error(data.msg)
}
})
}).catch(() => {
})
},
deleteCut(row){
this.$confirm(`是否删除这条信息?`, '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
deleteBMLaminationCut(row).then(({data}) => {
if (data && data.code === 0) {
this.cutSearch();
this.$message({
message: '操作成功',
type: 'success',
duration: 1500,
onClose: () => {}
})
} else {
this.$alert(data.msg, '错误', {
confirmButtonText: '确定'
})
}
})
}).catch(() => {
})
},
},
}
</script>
<style scoped>
</style>

26
src/views/modules/sampleManagement/technicalSpecificationDetail/technicalSpecificationDetail.vue

@ -52,6 +52,12 @@
<el-tab-pane label="油墨房" name="InkMixing" v-if="getPageIf('InkMixing')">
<InkMixing ref="InkMixing"></InkMixing>
</el-tab-pane>
<el-tab-pane label="油墨配方" name="InkFormulation" v-if="getPageIf('InkFormulation')">
<InkFormulation ref="InkFormulation"></InkFormulation>
</el-tab-pane>
<el-tab-pane label="覆膜" name="lamination" v-if="getPageIf('Lamination')">
<lamination ref="lamination"></lamination>
</el-tab-pane>
<el-tab-pane label="包装" name="packagePage" v-if="getPageIf('packagePage')">
<packagePage ref="packagePage"></packagePage>
</el-tab-pane>
@ -112,6 +118,8 @@
import tpInfo from "./com_bm_tpInfo";/*组件*/
import printOther from "./com_bm_printOther";/*组件*/
import InkMixing from "./com_bm_inkMixing";/*组件*/
import InkFormulation from "./com_bm_inkFormulation";/*组件*/
import lamination from "./com_bm_lamination";/*组件*/
export default {
name: "technicalSpecificationDetail",
components: {
@ -140,6 +148,8 @@
tpInfo,
printOther,
InkMixing,
InkFormulation,
lamination,
},
data() {
return {
@ -225,9 +235,13 @@
this.getTpInfo();
}else if(this.activeName == 'printOther'){
this.getPrintOther();
}
else if(this.activeName == 'InkMixing'){
}else if(this.activeName == 'InkMixing'){
this.getInkMixing();
}else if(this.activeName == 'InkFormulation'){
this.changeHeight(800);
this.getInkFormulation();
}else if(this.activeName == 'lamination'){
this.getLamination();
}
},
@ -326,6 +340,14 @@
this.dataForm.type='InkMixing'
this.$refs.InkMixing.init(JSON.parse(JSON.stringify(this.dataForm)))
},
getInkFormulation(){
this.dataForm.type='InkFormulation'
this.$refs.InkFormulation.init(JSON.parse(JSON.stringify(this.dataForm)))
},
getLamination(){
this.dataForm.type='lamination'
this.$refs.lamination.init(JSON.parse(JSON.stringify(this.dataForm)))
},
//
getPageRole(){

Loading…
Cancel
Save