Commit 14251acd authored by renjintao's avatar renjintao

Merge branch 'master' of git.mes123.com:zhouyx/mes-ui

parents 7553a06c 404b8207
...@@ -39,11 +39,11 @@ ...@@ -39,11 +39,11 @@
} }
} }
.ivu-card-head{ .ivu-card-head{
background: #62b8af!important; background: #2d8cf0!important;
} }
} }
.g_title{ .g_title{
color: #249e91; color: #2d8cf0;
} }
} }
.dispatch_card02{ .dispatch_card02{
...@@ -86,9 +86,9 @@ ...@@ -86,9 +86,9 @@
.drawer_center{ .drawer_center{
text-align: center; text-align: center;
padding: 10px; padding: 10px;
color: #249e91; color: #2d8cf0;
.color{ .color{
color: #2680EB; color: #2d8cf0;
} }
} }
} }
...@@ -106,9 +106,9 @@ ...@@ -106,9 +106,9 @@
.drawer_center{ .drawer_center{
text-align: center; text-align: center;
padding: 10px; padding: 10px;
color: #249e91; color: #2d8cf0;
.color{ .color{
color: #2680EB; color: #2d8cf0;
} }
} }
} }
......
...@@ -73,7 +73,7 @@ ...@@ -73,7 +73,7 @@
<Icon <Icon
type="ios-disc" type="ios-disc"
size="18" size="18"
:color="item.id==shebeiId?'#249e91':'#fff'" :color="item.id==shebeiId?'#2d8cf0':'#fff'"
/> />
<input <input
name="shebei" name="shebei"
......
...@@ -59,14 +59,42 @@ ...@@ -59,14 +59,42 @@
width: 40px; width: 40px;
height: 40px; height: 40px;
border-radius: 50%; border-radius: 50%;
background: #249e91; // background: #249e91;
float: left; float: left;
margin: 12px 10px 0 5px; margin: 12px 10px 0 5px;
.img_bg01 {
display: inline-block;
width: 40px;
height: 40px;
border-radius: 50%;
background: #249e91;
}
.img_bg02 {
display: inline-block;
width: 40px;
height: 40px;
border-radius: 50%;
background: #0099FF;
}
.img_bg03 {
display: inline-block;
width: 40px;
height: 40px;
border-radius: 50%;
background: #FF7A8B;
}
.img_bg04 {
display: inline-block;
width: 40px;
height: 40px;
border-radius: 50%;
background: #FFC300;
}
.Icon_bg { .Icon_bg {
text-align: center; text-align: center;
padding: 10px 0 0; padding: 10px 0 0;
img.Icon_icon { img.Icon_icon {
width: 18px; width: 20px;
} }
} }
} }
......
...@@ -18,8 +18,10 @@ ...@@ -18,8 +18,10 @@
:key="index" :key="index"
> >
<div class="leftIcon"> <div class="leftIcon">
<div class="Icon_bg"> <div class="Icon_bg" :class="item.name=='物料复验' ? 'img_bg02':(item.name=='产品合格证' ? 'img_bg03':(item.name=='生产执行' ? 'img_bg04' : 'img_bg01'))" >
<img class="Icon_icon" :src="imgUrl + item.image" alt /> <!-- <div > -->
<img class="Icon_icon" src="@/assets/imgicon/u1640.png" alt="">
<!-- <img class="Icon_icon" :src="imgUrl + item.image" alt /> -->
</div> </div>
</div> </div>
<div class="h60"> <div class="h60">
......
<style>
/* @font-face {
font-family: 'iconfont';
src: url('./iconfont/iconfont.eot');
src: url('./iconfont/iconfont.eot?#iefix') format('embedded-opentype'),
url('./iconfont/iconfont.woff2') format('woff2'),
url('./iconfont/iconfont.woff') format('woff'),
url('./iconfont/iconfont.ttf') format('truetype'),
url('./iconfont/iconfont.svg#iconfont') format('svg');
}
.iconfont {
font-family: "iconfont" !important;
font-size: 32px;
font-weight: bold;
/* font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
color:#249e91;
} */
.img_bg {
display: inline-block;
width: 48px;
height: 48px;
border-radius: 50%;
background: #249e91;
}
.img_icon {
width: 24px;
margin: 23% 0 0 0;
}
</style>
<template> <template>
<div style="width:100%"> <div style="width:100%">
<Card <Card
...@@ -41,9 +11,9 @@ ...@@ -41,9 +11,9 @@
<div class="leftIco"> <div class="leftIco">
<!-- color:rgba(36, 158, 145, 1) --> <!-- color:rgba(36, 158, 145, 1) -->
<!-- <span class="iconfont">&#xe607;</span> --> <!-- <span class="iconfont">&#xe607;</span> -->
<div class="img_bg"> <div :class="item.name=='物料复验' ? 'img_bg02':(item.name=='产品合格证' ? 'img_bg03':(item.name=='生产执行' ? 'img_bg04' : 'img_bg01'))" >
<img class="img_icon" :src="imgUrl + item.image" alt /> <!-- <img class="img_icon" :src="imgUrl + item.image" alt /> -->
<!-- <img class="img_icon" src="@/assets/imgicon/u1650.png" alt=""> --> <img class="img_icon" src="@/assets/imgicon/u1640.png" alt="">
</div> </div>
<!-- <command icon="@/assets/imgicon/u1638.png"> --> <!-- <command icon="@/assets/imgicon/u1638.png"> -->
<!-- <Icon type="md-analytics" size="36" color="#249e91" /> --> <!-- <Icon type="md-analytics" size="36" color="#249e91" /> -->
...@@ -82,6 +52,7 @@ export default { ...@@ -82,6 +52,7 @@ export default {
return (data.totalUrl = r.result) return (data.totalUrl = r.result)
}) })
}) })
console.log(list)
this.listTask = list this.listTask = list
}) })
}, },
...@@ -93,6 +64,38 @@ export default { ...@@ -93,6 +64,38 @@ export default {
} }
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>
.img_bg01 {
display: inline-block;
width: 48px;
height: 48px;
border-radius: 50%;
background: #249e91;
}
.img_bg02 {
display: inline-block;
width: 48px;
height: 48px;
border-radius: 50%;
background: #0099FF;
}
.img_bg03 {
display: inline-block;
width: 48px;
height: 48px;
border-radius: 50%;
background: #FF7A8B;
}
.img_bg04 {
display: inline-block;
width: 48px;
height: 48px;
border-radius: 50%;
background: #FFC300;
}
.img_icon {
width: 24px;
margin: 23% 0 0 0;
}
.waitTask { .waitTask {
cursor: pointer; cursor: pointer;
margin-bottom: 10px; margin-bottom: 10px;
......
...@@ -33,14 +33,14 @@ ...@@ -33,14 +33,14 @@
</div> </div>
</template> </template>
<script> <script>
import Api from './api' import Api from "./api";
import Suspend from './suspend' import Suspend from "./suspend";
import Record from './record' import Record from "./record";
import Search from './search' import Search from "./search";
import Speed from './speed' import Speed from "./speed";
export default { export default {
name: 'index', name: "index",
components: { components: {
Record, Record,
Search, Search,
...@@ -53,67 +53,68 @@ export default { ...@@ -53,67 +53,68 @@ export default {
SpeedModal: false, SpeedModal: false,
rowSuspend: {}, rowSuspend: {},
recordId: 0, recordId: 0,
laster: 0,
action: Api.index, action: Api.index,
easySearch: { easySearch: {
keys: { op: 'mesCode', value: null }, keys: { op: "mesCode", value: null },
productingpreparationpeople: { op: 'Equal', value: null } productingpreparationpeople: { op: "Equal", value: null }
}, },
suspendModal: false, suspendModal: false,
recordModal: false, recordModal: false,
deletelModal: false, deletelModal: false,
curId: 0, curId: 0,
columns: [ columns: [
{ key: 'id', title: this.l('id'), hide: true, align: 'left' }, { key: "id", title: this.l("id"), hide: true, align: "left" },
{ {
key: 'status', key: "status",
title: this.l('status'), title: this.l("status"),
code: 'plan.order.status', code: "plan.order.status",
align: 'center', align: "center",
easy: true, easy: true,
high: true high: true
}, },
{ {
key: 'mesCode', key: "mesCode",
title: this.l('mesCode'), title: this.l("mesCode"),
align: 'left', align: "left",
width: 230, width: 230,
render: (h, params) => { render: (h, params) => {
return h('div', [ return h("div", [
params.row.mesCode, params.row.mesCode,
[ [
h( h(
'Poptip', "Poptip",
{ {
props: { props: {
content: '开工预警:' + params.row.startWarning + '条', content: "开工预警:" + params.row.startWarning + "条",
trigger: 'hover' trigger: "hover"
}, },
style: { style: {
cursor: 'pointer' cursor: "pointer"
} }
}, },
[ [
h( h(
params.row.startWarning > 0 ? 'Badge' : '', params.row.startWarning > 0 ? "Badge" : "",
{ {
props: { props: {
type: 'warning', type: "warning",
// count: 2, // count: 2,
count: params.row.startWarning count: params.row.startWarning
}, },
style: { style: {
marginTop: '12px', marginTop: "12px",
marginLeft: '5px' marginLeft: "5px"
} }
}, },
[ [
h('Icon', { h("Icon", {
props: { props: {
type: 'md-alert' type: "md-alert"
}, },
style: { style: {
fontSize: '16px', fontSize: "16px",
color: '#f1cb08' color: "#f1cb08"
} }
}) })
] ]
...@@ -121,36 +122,36 @@ export default { ...@@ -121,36 +122,36 @@ export default {
] ]
), ),
h( h(
'Poptip', "Poptip",
{ {
props: { props: {
content: '完工预警:' + params.row.finishWarning + '条', content: "完工预警:" + params.row.finishWarning + "条",
trigger: 'hover' trigger: "hover"
} }
}, },
[ [
h( h(
params.row.finishWarning > 0 ? 'Badge' : '', params.row.finishWarning > 0 ? "Badge" : "",
{ {
props: { props: {
type: 'info', type: "info",
// count: 2, // count: 2,
count: params.row.finishWarning count: params.row.finishWarning
}, },
style: { style: {
marginTop: '12px', marginTop: "12px",
marginLeft: '5px' marginLeft: "5px"
} }
}, },
[ [
h('Icon', { h("Icon", {
props: { props: {
type: 'md-alert' type: "md-alert"
}, },
style: { style: {
fontSize: '16px', fontSize: "16px",
color: '#31F8E6', color: "#31F8E6",
marginLeft: '5px' marginLeft: "5px"
} }
}) })
] ]
...@@ -158,111 +159,111 @@ export default { ...@@ -158,111 +159,111 @@ export default {
] ]
) )
] ]
]) ]);
} }
}, },
{ {
key: 'productName', key: "productName",
title: this.l('productName'), title: this.l("productName"),
align: 'left', align: "left",
easy: true, easy: true,
high: true, high: true,
width: 130 width: 130
}, },
{ {
key: 'demandStartDate', key: "demandStartDate",
title: this.l('demandStartDate'), title: this.l("demandStartDate"),
align: 'center', align: "center",
high: true, high: true,
width: 130, width: 130,
render: (h, params) => { render: (h, params) => {
return h( return h(
'span', "span",
this.sliceStr(params.row.demandStartDate + ' ', 0, 10), this.sliceStr(params.row.demandStartDate + " ", 0, 10),
params.row.demandStartDate params.row.demandStartDate
) );
} }
}, },
{ {
key: 'demandFinishDate', key: "demandFinishDate",
title: this.l('demandFinishDate'), title: this.l("demandFinishDate"),
align: 'center', align: "center",
high: true, high: true,
width: 130, width: 130,
render: (h, params) => { render: (h, params) => {
return h( return h(
'span', "span",
this.sliceStr(params.row.demandFinishDate + ' ', 0, 10), this.sliceStr(params.row.demandFinishDate + " ", 0, 10),
params.row.demandFinishDate params.row.demandFinishDate
) );
} }
}, },
{ {
key: 'actualStartDate', key: "actualStartDate",
title: this.l('actualStartDate'), title: this.l("actualStartDate"),
align: 'center', align: "center",
high: true, high: true,
width: 150, width: 150,
render: (h, params) => { render: (h, params) => {
return h( return h(
'span', "span",
// this.sliceStr(params.row.actualStartDate + ' ', 0, 10), // this.sliceStr(params.row.actualStartDate + ' ', 0, 10),
params.row.actualStartDate == '0001-01-01 00:00:00' params.row.actualStartDate == "0001-01-01 00:00:00"
? '' ? ""
: params.row.actualStartDate : params.row.actualStartDate
) );
} }
}, },
{ {
key: 'actualFinishDate', key: "actualFinishDate",
title: this.l('actualFinishDate'), title: this.l("actualFinishDate"),
align: 'center', align: "center",
high: true, high: true,
width: 150, width: 150,
render: (h, params) => { render: (h, params) => {
return h( return h(
'span', "span",
// this.sliceStr(params.row.actualFinishDate + ' ', 0, 10), // this.sliceStr(params.row.actualFinishDate + ' ', 0, 10),
params.row.actualFinishDate == '0001-01-01 00:00:00' params.row.actualFinishDate == "0001-01-01 00:00:00"
? '' ? ""
: params.row.actualFinishDate : params.row.actualFinishDate
) );
} }
}, },
{ {
key: 'routingType', key: "routingType",
title: this.l('routingType'), title: this.l("routingType"),
align: 'left', align: "left",
code: 'mes_xingchi_plan.order_material.routingType', code: "mes_xingchi_plan.order_material.routingType",
easy: true, easy: true,
high: true high: true
}, },
{ {
title: this.l('jindu'), title: this.l("jindu"),
key: 'action', key: "action",
width: 200, width: 200,
align: 'center', align: "center",
render: (h, params) => { render: (h, params) => {
return h('div', [ return h("div", [
h( h(
'ButtonGroup', "ButtonGroup",
{ {
props: { props: {
shape: 'circle' shape: "circle"
} }
}, },
[ [
h( h(
'Button', "Button",
{ {
style: { style: {
background: '#e4e6ed ', background: "#e4e6ed ",
borderColor: '#e4e6ed ' borderColor: "#e4e6ed "
}, },
on: { on: {
click: () => { click: () => {
this.speed(params.row) this.speed(params.row);
} }
} }
}, },
...@@ -270,15 +271,15 @@ export default { ...@@ -270,15 +271,15 @@ export default {
params.row.unstartCount //未开工数 params.row.unstartCount //未开工数
), ),
h( h(
'Button', "Button",
{ {
style: { style: {
background: '#ffc000', background: "#ffc000",
borderColor: '#ffc000' borderColor: "#ffc000"
}, },
on: { on: {
click: () => { click: () => {
this.speed(params.row) this.speed(params.row);
} }
} }
}, },
...@@ -286,17 +287,17 @@ export default { ...@@ -286,17 +287,17 @@ export default {
params.row.startCount //开工数 params.row.startCount //开工数
), ),
h( h(
'Button', "Button",
{ {
style: { style: {
background: '#ff7a8b', background: "#ff7a8b",
borderColor: '#ff7a8b' borderColor: "#ff7a8b"
}, },
on: { on: {
click: () => { click: () => {
this.speed(params.row) this.speed(params.row);
} }
} }
}, },
...@@ -304,16 +305,16 @@ export default { ...@@ -304,16 +305,16 @@ export default {
params.row.stopCount //暂停数 params.row.stopCount //暂停数
), ),
h( h(
'Button', "Button",
{ {
style: { style: {
background: '#27c149', background: "#27c149",
borderColor: '#27c149' borderColor: "#27c149"
// color: '#fff' // color: '#fff'
}, },
on: { on: {
click: () => { click: () => {
this.speed(params.row) this.speed(params.row);
} }
} }
}, },
...@@ -322,176 +323,176 @@ export default { ...@@ -322,176 +323,176 @@ export default {
) )
] ]
) )
]) ]);
} }
}, },
{ {
key: 'remark', key: "remark",
title: this.l('remark'), title: this.l("remark"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true
}, },
{ {
title: '暂停记录', title: "暂停记录",
key: 'id', key: "id",
width: 140, width: 140,
align: 'center', align: "center",
render: (h, params) => { render: (h, params) => {
return h('div', { class: 'action' }, [ return h("div", { class: "action" }, [
h( h(
'op', "op",
{ {
attrs: { oprate: 'record', class: 'edit' }, attrs: { oprate: "record", class: "edit" },
on: { click: () => this.record(params.row.id) } on: { click: () => this.record(params.row.id) }
}, },
'暂停记录' "暂停记录"
) )
]) ]);
} }
}, },
{ {
title: '操作', title: "操作",
key: 'id', key: "id",
width: 100, width: 100,
align: 'center', align: "center",
render: (h, params) => { render: (h, params) => {
return h('div', { class: 'action' }, [ return h("div", { class: "action" }, [
h( h(
params.row.status == 5 ? 'Button' : '', //订单状态暂停,启动 params.row.status == 5 ? "Button" : "", //订单状态暂停,启动
{ {
props: { props: {
type: 'error', type: "error",
size: 'small', size: "small",
icon: 'md-play', icon: "md-play",
ghost: true ghost: true
}, },
style: { style: {
fontSize: '18px', fontSize: "18px",
width: '50px', width: "50px",
height: '25px', height: "25px",
paddingTop: '0' paddingTop: "0"
}, },
on: { on: {
click: () => { click: () => {
this.start(params.row) this.start(params.row);
} }
} }
}, },
'' ""
), ),
h( h(
params.row.status == 6 ? 'Button' : '', //订单状态执行中,暂停 params.row.status == 6 ? "Button" : "", //订单状态执行中,暂停
{ {
props: { props: {
type: 'default', type: "default",
size: 'small', size: "small",
icon: 'ios-pause', icon: "ios-pause",
ghost: true ghost: true
}, },
style: { style: {
fontSize: '18px', fontSize: "18px",
width: '50px', width: "50px",
height: '25px', height: "25px",
paddingTop: '0' paddingTop: "0"
}, },
on: { on: {
click: () => { click: () => {
this.suspend(params.row) this.suspend(params.row);
} }
} }
}, },
'' ""
) )
]) ]);
} }
} }
] ]
} };
}, },
mounted() {}, mounted() {},
async fetch({ store, params }) { async fetch({ store, params }) {
await store.dispatch('loadDictionary') // 加载数据字典 await store.dispatch("loadDictionary"); // 加载数据字典
}, },
methods: { methods: {
search() { search() {
this.$refs.grid.reload(this.easySearch) this.$refs.grid.reload(this.easySearch);
}, },
record(id) { record(id) {
this.recordModal = true this.recordModal = true;
this.recordId = id this.recordId = id;
}, },
speed(row) { speed(row) {
this.SpeedModal = true this.SpeedModal = true;
Api.info({ Api.info({
routingHeaderId: row.routingHeaderId, routingHeaderId: row.routingHeaderId,
dispatchExecuteId: row.dispatchExecuteId dispatchExecuteId: row.dispatchExecuteId
}).then((r) => { }).then(r => {
if (r.success) { if (r.success) {
this.result = r.result this.result = r.result;
} }
}) });
}, },
suspendOk() { suspendOk() {
this.suspendModal = false this.suspendModal = false;
this.$refs.grid.load() this.$refs.grid.load();
// this.curId = 0 // this.curId = 0
}, },
start(row) { start(row) {
console.log(JSON.parse(localStorage.getItem('userInfo'))) this.laster = this.$store.state.userInfo.login_id;
this.$Modal.confirm({ this.$Modal.confirm({
title: '提示', title: "提示",
content: '<p>确定要启动,是否继续?</p>', content: "<p>确定要启动,是否继续?</p>",
onOk: () => { onOk: () => {
Api.start({ Api.start({
id: row.id, id: row.id,
status: 6, status: 6,
laster: this.$store.state.userInfo.login_id laster: this.laster
}).then((r) => { }).then(r => {
if (r.success) { if (r.success) {
this.$refs.grid.load() this.$refs.grid.load();
this.$Message.success('启动成功') this.$Message.success("启动成功");
} }
}) });
// this.suspendModal = true // this.suspendModal = true
// this.curId = id // this.curId = id
}, },
onCancel: () => { onCancel: () => {
this.$Message.info('已取消') this.$Message.info("已取消");
} }
}) });
}, },
suspend(row) { suspend(row) {
console.log(row) console.log(row);
this.suspendModal = true this.suspendModal = true;
this.rowSuspend = row this.rowSuspend = row;
this.$refs.addBug.getEid() this.$refs.addBug.getEid();
}, },
removeOk() { removeOk() {
Api.delete({ id: this.curId }).then((r) => { Api.delete({ id: this.curId }).then(r => {
if (r.success) { if (r.success) {
this.$refs.grid.load() this.$refs.grid.load();
this.deletelModal = false this.deletelModal = false;
this.$Message.success('删除成功') this.$Message.success("删除成功");
} }
}) });
}, },
//截取字符串 //截取字符串
sliceStr(str, lenS, lenE) { sliceStr(str, lenS, lenE) {
return str.slice(lenS, lenE) return str.slice(lenS, lenE);
}, },
cancel() { cancel() {
this.curId = 0 this.curId = 0;
this.suspendModal = false this.suspendModal = false;
}, },
l(key) { l(key) {
let vkey = 'mes_order_watch' + '.' + key let vkey = "mes_order_watch" + "." + key;
return this.$t(vkey) || key return this.$t(vkey) || key;
} }
} }
} };
</script> </script>
<style lang="less"> <style lang="less">
.ivu-btn-group > .ivu-btn { .ivu-btn-group > .ivu-btn {
......
...@@ -145,7 +145,6 @@ import PhotosensitiveDetails from "./components/photosensitiveDetails.vue"; // ...@@ -145,7 +145,6 @@ import PhotosensitiveDetails from "./components/photosensitiveDetails.vue"; //
import MetalQuotationGeneration from "./components/metalQuotationGeneration.vue"; //生成报价单弹框 import MetalQuotationGeneration from "./components/metalQuotationGeneration.vue"; //生成报价单弹框
import PhotosensitiveGeneration from "./components/photosensitiveGeneration.vue"; //生成报价单弹框 import PhotosensitiveGeneration from "./components/photosensitiveGeneration.vue"; //生成报价单弹框
var userId = this.$store.state.userInfo.userId
export default { export default {
components: { components: {
DrawerSet, DrawerSet,
...@@ -164,6 +163,7 @@ export default { ...@@ -164,6 +163,7 @@ export default {
zPhotosensitive: { zPhotosensitive: {
result: [] result: []
}, },
userId: 0,
model1: "", model1: "",
rows: {}, rows: {},
modalDai: false, //待审核 modalDai: false, //待审核
...@@ -638,8 +638,9 @@ export default { ...@@ -638,8 +638,9 @@ export default {
}, },
//报价状态 //报价状态
statusData(row) { statusData(row) {
this.userId = this.$store.state.userInfo.userId;
if (row.status === 2) { if (row.status === 2) {
if (row.auditUser == userId) { if (row.auditUser == this.userId) {
//待审核 //待审核
this.modalDai = true; this.modalDai = true;
this.rows = {}; this.rows = {};
...@@ -648,7 +649,7 @@ export default { ...@@ -648,7 +649,7 @@ export default {
this.$Message.error("您不是当前数据处理的指定人员"); this.$Message.error("您不是当前数据处理的指定人员");
} }
} else if (row.status === 1) { } else if (row.status === 1) {
if (row.creatorUserId == userId) { if (row.creatorUserId == this.userId) {
//待送审 //待送审
this.modalSong = true; this.modalSong = true;
this.rows = {}; this.rows = {};
......
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