Commit bc061837 by chenjinjing

no message

parent ecb28620
...@@ -58,8 +58,8 @@ export async function pendingReviewList({unitName, joinTime, memberType, sheng, ...@@ -58,8 +58,8 @@ export async function pendingReviewList({unitName, joinTime, memberType, sheng,
* @param id 待审核列表返回的用户id * @param id 待审核列表返回的用户id
* @returns * @returns
*/ */
export async function adopt({id}) { export async function adopt({id, session}) {
let userInfo = await findOnce(TABLEENUM.用户表, {userId:id, isAdmin:STATE.}, ["userId", "registerFlow", "userRegisterState", "memberType", "unitName", "name"]); let userInfo = await findOnce(TABLEENUM.用户表, {userId:id, isAdmin:STATE., session}, ["userId", "registerFlow", "userRegisterState", "memberType", "unitName", "name"]);
if (!userInfo || !userInfo.userId) throw new BizError(ERRORENUM.目标数据不存在); if (!userInfo || !userInfo.userId) throw new BizError(ERRORENUM.目标数据不存在);
if (userInfo.memberType == MEMBERTYPE.个人会员 && userInfo.registerFlow != REGISTERFLOW.完成第二步) { if (userInfo.memberType == MEMBERTYPE.个人会员 && userInfo.registerFlow != REGISTERFLOW.完成第二步) {
throw new BizError(ERRORENUM.不具备审批条件, `${userInfo.userId}为个人会员,并没有完成第二步`); throw new BizError(ERRORENUM.不具备审批条件, `${userInfo.userId}为个人会员,并没有完成第二步`);
......
...@@ -318,7 +318,7 @@ export async function backInvoice({id}) { ...@@ -318,7 +318,7 @@ export async function backInvoice({id}) {
* 发票管理-已开发票 success * 发票管理-已开发票 success
* @param param0 * @param param0
*/ */
export async function InvoicedList({unitName, paymentType, isPay, pageNumber}) { export async function invoicedList({unitName, paymentType, isPay, pageNumber}) {
eccEnumValue("发票列表", "支付类型", PAYMENTTYPE, paymentType); eccEnumValue("发票列表", "支付类型", PAYMENTTYPE, paymentType);
eccEnumValue("发票列表", "是否支付", ISPAYENUM, isPay ); eccEnumValue("发票列表", "是否支付", ISPAYENUM, isPay );
......
...@@ -25,12 +25,15 @@ export async function adminList({pageNumber}) { ...@@ -25,12 +25,15 @@ export async function adminList({pageNumber}) {
let dataList = []; let dataList = [];
dbList.forEach(info => { dbList.forEach(info => {
let {userId, memberState, loginId, adminLv, adminType} = info; let {userId, memberState, loginId, adminLv, adminType} = info;
let memberStateStr = "正常";
if (memberState == MEMBERSTATE.冻结管理员) memberStateStr = "冻结";
dataList.push({ dataList.push({
userId, userId,
memberState:changeEnumValue(MEMBERSTATE, memberState), memberState:memberStateStr,
loginId, loginId,
adminType, adminType:changeEnumValue(ADMINTYPE, adminType),
adminLv adminLv:changeEnumValue(ADMINLV, adminLv)
}); });
}); });
...@@ -64,6 +67,7 @@ export async function addAdmin({userId, form}) { ...@@ -64,6 +67,7 @@ export async function addAdmin({userId, form}) {
return sysTools.successResult(); return sysTools.successResult();
} }
export async function initAdmin() { export async function initAdmin() {
let userInfo = await findOnce(TABLEENUM.用户表, {loginId:'admin'}); let userInfo = await findOnce(TABLEENUM.用户表, {loginId:'admin'});
if (!userInfo || !userInfo.userId) { if (!userInfo || !userInfo.userId) {
...@@ -80,6 +84,7 @@ export async function initAdmin() { ...@@ -80,6 +84,7 @@ export async function initAdmin() {
console.log("初始化admin账号成功"); console.log("初始化admin账号成功");
} }
/** /**
* 修改密码 * 修改密码
* @param userId 登录的用户id * @param userId 登录的用户id
......
...@@ -362,7 +362,8 @@ export const Config = { ...@@ -362,7 +362,8 @@ export const Config = {
apiName:"通过审批", apiName:"通过审批",
subUrl:'/examine/adopt', subUrl:'/examine/adopt',
param:[ param:[
{key:"id", type:"String", desc:"待审核列表返回的用户id"} {key:"id", type:"String", desc:"待审核列表返回的用户id"},
{key:"session", type:"String", desc:"审批届次"},
], ],
bindBiz:examineBiz.adopt bindBiz:examineBiz.adopt
}, },
...@@ -615,6 +616,7 @@ export const Config = { ...@@ -615,6 +616,7 @@ export const Config = {
apiName:"删除管理员", apiName:"删除管理员",
subUrl:'/rightsmgmt/deleteadmin', subUrl:'/rightsmgmt/deleteadmin',
param:[ param:[
{key:"id", type:"String", desc:"列表返回的用户id"}
], ],
bindBiz:rightsMgmtBiz.deleteAdmin bindBiz:rightsMgmtBiz.deleteAdmin
}, },
......
...@@ -75,7 +75,34 @@ export const Config = { ...@@ -75,7 +75,34 @@ export const Config = {
], ],
bindBiz:orderBiz.confirmReceiptOut bindBiz:orderBiz.confirmReceiptOut
}, },
{
apiName:"上传发票",
subUrl:'/order/invoice/examine/upinvoice',
param:[
{key:"id", type:"String", desc:"订单id"},
{key:"invoiceUrl", type:"String", desc:"发票地址"},
],
bindBiz:orderBiz.upInvoice
},
{
apiName:"退回发票",
subUrl:'/order/invoice/examine/backinvoice',
param:[
{key:"id", type:"String", desc:"订单id"}
],
bindBiz:orderBiz.backInvoice
},
{
apiName:"发票管理-已开发票",
subUrl:'/order/invoice/examine/invoicedlist',
param:[
{key:"unitName", type:"String", desc:"单位名称"},
{key:"paymentType", type:"Number", desc:"会员类型"},
{key:"isPay", type:"Number", desc:"是否支付"},
{key:"pageNumber", type:"Number", desc:"当前页"},
],
bindBiz:orderBiz.invoicedList
},
], ],
"会员个人页":[ "会员个人页":[
{ {
......
...@@ -18,7 +18,7 @@ import * as asyncHandler from 'express-async-handler'; ...@@ -18,7 +18,7 @@ import * as asyncHandler from 'express-async-handler';
import { payCallback } from "../biz/member/cost"; import { payCallback } from "../biz/member/cost";
import { checkUser, notCheck } from "../middleware/user"; import { checkUser, notCheck } from "../middleware/user";
const Look = true;//true更新文档 const Look = false;//true更新文档
export async function setRouter(httpServer){ export async function setRouter(httpServer){
if (Look) { if (Look) {
......
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