Commit 8b9f31e8 authored by 周远喜's avatar 周远喜

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

parents ef666dba 669c07ff
......@@ -21,7 +21,7 @@
</Form>
<Row>
<Col span="24" style="text-align:right;height:60px;line-height:60px">
<Button type="primary" @click="handleSubmit">确定</Button>
<Button type="primary" @click="handleSubmit" v-noClick>确定</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</Col>
</Row>
......
......@@ -138,7 +138,7 @@
</Col>
</Row>
<FormItem class="click-btn">
<Button type="primary" @click="handleSubmit">确定</Button>
<Button type="primary" @click="handleSubmit" v-noClick>确定</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
......
......@@ -21,7 +21,7 @@
</Form>
<Row>
<Col span="24" style="text-align:right;height:60px;line-height:60px">
<Button type="primary" @click="handleSubmit">确定</Button>
<Button type="primary" @click="handleSubmit" v-noClick>确定</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</Col>
</Row>
......
......@@ -138,7 +138,7 @@
</Col>
</Row>
<FormItem class="click-btn">
<Button type="primary" @click="handleSubmit">确定</Button>
<Button type="primary" @click="handleSubmit" v-noClick>确定</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
......
......@@ -96,7 +96,7 @@
</FormItem>
<FormItem>
<Button style="margin-left: 8px" @click="closeOk">取消</Button>
<Button type="primary" @click="lowerHair">下发</Button>
<Button type="primary" @click="lowerHair" v-noClick>下发</Button>
</FormItem>
</Form>
</div>
......
......@@ -254,7 +254,7 @@
</Row>
<FormItem>
<Button style="margin-right: 8px" @click="cancle">取消</Button>
<Button type="primary" @click="sendSheBei">派工</Button>
<Button type="primary" @click="sendSheBei" v-noClick>派工</Button>
</FormItem>
</Form>
</Drawer>
......
......@@ -42,7 +42,6 @@ export default {
name: "addAccessory",
data() {
return {
disabled: false,
deletelModal: false,
curId: 0,
editIndex: -1,
......
......@@ -43,7 +43,7 @@ export default {
name: "detailAccessory",
data() {
return {
disabled: false,
deletelModal: false,
statuList: this.$store.getters.dictionaryByKey("accessory.status") || [],
statuList1: this.$store.getters.dictionaryByKey("outstore.status") || [],
......
......@@ -2,99 +2,104 @@
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<Col span="12">
<FormItem :label="l('DistributeMainRouting')" prop="DistributeMainRouting">
<UserSelect ref="userSelected" v-model="entity.DistributeMainRouting" />
<FormItem
:label="l('DistributeMainRouting')"
prop="DistributeMainRouting"
>
<UserSelect
ref="userSelected"
v-model="entity.DistributeMainRouting"
/>
</FormItem>
</Col>
<Col span="12">
<FormItem label="完成时间" style="width:100%" prop="MainRoutingFinishDate">
<FormItem
label="完成时间"
style="width: 100%"
prop="MainRoutingFinishDate"
>
<DatePicker
v-model="entity.MainRoutingFinishDate"
type="datetime"
placeholder="请选择日期"
style="width:240px"
style="width: 240px"
@on-change="getTimeMainRFD"
></DatePicker>
</FormItem>
</Col>
</Row>
<Row >
&nbsp;
</Row>
<Row >
&nbsp;
</Row>
<Row> &nbsp; </Row>
<Row> &nbsp; </Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button type="primary" @click="handleSubmit" v-noClick>保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</template>
<script>
import Api from './api'
import Api from "./api";
export default {
name: 'Dispatch',
name: "Dispatch",
props: {
ids: Array
ids: Array,
},
data() {
return {
disabled: false,
entity: {
DistributeMainRouting: null,
MainRoutingFinishDate: ''
MainRoutingFinishDate: "",
},
rules: {
DistributeMainRouting: [
{
required: true,
message: '请选择人员',
trigger: 'change',
type: 'number'
}
message: "请选择人员",
trigger: "change",
type: "number",
},
],
MainRoutingFinishDate: [
{
required: true,
message: '请选择时间',
trigger: 'change'
}
]
}
}
message: "请选择时间",
trigger: "change",
},
],
},
};
},
methods: {
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.entity.ids = this.ids
this.entity.ids = this.ids;
Api.routingdistribute(this.entity)
.then((r) => {
if (r.success) {
this.$Message.success('工艺派发成功')
this.$emit('on-ok')
this.$Message.success("工艺派发成功");
this.$emit("on-ok");
} else {
this.$Message.error('工艺派发失败')
this.$Message.error("工艺派发失败");
}
this.$emit('on-ok')
this.$emit("on-ok");
})
.catch((err) => {
this.$Message.error('工艺派发失败')
})
this.$Message.error("工艺派发失败");
});
}
})
});
},
handleClose() {
this.$emit('on-close')
this.$emit("on-close");
},
l(key) {
key = 'mes_order' + '.' + key
return this.$t(key)
key = "mes_order" + "." + key;
return this.$t(key);
},
getTimeMainRFD(value) {
this.entity.MainRoutingFinishDate = value
}
this.entity.MainRoutingFinishDate = value;
},
},
watch: {}
}
watch: {},
};
</script>
......@@ -40,7 +40,7 @@
<Col span="12">
<FormItem label="分解数量" style="width:100%" prop="splitQuantity">
<InputNumber :min="0" v-model="orderForm.splitQuantity" style="width:180px"></InputNumber>
<Button type="primary" @click="addSplitOrder">确定</Button>
<Button type="primary" @click="addSplitOrder" v-noClick>确定</Button>
</FormItem>
</Col>
</Row>
......
......@@ -68,7 +68,7 @@
<Col span="16">&nbsp;</Col>
<Col span="8">
<Button @click="cancel" class="ml20">取消</Button>
<Button type="primary" @click="setNumOk">设置</Button>
<Button type="primary" @click="setNumOk" v-noClick>设置</Button>
</Col>
</Row>
</Form>
......
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<!-- <Col :span="12"
<!-- <Col :span="12"
><FormItem :label="l('creationTime')" prop="creationTime">
<DatePicker
type="date"
......@@ -101,9 +101,7 @@
></Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled"
>保存</Button
>
<Button type="primary" @click="handleSubmit" v-noClick>保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
......@@ -114,7 +112,6 @@ export default {
name: "Add",
data() {
return {
disabled: false,
entity: {
// creationTime: null,
// creatorUserId: null,
......@@ -152,10 +149,8 @@ export default {
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.disabled = true;
Api.create(this.entity)
.then((r) => {
this.disabled = false;
if (r.success) {
this.$Message.success("保存成功");
this.$emit("on-ok");
......@@ -164,7 +159,6 @@ export default {
}
})
.catch((err) => {
this.disabled = false;
this.$Message.error("保存失败");
console.warn(err);
});
......
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<Col :span="12"><FormItem :label="l('creationTime')" prop="creationTime"> <DatePicker type="date" v-model="entity.creationTime"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('creatorUserId')" prop="creatorUserId"> <InputNumber v-model="entity.creatorUserId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('lastModificationTime')" prop="lastModificationTime"> <DatePicker type="date" v-model="entity.lastModificationTime"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('lastModifierUserId')" prop="lastModifierUserId"> <InputNumber v-model="entity.lastModifierUserId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('isDeleted')" prop="isDeleted"> <InputNumber v-model="entity.isDeleted"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('deletionTime')" prop="deletionTime"> <DatePicker type="date" v-model="entity.deletionTime"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('deleterUserId')" prop="deleterUserId"> <InputNumber v-model="entity.deleterUserId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('projectId')" prop="projectId"> <InputNumber v-model="entity.projectId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('upId')" prop="upId"> <InputNumber v-model="entity.upId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('title')" prop="title"> <Input v-model="entity.title"> </Input>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('status')" prop="status"> <Dictionary code="mes.project_plan.Status" v-model="entity.status"></Dictionary>
</FormItem></Col>
<Col :span="24"><FormItem :label="l('note')" prop="note"> <Input v-model="entity.note" type="textarea" :rows="5"></Input>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('startDate')" prop="startDate"> <DatePicker type="date" v-model="entity.startDate"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('endDate')" prop="endDate"> <DatePicker type="date" v-model="entity.endDate"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('type')" prop="type"> <Dictionary code="mes.project_plan.Type" v-model="entity.type"></Dictionary>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('attachment')" prop="attachment"> <Input v-model="entity.attachment"> </Input>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('executor')" prop="executor"> <Input v-model="entity.executor"> </Input>
</FormItem></Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<Col :span="12"
><FormItem :label="l('creationTime')" prop="creationTime">
<DatePicker
type="date"
v-model="entity.creationTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('creatorUserId')" prop="creatorUserId">
<InputNumber v-model="entity.creatorUserId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem
:label="l('lastModificationTime')"
prop="lastModificationTime"
>
<DatePicker
type="date"
v-model="entity.lastModificationTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('lastModifierUserId')" prop="lastModifierUserId">
<InputNumber
v-model="entity.lastModifierUserId"
></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('isDeleted')" prop="isDeleted">
<InputNumber v-model="entity.isDeleted"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('deletionTime')" prop="deletionTime">
<DatePicker
type="date"
v-model="entity.deletionTime"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('deleterUserId')" prop="deleterUserId">
<InputNumber v-model="entity.deleterUserId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('projectId')" prop="projectId">
<InputNumber v-model="entity.projectId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('upId')" prop="upId">
<InputNumber v-model="entity.upId"></InputNumber> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('title')" prop="title">
<Input v-model="entity.title"> </Input> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('status')" prop="status">
<Dictionary
code="mes.project_plan.Status"
v-model="entity.status"
></Dictionary> </FormItem
></Col>
<Col :span="24"
><FormItem :label="l('note')" prop="note">
<Input
v-model="entity.note"
type="textarea"
:rows="5"
></Input> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('startDate')" prop="startDate">
<DatePicker
type="date"
v-model="entity.startDate"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('endDate')" prop="endDate">
<DatePicker
type="date"
v-model="entity.endDate"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('type')" prop="type">
<Dictionary
code="mes.project_plan.Type"
v-model="entity.type"
></Dictionary> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('attachment')" prop="attachment">
<Input v-model="entity.attachment"> </Input> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('executor')" prop="executor">
<Input v-model="entity.executor"> </Input> </FormItem
></Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" v-noClick>保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</template>
<script>
import Api from './api'
export default {
name: 'Edit',
data() {
return {
disabled: false,
entity: {
},
rules: {
name: [{ required: true, message: '必填', trigger: 'blur' }]
}
}
},
props: {
eid: Number
},
mounted() {
if (this.eid > 0) {
this.load(this.eid);
}
},
methods: {
load(v) {
Api.get({ id: v }).then(r => {
this.entity = r.result;
})
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.disabled = true;
Api.update(this.entity).then((r) => {
this.disabled = false;
if (r.success) {
this.$Message.success('保存成功')
this.$emit('on-ok')
} else {
this.$Message.error('保存失败')
}
}).catch(err => {
this.disabled = false;
this.$Message.error('保存失败')
console.warn(err)
})
}
})
},
handleClose() {
this.$emit('on-close')
},
l(key) {
key = "project_plan" + "." + key;
return this.$t(key)
}
},
watch: {
eid(v) {
if (v != 0) {
this.load(v);
}
}
}
import Api from "./api";
export default {
name: "Edit",
data() {
return {
entity: {},
rules: {
name: [{ required: true, message: "必填", trigger: "blur" }],
},
};
},
props: {
eid: Number,
},
mounted() {
if (this.eid > 0) {
this.load(this.eid);
}
},
methods: {
load(v) {
Api.get({ id: v }).then((r) => {
this.entity = r.result;
});
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
Api.update(this.entity)
.then((r) => {
if (r.success) {
this.$Message.success("保存成功");
this.$emit("on-ok");
} else {
this.$Message.error("保存失败");
}
})
.catch((err) => {
this.$Message.error("保存失败");
console.warn(err);
});
}
});
},
handleClose() {
this.$emit("on-close");
},
l(key) {
key = "project_plan" + "." + key;
return this.$t(key);
},
},
watch: {
eid(v) {
if (v != 0) {
this.load(v);
}
},
},
};
</script>
\ No newline at end of file
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<Col span="8">
<Col span="8" class="projct-img">
<FormItem :label="l('picture')" prop="picture">
<inputFile
class="tphoto"
......@@ -137,7 +137,7 @@ export default {
name: "Add",
data() {
return {
disabled: false,
imgName: "",
avatorPath: "",
entity: {
......@@ -155,12 +155,12 @@ export default {
picture: "",
attachment: "",
phase: null,
startDate: null,
endDate: null,
startDate: "",
endDate: "",
businessUnits: "",
},
rules: {
name: [{ required: true, message: "必填", trigger: "blur" }],
title: [{ required: true, message: "必填", trigger: "blur" }],
},
parmsName: "app=material&eid=1&name=ProjectMain",
parms: {
......@@ -196,7 +196,7 @@ export default {
}
Api.create(this.entity)
.then((r) => {
this.disabled = false;
if (r.success) {
this.$Message.success("保存成功");
this.$emit("on-ok");
......@@ -205,7 +205,7 @@ export default {
}
})
.catch((err) => {
this.disabled = false;
this.$Message.error("保存失败");
console.warn(err);
});
......@@ -221,6 +221,8 @@ export default {
this.entity.id = 0;
});
},
//时间相关end
l(key) {
key = "project_main" + "." + key;
return this.$t(key);
......@@ -243,4 +245,19 @@ export default {
},
},
};
</script>
\ No newline at end of file
</script>
<style lang="less">
.projct-img {
.img-touxiang {
width: 300px;
height: 300px;
margin: 0px 10px 15px 20px;
overflow: hidden;
border-radius: 5px;
.img1 {
width: 100%;
height: 100%;
}
}
}
</style>
\ No newline at end of file
<template>
<div class="detail">
<Row>
<Filed :span="12" :name="l('creationTime')">{{entity.creationTime}}</Filed>
<Filed :span="12" :name="l('creatorUserId')">{{entity.creatorUserId}}</Filed>
<Filed :span="12" :name="l('lastModificationTime')">{{entity.lastModificationTime}}</Filed>
<Filed :span="12" :name="l('lastModifierUserId')">{{entity.lastModifierUserId}}</Filed>
<Filed :span="12" :name="l('isDeleted')">{{entity.isDeleted}}</Filed>
<Filed :span="12" :name="l('deletionTime')">{{entity.deletionTime}}</Filed>
<Filed :span="12" :name="l('deleterUserId')">{{entity.deleterUserId}}</Filed>
<Filed :span="12" :name="l('title')">{{entity.title}}</Filed>
<Filed :span="24" :name="l('note')">{{entity.note}}</Filed>
<Filed :span="12" :name="l('state')">{{entity.state}}</Filed>
<Filed :span="12" :name="l('type')">{{entity.type}}</Filed>
<Filed :span="12" :name="l('picture')">{{entity.picture}}</Filed>
<Filed :span="12" :name="l('attachment')">{{entity.attachment}}</Filed>
<Filed :span="12" :name="l('phase')">{{entity.phase}}</Filed>
<Filed :span="12" :name="l('startDate')">{{entity.startDate}}</Filed>
<Filed :span="12" :name="l('endDate')">{{entity.endDate}}</Filed>
<Filed :span="12" :name="l('businessUnits')">{{entity.businessUnits}}</Filed>
</Row>
</div>
<div class="detail">
<Row>
<Filed :span="12" :name="l('creationTime')">{{
entity.creationTime
}}</Filed>
<Filed :span="12" :name="l('creatorUserId')">
<User :value="entity.creatorUserId" />
</Filed>
<!-- <Filed :span="12" :name="l('lastModificationTime')">{{
entity.lastModificationTime
}}</Filed>
<Filed :span="12" :name="l('lastModifierUserId')">{{
entity.lastModifierUserId
}}</Filed>
<Filed :span="12" :name="l('isDeleted')">{{ entity.isDeleted }}</Filed>
<Filed :span="12" :name="l('deletionTime')">{{
entity.deletionTime
}}</Filed>
<Filed :span="12" :name="l('deleterUserId')">{{
entity.deleterUserId
}}</Filed> -->
<Filed :span="12" :name="l('title')">{{ entity.title }}</Filed>
<Filed :span="12" :name="l('state')">
<state code="project.main.state" :value="entity.state"
/></Filed>
<!-- <Filed :span="12" :name="l('phase')">{{ entity.phase }}</Filed> -->
<Filed :span="12" :name="l('startDate')">{{ entity.startDate }}</Filed>
<Filed :span="12" :name="l('endDate')">{{ entity.endDate }}</Filed>
<!-- <Filed :span="12" :name="l('businessUnits')">{{
entity.businessUnits
}}</Filed> -->
<Filed :span="12" :name="l('type')">
<state code="project.main.type" :value="entity.type" />
</Filed>
<Filed :span="12" :name="l('picture')"
><a @click="imgClick(entity.picture)">查看图片</a></Filed
>
<Filed :span="12" :name="l('attachment')">
<files ref="refFile" :parms="parms" fileFormat :showList="false" />
</Filed>
<Filed :span="24" :name="l('note')">{{ entity.note }}</Filed>
</Row>
</div>
</template>
<script>
import Api from './api'
export default {
name: 'Add',
data() {
return {
entity: {},
rules: {
name: [{ required: true, message: '必填', trigger: 'blur' }],
code: [{ required: true, message: '必填', trigger: 'blur' }]
}
}
},
props: {
eid: Number
},
mounted() {
if (this.eid > 0) {
this.load(this.eid);
}
},
methods: {
load(v) {
Api.get({ id: v }).then(r => {
this.entity = r.result;
this.$emit('on-load')
})
},
handleClose() {
this.$emit('on-close')
},
l(key) {
key = "project_main" + "." + key;
return this.$t(key)
import Api from "./api";
export default {
name: "Add",
data() {
return {
entity: {},
rules: {
name: [{ required: true, message: "必填", trigger: "blur" }],
code: [{ required: true, message: "必填", trigger: "blur" }],
},
parms: {
app: "material",
eid: null,
name: "",
field: "",
},
};
},
props: ["eid"],
mounted() {
this.load(this.eid);
},
methods: {
imgClick(img) {
window.open(fileUrlDown + img, "_blank");
},
load(v) {
Api.get({ id: v }).then((r) => {
this.entity = r.result;
this.entity.type = r.result.type + "";
this.entity.state = r.result.state + "";
this.parms.eid = r.result.attachment;
this.$emit("on-load");
});
},
handleClose() {
this.$emit("on-close");
},
l(key) {
key = "project_main" + "." + key;
return this.$t(key);
},
},
watch: {
eid(v) {
if (v) {
this.load(v);
}
},
watch: {
eid(v) {
if (v > 0) {
this.load(v);
}
}
}
}
},
},
};
</script>
\ No newline at end of file
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<Col :span="12"><FormItem :label="l('creationTime')" prop="creationTime"> <DatePicker type="date" v-model="entity.creationTime"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('creatorUserId')" prop="creatorUserId"> <InputNumber v-model="entity.creatorUserId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('lastModificationTime')" prop="lastModificationTime"> <DatePicker type="date" v-model="entity.lastModificationTime"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('lastModifierUserId')" prop="lastModifierUserId"> <InputNumber v-model="entity.lastModifierUserId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('isDeleted')" prop="isDeleted"> <InputNumber v-model="entity.isDeleted"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('deletionTime')" prop="deletionTime"> <DatePicker type="date" v-model="entity.deletionTime"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('deleterUserId')" prop="deleterUserId"> <InputNumber v-model="entity.deleterUserId"></InputNumber>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('title')" prop="title"> <Input v-model="entity.title"> </Input>
</FormItem></Col>
<Col :span="24"><FormItem :label="l('note')" prop="note"> <Input v-model="entity.note" type="textarea" :rows="5"></Input>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('state')" prop="state"> <Dictionary code="mes.project_main.State" v-model="entity.state"></Dictionary>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('type')" prop="type"> <Dictionary code="mes.project_main.Type" v-model="entity.type"></Dictionary>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('picture')" prop="picture"> <Input v-model="entity.picture"> </Input>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('attachment')" prop="attachment"> <Input v-model="entity.attachment"> </Input>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('phase')" prop="phase"> <Dictionary code="mes.project_main.Phase" v-model="entity.phase"></Dictionary>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('startDate')" prop="startDate"> <DatePicker type="date" v-model="entity.startDate"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('endDate')" prop="endDate"> <DatePicker type="date" v-model="entity.endDate"></DatePicker>
</FormItem></Col>
<Col :span="12"><FormItem :label="l('businessUnits')" prop="businessUnits"> <Input v-model="entity.businessUnits"> </Input>
</FormItem></Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
<Form ref="form" :model="entity" :rules="rules" :label-width="90">
<Row>
<Col span="8" class="projct-img">
<FormItem :label="l('picture')" prop="picture">
<inputFile
class="tphoto"
ref="refmovieFile1"
v-model="imgName"
:parms="parmsName"
/>
</FormItem>
</Form>
<div class="img-touxiang">
<img :src="avatorPath" v-if="imgName" @click="imgUrl" class="img1" />
<img
src="@/assets/images/files_header.png"
v-else
width="100%"
height="100%"
/>
</div>
</Col>
<Col span="16">
<Col :span="12"
><FormItem :label="l('title')" prop="title">
<Input v-model="entity.title"> </Input> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('state')" prop="state">
<Dictionary
code="project.main.state"
v-model="entity.state"
></Dictionary> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('startDate')" prop="startDate">
<DatePicker
type="date"
v-model="entity.startDate"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('endDate')" prop="endDate">
<DatePicker
type="date"
v-model="entity.endDate"
></DatePicker> </FormItem
></Col>
<Col :span="12"
><FormItem :label="l('type')" prop="type">
<Dictionary
code="project.main.type"
v-model="entity.type"
></Dictionary> </FormItem
></Col>
<Col :span="24">
<FormItem :label="l('attachment')" prop="attachment">
<!-- <Input v-model="entity.template" type="textarea" :rows="5"></Input> -->
<files ref="refFile" :parms="parms" files />
</FormItem>
</Col>
<!-- <Col :span="12"
><FormItem :label="l('phase')" prop="phase">
<Dictionary
code="mes.project_main.Phase"
v-model="entity.phase"
></Dictionary> </FormItem
></Col> -->
<!-- <Col :span="12"
><FormItem :label="l('businessUnits')" prop="businessUnits">
<Input v-model="entity.businessUnits"> </Input> </FormItem
></Col> -->
<Col :span="24"
><FormItem :label="l('note')" prop="note">
<Input
v-model="entity.note"
type="textarea"
:rows="5"
></Input> </FormItem
></Col>
</Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" v-noClick>保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</template>
<script>
import Api from './api'
export default {
name: 'Edit',
data() {
return {
disabled: false,
entity: {
},
rules: {
name: [{ required: true, message: '必填', trigger: 'blur' }]
}
}
},
props: {
eid: Number
},
mounted() {
if (this.eid > 0) {
this.load(this.eid);
}
},
methods: {
load(v) {
Api.get({ id: v }).then(r => {
this.entity = r.result;
})
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.disabled = true;
Api.update(this.entity).then((r) => {
this.disabled = false;
if (r.success) {
this.$Message.success('保存成功')
this.$emit('on-ok')
} else {
this.$Message.error('保存失败')
}
}).catch(err => {
this.disabled = false;
this.$Message.error('保存失败')
console.warn(err)
})
}
})
},
handleClose() {
this.$emit('on-close')
},
l(key) {
key = "project_main" + "." + key;
return this.$t(key)
}
},
watch: {
eid(v) {
if (v != 0) {
this.load(v);
}
}
import Api from "./api";
export default {
name: "Edit",
data() {
return {
imgName: "",
avatorPath: "",
entity: {},
rules: {
title: [{ required: true, message: "必填", trigger: "blur" }],
},
parmsName: "app=material&eid=1&name=ProjectMain",
parms: {
app: "material",
eid: null,
name: "",
field: "",
},
};
},
props: ["eid"],
mounted() {
this.load(this.eid);
this.parms.eid = this.$u.guid();
this.$refs.refmovieFile1.inputShow = false;
},
methods: {
imgUrl() {
window.open(this.avatorPath, "_blank");
},
load(v) {
Api.get({ id: v }).then((r) => {
this.entity = r.result;
this.avatorPath = fileUrlDown + r.result.picture;
this.imgName = r.result.picture;
if (r.result.attachment && r.result.attachment != "") {
this.parms.eid = r.result.attachment;
} else {
this.parms.eid = this.$u.guid();
}
this.entity.attachment = this.parms.eid;
// this.entity.creatorUserId = r.result.creatorUserId;
});
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
if (this.$refs.refFile.nameList.length > 0) {
this.entity.attachment = this.parms.eid;
} else {
this.entity.attachment = "";
}
Api.update(this.entity)
.then((r) => {
if (r.success) {
this.$Message.success("保存成功");
this.$emit("on-ok");
} else {
this.$Message.error("保存失败");
}
})
.catch((err) => {
this.$Message.error("保存失败");
console.warn(err);
});
}
}
</script>
\ No newline at end of file
});
},
handleClose() {
this.$emit("on-close");
},
l(key) {
key = "project_main" + "." + key;
return this.$t(key);
},
},
watch: {
eid(v) {
if (v) {
this.load(v);
}
},
},
};
</script>
<style lang="less">
</style>
\ No newline at end of file
<template>
<div>
<div class="project">
<DataGrid
:columns="columns"
ref="grid"
......@@ -7,12 +7,14 @@
:conditions="easySearch"
:type="typeInfo"
:span="6"
:format="formatFun"
><template slot="easySearch"
><Form ref="formInline" :model="easySearch" inline
><FormItem prop="keys"
><Input
placeholder="请输入关键字标题"
v-model="easySearch.keys.value"
clearable
/>
</FormItem>
<FormItem
......@@ -33,17 +35,36 @@
></Button>
</template>
<template slot="card" slot-scope="{ row }">
<div class="body-card">
<Card
class="body-card"
:style="row._checked ? 'border:1px solid #2680eb;' : ''"
>
<Row class="title-i">
<Col :span="12">
<Ellipsis :text="row.name" :length="18" tooltip />
<Col :span="10" class="title-l">
<Checkbox v-model="row._checked"></Checkbox>
<Ellipsis :text="row.title" :length="18" tooltip />
</Col>
<Col :span="10" class="btn-click">
<!-- <Ellipsis :text="row.code" :length="18" tooltip/> -->
</Col>
<Col :span="4">
<div class="statuBg" :style="tdStyle(row.state)"></div>
<div class="boxTitle">
<div class="text">
<state
code="project.main.state"
ref="state"
:value="row.state"
type="text"
:color="false"
></state>
</div>
</div>
</Col>
<Col :span="12" class="btn-click">
<Ellipsis :text="row.code" :length="18" tooltip
/></Col>
</Row>
<Row class="row-down" :gutter="10">
<Col span="7">
<Col span="10">
<div class="img-i">
<!-- <img :src="downUrl + row.img" v-if="row.img" /> -->
<Pictrue :src="row.img" v-if="row.img" />
......@@ -55,24 +76,27 @@
/>
</div>
</Col>
<Col span="17">
<Col span="14">
<div class="c">
<div>版本:{{ row.version }}</div>
<div>创建人: <User :value="row.creatorUserId" /></div>
<div>
状态:
<state code="word.document.status" :value="row.status" />
创建时间:{{ row.creationTime }}
<!-- <state code="word.document.status" :value="row.status" /> -->
</div>
<!-- <div>
创建人:
<User :value="row.creatorUserId" />
</div>-->
<div>开始时间:{{ row.startDate }}</div>
<div>结束时间:{{ row.endDate }}</div>
<div class="shuo-ming">
<span>文档说明</span>
<Ellipsis :text="row.description" :length="12" tooltip />
<span>备注</span>
<Ellipsis :text="row.note" :length="12" tooltip />
</div>
</div>
</Col>
</Row>
<Row class="bottom-b">
<Col span="6"
><state code="project.main.type" :value="row.type"
/></Col>
<Col span="18">
<div class="a-icon">
<a @click="edit(row.id)"> <Icon type="md-create" />编辑 </a
>&nbsp;
......@@ -86,10 +110,10 @@
</div>
</Col>
</Row>
</div>
</Card>
</template>
</DataGrid>
<Modal v-model="modal" :title="title" width="1200" footer-hide>
<Modal v-model="modal" :title="title" width="1200" footer-hide :mask-closable="false">
<component :is="detail" :eid="curId" @on-close="cancel" @on-ok="ok" />
</Modal>
</div>
......@@ -113,6 +137,7 @@ export default {
easySearch: {
keys: { op: "title", value: null },
},
// single: false,
modal: false,
title: "新增",
detail: null,
......@@ -177,55 +202,100 @@ export default {
{
key: "state",
title: this.l("state"),
align: "left",
align: "center",
high: true,
code: "mes.project_main.State",
code: "project.main.state",
},
{
key: "type",
title: this.l("type"),
align: "left",
align: "center",
high: true,
code: "mes.project_main.Type",
code: "project.main.type",
},
{ key: "picture", title: this.l("picture"), align: "left", high: true },
{
key: "attachment",
title: this.l("attachment"),
align: "left",
key: "picture",
title: this.l("picture"),
align: "center",
high: true,
render: (h, params) => {
return h(
"a",
{
on: { click: () => this.viewImg(params.row) },
},
"查看图片"
);
},
},
{
key: "phase",
title: this.l("phase"),
align: "left",
key: "attachment",
title: this.l("attachment"),
align: "center",
high: true,
code: "mes.project_main.Phase",
render: (h, params) => {
return h(
"a",
{
on: { click: () => this.view(params.row.id) },
},
"查看附件"
);
},
},
// {
// key: "phase",
// title: this.l("phase"),
// align: "left",
// high: true,
// code: "mes.project_main.Phase",
// },
{
key: "startDate",
title: this.l("startDate"),
align: "left",
align: "center",
high: true,
render: (h, params) => {
return h(
"span",
params.row.startDate
? this.sliceStr(params.row.startDate + " ", 0, 10)
: ""
);
},
},
{ key: "endDate", title: this.l("endDate"), align: "left", high: true },
{
key: "businessUnits",
title: this.l("businessUnits"),
align: "left",
key: "endDate",
title: this.l("endDate"),
align: "center",
high: true,
render: (h, params) => {
return h(
"span",
params.row.endDate
? this.sliceStr(params.row.endDate + " ", 0, 10)
: ""
);
},
},
// {
// key: "businessUnits",
// title: this.l("businessUnits"),
// align: "left",
// high: true,
// },
{
key: "creationTime",
title: this.l("creationTime"),
align: "left",
align: "center",
hide: false,
},
{
key: "creatorUserId",
title: this.l("creatorUserId"),
align: "left",
align: "center",
high: true,
type: "user",
},
{
title: "操作",
......@@ -275,6 +345,26 @@ export default {
await store.dispatch("loadDictionary"); // 加载数据字典
},
methods: {
//格式化原始数据
formatFun(data) {
data.map((e) => {
return (e._checked = false);
});
return data;
},
tdStyle(val) {
//动态根据状态值加载状态值对应的颜色 #19c919
let temDic = this.$store.getters.dictionaryByKey("project.main.state");
let temColor = "#19c919";
temDic.forEach((data) => {
if (Number(data.code) == val) {
temColor = data.color;
}
});
var style = {};
style["border-top"] = " solid 38px " + temColor;
return style;
},
changeShwo() {
//显示模式切换
if (this.typeInfo == "card") {
......@@ -287,6 +377,10 @@ export default {
this.titleInfo = "卡片模式";
}
},
viewImg(row) {
console.log(row);
window.open(fileUrlDown + row.picture, "_blank");
},
ok() {
this.$refs.grid.load();
this.modal = false;
......@@ -302,6 +396,7 @@ export default {
this.modal = true;
},
copy(id) {
console.log(id);
this.curId = id;
this.title = "克隆";
this.detail = () => import("./add");
......@@ -331,6 +426,10 @@ export default {
this.curId = 0;
this.modal = false;
},
//截取字符串
sliceStr(str, lenS, lenE) {
return str.slice(lenS, lenE);
},
l(key) {
let vkey = "project_main" + "." + key;
return this.$t(vkey) || key;
......@@ -339,4 +438,89 @@ export default {
};
</script>
<style lang="less">
.project {
.ivu-card-body {
padding: 0 !important;
}
.body-card {
// border: 1px solid rgba(38, 128, 235, 1);
margin: 5px 0;
border-radius: 4px;
// height: 280px;
.title-i {
// border-bottom: 1px solid #2680eb;
// padding: 0 10px;
height: 35px;
line-height: 35px;
background: rgba(38, 128, 235, 0.2);
color: #2680eb;
padding-left: 10px;
.title-l {
display: -webkit-inline-box;
}
.btn-click {
text-align: right;
}
.statuBg {
height: 0px;
width: 0;
border-left: solid 50px transparent;
float: right;
margin-right: -1px;
}
.boxTitle {
color: white;
float: right;
margin-top: -40px;
/* Rotate div */
transform: rotate(37deg);
-ms-transform: rotate(37deg);
/* Internet Explorer */
-moz-transform: rotate(37deg);
/* Firefox */
-webkit-transform: rotate(37deg);
/* Safari 和 Chrome */
-o-transform: rotate(37deg);
/* Opera */
.text {
font-size: 8px;
font-weight: normal;
padding-right: 5px;
}
}
}
.row-down {
padding: 14px;
.img-i {
height: 170px;
width: 170px;
}
.c {
padding-left: 14px;
height: 170px;
div {
height: 33px;
line-height: 33px;
}
}
.shuo-ming {
display: -webkit-inline-box;
// display: inline-block;
}
}
.bottom-b {
// line-height: 40px;
padding: 0 0 6px 14px;
.a-icon {
text-align: right;
}
}
}
}
</style>
\ No newline at end of file
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="120">
<template>
<Form ref="form" :model="entity" :rules="rules" :label-width="120">
<Row>
<!--
<!--
<Col :span="12">
<FormItem :label="l('routingStepId')" prop="routingStepId">
<InputNumber v-model="entity.routingStepId"></InputNumber>
......@@ -34,19 +34,14 @@
</Col>
-->
<Col :span="12">
<Col :span="12">
<FormItem :label="l('routingDetailName')" prop="routingDetailId">
<Select v-model="entity.routingDetailId">
<Option
v-for="(item, index) in routingDetailList"
:value="item.value"
:key="index"
>{{ item.label }}</Option
>
</Select>
<Select v-model="entity.routingDetailId">
<Option v-for="(item, index) in routingDetailList" :value="item.value" :key="index">{{ item.label }}</Option>
</Select>
</FormItem>
</Col>
<!-- <Col :span="8">
</Col>
<!-- <Col :span="8">
<FormItem :label="l('materialType')" prop="materialType">
<Dictionary
code="mes_xingchi_resource.material.materialReType"
......@@ -54,66 +49,48 @@
></Dictionary>
</FormItem>
</Col>-->
<Col :span="12">
<Col :span="12">
<!-- <FormItem :label="l('nameMaterial')" prop="materialNumber">
<Materiel :bomId="productBomId" v-model="entity.materialId" @on-change="change"></Materiel>
</FormItem>-->
<FormItem :label="l('nameMaterial')" prop="materialId">
<Select
v-model="entity.materialId"
placeholder="请选择"
style="width: 300px"
>
<Option
v-for="(item, index) in listData"
:key="index"
:value="item.value"
:label="item.label"
style="display: none"
></Option>
<Tree
key="mytree"
:data="dataTree"
ref="mytree"
:render="renderContent"
></Tree>
</Select>
<!-- <Materiel
<Select v-model="entity.materialId" placeholder="请选择" style="width: 300px">
<Option v-for="(item, index) in listData" :key="index" :value="item.value" :label="item.label" style="display: none"></Option>
<Tree key="mytree" :data="dataTree" ref="mytree" :render="renderContent"></Tree>
</Select>
<!-- <Materiel
v-model="entity.materialId"
@on-change="change"
:codeRuleType="1"
:setType="true"
></Materiel> -->
</FormItem>
</Col>
<!-- <Col :span="8" v-if="false">
</Col>
<!-- <Col :span="8" v-if="false">
<FormItem :label="l('nameMaterial')" prop="nameMaterial">
<Input v-model="entity.nameMaterial"></Input>
</FormItem>
</Col>-->
<Col :span="12">
<Col :span="12">
<FormItem :label="l('quantity')" prop="quantity">
<InputNumber
v-model="entity.quantity"
style="width: 100%"
></InputNumber>
<InputNumber v-model="entity.quantity" style="width: 100%"></InputNumber>
</FormItem>
</Col>
<Divider orientation="left">物料属性</Divider>
<Row>
<Col :span="12" v-if="entity.materialId">
<FormItem label="名称:">
<span>{{ entity.nameMaterial }}</span>
</FormItem>
</Col>
<Col :span="12" v-if="entity.materialId">
<FormItem label="编码:">
<span>{{ entity.materialNumber }}</span>
</FormItem>
</Col>
</Row>
<CustomProperties :materialId="entity.materialId" :forItem="forItem" />
<!-- <Col :span="8">
<Divider orientation="left">物料属性</Divider>
<Row>
<Col :span="12" v-if="entity.materialId">
<FormItem label="名称:">
<span>{{ entity.nameMaterial }}</span>
</FormItem>
</Col>
<Col :span="12" v-if="entity.materialId">
<FormItem label="编码:">
<span>{{ entity.materialNumber }}</span>
</FormItem>
</Col>
</Row>
<CustomProperties :materialId="entity.materialId" :forItem="forItem" />
<!-- <Col :span="8">
<FormItem :label="l('brand')" prop="brand">
<Input v-model="entity.brand"></Input>
</FormItem>
......@@ -150,203 +127,205 @@
</Col>-->
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" v-noClick>保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
<Button type="primary" @click="handleSubmit" v-noClick>保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</Form>
</template>
<script>
<script>
import Api from "./api";
import ApiDetail from "../api";
export default {
name: "Add",
data() {
return {
forItem: {},
listData: [],
dataTree: [],
entity: {
routingHeaderId: null,
routingDetailId: null,
routingStepId: 0,
quantity: null,
materialId: "",
materialType: "",
materialNumber: null,
nameMaterial: "",
brand: "",
specifications: "",
xhgg: "",
texture: "",
procurementStandards: "",
qualityGrade: "",
state: null,
extend: "",
remark: "",
drawNum: "",
json: {},
},
rules: {
routingDetailId: [
{
required: true,
message: "请选择工序",
type: "number",
trigger: "change",
},
],
materialId: [
{
required: true,
message: "请选择工序",
trigger: "change",
},
],
quantity: [
{
required: true,
type: "number",
message: "请选择工序",
trigger: "blur",
},
],
},
routingDetailList: [],
};
},
props: {
v: Object,
eid: Number,
headid: Number,
productBomId: {
type: Number,
default: null,
},
},
mounted() {
this.loadDetails();
this.getData();
},
methods: {
renderContent(h, { root, node, data }) {
//渲染树的样式
return h(
"span",
{
style: {
cursor: "pointer",
},
on: {
click: () => {
this.handleSelect(data); //手动选择树节点
name: "Add",
data() {
return {
forItem: {},
listData: [],
dataTree: [],
entity: {
routingHeaderId: null,
routingDetailId: null,
routingStepId: 0,
quantity: null,
materialId: "",
materialType: "",
materialNumber: null,
nameMaterial: "",
brand: "",
specifications: "",
xhgg: "",
texture: "",
procurementStandards: "",
qualityGrade: "",
state: 0,
extend: "",
remark: "",
drawNum: "",
json: {},
},
},
rules: {
routingDetailId: [{
required: true,
message: "请选择工序",
type: "number",
trigger: "change",
}, ],
materialId: [{
required: true,
message: "请选择工序",
trigger: "change",
}, ],
quantity: [{
required: true,
type: "number",
message: "请选择工序",
trigger: "blur",
}, ],
},
routingDetailList: [],
};
},
props: {
v: Object,
eid: Number,
headid: Number,
productBomId: {
type: Number,
default: null,
},
data.title
);
},
handleSelect(data) {
console.log(data);
mounted() {
this.loadDetails();
this.getData();
},
methods: {
renderContent(h, {
root,
node,
data
}) {
//渲染树的样式
return h(
"span", {
style: {
cursor: "pointer",
},
on: {
click: () => {
this.handleSelect(data); //手动选择树节点
},
},
},
data.title
);
},
handleSelect(data) {
console.log(data);
let obj = {
label: data.title,
value: data.materialId,
};
this.listData = [];
this.listData.push(obj);
this.entity.materialId = this.listData[0].value;
this.entity.nameMaterial = this.listData[0].label;
let obj = {
label: data.title,
value: data.materialId,
};
this.listData = [];
this.listData.push(obj);
this.entity.materialId = this.listData[0].value;
this.entity.nameMaterial = this.listData[0].label;
this.entity.nameMaterial = data.name;
this.entity.materialId = data.materialId;
this.entity.materialNumber = data.mmcode;
this.entity.json.nameMaterial = data.name;
this.entity.json.materialNumber = data.mmcode;
Api.getMaterial({ id: data.materialId }).then((r) => {
if (r.result) {
this.forItem = r.result;
}
});
},
getData() {
Api.alltree({ id: this.productBomId }).then((r) => {
if (r.success) {
this.dataTree = r.result;
// this.$Message.success("获取物料成功");
} else {
this.$Message.error("获取物料失败");
}
});
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.entity.routingHeaderId = this.headid;
Api.create(this.entity)
.then((r) => {
if (r.success) {
this.$Message.success("保存成功");
this.$emit("on-ok");
} else {
this.$Message.error("保存失败");
}
})
.catch((err) => {
this.$Message.error("保存失败");
console.warn(err);
this.entity.nameMaterial = data.name;
this.entity.materialId = data.materialId;
this.entity.materialNumber = data.mmcode;
this.entity.json.nameMaterial = data.name;
this.entity.json.materialNumber = data.mmcode;
Api.getMaterial({
id: data.materialId
}).then((r) => {
if (r.result) {
this.forItem = r.result;
}
});
}
});
},
handleClose() {
this.$emit("on-close");
},
// change(e, v) {
// console.log(e);
// console.log(v);
// this.entity.nameMaterial = e.name;
// this.entity.materialId = e.materialId;
// this.entity.materialNumber = e.mmcode;
},
getData() {
Api.alltree({
id: this.productBomId
}).then((r) => {
if (r.success) {
this.dataTree = r.result;
// this.$Message.success("获取物料成功");
} else {
this.$Message.error("获取物料失败");
}
});
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.entity.routingHeaderId = this.headid;
Api.create(this.entity)
.then((r) => {
if (r.success) {
this.$Message.success("保存成功");
this.$emit("on-ok");
} else {
this.$Message.error("保存失败");
}
})
.catch((err) => {
this.$Message.error("保存失败");
console.warn(err);
});
}
});
},
handleClose() {
this.$emit("on-close");
},
// change(e, v) {
// console.log(e);
// console.log(v);
// this.entity.nameMaterial = e.name;
// this.entity.materialId = e.materialId;
// this.entity.materialNumber = e.mmcode;
// this.entity.json.nameMaterial = e.name;
// this.entity.json.materialNumber = e.mmcode;
// this.forItem = v;
// },
loadDetails() {
//获取工序列表
let parms = {
headerID: this.headid,
};
ApiDetail.pagedDetails(parms).then((r) => {
let tempDetails = r.result;
let tempD = [];
tempDetails.forEach((data) => {
let tempObj = {};
tempObj.value = data.id;
tempObj.label = data.taskSeq + " " + data.name;
tempD.push(tempObj);
});
this.routingDetailList = tempD;
});
},
l(key) {
key = "routingsupporting" + "." + key;
return this.$t(key);
},
},
watch: {
v() {
this.entity = this.$u.clone(this.v);
},
eid(v) {
if (v > 0) {
this.load(v);
}
// this.entity.json.nameMaterial = e.name;
// this.entity.json.materialNumber = e.mmcode;
// this.forItem = v;
// },
loadDetails() {
//获取工序列表
let parms = {
headerID: this.headid,
};
ApiDetail.pagedDetails(parms).then((r) => {
let tempDetails = r.result;
let tempD = [];
tempDetails.forEach((data) => {
let tempObj = {};
tempObj.value = data.id;
tempObj.label = data.taskSeq + " " + data.name;
tempD.push(tempObj);
});
this.routingDetailList = tempD;
});
},
l(key) {
key = "routingsupporting" + "." + key;
return this.$t(key);
},
},
productBomId(v) {
if (v > 0) {
}
watch: {
v() {
this.entity = this.$u.clone(this.v);
},
eid(v) {
if (v > 0) {
this.load(v);
}
},
productBomId(v) {
if (v > 0) {}
},
},
},
};
</script>
......@@ -461,7 +461,7 @@ export default {
}
})
.catch((err) => {
this.disabled = false;
this.$Message.error("保存失败");
console.warn(err);
});
......
......@@ -18,6 +18,7 @@
<Input
placeholder="请输入文档名称/编号"
v-model="easySearch.keys.value"
clearable
/>
</FormItem>
<FormItem>
......@@ -429,6 +430,7 @@ export default {
}
.shuo-ming {
display: -webkit-inline-box;
// display: inline-block;
}
.a-icon {
text-align: right;
......
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