租房掌柜微信小程序Api以及小程序前端模板
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

26 lines
570 B

const app = getApp();
var netUtil = require("../../utils/requestUtil.js"); //require引入
Page({
data: {
data: []
},
onLoad: function() {
this.getSingle('about');
},
//获取数据列表
getSingle: function(ident) {
this.loading = true;
var self = this;
var url = app.globalData.requestUrl + 'index/single/index/' + ident;
return netUtil.sendGet(url)
.then((res) => {
console.log(res)
this.setData({
data: res.data.data
})
}).then(() => {
this.loading = false;
})
},
});