denglijiekou

This commit is contained in:
shilixia 2022-01-25 09:56:14 +08:00
parent c35051df0c
commit 938ebf1e28
8 changed files with 53 additions and 77 deletions

View File

@ -263,10 +263,10 @@ export const asyncRoutes = [
meta: { title: '生产设备', icon: 'example', perms: ['em_equipment'] } meta: { title: '生产设备', icon: 'example', perms: ['em_equipment'] }
}, },
{ {
path: 'detection ', path: 'monitoring ',
name: 'detection ', name: 'monitoring ',
component: () => import('@/views/em/detection'), component: () => import('@/views/em/monitoring'),
meta: { title: '监视和测量设备', icon: 'example', perms: ['em_detection'] } meta: { title: '监视和测量设备', icon: 'example', perms: ['em_monitoring'] }
}, },
{ {
path: 'record', path: 'record',

View File

@ -820,9 +820,7 @@
this.getStatisticsData(); this.getStatisticsData();
this.getNoticeData(); this.getNoticeData();
}, },
updated() {
this.drawChart()
}
} }
</script> </script>

View File

@ -7,7 +7,7 @@
> >
<el-input <el-input
v-model="listQuery.search" v-model="listQuery.search"
placeholder="设备名称/设备编号/备注" placeholder="检测设备名称/检测设备编号/备注"
style="width: 300px" style="width: 300px"
class="filter-item" class="filter-item"
@keyup.enter.native="handleFilter" @keyup.enter.native="handleFilter"
@ -40,7 +40,7 @@
v-el-height-adaptive-table="{ bottomOffset: 42 }" v-el-height-adaptive-table="{ bottomOffset: 42 }"
> >
<el-table-column type="index" width="50" /> <el-table-column type="index" width="50" />
<el-table-column label="设备编号"> <el-table-column label="设备编号" width="100">
<template slot-scope="scope">{{ scope.row.number }}</template> <template slot-scope="scope">{{ scope.row.number }}</template>
</el-table-column> </el-table-column>
@ -70,7 +70,7 @@
<el-table-column label="设备名称"> <el-table-column label="设备名称">
<template slot-scope="scope">{{ scope.row.name }}</template> <template slot-scope="scope">{{ scope.row.name }}</template>
</el-table-column> </el-table-column>
<el-table-column label="型号规格"> <el-table-column label="型号规格" width="100">
<template slot-scope="scope">{{ scope.row.model }}</template> <template slot-scope="scope">{{ scope.row.model }}</template>
</el-table-column> </el-table-column>
@ -89,7 +89,7 @@
scope.row.keeper_.username scope.row.keeper_.username
}}</template> }}</template>
</el-table-column> </el-table-column>
<el-table-column label="存放位置"> <el-table-column label="存放位置" width="100">
<template slot-scope="scope">{{ scope.row.place }}</template> <template slot-scope="scope">{{ scope.row.place }}</template>
</el-table-column> </el-table-column>
<el-table-column label="绑定工序"> <el-table-column label="绑定工序">
@ -199,9 +199,9 @@
> >
<el-option <el-option
v-for="item in mgmoptions" v-for="item in mgmoptions"
:key="item.value" :key="item.id"
:label="item.label" :label="item.label"
:value="item.value" :value="item.id"
> >
</el-option> </el-option>
</el-select> </el-select>
@ -226,9 +226,9 @@
> >
<el-option <el-option
v-for="item in keeperOptions" v-for="item in keeperOptions"
:key="item.value" :key="item.id"
:label="item.label" :label="item.name"
:value="item.value" :value="item.id"
> >
</el-option> </el-option>
</el-select> </el-select>
@ -307,8 +307,7 @@
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
<style>
</style>
<script> <script>
import { import {
getpEquipmentList, getpEquipmentList,
@ -317,10 +316,8 @@ import {
deleteEquipment, deleteEquipment,
} from "@/api/equipment"; } from "@/api/equipment";
import { getUserList } from "@/api/user"; import { getUserList } from "@/api/user";
import { getOrgList } from "@/api/org";
import checkPermission from "@/utils/permission"; import checkPermission from "@/utils/permission";
import { genTree } from "@/utils";
import Pagination from "@/components/Pagination"; // secondary package based on el-pagination import Pagination from "@/components/Pagination"; // secondary package based on el-pagination
const defaultequipment = { const defaultequipment = {
name: "", name: "",
@ -411,7 +408,7 @@ export default {
type: [{ required: true, message: "请输入", trigger: "blur" }], type: [{ required: true, message: "请输入", trigger: "blur" }],
model: [{ required: true, message: "请输入", trigger: "blur" }], model: [{ required: true, message: "请输入", trigger: "blur" }],
state: [{ required: true, message: "请选择", trigger: "blur" }], state: [{ required: true, message: "请选择", trigger: "blur" }],
belong_dept: [{ required: true, message: "请选择", trigger: "blur" }],
}, },
datatime: null, datatime: null,
}; };
@ -422,7 +419,7 @@ export default {
this.getList(); this.getList();
this.getUserList(); this.getUserList();
this.getOrgList();
}, },
methods: { methods: {
checkPermission, checkPermission,
@ -473,15 +470,10 @@ export default {
//组员列表 //组员列表
getUserList() { getUserList() {
getUserList({ page: 0 }).then((res) => { getUserList({ page: 0 }).then((res) => {
this.keeperOptions = genTree(res.data); this.keeperOptions = res.data;
});
},
//部门列表
getOrgList() {
getOrgList({ page: 0 }).then((res) => {
this.depOptions = genTree(res.data);
}); });
}, },
handleFilter() { handleFilter() {
this.listQuery.page = 1; this.listQuery.page = 1;

View File

@ -8,67 +8,66 @@
border border
fit fit
stripe stripe
highlight-current-row
height="620" height="620"
v-el-height-adaptive-table="{ bottomOffset: 40 }" v-el-height-adaptive-table="{ bottomOffset: 40 }"
> >
<el-table-column type="index" width="50" /> <el-table-column type="index" width="50" />
<el-table-column label="任务编号"> <el-table-column label="任务编号" align="center">
<template slot-scope="scope">{{ scope.row.number }}</template> <template slot-scope="scope">{{ scope.row.number }}</template>
</el-table-column> </el-table-column>
<el-table-column label="产品名称"> <el-table-column label="产品名称" align="center">
<template slot-scope="scope">{{ <template slot-scope="scope">{{
scope.row.product_.name scope.row.product_.name
}}</template> }}</template>
</el-table-column> </el-table-column>
<el-table-column label="规格型号"> <el-table-column label="规格型号" align="center">
<template slot-scope="scope">{{ <template slot-scope="scope">{{
scope.row.product_.specification scope.row.product_.specification
}}</template> }}</template>
</el-table-column> </el-table-column>
<el-table-column label="合格率"> <el-table-column label="合格率" align="center">
<el-table-column label="冷加工"> <el-table-column label="冷加工" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['01']" <template slot-scope="scope" v-if="scope.row.process_json['01']"
>{{ scope.row.process_json["01"].rate }}%</template >{{ scope.row.process_json["01"].rate }}%</template
> >
</el-table-column> </el-table-column>
<el-table-column label="热弯"> <el-table-column label="热弯" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['02']" <template slot-scope="scope" v-if="scope.row.process_json['02']"
>{{ scope.row.process_json["02"].rate }}%</template >{{ scope.row.process_json["02"].rate }}%</template
> >
</el-table-column> </el-table-column>
<el-table-column label="化学钢化"> <el-table-column label="化学钢化" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['03']" <template slot-scope="scope" v-if="scope.row.process_json['03']"
>{{ scope.row.process_json["03"].rate }}%</template >{{ scope.row.process_json["03"].rate }}%</template
> >
</el-table-column> </el-table-column>
<el-table-column label="镀膜"> <el-table-column label="镀膜" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['05']" <template slot-scope="scope" v-if="scope.row.process_json['05']"
>{{ scope.row.process_json["05"].rate }}%</template >{{ scope.row.process_json["05"].rate }}%</template
> >
</el-table-column> </el-table-column>
<el-table-column label="夹层"> <el-table-column label="夹层" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['06']" <template slot-scope="scope" v-if="scope.row.process_json['06']"
>{{ scope.row.process_json["06"].rate }}%</template >{{ scope.row.process_json["06"].rate }}%</template
> >
</el-table-column> </el-table-column>
<el-table-column label="包边"> <el-table-column label="包边" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['07']" <template slot-scope="scope" v-if="scope.row.process_json['07']"
>{{ scope.row.process_json["07"].rate }}%</template >{{ scope.row.process_json["07"].rate }}%</template
> >
</el-table-column> </el-table-column>
<el-table-column label="装框"> <el-table-column label="装框" align="center">
<template slot-scope="scope" v-if="scope.row.process_json['08']" <template slot-scope="scope" v-if="scope.row.process_json['08']"
>{{ scope.row.process_json["08"].rate }}%</template >{{ scope.row.process_json["08"].rate }}%</template
> >
</el-table-column> </el-table-column>
</el-table-column> </el-table-column>
<el-table-column label="创建时间"> <el-table-column label="创建时间" align="center">
<template slot-scope="scope">{{ <template slot-scope="scope">{{
scope.row.create_time scope.row.create_time
}}</template> }}</template>
</el-table-column> </el-table-column>
<el-table-column label="操作"> <el-table-column label="操作" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<el-link <el-link
v-if="checkPermission(['material_update'])" v-if="checkPermission(['material_update'])"

View File

@ -28,14 +28,7 @@
<el-table-column label="所在仓库"> <el-table-column label="所在仓库">
<template slot-scope="scope">{{ scope.row.warehouse_.name }}</template> <template slot-scope="scope">{{ scope.row.warehouse_.name }}</template>
</el-table-column> </el-table-column>
<el-table-column label="是否已军检">
<template slot-scope="scope">
<el-tag v-if="scope.row.is_mtested == false">未军检</el-tag>
<el-tag v-else>已军检</el-tag></template>
</el-table-column>
<el-table-column label="军检"> <el-table-column label="军检">
<template slot-scope="scope"> <template slot-scope="scope">

View File

@ -23,12 +23,7 @@
<el-table-column label="型号规格"> <el-table-column label="型号规格">
<template slot-scope="scope" v-if="scope.row.material_">{{ scope.row.material_.specification }}</template> <template slot-scope="scope" v-if="scope.row.material_">{{ scope.row.material_.specification }}</template>
</el-table-column> </el-table-column>
<el-table-column label="军检状态">
<template slot-scope="scope">
<el-tag v-if="scope.row.is_mtested==false">未军检</el-tag>
<el-tag v-if="scope.row.is_mtested==true">已军检</el-tag>
</template>
</el-table-column>
<el-table-column label="军检结论"> <el-table-column label="军检结论">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.is_mtestok==false">不合格</el-tag> <el-tag v-if="scope.row.is_mtestok==false">不合格</el-tag>

View File

@ -25,12 +25,7 @@
<el-table-column label="型号规格"> <el-table-column label="型号规格">
<template slot-scope="scope" v-if="scope.row.material_">{{ scope.row.material_.specification }}</template> <template slot-scope="scope" v-if="scope.row.material_">{{ scope.row.material_.specification }}</template>
</el-table-column> </el-table-column>
<el-table-column label="军检状态">
<template slot-scope="scope">
<el-tag v-if="scope.row.is_mtested==false">未军检</el-tag>
<el-tag v-if="scope.row.is_mtested==true">已军检</el-tag>
</template>
</el-table-column>
<el-table-column label="军检结论"> <el-table-column label="军检结论">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.is_mtestok==false">不合格</el-tag> <el-tag v-if="scope.row.is_mtestok==false">不合格</el-tag>

View File

@ -131,18 +131,13 @@
</el-table-column> </el-table-column>
<el-table-column label="设备状态"> <el-table-column label="设备状态">
<template slot-scope="scope"> <template slot-scope="scope">
<el-tag v-if="scope.row.state===0" type="success"> <el-tag v-if="scope.row.equip_.type===1&&scope.row.equip_.state===10" type="success">
{{ state_[scope.row.equip_.state] }} {{ state_[scope.row.equip_.state] }}
</el-tag> </el-tag>
<el-tag v-else-if="scope.row.state===1" type="warning"> <el-tag v-else-if="scope.row.equip_.type===2&&scope.row.equip_.state===10" type="warning">
{{ state_[scope.row.equip_.state] }} {{ state2_[scope.row.equip_.state] }}
</el-tag>
<el-tag v-else-if="scope.row.state===2" >
{{ state_[scope.row.equip_.state] }}
</el-tag>
<el-tag v-else type="danger">
{{ state_[scope.row.equip_.state] }}
</el-tag> </el-tag>
</template> </template>
</el-table-column> </el-table-column>
@ -572,8 +567,12 @@
</div> </div>
</template> </template>
<style scoped> <style scoped>
.word-wrap {
padding: 25px;
};
.box-card { .box-card {
height: 300px; height: 300px;
} }
</style> </style>
<script> <script>
@ -619,11 +618,16 @@ export default {
page: 1, page: 1,
page_size: 20, page_size: 20,
}, },
state_:{ state_:{
0:'完好', 10:'完好',
1:'限用', 20:'限用',
2:'在修', 30:'在修',
3:'禁用', 40:'禁用',
},
state2_: {
10: "合格",
40: "禁用",
}, },
scrap: [ scrap: [
{ lable: "使用", value: true }, { lable: "使用", value: true },