摘要: function dealImage(path, callback){ var img = new Image(); img.src = path; img.onload = function(){ //默认按比例压缩 var w = this.width, h = this.height; ... 阅读全文
posted @ 2018-09-01 18:48 JJRains 阅读(2971) 评论(0) 推荐(0) 编辑
摘要: function getAccessToken(id,secret){ return new Promise((resolve,reject)=>{ axios({ method:'get', url:`https://api.weixin.qq.com/cgi-bin/token?grant_type=client_c... 阅读全文
posted @ 2018-09-01 15:58 JJRains 阅读(18649) 评论(0) 推荐(0) 编辑
摘要: const SMSClient = require('@alicloud/sms-sdk') const accessKeyId = 'accesskeyid' const secretAccessKey = 'secretaccessKey' let smsClient = new SMSClie 阅读全文
posted @ 2018-09-01 11:35 JJRains 阅读(542) 评论(0) 推荐(0) 编辑
摘要: const axios = require("axios") const fs = require("fs") const appId = 'appid' const secret = 'appsecret'let data = { scene: "参数", page: "小程序页面"}picUrl = `./upload/${data.scene}.png` axios({ metho... 阅读全文
posted @ 2018-09-01 11:13 JJRains 阅读(1078) 评论(0) 推荐(0) 编辑
摘要: 1、使用is 页面代码: <template name="msgItem"> <view> <text> {{index}}: {{msg}} </text> <text> Time: {{time}} </text> </view> </template> 使用 is 属性,声明需要的使用的模板, 阅读全文
posted @ 2018-08-30 21:17 JJRains 阅读(695) 评论(0) 推荐(0) 编辑