|
|
|
|
@ -4,22 +4,32 @@
|
|
|
|
|
<lay-container class="dataInfo">
|
|
|
|
|
|
|
|
|
|
<lay-row space="10">
|
|
|
|
|
<lay-col md="6"><div class="grid-demo" style="text-align: right;">原配方:</div></lay-col>
|
|
|
|
|
<lay-col md="18"><div class="grid-demo" style="text-align: left;">{{dataInfoObj.FTestCode}}+{{dataInfoObj.FVersionCode}}+{{dataInfoObj.FDesc}}</div></lay-col>
|
|
|
|
|
<lay-col md="6">
|
|
|
|
|
<div class="grid-demo" style="text-align: right;">原配方:</div>
|
|
|
|
|
</lay-col>
|
|
|
|
|
<lay-col md="18">
|
|
|
|
|
<div class="grid-demo" style="text-align: left;">
|
|
|
|
|
{{ dataInfoObj.FTestCode }}+{{ dataInfoObj.FVersionCode }}+{{ dataInfoObj.FDesc }}</div>
|
|
|
|
|
</lay-col>
|
|
|
|
|
</lay-row>
|
|
|
|
|
<lay-row space="10">
|
|
|
|
|
<lay-col md="6"><div class="grid-demo" style="text-align: right;">变更后的配方:</div></lay-col>
|
|
|
|
|
<lay-col md="18"><div class="grid-demo" style="text-align: left;">{{dataInfoObj.FNewTestCode}}+{{dataInfoObj.FNewVersionCode}}+{{dataInfoObj.FNewDesc}}</div></lay-col>
|
|
|
|
|
<lay-col md="6">
|
|
|
|
|
<div class="grid-demo" style="text-align: right;">变更后的配方:</div>
|
|
|
|
|
</lay-col>
|
|
|
|
|
<lay-col md="18">
|
|
|
|
|
<div class="grid-demo" style="text-align: left;">
|
|
|
|
|
{{ dataInfoObj.FNewTestCode }}+{{ dataInfoObj.FNewVersionCode }}+{{ dataInfoObj.FNewDesc }}</div>
|
|
|
|
|
</lay-col>
|
|
|
|
|
</lay-row>
|
|
|
|
|
</lay-container>
|
|
|
|
|
<lay-quote v-if="dataList.length>0">视图信息</lay-quote>
|
|
|
|
|
<lay-container class="tableInfo" v-if="dataList.length>0">
|
|
|
|
|
<lay-quote v-if="dataList.length > 0">视图信息</lay-quote>
|
|
|
|
|
<lay-container class="tableInfo" v-if="dataList.length > 0">
|
|
|
|
|
<lay-table :columns="dataColumn" :dataSource="dataList">
|
|
|
|
|
<template v-slot:operator="{ data }">
|
|
|
|
|
<lay-button v-if="data.seeCode!=''" size="xs" type="primary" @click="_getTeamworkView(data,1)">
|
|
|
|
|
<lay-button v-if="data.seeCode != ''" size="xs" type="primary" @click="_getTeamworkView(data, 1)">
|
|
|
|
|
查看
|
|
|
|
|
</lay-button>
|
|
|
|
|
<lay-button v-if="data.outCode!=''" size="xs" type="primary" @click="_getTeamworkView(data,2)">
|
|
|
|
|
<lay-button v-if="data.outCode != ''" size="xs" type="primary" @click="_getTeamworkView(data, 2)">
|
|
|
|
|
导出
|
|
|
|
|
</lay-button>
|
|
|
|
|
</template>
|
|
|
|
|
@ -27,53 +37,50 @@
|
|
|
|
|
</lay-container>
|
|
|
|
|
</lay-scroll>
|
|
|
|
|
<lay-layer area="90%" v-model="showEditBox" title="视图查看">
|
|
|
|
|
<ShowMaterial :viewList="viewList" :viewHeight="viewHeight" :dataInfoObj="objInfoObj" @cancelClick="cancelClick"></ShowMaterial>
|
|
|
|
|
</lay-layer>
|
|
|
|
|
<lay-layer area="90%" v-model="showEditBox1" title="配方视图">
|
|
|
|
|
<FormulaView :viewList="viewList" :viewHeight="viewHeight" :dataInfoObj="objInfoObj" @cancelClick="cancelClick"></FormulaView>
|
|
|
|
|
<ShowView :viewList="viewList" :viewHeight="viewHeight" @cancelClick="cancelClick"></ShowView>
|
|
|
|
|
</lay-layer>
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<style scoped>
|
|
|
|
|
.box-data {
|
|
|
|
|
.box-data {
|
|
|
|
|
margin: 10px auto;
|
|
|
|
|
display: block;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.dataInfo {
|
|
|
|
|
.dataInfo {
|
|
|
|
|
max-width: 960px;
|
|
|
|
|
margin: 14px auto 20px;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
clear: both;
|
|
|
|
|
float: none;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item.state1 {
|
|
|
|
|
.pro-item.state1 {
|
|
|
|
|
background-color: rgb(50, 189, 182, 0.9);
|
|
|
|
|
background-image: url('../../../assets/state1.png');
|
|
|
|
|
box-shadow: 4px 4px 4px rgb(50, 189, 182, 0.4);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item.state2 {
|
|
|
|
|
.pro-item.state2 {
|
|
|
|
|
background-color: rgb(22, 138, 221, 0.9);
|
|
|
|
|
background-image: url('../../../assets/state2.png');
|
|
|
|
|
box-shadow: 4px 4px 4px rgb(22, 138, 221, 0.4);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item.none {
|
|
|
|
|
.pro-item.none {
|
|
|
|
|
float: none !important;
|
|
|
|
|
display: block !important;
|
|
|
|
|
margin-left: auto;
|
|
|
|
|
margin-right: auto;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item.none .left {
|
|
|
|
|
.pro-item.none .left {
|
|
|
|
|
margin-top: 11px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item {
|
|
|
|
|
.pro-item {
|
|
|
|
|
background: rgb(187, 187, 187, 0.9) url('../../../assets/state0.png') no-repeat left top;
|
|
|
|
|
-webkit-border-radius: 6px;
|
|
|
|
|
-ms-border-radius: 6px;
|
|
|
|
|
@ -84,27 +91,27 @@
|
|
|
|
|
margin: 10px 1%;
|
|
|
|
|
padding: 16px 5px;
|
|
|
|
|
box-shadow: 4px 4px 4px rgb(187, 187, 187, 0.4);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .left {
|
|
|
|
|
.pro-item .left {
|
|
|
|
|
width: 34%;
|
|
|
|
|
display: block;
|
|
|
|
|
text-align: center;
|
|
|
|
|
float: left;
|
|
|
|
|
margin-top: 13px;
|
|
|
|
|
margin-bottom: 5px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .left.margin {
|
|
|
|
|
.pro-item .left.margin {
|
|
|
|
|
margin-top: 6px;
|
|
|
|
|
margin-bottom: 0;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .left.margin .group {
|
|
|
|
|
.pro-item .left.margin .group {
|
|
|
|
|
margin: 6px auto 2px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .left .num {
|
|
|
|
|
.pro-item .left .num {
|
|
|
|
|
-webkit-border-radius: 32px;
|
|
|
|
|
-ms-border-radius: 32px;
|
|
|
|
|
-o-border-radius: 32px;
|
|
|
|
|
@ -116,9 +123,9 @@
|
|
|
|
|
width: 32px;
|
|
|
|
|
border: 1px solid #222;
|
|
|
|
|
margin: 0 auto;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .left .group {
|
|
|
|
|
.pro-item .left .group {
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
line-height: 22px;
|
|
|
|
|
margin: 10px auto 8px;
|
|
|
|
|
@ -126,55 +133,54 @@
|
|
|
|
|
max-width: 100px;
|
|
|
|
|
display: block;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .right {
|
|
|
|
|
.pro-item .right {
|
|
|
|
|
width: 63%;
|
|
|
|
|
display: inline-block;
|
|
|
|
|
line-height: 22px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-item .right p {
|
|
|
|
|
.pro-item .right p {
|
|
|
|
|
white-space: nowrap;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
text-overflow: ellipsis
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.pro-next {
|
|
|
|
|
.pro-next {
|
|
|
|
|
display: block;
|
|
|
|
|
background: url('../../../assets/state-next.jpg') no-repeat center;
|
|
|
|
|
height: 30px;
|
|
|
|
|
margin: 10px auto;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.tableInfo {
|
|
|
|
|
.tableInfo {
|
|
|
|
|
max-width: 96%;
|
|
|
|
|
margin: 20px auto;
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
clear: both;
|
|
|
|
|
float: none;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|
|
|
|
|
<script>
|
|
|
|
|
import {
|
|
|
|
|
import {
|
|
|
|
|
ref,
|
|
|
|
|
watch
|
|
|
|
|
} from 'vue';
|
|
|
|
|
import {
|
|
|
|
|
} from 'vue';
|
|
|
|
|
import {
|
|
|
|
|
getTeamProcessList,
|
|
|
|
|
getTeamworkView
|
|
|
|
|
} from "/src/api/api/teamwork";
|
|
|
|
|
import {
|
|
|
|
|
} from "/src/api/api/halfmaterialteamwork";
|
|
|
|
|
import {
|
|
|
|
|
getBasicRoleList
|
|
|
|
|
} from "/src/api/api/user";
|
|
|
|
|
} from "/src/api/api/user";
|
|
|
|
|
|
|
|
|
|
import ShowMaterial from './ShowMaterial.vue';
|
|
|
|
|
import FormulaView from './FormulaView.vue';
|
|
|
|
|
import ShowView from './ShowView.vue';
|
|
|
|
|
import FormulaView from './FormulaView.vue';
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
|
export default {
|
|
|
|
|
components: {
|
|
|
|
|
ShowMaterial,
|
|
|
|
|
FormulaView
|
|
|
|
|
ShowView
|
|
|
|
|
},
|
|
|
|
|
setup() {
|
|
|
|
|
const dataList = ref([]);
|
|
|
|
|
@ -197,7 +203,7 @@
|
|
|
|
|
const showEditBox1 = ref(false);
|
|
|
|
|
const viewList = ref([]);
|
|
|
|
|
const viewHeight = ref(500);
|
|
|
|
|
const objInfoObj=ref([]);
|
|
|
|
|
const objInfoObj = ref([]);
|
|
|
|
|
return {
|
|
|
|
|
dataList,
|
|
|
|
|
dataColumn,
|
|
|
|
|
@ -213,7 +219,7 @@
|
|
|
|
|
props: {
|
|
|
|
|
dataInfoObj: {
|
|
|
|
|
type: Object,
|
|
|
|
|
default: () => {},
|
|
|
|
|
default: () => { },
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
|
@ -223,26 +229,40 @@
|
|
|
|
|
|
|
|
|
|
//获取视图
|
|
|
|
|
async _getViewList() {
|
|
|
|
|
debugger
|
|
|
|
|
this.dataList = [{"name":"物料视图","code":"1","outCode":"6"},{"name":"配方视图","code":"2","outCode":"10"}];
|
|
|
|
|
this.dataList = [{ "name": "物料视图", "code": "1", "outCode": "6","seeCode":"1" }, { "name": "配方视图", "code": "2", "outCode": "7","seeCode":"2" }];
|
|
|
|
|
},
|
|
|
|
|
async _getTeamworkView(data, type) {
|
|
|
|
|
debugger
|
|
|
|
|
|
|
|
|
|
let viewType = parseInt(type == 1 ? data.seeCode : data.outCode);
|
|
|
|
|
if (type == 2) viewType = viewType - this.viewTypeCount;
|
|
|
|
|
let postData = {
|
|
|
|
|
FTeamID: this.dataInfoObj.FID,
|
|
|
|
|
FViewType: viewType,
|
|
|
|
|
FType: type,
|
|
|
|
|
HalfId : this.dataInfoObj.FMaterialHalfIDs
|
|
|
|
|
};
|
|
|
|
|
if (this.dataInfoObj.FProgress == "100" || this.dataInfoObj.FProgress == "100%") {
|
|
|
|
|
postData.FFinish = 1;
|
|
|
|
|
}
|
|
|
|
|
let idx = layer.load(2);
|
|
|
|
|
let result = await getTeamworkView(postData);
|
|
|
|
|
layer.close(idx);
|
|
|
|
|
if (type == 1) {
|
|
|
|
|
|
|
|
|
|
if(data.code==1)
|
|
|
|
|
{
|
|
|
|
|
this.objInfoObj=this.dataInfoObj;
|
|
|
|
|
let list = [];
|
|
|
|
|
let count = 0;
|
|
|
|
|
for (let key in result) {
|
|
|
|
|
list.push(result[key]);
|
|
|
|
|
count += result[key].length;
|
|
|
|
|
};
|
|
|
|
|
if (count == 0) {
|
|
|
|
|
layer.msg("请稍等,视图信息还在编辑中", {
|
|
|
|
|
time: 2000,
|
|
|
|
|
icon: 3
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
this.viewList = list;
|
|
|
|
|
this.viewHeight = Math.ceil(500);
|
|
|
|
|
this.showEditBox = true;
|
|
|
|
|
}
|
|
|
|
|
else if(data.code==2){
|
|
|
|
|
this.objInfoObj=this.dataInfoObj;
|
|
|
|
|
this.showEditBox1 = true;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
window.open(result);
|
|
|
|
|
}
|
|
|
|
|
@ -256,5 +276,5 @@
|
|
|
|
|
this.$emit('cancelClick', isFirst ? isFirst : false);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</script>
|
|
|
|
|
|