Commit d31edcc2 by yuananting

fix:暂存bug修改

parent 42d8931e
/* /*
* @Author: 吴文洁 * @Author: 吴文洁
* @Date: 2020-08-31 09:34:25 * @Date: 2020-08-31 09:34:25
* @LastEditors: Please set LastEditors * @LastEditors: yuananting
* @LastEditTime: 2021-07-20 17:21:16 * @LastEditTime: 2021-08-17 19:20:33
* @Description: * @Description:
* @Copyright: 杭州杰竞科技有限公司 版权所有 * @Copyright: 杭州杰竞科技有限公司 版权所有
*/ */
import Storage from './storage'; import Storage from './storage';
import { PREFIX, USER_PREFIX } from '@/domains/basic-domain/constants'; import { PREFIX, USER_PREFIX } from '@/domains/basic-domain/constants';
declare var window:any; declare var window: any;
class User { class User {
getExpirationTime() { getExpirationTime() {
return Storage.get(`${PREFIX}_expiration_time`) return Storage.get(`${PREFIX}_expiration_time`);
} }
getVersion() { getVersion() {
return Storage.getObj(`${PREFIX}_version`) return Storage.getObj(`${PREFIX}_version`);
} }
getStoreId(){ getStoreId() {
return window.currentStoreUserInfo.storeId || Storage.get(`${PREFIX}_storeId`) return window.currentStoreUserInfo.storeId || Storage.get(`${PREFIX}_storeId`);
} }
getEnterpriseId() { getEnterpriseId() {
...@@ -43,15 +42,15 @@ class User { ...@@ -43,15 +42,15 @@ class User {
getCustomerId() { getCustomerId() {
return Storage.get(`${PREFIX}_customerId`); return Storage.get(`${PREFIX}_customerId`);
} }
getUserId() { getUserId() {
return window.currentStoreUserInfo.userId || Storage.get(`${PREFIX}_userId`); return window.currentStoreUserInfo.userId || Storage.get(`${PREFIX}_userId`);
} }
getAvatar(){ getAvatar() {
return Storage.get(`${PREFIX}_avatar`); return Storage.get(`${PREFIX}_avatar`);
} }
getUserRole() { getUserRole() {
return Storage.get(`${PREFIX}_userRole`); return Storage.get(`${PREFIX}_userRole`);
} }
...@@ -64,16 +63,16 @@ class User { ...@@ -64,16 +63,16 @@ class User {
return Storage.get(`${PREFIX}_isAdmin`); return Storage.get(`${PREFIX}_isAdmin`);
} }
setExpirationTime(value:number) { setExpirationTime(value: number) {
return Storage.set(`${PREFIX}_expiration_time`,value) return Storage.set(`${PREFIX}_expiration_time`, value);
} }
setVersion(value:any) { setVersion(value: any) {
return Storage.setObj(`${PREFIX}_version`,value) return Storage.setObj(`${PREFIX}_version`, value);
} }
setStoreId(value:any){ setStoreId(value: any) {
return Storage.set(`${PREFIX}_storeId`,value) return Storage.set(`${PREFIX}_storeId`, value);
} }
setEnterpriseId(value: any) { setEnterpriseId(value: any) {
...@@ -92,6 +91,10 @@ class User { ...@@ -92,6 +91,10 @@ class User {
return Storage.set(`${PREFIX}_storeUserId`, value); return Storage.set(`${PREFIX}_storeUserId`, value);
} }
setStoreUserName(value: any) {
return Storage.set(`${PREFIX}_storeUserName`, value);
}
setCustomerId(value: any) { setCustomerId(value: any) {
return Storage.set(`${PREFIX}_customerId`, value); return Storage.set(`${PREFIX}_customerId`, value);
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 吴文洁 * @Author: 吴文洁
* @Date: 2019-09-10 18:26:03 * @Date: 2019-09-10 18:26:03
* @LastEditors: yuananting * @LastEditors: yuananting
* @LastEditTime: 2021-08-09 19:20:55 * @LastEditTime: 2021-08-17 19:19:42
* @Description: * @Description:
*/ */
import React, { useRef, useContext, useEffect, useState } from 'react'; import React, { useRef, useContext, useEffect, useState } from 'react';
...@@ -81,6 +81,7 @@ function Header(props) { ...@@ -81,6 +81,7 @@ function Header(props) {
setPhone(phone); setPhone(phone);
setAvatar(res.result.avatar); setAvatar(res.result.avatar);
User.setAvatar(res.result.avatar); User.setAvatar(res.result.avatar);
User.setStoreUserName(weChatAccount);
}); });
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yuananting * @Author: yuananting
* @Date: 2021-07-29 13:57:03 * @Date: 2021-07-29 13:57:03
* @LastEditors: yuananting * @LastEditors: yuananting
* @LastEditTime: 2021-08-17 18:21:35 * @LastEditTime: 2021-08-17 19:14:55
* @Description: 任务中心-培训任务-新建页面 * @Description: 任务中心-培训任务-新建页面
* @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有 * @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有
* @@Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有 * @@Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有
...@@ -21,6 +21,7 @@ import { randomString } from '@/domains/basic-domain/utils'; ...@@ -21,6 +21,7 @@ import { randomString } from '@/domains/basic-domain/utils';
import TaskCenterService from '@/domains/task-center-domain/TaskCenterService'; import TaskCenterService from '@/domains/task-center-domain/TaskCenterService';
import Bus from '@/core/bus'; import Bus from '@/core/bus';
import $ from 'jquery'; import $ from 'jquery';
import user from '@/common/js/user';
function AddTrainTask() { function AddTrainTask() {
const type = getParameterByName('type'); const type = getParameterByName('type');
...@@ -33,7 +34,11 @@ function AddTrainTask() { ...@@ -33,7 +34,11 @@ function AddTrainTask() {
taskName: '', // 培训任务名称 taskName: '', // 培训任务名称
coverUrl: defaultCover, coverUrl: defaultCover,
coverId: null, coverId: null,
helpStoreUserIds: [], // 指定协同者id helpStoreUserIds: [
{
checkedId: User.getStoreUserId,
},
], // 指定协同者id
timeType: 'FOREVER', // 培训时间,默认永久有效 timeType: 'FOREVER', // 培训时间,默认永久有效
startTime: null, // 固定时间段-开始时间 startTime: null, // 固定时间段-开始时间
endTime: null, // 固定时间段-结束时间 endTime: null, // 固定时间段-结束时间
......
...@@ -86,6 +86,11 @@ ...@@ -86,6 +86,11 @@
font-size: 14px; font-size: 14px;
color: #cccccc; color: #cccccc;
} }
.disabled {
color: #ccc !important;
cursor: not-allowed !important;
pointer-events: none !important;
}
} }
.learning-model-tips { .learning-model-tips {
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: yuananting * @Author: yuananting
* @Date: 2021-08-12 16:27:38 * @Date: 2021-08-12 16:27:38
* @LastEditors: yuananting * @LastEditors: yuananting
* @LastEditTime: 2021-08-13 19:39:34 * @LastEditTime: 2021-08-17 19:10:02
* @Description: 新建培训任务-选择协同人员 * @Description: 新建培训任务-选择协同人员
* @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有 * @Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有
* @@Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有 * @@Copyrigh: © 2020 杭州杰竞科技有限公司 版权所有
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment