|
@@ -190,6 +190,7 @@
|
|
|
},
|
|
|
methods: {
|
|
|
getMsg() {
|
|
|
+ //获取模具
|
|
|
this.http.post( this.port.base.moulds, {
|
|
|
belongCompanyId: this.user.companyId
|
|
|
},
|
|
@@ -210,49 +211,44 @@
|
|
|
type: "error"
|
|
|
});
|
|
|
});
|
|
|
-
|
|
|
- this.http.post( this.port.base.ownerComps, {
|
|
|
- id: this.user.companyId
|
|
|
- },
|
|
|
- res => {
|
|
|
+ //获取公司
|
|
|
+ // this.http.post( this.port.base.ownerComps, {
|
|
|
+ // id: this.user.companyId
|
|
|
+ // },
|
|
|
+ // res => {
|
|
|
+ // if (res.code == "ok") {
|
|
|
+ // this.companys = res.data;
|
|
|
+ // } else {
|
|
|
+ // this.$message({
|
|
|
+ // message: res.msg,
|
|
|
+ // type: "error"
|
|
|
+ // });
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // error => {
|
|
|
+ // this.listLoading = false;
|
|
|
+ // this.$message({
|
|
|
+ // message: error,
|
|
|
+ // type: "error"
|
|
|
+ // });
|
|
|
+ // });
|
|
|
+ //新版获取公司
|
|
|
+ this.http.post(this.port.base.getInfo, {}, res => {
|
|
|
if (res.code == "ok") {
|
|
|
this.companys = res.data;
|
|
|
- } else {
|
|
|
- this.$message({
|
|
|
- message: res.msg,
|
|
|
- type: "error"
|
|
|
- });
|
|
|
- }
|
|
|
- },
|
|
|
- error => {
|
|
|
- this.listLoading = false;
|
|
|
- this.$message({
|
|
|
- message: error,
|
|
|
- type: "error"
|
|
|
- });
|
|
|
- });
|
|
|
-
|
|
|
- this.http.post( this.port.project.projects, {},
|
|
|
- res => {
|
|
|
- if (res.code == "ok") {
|
|
|
- this.projects = res.data;
|
|
|
} else {
|
|
|
this.$message({
|
|
|
message: res.msg,
|
|
|
- type: "error"
|
|
|
+ type: 'error'
|
|
|
});
|
|
|
}
|
|
|
- },
|
|
|
- error => {
|
|
|
- this.listLoading = false;
|
|
|
+ }, error => {
|
|
|
this.$message({
|
|
|
message: error,
|
|
|
- type: "error"
|
|
|
+ type: 'error'
|
|
|
});
|
|
|
});
|
|
|
- },
|
|
|
- //超级管理员获取项目列表
|
|
|
- getMsg2(){
|
|
|
+ //获取项目
|
|
|
this.http.post( this.port.project.projects, {},
|
|
|
res => {
|
|
|
if (res.code == "ok") {
|
|
@@ -415,7 +411,7 @@
|
|
|
});
|
|
|
}
|
|
|
});
|
|
|
- }
|
|
|
+ },
|
|
|
},
|
|
|
created() {
|
|
|
let height = window.innerHeight;
|
|
@@ -426,11 +422,7 @@
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
|
- if(this.user.id != 1){
|
|
|
- this.getMsg();
|
|
|
- }else{
|
|
|
- this.getMsg2();
|
|
|
- }
|
|
|
+ this.getMsg();
|
|
|
this.getMoldList();
|
|
|
}
|
|
|
};
|