Merge remote-tracking branch 'origin/dev0731' into dev0731

This commit is contained in:
lims1@hunktimes.com
2023-08-05 22:30:27 +08:00
11 changed files with 74 additions and 41 deletions

View File

@@ -102,6 +102,7 @@ const queryComments = function (pageSize) {
const majorTypes = function () {
return ajax.get('/xboe/m/boe/cases/majorTypes');
}
/**
* 详情新*/
const details = function (id, addView) {

View File

@@ -2,6 +2,7 @@
* 分类
*/
import ajax from '@/utils/xajax.js'
import request from '../unionAjax.js';
/**
* 提取全量树形结构数据
@@ -11,6 +12,16 @@ import ajax from '@/utils/xajax.js'
const tree = function(sysResType) {
return ajax.get(`/xboe/type/tree-list?sysResType=${sysResType}&status=1`);
}
/**
*
* @param {*} sysResType [1]
* @param {*} pid [字典类别码]
* @param {*} current [1当前页码]
* @returns
*/
const treeList = function(sysResType,pid,current) {
return request.get('/infrasApi',`/dict/page?type=${sysResType}&pid=${pid}&current=${current}`);
}
/**
* 按父ID查询列表
@@ -24,5 +35,6 @@ const list = function(sysResType, parentId) {
export default {
tree,
list
}
list,
treeList
}

View File

@@ -76,10 +76,11 @@
if(!data.id){
return;
}
if(item.info.deleted){
if(data.deleted){
this.$message.warning("此问题已删除");
return;
}
this.$router.push({ path: '/qa/answer', query: { id: data.id } });
},

View File

@@ -93,7 +93,7 @@
<el-dropdown-menu slot="dropdown">
<el-dropdown-item><router-link to="/index">学员</router-link></el-dropdown-item>
<el-dropdown-item v-if="identity == 2 || identity == 5" @click.native="setCurIdentity(2)"><router-link to="/need/waitaudit">教师</router-link></el-dropdown-item>
<el-dropdown-item v-if="identity == 3 || identity == 5" @click.native="setCurIdentity(3)"><router-link to="/course/manage">管理员</router-link></el-dropdown-item>
<el-dropdown-item v-if="identity == 3 || identity == 5" ><a :href="managerPath+'/learningpath'">管理员</a></el-dropdown-item>
</el-dropdown-menu>
</el-dropdown>
</div>
@@ -218,21 +218,17 @@ export default {
// });
},
handleCommand(val) {
if (val === "four") {
this.$emit('showClass',true)
} else {
let urlPre = window.location.protocol + "//" + window.location.host;
// process.env.VUE_APP_BOE_WEB_URL
let obj = {
one: urlPre + "/web/teacherLesson",
two: urlPre + "/grow180/login",
three: this.webBaseUrl + "/study/index?study=1",
// four: 'https://m.qingxuetang.com/x/?appId=qxtcorp306130',
five: urlPre + "/boe/new-employee/index.html",
six: urlPre + "/web/contributor/index",
};
window.open(obj[val]);
}
let urlPre=window.location.protocol+'//'+window.location.host;
// process.env.VUE_APP_BOE_WEB_URL
let obj = {
one: urlPre+'/web/teacherLesson',
two: urlPre+'/grow180/login',
three: this.webBaseUrl + '/study/index?study=1',
four: 'https://m.qingxuetang.com/x/?appId=qxtcorp306130',
five: urlPre+'/boe/new-employee/index.html',
six: urlPre+'/web/contributor/index'
};
window.open(obj[val]);
},
handleUcCommand(val) {
if (val == 'uc') {
@@ -304,7 +300,7 @@ export default {
}).then(() => {
this.$store.dispatch('LogOut').then(() => {
//location.href = this.webBaseUrl + '/login';
sessionStorage.setItem('dialog_session_show'+this.userInfo.aid,null); // 清除兴趣采集的"关闭"缓存
sessionStorage.setItem('dialog_session_show'+this.userInfo.aid,null); // 清除兴趣采集的"关闭"缓存
location.href = process.env.VUE_APP_LOGIN_URL;
});
})

View File

@@ -23,7 +23,7 @@ export const cutFullName = (fullName,num) => {
};
/**截取机构名称路径namePath最后两段不包含第一个 */
export const cutOrgNamePath = (namePath,firstOrder = -1) => {
export const cutOrgNamePath = (namePath) => {
let newName=namePath;
//debugger
if(newName){
@@ -36,9 +36,6 @@ export const cutOrgNamePath = (namePath,firstOrder = -1) => {
if(!newName){
newName=names[0]
}
if(firstOrder == 0){
newName=names[0]
}
}
// if(names.length>1){

View File

@@ -236,7 +236,7 @@ export default {
if (res.status == 200) {
this.$message({
type: 'success',
message: '设置优秀案例成功!'
message: '设置最佳案例成功!'
});
this.getData()
}

View File

@@ -872,14 +872,27 @@ export default {
apiUserBasic.getUserAudiences(params).then(res=>{
if(res.status==200){
let list=[];
this.pushData.count = res.result.totalElement;
res.result.audienceList.forEach(crowd=>{
// this.pushData.count = res.result.totalElement;
// res.result.audienceList.forEach(crowd=>{
// list.push({
// id:crowd.id,
// kid:crowd.kid,
// name:crowd.audienceName,
// sysCreateTime:crowd.createAt,
// audienceType:crowd.audienceType,
// users:crowd.totalMember,
// type:crowd.type,
// status:crowd.status
// })
// });
this.pushData.count = res.result.total;
res.result.list.forEach(crowd=>{
list.push({
id:crowd.id,
kid:crowd.kid,
kid:'',
name:crowd.audienceName,
sysCreateTime:crowd.createAt,
audienceType:crowd.audienceType,
audienceType:crowd.type,
users:crowd.totalMember,
type:crowd.type,
status:crowd.status

View File

@@ -346,6 +346,7 @@ import apiUser from "@/api/system/user.js";
import apiSearchterm from "@/api/modules/searchterm.js";
import { deepClone } from "../../../utils";
import apiDict from "@/api/modules/dict.js";
import apiType from "@/api/modules/type.js";
import { cutFullName } from "@/utils/tools.js";
import apiPlace from "@/api/phase2/place.js"
export default {
@@ -500,26 +501,28 @@ export default {
isBack = true;
}
console.log(isBack, 'isBack');
Promise.all([apiDict.items("org_domain"), apiCase.majorTypes()]).then(rs => {
if (rs[0].status == 200) {
rs[0].result.forEach(item => {
// Promise.all([apiType.items("org_domain"), apiCase.majorTypes()]).then(rs => {
Promise.all([apiType.treeList(1,90,1), apiCase.majorTypes()]).then(rs => {
if (rs[0].code == 200) {
const {records} = rs[0].data
records.forEach(item => {
item.fielclass = false;
item.type = 'org_domain';
item.list = item.list ? item.list : []
if (Array.isArray(item.list)) {
item.list = item.children ? item.children : []
if (Array.isArray(item.children)) {
item.list.forEach(sub => {
sub.list = sub.list ? sub.list : []
sub.list = sub.children ? sub.children : []
sub.fielclass = false
if (Array.isArray(sub.list)) {
if (Array.isArray(sub.children)) {
sub.list.forEach(three => {
three.list = three.list ? three.list : []
three.list = three.children ? three.children : []
three.fielclass = false
})
}
})
}
})
this.domain = rs[0].result;
this.domain = records;
}
if (rs[1].status == 200) {
rs[1].result.forEach(item => {
@@ -819,6 +822,7 @@ export default {
}
});
},
// 无用
async getdomain() {
let key = "org_domain";
await apiDict.items("org_domain").then(res => {
@@ -1066,6 +1070,7 @@ export default {
} else {
this.moreState = 3;
}
console.log(res?.result?.list ,'有没有数据');
this.caseList.list = res.result.list
this.getCaseUserData(res.result.list);
// 给所有的赋值
@@ -1186,6 +1191,9 @@ export default {
let ids = caseList.map((item, index) => {
return item.authorId;
});
//不能为空
if (!ids.length) return
const noReapetIds = [...new Set(ids)];
apiUser.getByIds(noReapetIds).then(res => {
if (res.status == 200) {

View File

@@ -121,7 +121,7 @@
<div class="teacher-info">
<div class="teacher-name">{{ item.teacherName }}</div>
<!-- <div class="teacher-remark" v-html="item.remark"></div> -->
<div class="teacher-remark">{{ cutOrgNamePath(item.orgInfo,0) }} </div>
<div class="teacher-remark">{{ cutOrgNamePath(item.orgInfo) }} </div>
</div>
</div>
</div>

View File

@@ -1029,7 +1029,7 @@ export default {
//增加死数据
item.children.push({
type: 12,
id: item.id + index,
id: item.id * (index + 200),
name: '线上品牌系列课程',
children: [],
checked: false,
@@ -1061,6 +1061,8 @@ export default {
})
}
$this.oneList.push(newItem);
console.log(newItem);
});
this.loadLocalFilters();
@@ -1433,6 +1435,9 @@ export default {
]
}
this.count = res?.result?.count
if(this.newData) {
this.count = 1
}
this.moreState = 3
} else {
this.moreState = 2;

View File

@@ -243,7 +243,7 @@
<!-- <span style="font-size: 12px; color:#666666 ;">( {{cutOrgNamePath(item.authorInfo.orgInfo)}} )</span> -->
</div>
<!-- <div class="teacher-remark" v-html="item.authorInfo.sign"></div> -->
<div class="teacher-remark">{{cutOrgNamePath(item.authorInfo.orgInfo,0)}}</div>
<div class="teacher-remark">{{cutOrgNamePath(item.authorInfo.orgInfo)}}</div>
</div>
<div style="padding-top:15px;width:70px;">
<followButton :auto="true" size="small" :aid="item.teacherId"></followButton>