Commit b7e3cfbd authored by 周远喜's avatar 周远喜

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

parents fc4618eb fdf5d990
...@@ -156,7 +156,7 @@ export default { ...@@ -156,7 +156,7 @@ export default {
}, },
// 加载物料 // 加载物料
materiallist() { materiallist() {
let url = `${systemUrl}/material/materiallist`; let url = `${material}/material/materiallist`;
this.$api this.$api
.post(url, { .post(url, {
// pageIndex: 1, // pageIndex: 1,
......
...@@ -36,13 +36,13 @@ ...@@ -36,13 +36,13 @@
</div> </div>
</template> </template>
<script> <script>
import Api from './api' import Api from "./api";
import Add from './add' import Add from "./add";
import Edit from './edit' import Edit from "./edit";
import Detail from './detail' import Detail from "./detail";
import Search from './search' import Search from "./search";
export default { export default {
name: 'list', name: "list",
components: { components: {
Add, Add,
Edit, Edit,
...@@ -54,8 +54,7 @@ export default { ...@@ -54,8 +54,7 @@ export default {
action: Api.index, action: Api.index,
easySearch: { easySearch: {
keys: { keys: {
op: op: "name,telephone",
'name,telephone',
value: null value: null
} }
}, },
...@@ -65,258 +64,262 @@ export default { ...@@ -65,258 +64,262 @@ export default {
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: 'creationTime', key: "creationTime",
title: this.l('creationTime'), title: this.l("creationTime"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'creatorUserId', key: "creatorUserId",
title: this.l('creatorUserId'), title: this.l("creatorUserId"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'lastModificationTime', key: "lastModificationTime",
title: this.l('lastModificationTime'), title: this.l("lastModificationTime"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'lastModifierUserId', key: "lastModifierUserId",
title: this.l('lastModifierUserId'), title: this.l("lastModifierUserId"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'isDeleted', key: "isDeleted",
title: this.l('isDeleted'), title: this.l("isDeleted"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'deletionTime', key: "deletionTime",
title: this.l('deletionTime'), title: this.l("deletionTime"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'deleterUserId', key: "deleterUserId",
title: this.l('deleterUserId'), title: this.l("deleterUserId"),
hide: true, hide: true,
align: 'left' align: "left"
}, },
{ {
key: 'name', key: "name",
title: this.l('name'), title: this.l("name"),
align: 'left', align: "left",
easy: true, easy: true,
high: true, high: true,
width: 160,
tooltip: true tooltip: true
}, },
{ {
key: 'abbre', key: "abbre",
title: this.l('abbre'), title: this.l("abbre"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true,
hide: true
}, },
{ {
key: 'address', key: "address",
title: this.l('address'), title: this.l("address"),
align: 'left', align: "left",
easy: true, easy: true,
high: true, high: true,
width: 120, width: 120,
tooltip: true, tooltip: true,
hide:true, hide: true
}, },
{ {
key: 'principal', key: "principal",
title: this.l('principal'), title: this.l("principal"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true
}, },
{ {
key: 'telephone', key: "telephone",
title: this.l('telephone'), title: this.l("telephone"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true
}, },
{ {
key: 'mobile', key: "mobile",
title: this.l('mobile'), title: this.l("mobile"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true
}, },
{ {
key: 'type', key: "type",
title: this.l('type'), title: this.l("type"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true,
hide: true
}, },
{ {
key: 'area', key: "area",
title: this.l('area'), title: this.l("area"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true,
hide: true
}, },
{ {
key: 'isInform', key: "isInform",
title: this.l('isInform'), title: this.l("isInform"),
align: 'center', align: "center",
high: true, high: true,
code: 'crm.customer.isInform', code: "crm.customer.isInform",
width:120, width: 120
}, },
{ {
key: 'status', key: "status",
title: this.l('status'), title: this.l("status"),
align: 'center', align: "center",
high: true, high: true,
code: 'crm.customer.status', code: "crm.customer.status",
width:120, width: 120
}, },
{ {
key: 'notes', key: "notes",
title: this.l('notes'), title: this.l("notes"),
align: 'left', align: "left",
easy: true, easy: true,
high: true, high: true,
tooltip: true, tooltip: true,
hide:true, hide: true
}, },
{ {
key: 'code', key: "code",
title: this.l('code'), title: this.l("code"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true,
hide: true
}, },
{ {
key: 'trade', key: "trade",
title: this.l('trade'), title: this.l("trade"),
align: 'left', align: "left",
easy: true, easy: true,
high: true high: true,
hide: true
}, },
{ {
title: '操作', title: "操作",
key: 'action', key: "action",
width: 180, width: 180,
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: 'detail' }, attrs: { oprate: "detail" },
on: { click: () => this.detail(params.row.id) } on: { click: () => this.detail(params.row.id) }
}, },
'查看' "查看"
), ),
h( h(
'op', "op",
{ {
attrs: { oprate: 'edit' }, attrs: { oprate: "edit" },
on: { click: () => this.edit(params.row.id) } on: { click: () => this.edit(params.row.id) }
}, },
'编辑' "编辑"
), ),
h( h(
'op', "op",
{ {
attrs: { oprate: 'remove' }, attrs: { oprate: "remove" },
on: { click: () => this.remove(params.row.id) } on: { click: () => this.remove(params.row.id) }
}, },
'删除' "删除"
), ),
h( h(
'op', "op",
{ {
attrs: { oprate: 'detail' }, attrs: { oprate: "detail" },
on: { click: () => this.goShop(params.row.id) } on: { click: () => this.goShop(params.row.id) }
}, },
'部门信息' "部门信息"
) )
]) ]);
} }
} }
] ]
} };
}, },
mounted() { mounted() {
console.log(this) console.log(this);
}, },
async fetch({ store, params }) { async fetch({ store, params }) {
await store.dispatch('loadDictionary') // 加载数据字典 await store.dispatch("loadDictionary"); // 加载数据字典
}, },
methods: { methods: {
addOk() { addOk() {
this.$refs.grid.load() this.$refs.grid.load();
this.addModal = false this.addModal = false;
this.detailModal = false this.detailModal = false;
this.editModal = false this.editModal = false;
this.curId = 0 this.curId = 0;
}, },
search() { search() {
this.$refs.grid.reload(this.easySearch) this.$refs.grid.reload(this.easySearch);
}, },
detail(id) { detail(id) {
setTimeout(() => { setTimeout(() => {
this.detailModal = true this.detailModal = true;
}, 400) }, 400);
this.curId = id this.curId = id;
}, },
edit(id) { edit(id) {
setTimeout(() => { setTimeout(() => {
this.editModal = true this.editModal = true;
}, 400) }, 400);
this.curId = id this.curId = id;
}, },
remove(id) { remove(id) {
this.deletelModal = true this.deletelModal = true;
this.curId = id this.curId = id;
}, },
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("删除成功");
} }
}) });
}, },
removeCancel() { removeCancel() {
this.deletelModal = false this.deletelModal = false;
}, },
cancel() { cancel() {
this.curId = 0 this.curId = 0;
this.addModal = false this.addModal = false;
this.detailModal = false this.detailModal = false;
this.editModal = false this.editModal = false;
this.deletedlModal = false this.deletedlModal = false;
}, },
goShop(id) { goShop(id) {
this.$router.push({ this.$router.push({
name: 'crm-customer-shopIndex', name: "crm-customer-shopIndex",
params: { customerId: id } params: { customerId: id }
}) });
}, },
l(key) { l(key) {
let vkey = 'Customer' + '.' + key let vkey = "Customer" + "." + key;
return this.$t(vkey) || key return this.$t(vkey) || key;
} }
} }
} };
</script> </script>
<style lang="less"></style> <style lang="less"></style>
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
</div> </div>
</template> </template>
<template slot="card" slot-scope="{row}"> <template slot="card" slot-scope="{row}">
<div class="body" v-for="i of 5" :key="i"> <div class="body" v-for="i of 2" :key="i">
<Row class="title-i"> <Row class="title-i">
<Col :span="16" class="order-code"> <Col :span="16" class="order-code">
<Ellipsis :text="row.productName+i" :lines="1" tooltip transfer /> <Ellipsis :text="row.productName+i" :lines="1" tooltip transfer />
...@@ -88,9 +88,9 @@ ...@@ -88,9 +88,9 @@
<!-- :title="row.productUrl" --> <!-- :title="row.productUrl" -->
</Col> </Col>
<Col span="16" class="row"> <Col span="16" class="row">
<p>机床类型:{{row.MachineType}}</p> <p>设备类型:{{row.MachineType}}</p>
<p>机床编码:{{row.MachineCode}}</p> <p>设备编码:{{row.MachineCode}}</p>
<p>机床IP:{{row.MachineIp}}</p> <p>设备IP:{{row.MachineIp}}</p>
<p>系统信息:{{row.information}}</p> <p>系统信息:{{row.information}}</p>
</Col> </Col>
</Row> </Row>
...@@ -123,7 +123,7 @@ export default { ...@@ -123,7 +123,7 @@ export default {
{ {
productName: "德玛吉235550", productName: "德玛吉235550",
statu: "空闲", statu: "空闲",
productUrl:"shebei.png", productUrl:"shebei01.png",
MachineType: "V1-256-16331", MachineType: "V1-256-16331",
MachineCode: "JCBM-06221", MachineCode: "JCBM-06221",
MachineIp: "1231-111-26012", MachineIp: "1231-111-26012",
...@@ -131,7 +131,7 @@ export default { ...@@ -131,7 +131,7 @@ export default {
},{ },{
productName: "德玛吉235536", productName: "德玛吉235536",
statu: "关机", statu: "关机",
productUrl:"shebei.png", productUrl:"shebei02.png",
MachineType: "V1-256-16332", MachineType: "V1-256-16332",
MachineCode: "JCBM-06222", MachineCode: "JCBM-06222",
MachineIp: "1231-111-26012", MachineIp: "1231-111-26012",
...@@ -139,7 +139,7 @@ export default { ...@@ -139,7 +139,7 @@ export default {
},{ },{
productName: "德玛吉235537", productName: "德玛吉235537",
statu: "故障", statu: "故障",
productUrl:"shebei.png", productUrl:"shebei03.png",
MachineType: "V1-256-16333", MachineType: "V1-256-16333",
MachineCode: "JCBM-06223", MachineCode: "JCBM-06223",
MachineIp: "1231-111-26012", MachineIp: "1231-111-26012",
...@@ -147,12 +147,85 @@ export default { ...@@ -147,12 +147,85 @@ export default {
},{ },{
productName: "德玛吉235537", productName: "德玛吉235537",
statu: "运行中", statu: "运行中",
productUrl:"shebei.png", productUrl:"shebei04.png",
MachineType: "V1-256-16334", MachineType: "V1-256-16334",
MachineCode: "JCBM-06224", MachineCode: "JCBM-06224",
MachineIp: "1231-111-26012", MachineIp: "1231-111-26012",
information: "V-5633-12112", information: "V-5633-12112",
}, },
// {
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei05.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei06.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei07.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei08.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei09.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei10.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei11.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei12.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },{
// productName: "德玛吉235537",
// statu: "运行中",
// productUrl:"shebei13.png",
// MachineType: "V1-256-16334",
// MachineCode: "JCBM-06224",
// MachineIp: "1231-111-26012",
// information: "V-5633-12112",
// },
], ],
typeInfo: "card", typeInfo: "card",
iconInfo: "md-apps", iconInfo: "md-apps",
...@@ -271,7 +344,7 @@ export default { ...@@ -271,7 +344,7 @@ export default {
let tempUrl = ""; let tempUrl = "";
if (url && url.length > 0) { if (url && url.length > 0) {
// tempUrl = this.downUrl + url; // tempUrl = this.downUrl + url;
tempUrl = iconImg + url; tempUrl = mncImg + url;
} else { } else {
tempUrl = iconImg + "noPic_product.png"; tempUrl = iconImg + "noPic_product.png";
} }
......
...@@ -18,10 +18,10 @@ ...@@ -18,10 +18,10 @@
</Col> </Col>
<Col span="14"> <Col span="14">
<div class="set_masage"> <div class="set_masage">
<p>机床名称:德玛吉235537</p> <p>设备名称:德玛吉235537</p>
<p>机床类型:V1-256-16334</p> <p>设备类型:V1-256-16334</p>
<p>机床编码:JCBM-06224</p> <p>设备编码:JCBM-06224</p>
<p>机床IP:1231-111-26012</p> <p>设备IP:1231-111-26012</p>
<p>系统信息:V-5633-12112</p> <p>系统信息:V-5633-12112</p>
</div> </div>
</Col> </Col>
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
</template> </template>
<script> <script>
import Api from '../api' import Api from '../api'
import Processview from '../../processDesign/Process/processview.vue' import Processview from '../../technology/processview.vue'
export default { export default {
name: 'detail', name: 'detail',
...@@ -40,7 +40,7 @@ export default { ...@@ -40,7 +40,7 @@ export default {
load(v) { load(v) {
Api.get({ Id: this.idVal }).then((r) => { Api.get({ Id: this.idVal }).then((r) => {
if (r.success) { if (r.success) {
this.$refs.processview.loaddata(r.result.fromIds) this.$refs.processview.load(r.result.fromIds)
} else { } else {
this.$Message.error('加载失败') this.$Message.error('加载失败')
} }
......
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<Col span="9"> <Col span="9">
<div class="iview_cont border_none"> <div class="iview_cont border_none">
&nbsp; &nbsp;
<label v-text="formValidate.task_type_str"></label> <state code="Process.Routing.routingType" :value="formValidate.routingType+''" type="text"></state>
</div> </div>
</Col> </Col>
</Row> </Row>
...@@ -52,16 +52,16 @@ ...@@ -52,16 +52,16 @@
<Col span="9"> <Col span="9">
<div class="iview_cont"> <div class="iview_cont">
&nbsp; &nbsp;
<label v-text="formValidate.versiondesc"></label> <state code="Process.Routing.version" :value="formValidate.versionid+''" type="text"></state>
</div> </div>
</Col> </Col>
<Col span="3"> <Col span="3">
<div class="row_label">研制方式</div> <div class="row_label">工艺阶段</div>
</Col> </Col>
<Col span="9"> <Col span="9">
<div class="iview_cont border_none"> <div class="iview_cont border_none">
&nbsp; &nbsp;
<label v-text="formValidate.development_mode_str"></label> <state code="Process.Routing.phase" :value="formValidate.phase+''" type="text"></state>
</div> </div>
</Col> </Col>
</Row> </Row>
...@@ -165,19 +165,19 @@ ...@@ -165,19 +165,19 @@
<tbody> <tbody>
<template v-for="(item5,index5) in formValidate.details"> <template v-for="(item5,index5) in formValidate.details">
<tr> <tr>
<td class="tl">{{item5.taskseq}}</td> <td class="tl">{{item5.taskSeq}}</td>
<td class="tl">{{item5.name}}</td> <td class="tl">{{item5.name}}</td>
<td class="tl"> <td class="tl">
<div v-html="item5.task_content" class="tohtml"></div> <div v-html="item5.taskContent" class="tohtml"></div>
</td> </td>
<td class="tl">{{item5.operator}}</td> <td class="tl">{{item5.operator}}</td>
<td class="tl">{{item5.proofreader}}</td> <td class="tl">{{item5.proofreader}}</td>
</tr> </tr>
<tr v-for="(item6,index6) in item5.step"> <tr v-for="(item6,index6) in item5.step">
<td class="tl">{{item6.taskseq}}</td> <td class="tl">{{item6.taskSeq}}</td>
<td class="tl">{{item6.name}}</td> <td class="tl">{{item6.name}}</td>
<td class="tl"> <td class="tl">
<div v-html="item6.task_content" class="tohtml"></div> <div v-html="item6.taskContent" class="tohtml"></div>
</td> </td>
<td class="tl">{{item6.operator}}</td> <td class="tl">{{item6.operator}}</td>
<td class="tl">{{item6.proofreader}}</td> <td class="tl">{{item6.proofreader}}</td>
...@@ -211,9 +211,9 @@ ...@@ -211,9 +211,9 @@
<tbody> <tbody>
<template v-for="(item7,index7) in formValidate.qcards"> <template v-for="(item7,index7) in formValidate.qcards">
<tr> <tr>
<td class="tl">{{item7.taskseq}}</td> <td class="tl">{{item7.taskSeq}}</td>
<td class="tl">{{item7.check_content}}</td> <td class="tl">{{item7.checkContent}}</td>
<td class="tl">{{item7.checkresult}}</td> <td class="tl">{{item7.checkResult}}</td>
<td class="tl">{{item7.result}}</td> <td class="tl">{{item7.result}}</td>
<td class="tl">{{item7.checker}}</td> <td class="tl">{{item7.checker}}</td>
<td class="tl">{{item7.remarks}}</td> <td class="tl">{{item7.remarks}}</td>
...@@ -233,6 +233,7 @@ ...@@ -233,6 +233,7 @@
</div> </div>
</template> </template>
<script> <script>
import Api from "./api";
import service from "@/plugins/request"; import service from "@/plugins/request";
export default { export default {
name: "processview", name: "processview",
...@@ -274,7 +275,7 @@ export default { ...@@ -274,7 +275,7 @@ export default {
load(v) { load(v) {
this.circleModal = true; this.circleModal = true;
this.dataSatus = false; this.dataSatus = false;
var url = `${designUrl}/routingheader/getprocessinfo?headerid=` + v; var url = `${technologyUrl}routingheader/getprocessinfo?headerid=` + v;
service service
.get(`${url}`) .get(`${url}`)
.then(response => { .then(response => {
...@@ -303,6 +304,39 @@ export default { ...@@ -303,6 +304,39 @@ export default {
loadImg() { loadImg() {
this.nameList = []; this.nameList = [];
this.formValidate.files = []; this.formValidate.files = [];
if (this.eid == undefined) {
let pars = {
conditions: [
{
fieldName: "code",
fieldValue: this.formValidate.code,
conditionalType: "Equal"
}
]
};
Api.paged(pars)
.then(res => {
if (res.result.items[0].fileId) {
this.parms.eid = res.result.items[0].fileId;
} else {
this.parms.eid = this.$u.guid(); //未上传过文件
}
//查询上传到文件服务器上的文件
this.$http.sysUser.getFile(this.parms).then(res => {
if (res.data != [] && res.data.length > 0) {
res.data.forEach(data => {
let objImag = {};
objImag.fileName = data.fileName;
objImag.url = data.downloadPath;
objImag.id = data.id;
this.nameList.push(objImag);
});
this.formValidate.files = this.nameList;
}
});
})
.catch(err => {});
} else {
//查询上传到文件服务器上的文件 //查询上传到文件服务器上的文件
this.$http.sysUser.getFile(this.parms).then(res => { this.$http.sysUser.getFile(this.parms).then(res => {
if (res.data != [] && res.data.length > 0) { if (res.data != [] && res.data.length > 0) {
...@@ -317,6 +351,7 @@ export default { ...@@ -317,6 +351,7 @@ export default {
} }
}); });
} }
}
}, },
watch: { watch: {
eid(v) { eid(v) {
...@@ -326,10 +361,9 @@ export default { ...@@ -326,10 +361,9 @@ export default {
}, },
uid(v) { uid(v) {
if (v != 0) { if (v != 0) {
this.parms.eid=v this.parms.eid = v;
}
} }
},
} }
}; };
</script> </script>
...@@ -353,6 +387,5 @@ export default { ...@@ -353,6 +387,5 @@ export default {
position: relative; position: relative;
border: 0px solid #eee; border: 0px solid #eee;
} }
</style> </style>
...@@ -26,6 +26,7 @@ window.crmUrl = `http://${address}:10000/crm`; //crm客户、合同、项目管 ...@@ -26,6 +26,7 @@ window.crmUrl = `http://${address}:10000/crm`; //crm客户、合同、项目管
window.apsUrl = `http://${systemApi.aps}:10111/api/services/app`;//aps排产(61) window.apsUrl = `http://${systemApi.aps}:10111/api/services/app`;//aps排产(61)
window.technologyUrl =`http://${address}:10000/technology/`;//新工艺规程接口 window.technologyUrl =`http://${address}:10000/technology/`;//新工艺规程接口
window.iconImg = `/imgicon/`; window.iconImg = `/imgicon/`;
window.mncImg = `/images/mnc/`;//mnc图片
window.material = `http://${address}:10000/material`; //物料管理 window.material = `http://${address}:10000/material`; //物料管理
/* window.systemUrl = `http://${address}:10020/api/services/app`; //System-api 系统管理(基础数据) /* window.systemUrl = `http://${address}:10020/api/services/app`; //System-api 系统管理(基础数据)
......
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