pageHeghtAdjust
This commit is contained in:
parent
755c0abb35
commit
0e9624281f
|
@ -135,6 +135,7 @@
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
mixins: [drawMixin],
|
mixins: [drawMixin],
|
||||||
|
inject:['reload'],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
timing: null,
|
timing: null,
|
||||||
|
@ -437,6 +438,7 @@
|
||||||
category:[],
|
category:[],
|
||||||
planData:[],
|
planData:[],
|
||||||
realData:[],
|
realData:[],
|
||||||
|
timer:null,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
|
@ -476,6 +478,9 @@
|
||||||
that.getOneData();//车间一
|
that.getOneData();//车间一
|
||||||
that.getTwoData();//车间二
|
that.getTwoData();//车间二
|
||||||
that.getArticle();
|
that.getArticle();
|
||||||
|
that.timer = window.setInterval(() => {
|
||||||
|
that.reload();
|
||||||
|
},3600000)
|
||||||
},
|
},
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
clearInterval(this.timing)
|
clearInterval(this.timing)
|
||||||
|
@ -483,8 +488,8 @@
|
||||||
methods: {
|
methods: {
|
||||||
timeFn() {
|
timeFn() {
|
||||||
this.timing = setInterval(() => {
|
this.timing = setInterval(() => {
|
||||||
this.dateDay = formatTimeBigScreen(new Date(), 'HH: mm: ss')
|
this.dateDay = formatTimeBigScreen(new Date(), 'HH: mm: ss');
|
||||||
this.dateYear = formatTimeBigScreen(new Date(), 'yyyy-MM-dd')
|
this.dateYear = formatTimeBigScreen(new Date(), 'yyyy-MM-dd');
|
||||||
this.dateWeek = this.weekday[new Date().getDay()]
|
this.dateWeek = this.weekday[new Date().getDay()]
|
||||||
}, 1000)
|
}, 1000)
|
||||||
},
|
},
|
||||||
|
@ -527,8 +532,19 @@
|
||||||
that.titleItem[3].number.number[0] = respo.data.count_selled;
|
that.titleItem[3].number.number[0] = respo.data.count_selled;
|
||||||
that.titleItem[4].number.number[0] = respo.data.count_notok;
|
that.titleItem[4].number.number[0] = respo.data.count_notok;
|
||||||
let mtestCount = respo.data.count_mtestok + respo.data.count_mtestnotok;
|
let mtestCount = respo.data.count_mtestok + respo.data.count_mtestnotok;
|
||||||
that.titleItem[5].number.number[0] = Math.floor((respo.data.count_mtestok / mtestCount) * 100);
|
if(respo.data.count_mtestok===0){
|
||||||
that.rate[0].tips = Math.floor((respo.data.count_ok / respo.data.count) * 100);
|
that.titleItem[5].number.number[0] = 0;
|
||||||
|
that.rate[0].tips = 0;
|
||||||
|
}else if(mtestCount===0){
|
||||||
|
that.titleItem[5].number.number[0] = 100;
|
||||||
|
}else{
|
||||||
|
that.titleItem[5].number.number[0] = Math.floor((respo.data.count_mtestok / mtestCount) * 100);
|
||||||
|
}
|
||||||
|
if(respo.data.count===0){
|
||||||
|
that.rate[0].tips = 100;
|
||||||
|
}else{
|
||||||
|
that.rate[0].tips = Math.floor((respo.data.count_ok / respo.data.count) * 100);
|
||||||
|
}
|
||||||
//工序生产进度
|
//工序生产进度
|
||||||
getProcessNow({type: 'big_screen'}).then(res => {
|
getProcessNow({type: 'big_screen'}).then(res => {
|
||||||
if (res.data) {
|
if (res.data) {
|
||||||
|
@ -703,6 +719,8 @@
|
||||||
that.limitedPlan = false;
|
that.limitedPlan = false;
|
||||||
getPlanGantt({type: 'big_screen'}).then(res => {
|
getPlanGantt({type: 'big_screen'}).then(res => {
|
||||||
if (res.code === 200) {
|
if (res.code === 200) {
|
||||||
|
that.planData = [];
|
||||||
|
that.realData = [];
|
||||||
let list = res.data.results;
|
let list = res.data.results;
|
||||||
list.forEach(item=>{
|
list.forEach(item=>{
|
||||||
that.category.push(item.number);
|
that.category.push(item.number);
|
||||||
|
@ -715,6 +733,9 @@
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
},
|
||||||
|
destroyed() {
|
||||||
|
clearInterval(this.timer)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -147,7 +147,7 @@
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-tabs type="border-card" style="height:310px">
|
<el-tabs type="border-card">
|
||||||
<el-tab-pane label="输入物料">
|
<el-tab-pane label="输入物料">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="checkPermission(['subproduction_update'])"
|
v-if="checkPermission(['subproduction_update'])"
|
||||||
|
@ -681,7 +681,7 @@
|
||||||
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
halfHeight: 190,
|
halfHeight: null,
|
||||||
materialoptions: [],
|
materialoptions: [],
|
||||||
subproducationData: [],
|
subproducationData: [],
|
||||||
inputtableData: [],
|
inputtableData: [],
|
||||||
|
@ -759,11 +759,7 @@
|
||||||
let that = this;
|
let that = this;
|
||||||
let hei = document.getElementsByClassName('app-main')[0].clientHeight;
|
let hei = document.getElementsByClassName('app-main')[0].clientHeight;
|
||||||
let h = document.getElementById('processCard').clientHeight;
|
let h = document.getElementById('processCard').clientHeight;
|
||||||
that.halfHeight = (hei - h - 160) / 2;
|
that.halfHeight = (hei - h - 176) / 2;
|
||||||
/* debugger;
|
|
||||||
console.log(hei);
|
|
||||||
console.log(h);
|
|
||||||
console.log(this.halfHeight)*/
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
checkPermission,
|
checkPermission,
|
||||||
|
|
|
@ -33,7 +33,7 @@
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
height="300"
|
:height="domHeight"
|
||||||
@row-click="tableRowClick"
|
@row-click="tableRowClick"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50"/>
|
<el-table-column type="index" width="50"/>
|
||||||
|
@ -96,7 +96,7 @@
|
||||||
@pagination="getplanList"
|
@pagination="getplanList"
|
||||||
/>
|
/>
|
||||||
</el-card>
|
</el-card>
|
||||||
<el-card class="box-card">
|
<el-card class="box-card" id="ganttCard">
|
||||||
<div style="height: 40px;line-height: 40px;background: #F5F7FA;padding-left: 20px;">甘特图</div>
|
<div style="height: 40px;line-height: 40px;background: #F5F7FA;padding-left: 20px;">甘特图</div>
|
||||||
<gantt
|
<gantt
|
||||||
v-if="proList.length>0"
|
v-if="proList.length>0"
|
||||||
|
@ -116,6 +116,7 @@
|
||||||
components: {Pagination, gantt},
|
components: {Pagination, gantt},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
domHeight:null,
|
||||||
productionplanList: {
|
productionplanList: {
|
||||||
count: 0,
|
count: 0,
|
||||||
},
|
},
|
||||||
|
@ -279,6 +280,11 @@
|
||||||
this.$router.push({name: "plandetails", params: {id: scope.row.id}});
|
this.$router.push({name: "plandetails", params: {id: scope.row.id}});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
let hei = document.getElementsByClassName('app-main')[0].clientHeight;//
|
||||||
|
// let h = document.getElementById('ganttCard').clientHeight;//
|
||||||
|
this.domHeight = hei - 460;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
@ -29,11 +29,12 @@
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-table
|
<el-table
|
||||||
:data="productionplanList.results"
|
:data="productionplanList.results"
|
||||||
|
id="productionPlan"
|
||||||
border
|
border
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
height="300"
|
:height="domHeight"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50"/>
|
<el-table-column type="index" width="50"/>
|
||||||
<el-table-column label="任务编号" prop="number" width="110">
|
<el-table-column label="任务编号" prop="number" width="110">
|
||||||
|
@ -141,11 +142,12 @@
|
||||||
<el-tab-pane label="订单排产" name="订单排产">
|
<el-tab-pane label="订单排产" name="订单排产">
|
||||||
<el-table
|
<el-table
|
||||||
:data="orderList.results"
|
:data="orderList.results"
|
||||||
|
id="orderList"
|
||||||
border
|
border
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
height="250"
|
:height="domHeight"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50"/>
|
<el-table-column type="index" width="50"/>
|
||||||
<el-table-column label="订单编号" width="110">
|
<el-table-column label="订单编号" width="110">
|
||||||
|
@ -278,6 +280,7 @@
|
||||||
components: {Pagination, gantt},
|
components: {Pagination, gantt},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
domHeight:null,
|
||||||
orderplan: defaulteorderplan,
|
orderplan: defaulteorderplan,
|
||||||
orderList: {
|
orderList: {
|
||||||
count: 0,
|
count: 0,
|
||||||
|
@ -507,6 +510,12 @@
|
||||||
this.$router.push({name: "work", params: {id: scope.row.id}});
|
this.$router.push({name: "work", params: {id: scope.row.id}});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
let hei = document.getElementsByClassName('app-main')[0].clientHeight;//
|
||||||
|
let domHeight = this.domHeight = (hei - 205) / 2;
|
||||||
|
document.getElementById('orderList').style.height = domHeight + 'px';
|
||||||
|
document.getElementById('productionPlan').style.height = domHeight + 'px';
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|
|
@ -21,66 +21,38 @@
|
||||||
stripe
|
stripe
|
||||||
highlight-current-row
|
highlight-current-row
|
||||||
height="100"
|
height="100"
|
||||||
v-el-height-adaptive-table="{ bottomOffset: 25 }"
|
v-el-height-adaptive-table="{ bottomOffset: 44 }"
|
||||||
>
|
>
|
||||||
<el-table-column type="selection" width="55"></el-table-column>
|
<el-table-column type="selection" width="55"></el-table-column>
|
||||||
|
|
||||||
<el-table-column label="订单编号" width="110">
|
<el-table-column label="订单编号" width="110">
|
||||||
<template slot-scope="scope">{{ scope.row.number }}</template>
|
<template slot-scope="scope">{{ scope.row.number }}</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column label="所需产品" show-overflow-tooltip width="150">
|
<el-table-column label="所需产品" show-overflow-tooltip width="150">
|
||||||
<template slot-scope="scope">{{
|
<template slot-scope="scope">{{scope.row.product_.name }}</template>
|
||||||
scope.row.product_.name
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column label="产品数量">
|
<el-table-column label="产品数量">
|
||||||
<template slot-scope="scope">{{ scope.row.count }}</template>
|
<template slot-scope="scope">{{ scope.row.count }}</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="已派数量">
|
<el-table-column label="已派数量">
|
||||||
<template slot-scope="scope">{{
|
<template slot-scope="scope">{{scope.row.planed_count }}</template>
|
||||||
scope.row.planed_count
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column label="产品型号">
|
<el-table-column label="产品型号">
|
||||||
<template slot-scope="scope">{{
|
<template slot-scope="scope">{{scope.row.product_.specification }}</template>
|
||||||
scope.row.product_.specification
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="客户名称" show-overflow-tooltip width="150">
|
<el-table-column label="客户名称" show-overflow-tooltip width="150">
|
||||||
<template slot-scope="scope">{{
|
<template slot-scope="scope">{{scope.row.customer_.name}}</template>
|
||||||
scope.row.customer_.name
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="合同编号" show-overflow-tooltip width="150">
|
<el-table-column label="合同编号" show-overflow-tooltip width="150">
|
||||||
<template slot-scope="scope" v-if=" scope.row.contract_">{{
|
<template slot-scope="scope" v-if=" scope.row.contract_">{{scope.row.contract_.number }}</template>
|
||||||
scope.row.contract_.number
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="合同名称" show-overflow-tooltip width="150">
|
<el-table-column label="合同名称" show-overflow-tooltip width="150">
|
||||||
<template slot-scope="scope" v-if=" scope.row.contract_">{{
|
<template slot-scope="scope" v-if=" scope.row.contract_">{{scope.row.contract_.name }}</template>
|
||||||
scope.row.contract_.name
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="交货日期" width="110">
|
<el-table-column label="交货日期" width="110">
|
||||||
<template slot-scope="scope">{{
|
<template slot-scope="scope">{{scope.row.delivery_date }}</template>
|
||||||
scope.row.delivery_date
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="创建时间" width="110">
|
<el-table-column label="创建时间" width="110">
|
||||||
<template slot-scope="scope">{{
|
<template slot-scope="scope">{{scope.row.create_time }}</template>
|
||||||
scope.row.create_time
|
|
||||||
}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="计划生产数" width="150px" fixed="right">
|
<el-table-column label="计划生产数" width="150px" fixed="right">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
|
@ -96,7 +68,6 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</el-table>
|
</el-table>
|
||||||
|
|
||||||
<pagination
|
<pagination
|
||||||
v-show="orderList.count > 0"
|
v-show="orderList.count > 0"
|
||||||
:total="orderList.count"
|
:total="orderList.count"
|
||||||
|
@ -127,7 +98,7 @@
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
height="330"
|
:height="domHeight"
|
||||||
ref="multipleTables"
|
ref="multipleTables"
|
||||||
>
|
>
|
||||||
<el-table-column type="selection" width="55"></el-table-column>
|
<el-table-column type="selection" width="55"></el-table-column>
|
||||||
|
@ -194,10 +165,9 @@
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
style="width: 100%"
|
style="width: 100%"
|
||||||
height="280"
|
:height="domHeight"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50"/>
|
<el-table-column type="index" width="50"/>
|
||||||
|
|
||||||
<el-table-column label="设备名称">
|
<el-table-column label="设备名称">
|
||||||
<template slot-scope="scope">{{ scope.row.name }}</template>
|
<template slot-scope="scope">{{ scope.row.name }}</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -268,6 +238,7 @@
|
||||||
components: {Pagination},
|
components: {Pagination},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
domHeight:null,
|
||||||
orderplan: defaulteorderplan,
|
orderplan: defaulteorderplan,
|
||||||
orderList: {
|
orderList: {
|
||||||
count: 0,
|
count: 0,
|
||||||
|
@ -397,5 +368,11 @@
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
mounted() {
|
||||||
|
let hei = document.getElementsByClassName('app-main')[0].clientHeight;//
|
||||||
|
let domHeight = this.domHeight = (hei - 116) / 2;
|
||||||
|
document.getElementById('orderList').style.height = domHeight + 'px';
|
||||||
|
document.getElementById('productionPlan').style.height = domHeight + 'px';
|
||||||
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
@ -43,7 +43,6 @@
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
highlight-current-row
|
highlight-current-row
|
||||||
max-height="700"
|
|
||||||
height="100"
|
height="100"
|
||||||
v-el-height-adaptive-table="{ bottomOffset: 43 }"
|
v-el-height-adaptive-table="{ bottomOffset: 43 }"
|
||||||
>
|
>
|
||||||
|
|
|
@ -43,9 +43,8 @@
|
||||||
fit
|
fit
|
||||||
stripe
|
stripe
|
||||||
highlight-current-row
|
highlight-current-row
|
||||||
max-height="700"
|
|
||||||
height="100"
|
height="100"
|
||||||
v-el-height-adaptive-table="{bottomOffset: 50}"
|
v-el-height-adaptive-table="{bottomOffset: 42}"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50"/>
|
<el-table-column type="index" width="50"/>
|
||||||
<el-table-column label="供应商名" prop="name">
|
<el-table-column label="供应商名" prop="name">
|
||||||
|
|
Loading…
Reference in New Issue