Commit 77013c07 authored by renjintao's avatar renjintao

Merge branch 'product' of git.mes123.com:zhouyx/mes-ui into product-rjt

parents 68beba9d f3cfc179
......@@ -23,7 +23,7 @@
<Checkbox
v-model="li.checked"
@on-change="checkData(li)"
:disabled="isdisabled"
:disabled="li.status==0?false:true"
>订单号:{{li.mesCode}}</Checkbox>
</Col>
<Col :span="4" class="order-ringht">
......@@ -114,7 +114,7 @@
</FormItem>
<FormItem>
<Button style="margin-left: 8px" @click="closeOk">取消</Button>
<Button type="primary" @click="lowerHair">下发</Button>
<Button type="primary" @click="lowerHair" v-if="showXia">下发</Button>
</FormItem>
</Form>
</div>
......@@ -135,8 +135,8 @@ export default {
data() {
return {
list: [],
showXia: true,
status: "0", //全部排产-1,0为未排产;2为已排查;
isdisabled: false,
formItem: {
radio: "0",
time: "",
......@@ -192,10 +192,10 @@ export default {
changeStatus(name) {
this.status = name;
this.orderlist(this.status);
if (this.status == 1) {
this.isdisabled = true;
if (this.status == 0) {
this.showXia = true;
} else {
this.isdisabled = false;
this.showXia = false;
}
},
//排产池列表
......
<template>
<div class="compare">
<div class="btn">
<Button type="primary" @click="parameter">下发</Button>
<!-- <Button type="primary">导出</Button>000 -->
<Button type="primary" icon="ios-redo" @click="comeBlck">返回</Button>
</div>
<div class="compare_box">
<div class="left_list">
</div>
<div class="right_add"></div>
</div>
</div>
</template>
<script>
import Api from "./api";
export default {
data() {
return {
code: '2',
name: '添加',
tree: []
}
},
async fetch({ store, params }) {
await store.dispatch('loadDictionary') // 加载数据字典
},
components: {},
created() {},
mounted() {},
methods: {
// 下发
parameter() {
Api.processschemedispatch({
id: this.id
}).then(r => {
if (r.result) {
this.$Message.success(r.result.retmsg);
this.orderlist();
} else {
this.$Message.success("下发失败");
}
});
},
// 返回
comeBlck() {
this.$router.push({ path: "/aps/aps" });
},
tabChange(name) {
if(name=='technicalcoordination')
{
this.$refs.technicalcoordination.loadchangelist();
}
if(name=='unqualifiedorder')
{
this.$refs.unqualifiedorder.loadchangelist();
}
},
}
}
</script>
<style lang="less">
</style>
<style lang="less">
@import './results.less';
</style>
<template>
<div class="results">
<Layout>
......@@ -26,25 +29,36 @@
</div>
</Sider>
<Content>
<h4>排产结果</h4>
<Tabs value="name1" :animated="false">
<TabPane label="结果列表" name="name1">
<resultsList ref="resultsList"/>
</TabPane>
<!-- <TabPane label="结果甘特图" name="name2">结果甘特图</TabPane> -->
<TabPane label="方案对比" name="name3">
<compareList ref="compareList"/>
</TabPane>
</Tabs>
<!-- <h4>排产结果</h4>
<div class="btn">
<Button type="primary" @click="parameter">下发</Button>
<!-- <Button type="primary">导出</Button> -->
<Button type="primary" icon="ios-redo" @click="comeBlck">返回</Button>
<Button type="primary" @click="parameter">下发</Button> -->
<!-- <Button type="primary">导出</Button>000 -->
<!-- <Button type="primary" icon="ios-redo" @click="comeBlck">返回</Button>
</div>
<div>
<Table :columns="columns" :data="data"></Table>
</div>
</div> -->
</Content>
</Layout>
</div>
</template>
<script>
import Api from "./api";
import expandRow from "./table-expand.vue";
// import expandRow from "./table-expand.vue";expandRow,
import resultsList from "./result.vue";
import compareList from "./compare.vue";
export default {
components: { expandRow },
components: { resultsList,compareList },
data() {
return {
......@@ -52,81 +66,81 @@ export default {
data: [],
list: [],
id: "",
columns: [
{
type: "expand",
width: 50,
render: (h, params) => {
return h(expandRow, {
props: {
row: params.row
}
});
}
},
{
title: "超期预警",
key: "alert",
align: "center",
render: (h, params) => {
return h("div", [
h("Icon", {
props: {
type:
params.row.alert == true
? "ios-information-circle-outline"
: "ios-remove-circle-outline"
},
style: {
marginRight: "5px",
fontSize: "18px",
fontWeight: "bold",
color: params.row.alert == true ? "#FE7777" : "#0DD78D"
}
})
]);
}
},
{
title: "零件图号",
key: "part_id",
align: "center"
},
{
title: "零件名称",
key: "part_name",
align: "center"
},
{
title: "计划开始时间",
key: "plan_start",
width: 200,
align: "center"
},
{
title: "计划结束时间",
key: "plan_start",
width: 200,
align: "center"
},
{
title: "投料时间",
key: "demand_start",
width: 200,
align: "center"
},
{
title: "节点时间",
key: "demand_finish",
width: 200,
align: "center"
},
{
title: "计划数量",
key: "plan_qty",
align: "center"
}
]
// columns: [
// {
// type: "expand",
// width: 50,
// render: (h, params) => {
// return h(expandRow, {
// props: {
// row: params.row
// }
// });
// }
// },
// {
// title: "超期预警",
// key: "alert",
// align: "center",
// render: (h, params) => {
// return h("div", [
// h("Icon", {
// props: {
// type:
// params.row.alert == true
// ? "ios-information-circle-outline"
// : "ios-remove-circle-outline"
// },
// style: {
// marginRight: "5px",
// fontSize: "18px",
// fontWeight: "bold",
// color: params.row.alert == true ? "#FE7777" : "#0DD78D"
// }
// })
// ]);
// }
// },
// {
// title: "零件图号",
// key: "part_id",
// align: "center"
// },
// {
// title: "零件名称",
// key: "part_name",
// align: "center"
// },
// {
// title: "计划开始时间",
// key: "plan_start",
// width: 200,
// align: "center"
// },
// {
// title: "计划结束时间",
// key: "plan_start",
// width: 200,
// align: "center"
// },
// {
// title: "投料时间",
// key: "demand_start",
// width: 200,
// align: "center"
// },
// {
// title: "节点时间",
// key: "demand_finish",
// width: 200,
// align: "center"
// },
// {
// title: "计划数量",
// key: "plan_qty",
// align: "center"
// }
// ]
};
},
async fetch({ store, params }) {
......@@ -202,60 +216,4 @@ export default {
}
}
};
</script>
<style lang="less" scoped>
.results {
font-family: Microsoft YaHei;
.ivu-layout-sider {
background: none;
height: 90vh;
border-right: 1px solid #e4e6ed;
.btn {
float: right;
margin-top: -44px;
margin-right: 15px;
}
}
.addclass {
border-color: #2680eb !important;
}
h4 {
height: 38px;
line-height: 38px;
border-bottom: 1px solid #e4e6ed;
margin-bottom: 15px;
margin-right: 15px;
}
.left-body:hover {
cursor: pointer;
border-color: #2680eb;
}
.left-body {
margin: 10px 15px 0 0;
border: 1px solid rgba(228, 230, 237, 1);
border-radius: 4px;
padding: 5px 8px;
.title-t {
height: 30px;
line-height: 30px;
color: #2680eb;
font-size: 15px;
font-weight: bold;
}
.fa {
height: 30px;
line-height: 30px;
}
}
.ivu-layout-content {
margin-left: 15px;
.btn {
float: right;
margin-top: -52px;
margin-right: 15px;
}
}
}
</style>
\ No newline at end of file
</script>
\ No newline at end of file
<style lang="less">
@import './results.less';
</style>
<template>
<div>
<div class="btn">
<Button type="primary" @click="parameter">下发</Button>
<!-- <Button type="primary">导出</Button>000 -->
<Button type="primary" icon="ios-redo" @click="comeBlck">返回</Button>
</div>
<div>
<Table :columns="columns" :data="data"></Table>
</div>
</div>
</template>
<script>
import Api from "./api";
import expandRow from "./table-expand.vue";
export default {
components: { expandRow },
data() {
return {
isactive: 0,
data: [],
list: [],
columns: [
{
type: "expand",
width: 50,
render: (h, params) => {
return h(expandRow, {
props: {
row: params.row
}
});
}
},
{
title: "超期预警",
key: "alert",
align: "center",
render: (h, params) => {
return h("div", [
h("Icon", {
props: {
type:
params.row.alert == true
? "ios-information-circle-outline"
: "ios-remove-circle-outline"
},
style: {
marginRight: "5px",
fontSize: "18px",
fontWeight: "bold",
color: params.row.alert == true ? "#FE7777" : "#0DD78D"
}
})
]);
}
},
{
title: "零件图号",
key: "part_id",
align: "center"
},
{
title: "零件名称",
key: "part_name",
align: "center"
},
{
title: "计划开始时间",
key: "plan_start",
width: 200,
align: "center"
},
{
title: "计划结束时间",
key: "plan_start",
width: 200,
align: "center"
},
{
title: "投料时间",
key: "demand_start",
width: 200,
align: "center"
},
{
title: "节点时间",
key: "demand_finish",
width: 200,
align: "center"
},
{
title: "计划数量",
key: "plan_qty",
align: "center"
}
],
}
},
async fetch({ store, params }) {
await store.dispatch('loadDictionary') // 加载数据字典
},
components: {},
created() {
this.orderlist();
},
mounted() {},
methods: {
orderlist() {
Api.getall()
.then(r => {
if (r.success) {
this.list = r.result;
if (r.result) {
this.listData(r.result[0].schedule_Id, 0);
} else {
this.listData(0, null);
}
}
})
.catch(error => {
this.$$Message.error("请求失败");
});
},
listData(id, index) {
this.$emit.isactive = index;
this.id = id;
Api.paged({ scheduleId: id })
.then(r => {
if (r.success) {
this.data = r.result;
}
})
.catch(error => {
this.$$Message.error("请求失败");
});
},
// 下发
parameter() {
Api.processschemedispatch({
id: this.id
}).then(r => {
if (r.result) {
this.$Message.success(r.result.retmsg);
this.orderlist();
} else {
this.$Message.success("下发失败");
}
});
},
// 返回
comeBlck() {
this.$router.push({ path: "/aps/aps" });
},
tabChange(name) {
if(name=='technicalcoordination')
{
this.$refs.technicalcoordination.loadchangelist();
}
if(name=='unqualifiedorder'){
this.$refs.unqualifiedorder.loadchangelist();
}
},
}
}
</script>
<style lang="less">
</style>
.results {
font-family: Microsoft YaHei;
.ivu-layout-sider {
background: none;
height: 90vh;
border-right: 1px solid #e4e6ed;
.btn {
float: right;
margin-top: -44px;
margin-right: 15px;
}
}
.addclass {
border-color: #2680eb !important;
}
h4 {
height: 38px;
line-height: 38px;
border-bottom: 1px solid #e4e6ed;
margin-bottom: 15px;
margin-right: 15px;
}
.left-body:hover {
cursor: pointer;
border-color: #2680eb;
}
.left-body {
margin: 10px 15px 0 0;
border: 1px solid rgba(228, 230, 237, 1);
border-radius: 4px;
padding: 5px 8px;
.title-t {
height: 30px;
line-height: 30px;
color: #2680eb;
font-size: 15px;
font-weight: bold;
}
.fa {
height: 30px;
line-height: 30px;
}
}
.ivu-layout-content {
margin-left: 15px;
.btn {
float: right;
margin-top: -52px;
margin-right: 15px;
}
}
}
.compare{
.compare_box{
border: 1px solid #ccc;
height: 200px;
}
}
\ No newline at end of file
......@@ -23,7 +23,7 @@
<span class="expand-key">设备编号</span>
</Col>
</Row>
<Row v-for="(item,index) in dataList" :key="item.id">
<Row v-for="(item,index) in dataList" :key="item.index">
<Col span="4" class="expand-value">
<span>{{ item.task_seq }}</span>
</Col>
......
......@@ -7,7 +7,7 @@
<RadioGroup v-model="status" type="button" @on-change="changeStatus" size="small">
<Radio label="0">未排产</Radio>
<Radio label="2">已排查</Radio>
<Radio label="-1">全部</Radio>
<!-- <Radio label="-1">全部</Radio> -->
</RadioGroup>
</Col>
</Row>
......@@ -48,7 +48,7 @@
<Radio :label="1">一级排产</Radio>
<Radio :label="2">二级排产</Radio>
</RadioGroup>
<Button type="primary" @click="lowerHair" :disabled="!allow">下发</Button>
<Button type="primary" @click="lowerHair" :disabled="!allow" v-if="showXia">下发</Button>
</Col>
</Row>
<Row class="right-body">
......@@ -144,6 +144,7 @@ export default {
},
data() {
return {
showXia: true,
disabled: false,
chaiLIst: [],
mode: 1,
......@@ -176,6 +177,11 @@ export default {
this.orderlist(this.status);
this.orderId = 0;
this.isactive = null;
if (this.status == 0) {
this.showXia = true;
} else {
this.showXia = false;
}
},
//排产池列表
......
......@@ -99,6 +99,8 @@ export default {
this.formItem.equip_id = r.result.code;
this.formItem1.calendarwork_pk = r.result.calKey;
this.formItem2.calendarovertime_pk = r.result.holidayKey;
this.formItem1.equip_pk = r.result.id;
this.formItem2.equip_pk = r.result.id;
});
},
handleSubmit() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment