前端:
onLoad: function (options) {
var scene = JSON.stringify(decodeURIComponent(options))
console.log('我是options: ' + scene)
console.log(options.scene)
},
后端
params.put("scene", "c=" + cardOpenId);
params.put("width", 430);
HttpPost request = new HttpPost(postUrl.trim());
request.setHeader("Content-Type", "application/json");
request.setEntity(new ByteArrayEntity(JSON.toJSON(params).toString().getBytes()));
HttpClient httpClient = HttpClients.createDefault();
HttpResponse httpResponse = httpClient.execute(request);
请问前端如何获取小程序码中附带的参数值呢?
我使用postman生成的小程序码 使用工具进行调试也获取不到参数!