Commit 168c9933 by chenjinjing

no message

parent 596d9df1
......@@ -11,7 +11,7 @@ import { deleteManyData } from "../../data/delete";
import { TABLEENUM } from "../../data/models/model";
import { find, findOnce } from "../../data/select";
import { updateOneData } from "../../data/update";
import { generateSystemId, getEdition, successResult } from "../../tools/system";
import { generateSystemId, getEdition, successErrorResult, successResult } from "../../tools/system";
import { BizError } from "../../util/bizError";
import { extractData } from "../../util/piecemeal";
import { eccEnumValue } from "../../util/verificationEnum";
......@@ -315,6 +315,31 @@ export async function getSheng ({userId}) {
/**
* 能否申请变更理事
* @param userId 登录的userid
* @returns
*/
export async function getApply({userId}) {
let oldInfo = await findOnce(TABLEENUM.用户表, {userId});
if (!oldInfo || !oldInfo.userId) throw new BizError(ERRORENUM.目标数据不存在);
const NowMs = new Date().valueOf();
let isApply = true;
let time = moment(1747895510765).format("YYYY-MM-dd")
if (oldInfo.memberType == MEMBERTYPE.个人会员) {
if(oldInfo.lifespanEndTime) {
// 会员有效期结束时间小于当前时间的欠费会员
if(oldInfo.memberState == MEMBERSTATE.异常 || oldInfo.lifespanEndTime < NowMs) isApply = false;
}
}
return {isApply};
}
/**
* 变更理事申请,职位未发生变更不需要走当前流程
* @param memberLevel 变更理事
* @param userId 登录的userid
......
......@@ -957,6 +957,13 @@ export const Config = {
},
{
apiName:"变更职位",
subUrl:'/homepage/getapply',
param:[
],
bindBiz:homePageBiz.getApply
},
{
apiName:"变更职位",
subUrl:'/homepage/memberlevelupdate',
param:[
{key:"memberLevel", type:"Number", desc:"变更职位"}
......
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