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