diff --git a/controller/userController.js b/controller/userController.js index b14bd52..e69432f 100644 --- a/controller/userController.js +++ b/controller/userController.js @@ -123,7 +123,7 @@ userController.prototype.getStu = async(ctx, next) =>{ return status.paramError('type'); } let page = ctx.header.page ? Number(ctx.header.page):ctx.header.page; - let pageno = ctx.header.pageno; + let pageno = ctx.header.pageno ? Number(ctx.header.pageno):ctx.header.pageno; let stu = await userService.getStu(stuType,page,pageno); return stu } catch (error) { diff --git a/routes/users.js b/routes/users.js index 8b3c182..44a23f1 100644 --- a/routes/users.js +++ b/routes/users.js @@ -116,7 +116,7 @@ router.post('/encryptionToken',async (ctx, next) => { try{ let body = ctx.request.body; - let inspectMediaChannel = await inspectMediaChannelKey(body.appID,body.appCertificate,body.channel,body.uid) + let inspectMediaChannel = await inspectMediaChannelKey(body.appId,body.appCertificate,body.channel,body.uid) ctx.response.status= 200; ctx.response.body= inspectMediaChannel }catch(e){ @@ -133,7 +133,7 @@ router.post('/Recording',async (ctx, next) => { try{ let body = ctx.request.body; console.log() - let Recording = await shellUtil.Recording(body.appID,body.uid,body.channel,body.channelKey) + let Recording = await shellUtil.Recording(body.appId,body.uid,body.channel,body.channelKey) ctx.response.status= 200; ctx.response.body= {msg:Recording}; }catch(e){