Sfoglia il codice sorgente

Merge branch 'master' of http://git.qmth.com.cn/ExamCloud-3/examcloud-web-admin

chenken 6 anni fa
parent
commit
c23bb9c7db

+ 31 - 75
src/modules/basic/view/campus.vue

@@ -431,7 +431,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         this.tableData = response.data.list;
         this.tableData = response.data.list;
         this.total = response.data.total;
         this.total = response.data.total;
         this.loading = false;
         this.loading = false;
@@ -458,24 +458,13 @@ export default {
           type: "warning"
           type: "warning"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/org/enable/" + this.orgIds;
           var url = CORE_API + "/org/enable/" + this.orgIds;
-          this.$http
-            .put(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "启用成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "启用成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -492,24 +481,13 @@ export default {
           type: "warning"
           type: "warning"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/org/disable/" + this.orgIds;
           var url = CORE_API + "/org/disable/" + this.orgIds;
-          this.$http
-            .put(url, {})
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "禁用成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url, {}).then(() => {
+            this.$notify({
+              type: "success",
+              message: "禁用成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -530,49 +508,27 @@ export default {
         if (valid) {
         if (valid) {
           if (null != this.campusForm.id) {
           if (null != this.campusForm.id) {
             url = CORE_API + "/org/updateSubOrg";
             url = CORE_API + "/org/updateSubOrg";
-            this.$http.put(url, this.campusForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "修改成功!"
-                });
-                this.searchForm();
-                this.resetForm();
-                this.campusDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.put(url, this.campusForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "修改成功!"
+              });
+              this.searchForm();
+              this.resetForm();
+              this.campusDialog = false;
+            });
           } else {
           } else {
             //新增
             //新增
             var url = CORE_API + "/org/addSubOrg";
             var url = CORE_API + "/org/addSubOrg";
-            this.$http.post(url, this.campusForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "新增成功!"
-                });
-                this.searchForm();
-                this.resetForm();
-                this.campusDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.post(url, this.campusForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "新增成功!"
+              });
+              this.searchForm();
+              this.resetForm();
+              this.campusDialog = false;
+            });
           }
           }
         } else {
         } else {
           console.log("error submit!");
           console.log("error submit!");

+ 72 - 182
src/modules/basic/view/course.vue

@@ -662,49 +662,27 @@ export default {
         specialtyId: specialtyId
         specialtyId: specialtyId
       });
       });
       var url = CORE_API + "/courseSpeciatlyRelation/delete?" + param;
       var url = CORE_API + "/courseSpeciatlyRelation/delete?" + param;
-      this.$http
-        .delete(url)
-        .then(() => {
-          this.$notify({
-            type: "success",
-            message: "取消关联成功!"
-          });
-          this.searchSpecialtyPage();
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
+      this.$httpWithMsg.delete(url).then(() => {
+        this.$notify({
+          type: "success",
+          message: "取消关联成功!"
         });
         });
+        this.searchSpecialtyPage();
+      });
     },
     },
     submitAddRelationForm() {
     submitAddRelationForm() {
       this.$refs.addRelationForm.validate(valid => {
       this.$refs.addRelationForm.validate(valid => {
         if (valid) {
         if (valid) {
           var param = new URLSearchParams(this.addRelationForm);
           var param = new URLSearchParams(this.addRelationForm);
           var url = CORE_API + "/courseSpeciatlyRelation/add?" + param;
           var url = CORE_API + "/courseSpeciatlyRelation/add?" + param;
-          this.$http.post(url, this.speciallyForm).then(
-            () => {
-              this.$notify({
-                type: "success",
-                message: "添加成功!"
-              });
-              this.searchSpecialtyPage();
-              this.addRelationDialog = false;
-            },
-            response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
-            }
-          );
+          this.$httpWithMsg.post(url, this.speciallyForm).then(() => {
+            this.$notify({
+              type: "success",
+              message: "添加成功!"
+            });
+            this.searchSpecialtyPage();
+            this.addRelationDialog = false;
+          });
         } else {
         } else {
           console.log("error submit!");
           console.log("error submit!");
           return false;
           return false;
@@ -713,7 +691,7 @@ export default {
     },
     },
     getSpecialtyList4AddRelation(query) {
     getSpecialtyList4AddRelation(query) {
       this.specialtyLoading4AddRelation = true;
       this.specialtyLoading4AddRelation = true;
-      this.$http
+      this.$httpWithMsg
         .get(CORE_API + "/specialty/query?name=" + query)
         .get(CORE_API + "/specialty/query?name=" + query)
         .then(response => {
         .then(response => {
           this.specialtyList4AddRelation = response.data;
           this.specialtyList4AddRelation = response.data;
@@ -742,7 +720,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         this.specialtyTableData = response.data.content;
         this.specialtyTableData = response.data.content;
         this.specialtyTotal = response.data.totalElements;
         this.specialtyTotal = response.data.totalElements;
       });
       });
@@ -768,7 +746,7 @@ export default {
     },
     },
     getSpecialtyList4Search(query) {
     getSpecialtyList4Search(query) {
       this.specialtyLoading4Search = true;
       this.specialtyLoading4Search = true;
-      this.$http
+      this.$httpWithMsg
         .get(CORE_API + "/specialty/query?name=" + query)
         .get(CORE_API + "/specialty/query?name=" + query)
         .then(response => {
         .then(response => {
           this.specialtyList4Search = response.data;
           this.specialtyList4Search = response.data;
@@ -789,7 +767,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         this.tableData = response.data.content;
         this.tableData = response.data.content;
         this.total = response.data.totalElements;
         this.total = response.data.totalElements;
       });
       });
@@ -862,26 +840,15 @@ export default {
         //修改
         //修改
         this.$refs.courseForm.validate(valid => {
         this.$refs.courseForm.validate(valid => {
           if (valid) {
           if (valid) {
-            this.$http.put(url, this.courseForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "修改成功!"
-                });
-                this.searchForm();
-                this.resetForm();
-                this.courseDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.put(url, this.courseForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "修改成功!"
+              });
+              this.searchForm();
+              this.resetForm();
+              this.courseDialog = false;
+            });
           } else {
           } else {
             console.log("error submit!");
             console.log("error submit!");
             return false;
             return false;
@@ -890,26 +857,15 @@ export default {
       } else {
       } else {
         this.$refs.courseForm.validate(valid => {
         this.$refs.courseForm.validate(valid => {
           if (valid) {
           if (valid) {
-            this.$http.post(url, this.courseForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "添加成功"
-                });
-                this.searchForm();
-                this.resetForm();
-                this.courseDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.post(url, this.courseForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "添加成功"
+              });
+              this.searchForm();
+              this.resetForm();
+              this.courseDialog = false;
+            });
           } else {
           } else {
             console.log("error submit!");
             console.log("error submit!");
             return false;
             return false;
@@ -939,24 +895,13 @@ export default {
         type: "warning"
         type: "warning"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/course/" + row.id;
         var url = CORE_API + "/course/" + row.id;
-        this.$http
-          .delete(url)
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "删除成功!"
-            });
-            this.searchForm();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.delete(url).then(() => {
+          this.$notify({
+            type: "success",
+            message: "删除成功!"
           });
           });
+          this.searchForm();
+        });
       });
       });
     },
     },
     //删除多条数据
     //删除多条数据
@@ -973,24 +918,13 @@ export default {
           type: "error"
           type: "error"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/course/" + this.courseIds;
           var url = CORE_API + "/course/" + this.courseIds;
-          this.$http
-            .delete(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "删除成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.delete(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "删除成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -1008,24 +942,13 @@ export default {
           type: "warning"
           type: "warning"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/course/enable/" + this.courseIds;
           var url = CORE_API + "/course/enable/" + this.courseIds;
-          this.$http
-            .put(url, {})
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "开启成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url, {}).then(() => {
+            this.$notify({
+              type: "success",
+              message: "开启成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -1036,24 +959,13 @@ export default {
         type: "warning"
         type: "warning"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/course/enable/" + row.id;
         var url = CORE_API + "/course/enable/" + row.id;
-        this.$http
-          .put(url, {})
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "开启成功!"
-            });
-            this.searchForm();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.put(url, {}).then(() => {
+          this.$notify({
+            type: "success",
+            message: "开启成功!"
           });
           });
+          this.searchForm();
+        });
       });
       });
     },
     },
     //禁用
     //禁用
@@ -1070,24 +982,13 @@ export default {
           type: "error"
           type: "error"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/course/disable/" + this.courseIds;
           var url = CORE_API + "/course/disable/" + this.courseIds;
-          this.$http
-            .put(url, {})
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "禁用成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url, {}).then(() => {
+            this.$notify({
+              type: "success",
+              message: "禁用成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -1099,24 +1000,13 @@ export default {
         type: "error"
         type: "error"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/course/disable/" + row.id;
         var url = CORE_API + "/course/disable/" + row.id;
-        this.$http
-          .put(url, {})
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "禁用成功!"
-            });
-            this.searchForm();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        return this.$httpWithMsg.put(url, {}).then(() => {
+          this.$notify({
+            type: "success",
+            message: "禁用成功!"
           });
           });
+          return this.searchForm();
+        });
       });
       });
     },
     },
     //导入
     //导入

+ 35 - 90
src/modules/basic/view/exam_site.vue

@@ -297,7 +297,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         this.tableData = response.data.content;
         this.tableData = response.data.content;
         this.total = response.data.totalElements;
         this.total = response.data.totalElements;
         this.loading = false;
         this.loading = false;
@@ -320,47 +320,25 @@ export default {
         if (valid) {
         if (valid) {
           var url = CORE_API + "/examSite";
           var url = CORE_API + "/examSite";
           if (this.examSiteForm.id) {
           if (this.examSiteForm.id) {
-            this.$http.put(url, this.examSiteForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "修改成功!"
-                });
-                this.searchForm();
-                this.resetForm();
-                this.examSiteDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.put(url, this.examSiteForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "修改成功!"
+              });
+              this.searchForm();
+              this.resetForm();
+              this.examSiteDialog = false;
+            });
           } else {
           } else {
-            this.$http.post(url, this.examSiteForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "新增成功!"
-                });
-                this.searchForm();
-                this.resetForm();
-                this.examSiteDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.post(url, this.examSiteForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "新增成功!"
+              });
+              this.searchForm();
+              this.resetForm();
+              this.examSiteDialog = false;
+            });
           }
           }
         } else {
         } else {
           console.log("error submit!");
           console.log("error submit!");
@@ -403,24 +381,13 @@ export default {
         type: "warning"
         type: "warning"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/examSite/" + row.id;
         var url = CORE_API + "/examSite/" + row.id;
-        this.$http
-          .delete(url)
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "删除成功!"
-            });
-            this.searchForm();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.delete(url).then(() => {
+          this.$notify({
+            type: "success",
+            message: "删除成功!"
           });
           });
+          this.searchForm();
+        });
       });
       });
     },
     },
     //删除多条数据
     //删除多条数据
@@ -437,44 +404,22 @@ export default {
           type: "error"
           type: "error"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/examSite/" + this.examSiteIds;
           var url = CORE_API + "/examSite/" + this.examSiteIds;
-          this.$http
-            .delete(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "删除成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.delete(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "删除成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
     init() {
     init() {
       var url = CORE_API + "/org/subOrg/" + this.orgId;
       var url = CORE_API + "/org/subOrg/" + this.orgId;
-      this.$http
-        .get(url)
-        .then(response => {
-          this.orgName = response.data.name;
-          this.searchForm();
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
-        });
+      this.$httpWithMsg.get(url).then(response => {
+        this.orgName = response.data.name;
+        this.searchForm();
+      });
     }
     }
   },
   },
   created() {
   created() {

+ 1 - 10
src/modules/basic/view/index.vue

@@ -121,7 +121,7 @@ export default {
   },
   },
   created() {
   created() {
     var url = CORE_API + "/rolePrivilege/getUserPrivileges";
     var url = CORE_API + "/rolePrivilege/getUserPrivileges";
-    this.$http
+    this.$httpWithMsg
       .post(
       .post(
         url,
         url,
         {
         {
@@ -132,15 +132,6 @@ export default {
       )
       )
       .then(response => {
       .then(response => {
         this.menuList = response.data;
         this.menuList = response.data;
-      })
-      .catch(response => {
-        if (response.status == 500) {
-          this.$notify({
-            showClose: true,
-            message: response.data.desc,
-            type: "error"
-          });
-        }
       });
       });
   }
   }
 };
 };

+ 1 - 1
src/modules/basic/view/privilege_group_list.vue

@@ -41,7 +41,7 @@ export default {
   methods: {
   methods: {
     async queryAppList() {
     async queryAppList() {
       var url = CORE_API + "/rolePrivilege/getPrivilegeGroupList";
       var url = CORE_API + "/rolePrivilege/getPrivilegeGroupList";
-      const response = await this.$http.get(url);
+      const response = await this.$httpWithMsg.get(url);
       this.privilegeGroupList = response.data;
       this.privilegeGroupList = response.data;
     },
     },
     editPrivilege(row) {
     editPrivilege(row) {

+ 6 - 39
src/modules/basic/view/privilege_tree.vue

@@ -388,7 +388,7 @@ export default {
                     return;
                     return;
                 }
                 }
                 var url = CORE_API + '/rolePrivilege/addPrivilege';
                 var url = CORE_API + '/rolePrivilege/addPrivilege';
-                this.$http.post(url, this.addingDialog.privilege).then((response) => {
+                this.$httpWithMsg.post(url, this.addingDialog.privilege).then((response) => {
                     this.$notify({
                     this.$notify({
                         message: '添加成功',
                         message: '添加成功',
                         type: 'success'
                         type: 'success'
@@ -399,15 +399,7 @@ export default {
                         label: this.addingDialog.privilege.name,
                         label: this.addingDialog.privilege.name,
                         children: []
                         children: []
                     }, this.data);
                     }, this.data);
-                }).catch((response) => {
-                    if (response.status == 500) {
-                        this.$notify({
-                            showClose: true,
-                            message: response.data.desc,
-                            type: 'error'
-                        });
-                    }
-                });
+                })
                 this.addingDialog.show = false;
                 this.addingDialog.show = false;
             });
             });
         },
         },
@@ -416,23 +408,14 @@ export default {
                 if (!valid) {
                 if (!valid) {
                     return;
                     return;
                 }
                 }
-                console.log(this.updateDialog.privilege);
                 var url = CORE_API + '/rolePrivilege/updatePrivilege';
                 var url = CORE_API + '/rolePrivilege/updatePrivilege';
-                this.$http.put(url, this.updateDialog.privilege).then(() => {
+                this.$httpWithMsg.put(url, this.updateDialog.privilege).then(() => {
                     this.$notify({
                     this.$notify({
                         message: '修改成功',
                         message: '修改成功',
                         type: 'success'
                         type: 'success'
                     });
                     });
                     this.data.label = this.updateDialog.privilege.name;
                     this.data.label = this.updateDialog.privilege.name;
-                }).catch((response) => {
-                    if (response.status == 500) {
-                        this.$notify({
-                            showClose: true,
-                            message: response.data.desc,
-                            type: 'error'
-                        });
-                    }
-                });
+                })
                 this.updateDialog.show = false;
                 this.updateDialog.show = false;
             });
             });
         },
         },
@@ -451,7 +434,7 @@ export default {
         },
         },
         getPrivilege(id, type) {
         getPrivilege(id, type) {
             var url = CORE_API + '/rolePrivilege/getPrivilege/' + id;
             var url = CORE_API + '/rolePrivilege/getPrivilege/' + id;
-            this.$http.get(url).then((response) => {
+            this.$httpWithMsg.get(url).then((response) => {
                 var resp = response.data;
                 var resp = response.data;
 
 
                 this.updateDialog.privilege.id = resp.id;
                 this.updateDialog.privilege.id = resp.id;
@@ -486,14 +469,6 @@ export default {
                 else if ("for-show" == type) {
                 else if ("for-show" == type) {
                     this.showDialog.show = true;
                     this.showDialog.show = true;
                 }
                 }
-            }).catch((response) => {
-                if (response.status == 500) {
-                    this.$notify({
-                        showClose: true,
-                        message: response.data.desc,
-                        type: 'error'
-                    });
-                }
             });
             });
         },
         },
 
 
@@ -504,20 +479,12 @@ export default {
                 type: 'warning'
                 type: 'warning'
             }).then(() => {
             }).then(() => {
                 var url = CORE_API + '/rolePrivilege/deletePrivilege/' + data.id;
                 var url = CORE_API + '/rolePrivilege/deletePrivilege/' + data.id;
-                this.$http.delete(url).then(() => {
+                return this.$httpWithMsg.delete(url).then(() => {
                     this.$notify({
                     this.$notify({
                         message: '删除成功',
                         message: '删除成功',
                         type: 'success'
                         type: 'success'
                     });
                     });
                     store.remove(data);
                     store.remove(data);
-                }).catch((response) => {
-                    if (response.status == 500) {
-                        this.$notify({
-                            showClose: true,
-                            message: response.data.desc,
-                            type: 'error'
-                        });
-                    }
                 });
                 });
             }).catch(() => {
             }).catch(() => {
                 this.$message({
                 this.$message({

+ 17 - 36
src/modules/basic/view/role_privilege_settings.vue

@@ -159,15 +159,16 @@ export default {
       var url2 =
       var url2 =
         CORE_API + "/rolePrivilege/getPrivilegeIdList/" + orgId + "/" + roleId;
         CORE_API + "/rolePrivilege/getPrivilegeIdList/" + orgId + "/" + roleId;
 
 
-      Promise.all([this.$http.get(url1), this.$http.get(url2)]).then(
-        ([resp1, resp2]) => {
-          console.log("initTree(). treeData:", resp1.data.children);
-          console.log("initTree(). checkedKeys:", resp2.data);
-          this.treeData = resp1.data.children;
-          this.checkedKeys = resp2.data;
-          this.completed = true;
-        }
-      );
+      Promise.all([
+        this.$httpWithMsg.get(url1),
+        this.$httpWithMsg.get(url2)
+      ]).then(([resp1, resp2]) => {
+        console.log("initTree(). treeData:", resp1.data.children);
+        console.log("initTree(). checkedKeys:", resp2.data);
+        this.treeData = resp1.data.children;
+        this.checkedKeys = resp2.data;
+        this.completed = true;
+      });
     },
     },
     /*change事件*/
     /*change事件*/
     change() {
     change() {
@@ -190,23 +191,12 @@ export default {
         CORE_API +
         CORE_API +
         "/rolePrivilege/getRoles?includeSuperAdmin=false&rootOrgId=" +
         "/rolePrivilege/getRoles?includeSuperAdmin=false&rootOrgId=" +
         this.form.orgId;
         this.form.orgId;
-      this.$http
-        .post(url)
-        .then(response => {
-          this.roleList = response.data;
-          if (0 < this.roleList.length) {
-            this.form.roleId = this.roleList[0].roleId;
-          }
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
-        });
+      this.$httpWithMsg.post(url).then(response => {
+        this.roleList = response.data;
+        if (0 < this.roleList.length) {
+          this.form.roleId = this.roleList[0].roleId;
+        }
+      });
 
 
       this.initTree(
       this.initTree(
         this.form.orgId,
         this.form.orgId,
@@ -250,7 +240,7 @@ export default {
     save() {
     save() {
       console.log("save(). checkedKeys:", this.checkedKeys);
       console.log("save(). checkedKeys:", this.checkedKeys);
       var url = CORE_API + "/rolePrivilege/updateRolePrivilegeRelations";
       var url = CORE_API + "/rolePrivilege/updateRolePrivilegeRelations";
-      this.$http
+      this.$httpWithMsg
         .post(url, {
         .post(url, {
           rootOrgId: this.form.orgId,
           rootOrgId: this.form.orgId,
           roleId: this.form.roleId,
           roleId: this.form.roleId,
@@ -263,15 +253,6 @@ export default {
             type: "success"
             type: "success"
           });
           });
           this.treeChanged = false;
           this.treeChanged = false;
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
         });
         });
     }
     }
   },
   },

+ 36 - 88
src/modules/basic/view/school.vue

@@ -443,7 +443,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         this.tableData = response.data.list;
         this.tableData = response.data.list;
         this.total = response.data.total;
         this.total = response.data.total;
         this.loading = false;
         this.loading = false;
@@ -463,24 +463,13 @@ export default {
           type: "warning"
           type: "warning"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/org/enable/" + this.orgIds;
           var url = CORE_API + "/org/enable/" + this.orgIds;
-          this.$http
-            .put(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "启用成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "启用成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -497,24 +486,13 @@ export default {
           type: "warning"
           type: "warning"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/org/disable/" + this.orgIds;
           var url = CORE_API + "/org/disable/" + this.orgIds;
-          this.$http
-            .put(url, {})
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "禁用成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$$httpWithMsg.put(url, {}).then(() => {
+            this.$notify({
+              type: "success",
+              message: "禁用成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -536,47 +514,25 @@ export default {
           if (null != this.schoolForm.id) {
           if (null != this.schoolForm.id) {
             //修改
             //修改
             url = CORE_API + "/org/updateRootOrg";
             url = CORE_API + "/org/updateRootOrg";
-            this.$http.put(url, this.schoolForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "修改成功!"
-                });
-                this.searchForm();
-                this.schoolDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.put(url, this.schoolForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "修改成功!"
+              });
+              this.searchForm();
+              this.schoolDialog = false;
+            });
           } else {
           } else {
             //新增
             //新增
             var url = CORE_API + "/org/addRootOrg";
             var url = CORE_API + "/org/addRootOrg";
-            this.$http.post(url, this.schoolForm).then(
-              () => {
-                this.$notify({
-                  type: "success",
-                  message: "新增成功!"
-                });
-                this.searchForm();
-                this.schoolDialog = false;
-              },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
-              }
-            );
+            this.$httpWithMsg.post(url, this.schoolForm).then(() => {
+              this.$notify({
+                type: "success",
+                message: "新增成功!"
+              });
+              this.searchForm();
+              this.schoolDialog = false;
+            });
           }
           }
         } else {
         } else {
           console.log("error submit!");
           console.log("error submit!");
@@ -609,21 +565,13 @@ export default {
       this.schoolForm.enable = row.enable ? "true" : "false";
       this.schoolForm.enable = row.enable ? "true" : "false";
 
 
       var url = CORE_API + "/org/allProperties/" + row.id;
       var url = CORE_API + "/org/allProperties/" + row.id;
-      this.$http.get(url).then(
-        response => {
-          this.schoolForm.properties = Object.assign(
-            this.schoolForm.properties,
-            response.data
-          );
-          this.schoolDialog = true;
-        },
-        response => {
-          this.$notify({
-            type: "error",
-            message: response.data.desc
-          });
-        }
-      );
+      this.$httpWithMsg.get(url).then(response => {
+        this.schoolForm.properties = Object.assign(
+          this.schoolForm.properties,
+          response.data
+        );
+        this.schoolDialog = true;
+      });
     },
     },
     //设置产品
     //设置产品
     saveOrgFunction() {},
     saveOrgFunction() {},

+ 35 - 102
src/modules/basic/view/specially.vue

@@ -502,31 +502,20 @@ export default {
         specialtyId: specialtyId
         specialtyId: specialtyId
       });
       });
       var url = CORE_API + "/courseSpeciatlyRelation/delete?" + param;
       var url = CORE_API + "/courseSpeciatlyRelation/delete?" + param;
-      this.$http
-        .delete(url)
-        .then(() => {
-          this.$notify({
-            type: "success",
-            message: "取消关联成功!"
-          });
-          this.searchCoursePage();
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
+      this.$httpWithMsg.delete(url).then(() => {
+        this.$notify({
+          type: "success",
+          message: "取消关联成功!"
         });
         });
+        return this.searchCoursePage();
+      });
     },
     },
     submitAddRelationForm() {
     submitAddRelationForm() {
       this.$refs.addRelationForm.validate(valid => {
       this.$refs.addRelationForm.validate(valid => {
         if (valid) {
         if (valid) {
           var param = new URLSearchParams(this.addRelationForm);
           var param = new URLSearchParams(this.addRelationForm);
           var url = CORE_API + "/courseSpeciatlyRelation/add?" + param;
           var url = CORE_API + "/courseSpeciatlyRelation/add?" + param;
-          this.$http.post(url, this.speciallyForm).then(
+          this.$httpWithMsg.post(url, this.speciallyForm).then(
             () => {
             () => {
               this.$notify({
               this.$notify({
                 type: "success",
                 type: "success",
@@ -535,16 +524,7 @@ export default {
               this.searchCoursePage();
               this.searchCoursePage();
               this.addRelationDialog = false;
               this.addRelationDialog = false;
             },
             },
-            response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
-              this.addRelationDialog = false;
-            }
+            () => (this.addRelationDialog = false)
           );
           );
         } else {
         } else {
           console.log("error submit!");
           console.log("error submit!");
@@ -568,7 +548,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         console.log(response);
         console.log(response);
         this.courseTableData = response.data.content;
         this.courseTableData = response.data.content;
         this.courseTotal = response.data.totalElements;
         this.courseTotal = response.data.totalElements;
@@ -576,7 +556,7 @@ export default {
     },
     },
     getCourses(query) {
     getCourses(query) {
       this.courseLoading = true;
       this.courseLoading = true;
-      this.$http
+      this.$httpWithMsg
         .get(CORE_API + "/course/query?name=" + query)
         .get(CORE_API + "/course/query?name=" + query)
         .then(response => {
         .then(response => {
           this.courseList4Search = response.data;
           this.courseList4Search = response.data;
@@ -585,7 +565,7 @@ export default {
     },
     },
     getCourses4AddRelation(query) {
     getCourses4AddRelation(query) {
       this.courseLoading4AddRelation = true;
       this.courseLoading4AddRelation = true;
-      this.$http
+      this.$httpWithMsg
         .get(CORE_API + "/course/query?name=" + query)
         .get(CORE_API + "/course/query?name=" + query)
         .then(response => {
         .then(response => {
           this.courseList4AddRelation = response.data;
           this.courseList4AddRelation = response.data;
@@ -607,22 +587,11 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http
-        .get(url)
-        .then(response => {
-          console.log("response :", response);
-          this.tableData = response.data.content;
-          this.total = response.data.totalElements;
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
-        });
+      this.$httpWithMsg.get(url).then(response => {
+        console.log("response :", response);
+        this.tableData = response.data.content;
+        this.total = response.data.totalElements;
+      });
     },
     },
     handleCurrentChange(val) {
     handleCurrentChange(val) {
       this.currentPage = val;
       this.currentPage = val;
@@ -647,7 +616,7 @@ export default {
         this.loading = true;
         this.loading = true;
         var vm = this;
         var vm = this;
         var url = CORE_API;
         var url = CORE_API;
-        vm.$http.delete(url).then(() => {
+        vm.$httpWithMsg.delete(url).then(() => {
           this.loading = false;
           this.loading = false;
           this.$notify({
           this.$notify({
             type: "success",
             type: "success",
@@ -664,7 +633,7 @@ export default {
           var url = CORE_API + "/specialty";
           var url = CORE_API + "/specialty";
           //修改
           //修改
           if (null != this.speciallyForm.id) {
           if (null != this.speciallyForm.id) {
-            this.$http.put(url, this.speciallyForm).then(
+            this.$httpWithMsg.put(url, this.speciallyForm).then(
               () => {
               () => {
                 this.$notify({
                 this.$notify({
                   type: "success",
                   type: "success",
@@ -673,14 +642,7 @@ export default {
                 this.searchForm();
                 this.searchForm();
                 this.speciallyDialog = false;
                 this.speciallyDialog = false;
               },
               },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
+              () => {
                 this.searchForm();
                 this.searchForm();
                 this.speciallyDialog = false;
                 this.speciallyDialog = false;
               }
               }
@@ -688,7 +650,7 @@ export default {
           }
           }
           //新增
           //新增
           else {
           else {
-            this.$http.post(url, this.speciallyForm).then(
+            this.$httpWithMsg.post(url, this.speciallyForm).then(
               () => {
               () => {
                 this.$notify({
                 this.$notify({
                   type: "success",
                   type: "success",
@@ -697,16 +659,9 @@ export default {
                 this.speciallyDialog = false;
                 this.speciallyDialog = false;
                 this.searchForm();
                 this.searchForm();
               },
               },
-              response => {
-                if (response.status == 500) {
-                  this.$notify({
-                    showClose: true,
-                    message: response.data.desc,
-                    type: "error"
-                  });
-                }
+              () => {
                 this.speciallyDialog = false;
                 this.speciallyDialog = false;
-                this.searchForm();
+                return this.searchForm();
               }
               }
             );
             );
           }
           }
@@ -746,24 +701,13 @@ export default {
         type: "error"
         type: "error"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/specialty/" + row.id;
         var url = CORE_API + "/specialty/" + row.id;
-        this.$http
-          .delete(url)
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "删除成功!"
-            });
-            this.searchForm();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.delete(url).then(() => {
+          this.$notify({
+            type: "success",
+            message: "删除成功!"
           });
           });
+          this.searchForm();
+        });
       });
       });
     },
     },
     //删除多条信息
     //删除多条信息
@@ -784,24 +728,13 @@ export default {
             ids.push(this.multipleSelection[i].id);
             ids.push(this.multipleSelection[i].id);
           }
           }
           var url = CORE_API + "/specialty/" + ids;
           var url = CORE_API + "/specialty/" + ids;
-          this.$http
-            .delete(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "删除成功!"
-              });
-              this.searchForm();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.delete(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "删除成功!"
             });
             });
+            this.searchForm();
+          });
         });
         });
       }
       }
     },
     },
@@ -826,7 +759,7 @@ export default {
     saveCourse() {
     saveCourse() {
       //debugger;
       //debugger;
       var url = CORE_API + "/CourseSpeciatly/addCourse/" + this.speciatlyId;
       var url = CORE_API + "/CourseSpeciatly/addCourse/" + this.speciatlyId;
-      this.$http.post(url, this.courseList).then(
+      this.$httpWithMsg.post(url, this.courseList).then(
         () => {
         () => {
           this.$notify({
           this.$notify({
             type: "success",
             type: "success",

+ 68 - 190
src/modules/basic/view/user.vue

@@ -630,20 +630,9 @@ export default {
         true +
         true +
         "&rootOrgId=" +
         "&rootOrgId=" +
         this.searchForm.rootOrgId;
         this.searchForm.rootOrgId;
-      this.$http
-        .post(url)
-        .then(response => {
-          this.roleList4Search = response.data;
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
-        });
+      this.$httpWithMsg.post(url).then(response => {
+        this.roleList4Search = response.data;
+      });
     },
     },
     rootOrgChanged4InsertOrUpdate() {
     rootOrgChanged4InsertOrUpdate() {
       this.orgList4InsertOrUpdate = [];
       this.orgList4InsertOrUpdate = [];
@@ -654,21 +643,10 @@ export default {
         true +
         true +
         "&rootOrgId=" +
         "&rootOrgId=" +
         this.userForm.rootOrgId;
         this.userForm.rootOrgId;
-      this.$http
-        .post(url)
-        .then(response => {
-          this.roleList4InsertOrUpdate = response.data;
-          this.rolesChanged();
-        })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
-        });
+      this.$httpWithMsg.post(url).then(response => {
+        this.roleList4InsertOrUpdate = response.data;
+        this.rolesChanged();
+      });
     },
     },
     getOrgList4InsertOrUpdate(query) {
     getOrgList4InsertOrUpdate(query) {
       this.orgLoading4InsertOrUpdate = true;
       this.orgLoading4InsertOrUpdate = true;
@@ -679,20 +657,13 @@ export default {
           name: query,
           name: query,
           rootOrgId: this.userForm.rootOrgId
           rootOrgId: this.userForm.rootOrgId
         });
         });
-      this.$http
+      this.$httpWithMsg
         .get(url)
         .get(url)
         .then(response => {
         .then(response => {
           this.orgList4InsertOrUpdate = response.data;
           this.orgList4InsertOrUpdate = response.data;
           this.orgLoading4InsertOrUpdate = false;
           this.orgLoading4InsertOrUpdate = false;
         })
         })
-        .catch(response => {
-          if (response.status == 500) {
-            this.$notify({
-              showClose: true,
-              message: response.data.desc,
-              type: "error"
-            });
-          }
+        .catch(() => {
           this.orgLoading4InsertOrUpdate = false;
           this.orgLoading4InsertOrUpdate = false;
         });
         });
     },
     },
@@ -727,7 +698,7 @@ export default {
         this.pageSize +
         this.pageSize +
         "?" +
         "?" +
         param;
         param;
-      this.$http.get(url).then(response => {
+      this.$httpWithMsg.get(url).then(response => {
         console.log(response);
         console.log(response);
         this.tableData = response.data.list;
         this.tableData = response.data.list;
         this.total = response.data.total;
         this.total = response.data.total;
@@ -804,22 +775,14 @@ export default {
       this.$refs.addingForm.validate(valid => {
       this.$refs.addingForm.validate(valid => {
         if (valid) {
         if (valid) {
           this.userForm.enable = this.enableStr == "true";
           this.userForm.enable = this.enableStr == "true";
-          this.$http.post(url, this.userForm).then(
-            () => {
-              this.$notify({
-                type: "success",
-                message: "添加成功"
-              });
-              this.search();
-              this.addingDialog = false;
-            },
-            resp => {
-              this.$notify({
-                type: "error",
-                message: resp.body.desc
-              });
-            }
-          );
+          this.$httpWithMsg.post(url, this.userForm).then(() => {
+            this.$notify({
+              type: "success",
+              message: "添加成功"
+            });
+            this.search();
+            this.addingDialog = false;
+          });
         } else {
         } else {
           return false;
           return false;
         }
         }
@@ -831,22 +794,14 @@ export default {
       this.$refs.updateForm.validate(valid => {
       this.$refs.updateForm.validate(valid => {
         if (valid) {
         if (valid) {
           this.userForm.enable = this.enableStr == "true";
           this.userForm.enable = this.enableStr == "true";
-          this.$http.put(url, this.userForm).then(
-            () => {
-              this.$notify({
-                type: "success",
-                message: "添加成功"
-              });
-              this.search();
-              this.updateDialog = false;
-            },
-            resp => {
-              this.$notify({
-                type: "error",
-                message: resp.body.desc
-              });
-            }
-          );
+          this.$httpWithMsg.put(url, this.userForm).then(() => {
+            this.$notify({
+              type: "success",
+              message: "添加成功"
+            });
+            this.search();
+            this.updateDialog = false;
+          });
         } else {
         } else {
           return false;
           return false;
         }
         }
@@ -861,24 +816,13 @@ export default {
       })
       })
         .then(() => {
         .then(() => {
           var url = CORE_API + "/user/resetPass/" + row.id;
           var url = CORE_API + "/user/resetPass/" + row.id;
-          this.$http
-            .put(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "重置成功!"
-              });
-              this.search();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "重置成功!"
             });
             });
+            return this.search();
+          });
         })
         })
         .catch(e => console.log(e));
         .catch(e => console.log(e));
     },
     },
@@ -890,24 +834,13 @@ export default {
         type: "warning"
         type: "warning"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/user/" + row.id;
         var url = CORE_API + "/user/" + row.id;
-        this.$http
-          .delete(url)
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "删除成功!"
-            });
-            this.search();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.delete(url).then(() => {
+          this.$notify({
+            type: "success",
+            message: "删除成功!"
           });
           });
+          return this.search();
+        });
       });
       });
     },
     },
     //删除多条数据
     //删除多条数据
@@ -924,24 +857,13 @@ export default {
           type: "error"
           type: "error"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/user/" + this.userIds;
           var url = CORE_API + "/user/" + this.userIds;
-          this.$http
-            .delete(url)
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "删除成功!"
-              });
-              this.search();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.delete(url).then(() => {
+            this.$notify({
+              type: "success",
+              message: "删除成功!"
             });
             });
+            this.search();
+          });
         });
         });
       }
       }
     },
     },
@@ -959,24 +881,13 @@ export default {
           type: "warning"
           type: "warning"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/user/enable/" + this.userIds;
           var url = CORE_API + "/user/enable/" + this.userIds;
-          this.$http
-            .put(url, {})
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "开启成功!"
-              });
-              this.search();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url, {}).then(() => {
+            this.$notify({
+              type: "success",
+              message: "开启成功!"
             });
             });
+            return this.search();
+          });
         });
         });
       }
       }
     },
     },
@@ -987,24 +898,13 @@ export default {
         type: "warning"
         type: "warning"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/user/enable/" + row.id;
         var url = CORE_API + "/user/enable/" + row.id;
-        this.$http
-          .put(url, {})
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "开启成功!"
-            });
-            this.search();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.put(url, {}).then(() => {
+          this.$notify({
+            type: "success",
+            message: "开启成功!"
           });
           });
+          this.search();
+        });
       });
       });
     },
     },
     //禁用
     //禁用
@@ -1021,24 +921,13 @@ export default {
           type: "error"
           type: "error"
         }).then(() => {
         }).then(() => {
           var url = CORE_API + "/user/disable/" + this.userIds;
           var url = CORE_API + "/user/disable/" + this.userIds;
-          this.$http
-            .put(url, {})
-            .then(() => {
-              this.$notify({
-                type: "success",
-                message: "禁用成功!"
-              });
-              this.search();
-            })
-            .catch(response => {
-              if (response.status == 500) {
-                this.$notify({
-                  showClose: true,
-                  message: response.data.desc,
-                  type: "error"
-                });
-              }
+          this.$httpWithMsg.put(url, {}).then(() => {
+            this.$notify({
+              type: "success",
+              message: "禁用成功!"
             });
             });
+            this.search();
+          });
         });
         });
       }
       }
     },
     },
@@ -1050,24 +939,13 @@ export default {
         type: "error"
         type: "error"
       }).then(() => {
       }).then(() => {
         var url = CORE_API + "/user/disable/" + row.id;
         var url = CORE_API + "/user/disable/" + row.id;
-        this.$http
-          .put(url, {})
-          .then(() => {
-            this.$notify({
-              type: "success",
-              message: "禁用成功!"
-            });
-            this.search();
-          })
-          .catch(response => {
-            if (response.status == 500) {
-              this.$notify({
-                showClose: true,
-                message: response.data.desc,
-                type: "error"
-              });
-            }
+        this.$httpWithMsg.put(url, {}).then(() => {
+          this.$notify({
+            type: "success",
+            message: "禁用成功!"
           });
           });
+          this.search();
+        });
       });
       });
     },
     },
 
 

+ 1 - 1
src/modules/portal/store/currentPaths.js

@@ -1,4 +1,4 @@
-export const UPDATE_CURRENT_PATHS = "UPDATE_CURRENT_PATHS"; //退出登录
+export const UPDATE_CURRENT_PATHS = "UPDATE_CURRENT_PATHS";
 
 
 export default {
 export default {
   state: [],
   state: [],

+ 12 - 0
src/modules/portal/store/menuList.js

@@ -0,0 +1,12 @@
+export const UPDATE_MENU_LIST = "UPDATE_MENU_LIST";
+
+export default {
+  state: [],
+  mutations: {
+    [UPDATE_MENU_LIST](state, menuList) {
+      console.log(state, menuList);
+      state.length = 0;
+      state.push(...menuList);
+    }
+  }
+};

+ 2 - 2
src/modules/portal/views/home/Home.vue

@@ -2,10 +2,10 @@
   <el-container>
   <el-container>
     <el-header style="padding: 0;">
     <el-header style="padding: 0;">
       <el-menu class="el-menu" mode="horizontal">
       <el-menu class="el-menu" mode="horizontal">
-        <el-menu-item index="1" style=" width: 200px;">
+        <el-menu-item index="1" style="width: 200px;">
           <router-link
           <router-link
             to="/home/overview"
             to="/home/overview"
-            style="font-size: 20px; line-height: 24px; width: 100%; text-decoration-line: none"
+            style="display: inline-block; font-size: 20px; line-height: 48px; width: 100%; text-decoration-line: none"
             title="回到主页"
             title="回到主页"
           >
           >
             云平台主页
             云平台主页

+ 3 - 1
src/modules/portal/views/home/HomeSide.vue

@@ -110,6 +110,7 @@ const routesToMenu = [
 
 
 import { mapMutations } from "vuex";
 import { mapMutations } from "vuex";
 import { UPDATE_CURRENT_PATHS } from "../../store/currentPaths";
 import { UPDATE_CURRENT_PATHS } from "../../store/currentPaths";
+import { UPDATE_MENU_LIST } from "../../store/menuList";
 
 
 export default {
 export default {
   name: "HomeSide",
   name: "HomeSide",
@@ -129,7 +130,7 @@ export default {
     }
     }
   },
   },
   methods: {
   methods: {
-    ...mapMutations([UPDATE_CURRENT_PATHS]),
+    ...mapMutations([UPDATE_CURRENT_PATHS, UPDATE_MENU_LIST]),
     toggoleSidebar() {
     toggoleSidebar() {
       this.isCollapse = !this.isCollapse;
       this.isCollapse = !this.isCollapse;
     },
     },
@@ -170,6 +171,7 @@ export default {
     const groupCode = this.group && this.group.groupCode;
     const groupCode = this.group && this.group.groupCode;
     if (groupCode) {
     if (groupCode) {
       this.menuList = await this.getUserPrivileges(groupCode);
       this.menuList = await this.getUserPrivileges(groupCode);
+      this.UPDATE_MENU_LIST(this.menuList);
       this.updatePath();
       this.updatePath();
     }
     }
   },
   },

+ 42 - 23
src/modules/portal/views/tips/Tips.vue

@@ -3,25 +3,15 @@
     <div class=""><img src="./tips.jpg" /></div>
     <div class=""><img src="./tips.jpg" /></div>
     <div class="text">
     <div class="text">
       <div v-for="(menu1, index) in instructions" :key="index" class="menu1">
       <div v-for="(menu1, index) in instructions" :key="index" class="menu1">
-        <h4>{{ menu1.menu1Name }}</h4>
+        <h4 v-if="menu1.menu2.filter(m => m.canAccess).length > 0">
+          {{ menu1.menu1Name }}
+        </h4>
         <div v-for="(menu2, index) in menu1.menu2" :key="index" class="menu1">
         <div v-for="(menu2, index) in menu1.menu2" :key="index" class="menu1">
-          <span class="link">{{ menu2.name }}</span> {{ menu2.detail }}
+          <span v-if="menu2.canAccess">
+            <span class="link">{{ menu2.name }}</span> {{ menu2.detail }}
+          </span>
         </div>
         </div>
       </div>
       </div>
-      <!-- <div class="menu1">
-        <h4>学习中心查询</h4>
-        <div>
-          <span class="link">机构管理——中心列表</span>
-          查询学校下属所有学习中心编码及名称,可按学习中心设置学习中心平台权限,即A学习中心只能查询A中心的相关考试数据。
-        </div>
-      </div>
-      <div>
-        <h4>课程查询</h4>
-        <div>
-          <span class="link">课程管理——课程列表</span>
-          查看所有课程名称及代码,如一门课程即有专科又有本科,课程对应在的教材、试卷不一样时,需要建立专科课程及本科课程。
-        </div>
-      </div> -->
     </div>
     </div>
   </section>
   </section>
 </template>
 </template>
@@ -34,7 +24,7 @@ const ALL_INSTRUCTIONS = {
       menu2: [
       menu2: [
         {
         {
           name: "机构管理——中心列表",
           name: "机构管理——中心列表",
-          // link: "/basic/campus",
+          link: "/basic/campus",
           detail:
           detail:
             "查询学校下属所有学习中心编码及名称,可按学习中心设置学习中心平台权限,即A学习中心只能查询A中心的相关考试数据。"
             "查询学校下属所有学习中心编码及名称,可按学习中心设置学习中心平台权限,即A学习中心只能查询A中心的相关考试数据。"
         }
         }
@@ -45,7 +35,7 @@ const ALL_INSTRUCTIONS = {
       menu2: [
       menu2: [
         {
         {
           name: "课程管理——课程列表",
           name: "课程管理——课程列表",
-          // link: "/basic/campus",
+          link: "/basic/course",
           detail:
           detail:
             "查看所有课程名称及代码,如一门课程即有专科又有本科,课程对应在的教材、试卷不一样时,需要建立专科课程及本科课程。"
             "查看所有课程名称及代码,如一门课程即有专科又有本科,课程对应在的教材、试卷不一样时,需要建立专科课程及本科课程。"
         }
         }
@@ -56,7 +46,7 @@ const ALL_INSTRUCTIONS = {
       menu2: [
       menu2: [
         {
         {
           name: "用户管理——普通用户管理",
           name: "用户管理——普通用户管理",
-          // link: "/basic/campus",
+          link: "/basic/user",
           detail:
           detail:
             "添加、查询、禁用管理平台用户,并可以针对不同用户设置不同的平台模块权限。"
             "添加、查询、禁用管理平台用户,并可以针对不同用户设置不同的平台模块权限。"
         }
         }
@@ -69,7 +59,7 @@ const ALL_INSTRUCTIONS = {
       menu2: [
       menu2: [
         {
         {
           name: "考试管理——考试信息",
           name: "考试管理——考试信息",
-          // link: "/basic/campus",
+          link: "/examwork/examInfo",
           detail: "安排一场在线考试,设置考试开启、结束时间。"
           detail: "安排一场在线考试,设置考试开启、结束时间。"
         }
         }
       ]
       ]
@@ -154,9 +144,19 @@ const ALL_INSTRUCTIONS = {
       menu1Name: "考试完成进度查询",
       menu1Name: "考试完成进度查询",
       menu2: [
       menu2: [
         {
         {
-          name: "考试进度——考试概览/考试进度详情",
+          name: "考试进度——考试概览",
           // link: "/oe/campus",
           // link: "/oe/campus",
-          detail: "可以查看按考试的人数、学习中心、课程数来查看考试完成的进度。"
+          detail: "可以查看按考试、学习中心、课程数来查看考试完成的进度。"
+        }
+      ]
+    },
+    {
+      menu1Name: "考试完成进度查询",
+      menu2: [
+        {
+          name: "考试进度——考试进度详情",
+          // link: "/oe/campus",
+          detail: "可以查看按考试的人数、学习中心、查看考生的完成情况。"
         }
         }
       ]
       ]
     }
     }
@@ -174,6 +174,9 @@ const ALL_INSTRUCTIONS = {
     }
     }
   ]
   ]
 };
 };
+
+import { mapState } from "vuex";
+
 export default {
 export default {
   name: "Tips",
   name: "Tips",
   data() {
   data() {
@@ -181,10 +184,26 @@ export default {
       instructions: []
       instructions: []
     };
     };
   },
   },
-  computed: {},
+  computed: { ...mapState({ menuList: state => state.menuList }) },
   methods: {},
   methods: {},
   created() {
   created() {
     this.instructions = ALL_INSTRUCTIONS[this.$route.path];
     this.instructions = ALL_INSTRUCTIONS[this.$route.path];
+  },
+  watch: {
+    menuList() {
+      const tipsLink = this.menuList.map(m => m.ext5);
+      this.instructions.map(menu => {
+        menu.menu2 = menu.menu2.map(m => {
+          if (tipsLink.includes(m.link)) {
+            m.canAccess = true;
+          } else {
+            m.canAccess = false;
+          }
+          return m;
+        });
+        return menu;
+      });
+    }
   }
   }
 };
 };
 </script>
 </script>

+ 1 - 0
src/modules/questions/views/BluePaperStructure.vue

@@ -119,6 +119,7 @@
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
                 @click="editStruct(scope.row)"
                 @click="editStruct(scope.row)"
+                plain
                 ><i class="el-icon-edit"></i>编辑</el-button
                 ><i class="el-icon-edit"></i>编辑</el-button
               >
               >
               <el-button
               <el-button

+ 30 - 12
src/modules/questions/views/CourseProperty.vue

@@ -62,10 +62,10 @@
           <el-form-item class="pull-left">
           <el-form-item class="pull-left">
             <span>批量操作:</span>
             <span>批量操作:</span>
             <el-button size="small" type="primary" @click="openCoursePropertys"
             <el-button size="small" type="primary" @click="openCoursePropertys"
-              ><i class="el-icon-circle-check"></i> 启用</el-button
+              ><i class="el-icon-check"></i> 启用</el-button
             >
             >
             <el-button size="small" type="danger" @click="closeCoursePropertys"
             <el-button size="small" type="danger" @click="closeCoursePropertys"
-              ><i class="el-icon-circle-close"></i> 禁用</el-button
+              ><i class="el-icon-close"></i> 禁用</el-button
             >
             >
           </el-form-item>
           </el-form-item>
         </el-row>
         </el-row>
@@ -93,7 +93,26 @@
         </el-table-column>
         </el-table-column>
         <el-table-column label="状态">
         <el-table-column label="状态">
           <template slot-scope="scope">
           <template slot-scope="scope">
-            <span>{{ getEnable(scope.row.enable) }}</span>
+            <span v-if="scope.row.enable">
+              <el-tooltip
+                class="item"
+                effect="dark"
+                content="启用"
+                placement="left"
+              >
+                <i class="el-icon-success" style="color:green;"></i>
+              </el-tooltip>
+            </span>
+            <span v-else>
+              <el-tooltip
+                class="item"
+                effect="dark"
+                content="禁用"
+                placement="left"
+              >
+                <i class="el-icon-error" style="color:red;"></i>
+              </el-tooltip>
+            </span>
           </template>
           </template>
         </el-table-column>
         </el-table-column>
         <el-table-column label="操作" width="260">
         <el-table-column label="操作" width="260">
@@ -103,19 +122,25 @@
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
                 @click="editCourseProperty(scope.row)"
                 @click="editCourseProperty(scope.row)"
+                plain
                 ><i class="el-icon-zoom-in"></i> 详情
                 ><i class="el-icon-zoom-in"></i> 详情
               </el-button>
               </el-button>
               <el-button
               <el-button
+                v-if="!scope.row.enable"
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
+                plain
                 @click="openCourseProperty(scope.row)"
                 @click="openCourseProperty(scope.row)"
-                ><i class="el-icon-circle-check"></i> 启用
+              >
+                <i class="fa fa-check" aria-hidden="true"></i>启用
               </el-button>
               </el-button>
               <el-button
               <el-button
+                v-if="scope.row.enable"
                 size="mini"
                 size="mini"
                 type="danger"
                 type="danger"
                 @click="closeCourseProperty(scope.row)"
                 @click="closeCourseProperty(scope.row)"
-                ><i class="el-icon-circle-close"></i> 禁用
+              >
+                <i class="fa fa-close" aria-hidden="true"></i>禁用
               </el-button>
               </el-button>
             </div>
             </div>
           </template>
           </template>
@@ -428,13 +453,6 @@ export default {
         }
         }
       });
       });
     },
     },
-    getEnable(value) {
-      if (value === true) {
-        return "开启";
-      } else {
-        return "禁用";
-      }
-    },
     //查询所有课程
     //查询所有课程
     getCourses(query) {
     getCourses(query) {
       query = query.trim();
       query = query.trim();

+ 5 - 1
src/modules/questions/views/ExportStructure.vue

@@ -118,7 +118,11 @@
         <el-table-column label="操作" width="175">
         <el-table-column label="操作" width="175">
           <template slot-scope="scope">
           <template slot-scope="scope">
             <div class="operate_left">
             <div class="operate_left">
-              <el-button size="mini" type="primary" @click="copy(scope.row)"
+              <el-button
+                size="mini"
+                type="primary"
+                @click="copy(scope.row)"
+                plain
                 ><i class="el-icon-edit"></i>复用</el-button
                 ><i class="el-icon-edit"></i>复用</el-button
               >
               >
               <el-button size="mini" type="danger" @click="del(scope.row)"
               <el-button size="mini" type="danger" @click="del(scope.row)"

+ 2 - 0
src/modules/questions/views/ExtractPaperRule.vue

@@ -134,6 +134,7 @@
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
                 @click="updateRules(scope.row)"
                 @click="updateRules(scope.row)"
+                plain
                 ><i class="el-icon-edit"></i>修改
                 ><i class="el-icon-edit"></i>修改
               </el-button>
               </el-button>
               <el-button
               <el-button
@@ -141,6 +142,7 @@
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
                 @click="openSingleExportPaperDialog(scope.row)"
                 @click="openSingleExportPaperDialog(scope.row)"
+                plain
                 ><i class="el-icon-download"></i> 下载
                 ><i class="el-icon-download"></i> 下载
               </el-button>
               </el-button>
             </div>
             </div>

+ 4 - 0
src/modules/questions/views/GenPaper.vue

@@ -156,6 +156,7 @@
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
                 @click="editGenPaper(scope.row)"
                 @click="editGenPaper(scope.row)"
+                plain
                 ><i class="el-icon-edit"></i>编辑</el-button
                 ><i class="el-icon-edit"></i>编辑</el-button
               >
               >
               <el-dropdown class="button_left">
               <el-dropdown class="button_left">
@@ -168,6 +169,7 @@
                       size="mini"
                       size="mini"
                       type="primary"
                       type="primary"
                       @click="openExportDialog(scope.row)"
                       @click="openExportDialog(scope.row)"
+                      plain
                       ><i class="el-icon-download"></i> 下载</el-button
                       ><i class="el-icon-download"></i> 下载</el-button
                     >
                     >
                   </el-dropdown-item>
                   </el-dropdown-item>
@@ -176,6 +178,7 @@
                       size="mini"
                       size="mini"
                       type="primary"
                       type="primary"
                       @click="previewPDF2(scope.row)"
                       @click="previewPDF2(scope.row)"
+                      plain
                       ><i class="el-icon-zoom-in"></i> 预览</el-button
                       ><i class="el-icon-zoom-in"></i> 预览</el-button
                     >
                     >
                   </el-dropdown-item>
                   </el-dropdown-item>
@@ -184,6 +187,7 @@
                       size="mini"
                       size="mini"
                       type="primary"
                       type="primary"
                       @click="openPrint(scope.row)"
                       @click="openPrint(scope.row)"
+                      plain
                       ><i class="el-icon-share"></i> 发送</el-button
                       ><i class="el-icon-share"></i> 发送</el-button
                     >
                     >
                   </el-dropdown-item>
                   </el-dropdown-item>

+ 4 - 1
src/modules/questions/views/ImportPaper.vue

@@ -69,7 +69,7 @@
                 ><i class="el-icon-search"></i> 查询</el-button
                 ><i class="el-icon-search"></i> 查询</el-button
               >
               >
               <el-button size="small" type="primary" @click="impPaper"
               <el-button size="small" type="primary" @click="impPaper"
-                ><i class="el-icon-upload"></i> 导入</el-button
+                ><i class="el-icon-upload2"></i> 导入</el-button
               >
               >
               <el-dropdown class="button_left">
               <el-dropdown class="button_left">
                 <el-button type="primary" size="small">
                 <el-button type="primary" size="small">
@@ -173,6 +173,7 @@
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
                 @click="editImportPaper(scope.row)"
                 @click="editImportPaper(scope.row)"
+                plain
                 ><i class="el-icon-edit"></i>编辑</el-button
                 ><i class="el-icon-edit"></i>编辑</el-button
               >
               >
               <el-dropdown class="button_left">
               <el-dropdown class="button_left">
@@ -185,6 +186,7 @@
                       size="mini"
                       size="mini"
                       type="primary"
                       type="primary"
                       @click="copyImportPaper(scope.row)"
                       @click="copyImportPaper(scope.row)"
+                      plain
                       ><i class="el-icon-tickets"></i> 复制</el-button
                       ><i class="el-icon-tickets"></i> 复制</el-button
                     >
                     >
                   </el-dropdown-item>
                   </el-dropdown-item>
@@ -193,6 +195,7 @@
                       size="mini"
                       size="mini"
                       type="primary"
                       type="primary"
                       @click="exportOriginalPaper(scope.row)"
                       @click="exportOriginalPaper(scope.row)"
+                      plain
                       ><i class="el-icon-download"></i> 下载</el-button
                       ><i class="el-icon-download"></i> 下载</el-button
                     >
                     >
                   </el-dropdown-item>
                   </el-dropdown-item>

+ 1 - 1
src/modules/questions/views/ImportPaperInfo.vue

@@ -268,7 +268,7 @@ export default {
           this.$http
           this.$http
             .get(CORE_API + "/course/query?name=" + query + "&enable=true")
             .get(CORE_API + "/course/query?name=" + query + "&enable=true")
             .then(response => {
             .then(response => {
-              this.courseList = response.body;
+              this.courseList = response.data;
               this.courseLoading = false;
               this.courseLoading = false;
             });
             });
         }
         }

+ 1 - 0
src/modules/questions/views/PaperStructure.vue

@@ -137,6 +137,7 @@
               <el-button
               <el-button
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
+                plain
                 @click="editPaperStruct(scope.row)"
                 @click="editPaperStruct(scope.row)"
                 ><i class="el-icon-edit"></i>编辑</el-button
                 ><i class="el-icon-edit"></i>编辑</el-button
               >
               >

+ 1 - 0
src/modules/questions/views/Question.vue

@@ -204,6 +204,7 @@
                 v-if="scope.row.questionType !== 'NESTED_ANSWER_QUESTION'"
                 v-if="scope.row.questionType !== 'NESTED_ANSWER_QUESTION'"
                 size="mini"
                 size="mini"
                 type="primary"
                 type="primary"
+                plain
                 @click="updateRow(scope.row)"
                 @click="updateRow(scope.row)"
               >
               >
                 <i class="el-icon-edit"></i>编辑
                 <i class="el-icon-edit"></i>编辑

+ 24 - 11
src/plugins/axios.js

@@ -2,6 +2,8 @@ import Vue from "vue";
 import axios from "axios";
 import axios from "axios";
 import router from "../router";
 import router from "../router";
 
 
+const ERROR_MSG_CONFIG = require("./errorMsgConfig").default;
+
 // Full config:  https://github.com/axios/axios#request-config
 // Full config:  https://github.com/axios/axios#request-config
 // axios.defaults.baseURL = process.env.baseURL || process.env.apiUrl || '';
 // axios.defaults.baseURL = process.env.baseURL || process.env.apiUrl || '';
 // axios.defaults.headers.common['Authorization'] = AUTH_TOKEN;
 // axios.defaults.headers.common['Authorization'] = AUTH_TOKEN;
@@ -145,18 +147,29 @@ _axios.interceptors.response.use(
 
 
     if (status != 200) {
     if (status != 200) {
       const data = error.response.data;
       const data = error.response.data;
-      if (data && data.desc) {
-        Vue.prototype.$notify({
-          showClose: true,
-          message: data.desc,
-          type: "error"
-        });
+      if (ERROR_MSG_CONFIG.map(v => v.code).includes(data.code)) {
+        const MSG = ERROR_MSG_CONFIG.find(v => v.code === data.code);
+        if (MSG.display) {
+          Vue.prototype.$notify({
+            showClose: true,
+            message: MSG.message,
+            type: "error"
+          });
+        }
       } else {
       } else {
-        Vue.prototype.$notify({
-          showClose: true,
-          message: "未定义异常: " + JSON.stringify(data, 2),
-          type: "error"
-        });
+        if (data && data.desc) {
+          Vue.prototype.$notify({
+            showClose: true,
+            message: data.desc,
+            type: "error"
+          });
+        } else {
+          Vue.prototype.$notify({
+            showClose: true,
+            message: "未定义异常: " + JSON.stringify(data, 2),
+            type: "error"
+          });
+        }
       }
       }
       return Promise.reject(error);
       return Promise.reject(error);
     }
     }

+ 7 - 0
src/plugins/errorMsgConfig.js

@@ -0,0 +1,7 @@
+export default [
+  {
+    code: "B-001-example",
+    display: false,
+    message: ""
+  }
+];

+ 3 - 1
src/store.js

@@ -2,6 +2,7 @@ import Vue from "vue";
 import Vuex from "vuex";
 import Vuex from "vuex";
 import user from "./modules/portal/store/user";
 import user from "./modules/portal/store/user";
 import currentPaths from "./modules/portal/store/currentPaths";
 import currentPaths from "./modules/portal/store/currentPaths";
+import menuList from "./modules/portal/store/menuList";
 
 
 Vue.use(Vuex);
 Vue.use(Vuex);
 
 
@@ -11,6 +12,7 @@ export default new Vuex.Store({
   actions: {},
   actions: {},
   modules: {
   modules: {
     user,
     user,
-    currentPaths
+    currentPaths,
+    menuList
   }
   }
 });
 });