- 腾讯云一个域名怎样对应多个小程序?
多个小程序上传到同一个生产环境会不会有冲突?
2017-12-07 - 操作数据库出错,大神,我是小白能给详细的资料不
错误信息: RequestError {type: "mySql is not a function", message: "登录态已过期"} message:"登录态已过期" type:"mySql is not a function" 前端: testCgi: function () { util.showBusy('请求中...') var that = this qcloud.request({ url: `${config.service.host}/weapp/demo`, data:{ name:'Mickey' ,sex:'男' } ,login: false ,success (result) { util.showSuccess('请求成功完成') that.setData({ requestResult: JSON.stringify(result.data) }) console.log(result.data) }, fail (error) { util.showModel('请求失败', error) console.log('request fail', error) } }) } demo.js这样写: const {mySql} =require('../qcloud') module.exports=ctx=>{ var book={ id:3 ,name:'ecma6入门' ,price:99 } mySql('cBooks').insert(book) ctx.state.data={ msg:"Hello World" } }
2017-12-05