Merge remote-tracking branch 'origin/master'

yangwl
zhaoxiaolin 11 months ago
commit 14126b2f22

@ -114,3 +114,21 @@ export function getAuxiliaryEquipmentList(query) {
params: query
});
}
// 查询维修记录
export function getWXRecordsList(query) {
return request({
url: '/wms/equipment/getWXRecordsList',
method: 'get',
params: query
});
}
// 查询保养记录
export function getBYRecordsList(query) {
return request({
url: '/wms/equipment/getBYRecordsList',
method: 'get',
params: query
});
}

@ -1729,7 +1729,7 @@ export default {
indexMethod(index) {
return index + 1;
},
// -
// -
listeningTime() {
if (this.form.workEndTime != null && this.form.workStartTime != null) {
var time1 = moment(this.form.workStartTime);
@ -1738,26 +1738,14 @@ export default {
let { _data } = duration;
console.log("打印维修时间", _data);
//
this.form.workCostTime =
_data.years +
"年" +
_data.months +
"月" +
_data.days +
"日" +
_data.hours +
"小时" +
_data.minutes +
"分" +
_data.seconds +
"秒";
this.form.workCostTime = (_data.days*24 + _data.hours + (_data.minutes/60) + (_data.seconds/3600)).toFixed(1)+ "小时" ;
}
},
// -
// listeningDownTime() {
// if (this.form.actualDownEndTime != null && this.form.actualDownStartTime != null) {
// var time1 = moment(this.form.actualDownStartTime);
// var time2 = moment(this.form.actualDownEndTime);
// -
// listeningTime() {
// if (this.form.workEndTime != null && this.form.workStartTime != null) {
// var time1 = moment(this.form.workStartTime);
// var time2 = moment(this.form.workEndTime);
// let duration = moment.duration(time2.diff(time1));
// let { _data } = duration;
// console.log("", _data);

@ -907,6 +907,18 @@
:equipmentCode="form.equipmentCode"
></ItemEquipment>
</el-tab-pane>
<el-tab-pane label="维修记录" >
<ItemWXRecords
:optType="optType"
:equipmentCode="form.equipmentCode"
></ItemWXRecords>
</el-tab-pane>
<el-tab-pane label="保养记录" >
<ItemBYRecords
:optType="optType"
:equipmentCode="form.equipmentCode"
></ItemBYRecords>
</el-tab-pane>
<el-tab-pane label="设备相关图片">
<el-descriptions
:column="1"
@ -1037,6 +1049,8 @@ import { Message } from "element-ui";
import { getToken } from "@/utils/auth";
import ItemSelectPerson from "./itemPerson.vue";
import ItemEquipment from "./itemEquipment.vue";
import ItemWXRecords from "./itemWXRecords.vue";
import ItemBYRecords from "./itemBYRecords.vue";
export default {
name: "Equipment",
@ -1046,7 +1060,7 @@ export default {
"equipment_status",
"equipment_category",
],
components: { ItemSelectPerson, ItemEquipment },
components: { ItemSelectPerson, ItemEquipment , ItemWXRecords , ItemBYRecords},
data() {
return {
CS: {

@ -0,0 +1,167 @@
<template>
<div class="app-container">
<el-table
:data="itemList"
>
<!-- 序号 -->
<el-table-column
type="index"
width="90"
align="center"
:index="indexMethod"
label="序号"
fixed
/>
<el-table-column
label="单号"
align="center"
width="200"
prop="orderCode"
fixed
/>
<el-table-column
label="循环周期"
align="center"
prop="planLoop"
width="80"
/>
<el-table-column
label="实际开始时间"
align="center"
prop="orderStart"
width="200"
/>
<el-table-column
label="实际结束时间"
align="center"
prop="orderEnd"
width="200"
/>
<el-table-column
label="工单状态"
align="center"
prop="orderStatus"
width="100"
>
<template slot-scope="scope">
{{
scope.row.orderStatus == 0
? "待处理"
: scope.row.orderStatus == 1
? "已完成"
: scope.row.orderStatus == 2
? "已逾期"
: scope.row.orderStatus == 3
? "进行中"
: ""
}}
</template>
</el-table-column>
<el-table-column
label="工单费用"
align="center"
prop="orderCost"
width="100"
/>
<el-table-column
label="责任人"
align="center"
prop="planPerson"
width="100"
/>
<el-table-column
label="工单用时"
align="center"
prop="orderCostTime"
width="100"
/>
<el-table-column
label="签字"
align="center"
prop="orderSignPerson"
width="100"
/>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
import { getBYRecordsList } from "@/api/wms/equipment";
import { Message } from "element-ui";
export default {
name: "MdItemSingle",
dicts: ["equipment_status"],
data() {
return {
showFlag: false,
//
selectedItemId: undefined,
selectedRows: undefined,
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
queryParams: {
pageNum: 1,
pageSize: 10,
equipmentCode: this.equipmentCode,
},
};
},
props: {
equipmentCode: undefined,
optType: undefined,
},
created() {
this.getList();
},
methods: {
//
cancel() {
this.showFlag = false;
this.reset();
},
//
reset() {
this.form = {
itemId: null,
itemCode: this.processId,
itemType: null,
};
this.resetForm("form");
},
//
indexMethod(index) {
return index + 1;
},
/** 查询设备编码列表*/
getList() {
getBYRecordsList(this.queryParams).then((response) => {
this.itemList = response.rows;
this.total = response.total;
});
},
},
};
</script>

@ -0,0 +1,160 @@
<template>
<div class="app-container">
<el-table
:data="itemList"
>
<!-- 序号 -->
<el-table-column
type="index"
width="90"
align="center"
:index="indexMethod"
label="序号"
fixed
/>
<el-table-column
label="维修单号"
align="center"
prop="workCode"
fixed
width="200"
/>
<el-table-column
label="维修人员"
align="center"
prop="workPerson"
width="100"
/>
<el-table-column
label="维修班组"
align="center"
prop="workTeam"
width="100"
/>
<el-table-column
label="故障描述"
align="center"
prop="workFaultDesc"
width="150"
/>
<el-table-column
label="原因分析"
align="center"
prop="workReason"
width="150"
/>
<el-table-column
label="维修措施"
align="center"
prop="repairMeasures"
width="150"
/>
<el-table-column
label="维修开始时间"
align="center"
prop="workStartTime"
width="150"
/>
<el-table-column
label="维修结束时间"
align="center"
prop="workEndTime"
width="150"
/>
<el-table-column
label="维修状态"
align="center"
prop="workStatus"
width="100"
>
<template slot-scope="scope">
<dict-tag
:options="dict.type.device_repair_status"
:value="scope.row.workStatus"
/>
</template>
</el-table-column>
</el-table>
<pagination
v-show="total > 0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
import { getWXRecordsList } from "@/api/wms/equipment";
import { Message } from "element-ui";
export default {
name: "MdItemSingle",
dicts: ["device_repair_status"],
data() {
return {
showFlag: false,
//
selectedItemId: undefined,
selectedRows: undefined,
//
single: true,
//
multiple: true,
//
showSearch: true,
//
total: 0,
//
queryParams: {
pageNum: 1,
pageSize: 10,
equipmentCode: this.equipmentCode,
},
};
},
props: {
equipmentCode: undefined,
optType: undefined,
},
created() {
this.getList();
},
methods: {
//
cancel() {
this.showFlag = false;
this.reset();
},
//
reset() {
this.form = {
itemId: null,
itemCode: this.processId,
itemType: null,
};
this.resetForm("form");
},
//
indexMethod(index) {
return index + 1;
},
/** 查询设备编码列表*/
getList() {
getWXRecordsList(this.queryParams).then((response) => {
this.itemList = response.rows;
this.total = response.total;
});
},
},
};
</script>

@ -58,7 +58,7 @@
<el-table-column label="单位" align="center" prop="unit" v-if="false" />
<el-table-column label="计划数量" align="center" prop="planNumber" />
<el-table-column label="出库数量" align="center" prop="outNumber" />
<el-table-column label="托盘号" align="center" prop="userDefined2" />
<!-- <el-table-column label="托盘号" align="center" prop="userDefined2" /> -->
<el-table-column label="仓库编号" align="center" prop="locCode" />
<el-table-column label="库位名称" align="center" prop="locDesc" v-if="false" />
<el-table-column label="产线名称" align="center" prop="productionLineDesc" v-if="false" />
@ -357,36 +357,36 @@ export default {
Optionlistck: [],
Packagingline: [
{
stationNo: 'LJ1',
stationname: '榄菊1',
stationNo: 'XL01',
stationname: '包装线01',
},
{
stationNo: 'LJ2',
stationname: '榄菊2',
stationNo: 'XL02',
stationname: '包装线02',
},
{
stationNo: 'LJ3',
stationname: '榄菊3',
stationNo: 'XL03',
stationname: '包装线03',
},
{
stationNo: 'LJ4',
stationname: '榄菊4',
stationNo: 'XL04',
stationname: '包装线04',
},
{
stationNo: 'LJ5',
stationname: '榄菊5',
stationNo: 'XL05',
stationname: '包装线05',
},
{
stationNo: 'LJ6',
stationname: '榄菊6',
stationNo: 'XL06',
stationname: '包装线06',
},
{
stationNo: 'LJ7',
stationname: '榄菊7',
stationNo: 'XL07',
stationname: '包装线07',
},
{
stationNo: 'LJ8',
stationname: '榄菊8',
stationNo: 'XL08',
stationname: '包装线08',
},
],

Loading…
Cancel
Save