
uniapp
lqk11
自信
展开
-
uniapp,vue,uni.request()实现同步返回数据处理,继续执行后面的数据
App.vue//应用载入onLaunch: function(option) {let $this = this;$this.globalMain();methods: { globalMain: async function(apiServer, params = {}) { let $this = this; let Time = new Date(); let timestemp = Time.getTime(); let getUrl = $this.$base_url原创 2020-06-16 17:52:39 · 3668 阅读 · 0 评论 -
uniapp vue JS php 跨域访问解决方法
header("Access-Control-Allow-Origin: *" );//设置允许的请求方法,可以用*表示所有,header("Access-Control-Allow-Methods: *");header('Access-Control-Allow-Credentials:true');header("Access-Control-Allow-Headers:Content-Type,Client-Token");header("Access-Control-Expose-He.原创 2020-06-11 09:46:18 · 665 阅读 · 0 评论 -
uniapp 选择元素,操作元素属性
const query = uni.createSelectorQuery().in(this); query.select('#userList_1').boundingClientRect(data => { console.log("得到布局位置信息" + JSON.stringify(data)); console.log("节点离页面顶部的距离为" + da...原创 2020-05-26 10:28:36 · 8912 阅读 · 1 评论