Commit 707b74cb authored by kangzhenfei's avatar kangzhenfei

dnc&mnc

parent 28524808
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="140">
<Row>
<Col :span="12">
<FormItem label="物料编码:" prop="">
<Input placeholder="请输入物料编码" v-model="entity.projectNo" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="零件图号:" prop="">
<Input placeholder="请输入零件图号" v-model="entity.lingNo" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="零件名称:" prop="">
<Input placeholder="请输入零件名称" v-model="entity.lingName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="工艺规程/工序号:" prop="">
<Input placeholder="请输入工艺规程/工序号" v-model="entity.produCode" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="工序名称:" prop="">
<Input placeholder="请输入工序名称" v-model="entity.produName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="程序名称:" prop="">
<Input placeholder="请输入程序名称" v-model="entity.projecName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="程序文件名称:" prop="">
<Input placeholder="请输入程序文件名称" v-model="entity.fileName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="版本号:" prop="">
<Input placeholder="请输入版本号" v-model="entity.tvb" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="创建人:" prop="">
<Input placeholder="请输入创建人" v-model="entity.creatUser" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="状态:" prop="">
{{entity.statue}}
<!-- <Input v-model="entity.statue" /> -->
</FormItem>
</Col>
<Col :span="12">
<FormItem label="备注:" prop="">
<Input placeholder="请输入备注信息" v-model="entity.notse" />
</FormItem>
</Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</template>
<script>
export default {
name: "Edit",
data() {
return {
disabled: false,
entity: {},
orderCatList: [],
rules: {
name: [{ required: true, message: "必填", trigger: "blur" }]
},
single: false
};
},
props: {
row: {
type: Object,
default: () => {
return null;
}
}
},
methods: {
load(v) {
this.entity = v;
},
handleSubmit() {
this.$refs.form.validate(v => {
if (v) {
}
});
},
handleClose() {
this.$emit("on-close");
},
l(key) {
key = "mes_op_task_execute" + "." + key;
return this.$t(key);
}
},
watch: {
// row(v) {
// if (v != {}) {
//alert(JSON.stringify(v))
// this.entity = v;
// }
// }
}
};
</script>
This diff is collapsed.
...@@ -31,11 +31,39 @@ ...@@ -31,11 +31,39 @@
.dispatch_part_body{ .dispatch_part_body{
padding: 10px; padding: 10px;
overflow-y: auto; overflow-y: auto;
.h3_bg{ .row_box {
background: #a5adbf; border: 1px solid #ccc;
padding: 0 0 0 10px; border-radius:4px;
.h3_tag{ margin: 10px 0;
margin-left: 15px!important; .h3_bg{
padding: 5px 0 5px 10px;
border-bottom: 1px solid #ccc;
.h3_tag{
margin-left: 40px;
color: #2680EB;
}
}
.card_body01{
padding: 0 10px 0;
}
.h60{
.card_body02{
padding: 0 10px 0;
margin: 4px 0;
.dispatch_li{
line-height: 24px;
}
}
}
.show_btn{
font-size: 16px;
a{
text-align: center;
width: 40px;
display: block;
height: 24px;
margin: 0 auto;
}
} }
} }
.dispatch_card{ .dispatch_card{
...@@ -47,43 +75,13 @@ ...@@ -47,43 +75,13 @@
} }
} }
.ivu-card-head{ .ivu-card-head{
background: #2d8cf0!important; background: #2d8cf0;
} }
} }
.g_title{ .g_title{
color: #2d8cf0; color: #2d8cf0;
} }
} }
.dispatch_card02{
margin: 10px 0;
// padding-left: 0!important;
// padding-right: 0!important;
.man_body{
max-width: 185px;
.checkUser{
border-radius: 24px;
width: 100%;
height: 50px;
line-height: 47px;
span{
height: 50px;
}
.svg_name{
overflow: hidden;
text-overflow: ellipsis;
-o-text-overflow: ellipsis;
white-space:nowrap;
display: block;
float: right;
width: 82%;
}
.svg{
width: 70px;
}
}
}
}
} }
} }
.drawer_midell{ .drawer_midell{
...@@ -105,8 +103,6 @@ ...@@ -105,8 +103,6 @@
font-weight: 600; font-weight: 600;
} }
.drawer_midell{ .drawer_midell{
// height: 120px;
// margin: 20px 0;
.drawer_center{ .drawer_center{
text-align: center; text-align: center;
padding: 10px; padding: 10px;
......
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="140">
<Row>
<Col :span="12">
<FormItem label="物料编码:" prop="">
<Input placeholder="请输入物料编码" v-model="entity.projectNo" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="零件图号:" prop="">
<Input placeholder="请输入零件图号" v-model="entity.lingNo" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="零件名称:" prop="">
<Input placeholder="请输入零件名称" v-model="entity.lingName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="工艺规程/工序号:" prop="">
<Input placeholder="请输入工艺规程/工序号" v-model="entity.produCode" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="工序名称:" prop="">
<Input placeholder="请输入工序名称" v-model="entity.produName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="程序名称:" prop="">
<Input placeholder="请输入程序名称" v-model="entity.projecName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="程序文件名称:" prop="">
<Input placeholder="请输入程序文件名称" v-model="entity.fileName" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="版本号:" prop="">
<Input placeholder="请输入版本号" v-model="entity.tvb" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="创建人:" prop="">
<Input placeholder="请输入创建人" v-model="entity.creatUser" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="状态:" prop="">
{{entity.statue}}
<!-- <Input v-model="entity.statue" /> -->
</FormItem>
</Col>
<Col :span="12">
<FormItem label="备注:" prop="">
<Input placeholder="请输入备注信息" v-model="entity.notse" />
</FormItem>
</Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</template>
<script>
export default {
name: "Edit",
data() {
return {
disabled: false,
entity: {},
orderCatList: [],
rules: {
name: [{ required: true, message: "必填", trigger: "blur" }]
},
single: false
};
},
props: {
row: {
type: Object,
default: () => {
return null;
}
}
},
methods: {
load(v) {
this.entity = v;
},
handleSubmit() {
this.$refs.form.validate(v => {
if (v) {
this.disabled = true;
let parmsUp = {
run_time: this.entity.run_time,
first_equip: this.entity.eQUIPID,
id: this.entity.id
};
// Api.updatesetuptimeandfirstequip(parmsUp)
// .then(res => {
// if (res.success) {
// if (!this.single) {
// this.$Message.success("保存成功");
// this.$emit("on-option-ok");
// } else {
// let parms = {
// id: this.entity.routing_detail_id, //工序ID
// name: this.entity.task_name, //工序名
// task_seq: this.entity.task_seq, //工序号
// resource_id: this.entity.eQUIPID, //设备id
// runtime: this.entity.run_time, //单件工时
// department_id: 0 //班组ID
// };
// Api.apsupdate(parms)
// .then(r => {
// this.disabled = false;
// if (r.success) {
// this.$Message.success("保存成功");
// this.$emit("on-option-ok");
// } else {
// this.$Message.error("保存失败");
// }
// })
// .catch(err => {
// this.disabled = false;
// this.$Message.error("保存失败");
// console.warn(err);
// });
// }
// } else {
// this.$Message.error("保存失败");
// }
// })
// .catch(err => {
// this.disabled = false;
// this.$Message.error("保存失败");
// console.warn(err);
// });
}
});
},
handleClose() {
this.$emit("on-close");
},
l(key) {
key = "mes_op_task_execute" + "." + key;
return this.$t(key);
}
},
watch: {
row(v) {
if (v != {}) {
alert(JSON.stringify(v))
this.entity = v;
}
}
}
};
</script>
<template> <template>
<div class="dnc_box"> <div class="dnc_box">
<!-- 数据传输:action="action" 接口数据 --> <!-- 数据传输:action="action" 接口数据 -->
<DataGrid :columns="columns" ref="grid" :data="data" :high="false"> <DataGrid :columns="columns" ref="grid" :data="data" :high="false" :height="tableHeight">
<template slot="easySearch"> <template slot="easySearch">
<Form ref="formInline" :model="easySearch" inline> <Form ref="formInline" :model="easySearch" inline>
<FormItem prop="keys"> <FormItem prop="keys">
...@@ -13,20 +13,28 @@ ...@@ -13,20 +13,28 @@
</Form> </Form>
</template> </template>
<template slot="buttons"> <template slot="buttons">
<Button type="primary" >新增</Button> <Button type="primary" @click="addRow">新增</Button>
</template> </template>
</DataGrid> </DataGrid>
<Modal v-model="editModal" title="编辑" footer-hide width="800"> <Modal v-model="editModal" title="编辑" footer-hide width="800">
<!-- <Edit :row="rowData" @on-close="cancel" @on-option-ok="addOk" /> --> <Edit :row="rowData" @on-close="cancel" @on-option-ok="editOk" />
</Modal>
<Modal v-model="addModal" title="新增" footer-hide width="800">
<addView @on-close="cancel" @on-option-ok="addOk" />
</Modal> </Modal>
</div> </div>
</template> </template>
<script> <script>
import Edit from "./edit";
import addView from "./add";
export default { export default {
components: {}, components: {Edit,addView},
data() { data() {
return { return {
editModal: false, editModal: false,
addModal:false,
tableHeight:800,
rowData:{},
easySearch: { easySearch: {
keys: { op: 'projectNo', value: null } keys: { op: 'projectNo', value: null }
}, },
...@@ -61,7 +69,7 @@ export default { ...@@ -61,7 +69,7 @@ export default {
}, },
{ {
key: "tvb", key: "tvb",
title: "版本" title: "版本"
}, },
{ {
key: "creatUser", key: "creatUser",
...@@ -110,8 +118,7 @@ export default { ...@@ -110,8 +118,7 @@ export default {
creatUser: "刘建", creatUser: "刘建",
statue: "受控", statue: "受控",
notse: "适用于MDF设备" notse: "适用于MDF设备"
}, },{
{
projectNo: "12366588", projectNo: "12366588",
id:2, id:2,
lingNo: "dd4.rt5.991", lingNo: "dd4.rt5.991",
...@@ -124,8 +131,7 @@ export default { ...@@ -124,8 +131,7 @@ export default {
creatUser: "刘建", creatUser: "刘建",
statue: "受控", statue: "受控",
notse: "适用于MDF设备" notse: "适用于MDF设备"
}, },{
{
projectNo: "2536898", projectNo: "2536898",
id:3, id:3,
lingNo: "dd4.rt5.991", lingNo: "dd4.rt5.991",
...@@ -138,8 +144,46 @@ export default { ...@@ -138,8 +144,46 @@ export default {
creatUser: "刘建", creatUser: "刘建",
statue: "受控", statue: "受控",
notse: "适用于MDF设备" notse: "适用于MDF设备"
}, },{
{ projectNo: "35653248",
id:4,
lingNo: "dd4.rt5.991",
lingName: "轴承",
produCode: "JJGYI-001/1",
produName: "车",
projecName: "精车文件",
fileName: "dd4rt5991.1.A.txt",
tvb: "A",
creatUser: "刘建",
statue: "受控",
notse: "适用于MDF设备"
},{
projectNo: "35653248",
id:4,
lingNo: "dd4.rt5.991",
lingName: "轴承",
produCode: "JJGYI-001/1",
produName: "车",
projecName: "精车文件",
fileName: "dd4rt5991.1.A.txt",
tvb: "A",
creatUser: "刘建",
statue: "受控",
notse: "适用于MDF设备"
},{
projectNo: "35653248",
id:4,
lingNo: "dd4.rt5.991",
lingName: "轴承",
produCode: "JJGYI-001/1",
produName: "车",
projecName: "精车文件",
fileName: "dd4rt5991.1.A.txt",
tvb: "A",
creatUser: "刘建",
statue: "受控",
notse: "适用于MDF设备"
},{
projectNo: "35653248", projectNo: "35653248",
id:4, id:4,
lingNo: "dd4.rt5.991", lingNo: "dd4.rt5.991",
...@@ -156,17 +200,35 @@ export default { ...@@ -156,17 +200,35 @@ export default {
] ]
}; };
}, },
created() {}, created(){
this.tableHeight = window.innerHeight - 230
},
mounted() { mounted() {
// this.loadDuration(); window.onresize = () => {///浏览器窗口大小变化
return (() => {
window.screenHeight = window.innerHeight
this.tableHeight = window.screenHeight - 230
})()
}
}, },
methods: { methods: {
search() { search() {
this.$Message.success("搜索查询") this.$Message.success("搜索查询")
// this.$refs.grid.reload(this.easySearch) // this.$refs.grid.reload(this.easySearch)
}, },
addRow(){
this.addModal = true
},
edit(rowData){ edit(rowData){
console.log(rowData) console.log(rowData)
this.rowData = rowData;
this.editModal = true
},
editOk(){},
addOk(){},
cancel(){
this.editModal = false
this.addModal = false
}, },
}, },
computed: {}, computed: {},
......
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