shihuojian commited on
Commit
e86f384
·
1 Parent(s): 35f6fb4

update basei

Browse files
ndcc/server/lib/basic.js CHANGED
@@ -110,7 +110,7 @@ module.exports = class{
110
  if(!_.isEmpty(thisPlugin)){
111
  let {result,statusMessage} = await this.server.inject({
112
  url:`/plugins/${thisPlugin._id}`,method:"POST",
113
- // allowInternals:true,
114
  headers:this.request.headers,
115
  plugins:{
116
  request:this.request
 
110
  if(!_.isEmpty(thisPlugin)){
111
  let {result,statusMessage} = await this.server.inject({
112
  url:`/plugins/${thisPlugin._id}`,method:"POST",
113
+ allowInternals:true,
114
  headers:this.request.headers,
115
  plugins:{
116
  request:this.request
src/pages/api/plugins/Zi34RUP5T5YuGLrJ.js CHANGED
@@ -3,7 +3,8 @@
3
  export default async (req)=>{
4
  const {send,reply,error,isGet,db,cookie,event,socket} = await req.ctx();
5
  try{
6
- send('await db('test').findOne()')
 
7
  }catch (e){
8
  error(e)
9
  }
 
3
  export default async (req)=>{
4
  const {send,reply,error,isGet,db,cookie,event,socket} = await req.ctx();
5
  try{
6
+ console.log('123123')
7
+ send(await db('test').findOne())
8
  }catch (e){
9
  error(e)
10
  }