Commit 4a4ee0ca authored by 仇晓婷's avatar 仇晓婷

站内邮件、bug;ok

parent 5c44c709
......@@ -5,14 +5,16 @@
<Filed :span="8" name="编码:">{{!entity.code?'未分配':entity.code}}</Filed>
<Filed :span="8" name="名称:">{{entity.name}}</Filed>
<Filed :span="8" name="状态:">
<State code="materail.main.status" :value="parseInt(entity.status)" />
<State code="material.main.status" :value="parseInt(entity.status)" />
</Filed>
<Filed :span="8" name="版本:">
<State code="material.main.version" :value="parseInt(entity.version)" />
</Filed>
<Filed :span="8" name="描述:">{{entity.description}}</Filed>
</Row>
<Divider orientation="center"><h3>扩展属性</h3></Divider>
<Divider orientation="center">
<h3>扩展属性</h3>
</Divider>
<Row>
<Filed v-for="li in fileds" :key="li.field" :span="li.span" :name="li.title+':'">
<State v-if="li.dataType==3" :code="li.note" :value="entity[li.field]" />
......@@ -37,8 +39,8 @@ export default {
props: {
idVal: {
type: String,
default: ""
}
default: "",
},
},
async fetch({ store, params }) {
await store.dispatch("loadDictionary"); // 加载数据字典
......@@ -46,16 +48,16 @@ export default {
data() {
return {
entity: {
state: ""
state: "",
},
fileds: []
fileds: [],
};
},
created() {
this.dataImmut = [];
this.dataMut = [];
Api.get({ Id: this.idVal }).then(r => {
Api.get({ Id: this.idVal }).then((r) => {
console.log(r);
if (r.success) {
let farmData = {};
......@@ -66,24 +68,24 @@ export default {
{
conditionalType: "Equal",
fieldName: "categoryId",
fieldValue: farmData.rootCategoryId
}
fieldValue: farmData.rootCategoryId,
},
];
Api.listTable({
conditions: conditions,
sortBy: "id",
isDesc: false
}).then(r => {
isDesc: false,
}).then((r) => {
if (r.result) {
this.fileds = r.result.filter(function(item) {
this.fileds = r.result.filter(function (item) {
item.span = 8;
if (item.dataType == 8 || item.dataType == 5) {
item.span = 24;
}
return item.fieldType != 1;
});
this.fileds.map(u => {
this.fileds.map((u) => {
let v = "";
if (u.dataType == 1 || u.dataType == 2) {
v = 0;
......@@ -98,8 +100,8 @@ export default {
});
},
methods: {
load(v) {}
load(v) {},
},
watch: {}
watch: {},
};
</script>
\ No newline at end of file
import Api from '@/plugins/request'
export default {
index: `${systemUrl}/usermessage/paged`,
paged(params) {
return Api.get(`${systemUrl}/usermessage/paged`, params); //消息历史记录列表
},
get(params) {
return Api.get(`${systemUrl}/usermessage/get`, params);
},
getUserInfo(params) {
return Api.get(`${systemUrl}/user/getuserinfo`, params);
},
sendmessagetousers(params) { //给指定用户发送消息
return Api.post(`${systemUrl}/usermessage/sendmessagetousers`, params);
},
// 获取打你审批数据
getpaged(params) {
......@@ -22,5 +32,5 @@ export default {
list(params) {
return Api.post(`${systemUrl}/newmessage/list`, params); //获取列表信息
},
}
\ No newline at end of file
......@@ -4,40 +4,101 @@
<template slot="easySearch">
<Form ref="formInline" :model="easySearch" inline>
<FormItem prop="keys">
<Input placeholder="请输入消息标题" v-model="easySearch.keys.value" v-width="260" />
<Input placeholder="请输入消息标题" v-model="easySearch.keys.value" v-width="260" clearable />
</FormItem>
<FormItem>
<Button type="primary" @click="search">查询</Button>
</FormItem>
</Form>
</template>
<template slot="buttons">
<Button type="primary" @click="add">站内邮件</Button>
</template>
</DataGrid>
<Modal v-model="modal" :title="title" width="1200" footer-hide>
<component
:is="detail"
:eid="curId"
:cartList="this.$u.clone(this.$store.state.cart)"
@on-close="cancel"
@on-ok="ok"
/>
<Modal v-model="modal" title="查看详情" width="1200" footer-hide>
<div class="detail">
<Row>
<Filed :span="12" name="标题">{{entity.title}}</Filed>
<Filed :span="12" name="接受时间">{{entity.creationTime}}</Filed>
<Filed :span="24" name="内容">{{entity.content}}</Filed>
<Filed :span="12" name="发送人">{{entity.senderId}}</Filed>
<Filed :span="12" name="接受人">{{entity.receiverId}}</Filed>
<Filed :span="24" name="状态" style="color:red">{{entity.messageType== 1 ? "已读" : ""}}</Filed>
</Row>
</div>
</Modal>
<Modal v-model="modal1" title="站内邮件" width="1000" :mask-closable="false" footer-hide>
<Form ref="form" :model="entity1" :rules="rules" :label-width="100">
<Row>
<Col span="12">
<FormItem label="收件人" prop="receiverIds">
<UserSelect ref="userSelected" v-model="entity1.receiverIds" :multiple="true" />
</FormItem>
</Col>
<Col :span="12">
<FormItem label="标题" prop="title">
<Input v-model="entity1.title"></Input>
</FormItem>
</Col>
<Col :span="24">
<FormItem label="内容" prop="content">
<Input v-model="entity1.content" type="textarea" :rows="5"></Input>
</FormItem>
</Col>
<Col :span="24">
<FormItem label="上传附件">
<files ref="refFile" :parms="parms" files />
</FormItem>
</Col>
</Row>
<FormItem>
<Button type="primary" @click="handleSubmit" :disabled="disabled">保存</Button>
<Button @click="handleClose" class="ml20">取消</Button>
</FormItem>
</Form>
</Modal>
</div>
</template>
<script>
// import Api from "./api";
import Api from "./api";
import userVue from "../../components/page/user.vue";
export default {
name: "Add",
data() {
return {
action: "", //Api.index1
action: Api.index,
easySearch: {
keys: { op: "serialNumber,customer", value: null },
keys: { op: "title", value: null },
},
detail: null,
dataList: [],
curId: 0,
disabled: false,
entity: {},
modal1: false,
modal: false,
title: "归还",
entity1: {
receiverIds: null,
},
parms: {
app: "UserMessage",
eid: null,
name: "",
field: "",
},
rules: {
title: [
{ required: true, message: "必填", trigger: "blur", type: "string" },
],
content: [
{ required: true, message: "必填", trigger: "blur", type: "string" },
],
receiverIds: [
{
required: true,
message: "请选择人员!",
trigger: "blur",
type: "array",
},
],
},
columns: [
{
type: "index",
......@@ -46,69 +107,129 @@ export default {
},
{
title: "标题",
key: "serialNumber",
key: "title",
width: 200,
},
{
title: "内容",
key: "content",
tooltip: true,
},
{
key: "creationTime",
title: "接受时间",
width: 200,
},
{
title: "接受人",
key: "libraryTube",
title: "发送人",
key: "receiverId",
width: 120,
type: "user",
},
{
title: "发送人",
key: "customer",
title: "接受人",
key: "senderId",
width: 120,
type: "user",
},
{
title: "状态",
key: "status",
code: "resource.record.status",
key: "messageType",
width: 120,
render: (h, params) => {
return h(
"div",
{
style: {
color: "red",
},
},
params.row.messageType == 1 ? "已读" : ""
);
},
},
{
title: this.l("action"),
key: "action",
width: 150,
align: "center",
render: (h, params) => {
return h("div", { class: "action" }, [
h(
"a",
{
class: "details",
on: { click: () => this.details(params.row.id) },
},
"查看"
),
]);
},
},
// {
// title: this.l("action"),
// key: "action",
// width: 150,
// align: "center",
// render: (h, params) => {
// return h("div", { class: "action" }, [
// h(
// "a",
// {
// class: "details",
// on: { click: () => this.details(params.row.id) },
// },
// params.row.status == 0 ? "归还" : ""
// ),
// ]);
// },
// },
],
name: "",
resource: [],
selectList: [],
libraryTube: this.$store.state.userInfo.userName, //库管员
};
},
async fetch({ store, params }) {
await store.dispatch("loadDictionary"); // 加载数据字典
},
props: {},
mounted() {},
mounted() {
this.parms.eid = this.$u.guid();
this.$refs.refFile.intFiles();
},
methods: {
details(id) {
this.curId = id;
// this.detail = () => import("./return");
this.modal = true;
Api.get({ id: id }).then((r) => {
this.entity = r.result;
});
},
handleClose() {
this.$emit("on-close");
add() {
this.entity1 = {};
this.modal1 = true;
this.disabled = false;
},
handleSubmit() {
this.$refs.form.validate((v) => {
if (v) {
this.disabled = true;
this.entity1.attachment = "";
if (this.$refs.refFile.nameList.length > 0) {
let nameList = this.$refs.refFile.nameList;
let names = [];
nameList.forEach((e) => {
names.push(e.fileName);
});
this.entity1.attachment = JSON.stringify(names)
.replace("[", "")
.replace("]", "")
.replace(/\"/g, ""); //附件本地库暂存文件名称
}
let ids = this.entity1.receiverIds;
this.entity1.receiverIds = ids.join(",");
this.entity1.senderId = this.$store.state.userInfo.userId;
Api.sendmessagetousers(this.entity1)
.then((r) => {
if (r.success) {
this.$Message.success("保存成功");
this.modal1 = false;
} else {
this.$Message.error("保存失败");
this.disabled = false;
}
this.$refs.refFile.intFiles();
})
.catch((err) => {
this.disabled = false;
this.$Message.error("保存失败");
});
}
});
},
selectInfo(value) {
this.selectList = [];
this.selectList = value;
handleClose() {
this.modal1 = false;
this.$refs.form.resetFields();
},
l(key) {
let vkey = "resource" + "." + key;
......@@ -117,15 +238,6 @@ export default {
search() {
this.$refs.grid.reload(this.easySearch);
},
ok() {
this.$refs.grid.load();
this.modal = false;
this.curId = 0;
},
cancel() {
this.curId = 0;
this.modal = false;
},
},
watch: {},
};
......
......@@ -21,23 +21,26 @@
<Dictionary code="material.code.status" v-model="entity.status"></Dictionary>
</FormItem>
</Col>
<Col :span="12">
<!-- :disabled="!(entity.isEdit)" -->
<FormItem :label="l('levelNum')" prop="levelNum">
<InputNumber v-model="entity.levelNum" :disabled="!(entity.isEdit)" :max="10" :min="1"></InputNumber>
<InputNumber v-model="entity.levelNum" :max="10" :min="1"></InputNumber>
</FormItem>
</Col>
<Col :span="12">
<!-- :disabled="!(entity.isEdit)" -->
<FormItem :label="l('codeLength')" prop="codeLength">
<InputNumber v-model="entity.codeLength" :disabled="!(entity.isEdit)" :max="5" :min="1"></InputNumber>
<InputNumber v-model="entity.codeLength" :max="5" :min="1"></InputNumber>
</FormItem>
</Col>
<Col :span="12">
<Col :span="12">
<!-- :disabled="!(entity.isEdit)" -->
<FormItem :label="l('materialCodeLength')" prop="materialCodeLength">
<InputNumber v-model="entity.materialCodeLength" :disabled="!(entity.isEdit)" :max="10" :min="1"></InputNumber>
<InputNumber v-model="entity.materialCodeLength" :max="10" :min="1"></InputNumber>
</FormItem>
</Col>
<Col :span="24">
<Col :span="24">
<FormItem :label="l('description')" prop="description">
<Input v-model="entity.description" type="textarea" :rows="2"></Input>
</FormItem>
......@@ -63,12 +66,12 @@ export default {
status: [{ required: true, message: "必填" }],
levelNum: [{ required: true, message: "必填" }],
codeLength: [{ required: true, message: "必填" }],
materialCodeLength: [{ required: true, message: "必填" }]
}
materialCodeLength: [{ required: true, message: "必填" }],
},
};
},
props: {
eid: Number
eid: Number,
},
mounted() {
if (this.eid > 0) {
......@@ -77,16 +80,16 @@ export default {
},
methods: {
load(v) {
Api.get({ id: v }).then(r => {
Api.get({ id: v }).then((r) => {
this.entity = r.result;
});
},
handleSubmit() {
this.$refs.form.validate(v => {
this.$refs.form.validate((v) => {
if (v) {
this.disabled = true;
Api.update(this.entity)
.then(r => {
.then((r) => {
this.disabled = false;
if (r.success) {
this.$Message.success("保存成功");
......@@ -95,7 +98,7 @@ export default {
this.$Message.error("保存失败");
}
})
.catch(err => {
.catch((err) => {
this.disabled = false;
this.$Message.error("保存失败");
console.warn(err);
......@@ -109,14 +112,14 @@ export default {
l(key) {
key = "coderule" + "." + key;
return this.$t(key);
}
},
},
watch: {
eid(v) {
if (v != 0) {
this.load(v);
}
}
}
},
},
};
</script>
\ No newline at end of file
......@@ -31,13 +31,17 @@
</FormItem>
</Col>
</Row>
<Row :gutter="16">
<Col span="11">
<FormItem label="所属部门" prop="shop_name">
<FormItem label="所属部门" prop="shop_id">
<departmentSelect v-model="formItem.shop_id" @on-change="departChange"></departmentSelect>
</FormItem>
<!-- <FormItem label="所属部门" prop="shop_name">
<Input v-model="formItem.shop_name" readonly placeholder="请选择..." style="width:327px">
<Button slot="append" @click="selectDepart">选择</Button>
</Input>
</FormItem>
</FormItem>-->
</Col>
<Col span="11" offset="1">
<FormItem label="设备IP" prop="equip_ip">
......@@ -52,7 +56,8 @@
<span>上传图片</span>
<Icon type="ios-cloud-upload" size="30" style="color: #3399ff"></Icon>
</Upload>-->
<inputFile ref="refqcFile" v-model="imgName" :parms="qcfileparms" files />
<files ref="refFile" :parms="parms" fileFormat :Photos="true" @clickItem="clickData" />
<!-- <inputFile ref="refqcFile" v-model="imgName" :parms="qcfileparms" files /> -->
</FormItem>
</Col>
<Col :span="12">
......@@ -89,12 +94,18 @@ import Department from "@/components/modalTree/department.vue";
import service from "@/plugins/request";
export default {
components: {
Department
Department,
},
name: "",
data() {
return {
qcfileparms: "app=newEquipment&eid=23&name=newEquipment",
// qcfileparms: "app=newEquipment&eid=23&name=newEquipment",
parms: {
app: "newEquipment", //服务
eid: this.$u.guid(), //记录id
name: "", //表名process_case
field: "", //字段名
},
modalShow: false,
showDeptTree: false,
saveId: "",
......@@ -113,7 +124,7 @@ export default {
shop_id: "",
shop_name: "",
// isimportant: 2,
location: ""
location: "",
// capability_value: 1
},
property: true,
......@@ -123,17 +134,17 @@ export default {
{
required: true,
message: "设备编号不能为空!",
trigger: "blur"
}
trigger: "blur",
},
],
shop_name: [
shop_id: [
{
required: true,
message: "所属部门不能为空!",
trigger: "blur"
}
]
}
trigger: "blur",
},
],
},
};
},
created() {
......@@ -145,7 +156,7 @@ export default {
const imgPathsArr = JSON.parse(newName);
this.formItem.equip_pic = imgPathsArr[0].filePath;
}
}
},
},
methods: {
selectDepart() {
......@@ -154,14 +165,14 @@ export default {
laodaction() {
let url = `${systemUrl}/equiptype/getpaged`,
that = this;
service.get(`${url}`).then(res => {
service.get(`${url}`).then((res) => {
let selectdata = res.result.items;
// console.log(selectdata)
selectdata.forEach(item => {
selectdata.forEach((item) => {
that.cityList.push({
value: item.equip_type_name,
label: item.equip_type_name,
id: item.id
id: item.id,
});
// console.log(that.cityList)
});
......@@ -193,7 +204,7 @@ export default {
let arr = this.formItem.equip_type;
let str = arr.join(",");
let url = `${systemUrl}/equipinfo/createorupdate`;
var ar1 = this.data1.find(val => {
var ar1 = this.data1.find((val) => {
if (val.id != saveId) return val.equip_id == this.formItem.equip_id;
});
if (ar1) {
......@@ -218,10 +229,10 @@ export default {
location: this.formItem.location,
// capability_value: this.formItem.capability_value,
property: this.property,
shop_name: this.formItem.shop_name
shop_name: this.formItem.shop_name,
};
// console.log(paramsdata);
service.post(`${url}`, { equipInfo: paramsdata }).then(res => {
service.post(`${url}`, { equipInfo: paramsdata }).then((res) => {
if (res.success) {
this.$emit("getMessage");
this.modalShow = false;
......@@ -235,7 +246,7 @@ export default {
let str = arr.join(",");
//console.log(str);
let url = `${systemUrl}/equipinfo/createorupdate`;
var ar = this.data1.find(val => {
var ar = this.data1.find((val) => {
return val.equip_id == this.formItem.equip_id;
});
if (ar) {
......@@ -248,6 +259,14 @@ export default {
} else {
this.property = "";
}
if (this.$refs.refFile.nameList.length > 0) {
// this.entity.filePath = this.$refs.refFile.nameList[0].filePath
this.formItem.filePaths = this.parms.eid;
this.formItem.equip_pic = this.parms.eid;
} else {
this.formItem.filePath = "";
this.formItem.filePaths = "";
}
let paramsdata = {
id: this.saveId,
equip_id: this.formItem.equip_id,
......@@ -261,10 +280,10 @@ export default {
location: this.formItem.location,
// capability_value: this.formItem.capability_value,
property: this.property,
shop_name: this.formItem.shop_name
shop_name: this.formItem.shop_name,
};
//console.log(this.formItem.equip_type);
service.post(`${url}`, { equipInfo: paramsdata }).then(res => {
service.post(`${url}`, { equipInfo: paramsdata }).then((res) => {
if (res.success) {
this.$emit("getMessage");
this.modalShow = false;
......@@ -272,8 +291,14 @@ export default {
}
});
}
}
}
},
departChange(v, items) {
this.formItem.shop_name = items.name;
},
clickData(data, liUrl) {
this.formItem.filePath = liUrl;
},
},
};
</script>
......
......@@ -387,7 +387,7 @@ import service from "@/plugins/request";
export default {
components: {
TreeType,
NewEquipment
NewEquipment,
},
name: "",
data() {
......@@ -437,7 +437,7 @@ export default {
plan_start: "",
plan_finish: "",
input_time: "",
notes: ""
notes: "",
},
formItemMain1: {
equip_name: "",
......@@ -448,35 +448,35 @@ export default {
actual_start: "",
actual_finish: "",
failure_notes: "",
status: ""
status: "",
},
sysdata: [
{
value: "月度保养",
label: "月度保养"
label: "月度保养",
},
{
value: "季度保养",
label: "季度保养"
label: "季度保养",
},
{
value: "精度检查",
label: "精度检查"
label: "精度检查",
},
{
value: "常规保养",
label: "常规保养"
}
label: "常规保养",
},
],
sysdata1: [
{
value: "维护中",
label: "维护中"
label: "维护中",
},
{
value: "完成",
label: "维护完成"
}
label: "维护完成",
},
],
column: [
// {
......@@ -487,19 +487,19 @@ export default {
{
type: "index",
width: 60,
align: "center"
align: "center",
},
{
title: "设备名称",
key: "equip_name"
key: "equip_name",
},
{
title: "设备编号",
key: "equip_id"
key: "equip_id",
},
{
title: "设备类型",
key: "type_name"
key: "type_name",
},
{
title: "设备图片",
......@@ -512,30 +512,30 @@ export default {
attrs: {
oprate: "detail",
href: this.fileUrlPath,
target: "_blank"
target: "_blank",
},
on: {
click: () => {
this.downFile(params);
}
}
},
},
},
"查看图片"
)
),
]);
}
},
},
{
title: "设备状态",
key: "equip_status"
key: "equip_status",
},
{
title: "设备IP",
key: "equip_ip"
key: "equip_ip",
},
{
title: "所属部门",
key: "shop_name"
key: "shop_name",
},
// {
// title: "是否关重",
......@@ -548,7 +548,7 @@ export default {
// },
{
title: "位置",
key: "location"
key: "location",
},
// {
// title: "能力系数",
......@@ -579,13 +579,13 @@ export default {
attrs: {
oprate: "edit",
// class: "edit",
title: "编辑"
title: "编辑",
},
on: {
click: () => {
this.edit(params);
}
}
},
},
},
"编辑"
),
......@@ -594,16 +594,16 @@ export default {
{
attrs: {
oprate: "delete",
title: "删除"
title: "删除",
},
style: {
color: "red"
color: "red",
},
on: {
click: () => {
this.del(params);
}
}
},
},
},
"删除"
),
......@@ -612,13 +612,13 @@ export default {
{
attrs: {
oprate: "detail",
title: "保养"
title: "保养",
},
on: {
click: () => {
this.Main(params);
}
}
},
},
},
"保养"
),
......@@ -627,19 +627,19 @@ export default {
{
attrs: {
oprate: "detail",
title: "维修"
title: "维修",
},
on: {
click: () => {
this.Main1(params);
}
}
},
},
},
"维修"
)
),
]);
}
}
},
},
],
column1: [
// {
......@@ -649,40 +649,40 @@ export default {
// },
{
title: "维护状态",
key: "status"
key: "status",
},
{
title: "计划人",
key: "input_name"
key: "input_name",
},
{
title: "报修时间",
key: "input_time"
key: "input_time",
},
{
title: "保养人",
key: "maintain_name"
key: "maintain_name",
},
{
title: "计划开始时间",
key: "plan_start"
key: "plan_start",
},
{
title: "计划完成时间",
key: "plan_finish"
key: "plan_finish",
},
{
title: "实际开始时间",
key: "actual_start"
key: "actual_start",
},
{
title: "实际结束时间",
key: "actual_finish"
key: "actual_finish",
},
{
title: "维保类型",
key: "equip_down_type"
}
key: "equip_down_type",
},
],
datatable1: [],
datatable: [
......@@ -694,7 +694,7 @@ export default {
name4: "正常",
name5: "102.10.0.80",
name6: "车间1",
name7: ""
name7: "",
},
{
name: "3D打印机",
......@@ -704,7 +704,7 @@ export default {
name4: "正常",
name5: "102.10.0.80",
name6: "车间1",
name7: ""
name7: "",
},
{
name: "3D打印机",
......@@ -714,10 +714,10 @@ export default {
name4: "正常",
name5: "102.10.0.80",
name6: "车间1",
name7: ""
}
name7: "",
},
],
page: 1 //当前页 整形 选填 默认1
page: 1, //当前页 整形 选填 默认1
};
},
created() {
......@@ -786,9 +786,9 @@ export default {
equip_name: this.value1,
shopid: this.shopid,
pageindex: this.page,
pageSize: this.pageSize
pageSize: this.pageSize,
})
.then(res => {
.then((res) => {
this.datatable = res.result.items;
this.total = res.result.totalCount;
});
......@@ -836,7 +836,7 @@ export default {
shop_name: "",
isimportant: 2,
location: "",
capability_value: 1
capability_value: 1,
};
},
// 删除
......@@ -849,7 +849,7 @@ export default {
},
onCancel: () => {
this.$Message.info("已取消");
}
},
});
},
// 分页
......@@ -904,10 +904,10 @@ export default {
equip_down_type: this.formItemMain.equip_down_type,
plan_start: this.formItemMain.plan_start,
plan_finish: this.formItemMain.plan_finish,
maintain_type: "1"
maintain_type: "1",
};
console.log(paramsdata);
service.post(`${url}`, { equipMaintainPlan: paramsdata }).then(res => {
service.post(`${url}`, { equipMaintainPlan: paramsdata }).then((res) => {
if (res.success) {
this.changestatus(this.eid);
this.show = false;
......@@ -944,10 +944,10 @@ export default {
notes: this.formItemMain.notes,
input_time: this.formItemMain.input_time,
equip_down_type: "设备故障",
maintain_type: "2"
maintain_type: "2",
};
console.log(paramsdata);
service.post(`${url}`, { equipMaintainPlan: paramsdata }).then(res => {
service.post(`${url}`, { equipMaintainPlan: paramsdata }).then((res) => {
if (res.success) {
this.changestatus(this.eid);
this.show = false;
......@@ -959,10 +959,10 @@ export default {
});
},
edit(data) {
this.$refs.equipment.$refs.refqcFile.newName = data.row.equip_pic;
// this.$refs.equipment.$refs.refqcFile.newName = data.row.equip_pic;
this.$refs.equipment.data1 = this.datatable;
let url = `${systemUrl}/equipbelongtype/getbyid`;
service.get(`${url}`, { Id: data.row.id }).then(res => {
service.get(`${url}`, { Id: data.row.id }).then((res) => {
console.log(data);
this.typepk = res.result;
this.$refs.equipment.title = "编辑设备";
......@@ -978,7 +978,7 @@ export default {
shop_name: data.row.shop_name,
isimportant: data.row.isimportant,
location: data.row.location,
capability_value: data.row.capability_value
capability_value: data.row.capability_value,
};
if (data.row.property == 2) {
this.$refs.equipment.property = true;
......@@ -994,7 +994,7 @@ export default {
this.seleId = data.row.id;
let url = `${systemUrl}/equipinfo/delete`,
uId = this.seleId;
service.delete(`${systemUrl}/equipinfo/delete?id=${uId}`).then(res => {
service.delete(`${systemUrl}/equipinfo/delete?id=${uId}`).then((res) => {
if (res.success) {
this.laodaction();
this.$Message.success("删除成功");
......@@ -1007,7 +1007,7 @@ export default {
let url = `${systemUrl}/equipmaintainplan/getpaged`;
service
.get(`${url}`, { equipid: this.seleId, maintain_type: "1" })
.then(res => {
.then((res) => {
//console.log(res)
this.datatable1 = res.result.items;
if (this.datatable1.length == 0) {
......@@ -1025,7 +1025,7 @@ export default {
let url = `${systemUrl}/equipmaintainplan/getpaged`;
service
.get(`${url}`, { equipid: this.seleId, maintain_type: "2" })
.then(res => {
.then((res) => {
//console.log(res)
this.datatable1 = res.result.items;
if (this.datatable1.length == 0) {
......@@ -1040,14 +1040,14 @@ export default {
let url = `${systemUrl}/equipmaintainplan/getpaged`;
service
.get(`${url}`, { equipid: id, maintain_type: this.borw })
.then(res => {
.then((res) => {
//console.log(res)
this.datatable1 = res.result.items;
});
},
changestatus(id) {
let url = `${systemUrl}/equipmaintainplan/changestatus`;
service.post(`${url}`, { equipid: id }).then(res => {
service.post(`${url}`, { equipid: id }).then((res) => {
//console.log(res)
});
},
......@@ -1091,10 +1091,10 @@ export default {
failure_notes: this.formItemMain1.failure_notes,
input_time: this.inputtime,
maintain_type: this.borw,
status: this.formItemMain1.status
status: this.formItemMain1.status,
};
console.log(paramsdata);
service.post(`${url}`, { equipMaintainPlan: paramsdata }).then(res => {
service.post(`${url}`, { equipMaintainPlan: paramsdata }).then((res) => {
if (res.success) {
this.changestatus(this.eid);
this.loadmain(this.eid);
......@@ -1120,7 +1120,7 @@ export default {
// this.mDatas.splice(0)
// this.$http.sysUser.getSearchTable2(this.mDatas, this.searchObj)
// }
}
},
},
computed: {
searchList() {
......@@ -1142,8 +1142,8 @@ export default {
return nodeList;
}
return newNodeList;
}
}
},
},
};
</script>
......
......@@ -21,20 +21,18 @@ export default {
key: "routingDetailNo",
title: this.l("routingDetailNo"),
align: "left",
width: 100,
},
{
key: "routingDetailName",
title: this.l("routingDetailName"),
align: "left",
},
{
key: "materialType",
title: this.l("materialType"),
align: "center",
code: "mes_xingchi_resource.material.materialReType",
width: 100,
},
// {
// key: "materialType",
// title: this.l("materialType"),
// align: "center",
// code: "mes_xingchi_resource.material.materialReType",
// },
{
key: "materialNumber",
title: this.l("materialNumber"),
......@@ -48,42 +46,40 @@ export default {
{
key: "totalCount",
title: this.l("quantity"),
align: "right",
width: 80,
},
{
key: "brand",
title: this.l("brand"),
align: "left",
},
{
key: "specifications",
title: this.l("specifications"),
align: "left",
},
{
key: "xhgg",
title: this.l("xhgg"),
align: "left",
easy: true,
high: true,
hide: true,
},
{
key: "texture",
title: this.l("texture"),
align: "left",
},
{
key: "procurementStandards",
title: this.l("procurementStandards"),
align: "left",
},
{
key: "qualityGrade",
title: this.l("qualityGrade"),
align: "left",
},
// {
// key: "brand",
// title: this.l("brand"),
// align: "left",
// },
// {
// key: "specifications",
// title: this.l("specifications"),
// align: "left",
// },
// {
// key: "xhgg",
// title: this.l("xhgg"),
// align: "left",
// easy: true,
// high: true,
// hide: true,
// },
// {
// key: "texture",
// title: this.l("texture"),
// align: "left",
// },
// {
// key: "procurementStandards",
// title: this.l("procurementStandards"),
// align: "left",
// },
// {
// key: "qualityGrade",
// title: this.l("qualityGrade"),
// align: "left",
// },
{
key: "drawNum",
title: this.l("drawNum"),
......
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