修改页面bug,添加左侧菜单栏默认展开功能

main
jinna 2 years ago
parent 78eb7de549
commit 4dd6a06545
  1. 11
      src/page/index/sidebar/index.vue
  2. 6
      src/views/capital/components/scrapQuery.vue
  3. 2
      src/views/inspection/insTask.vue
  4. 4
      src/views/inspection/leavepoints.vue
  5. 2
      src/views/inspection/setting/points.vue
  6. 10
      src/views/oiling/statistics.vue
  7. 2
      src/views/oiling/task.vue
  8. 27
      src/views/repair/repairAppyDetail.vue
  9. 22
      src/views/system/user.vue

@ -7,6 +7,7 @@
</div> </div>
<el-menu unique-opened <el-menu unique-opened
:default-active="nowTagValue" :default-active="nowTagValue"
:default-openeds="menuArr"
mode="vertical" mode="vertical"
:show-timeout="200" :show-timeout="200"
:collapse="keyCollapse"> :collapse="keyCollapse">
@ -30,9 +31,17 @@
components: {sidebarItem, logo}, components: {sidebarItem, logo},
inject: ["index"], inject: ["index"],
data() { data() {
return {}; return {
menuArr:[]
};
}, },
created() { created() {
setTimeout(() =>{
this.menu.map((item,index) =>{
this.menuArr.push(item.path)
})
},300)
this.index.openMenu(); this.index.openMenu();
}, },
computed: { computed: {

@ -53,7 +53,7 @@ export default {
return { return {
// //
searchForm: { searchForm: {
goodsName: "", reportGoodsName: "",
}, },
searchText: { searchText: {
flag: 1, flag: 1,
@ -101,10 +101,10 @@ export default {
// //
searchHandle (item, index) { searchHandle (item, index) {
this.page.currentPage = 1 this.page.currentPage = 1
this.searchForm.goodsName = item.name this.searchForm.reportGoodsName = item.name
if (index === 1) { if (index === 1) {
this.searchForm = { this.searchForm = {
goodsName: "", reportGoodsName: "",
} }
this.onLoad(this.page) this.onLoad(this.page)
} else { } else {

@ -1044,6 +1044,7 @@ export default {
console.log('res =====>',res) console.log('res =====>',res)
this.addForm = res.data.data this.addForm = res.data.data
this.addForm.orderList = res.data.data.taskPointList this.addForm.orderList = res.data.data.taskPointList
this.addForm.planInspectionMethod = Number(this.addForm.planInspectionMethod)
this.showAddDialog = true this.showAddDialog = true
}) })
}, },
@ -1068,6 +1069,7 @@ export default {
getInsTaskDetail(this.currentId).then(res =>{ getInsTaskDetail(this.currentId).then(res =>{
this.addForm = res.data.data this.addForm = res.data.data
this.addForm.orderList = res.data.data.taskPointList this.addForm.orderList = res.data.data.taskPointList
this.addForm.planInspectionMethod = Number(this.addForm.planInspectionMethod)
this.showExecuteDialog = false this.showExecuteDialog = false
this.onLoad() this.onLoad()
this.$message.success('执行成功') this.$message.success('执行成功')

@ -114,7 +114,7 @@
:before-close="handleClose" :before-close="handleClose"
:cell-style="tableCellStyle" :cell-style="tableCellStyle"
:visible.sync="showPlanDialog" :visible.sync="showPlanDialog"
title="查看异常巡检任务单" title="查看漏检巡检点"
width="70%" width="70%"
:append-to-body="true" :append-to-body="true"
:close-on-click-modal="false" :close-on-click-modal="false"
@ -569,7 +569,7 @@ export default {
// //
onLoad() { onLoad() {
this.loading = true this.loading = true
getLeavePointList({current:this.listPage.current,size:this.listPage.size,...this.searchForm}).then(res =>{ getLeavePointList({current:this.listPage.current,size:this.listPage.size,pointStatus:3,...this.searchForm}).then(res =>{
this.data = res.data.data.records this.data = res.data.data.records
this.listPage.total = res.data.data.total this.listPage.total = res.data.data.total
this.loading = false this.loading = false

@ -1306,6 +1306,8 @@ export default {
this.addForm = { this.addForm = {
orderList:[] orderList:[]
} }
this.fileList = []
this.imgList = []
this.title = '新建巡检点位' this.title = '新建巡检点位'
this.$refs.addForm.clearValidate() this.$refs.addForm.clearValidate()
}) })

@ -84,10 +84,16 @@ export default {
overHidden: true, overHidden: true,
align: "left", align: "left",
}, },
// {
// label: "ID",
// align: "left",
// prop: "assetId",
// overHidden: true,
// },
{ {
label: "设备ID", label: "设备名称",
align: "left", align: "left",
prop: "assetId", prop: "assetName",
overHidden: true, overHidden: true,
}, },
{ {

@ -1847,7 +1847,7 @@ export default {
}, },
// //
handleComplete(row,index){ handleComplete(row,index){
this.$confirm("确定删除此保养任务吗?", "提示", { this.$confirm("确定完成此保养任务吗?", "提示", {
confirmButtonText: "确定", confirmButtonText: "确定",
cancelButtonText: "取消", cancelButtonText: "取消",
type: "warning", type: "warning",

@ -5,6 +5,7 @@
<el-form <el-form
ref="form" ref="form"
:model="form" :model="form"
:rules="formRules"
label-width="140px" label-width="140px"
label-position="top" label-position="top"
> >
@ -300,7 +301,7 @@
</div> </div>
<el-row v-if="this.status >= 1 || (viewType == 'view' && status == -4)"> <el-row v-if="this.status >= 1 || (viewType == 'view' && status == -4)">
<el-col :span="6"> <el-col :span="6">
<el-form-item label="维修班组" > <el-form-item label="维修班组" prop="repairTeam">
<el-select <el-select
v-model="form.repairTeam" v-model="form.repairTeam"
:rows="3" :rows="3"
@ -312,9 +313,9 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="维修人员" > <el-form-item label="维修人员" prop="repairPerson">
<el-select <el-select
v-model="repairPerson" v-model="form.repairPerson"
:rows="3" :rows="3"
:disabled="status > 1 || viewType == 'view'" :disabled="status > 1 || viewType == 'view'"
> >
@ -647,6 +648,14 @@ export default {
repairPerson:'', repairPerson:'',
repairContent:'' repairContent:''
}, },
formRules:{
repairTeam:[
{required:true,message:'请选择维修班组',trigger:'change'}
],
repairPerson:[
{required:true,message:'请选择维修人员',trigger:'change'}
]
},
// //
status: 0, status: 0,
//id //id
@ -690,6 +699,7 @@ export default {
this.groupId = val this.groupId = val
getMainPer({deptId:val}).then(res =>{ getMainPer({deptId:val}).then(res =>{
this.perData = res.data.data this.perData = res.data.data
this.form.repairPerson = ''
}) })
}, },
// //
@ -748,7 +758,7 @@ export default {
} }
getMainPer({deptId:this.form.repairTeam}).then(res =>{ getMainPer({deptId:this.form.repairTeam}).then(res =>{
this.perData = res.data.data this.perData = res.data.data
this.repairPerson = row.repairPerson this.form.repairPerson = row.repairPerson
}) })
// //
@ -778,6 +788,8 @@ export default {
* 按钮报修单提交 * 按钮报修单提交
*/ */
async submit() { async submit() {
this.$refs.form.validate((valid) =>{
if(valid){
if (this.status > 2) { if (this.status > 2) {
if (this.form.status2 === undefined || this.form.status2 === "") { if (this.form.status2 === undefined || this.form.status2 === "") {
this.$message({ type: "warning", message: "请选择维修结果" }); this.$message({ type: "warning", message: "请选择维修结果" });
@ -796,7 +808,7 @@ export default {
instrumentId: this.instrumentId, instrumentId: this.instrumentId,
...this.form, ...this.form,
status, status,
repairPerson:this.repairPerson // repairPerson:this.repairPerson
}; };
if(this.imgList.length !== 0){ if(this.imgList.length !== 0){
params.repairAttach = this.imgList[0].url params.repairAttach = this.imgList[0].url
@ -805,7 +817,7 @@ export default {
this.$delete(params, "applyUser"); this.$delete(params, "applyUser");
this.$delete(params, "applyUserName"); this.$delete(params, "applyUserName");
// console.log('params ==============>',params) // console.log('params ==============>',params)
await reportModify(params); reportModify(params);
// if (this.status === 0) { // if (this.status === 0) {
// await reportModify(1, this.id) // await reportModify(1, this.id)
// } else if (this.status === 1) { // } else if (this.status === 1) {
@ -822,6 +834,9 @@ export default {
); );
this.$store.commit("DEL_TAG", tag); this.$store.commit("DEL_TAG", tag);
this.$router.push({ path: "/repair/proposer" }); this.$router.push({ path: "/repair/proposer" });
}
})
}, },
}, },
}; };

@ -659,7 +659,8 @@ export default {
label: "所属部门", label: "所属部门",
prop: "deptId", prop: "deptId",
type: "tree", type: "tree",
multiple: true, popperClass:'popperClass',
// multiple: true,
dicData: [], dicData: [],
props: { props: {
label: "title", label: "title",
@ -920,7 +921,7 @@ export default {
}, },
rowSave(row, done, loading) { rowSave(row, done, loading) {
console.log(row, "rowww"); console.log(row, "rowww");
row.deptId = row.deptId.join(","); // row.deptId = row.deptId.join(",");
row.roleId = row.roleId.join(","); row.roleId = row.roleId.join(",");
row.postId = row.postId.join(","); row.postId = row.postId.join(",");
add(row).then( add(row).then(
@ -940,7 +941,7 @@ export default {
); );
}, },
rowUpdate(row, index, done, loading) { rowUpdate(row, index, done, loading) {
row.deptId = row.deptId.join(","); // row.deptId = row.deptId.join(",");
row.roleId = row.roleId.join(","); row.roleId = row.roleId.join(",");
row.postId = row.postId.join(","); row.postId = row.postId.join(",");
this.$delete(row, "electronicSignature"); this.$delete(row, "electronicSignature");
@ -1148,9 +1149,9 @@ export default {
if (["edit", "view"].includes(type)) { if (["edit", "view"].includes(type)) {
getUser(this.form.id).then((res) => { getUser(this.form.id).then((res) => {
this.form = res.data.data; this.form = res.data.data;
if (this.form.hasOwnProperty("deptId")) { // if (this.form.hasOwnProperty("deptId")) {
this.form.deptId = this.form.deptId.split(","); // this.form.deptId = this.form.deptId.split(",");
} // }
if (this.form.hasOwnProperty("roleId")) { if (this.form.hasOwnProperty("roleId")) {
this.form.roleId = this.form.roleId.split(","); this.form.roleId = this.form.roleId.split(",");
} }
@ -1310,4 +1311,13 @@ export default {
line-height: 20px; line-height: 20px;
width: 90px; width: 90px;
} }
</style>
<style lang="scss">
.popperClass {
.el-select-dropdown__item{
height: 80px !important;
overflow-y: auto;
}
}
</style> </style>

Loading…
Cancel
Save