|
@@ -309,6 +309,7 @@ import {
|
|
asyncPlayLog,
|
|
asyncPlayLog,
|
|
queryUserInfo,
|
|
queryUserInfo,
|
|
queryAllOrgan,
|
|
queryAllOrgan,
|
|
|
|
+ queryTeacherOrgan,
|
|
orderComment
|
|
orderComment
|
|
} from "@/api/process/work-order";
|
|
} from "@/api/process/work-order";
|
|
import store from "@/store";
|
|
import store from "@/store";
|
|
@@ -372,6 +373,7 @@ export default {
|
|
},
|
|
},
|
|
userIds: null,
|
|
userIds: null,
|
|
tenantId: 1,
|
|
tenantId: 1,
|
|
|
|
+ userType: "SYSTEM",
|
|
btn_group: [],
|
|
btn_group: [],
|
|
is_end: 0, // 是否结束
|
|
is_end: 0, // 是否结束
|
|
remoteFunc: {
|
|
remoteFunc: {
|
|
@@ -511,6 +513,7 @@ export default {
|
|
if (res.code == 200) {
|
|
if (res.code == 200) {
|
|
this.userIds = res.data.id;
|
|
this.userIds = res.data.id;
|
|
this.tenantId = res.data.tenantId;
|
|
this.tenantId = res.data.tenantId;
|
|
|
|
+ this.userType = res.data.userType;
|
|
} else {
|
|
} else {
|
|
this.$message.error(res.data);
|
|
this.$message.error(res.data);
|
|
}
|
|
}
|
|
@@ -986,37 +989,46 @@ export default {
|
|
// })
|
|
// })
|
|
// },
|
|
// },
|
|
async getAllOrgan() {
|
|
async getAllOrgan() {
|
|
- await queryAllOrgan({ tenantId: this.tenantId }).then(res => {
|
|
|
|
- if (res.code == 200) {
|
|
|
|
- const result = res.data;
|
|
|
|
- const filterOrganId = [
|
|
|
|
- 36,
|
|
|
|
- 39,
|
|
|
|
- 41,
|
|
|
|
- 42,
|
|
|
|
- 43,
|
|
|
|
- 44,
|
|
|
|
- 45,
|
|
|
|
- 46,
|
|
|
|
- 47,
|
|
|
|
- 48,
|
|
|
|
- 49,
|
|
|
|
- 50,
|
|
|
|
- 52,
|
|
|
|
- 54,
|
|
|
|
- 55,
|
|
|
|
- 56
|
|
|
|
- ];
|
|
|
|
- let tempOrgan = [];
|
|
|
|
- // 过滤不会显示的分部
|
|
|
|
- result.forEach(item => {
|
|
|
|
- if (!filterOrganId.includes(item.id)) {
|
|
|
|
- tempOrgan.push(item);
|
|
|
|
- }
|
|
|
|
- });
|
|
|
|
- this.organList = tempOrgan;
|
|
|
|
- }
|
|
|
|
- });
|
|
|
|
|
|
+ // 获取分部
|
|
|
|
+ console.log(this.tenantId, "tenantId");
|
|
|
|
+ if (this.userType.indexOf("SYSTEM") != -1) {
|
|
|
|
+ queryAllOrgan({ tenantId: this.tenantId }).then((res) => {
|
|
|
|
+ if (res.code == 200) {
|
|
|
|
+ const result = res.data;
|
|
|
|
+ const filterOrganId = [
|
|
|
|
+ 36, 39, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 52, 54, 55, 56,
|
|
|
|
+ ];
|
|
|
|
+ let tempOrgan = [];
|
|
|
|
+ // 过滤不会显示的分部
|
|
|
|
+ result.forEach((item) => {
|
|
|
|
+ if (!filterOrganId.includes(item.id)) {
|
|
|
|
+ tempOrgan.push(item);
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ this.organList = tempOrgan;
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ } else {
|
|
|
|
+ queryTeacherOrgan({ tenantId: this.tenantId }).then((res) => {
|
|
|
|
+ if (res.code == 200) {
|
|
|
|
+ const result = res.data;
|
|
|
|
+ const filterOrganId = [
|
|
|
|
+ 36, 39, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 52, 54, 55, 56,
|
|
|
|
+ ];
|
|
|
|
+ let tempOrgan = [];
|
|
|
|
+ // 过滤不会显示的分部
|
|
|
|
+ result.forEach((item) => {
|
|
|
|
+ if (!filterOrganId.includes(item.key)) {
|
|
|
|
+ tempOrgan.push({
|
|
|
|
+ id: item.key,
|
|
|
|
+ name: item.value,
|
|
|
|
+ });
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ this.organList = tempOrgan;
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ }
|
|
},
|
|
},
|
|
dataModelFormatBr(str) {
|
|
dataModelFormatBr(str) {
|
|
return str ? str.replace(/\n/g, "<br />") : str;
|
|
return str ? str.replace(/\n/g, "<br />") : str;
|