// 搜索用的下拉数据列表 import { payOrderType, auditType, auditPaymentType, orderServerType, orderAuditType, rewardModeType, classTime, musicClassType, ProbationPeriodStatus, downListType, musicGroupType, conclusion, // vipResetType, // courseViewType, clientType, couponType, backType, memberEnum, coupontypeDetail, issue, feedbackType, feedbackTypeDesc, campState, catgGoupType, catRole, catType, quiteReason, payUserType, levelStatus, evaluateStatus, problemType, schoolUserType, shareLiveType, courseEmnu } from "../constant"; // 课程类型 let tenantConfig = sessionStorage.getItem("tenantConfig"); tenantConfig = tenantConfig ? JSON.parse(tenantConfig) : {}; let tenantId = tenantConfig.tenantId; let courseType = null; let musicCourseType = null; if (tenantId == 1) { musicCourseType = [ { label: "声部课", value: "SINGLE" }, { label: "合奏课", value: "MIX" }, { label: "基础技能课", value: "HIGH" }, { label: "线上基础技能课", value: "HIGH_ONLINE" }, { label: "乐团网管课", value: "MUSIC_NETWORK" }, { label: "集训声部课", value: "TRAINING_SINGLE" }, { label: "集训合奏课", value: "TRAINING_MIX" }, { label: "课堂课", value: "CLASSROOM" }, { label: "综合课", value: "COMPREHENSIVE" } ]; courseType = [ { label: "声部课", value: "SINGLE" }, { label: "合奏课", value: "MIX" }, { label: "基础技能课", value: "HIGH" }, { label: "线上基础技能课", value: "HIGH_ONLINE" }, { label: "vip课", value: "VIP" }, { label: "试听课", value: "DEMO" }, { label: "综合课", value: "COMPREHENSIVE" }, { label: "网管课", value: "PRACTICE" }, { label: "乐团网管课", value: "MUSIC_NETWORK" }, { label: "启蒙课", value: "ENLIGHTENMENT" }, { label: "集训声部课", value: "TRAINING_SINGLE" }, { label: "集训合奏课", value: "TRAINING_MIX" }, { label: "课堂课", value: "CLASSROOM" }, { label: "对外课", value: "COMM" }, { label: "直播课", value: "LIVE" } ]; } else { musicCourseType = [ { label: "声部课", value: "SINGLE" }, { label: "合奏课", value: "MIX" }, { label: "基础技能课", value: "HIGH" }, { label: "集训声部课", value: "TRAINING_SINGLE" }, { label: "集训合奏课", value: "TRAINING_MIX" }, { label: "课堂课", value: "CLASSROOM" }, { label: "综合课", value: "COMPREHENSIVE" } ]; courseType = [ { label: "声部课", value: "SINGLE" }, { label: "合奏课", value: "MIX" }, { label: "vip课", value: "VIP" }, { label: "试听课", value: "DEMO" }, { label: "综合课", value: "COMPREHENSIVE" }, { label: "网管课", value: "PRACTICE" }, { label: "启蒙课", value: "ENLIGHTENMENT" }, { label: "集训声部课", value: "TRAINING_SINGLE" }, { label: "集训合奏课", value: "TRAINING_MIX" }, { label: "课堂课", value: "CLASSROOM" }, { label: "对外课", value: "COMM" }, { label: "直播课", value: "LIVE" } ]; } export { courseType, musicCourseType }; export const courseListType = [ { label: "乐团课", value: "MUSIC" }, { label: "VIP课", value: "VIP" }, { label: "网管课", value: "PRACTICE" }, { label: "直播课", value: "LIVE" } ]; // 考勤状态 export const attendance = [ { label: "正常签到", value: 1 }, { label: "异常签到", value: 0 } ]; // 工作类型 export const jobNature = [ { label: "兼职", value: "PART_TIME" }, { label: "全职", value: "FULL_TIME" }, { label: "劳务", value: "LABOUR" } // { label: '临时工', value: 'TEMPORARY' } ]; // 老师状态 export const teacherStatus = [ { label: "正常", value: "0" }, { label: "冻结", value: "1" }, { label: "锁定", value: "9" } ]; export const stuAttendance = [ { value: "NORMAL", label: "正常" }, { value: "TRUANT", label: "旷课" }, { value: "LEAVE", label: "请假" } ]; // 考勤状态 export const attendanceStatus = [ ...stuAttendance, { value: "QUIT_SCHOOL", label: "休学" }, { value: "DROP_OUT", label: "退学" }, { value: "LATE", label: "迟到" } // { value: "DROP_OUT", label: "休学" } ]; // 交易状态 export const orderStatus = [ { value: "APPLY", label: "报名" }, { value: "RENEW", label: "续费" }, { value: "MEMBER", label: "会员购买" }, { value: "SMALL_CLASS_TO_BUY", label: "VIP购买" }, { value: "SPORADIC", label: "零星收费" }, { value: "LUCK", label: "福袋活动" }, { value: "DEGREE_REGISTRATION", label: "考级报名" }, { value: "DOUBLE_ELEVEN2020", label: "2020双十一活动" }, { value: "DOUBLE_ELEVEN2021", label: "2021双十一活动" }, { value: "DEGREE", label: "儿童节活动" }, { value: "PRACTICE_GROUP_BUY", label: "网管课" }, { value: "PRACTICE_GROUP_RENEW", label: "网管课续费" }, { value: "REPAIR", label: "乐器维修" }, { value: "OUTORDER", label: "外部收入" }, { value: "GOODS_SELL", label: "商品销售" }, { value: "MALL_BUY", label: "商城销售" }, { value: "SUBJECT_CHANGE", label: "声部更换" }, { value: "MAINTENANCE", label: "乐器保养" }, { value: "ADD_STUDENT", label: "乐团报名" }, { value: "REPLACEMENT", label: "乐器置换" }, { value: "SCHOOL", label: "学校订单" }, { value: "PERSONAL", label: "个人订单" }, { value: "OTHER", label: "其他" }, { value: "ACTIVITY", label: "活动购买" }, { value: "LIVE_BUY", label: "直播购物" }, { value: "LIVE_GROUP_BUY", label: "直播课购买" } ]; // 交易状态 export const dealStatus = [ { value: "ING", label: "交易中" }, { value: "SUCCESS", label: "成功交易" }, { value: "FAILED", label: "交易失败" }, { value: "CLOSE", label: "交易关闭" } ]; export const vipGroupStatus = [ { value: "0", text: "未开始" }, { value: "1", text: "报名中" }, // { // value: "5", // text: "报名结束" // }, { value: "2", text: "进行中" }, { value: "4", text: "已结束" }, { value: "3", text: "取消" } // { // value: "6", // text: "暂停" // } ]; // 课程状态 export const courseStatus = [ { value: "NOT_START", label: "未开始" }, { value: "UNDERWAY", label: "进行中" }, { value: "OVER", label: "已结束" } ]; export const courseGroupStatus = [ { value: "NORMAL", label: "正常" }, { value: "LOCK", label: "锁定" }, { value: "FINISH", label: "结束" }, { value: "CANCEL", label: "取消" } ]; export const commGroupStatus = [ { value: "NORMAL", label: "进行中" }, { value: "FINISH", label: "结束" }, { value: "CANCEL", label: "关闭" }, { value: "LOCK", label: "锁定" } ]; // 老师时间充值状态 export const teacherTimeStatus = [ { value: "RECHARGE", label: "充值" }, { value: "CONSUME", label: "建课" }, { value: "RETURN", label: "退课" }, { value: "MANUAL_ADD", label: "系统充值" }, { value: "MANUAL_SUB", label: "系统扣除" } ]; export const practiceGroupType = [ { value: "FREE", label: "免费" }, { value: "CHARGE", label: "收费" }, { value: "TRIAL", label: "试听课" }, { value: "CARE_PACKAGE", label: "关心包" }, { value: "COME_ON_PACKAGE", label: "加油包" } ]; export const visitChiose = [ { value: "课程推荐", label: "课程推荐", children: [ { value: "新课推荐", label: "新课推荐" }, { value: "续费提醒", label: "续费提醒" } ] }, { value: "常规回访", label: "常规回访", children: [ { value: "课后及训练回访", label: "课后及训练回访" }, { value: "练习及乐团表现", label: "练习及乐团表现" } ] }, { value: "其它", label: "其它", children: [ { value: "其它", label: "其它" } ] } ]; export const visitChiose1 = [ { value: "课程推荐", label: "课程推荐", children: [ { value: "新课推荐", label: "新课推荐" }, { value: "续费提醒", label: "续费提醒" } ] }, { value: "常规回访", label: "常规回访", children: [ { value: "课后及训练回访", label: "课后及训练回访" }, { value: "练习及乐团表现", label: "练习及乐团表现" }, { label: "考勤申诉", value: "考勤申诉" }, { value: "异常请假回访", label: "异常请假回访" } ] }, { value: "小课回访", label: "小课回访", children: [ { value: "续费类回访", label: "续费类回访" }, { value: "服务回访", label: "服务回访" }, { value: "其他", label: "其他" } ] }, { value: "云教练", label: "云教练", children: [ { value: "体验回访", label: "体验回访" } ] }, { value: "其它", label: "其它", children: [ { value: "其它", label: "其它" }, { value: "会员续费", label: "会员续费" } ] } ]; // 交易状态 export const paymentChannelStatus = [ { value: "YQPAY", label: "双乾" }, { value: "BALANCE", label: "余额" }, { value: "ADAPAY", label: "汇付" }, { value: "YEEPAY", label: "易宝" } ]; // 销售类型 export const saleStatus = [ { value: "INSTRUMENT", label: "乐器销售" }, { value: "ACCESSORIES", label: "配件销售" }, { value: "SCHOOL_BUY", label: "学校采购" }, { value: "OTHER", label: "其它" } ]; // 商品类型 export const goodsType = [ { value: "INSTRUMENT", label: "乐器" }, { value: "ACCESSORIES", label: "辅件" }, { value: "TEACHING", label: "教材" }, { value: "STAFF", label: "教谱" }, { value: "OTHER", label: "其它" } ]; export const classStatus = [ { value: "1", label: "一年级" }, { value: "2", label: "二年级" }, { value: "3", label: "三年级" }, { value: "4", label: "四年级" }, { value: "5", label: "五年级" }, { value: "6", label: "六年级" }, { value: "7", label: "初一" }, { value: "8", label: "初二" }, { value: "9", label: "初三" }, { value: "10", label: "高一" }, { value: "11", label: "高二" }, { value: "12", label: "高三" } ]; // 库存类型 export const stockType = [ { value: "INTERNAL", label: "内部" }, { value: "EXTERNAL", label: "外部" }, { value: "ALL", label: "全部" } ]; // export const musicGroupStatus = [ // { value: 'DRAFT', text: '编辑中' }, // { value: 'AUDIT', text: '审核中' }, // { value: 'PRE_APPLY', text: '预报名中' }, // { value: 'DRAFT', text: '创建缴费中' }, // { value: 'APPLY', text: '报名中' }, // { value: 'PAY', text: '缴费中' }, // { value: 'PREPARE', text: '筹备中' }, // { value: 'PROGRESS', text: '进行中' }, // { value: 'FEE_AUDIT', text: '费用审核中' }, // { value: 'AUDIT_FAILED', text: '审核失败' }, // { value: 'PAUSE', text: '暂停' }, // { value: 'CANCELED', text: '取消' }, // { value: 'CLOSE', text: '已关闭' }, // ] export const vipResetTypeList = [ { label: "不限制", value: "1" }, { label: "线上不可调为线下", value: "0" }, { label: "线下不可调为线上", value: "2" }, { label: "线上线下不可互调", value: "3" } ]; export const musicGroupStatus = getValueForKey(musicGroupType); export const classTimeList = getValueForKey(classTime); export const courseViewTypeList = [ { label: "课程收费", value: 0 }, { label: "会员收费", value: 2 }, { label: "免费", value: 3 } ]; export const payOrderTypeList = getValueForKey(payOrderType); export const auditTypeList = getValueForKey(auditType); export const auditPaymentTypeList = getValueForKey(auditPaymentType); export const orderServerList = getValueForKey(orderServerType); export const orderAuditTypeList = getValueForKey(orderAuditType); export const rewardModeTypeList = getValueForKey(rewardModeType); export const musicClassTypeList = getValueForKey(musicClassType); export const ProbationPeriodList = getValueForKey(ProbationPeriodStatus); export const downTypeList = getValueForKey(downListType); export const conclusionList = getValueForKey(conclusion); export const clientList = getValueForKey(clientType); export const couponTypeList = getValueForKey(couponType); export const backTypeList = getValueForKey(backType); export const memberEnumList = getValueForKey(memberEnum); export const coupontypeDetailList = getValueForKey(coupontypeDetail); export const issueList = getValueForKey(issue); export const feedbackTypeList = getValueForKey(feedbackType); export const feedbackTypeDescList = getValueForKey(feedbackTypeDesc); export const campStateList = getValueForKey(campState); export const catgGoupTypeList = getValueForKey(catgGoupType); export const catRoleList = getValueForKey(catRole); export const catTypeList = getValueForKey(catType); export const quiteReasonList = getValueForKey(quiteReason); export const payUserTypeList = getValueForKey(payUserType); export const levelStatusList = getValueForKey(levelStatus); export const evaluateStatusList = getValueForKey(evaluateStatus); export const problemTypeList = getValueForKey(problemType); export const schoolUserTypeList = getValueForKey(schoolUserType); export const shareLiveTypeList = getValueForKey(shareLiveType); export const courseEmnuList = getValueForKey(courseEmnu); //downListType function getValueForKey(obj) { let arr = []; for (let k in obj) { arr.push({ label: obj[k], value: k }); } return arr; } export const array2object = (array, [lk, vk] = ["value", "label"]) => { const object = {}; if (array && array.length) { for (const item of array) { object[item[lk]] = item[vk]; } } return object; }; // export { // courseType, // attendance, // jobNature, // teacherStatus, // attendanceStatus, // orderStatus, // dealStatus, // musicGroupStatus, // vipGroupStatus, // courseStatus, // teacherTimeStatus, // courseGroupStatus, // commGroupStatus, // courseListType, // practiceGroupType, // visitChiose, // paymentChannelStatus, // saleStatus, // goodsType, // classStatus, // stockType, // classTimeList // }