摘要: 混入(mixin)提供了一种非常灵活的方式,来分发 Vue 组件中的可复用功能。一个混入对象可以包含任意组件选项(如data、methods、mounted、filters等等)。 一、注册使用 1、在main.js中全局配置 import mixin from './mixins' Vue.mix 阅读全文
posted @ 2024-08-22 09:58 样子2018 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 一、注册过滤器 1、在main.js中配置全局 import { formatTime } from './filter' Vue.filter('formatTime', formatTime); 2、在组件中注册 二、使用 <view class="text-area"> <text class 阅读全文
posted @ 2024-08-22 09:40 样子2018 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 一、代码示例 /** * 生成cos签名 * @param string $httpURI 你的url地址,如:https://xxxx.com/123/23/test.png * @param string $expires 有效时间 分钟 * @param string $headerList 阅读全文
posted @ 2024-07-27 16:29 样子2018 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 一、示例 function getDistance(lat1, lng1, lat2, lng2) { let EARTH_RADIUS = 6378.137; // 地球半径 let radLat1 = lat1 * Math.PI / 180.0; //lat1 * Math.PI / 180. 阅读全文
posted @ 2024-07-27 16:17 样子2018 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 一、效果图 二、代码示例 qianming.js export const qianming = { data() { return { windowWidth: 0, pixelRatio: 0, context: null, points: [], oldPoints: [], qm_width 阅读全文
posted @ 2024-07-27 15:51 样子2018 阅读(4) 评论(0) 推荐(0) 编辑
摘要: 一、文档 https://uniapp.dcloud.net.cn/api/plugins/universal-links.html#%E8%83%8C%E6%99%AF%E4%BB%8B%E7%BB%8D 二、配置 1、登录苹果开发者中心找到对应的APPID,配置Associated Domain 阅读全文
posted @ 2024-05-20 09:56 样子2018 阅读(449) 评论(0) 推荐(0) 编辑
摘要: 一、开发文档 https://uniapp.dcloud.net.cn/tutorial/app-oauth-apple.html 二、示例 appleLogin() { uni.login({ provider: 'apple', success: function(loginRes) { con 阅读全文
posted @ 2024-05-20 09:22 样子2018 阅读(94) 评论(0) 推荐(0) 编辑
摘要: 一、explain语句 EXPLAIN [EXTENDED] SELECT select_options 二、字段分析 1、id select识别符。这是select的查询序列号,id的值越大优先级别越高,越先被执行,如果id相同,执行顺序右上至下 2、select_type select_type 阅读全文
posted @ 2024-05-15 11:28 样子2018 阅读(21) 评论(0) 推荐(0) 编辑
摘要: 一、效果图 二、代码示例 <!doctype html> <html lang="zh"> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <meta http-equiv="X-UA-Comp 阅读全文
posted @ 2024-04-09 16:07 样子2018 阅读(247) 评论(0) 推荐(0) 编辑
摘要: 一、配置 1、uni-push1.0文档 https://uniapp.dcloud.net.cn/unipush-v1.html 2、服务端推送文档 https://docs.getui.com/getui/server/rest_v2/push/ 二、客户端 1、App.vue import p 阅读全文
posted @ 2024-03-23 10:06 样子2018 阅读(274) 评论(0) 推荐(0) 编辑