commit bf8dc07cb7f64f577b994378f25b6861a657bd06
Author: 山兮 <3208053815@qq.com>
Date: Thu Mar 21 13:53:51 2024 +0800
初始化项目
diff --git a/.buildpath b/.buildpath
new file mode 100644
index 0000000..8bcb4b5
--- /dev/null
+++ b/.buildpath
@@ -0,0 +1,5 @@
+
+
因本产品首页需根据用户定位信息来推荐附近的热门店铺,因此进入APP首页将会弹出获取定位授权。
你可阅读《服务协议》和《隐私政策》了解详细信息。如果你同意,请点击下面按钮开始接受我们的服务。",
+ "buttonAccept" : "同意并接受",
+ "buttonRefuse" : "暂不同意",
+ "hrefLoader" : "system|default",
+ "backToExit" : "true",
+ "second" : {
+ "title" : "确认提示",
+ "message" : " 进入应用前,你需先同意《服务协议》和《隐私政策》,否则将退出应用。",
+ "buttonAccept" : "同意并继续",
+ "buttonRefuse" : "退出应用"
+ },
+ "disagreeMode" : {
+ "support" : false,
+ "loadNativePlugins" : false,
+ "visitorEntry" : false,
+ "showAlways" : false
+ },
+ "styles" : {
+ "backgroundColor" : "#ffffff",
+ "borderRadius" : "15px",
+ "title" : {
+ "color" : "#000000"
+ },
+ "buttonAccept" : {
+ "color" : "#F3A664"
+ },
+ "buttonRefuse" : {
+ "color" : "#009254"
+ },
+ "buttonVisitor" : {
+ "color" : "#6A5ACD"
+ }
+ }
+}
diff --git a/api/index.js b/api/index.js
new file mode 100644
index 0000000..fa700f2
--- /dev/null
+++ b/api/index.js
@@ -0,0 +1,9 @@
+const files = require.context('./modules', false, /\.js$/)
+const modules = {}
+files.keys().forEach(key => {
+ modules[key.replace(/(\.\/|\.js)/g, '')] = files(key).default
+})
+
+export default{
+ ...modules
+}
\ No newline at end of file
diff --git a/api/modules/admin.js b/api/modules/admin.js
new file mode 100644
index 0000000..71449e6
--- /dev/null
+++ b/api/modules/admin.js
@@ -0,0 +1,57 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 首页
+ index(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/index", param)
+ },
+ // 拨打客户电话
+ getVirtualPhone(param) {
+ return req.post("mobilenode/app/IndexAdminOrder/getVirtualPhone", param)
+ },
+ // 编辑通知状态
+ noticeUpdate(param) {
+ return req.post("mobilenode/app/IndexAdminOrder/noticeUpdate", param)
+ },
+ // 订单列表
+ orderList(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/orderList", param)
+ },
+ // 订单详情
+ orderInfo(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/orderInfo", param)
+ },
+ // 修改订单状态
+ adminUpdateOrder(param) {
+ return req.post("mobilenode/app/IndexAdminOrder/adminUpdateOrder", param)
+ },
+ // 退款列表
+ refundOrderList(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/refundOrderList", param)
+ },
+ // 退款详情
+ refundOrderInfo(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/refundOrderInfo", param)
+ },
+ // 同意退款
+ passRefund(param) {
+ return req.post("mobilenode/app/IndexAdminOrder/passRefund", param)
+ },
+ // 拒绝退款
+ noPassRefund(param) {
+ return req.post("mobilenode/app/IndexAdminOrder/noPassRefund", param)
+ },
+ // 代理商列表
+ adminSelect(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/adminSelect", param)
+ },
+ // 更换技-师
+ orderChangeCoach(param) {
+ return req.post("mobilenode/app/IndexAdminOrder/orderChangeCoach", param)
+ },
+ // 转派技-师列表
+ orderChangeCoachList(param) {
+ return req.get("mobilenode/app/IndexAdminOrder/orderChangeCoachList", param)
+ },
+}
diff --git a/api/modules/agent.js b/api/modules/agent.js
new file mode 100644
index 0000000..2ff929e
--- /dev/null
+++ b/api/modules/agent.js
@@ -0,0 +1,109 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 合作加盟
+ agentApply(param) {
+ return req.post("massage/app/IndexUser/agentApply", param)
+ },
+ //代理商详情
+ agentInfo(param) {
+ return req.get("massage/app/Index/agentInfo", param)
+ },
+ // 首页
+ index(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/index", param)
+ },
+ // 邀请海报
+ agentInviteQr(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/agentInviteQr", param)
+ },
+ //申请提现
+ applyWallet(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/applyWallet", param)
+ },
+ //提现记录
+ walletList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/walletList", param)
+ },
+ //账号设置
+ adminInfoData(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/adminInfoData", param)
+ },
+ // 门店下拉列表
+ storeSelect(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/storeSelect", param)
+ },
+ //技-师列表
+ coachList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/coachList", param)
+ },
+ //技-师详情
+ coachInfo(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/coachInfo", param)
+ },
+ //新增技-师
+ coachApply(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/coachApply", param)
+ },
+ //编辑技-师
+ coachDataUpdate(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/coachDataUpdate", param)
+ },
+ //技-师关联用户
+ coachUserList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/coachUserList", param)
+ },
+ //佣金列表
+ commList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/commList", param)
+ },
+ // 拨打客户电话
+ getVirtualPhone(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/getVirtualPhone", param)
+ },
+ // 编辑通知状态
+ noticeUpdate(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/noticeUpdate", param)
+ },
+ // 订单列表
+ orderList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/orderList", param)
+ },
+ // 订单详情
+ orderInfo(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/orderInfo", param)
+ },
+ // 修改订单状态
+ adminUpdateOrder(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/adminUpdateOrder", param)
+ },
+ // 退款列表
+ refundOrderList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/refundOrderList", param)
+ },
+ // 退款详情
+ refundOrderInfo(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/refundOrderInfo", param)
+ },
+ // 同意退款
+ passRefund(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/passRefund", param)
+ },
+ // 拒绝退款
+ noPassRefund(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/noPassRefund", param)
+ },
+ // 代理商下拉列表
+ adminSelect(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/adminSelect", param)
+ },
+ // 更换技-师
+ orderChangeCoach(param) {
+ return req.post("mobilenode/app/IndexAgentOrder/orderChangeCoach", param)
+ },
+ // 转派技-师列表
+ orderChangeCoachList(param) {
+ return req.get("mobilenode/app/IndexAgentOrder/orderChangeCoachList", param)
+ },
+}
diff --git a/api/modules/base.js b/api/modules/base.js
new file mode 100644
index 0000000..0a87613
--- /dev/null
+++ b/api/modules/base.js
@@ -0,0 +1,65 @@
+import {
+ req,
+ uploadFile
+} from '../../utils/req.js';
+export default {
+ // 小程序登录
+ login(param) {
+ return req.post("index/login", param)
+ },
+ // 公众号登录
+ webLogin(param) {
+ return req.post("index/webLogin", param)
+ },
+ // app微信登录
+ appLogin(param) {
+ return req.post("index/appLogin", param)
+ },
+ // app苹果登录
+ iosLogin(param) {
+ return req.post("index/iosLogin", param)
+ },
+ // app登录配置
+ getConfig(param) {
+ return req.get("index/getConfig", param)
+ },
+ // 获取配置
+ getWebConfig(param) {
+ return req.get("index/getWebConfig", param)
+ },
+ // 系统配置
+ configInfo(param) {
+ return req.get("massage/app/Index/configInfo", param)
+ },
+ // 获取地图定位
+ getMapInfo(param) {
+ return req.get("massage/app/Index/getMapInfo", param)
+ },
+ // 解析二维码
+ getWxCodeData(param) {
+ return req.get("card/app/getWxCodeData", param)
+ },
+ // base64ToImg
+ base64ToImg(param) {
+ return req.get("massage/app/IndexUser/base64ToImg", param)
+ },
+ // 上传文件
+ uploadFile(param) {
+ return uploadFile("admin/app/wx/uploadFile", param)
+ },
+ uploadFiles(querys, fn) {
+ return req.post('admin/admin/file/uploadFiles', querys, fn)
+ },
+ // 上传视频
+ uploadVideo(param) {
+ return uploadFile("admin/app/wx/uploadVideo", param)
+ },
+ // 获取城市
+ getCity(param) {
+ return req.get("massage/app/Index/getCity", param)
+ },
+ // 获取插件授权
+ plugAuth(param) {
+ return req.get("massage/app/Index/plugAuth", param)
+ },
+}
\ No newline at end of file
diff --git a/api/modules/channel.js b/api/modules/channel.js
new file mode 100644
index 0000000..1e3e5ee
--- /dev/null
+++ b/api/modules/channel.js
@@ -0,0 +1,37 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 渠道商下拉
+ channelCateSelect(param) {
+ return req.get("massage/app/IndexUser/channelCateSelect", param)
+ },
+ // 申请渠道商
+ applyChannel(param) {
+ return req.post("massage/app/IndexUser/applyChannel", param)
+ },
+ // 渠道商信息
+ channelInfo(param) {
+ return req.get("massage/app/IndexUser/channelInfo", param)
+ },
+ // 渠道商首页
+ index(param) {
+ return req.get("massage/app/IndexChannel/index", param)
+ },
+ // 渠道商二维码
+ channelQr(param) {
+ return req.get("massage/app/IndexChannel/channelQr", param)
+ },
+ // 订单列表
+ orderList(param) {
+ return req.get("massage/app/IndexChannel/orderList", param)
+ },
+ //申请提现
+ applyWallet(param) {
+ return req.post("massage/app/IndexChannel/applyWallet", param)
+ },
+ //提现记录
+ walletList(param) {
+ return req.get("massage/app/IndexChannel/walletList", param)
+ },
+}
diff --git a/api/modules/dynamic.js b/api/modules/dynamic.js
new file mode 100644
index 0000000..c53335c
--- /dev/null
+++ b/api/modules/dynamic.js
@@ -0,0 +1,82 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 动态列表
+ dynamicList(param) {
+ return req.get("dynamic/app/IndexDynamicList/dynamicList", param)
+ },
+ // 获取关注技-师的最新动态数量
+ getFollowData(param) {
+ return req.get("dynamic/app/IndexDynamicList/getFollowData", param)
+ },
+ // 关注技-师动态列表
+ followDynamicList(param) {
+ return req.get("dynamic/app/IndexDynamicList/followDynamicList", param)
+ },
+ // 动态详情
+ dynamicInfo(param) {
+ return req.get("dynamic/app/IndexDynamicList/dynamicInfo", param)
+ },
+ // 点赞或者取消点赞
+ thumbsAddOrCancek(param) {
+ return req.post("dynamic/app/IndexDynamicList/thumbsAddOrCancek", param)
+ },
+ // 我的关注
+ followCoachList(param) {
+ return req.get("dynamic/app/IndexDynamicList/followCoachList", param)
+ },
+ // 关注或者取消关注
+ followAddOrCancek(param) {
+ return req.post("dynamic/app/IndexDynamicList/followAddOrCancek", param)
+ },
+ // 评论列表
+ commentList(param) {
+ return req.get("dynamic/app/IndexDynamicList/commentList", param)
+ },
+ // 新增评论
+ commentAdd(param) {
+ return req.post("dynamic/app/IndexDynamicList/commentAdd", param)
+ },
+ // 删除评论
+ commentDel(param) {
+ return req.post("dynamic/app/IndexDynamicList/commentDel", param)
+ },
+ // --------- 技-师端
+ // 动态列表
+ coachDynamicList(param) {
+ return req.get("dynamic/app/IndexDynamicCoach/dynamicList", param)
+ },
+ // 动态详情
+ coachDynamicInfo(param) {
+ return req.get("dynamic/app/IndexDynamicCoach/dynamicInfo", param)
+ },
+ // 关注点赞消息详情
+ dynamicData(param) {
+ return req.get("dynamic/app/IndexDynamicCoach/dynamicData", param)
+ },
+ // 发布动态
+ dynamicAdd(param) {
+ return req.post("dynamic/app/IndexDynamicCoach/dynamicAdd", param)
+ },
+ // 编辑动态
+ dynamicUpdate(param) {
+ return req.post("dynamic/app/IndexDynamicCoach/dynamicUpdate", param)
+ },
+ // 删除动态
+ dynamicDel(param) {
+ return req.post("dynamic/app/IndexDynamicCoach/dynamicDel", param)
+ },
+ // 收获的赞
+ thumbsList(param) {
+ return req.get("dynamic/app/IndexDynamicCoach/thumbsList", param)
+ },
+ // 新增关注
+ followList(param) {
+ return req.get("dynamic/app/IndexDynamicCoach/followList", param)
+ },
+ // 收获的评论
+ coachCommentList(param) {
+ return req.get("dynamic/app/IndexDynamicCoach/commentList", param)
+ },
+}
diff --git a/api/modules/mine.js b/api/modules/mine.js
new file mode 100644
index 0000000..2ea7fcf
--- /dev/null
+++ b/api/modules/mine.js
@@ -0,0 +1,177 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 个人中心页面
+ index(param) {
+ return req.get("massage/app/IndexUser/index", param)
+ },
+ //技师端显示隐藏
+ isShowwx(param) {
+ return req.get("massage/CallBack/is_showwx", param)
+ },
+ // 认证技-师
+ attestationCoach(param) {
+ return req.post("massage/app/IndexUser/attestationCoach", param)
+ },
+ //申请分销商
+ applyReseller(param) {
+ return req.post("massage/app/IndexUser/applyReseller", param)
+ },
+ //分销商详情
+ resellerInfo(param) {
+ return req.get("massage/app/IndexUser/resellerInfo", param)
+ },
+ //我的收益
+ capCashInfo(param) {
+ return req.get("massage/app/IndexUser/userCashInfo", param)
+ },
+ //申请提现
+ applyWallet(param) {
+ return req.post("massage/app/IndexUser/applyWallet", param)
+ },
+ //提现记录
+ walletList(param) {
+ return req.get("massage/app/IndexUser/walletList", param)
+ },
+ //合伙人首页
+ partnerIndex(param) {
+ return req.get("massage/app/IndexReseller/partnerIndex", param)
+ },
+ //邀请的技-师
+ partnerCoachList(param) {
+ return req.get("massage/app/IndexReseller/partnerCoachList", param)
+ },
+ //我的团队
+ myTeam(param) {
+ return req.get("massage/app/IndexUser/myTeam", param)
+ },
+ //邀请用户
+ userCommQr(param) {
+ return req.get("massage/app/IndexUser/userCommQr", param)
+ },
+ //代理商绑定技-师
+ adminCoachQr(param) {
+ return req.get("massage/app/IndexUser/adminCoachQr", param)
+ },
+ //邀请技-师
+ resellerInvCoachQr(param) {
+ return req.get("massage/app/IndexReseller/resellerInvCoachQr", param)
+ },
+ //选择代理商
+ adminList(param) {
+ return req.get("massage/app/IndexReseller/adminList", param)
+ },
+ // 获取默认地址
+ getDefultAddress(param) {
+ return req.get("massage/app/IndexUser/getDefultAddress", param)
+ },
+ // 地址列表
+ addressList(param) {
+ return req.get("massage/app/IndexUser/addressList", param)
+ },
+ // 地址详情
+ addressInfo(param) {
+ return req.get("massage/app/IndexUser/addressInfo", param)
+ },
+ // 新增地址
+ addressAdd(param) {
+ return req.post("massage/app/IndexUser/addressAdd", param)
+ },
+ // 修改地址
+ addressUpdate(param) {
+ return req.post("massage/app/IndexUser/addressUpdate", param)
+ },
+ // 删除地址
+ addressDel(param) {
+ return req.post("massage/app/IndexUser/addressDel", param)
+ },
+ // 收藏技-师
+ coachCollectList(param) {
+ return req.get("massage/app/IndexUser/coachCollectList", param)
+ },
+ // 新增收藏
+ addCollect(param) {
+ return req.post("massage/app/IndexUser/addCollect", param)
+ },
+ // 删除收藏
+ delCollect(param) {
+ return req.post("massage/app/IndexUser/delCollect", param)
+ },
+ //卡券列表
+ userCouponList(param) {
+ return req.get("massage/app/IndexUser/userCouponList", param)
+ },
+ //删除卡券
+ couponDel(param) {
+ return req.post("massage/app/IndexUser/couponDel", param)
+ },
+ //卡券活动
+ couponAtvInfo(param) {
+ return req.post("massage/app/IndexUser/couponAtvInfo", param)
+ },
+ //卡券二维码
+ atvQr(param) {
+ return req.post("massage/app/IndexUser/atvQr", param)
+ },
+ //技-师分享储值套餐
+ coachBalanceQr(param) {
+ return req.get("massage/app/IndexCoach/coachBalanceQr", param)
+ },
+ //选择技-师
+ coachList(param) {
+ return req.get("massage/app/IndexBalance/coachList", param)
+ },
+ //储值充值卡列表
+ cardList(param) {
+ return req.get("massage/app/IndexBalance/cardList", param)
+ },
+ //充值余额(card_id)
+ payBalanceOrder(param) {
+ return req.post("massage/app/IndexBalance/payBalanceOrder", param)
+ },
+ //充值订单列表(时间筛选 start_time,end_time)
+ balaceOrder(param) {
+ return req.get("massage/app/IndexBalance/balaceOrder", param)
+ },
+ //消费明细
+ payWater(param) {
+ return req.get("massage/app/IndexBalance/payWater", param)
+ },
+ //佣金明细
+ commList(param) {
+ return req.get("massage/app/IndexUser/commList", param)
+ },
+ // 提交反馈
+ addFeedback(param) {
+ return req.post("massage/app/IndexCoach/addFeedback", param)
+ },
+ // 反馈记录
+ listFeedback(param) {
+ return req.get("massage/app/IndexCoach/listFeedback", param)
+ },
+ // 反馈详情
+ feedbackInfo(param) {
+ return req.get("massage/app/IndexCoach/feedbackInfo", param)
+ },
+ // 屏蔽列表
+ shieldCoachList(param) {
+ return req.get("massage/app/IndexUser/shieldCoachList", param)
+ },
+ // 新增屏蔽
+ shieldCoachAdd(param) {
+ return req.post("massage/app/IndexUser/shieldCoachAdd", param)
+ },
+ // 删除屏蔽
+ shieldCoachDel(param) {
+ return req.post("massage/app/IndexUser/shieldCoachDel", param)
+ },
+ // 绑定支付宝账号
+ bindAlipayNumber(param) {
+ return req.post("massage/app/IndexUser/bindAlipayNumber", param)
+ },
+ // 获取门店数据
+ getStoreSelect(param) {
+ return req.get("massage/app/IndexUser/getStoreSelect", param)
+ },
+}
\ No newline at end of file
diff --git a/api/modules/order.js b/api/modules/order.js
new file mode 100644
index 0000000..ea0aa39
--- /dev/null
+++ b/api/modules/order.js
@@ -0,0 +1,133 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 购物车
+ carInfo(param) {
+ return req.get("massage/app/Index/carInfo", param)
+ },
+ // 加入购物车
+ addCar(param) {
+ return req.post("massage/app/Index/addCar", param)
+ },
+ // 删除购物车数量
+ delCar(param) {
+ return req.post("massage/app/Index/delCar", param)
+ },
+ //清空购物车
+ delSomeCar(param) {
+ return req.post("massage/app/IndexGoods/delSomeCar", param)
+ },
+ //选择购物车商品
+ carUpdate(param) {
+ return req.post("massage/app/IndexGoods/carUpdate", param)
+ },
+ //获取是否能选择 公交/地铁
+ getIsBus(param) {
+ return req.get("massage/app/IndexOrder/getIsBus", param)
+ },
+ //下单选择时间
+ dayText(param) {
+ return req.get("massage/app/IndexOrder/dayText", param)
+ },
+ //下单选择时间(coach_id,day)
+ timeText(param) {
+ return req.get("massage/app/IndexOrder/timeText", param)
+ },
+ //获取升级订单信息
+ upOrderInfo(param) {
+ return req.post("massage/app/IndexOrder/upOrderInfo", param)
+ },
+ //升级服务下单
+ upOrderGoods(param) {
+ return req.post("massage/app/IndexOrder/upOrderGoods", param)
+ },
+ //校验加钟订单是否可下单
+ checkAddOrder(param) {
+ return req.post("massage/app/IndexOrder/checkAddOrder", param)
+ },
+ //获取下单信息(coach_id,有卡券就传 coupon_id)
+ payOrderInfo(param) {
+ return req.get("massage/app/IndexOrder/payOrderInfo", param)
+ },
+ //下单
+ payOrder(param) {
+ return req.post("massage/app/IndexOrder/payOrder", param)
+ },
+ //可用卡券
+ couponList(param) {
+ return req.get("massage/app/IndexOrder/couponList", param)
+ },
+ //订单列表
+ orderList(param) {
+ return req.get("massage/app/IndexOrder/orderList", param)
+ },
+ //根据主订单查询加钟订单列表
+ getAddClockOrder(param) {
+ return req.get("massage/app/IndexOrder/getAddClockOrder", param)
+ },
+ //订单详情
+ orderInfo(param) {
+ return req.get("massage/app/IndexOrder/orderInfo", param)
+ },
+ // 技师已到达
+ userSureArrivalOrder(param) {
+ return req.post("massage/app/IndexOrder/userSureArrival", param)
+ },
+ // 升级订单记录
+ orderUpRecord(param) {
+ return req.get("massage/app/IndexOrder/orderUpRecord", param)
+ },
+ // 拨打技-师电话
+ getVirtualPhone(param) {
+ return req.get("massage/app/IndexUser/getVirtualPhone", param)
+ },
+ //刷新二维码
+ refreshQr(param) {
+ return req.post("massage/app/IndexOrder/refreshQr", param)
+ },
+ //取消订单
+ cancelOrder(param) {
+ return req.post("massage/app/IndexOrder/cancelOrder", param)
+ },
+ //删除订单
+ delOrder(param) {
+ return req.post("massage/app/IndexOrder/delOrder", param)
+ },
+ //确认完成订单
+ userSignOrder(param) {
+ return req.post("massage/app/IndexOrder/userSignOrder", param)
+ },
+ //重新支付
+ rePayOrder(param) {
+ return req.post("massage/app/IndexOrder/rePayOrder", param)
+ },
+ //申请退款
+ applyOrder(param) {
+ return req.post("massage/app/IndexOrder/applyOrder", param)
+ },
+ //再来一单
+ onceMoreOrder(param) {
+ return req.post("massage/app/Index/onceMoreOrder", param)
+ },
+ //添加评价(order_id,text,star)
+ addComment(param) {
+ return req.post("massage/app/IndexOrder/addComment", param)
+ },
+ //标签列表
+ lableList(param) {
+ return req.get("massage/app/IndexOrder/lableList", param)
+ },
+ //我的售后
+ refundOrderList(param) {
+ return req.get("massage/app/IndexOrder/refundOrderList", param)
+ },
+ //售后详情
+ refundOrderInfo(param) {
+ return req.get("massage/app/IndexOrder/refundOrderInfo", param)
+ },
+ //取消退款
+ cancelRefundOrder(param) {
+ return req.post("massage/app/IndexOrder/cancelRefundOrder", param)
+ },
+}
\ No newline at end of file
diff --git a/api/modules/salesman.js b/api/modules/salesman.js
new file mode 100644
index 0000000..98c06e9
--- /dev/null
+++ b/api/modules/salesman.js
@@ -0,0 +1,37 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 申请业务员
+ applySalesman(param) {
+ return req.post("massage/app/IndexUser/applySalesman", param)
+ },
+ // 业务员信息
+ salesmanInfo(param) {
+ return req.get("massage/app/IndexUser/salesmanInfo", param)
+ },
+ // 业务员首页
+ index(param) {
+ return req.get("massage/app/IndexSalesman/index", param)
+ },
+ // 业务员二维码
+ salesmanQr(param) {
+ return req.get("massage/app/IndexSalesman/salesmanQr", param)
+ },
+ // 申请提现
+ applyWallet(param) {
+ return req.post("massage/app/IndexSalesman/applyWallet", param)
+ },
+ // 提现记录
+ walletList(param) {
+ return req.get("massage/app/IndexSalesman/walletList", param)
+ },
+ // 渠道明细
+ salesmanChannelCash(param) {
+ return req.get("massage/app/IndexSalesman/salesmanChannelCash", param)
+ },
+ // 业务员渠道商明细详情
+ salesmanChannelOrderList(param) {
+ return req.get("massage/app/IndexSalesman/salesmanChannelOrderList", param)
+ }
+}
\ No newline at end of file
diff --git a/api/modules/service.js b/api/modules/service.js
new file mode 100644
index 0000000..90468e0
--- /dev/null
+++ b/api/modules/service.js
@@ -0,0 +1,65 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 首页轮播图
+ index(param) {
+ return req.get("massage/app/Index/index", param)
+ },
+ //文章详情
+ articleInfo(param) {
+ return req.get("massage/app/IndexArticle/articleInfo", param)
+ },
+ //文章详情-提交表单
+ subArticleForm(param) {
+ return req.post("massage/app/IndexArticle/subArticleForm", param)
+ },
+ // 服务分类列表
+ serviceCateList(param) {
+ return req.get("massage/app/Index/serviceCateList", param)
+ },
+ // 服务列表
+ serviceList(param) {
+ return req.get("massage/app/Index/serviceList", param)
+ },
+ // 服务详情
+ serviceInfo(param) {
+ return req.get("massage/app/Index/serviceInfo", param)
+ },
+ // 地图找人
+ mapCoachList(param) {
+ return req.get("map/app/Index/coachList", param)
+ },
+ // 服务技-师列表无筛选项(ser_id,服务id,lat,lng)
+ typeServiceCoachList(param) {
+ return req.get("massage/app/Index/typeServiceCoachList", param)
+ },
+ // 服务技-师列表(ser_id,服务id,lat,lng,type)
+ serviceCoachList(param) {
+ return req.get("massage/app/Index/serviceCoachList", param)
+ },
+ // 技-师服务列表(coach_id)
+ coachServiceList(param) {
+ return req.get("massage/app/Index/coachServiceList", param)
+ },
+ // 技-师评价
+ commentList(param) {
+ return req.get("massage/app/Index/commentList", param)
+ },
+ // 技-师信息
+ coachInfo(param) {
+ return req.get("massage/app/Index/coachInfo", param)
+ },
+ //优惠券列表
+ couponList(param) {
+ return req.get("massage/app/Index/couponList", param)
+ },
+ //领取优惠券
+ userGetCoupon(param) {
+ return req.post("massage/app/Index/userGetCoupon", param)
+ },
+ //获取可升级的服务
+ getUpOrderGoods(param) {
+ return req.get("massage/app/IndexOrder/getUpOrderGoods", param)
+ },
+}
diff --git a/api/modules/shopstore.js b/api/modules/shopstore.js
new file mode 100644
index 0000000..cbc0ef6
--- /dev/null
+++ b/api/modules/shopstore.js
@@ -0,0 +1,21 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 门店列表
+ storeList(param) {
+ return req.get("store/app/IndexStore/storeList", param)
+ },
+ // 门店详情
+ storeInfo(param) {
+ return req.get("store/app/IndexStore/storeInfo", param)
+ },
+ // 门店服务列表
+ storeServiceList(param) {
+ return req.get("store/app/IndexStore/storeServiceList", param)
+ },
+ // 门店评价列表
+ commentList(param) {
+ return req.get("store/app/IndexStore/commentList", param)
+ }
+}
diff --git a/api/modules/technician.js b/api/modules/technician.js
new file mode 100644
index 0000000..b46d7e7
--- /dev/null
+++ b/api/modules/technician.js
@@ -0,0 +1,185 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 申请技-师
+ coachApply(param) {
+ return req.post("massage/app/IndexUser/coachApply", param)
+ },
+ // 获取是否开启合同
+ getFddStatus(param) {
+ return req.get("massage/app/IndexCoach/getFddStatus", param)
+ },
+ // 获取是否已签合同
+ getFddRecord(param) {
+ return req.get("massage/app/IndexCoach/getFddRecord", param)
+ },
+ // 获取发大大实名认证地址
+ getPersonVerifyUrl(param) {
+ return req.get("massage/app/IndexCoach/getPersonVerifyUrl", param)
+ },
+ // 获取用户实名注册信息
+ getAttestationInfo(param) {
+ return req.get("massage/app/IndexCoach/getAttestationInfo", param)
+ },
+ // 签署合同
+ Extsign(param) {
+ return req.post("massage/app/IndexCoach/Extsign", param)
+ },
+ // 技-师信息
+ coachInfo(param) {
+ return req.get("massage/app/IndexUser/coachInfo", param)
+ },
+ // 编辑技-师
+ coachUpdate(param) {
+ return req.post("massage/app/IndexCoach/coachUpdate", param)
+ },
+ // 编辑技-师
+ coachUpdateV2(param) {
+ return req.post("massage/app/IndexCoach/coachUpdateV2", param)
+ },
+ // 技-师等级
+ coachLevel(param) {
+ return req.get("massage/app/IndexCoach/coachLevel", param)
+ },
+ // 技-师首页
+ coachIndex(param) {
+ return req.get("massage/app/IndexCoach/coachIndex", param)
+ },
+ // 技-师报警
+ police(param) {
+ return req.post("massage/app/IndexCoach/police", param)
+ },
+ // 订单列表
+ orderList(param) {
+ return req.get("massage/app/IndexCoach/orderList", param)
+ },
+ // 订单详情
+ orderInfo(param) {
+ return req.get("massage/app/IndexCoach/orderInfo", param)
+ },
+ // 修改订单状态(type,order_id)
+ updateOrder(param) {
+ return req.post("massage/app/IndexCoach/updateOrder", param)
+ },
+ // 客户爽约
+ breakThePromiseOrder(param) {
+ return req.post("massage/app/IndexCoach/breakThePromise", param)
+ },
+ // 拨打客户电话
+ getVirtualPhone(param) {
+ return req.post("massage/app/IndexCoach/getVirtualPhone", param)
+ },
+ //佣金信息
+ capCashInfo(param) {
+ return req.get("massage/app/IndexCoach/capCashInfo", param)
+ },
+ //佣金信息(车费)
+ capCashInfoCar(param) {
+ return req.get("massage/app/IndexCoach/capCashInfoCar", param)
+ },
+ //申请提现 (apply_price,text,type:1服务费提现,2车费提现)
+ applyWallet(param) {
+ return req.post("massage/app/IndexCoach/applyWallet", param)
+ },
+ //提现记录
+ capCashList(param) {
+ return req.get("massage/app/IndexCoach/capCashList", param)
+ },
+ //时间管理回显
+ timeConfig(param) {
+ return req.get("massage/app/IndexCoach/timeConfig", param)
+ },
+ //时间管理设置
+ setTimeConfig(param) {
+ return req.post("massage/app/IndexCoach/timeConfig", param)
+ },
+ //根据接单时间获取时间节点
+ getTime(param) {
+ return req.get("massage/app/IndexCoach/getTime", param)
+ },
+ //根据接单时间获取时间节点
+ getOrderNum(param) {
+ return req.get("massage/app/IndexCoach/getOrderNum", param)
+ },
+ //物料商城-商品列表
+ goodsList(param) {
+ return req.get("massage/app/IndexCoach/goodsList", param)
+ },
+ //物料商城-分类列表
+ carteList(param) {
+ return req.get("massage/app/IndexCoach/carteList", param)
+ },
+ //物料商城-商品详情
+ goodsInfo(param) {
+ return req.get("massage/app/IndexCoach/goodsInfo", param)
+ },
+ //车费明细列表
+ carMoneyList(param) {
+ return req.get("massage/app/IndexCoach/carMoneyList", param)
+ },
+ //差评申诉 订单列表
+ appealOrder(param) {
+ return req.get("massage/app/IndexCoach/appealOrder", param)
+ },
+ //差评申诉 提交申诉
+ addAppeal(param) {
+ return req.post("massage/app/IndexCoach/addAppeal", param)
+ },
+ //差评申诉 申诉记录列表
+ appealList(param) {
+ return req.get("massage/app/IndexCoach/appealList", param)
+ },
+ //标签列表
+ labelList(param) {
+ return req.get("massage/app/IndexCoach/labelList", param)
+ },
+ //添加用户评价
+ userLabelAdd(param) {
+ return req.post("massage/app/IndexCoach/userLabelAdd", param)
+ },
+ //获取用户当前标签
+ userLabelList(param) {
+ return req.get("massage/app/IndexCoach/userLabelList", param)
+ },
+ //储值返佣列表
+ balanceCommissionList(param) {
+ return req.get("massage/app/IndexCoach/balanceCommissionList", param)
+ },
+ //储值返佣金额统计
+ balanceCommissionData(param) {
+ return req.get("massage/app/IndexCoach/balanceCommissionData", param)
+ },
+ //分成明细
+ coachCommissionList(param) {
+ return req.get("massage/app/IndexCoach/coachCommissionList", param)
+ },
+ //分成明细金额统计
+ coachCommissionData(param) {
+ return req.get("massage/app/IndexCoach/coachCommissionData", param)
+ },
+ //收益详情
+ coachCommissionInfo(param) {
+ return req.get("massage/app/IndexCoach/coachCommissionInfo", param)
+ },
+ //拉黑用户
+ shieldUserAdd(param) {
+ return req.post("massage/app/IndexCoach/shieldUserAdd", param)
+ },
+ //移除拉黑用户
+ shieldUserDel(param) {
+ return req.post("massage/app/IndexCoach/shieldUserDel", param)
+ },
+ //拉黑用户列表
+ shieldCoachList(param) {
+ return req.get("massage/app/IndexCoach/shieldCoachList", param)
+ },
+ // 订单服务录音
+ recordingAdd(param) {
+ return req.post("recording/app/Recording/recordingAdd", param)
+ },
+ // 修改技师白天夜间免费出行距离
+ updateCoachRidingForfree(param) {
+ return req.post("massage/app/IndexCoach/updateCoachRidingForfree", param)
+ },
+}
\ No newline at end of file
diff --git a/api/modules/user.js b/api/modules/user.js
new file mode 100644
index 0000000..a6d93c8
--- /dev/null
+++ b/api/modules/user.js
@@ -0,0 +1,33 @@
+import {
+ req
+} from '../../utils/req.js';
+export default {
+ // 用户信息
+ userInfo(param) {
+ return req.get("massage/app/IndexUser/userInfo", param)
+ },
+ // 更新用户信息
+ userUpdate(param) {
+ return req.post("massage/app/IndexUser/userUpdate", param)
+ },
+ // 绑定渠道商
+ bindChannel(param) {
+ return req.post("massage/app/IndexUser/bindChannel", param)
+ },
+ // 注销用户
+ delUserInfo(param) {
+ return req.post("/massage/app/IndexUser/delUserInfo", param)
+ },
+ // 获取手机号
+ reportPhone(param) {
+ return req.post("massage/app/IndexUser/reportPhone", param)
+ },
+ // 验证码
+ sendShortMsg(param) {
+ return req.post("massage/app/IndexUser/sendShortMsg", param)
+ },
+ // 绑定手机号
+ bindUserPhone(param) {
+ return req.post("massage/app/IndexUser/bindUserPhone", param)
+ }
+}
diff --git a/components/abnor.vue b/components/abnor.vue
new file mode 100644
index 0000000..23675fd
--- /dev/null
+++ b/components/abnor.vue
@@ -0,0 +1,322 @@
+
+
' + config.highlight(arguments[2], "') + ""; + }) + for (var len = this.data.length; this._i < len; this._i++) + this._state(this.data[this._i]); + if (this._state == this.Text) this.setText(); + while (this._STACK.length) + this.popNode(this._STACK.pop()); + // #ifdef MP-BAIDU || MP-TOUTIAO + const inlineTags = config.makeMap( + "abbr,b,big,code,del,em,font,i,ins,label,mark,q,s,small,span,strong,sub,sup,u") + // 将顶层标签的一些样式提取出来给 rich-text + const setContain = function(nodes) { + for (var element of nodes) { + if (element.type == "text") + continue; + if (!element.c) { + var res = ""; + var style = element.attrs.style; + var reg = /float[^;]+(?![\s\S]*?float)/i; + if (reg.test(style)) res += reg.exec(style)[0]; + reg = /margin[^;]+/gi; + if (reg.test(style)) res += (';' + style.match(reg).join(';')); + reg = /display\s*:\s*([^;]*)(?![\s\S]*?display)/i; + if (reg.test(style) && reg.exec(style)[1] != "flex") res += (';' + reg.exec(style)[0]); + else if (inlineTags[element.name]) res += ";display:inline"; + else res += (";display:" + (element.name == 'img' ? 'inline-block' : 'block')); + reg = /flex[^;]*:[^;]+/gi; + if (reg.test(style)) res += (';' + style.match(reg).join(';')); + reg = /[^;\s]*width[^;]+/gi; + if (reg.test(style)) res += (';' + style.match(reg).join(';')); + element.attrs.containStyle = res; + if (/[^-]width[^pev;]+/.test(";" + style)) + element.attrs.style += ";width:100%"; + let addMargin = ""; + if (/margin\s*:/.test(style)) addMargin = ';margin:0'; + else if (/margin-top/.test(style)) addMargin = ';margin-top:0'; + else if (/margin-bottom/.test(style)) addMargin = ';margin-bottom:0'; + element.attrs.style = (element.attrs.style || '').replace(/margin[^;]*/gi, ""); + element.attrs.style += addMargin; + } else setContain(element.children); + } + }; + setContain(this.DOM); + // #endif + if (this.DOM.length) this.DOM[0].PoweredBy = "Parser"; + // console.log(this.DOM) + if (this.cb) + this.cb(this.DOM) + else return this.DOM; + }; + // 设置属性 + setAttr() { + if (config.trustAttrs[this._attrName]) + this._attrs[this._attrName] = (this._attrValue ? this._attrValue : (this._attrName == "src" ? "" : + "true")); + this._attrValue = ''; + while (isBlankChar(this.data[this._i])) this._i++; + if (this.checkClose()) this.setNode(); + else this._state = this.AttrName; + }; + // 设置文本节点 + setText() { + var text = this.getSelection(); + if (text) { + if (!this._whiteSpace) { + // 移除空白符 + var flag = false, + has = false, + pos; + for (var i = 0; i < text.length; i++) { + if (isBlankChar(text[i])) { + if (!flag) { + pos = i; + flag = true; + } + } else { + has = true; + if (flag) { + if (i - pos > 1) text = text.substring(0, pos) + ' ' + text.substring(i); + i = pos; + flag = false; + } + } + } + if (flag) text = text.substring(0, pos) + ' '; + if (!text || !has) return; + } + // 检查实体 + // #ifdef MP-BAIDU || MP-ALIPAY || MP-TOUTIAO + var entities = { + lt: "<", + gt: ">", + amp: "&", + quot: '"', + apos: "'", + nbsp: "\u00A0", + ensp: "\u2002", + emsp: "\u2003", + ndash: "–", + mdash: "—", + middot: "·", + lsquo: "‘", + rsquo: "’", + ldquo: "“", + rdquo: "”", + bull: "•", + hellip: "…", + permil: "‰", + copy: "©", + reg: "®", + trade: "™", + times: "×", + divide: "÷", + cent: "¢", + pound: "£", + yen: "¥", + euro: "€", + sect: "§" + }; + // #endif + var i = text.indexOf('&'), + j, decode; + while (i != -1 && i < text.length) { + j = text.indexOf(';', i); + if (j - i >= 2 && j - i <= 7) { + var entity = text.substring(i + 1, j); + // #ifdef MP-WEIXIN || MP-QQ || APP-PLUS + if (!entity.includes("sp") && !entity.includes("lt") && !entity.includes("gt")) { + decode = true + break; + } + // #endif + // #ifdef MP-BAIDU || MP-ALIPAY || MP-TOUTIAO + if (entities[entity]) text = text.substring(0, i) + entities[entity] + text.substring(j + 1); + // #endif + } + i = text.indexOf('&', i + 1); + } + var slibings = this._STACK.length ? this._STACK[this._STACK.length - 1].children : this.DOM; + if (slibings.length && slibings[slibings.length - 1].type == "text") { + slibings[slibings.length - 1].text += text; + if (decode) slibings[slibings.length - 1].decode = true; + } else + slibings.push({ + type: "text", + text, + decode + }) + } + }; + // 设置元素节点 + setNode() { + var slibings = this._STACK.length ? this._STACK[this._STACK.length - 1].children : this.DOM; + var node = { + name: this._tagName.toLowerCase(), + attrs: this._attrs + } + config.LabelAttrsHandler(node, this); + this._attrs = {}; + if (this.data[this._i] == '>') { + if (!config.selfClosingTags[this._tagName]) { + if (config.ignoreTags[node.name]) { + var j = this._i; + // 处理要被移除的标签 + while (this._i < this.data.length) { + this._i = this.data.indexOf("", this._i); + if (this._i == -1) return this._i = this.data.length; + this._i += 2; + this._sectionStart = this._i; + while (!isBlankChar(this.data[this._i]) && this.data[this._i] != '>' && this.data[this + ._i] != '/') this._i++; + if (this.data.substring(this._sectionStart, this._i).toLowerCase() == node.name) { + this._i = this.data.indexOf('>', this._i); + if (this._i == -1) this._i = this.data.length; + else this._sectionStart = this._i + 1; + this._state = this.Text; + // 处理svg + if (node.name == "svg") { + var src = this.data.substring(j, this._i + 1); + if (!node.attrs.xmlns) src = " xmlns=\"http://www.w3.org/2000/svg\"" + src; + this._i = j; + while (this.data[j] != '<') j--; + src = this.data.substring(j, this._i) + src; + this._i = this._sectionStart - 1; + node.name = "img"; + node.attrs = { + src: "data:image/svg+xml;utf8," + src.replace(/#/g, "%23"), + ignore: "true" + } + slibings.push(node); + } + break; + } + } + return; + } else this._STACK.push(node); + node.children = []; + } + } else this._i++; + this._sectionStart = this._i + 1; + this._state = this.Text; + if (!config.ignoreTags[node.name]) { + // 检查空白符是否有效 + if (node.name == "pre" || (node.attrs.style && node.attrs.style.toLowerCase().includes("white-space") && + node.attrs + .style.toLowerCase().includes("pre"))) { + this._whiteSpace = true; + node.pre = true; + } + slibings.push(node); + } + }; + // 标签出栈处理 + popNode(node) { + // 替换一些标签名 + if (config.blockTags[node.name]) node.name = 'div'; + else if (!config.trustTags[node.name]) node.name = 'span'; + // 空白符处理 + if (node.pre) { + this._whiteSpace = false; + node.pre = undefined; + for (var i = 0; i < this._STACK.length; i++) + if (this._STACK[i].pre) + this._whiteSpace = true; + } + // 处理表格的边框 + if (node.name == 'table') { + if (node.attrs.border) + node.attrs.style = "border:" + node.attrs.border + "px solid gray;" + (node.attrs.style || ''); + if (node.attrs.hasOwnProperty("cellspacing")) + node.attrs.style = "border-spacing:" + node.attrs.cellspacing + "px;" + (node.attrs.style || ''); + + function setBorder(elem) { + if (elem.name == 'th' || elem.name == 'td') { + if (node.attrs.border) + elem.attrs.style = "border:" + node.attrs.border + "px solid gray;" + (elem.attrs.style || + ''); + if (node.attrs.hasOwnProperty("cellpadding")) + elem.attrs.style = "padding:" + node.attrs.cellpadding + "px;" + (elem.attrs.style || ''); + return; + } + if (elem.type == 'text') return; + for (var i = 0; i < elem.children.length; i++) + setBorder(elem.children[i]); + } + if (node.attrs.border || node.attrs.hasOwnProperty("cellpadding")) + for (var i = 0; i < node.children.length; i++) + setBorder(node.children[i]); + } + // 合并一些不必要的层,减小节点深度 + if (node.children.length == 1 && node.name == "div" && node.children[0].name == "div") { + var child = node.children[0]; + node.attrs.style = node.attrs.style || ''; + child.attrs.style = child.attrs.style || ''; + if (node.attrs.style.includes("padding") && (node.attrs.style.includes("margin") || child.attrs.style + .includes( + "margin")) && node.attrs.style.includes("display") && child.attrs.style.includes( + "display") && !(node.attrs.id && + node.attrs.id) && !(node.attrs.class && child.attrs.class)) { + if (child.attrs.style.includes("padding")) + child.attrs.style = "box-sizing:border-box;" + child.attrs.style; + node.attrs.style = node.attrs.style + ";" + child.attrs.style; + node.attrs.id = (child.attrs.id || '') + (node.attrs.id || ''); + node.attrs.class = (child.attrs.class || '') + (node.attrs.class || ''); + node.children = child.children; + } + } + // 多层样式处理 + if (this.CssHandler.pop) + this.CssHandler.pop(node); + }; + // 工具函数 + checkClose() { + if (this.data[this._i] == '>' || (this.data[this._i] == '/' && this.data[this._i + 1] == '>')) + return true; + return false; + }; + getSelection(trim) { + var str = (this._sectionStart == this._i ? '' : this.data.substring(this._sectionStart, this._i)); + while (trim && isBlankChar(this.data[++this._i])); + if (trim) this._i--; + this._sectionStart = this._i + 1; + return str; + }; + // 状态机 + Text(c) { + if (c == '<') { + var next = this.data[this._i + 1]; + if ((next >= 'a' && next <= 'z') || (next >= 'A' && next <= 'Z')) { + this.setText(); + this._state = this.TagName; + } else if (next == '/') { + this.setText(); + this._i++; + next = this.data[this._i + 1]; + if ((next >= 'a' && next <= 'z') || (next >= 'A' && next <= 'Z')) { + this._sectionStart = this._i + 1; + this._state = this.EndTag; + } else + this._state = this.Comment; + } else if (next == '!') { + this.setText(); + this._state = this.Comment; + } + } + }; + Comment() { + if (this.data.substring(this._i + 1, this._i + 3) == "--" || this.data.substring(this._i + 1, this._i + + 7) == + "[CDATA[") { + this._i = this.data.indexOf("-->", this._i + 1); + if (this._i == -1) return this._i = this.data.length; + else this._i = this._i + 2; + } else { + this._i = this.data.indexOf(">", this._i + 1); + if (this._i == -1) return this._i = this.data.length; + } + this._sectionStart = this._i + 1; + this._state = this.Text; + }; + TagName(c) { + if (isBlankChar(c)) { + this._tagName = this.getSelection(true); + if (this.checkClose()) this.setNode(); + else this._state = this.AttrName; + } else if (this.checkClose()) { + this._tagName = this.getSelection(); + this.setNode(); + } + }; + AttrName(c) { + if (isBlankChar(c)) { + this._attrName = this.getSelection(true).toLowerCase(); + if (this.data[this._i] == '=') { + while (isBlankChar(this.data[++this._i])); + this._sectionStart = this._i; + this._i--; + this._state = this.AttrValue; + } else this.setAttr(); + } else if (c == '=') { + this._attrName = this.getSelection().toLowerCase(); + while (isBlankChar(this.data[++this._i])); + this._sectionStart = this._i; + this._i--; + this._state = this.AttrValue; + } else if (this.checkClose()) { + this._attrName = this.getSelection().toLowerCase(); + this.setAttr(); + } + }; + AttrValue(c) { + if (c == '"' || c == "'") { + this._sectionStart++; + if ((this._i = this.data.indexOf(c, this._i + 1)) == -1) return this._i = this.data.length; + } else + for (; !isBlankChar(this.data[this._i] && this.data[this._i] != '/' && this.data[this._i] != '>'); this + ._i++); + this._attrValue = this.getSelection(); + while (this._attrValue.includes(""")) this._attrValue = this._attrValue.replace(""", ''); + this.setAttr(); + }; + EndTag(c) { + if (isBlankChar(c) || c == '>' || c == '/') { + var name = this.getSelection().toLowerCase(); + var flag = false; + for (var i = this._STACK.length - 1; i >= 0; i--) + if (this._STACK[i].name == name) { + flag = true; + break; + } + if (flag) { + var node; + while (flag) { + node = this._STACK.pop(); + if (node.name == name) flag = false; + this.popNode(node); + } + } else if (name == 'p' || name == "br") { + var slibings = this._STACK.length ? this._STACK[this._STACK.length - 1].children : this.DOM; + var node = { + name + } + slibings.push(node); + } + this._i = this.data.indexOf('>', this._i); + if (this._i == -1) this._i = this.data.length; + else this._state = this.Text; + } + }; +}; +module.exports = { + parseHtml: (data, options) => new Promise((resolve) => new MpHtmlParser(data, options, resolve).parse()), + parseHtmlSync: (data, options) => new MpHtmlParser(data, options).parse() +}; diff --git a/components/jyf-Parser/libs/config.js b/components/jyf-Parser/libs/config.js new file mode 100644 index 0000000..e2f37f5 --- /dev/null +++ b/components/jyf-Parser/libs/config.js @@ -0,0 +1,252 @@ +/* 配置文件 */ +function makeMap(str) { + var map = Object.create(null), + list = str.split(','); + for (var item of list) + map[item] = true; + return map; +} +// 信任的属性列表,不在列表中的属性将被移除 +const trustAttrs = makeMap( + "align,alt,app-id,appId," + // #ifdef MP-BAIDU + + + "appid,apid," + // #endif + + + "author,autoplay,border,cellpadding,cellspacing,class,color,colspan,controls,data-src,dir,face,height,href,id,ignore,loop,muted,name,path,poster,rowspan,size,span,src,start,style,type,lbType,lbtype," + // #ifdef MP-WEIXIN || MP-QQ + + + "unit-id,unitId," + // #endif + + + "width,xmlns" +); +// 信任的标签,将保持标签名不变 +const trustTags = makeMap( + "a,abbr,ad,audio,b,blockquote,br,code,col,colgroup,dd,del,dl,dt,div,em,fieldset,h1,h2,h3,h4,h5,h6,hr,i,img,ins,label,legend,li,ol,p,q,source,span,strong,sub,sup,table,tbody,td,tfoot,th,thead,tr,title,u,ul,video,iframe" +); +// 块级标签,将被转为 div +const blockTags = makeMap("address,article,aside,body,center,cite,footer,header,html,nav,pre,section"); +// 被移除的标签(其中 svg 系列标签会被转为图片) +const ignoreTags = makeMap( + "area,base,basefont,canvas,circle,command,ellipse,embed,frame,head,input,isindex,keygen,line,link,map,meta,param,path,polygon,rect,script,source,svg,textarea,track,use,wbr," +); +// 只能用 rich-text 显示的标签(其中图片不能预览、不能显示视频、音频等) +const richOnlyTags = makeMap( + "a,ad,audio,colgroup,fieldset,legend,li,ol,sub,sup,table,tbody,td,tfoot,th,thead,tr,ul,video,iframe,"); +// 自闭合标签 +const selfClosingTags = makeMap( + "area,base,basefont,br,col,circle,ellipse,embed,frame,hr,img,input,isindex,keygen,line,link,meta,param,path,polygon,rect,source,track,use,wbr," +); +// 默认的标签样式 +var userAgentStyles = { + a: "color:#366092;word-break:break-all;padding:1.5px 0 1.5px 0", + address: "font-style:italic", + blockquote: "background-color:#f6f6f6;border-left:3px solid #dbdbdb;color:#6c6c6c;padding:5px 0 5px 10px", + center: "text-align:center", + cite: "font-style:italic", + code: "padding:0 1px 0 1px;margin-left:2px;margin-right:2px;background-color:#f8f8f8;border-radius:3px", + dd: "margin-left:40px", + img: "max-width:100%", + mark: "background-color:yellow", + pre: "font-family:monospace;white-space:pre;overflow:scroll", + s: "text-decoration:line-through", + u: "text-decoration:underline" +}; +// #ifndef MP-ALIPAY || H5 +const SDKVersion = uni.getSystemInfoSync().SDKVersion; + +function versionHigherThan(version = '') { + var v1 = SDKVersion.split('.'), + v2 = version.split('.'); + while (v1.length != v2.length) + v1.length < v2.length ? v1.push('0') : v2.push('0'); + for (var i = 0; i < v1.length; i++) { + if (v1[i] == v2[i]) continue; + if (parseInt(v1[i]) > parseInt(v2[i])) return true; + return false; + } + return true; +}; +// #endif +// #ifdef MP-WEIXIN || MP-QQ +// 版本兼容 +if (versionHigherThan("2.7.1")) { + trustTags.bdi = true; + trustTags.bdo = true; + trustTags.caption = true; + trustTags.rt = true; + trustTags.ruby = true; + ignoreTags.rp = true; + trustTags.big = true; + trustTags.small = true; + trustTags.pre = true; + trustTags.iframe = true; + richOnlyTags.bdi = true; + richOnlyTags.bdo = true; + richOnlyTags.caption = true; + richOnlyTags.rt = true; + richOnlyTags.ruby = true; + richOnlyTags.pre = true; + blockTags.pre = undefined; +} else { + blockTags.caption = true; + userAgentStyles.big = "display:inline;font-size:1.2em"; + userAgentStyles.small = "display:inline;font-size:0.8em"; +} +// #endif +function bubbling(Parser) { + for (var i = Parser._STACK.length - 1; i >= 0; i--) { + if (!richOnlyTags[Parser._STACK[i].name]) + Parser._STACK[i].c = 1; + else return false; + } + return true; +} +module.exports = { + // 高亮处理函数 + highlight: null, + // 处理标签的属性,需要通过组件递归方式显示的标签需要调用 bubbling(Parser) + LabelAttrsHandler(node, Parser) { + let default_style = "max-width: 100% !important;display:block;" + node.attrs.style = Parser.CssHandler.match(node.name, node.attrs, node) + (node.attrs.style || ''); + switch (node.name) { + case "ul": + case "ol": + case "li": + case "dd": + case "dl": + case "dt": + case "div": + case "span": + case "em": + case 'p': + if (node.name === 'span') { + default_style = 'white-space:normal;' + } + if (node.name === 'p' && (!node.attrs.style || !node.attrs.style.includes('margin-top:'))) { + default_style += 'margin-top:10px;' + } + if (node.attrs.style) { + node.attrs.style = node.attrs.style.includes('width:') ? default_style : node.attrs.style + + `;${default_style}` + } + if (node.attrs.align) { + node.attrs.style = "text-align:" + node.attrs.align + ';' + node.attrs.style; + node.attrs.align = undefined; + } + break; + case "img": + if (node.attrs.height) { + node.attrs.height = 'auto' + } + if (node.attrs.style) { + node.attrs.style = node.attrs.style.includes('height:') ? default_style : node.attrs.style + + `;${default_style}` + } + if (node.attrs["data-src"]) { + node.attrs.src = node.attrs.src || node.attrs["data-src"]; + node.attrs["data-src"] = undefined; + } + // #ifdef MP-BAIDU || MP-TOUTIAO + if (Parser._imgMode == "widthFix") node.attrs.style = node.attrs.style + ";height:auto !important;"; + // #endif + if (node.attrs.src) { + if (!node.attrs.ignore) { + if (bubbling(Parser)) node.attrs.i = (Parser._imgNum++).toString(); + else node.attrs.ignore = "true"; + } + if (Parser._domain && node.attrs.src[0] == '/') { + if (node.attrs.src[1] == '/') node.attrs.src = Parser._protocol + ":" + node.attrs.src; + else node.attrs.src = Parser._domain + node.attrs.src; + } + } + break; + case 'a': + case "ad": + bubbling(Parser); + break; + case "font": + if (node.attrs.color) { + node.attrs.style = "color:" + node.attrs.color + ';' + node.attrs.style; + node.attrs.color = undefined; + } + if (node.attrs.face) { + node.attrs.style = "font-family:" + node.attrs.face + ';' + node.attrs.style; + node.attrs.face = undefined; + } + if (node.attrs.size) { + var size = parseInt(node.attrs.size); + if (size < 1) size = 1; + else if (size > 7) size = 7; + var map = ["xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large"]; + node.attrs.style = "font-size:" + map[size - 1] + ';' + node.attrs.style; + node.attrs.size = undefined; + } + break; + case 'iframe': + case "video": + case "audio": + node.attrs.loop = node.attrs.hasOwnProperty('loop') || false; + node.attrs.controls = node.attrs.hasOwnProperty( + 'controls') || true; + node.attrs.autoplay = node.attrs.hasOwnProperty('autoplay') || false; + if (node.attrs.id) Parser['_' + node.name + "Num"]++; + else node.attrs.id = (node.name + (++Parser['_' + node.name + "Num"])); + if (node.name == "video") { + node.attrs.style = node.attrs.style || ''; + if (node.attrs.width) { + node.attrs.style = "width:" + parseFloat(node.attrs.width) + (node.attrs.height.includes( + '%') ? '%' : "px") + + ';' + node.attrs.style; + node.attrs.width = undefined; + } + if (node.attrs.height) { + node.attrs.style = "height:" + parseFloat(node.attrs.height) + (node.attrs.height.includes( + '%') ? '%' : "px") + + ';' + node.attrs.style; + node.attrs.height = undefined; + } + if (Parser._videoNum > 3) node.lazyLoad = true; + } + // 新增iframe【create_by_xx】 + if (node.name == 'iframe') { + // console.log(node.attrs, "====iframe attrs"); + } + node.attrs.source = []; + if (node.attrs.src) node.attrs.source.push(node.attrs.src); + if (!node.attrs.controls && !node.attrs.autoplay) + console.warn("存在没有controls属性的 " + node.name + " 标签,可能导致无法播放", node); + bubbling(Parser); + break; + case "source": + var parent = Parser._STACK[Parser._STACK.length - 1]; + if (parent && (parent.name == "video" || parent.name == "audio")) { + parent.attrs.source.push(node.attrs.src); + if (!parent.attrs.src) parent.attrs.src = node.attrs.src; + } + break; + } + if (Parser._domain && node.attrs.style.includes("url")) + node.attrs.style = node.attrs.style.replace(/url\s*\(['"\s]*(\S*?)['"\s]*\)/, function() { + var src = arguments[1]; + if (src && src[0] == '/') { + if (src[1] == '/') return "url(" + Parser._protocol + ':' + src + ')'; + else return "url(" + Parser._domain + src + ')'; + } else return arguments[0]; + }) + if (!node.attrs.style) node.attrs.style = undefined; + if (Parser._useAnchor && node.attrs.id) bubbling(Parser); + }, + trustAttrs, + trustTags, + blockTags, + ignoreTags, + selfClosingTags, + userAgentStyles, + // #ifndef MP-ALIPAY || H5 + versionHigherThan, + // #endif + makeMap +} \ No newline at end of file diff --git a/components/jyf-Parser/trees.vue b/components/jyf-Parser/trees.vue new file mode 100644 index 0000000..f17789a --- /dev/null +++ b/components/jyf-Parser/trees.vue @@ -0,0 +1,407 @@ + + ++ + + + + + + diff --git a/components/load-more.vue b/components/load-more.vue new file mode 100644 index 0000000..70480b8 --- /dev/null +++ b/components/load-more.vue @@ -0,0 +1,131 @@ + ++ + + + + + ++ + + + + ++ + + + + + + + + + +{{item.text}} ++ {{item.text}} + +\n + ++ + + ++ + + + + + + + + + + + ++ + ++ + + ++ + + + + + + + + + + + + + + + ++ + + + + + + + + diff --git a/components/login-info.vue b/components/login-info.vue new file mode 100644 index 0000000..d9461e8 --- /dev/null +++ b/components/login-info.vue @@ -0,0 +1,112 @@ + ++ ++ {{noMoreText}} ++ + ++ {{loadText}} ++ + + + + + diff --git a/components/mask.vue b/components/mask.vue new file mode 100644 index 0000000..3441b2b --- /dev/null +++ b/components/mask.vue @@ -0,0 +1,121 @@ + ++ ++ + ++ + ++ +{{`欢迎来到${configInfo.app_text}`}} +登录后获取更多精彩内容 +去登录 ++ + + + + + + diff --git a/components/min-countdown.vue b/components/min-countdown.vue new file mode 100644 index 0000000..f1b2dc5 --- /dev/null +++ b/components/min-countdown.vue @@ -0,0 +1,176 @@ + ++ + + + + + + \ No newline at end of file diff --git a/components/search.vue b/components/search.vue new file mode 100644 index 0000000..50f9842 --- /dev/null +++ b/components/search.vue @@ -0,0 +1,207 @@ + ++ ++ + +{{time.d}} 天{{time.h}} + 时 +{{time.m}} 分{{time.s}} + 秒 ++ + + + + + + diff --git a/components/service-list-item.vue b/components/service-list-item.vue new file mode 100644 index 0000000..fcc5d72 --- /dev/null +++ b/components/service-list-item.vue @@ -0,0 +1,180 @@ + ++ ++ ++ {{placeholder}} ++ ++ ++ + 搜索 ++ + + + + + \ No newline at end of file diff --git a/components/shop-banner.vue b/components/shop-banner.vue new file mode 100644 index 0000000..ee92837 --- /dev/null +++ b/components/shop-banner.vue @@ -0,0 +1,233 @@ + ++ + + ++ + + ++ ++ + + ++ +{{ info.title }} +超{{ info.total_sale }}人选择 +{{ info.sub_title || '' }} + +物料费:¥{{info.material_price}} ++ ++ ++ ¥ + ++ {{ info.price }} + +¥{{ info.init_price }} ++ + + ++ ++ ++ + {{ from == 'technician-info' ? `立即预约` : `选择${$t('action.attendantName')}`}} + ++ + + + + + diff --git a/components/tab.vue b/components/tab.vue new file mode 100644 index 0000000..7e11e45 --- /dev/null +++ b/components/tab.vue @@ -0,0 +1,210 @@ + ++ + ++ + + ++ + + ++ 回到首页 ++ ++ ++ ++ ++ + ++ + + + ++ + ++ + {{current+1}}/{{detail.images.length}} + ++ + + + + + diff --git a/components/tabbar.vue b/components/tabbar.vue new file mode 100644 index 0000000..3942976 --- /dev/null +++ b/components/tabbar.vue @@ -0,0 +1,117 @@ + ++ ++ ++ ++ {{item.title || item}} + ++ {{item.number < 100 ? item.number : '99+'}} + ++ {{item.number < 100 ? item.number : '99+'}} + +{{item.title || item}} ++ ++ ++ + + ++ + + + + + diff --git a/components/technician-list-item.vue b/components/technician-list-item.vue new file mode 100644 index 0000000..5140120 --- /dev/null +++ b/components/technician-list-item.vue @@ -0,0 +1,306 @@ + ++ + ++ {{item.name}} ++ + + + + + + \ No newline at end of file diff --git a/components/technician-list-popup.vue b/components/technician-list-popup.vue new file mode 100644 index 0000000..c83d4bc --- /dev/null +++ b/components/technician-list-popup.vue @@ -0,0 +1,331 @@ + ++ + ++ ++ ++ + ++ ++ ++ + + ++ ++ + ++ {{textType[info.text_type]}} + ++ ++ ++ ++ +{{info.coach_name}} +生活照 ++ ++ +{{info.star}} ++ 已服务 {{info.order_num > 9999 ? '9999+' : info.order_num}}单 ++ ++ + +{{info.distance}} ++ +最早可约 +{{'时间'+info.near_time+''}} ++ ++ ++ ++ + 商家 + ++ + {{info.admin_name}} + ++ + 详情 + +{{info.comment_num > 9999 ? '9999+':info.comment_num}} + +{{info.collect_num > 9999 ? '9999+':info.collect_num}} + ++ ++ 预约TA + ++ + + + + + \ No newline at end of file diff --git a/components/time-picker-popup/README.md b/components/time-picker-popup/README.md new file mode 100644 index 0000000..91e3133 --- /dev/null +++ b/components/time-picker-popup/README.md @@ -0,0 +1,87 @@ +### 使用组件 + +```html ++ ++ ++ ++ + + ++ ++ ++ {{info.coach_name}} + 从业{{info.work_time}}年 ++ {{info.text}} + ++ + ++ ++ ++ + ++ {{item.title}} + +超{{item.total_sale}}人选择 ++ ++ ++ ¥ + ++ {{item.price}} + ++ ¥{{item.init_price}} ++ + {{item.time_long}}分钟 + ++ ++ + + + ++ + ++ ++ + ++ 查看更多 + ++ + +合计: +¥{{car_info.car_price}} + +提交订单 + ++ + +``` + +### 引入组件 + +```javascript +import TimePickerPopup from '@/components/time-picker-popup/time-picker-popup.vue'; +``` + +### 注册组件 + +```javascript +export default { + components: { TimePickerPopup }, + data() { + return { + value: ['00', '00', '00', '00'] + } + }, + onReady() { + this.open(); + }, + methods: { + confirm(data) { + uni.showToast({ + title: `${data[0]}:${data[1]}-${data[2]}:${data[3]}` + }) + }, + open() { + this.$refs.TimePickerPopupRef.open(); + } + } +} +``` + +### 参数 + +```javascript +// 当前选中的值 +value: { + type: Array, + default: () => (['00', '00', '00', '00']) +}, +// 标题 +title: { + type: String, + default: '时间' +}, +// 取消按钮文字 +cancelText: { + type: String, + default: '取消' +}, +// 取消按钮颜色 +canceColor: { + type: String, + default: '#666666' +}, +// 确定按钮文字 +confirmText: { + type: String, + default: '确定' +}, +// 确定按钮颜色 +confirmColor: { + type: String, + default: '#2bb781' +}, +// 分割符 +segmentation: { + type: String, + default: '-' +}, +// 设置选择器中间选中框的类名 注意页面或组件的style中写了scoped时,需要在类名前写/deep/ +indicatorClass: { + type: String, + default: 'picker-view__indicator' +}, +// 设置选择器中间选中框的样式 +indicatorStyle: { + type: String, + default: '' +}, +``` diff --git a/components/time-picker-popup/time-picker-popup.vue b/components/time-picker-popup/time-picker-popup.vue new file mode 100644 index 0000000..44dafef --- /dev/null +++ b/components/time-picker-popup/time-picker-popup.vue @@ -0,0 +1,163 @@ + + + + + + + + + \ No newline at end of file diff --git a/components/time-picker-popup/utils.js b/components/time-picker-popup/utils.js new file mode 100644 index 0000000..e093659 --- /dev/null +++ b/components/time-picker-popup/utils.js @@ -0,0 +1,69 @@ +// 组件props +const props = { + // 当前选中的值 + value: { + type: Array, + default: () => (['00', '00', '00', '00']) + }, + // 标题 + title: { + type: String, + default: '时间' + }, + // 取消按钮文字 + cancelText: { + type: String, + default: '取消' + }, + // 取消按钮颜色 + canceColor: { + type: String, + default: '#666666' + }, + // 确定按钮文字 + confirmText: { + type: String, + default: '确定' + }, + // 确定按钮颜色 + confirmColor: { + type: String, + default: '#2bb781' + }, + // 分割符 + segmentation: { + type: String, + default: '-' + }, + // 设置选择器中间选中框的类名 注意页面或组件的style中写了scoped时,需要在类名前写/deep/ + indicatorClass: { + type: String, + default: 'picker-view__indicator' + }, + // 设置选择器中间选中框的样式 + indicatorStyle: { + type: String, + default: '' + }, +} + +// 滚动数据 +let range = [ + [], + [], + [], + [] +]; +for (let i = 0; i < 24; i++) { + range[0].push(i >= 10 ? String(i) : `0${i}`); + range[2].push(i >= 10 ? String(i) : `0${i}`); +} +for (let i = 0; i < 60; i++) { + range[1].push(i >= 10 ? String(i) : `0${i}`); + range[3].push(i >= 10 ? String(i) : `0${i}`); +} + +export default { + props, + range +} \ No newline at end of file diff --git a/components/timeline.vue b/components/timeline.vue new file mode 100644 index 0000000..14f4666 --- /dev/null +++ b/components/timeline.vue @@ -0,0 +1,210 @@ + ++ ++ +{{ cancelText }} +{{ title }} +{{ confirmText }} ++ ++ +{{item}} ++ + +{{item}} ++ +{{item}} ++ +{{item}} ++ + + + + + diff --git a/components/uni-nav-bar.vue b/components/uni-nav-bar.vue new file mode 100644 index 0000000..baca195 --- /dev/null +++ b/components/uni-nav-bar.vue @@ -0,0 +1,247 @@ + ++ ++ + ++ + + ++ {{item.title}} + ++ {{item.title == '签字确认' && !info.sign_img ? '暂未签字确认' : info.pay_type > item.pay_type -1 && info.pay_type != 8? '' : '状态未开始' }} + ++ {{info[item.time]}} + ++ ++ {{info.serout_address}} + ++ ++ + ++ + + ++ ++ + ++ {{info.arr_address}} + ++ ++ + ++ + + ++ ++ + ++ {{info.end_address}} + ++ ++ + ++ + + ++ ++ + ++ ++ 签字确认 + ++ + + + + + + \ No newline at end of file diff --git a/components/uni-popup.vue b/components/uni-popup.vue new file mode 100644 index 0000000..32004f6 --- /dev/null +++ b/components/uni-popup.vue @@ -0,0 +1,209 @@ + ++ + ++ ++ {{leftText || ''}} ++ ++ +{{title}} + ++ + +{{rightText}} ++ + + + + + \ No newline at end of file diff --git a/components/uni-segmented-control.vue b/components/uni-segmented-control.vue new file mode 100644 index 0000000..73d07c7 --- /dev/null +++ b/components/uni-segmented-control.vue @@ -0,0 +1,160 @@ + ++ + ++ ++ + + + + + + diff --git a/components/uni-status-bar.vue b/components/uni-status-bar.vue new file mode 100644 index 0000000..f35d1dc --- /dev/null +++ b/components/uni-status-bar.vue @@ -0,0 +1,29 @@ + ++ {{item.title}} + ++ + + + + + diff --git a/components/upload.vue b/components/upload.vue new file mode 100644 index 0000000..64c66ac --- /dev/null +++ b/components/upload.vue @@ -0,0 +1,353 @@ + ++ + + + + + + \ No newline at end of file diff --git a/components/w-picker/areadata/areadata.js b/components/w-picker/areadata/areadata.js new file mode 100644 index 0000000..b07228c --- /dev/null +++ b/components/w-picker/areadata/areadata.js @@ -0,0 +1 @@ +const cityData=[{value:'110000',label:'北京市',children:[{value:"110100",label:"北京市",children:[{value:"110101",label:"东城区"},{value:"110102",label:"西城区"},{value:"110105",label:"朝阳区"},{value:"110106",label:"丰台区"},{value:"110107",label:"石景山区"},{value:"110108",label:"海淀区"},{value:"110109",label:"门头沟区"},{value:"110111",label:"房山区"},{value:"110112",label:"通州区"},{value:"110113",label:"顺义区"},{value:"110114",label:"昌平区"},{value:"110115",label:"大兴区"},{value:"110116",label:"怀柔区"},{value:"110117",label:"平谷区"},{value:"110118",label:"密云区"},{value:"110119",label:"延庆区"}]}]},{value:'120000',label:'天津市',children:[{value:"120100",label:"天津市",children:[{value:"120101",label:"和平区"},{value:"120102",label:"河东区"},{value:"120103",label:"河西区"},{value:"120104",label:"南开区"},{value:"120105",label:"河北区"},{value:"120106",label:"红桥区"},{value:"120110",label:"东丽区"},{value:"120111",label:"西青区"},{value:"120112",label:"津南区"},{value:"120113",label:"北辰区"},{value:"120114",label:"武清区"},{value:"120115",label:"宝坻区"},{value:"120116",label:"滨海新区"},{value:"120117",label:"宁河区"},{value:"120118",label:"静海区"},{value:"120119",label:"蓟州区"}]}]},{value:'130000',label:'河北省',children:[{value:"130100",label:"石家庄市",children:[{value:"130102",label:"长安区"},{value:"130104",label:"桥西区"},{value:"130105",label:"新华区"},{value:"130107",label:"井陉矿区"},{value:"130108",label:"裕华区"},{value:"130109",label:"藁城区"},{value:"130110",label:"鹿泉区"},{value:"130111",label:"栾城区"},{value:"130121",label:"井陉县"},{value:"130123",label:"正定县"},{value:"130125",label:"行唐县"},{value:"130126",label:"灵寿县"},{value:"130127",label:"高邑县"},{value:"130128",label:"深泽县"},{value:"130129",label:"赞皇县"},{value:"130130",label:"无极县"},{value:"130131",label:"平山县"},{value:"130132",label:"元氏县"},{value:"130133",label:"赵县"},{value:"130181",label:"辛集市"},{value:"130183",label:"晋州市"},{value:"130184",label:"新乐市"},{value:"130172",label:"石家庄循环化工园区"},{value:"130171",label:"石家庄高新技术产业开发区"}]},{value:"130200",label:"唐山市",children:[{value:"130202",label:"路南区"},{value:"130203",label:"路北区"},{value:"130204",label:"古冶区"},{value:"130205",label:"开平区"},{value:"130207",label:"丰南区"},{value:"130208",label:"丰润区"},{value:"130209",label:"曹妃甸区"},{value:"130223",label:"滦县"},{value:"130224",label:"滦南县"},{value:"130225",label:"乐亭县"},{value:"130227",label:"迁西县"},{value:"130229",label:"玉田县"},{value:"130281",label:"遵化市"},{value:"130283",label:"迁安市"},{value:"130271",label:"唐山市芦台经济技术开发区"},{value:"130272",label:"唐山市汉沽管理区"},{value:"130273",label:"唐山高新技术产业开发区"},{value:"130274",label:"河北唐山海港经济开发区"}]},{value:"130300",label:"秦皇岛市",children:[{value:"130302",label:"海港区"},{value:"130303",label:"山海关区"},{value:"130304",label:"北戴河区"},{value:"130321",label:"青龙满族自治县"},{value:"130322",label:"昌黎县"},{value:"130306",label:"抚宁区"},{value:"130324",label:"卢龙县"},{value:"130371",label:"秦皇岛市经济技术开发区"},{value:"130372",label:"北戴河新区"}]},{value:"130400",label:"邯郸市",children:[{value:"130402",label:"邯山区"},{value:"130403",label:"丛台区"},{value:"130404",label:"复兴区"},{value:"130406",label:"峰峰矿区"},{value:"130421",label:"邯郸县"},{value:"130423",label:"临漳县"},{value:"130424",label:"成安县"},{value:"130425",label:"大名县"},{value:"130426",label:"涉县"},{value:"130427",label:"磁县"},{value:"130407",label:"肥乡区"},{value:"130408",label:"永年区"},{value:"130430",label:"邱县"},{value:"130431",label:"鸡泽县"},{value:"130432",label:"广平县"},{value:"130433",label:"馆陶县"},{value:"130434",label:"魏县"},{value:"130435",label:"曲周县"},{value:"130481",label:"武安市"},{value:"130471",label:"邯郸经济技术开发区"},{value:"130473",label:"邯郸冀南新区"}]},{value:"130500",label:"邢台市",children:[{value:"130502",label:"桥东区"},{value:"130503",label:"桥西区"},{value:"130521",label:"邢台县"},{value:"130522",label:"临城县"},{value:"130523",label:"内丘县"},{value:"130524",label:"柏乡县"},{value:"130525",label:"隆尧县"},{value:"130526",label:"任县"},{value:"130527",label:"南和县"},{value:"130528",label:"宁晋县"},{value:"130529",label:"巨鹿县"},{value:"130530",label:"新河县"},{value:"130531",label:"广宗县"},{value:"130532",label:"平乡县"},{value:"130533",label:"威县"},{value:"130534",label:"清河县"},{value:"130535",label:"临西县"},{value:"130581",label:"南宫市"},{value:"130582",label:"沙河市"},{value:"130571",label:"河北邢台经济开发区"}]},{value:"130600",label:"保定市",children:[{value:"130602",label:"竞秀区"},{value:"130606",label:"莲池区"},{value:"130607",label:"满城区"},{value:"130608",label:"清苑区"},{value:"130623",label:"涞水县"},{value:"130624",label:"阜平县"},{value:"130609",label:"徐水区"},{value:"130626",label:"定兴县"},{value:"130627",label:"唐县"},{value:"130628",label:"高阳县"},{value:"130629",label:"容城县"},{value:"130630",label:"涞源县"},{value:"130631",label:"望都县"},{value:"130632",label:"安新县"},{value:"130633",label:"易县"},{value:"130634",label:"曲阳县"},{value:"130635",label:"蠡县"},{value:"130636",label:"顺平县"},{value:"130637",label:"博野县"},{value:"130638",label:"雄县"},{value:"130681",label:"涿州市"},{value:"130682",label:"定州市"},{value:"130683",label:"安国市"},{value:"130684",label:"高碑店市"},{value:"130671",label:"保定高新技术产业开发区"},{value:"130672",label:"保定白沟新城"}]},{value:"130700",label:"张家口市",children:[{value:"130702",label:"桥东区"},{value:"130703",label:"桥西区"},{value:"130705",label:"宣化区"},{value:"130706",label:"下花园区"},{value:"130708",label:"万全区"},{value:"130709",label:"崇礼区"},{value:"130722",label:"张北县"},{value:"130723",label:"康保县"},{value:"130724",label:"沽源县"},{value:"130725",label:"尚义县"},{value:"130726",label:"蔚县"},{value:"130727",label:"阳原县"},{value:"130728",label:"怀安县"},{value:"130730",label:"怀来县"},{value:"130731",label:"涿鹿县"},{value:"130732",label:"赤城县"},{value:"130733",label:"崇礼县"},{value:"130771",label:"张家口市高新技术产业开发区"},{value:"130772",label:"张家口市察北管理区"},{value:"130773",label:"张家口市塞北管理区"}]},{value:"130800",label:"承德市",children:[{value:"130802",label:"双桥区"},{value:"130803",label:"双滦区"},{value:"130804",label:"鹰手营子矿区"},{value:"130821",label:"承德县"},{value:"130822",label:"兴隆县"},{value:"130881",label:"平泉市"},{value:"130824",label:"滦平县"},{value:"130825",label:"隆化县"},{value:"130826",label:"丰宁满族自治县"},{value:"130827",label:"宽城满族自治县"},{value:"130828",label:"围场满族蒙古族自治县"},{value:"130871",label:"承德高新技术产业开发区"}]},{value:"130900",label:"沧州市",children:[{value:"130902",label:"新华区"},{value:"130903",label:"运河区"},{value:"130921",label:"沧县"},{value:"130922",label:"青县"},{value:"130923",label:"东光县"},{value:"130924",label:"海兴县"},{value:"130925",label:"盐山县"},{value:"130926",label:"肃宁县"},{value:"130927",label:"南皮县"},{value:"130928",label:"吴桥县"},{value:"130929",label:"献县"},{value:"130930",label:"孟村回族自治县"},{value:"130981",label:"泊头市"},{value:"130982",label:"任丘市"},{value:"130983",label:"黄骅市"},{value:"130984",label:"河间市"},{value:"130971",label:"河北沧州经济开发区"},{value:"130972",label:"沧州高新技术产业开发区"},{value:"130973",label:"沧州渤海新区"}]},{value:"131000",label:"廊坊市",children:[{value:"131002",label:"安次区"},{value:"131003",label:"广阳区"},{value:"131022",label:"固安县"},{value:"131023",label:"永清县"},{value:"131024",label:"香河县"},{value:"131025",label:"大城县"},{value:"131026",label:"文安县"},{value:"131028",label:"大厂回族自治县"},{value:"131071",label:"廊坊经济技术开发区"},{value:"131081",label:"霸州市"},{value:"131082",label:"三河市"}]},{value:"131100",label:"衡水市",children:[{value:"131102",label:"桃城区"},{value:"131121",label:"枣强县"},{value:"131122",label:"武邑县"},{value:"131123",label:"武强县"},{value:"131124",label:"饶阳县"},{value:"131125",label:"安平县"},{value:"131126",label:"故城县"},{value:"131127",label:"景县"},{value:"131128",label:"阜城县"},{value:"131103",label:"冀州区"},{value:"131182",label:"深州市"},{value:"131172",label:"衡水滨湖新区"},{value:"131171",label:"河北衡水经济开发区"}]}]},{value:'140000',label:'山西省',children:[{value:"140100",label:"太原市",children:[{value:"140105",label:"小店区"},{value:"140106",label:"迎泽区"},{value:"140107",label:"杏花岭区"},{value:"140108",label:"尖草坪区"},{value:"140109",label:"万柏林区"},{value:"140110",label:"晋源区"},{value:"140121",label:"清徐县"},{value:"140122",label:"阳曲县"},{value:"140123",label:"娄烦县"},{value:"140181",label:"古交市"},{value:"140171",label:"山西转型综合改革示范区"}]},{value:"140200",label:"大同市",children:[{value:"140202",label:"城区"},{value:"140203",label:"矿区"},{value:"140211",label:"南郊区"},{value:"140212",label:"新荣区"},{value:"140221",label:"阳高县"},{value:"140222",label:"天镇县"},{value:"140223",label:"广灵县"},{value:"140224",label:"灵丘县"},{value:"140225",label:"浑源县"},{value:"140226",label:"左云县"},{value:"140227",label:"大同县"},{value:"140271",label:"山西大同经济开发区"}]},{value:"140300",label:"阳泉市",children:[{value:"140302",label:"城区"},{value:"140303",label:"矿区"},{value:"140311",label:"郊区"},{value:"140321",label:"平定县"},{value:"140322",label:"盂县"},{value:"140371",label:"山西阳泉经济开发区"}]},{value:"140400",label:"长治市",children:[{value:"140421",label:"长治县"},{value:"140423",label:"襄垣县"},{value:"140424",label:"屯留县"},{value:"140425",label:"平顺县"},{value:"140426",label:"黎城县"},{value:"140427",label:"壶关县"},{value:"140428",label:"长子县"},{value:"140429",label:"武乡县"},{value:"140430",label:"沁县"},{value:"140431",label:"沁源县"},{value:"140481",label:"潞城市"},{value:"140402",label:"城区"},{value:"140411",label:"郊区"},{value:"140471",label:"山西长治高新技术产业园区"}]},{value:"140500",label:"晋城市",children:[{value:"140502",label:"城区"},{value:"140521",label:"沁水县"},{value:"140522",label:"阳城县"},{value:"140524",label:"陵川县"},{value:"140525",label:"泽州县"},{value:"140581",label:"高平市"}]},{value:"140600",label:"朔州市",children:[{value:"140602",label:"朔城区"},{value:"140603",label:"平鲁区"},{value:"140621",label:"山阴县"},{value:"140622",label:"应县"},{value:"140623",label:"右玉县"},{value:"140624",label:"怀仁县"},{value:"140671",label:"山西朔州经济开发区"}]},{value:"140700",label:"晋中市",children:[{value:"140702",label:"榆次区"},{value:"140721",label:"榆社县"},{value:"140722",label:"左权县"},{value:"140723",label:"和顺县"},{value:"140724",label:"昔阳县"},{value:"140725",label:"寿阳县"},{value:"140726",label:"太谷县"},{value:"140727",label:"祁县"},{value:"140728",label:"平遥县"},{value:"140729",label:"灵石县"},{value:"140781",label:"介休市"}]},{value:"140800",label:"运城市",children:[{value:"140802",label:"盐湖区"},{value:"140821",label:"临猗县"},{value:"140822",label:"万荣县"},{value:"140823",label:"闻喜县"},{value:"140824",label:"稷山县"},{value:"140825",label:"新绛县"},{value:"140826",label:"绛县"},{value:"140827",label:"垣曲县"},{value:"140828",label:"夏县"},{value:"140829",label:"平陆县"},{value:"140830",label:"芮城县"},{value:"140881",label:"永济市"},{value:"140882",label:"河津市"}]},{value:"140900",label:"忻州市",children:[{value:"140902",label:"忻府区"},{value:"140921",label:"定襄县"},{value:"140922",label:"五台县"},{value:"140923",label:"代县"},{value:"140924",label:"繁峙县"},{value:"140925",label:"宁武县"},{value:"140926",label:"静乐县"},{value:"140927",label:"神池县"},{value:"140928",label:"五寨县"},{value:"140929",label:"岢岚县"},{value:"140930",label:"河曲县"},{value:"140931",label:"保德县"},{value:"140932",label:"偏关县"},{value:"140981",label:"原平市"},{value:"140971",label:"五台山风景名胜区"}]},{value:"141000",label:"临汾市",children:[{value:"141002",label:"尧都区"},{value:"141021",label:"曲沃县"},{value:"141022",label:"翼城县"},{value:"141023",label:"襄汾县"},{value:"141024",label:"洪洞县"},{value:"141025",label:"古县"},{value:"141026",label:"安泽县"},{value:"141027",label:"浮山县"},{value:"141028",label:"吉县"},{value:"141029",label:"乡宁县"},{value:"141030",label:"大宁县"},{value:"141031",label:"隰县"},{value:"141032",label:"永和县"},{value:"141033",label:"蒲县"},{value:"141034",label:"汾西县"},{value:"141081",label:"侯马市"},{value:"141082",label:"霍州市"}]},{value:"141100",label:"吕梁市",children:[{value:"141102",label:"离石区"},{value:"141121",label:"文水县"},{value:"141122",label:"交城县"},{value:"141123",label:"兴县"},{value:"141124",label:"临县"},{value:"141125",label:"柳林县"},{value:"141126",label:"石楼县"},{value:"141127",label:"岚县"},{value:"141128",label:"方山县"},{value:"141129",label:"中阳县"},{value:"141130",label:"交口县"},{value:"141181",label:"孝义市"},{value:"141182",label:"汾阳市"}]}]},{value:'150000',label:'内蒙古',children:[{value:"150100",label:"呼和浩特市",children:[{value:"150102",label:"新城区"},{value:"150103",label:"回民区"},{value:"150104",label:"玉泉区"},{value:"150105",label:"赛罕区"},{value:"150121",label:"土默特左旗"},{value:"150122",label:"托克托县"},{value:"150123",label:"和林格尔县"},{value:"150124",label:"清水河县"},{value:"150125",label:"武川县"},{value:"150171",label:"呼和浩特金海工业园区"},{value:"150172",label:"呼和浩特经济技术开发区"}]},{value:"150200",label:"包头市",children:[{value:"150202",label:"东河区"},{value:"150203",label:"昆都仑区"},{value:"150204",label:"青山区"},{value:"150205",label:"石拐区"},{value:"150206",label:"白云矿区"},{value:"150207",label:"九原区"},{value:"150221",label:"土默特右旗"},{value:"150222",label:"固阳县"},{value:"150223",label:"达尔罕茂明安联合旗"},{value:"150271",label:"包头稀土高新技术产业开发区"}]},{value:"150300",label:"乌海市",children:[{value:"150302",label:"海勃湾区"},{value:"150303",label:"海南区"},{value:"150304",label:"乌达区"}]},{value:"150400",label:"赤峰市",children:[{value:"150402",label:"红山区"},{value:"150403",label:"元宝山区"},{value:"150404",label:"松山区"},{value:"150421",label:"阿鲁科尔沁旗"},{value:"150422",label:"巴林左旗"},{value:"150423",label:"巴林右旗"},{value:"150424",label:"林西县"},{value:"150425",label:"克什克腾旗"},{value:"150426",label:"翁牛特旗"},{value:"150428",label:"喀喇沁旗"},{value:"150429",label:"宁城县"},{value:"150430",label:"敖汉旗"}]},{value:"150500",label:"通辽市",children:[{value:"150502",label:"科尔沁区"},{value:"150521",label:"科尔沁左翼中旗"},{value:"150522",label:"科尔沁左翼后旗"},{value:"150523",label:"开鲁县"},{value:"150524",label:"库伦旗"},{value:"150525",label:"奈曼旗"},{value:"150526",label:"扎鲁特旗"},{value:"150581",label:"霍林郭勒市"},{value:"150571",label:"通辽经济技术开发区"}]},{value:"150600",label:"鄂尔多斯市",children:[{value:"150602",label:"东胜区"},{value:"150621",label:"达拉特旗"},{value:"150622",label:"准格尔旗"},{value:"150623",label:"鄂托克前旗"},{value:"150624",label:"鄂托克旗"},{value:"150625",label:"杭锦旗"},{value:"150626",label:"乌审旗"},{value:"150627",label:"伊金霍洛旗"},{value:"150603",label:"康巴什区"}]},{value:"150700",label:"呼伦贝尔市",children:[{value:"150702",label:"海拉尔区"},{value:"150721",label:"阿荣旗"},{value:"150722",label:"莫力达瓦达斡尔族自治旗"},{value:"150723",label:"鄂伦春自治旗"},{value:"150724",label:"鄂温克族自治旗"},{value:"150725",label:"陈巴尔虎旗"},{value:"150726",label:"新巴尔虎左旗"},{value:"150727",label:"新巴尔虎右旗"},{value:"150781",label:"满洲里市"},{value:"150782",label:"牙克石市"},{value:"150783",label:"扎兰屯市"},{value:"150784",label:"额尔古纳市"},{value:"150785",label:"根河市"},{value:"150703",label:"扎赉诺尔区"}]},{value:"150800",label:"巴彦淖尔市",children:[{value:"150802",label:"临河区"},{value:"150821",label:"五原县"},{value:"150822",label:"磴口县"},{value:"150823",label:"乌拉特前旗"},{value:"150824",label:"乌拉特中旗"},{value:"150825",label:"乌拉特后旗"},{value:"150826",label:"杭锦后旗"}]},{value:"150900",label:"乌兰察布市",children:[{value:"150902",label:"集宁区"},{value:"150921",label:"卓资县"},{value:"150922",label:"化德县"},{value:"150923",label:"商都县"},{value:"150924",label:"兴和县"},{value:"150925",label:"凉城县"},{value:"150926",label:"察哈尔右翼前旗"},{value:"150927",label:"察哈尔右翼中旗"},{value:"150928",label:"察哈尔右翼后旗"},{value:"150929",label:"四子王旗"},{value:"150981",label:"丰镇市"}]},{value:"152200",label:"兴安盟",children:[{value:"152201",label:"乌兰浩特市"},{value:"152202",label:"阿尔山市"},{value:"152221",label:"科尔沁右翼前旗"},{value:"152222",label:"科尔沁右翼中旗"},{value:"152223",label:"扎赉特旗"},{value:"152224",label:"突泉县"}]},{value:"152500",label:"锡林郭勒盟",children:[{value:"152501",label:"二连浩特市"},{value:"152502",label:"锡林浩特市"},{value:"152522",label:"阿巴嘎旗"},{value:"152523",label:"苏尼特左旗"},{value:"152524",label:"苏尼特右旗"},{value:"152525",label:"东乌珠穆沁旗"},{value:"152526",label:"西乌珠穆沁旗"},{value:"152527",label:"太仆寺旗"},{value:"152528",label:"镶黄旗"},{value:"152529",label:"正镶白旗"},{value:"152530",label:"正蓝旗"},{value:"152531",label:"多伦县"},{value:"152571",label:"乌拉盖管委会"}]},{value:"152900",label:"阿拉善盟",children:[{value:"152921",label:"阿拉善左旗"},{value:"152922",label:"阿拉善右旗"},{value:"152923",label:"额济纳旗"},{value:"152971",label:"内蒙古阿拉善经济开发区"}]}]},{value:'210000',label:'辽宁省',children:[{value:"210100",label:"沈阳市",children:[{value:"210102",label:"和平区"},{value:"210103",label:"沈河区"},{value:"210104",label:"大东区"},{value:"210105",label:"皇姑区"},{value:"210106",label:"铁西区"},{value:"210111",label:"苏家屯区"},{value:"210112",label:"东陵区"},{value:"210113",label:"新城子区"},{value:"210114",label:"于洪区"},{value:"210115",label:"辽中区"},{value:"210123",label:"康平县"},{value:"210124",label:"法库县"},{value:"210181",label:"新民市"},{value:"210112",label:"浑南区"},{value:"210113",label:"沈北新区"}]},{value:"210200",label:"大连市",children:[{value:"210202",label:"中山区"},{value:"210203",label:"西岗区"},{value:"210204",label:"沙河口区"},{value:"210211",label:"甘井子区"},{value:"210212",label:"旅顺口区"},{value:"210213",label:"金州区"},{value:"210224",label:"长海县"},{value:"210251",label:"开发区"},{value:"210281",label:"瓦房店市"},{value:"210214",label:"普兰店区"},{value:"210283",label:"庄河市"}]},{value:"210300",label:"鞍山市",children:[{value:"210302",label:"铁东区"},{value:"210303",label:"铁西区"},{value:"210304",label:"立山区"},{value:"210311",label:"千山区"},{value:"210321",label:"台安县"},{value:"210323",label:"岫岩满族自治县"},{value:"210381",label:"海城市"}]},{value:"210400",label:"抚顺市",children:[{value:"210402",label:"新抚区"},{value:"210403",label:"东洲区"},{value:"210404",label:"望花区"},{value:"210411",label:"顺城区"},{value:"210421",label:"抚顺县"},{value:"210422",label:"新宾满族自治县"},{value:"210423",label:"清原满族自治县"}]},{value:"210500",label:"本溪市",children:[{value:"210502",label:"平山区"},{value:"210503",label:"溪湖区"},{value:"210504",label:"明山区"},{value:"210505",label:"南芬区"},{value:"210521",label:"本溪满族自治县"},{value:"210522",label:"桓仁满族自治县"}]},{value:"210600",label:"丹东市",children:[{value:"210602",label:"元宝区"},{value:"210603",label:"振兴区"},{value:"210604",label:"振安区"},{value:"210624",label:"宽甸满族自治县"},{value:"210681",label:"东港市"},{value:"210682",label:"凤城市"}]},{value:"210700",label:"锦州市",children:[{value:"210702",label:"古塔区"},{value:"210703",label:"凌河区"},{value:"210711",label:"太和区"},{value:"210726",label:"黑山县"},{value:"210727",label:"义县"},{value:"210781",label:"凌海市"},{value:"210782",label:"北镇市"}]},{value:"210800",label:"营口市",children:[{value:"210802",label:"站前区"},{value:"210803",label:"西市区"},{value:"210804",label:"鲅鱼圈区"},{value:"210811",label:"老边区"},{value:"210881",label:"盖州市"},{value:"210882",label:"大石桥市"}]},{value:"210900",label:"阜新市",children:[{value:"210902",label:"海州区"},{value:"210903",label:"新邱区"},{value:"210904",label:"太平区"},{value:"210905",label:"清河门区"},{value:"210911",label:"细河区"},{value:"210921",label:"阜新蒙古族自治县"},{value:"210922",label:"彰武县"}]},{value:"211000",label:"辽阳市",children:[{value:"211002",label:"白塔区"},{value:"211003",label:"文圣区"},{value:"211004",label:"宏伟区"},{value:"211005",label:"弓长岭区"},{value:"211011",label:"太子河区"},{value:"211021",label:"辽阳县"},{value:"211081",label:"灯塔市"}]},{value:"211100",label:"盘锦市",children:[{value:"211102",label:"双台子区"},{value:"211103",label:"兴隆台区"},{value:"211121",label:"大洼县"},{value:"211122",label:"盘山县"}]},{value:"211200",label:"铁岭市",children:[{value:"211202",label:"银州区"},{value:"211204",label:"清河区"},{value:"211221",label:"铁岭县"},{value:"211223",label:"西丰县"},{value:"211224",label:"昌图县"},{value:"211281",label:"调兵山市"},{value:"211282",label:"开原市"}]},{value:"211300",label:"朝阳市",children:[{value:"211302",label:"双塔区"},{value:"211303",label:"龙城区"},{value:"211321",label:"朝阳县"},{value:"211322",label:"建平县"},{value:"211324",label:"喀喇沁左翼蒙古族自治县"},{value:"211381",label:"北票市"},{value:"211382",label:"凌源市"}]},{value:"211400",label:"葫芦岛市",children:[{value:"211402",label:"连山区"},{value:"211403",label:"龙港区"},{value:"211404",label:"南票区"},{value:"211421",label:"绥中县"},{value:"211422",label:"建昌县"},{value:"211481",label:"兴城市"}]}]},{value:'220000',label:'吉林省',children:[{value:"220100",label:"长春市",children:[{value:"220102",label:"南关区"},{value:"220103",label:"宽城区"},{value:"220104",label:"朝阳区"},{value:"220105",label:"二道区"},{value:"220106",label:"绿园区"},{value:"220112",label:"双阳区"},{value:"220122",label:"农安县"},{value:"220181",label:"九台市"},{value:"220182",label:"榆树市"},{value:"220183",label:"德惠市"},{value:"220171",label:"长春经济技术开发区"},{value:"220172",label:"长春净月高新技术产业开发区"},{value:"220173",label:"长春高新技术产业开发区"},{value:"220174",label:"长春汽车经济技术开发区"}]},{value:"220200",label:"吉林市",children:[{value:"220202",label:"昌邑区"},{value:"220203",label:"龙潭区"},{value:"220204",label:"船营区"},{value:"220211",label:"丰满区"},{value:"220221",label:"永吉县"},{value:"220281",label:"蛟河市"},{value:"220282",label:"桦甸市"},{value:"220283",label:"舒兰市"},{value:"220284",label:"磐石市"},{value:"220271",label:"吉林经济开发区"},{value:"220272",label:"吉林高新技术产业开发区"},{value:"220273",label:"吉林中国新加坡食品区"}]},{value:"220300",label:"四平市",children:[{value:"220302",label:"铁西区"},{value:"220303",label:"铁东区"},{value:"220322",label:"梨树县"},{value:"220323",label:"伊通满族自治县"},{value:"220381",label:"公主岭市"},{value:"220382",label:"双辽市"}]},{value:"220400",label:"辽源市",children:[{value:"220402",label:"龙山区"},{value:"220403",label:"西安区"},{value:"220421",label:"东丰县"},{value:"220422",label:"东辽县"}]},{value:"220500",label:"通化市",children:[{value:"220502",label:"东昌区"},{value:"220503",label:"二道江区"},{value:"220521",label:"通化县"},{value:"220523",label:"辉南县"},{value:"220524",label:"柳河县"},{value:"220581",label:"梅河口市"},{value:"220582",label:"集安市"}]},{value:"220600",label:"白山市",children:[{value:"220602",label:"八道江区"},{value:"220621",label:"抚松县"},{value:"220622",label:"靖宇县"},{value:"220623",label:"长白朝鲜族自治县"},{value:"220605",label:"江源区"},{value:"220681",label:"临江市"},{value:"220602",label:"浑江区"}]},{value:"220700",label:"松原市",children:[{value:"220702",label:"宁江区"},{value:"220721",label:"前郭尔罗斯蒙古族自治县"},{value:"220722",label:"长岭县"},{value:"220723",label:"乾安县"},{value:"220781",label:"扶余市"},{value:"220771",label:"吉林松原经济开发区"}]},{value:"220800",label:"白城市",children:[{value:"220802",label:"洮北区"},{value:"220821",label:"镇赉县"},{value:"220822",label:"通榆县"},{value:"220881",label:"洮南市"},{value:"220882",label:"大安市"},{value:"220871",label:"吉林白城经济开发区"}]},{value:"222400",label:"延边朝鲜族自治州",children:[{value:"222401",label:"延吉市"},{value:"222402",label:"图们市"},{value:"222403",label:"敦化市"},{value:"222404",label:"珲春市"},{value:"222405",label:"龙井市"},{value:"222406",label:"和龙市"},{value:"222424",label:"汪清县"},{value:"222426",label:"安图县"}]}]},{value:'230000',label:'黑龙江省',children:[{value:"230100",label:"哈尔滨市",children:[{value:"230102",label:"道里区"},{value:"230103",label:"南岗区"},{value:"230104",label:"道外区"},{value:"230110",label:"香坊区"},{value:"230107",label:"动力区"},{value:"230108",label:"平房区"},{value:"230109",label:"松北区"},{value:"230111",label:"呼兰区"},{value:"230123",label:"依兰县"},{value:"230124",label:"方正县"},{value:"230125",label:"宾县"},{value:"230126",label:"巴彦县"},{value:"230127",label:"木兰县"},{value:"230128",label:"通河县"},{value:"230129",label:"延寿县"},{value:"230112",label:"阿城区"},{value:"230113",label:"双城区"},{value:"230183",label:"尚志市"},{value:"230184",label:"五常市"}]},{value:"230200",label:"齐齐哈尔市",children:[{value:"230202",label:"龙沙区"},{value:"230203",label:"建华区"},{value:"230204",label:"铁锋区"},{value:"230205",label:"昂昂溪区"},{value:"230206",label:"富拉尔基区"},{value:"230207",label:"碾子山区"},{value:"230208",label:"梅里斯达斡尔族区"},{value:"230221",label:"龙江县"},{value:"230223",label:"依安县"},{value:"230224",label:"泰来县"},{value:"230225",label:"甘南县"},{value:"230227",label:"富裕县"},{value:"230229",label:"克山县"},{value:"230230",label:"克东县"},{value:"230231",label:"拜泉县"},{value:"230281",label:"讷河市"}]},{value:"230300",label:"鸡西市",children:[{value:"230302",label:"鸡冠区"},{value:"230303",label:"恒山区"},{value:"230304",label:"滴道区"},{value:"230305",label:"梨树区"},{value:"230306",label:"城子河区"},{value:"230307",label:"麻山区"},{value:"230321",label:"鸡东县"},{value:"230381",label:"虎林市"},{value:"230382",label:"密山市"}]},{value:"230400",label:"鹤岗市",children:[{value:"230402",label:"向阳区"},{value:"230403",label:"工农区"},{value:"230404",label:"南山区"},{value:"230405",label:"兴安区"},{value:"230406",label:"东山区"},{value:"230407",label:"兴山区"},{value:"230421",label:"萝北县"},{value:"230422",label:"绥滨县"}]},{value:"230500",label:"双鸭山市",children:[{value:"230502",label:"尖山区"},{value:"230503",label:"岭东区"},{value:"230505",label:"四方台区"},{value:"230506",label:"宝山区"},{value:"230521",label:"集贤县"},{value:"230522",label:"友谊县"},{value:"230523",label:"宝清县"},{value:"230524",label:"饶河县"}]},{value:"230600",label:"大庆市",children:[{value:"230602",label:"萨尔图区"},{value:"230603",label:"龙凤区"},{value:"230604",label:"让胡路区"},{value:"230605",label:"红岗区"},{value:"230606",label:"大同区"},{value:"230621",label:"肇州县"},{value:"230622",label:"肇源县"},{value:"230623",label:"林甸县"},{value:"230624",label:"杜尔伯特蒙古族自治县"},{value:"230671",label:"大庆高新技术产业开发区"}]},{value:"230700",label:"伊春市",children:[{value:"230702",label:"伊春区"},{value:"230703",label:"南岔区"},{value:"230704",label:"友好区"},{value:"230705",label:"西林区"},{value:"230706",label:"翠峦区"},{value:"230707",label:"新青区"},{value:"230708",label:"美溪区"},{value:"230709",label:"金山屯区"},{value:"230710",label:"五营区"},{value:"230711",label:"乌马河区"},{value:"230712",label:"汤旺河区"},{value:"230713",label:"带岭区"},{value:"230714",label:"乌伊岭区"},{value:"230715",label:"红星区"},{value:"230716",label:"上甘岭区"},{value:"230722",label:"嘉荫县"},{value:"230781",label:"铁力市"}]},{value:"230800",label:"佳木斯市",children:[{value:"230803",label:"向阳区"},{value:"230804",label:"前进区"},{value:"230805",label:"东风区"},{value:"230811",label:"郊区"},{value:"230822",label:"桦南县"},{value:"230826",label:"桦川县"},{value:"230828",label:"汤原县"},{value:"230833",label:"抚远市"},{value:"230881",label:"同江市"},{value:"230882",label:"富锦市"}]},{value:"230900",label:"七台河市",children:[{value:"230902",label:"新兴区"},{value:"230903",label:"桃山区"},{value:"230904",label:"茄子河区"},{value:"230921",label:"勃利县"}]},{value:"231000",label:"牡丹江市",children:[{value:"231002",label:"东安区"},{value:"231003",label:"阳明区"},{value:"231004",label:"爱民区"},{value:"231005",label:"西安区"},{value:"231086",label:"东宁市"},{value:"231025",label:"林口县"},{value:"231081",label:"绥芬河市"},{value:"231083",label:"海林市"},{value:"231084",label:"宁安市"},{value:"231085",label:"穆棱市"},{value:"231071",label:"牡丹江经济技术开发区"}]},{value:"231100",label:"黑河市",children:[{value:"231102",label:"爱辉区"},{value:"231121",label:"嫩江县"},{value:"231123",label:"逊克县"},{value:"231124",label:"孙吴县"},{value:"231181",label:"北安市"},{value:"231182",label:"五大连池市"}]},{value:"231200",label:"绥化市",children:[{value:"231202",label:"北林区"},{value:"231221",label:"望奎县"},{value:"231222",label:"兰西县"},{value:"231223",label:"青冈县"},{value:"231224",label:"庆安县"},{value:"231225",label:"明水县"},{value:"231226",label:"绥棱县"},{value:"231281",label:"安达市"},{value:"231282",label:"肇东市"},{value:"231283",label:"海伦市"}]},{value:"232700",label:"大兴安岭地区",children:[{value:"232721",label:"呼玛县"},{value:"232722",label:"塔河县"},{value:"232723",label:"漠河县"},{value:"232701",label:"加格达奇区"},{value:"232704",label:"呼中区"},{value:"232703",label:"新林区"}]}]},{value:'310000',label:'上海市',children:[{value:'310100',label:'上海市',children:[{value:"310101",label:"黄浦区"},{value:"310104",label:"徐汇区"},{value:"310105",label:"长宁区"},{value:"310106",label:"静安区"},{value:"310107",label:"普陀区"},{value:"310109",label:"虹口区"},{value:"310110",label:"杨浦区"},{value:"310112",label:"闵行区"},{value:"310113",label:"宝山区"},{value:"310114",label:"嘉定区"},{value:"310115",label:"浦东新区"},{value:"310116",label:"金山区"},{value:"310117",label:"松江区"},{value:"310118",label:"青浦区"},{value:"310120",label:"奉贤区"},{value:"310151",label:"崇明区"}]}]},{value:'320000',label:'江苏省',children:[{value:"320100",label:"南京市",children:[{value:"320102",label:"玄武区"},{value:"320104",label:"秦淮区"},{value:"320105",label:"建邺区"},{value:"320106",label:"鼓楼区"},{value:"320111",label:"浦口区"},{value:"320113",label:"栖霞区"},{value:"320114",label:"雨花台区"},{value:"320115",label:"江宁区"},{value:"320116",label:"六合区"},{value:"320117",label:"溧水区"},{value:"320118",label:"高淳区"}]},{value:"320200",label:"无锡市",children:[{value:"320205",label:"锡山区"},{value:"320206",label:"惠山区"},{value:"320211",label:"滨湖区"},{value:"320281",label:"江阴市"},{value:"320282",label:"宜兴市"},{value:"320213",label:"梁溪区"},{value:"320214",label:"新吴区"}]},{value:"320300",label:"徐州市",children:[{value:"320302",label:"鼓楼区"},{value:"320303",label:"云龙区"},{value:"320305",label:"贾汪区"},{value:"320311",label:"泉山区"},{value:"320321",label:"丰县"},{value:"320322",label:"沛县"},{value:"320324",label:"睢宁县"},{value:"320381",label:"新沂市"},{value:"320382",label:"邳州市"},{value:"320371",label:"徐州经济技术开发区"}]},{value:"320400",label:"常州市",children:[{value:"320402",label:"天宁区"},{value:"320404",label:"钟楼区"},{value:"320411",label:"新北区"},{value:"320412",label:"武进区"},{value:"320481",label:"溧阳市"},{value:"320413",label:"金坛区"}]},{value:"320500",label:"苏州市",children:[{value:"320505",label:"虎丘区"},{value:"320506",label:"吴中区"},{value:"320507",label:"相城区"},{value:"320581",label:"常熟市"},{value:"320582",label:"张家港市"},{value:"320583",label:"昆山市"},{value:"320509",label:"吴江区"},{value:"320585",label:"太仓市"},{value:"320508",label:"姑苏区"},{value:"320571",label:"苏州工业园区"}]},{value:"320600",label:"南通市",children:[{value:"320602",label:"崇川区"},{value:"320611",label:"港闸区"},{value:"320612",label:"通州区"},{value:"320621",label:"海安县"},{value:"320623",label:"如东县"},{value:"320681",label:"启东市"},{value:"320682",label:"如皋市"},{value:"320684",label:"海门市"},{value:"320671",label:"南通经济技术开发区"}]},{value:"320700",label:"连云港市",children:[{value:"320703",label:"连云区"},{value:"320706",label:"海州区"},{value:"320707",label:"赣榆区"},{value:"320722",label:"东海县"},{value:"320723",label:"灌云县"},{value:"320724",label:"灌南县"},{value:"320771",label:"连云港经济技术开发区"},{value:"320772",label:"连云港高新技术产业开发区"}]},{value:"320800",label:"淮安市",children:[{value:"320804",label:"淮阴区"},{value:"320812",label:"清江浦区"},{value:"320826",label:"涟水县"},{value:"320813",label:"洪泽区"},{value:"320830",label:"盱眙县"},{value:"320831",label:"金湖县"},{value:"320803",label:"淮安区"},{value:"320871",label:"淮安经济技术开发区"}]},{value:"320900",label:"盐城市",children:[{value:"320902",label:"亭湖区"},{value:"320903",label:"盐都区"},{value:"320921",label:"响水县"},{value:"320922",label:"滨海县"},{value:"320904",label:"大丰区"},{value:"320923",label:"阜宁县"},{value:"320924",label:"射阳县"},{value:"320925",label:"建湖县"},{value:"320981",label:"东台市"},{value:"320971",label:"盐城经济技术开发区"}]},{value:"321000",label:"扬州市",children:[{value:"321002",label:"广陵区"},{value:"321003",label:"邗江区"},{value:"321011",label:"维扬区"},{value:"321023",label:"宝应县"},{value:"321081",label:"仪征市"},{value:"321084",label:"高邮市"},{value:"321012",label:"江都区"},{value:"321071",label:"扬州经济技术开发区"}]},{value:"321100",label:"镇江市",children:[{value:"321102",label:"京口区"},{value:"321111",label:"润州区"},{value:"321112",label:"丹徒区"},{value:"321181",label:"丹阳市"},{value:"321182",label:"扬中市"},{value:"321183",label:"句容市"},{value:"321171",label:"镇江新区"}]},{value:"321200",label:"泰州市",children:[{value:"321202",label:"海陵区"},{value:"321203",label:"高港区"},{value:"321281",label:"兴化市"},{value:"321282",label:"靖江市"},{value:"321283",label:"泰兴市"},{value:"321204",label:"姜堰区"},{value:"321271",label:"泰州医药高新技术产业开发区"}]},{value:"321300",label:"宿迁市",children:[{value:"321302",label:"宿城区"},{value:"321311",label:"宿豫区"},{value:"321322",label:"沭阳县"},{value:"321323",label:"泗阳县"},{value:"321324",label:"泗洪县"}]}]},{value:'330000',label:'浙江省',children:[{value:"330100",label:"杭州市",children:[{value:"330102",label:"上城区"},{value:"330103",label:"下城区"},{value:"330104",label:"江干区"},{value:"330105",label:"拱墅区"},{value:"330106",label:"西湖区"},{value:"330108",label:"滨江区"},{value:"330109",label:"萧山区"},{value:"330110",label:"余杭区"},{value:"330122",label:"桐庐县"},{value:"330127",label:"淳安县"},{value:"330182",label:"建德市"},{value:"330111",label:"富阳区"},{value:"330112",label:"临安区"},{value:"330186",label:"其它区"}]},{value:"330200",label:"宁波市",children:[{value:"330203",label:"海曙区"},{value:"330205",label:"江北区"},{value:"330206",label:"北仑区"},{value:"330211",label:"镇海区"},{value:"330212",label:"鄞州区"},{value:"330225",label:"象山县"},{value:"330226",label:"宁海县"},{value:"330281",label:"余姚市"},{value:"330282",label:"慈溪市"},{value:"330213",label:"奉化区"}]},{value:"330300",label:"温州市",children:[{value:"330302",label:"鹿城区"},{value:"330303",label:"龙湾区"},{value:"330304",label:"瓯海区"},{value:"330305",label:"洞头区"},{value:"330324",label:"永嘉县"},{value:"330326",label:"平阳县"},{value:"330327",label:"苍南县"},{value:"330328",label:"文成县"},{value:"330329",label:"泰顺县"},{value:"330381",label:"瑞安市"},{value:"330382",label:"乐清市"},{value:"330371",label:"温州经济技术开发区"}]},{value:"330400",label:"嘉兴市",children:[{value:"330402",label:"南湖区"},{value:"330411",label:"秀洲区"},{value:"330421",label:"嘉善县"},{value:"330424",label:"海盐县"},{value:"330481",label:"海宁市"},{value:"330482",label:"平湖市"},{value:"330483",label:"桐乡市"}]},{value:"330500",label:"湖州市",children:[{value:"330502",label:"吴兴区"},{value:"330503",label:"南浔区"},{value:"330521",label:"德清县"},{value:"330522",label:"长兴县"},{value:"330523",label:"安吉县"}]},{value:"330600",label:"绍兴市",children:[{value:"330602",label:"越城区"},{value:"330621",label:"柯桥区"},{value:"330681",label:"诸暨市"},{value:"330604",label:"上虞区"},{value:"330683",label:"嵊州市"},{value:"330624",label:"新昌县"}]},{value:"330700",label:"金华市",children:[{value:"330702",label:"婺城区"},{value:"330703",label:"金东区"},{value:"330723",label:"武义县"},{value:"330726",label:"浦江县"},{value:"330727",label:"磐安县"},{value:"330781",label:"兰溪市"},{value:"330782",label:"义乌市"},{value:"330783",label:"东阳市"},{value:"330784",label:"永康市"}]},{value:"330800",label:"衢州市",children:[{value:"330802",label:"柯城区"},{value:"330803",label:"衢江区"},{value:"330822",label:"常山县"},{value:"330824",label:"开化县"},{value:"330825",label:"龙游县"},{value:"330881",label:"江山市"}]},{value:"330900",label:"舟山市",children:[{value:"330902",label:"定海区"},{value:"330903",label:"普陀区"},{value:"330921",label:"岱山县"},{value:"330922",label:"嵊泗县"}]},{value:"331000",label:"台州市",children:[{value:"331002",label:"椒江区"},{value:"331003",label:"黄岩区"},{value:"331004",label:"路桥区"},{value:"331083",label:"玉环市"},{value:"331022",label:"三门县"},{value:"331023",label:"天台县"},{value:"331024",label:"仙居县"},{value:"331081",label:"温岭市"},{value:"331082",label:"临海市"}]},{value:"331100",label:"丽水市",children:[{value:"331102",label:"莲都区"},{value:"331121",label:"青田县"},{value:"331122",label:"缙云县"},{value:"331123",label:"遂昌县"},{value:"331124",label:"松阳县"},{value:"331125",label:"云和县"},{value:"331126",label:"庆元县"},{value:"331127",label:"景宁畲族自治县"},{value:"331181",label:"龙泉市"}]}]},{value:'340000',label:'安徽省',children:[{value:"340100",label:"合肥市",children:[{value:"340111",label:"包河区"},{value:"340104",label:"蜀山区"},{value:"340103",label:"庐阳区"},{value:"340102",label:"瑶海区"},{value:"340171",label:"合肥高新技术产业开发区"},{value:"340172",label:"合肥经济技术开发区"},{value:"340173",label:"合肥新站高新技术产业开发区"},{value:"340121",label:"长丰县"},{value:"340122",label:"肥东县"},{value:"340123",label:"肥西县"},{value:"340124",label:"庐江县"},{value:"340181",label:"巢湖市"}]},{value:"340200",label:"芜湖市",children:[{value:"340202",label:"镜湖区"},{value:"340203",label:"弋江区"},{value:"340207",label:"鸠江区"},{value:"340208",label:"三山区"},{value:"340221",label:"芜湖县"},{value:"340222",label:"繁昌县"},{value:"340223",label:"南陵县"},{value:"340225",label:"无为县"},{value:"340272",label:"安徽芜湖长江大桥经济开发区"},{value:"340271",label:"芜湖经济技术开发区"}]},{value:"340300",label:"蚌埠市",children:[{value:"340302",label:"龙子湖区"},{value:"340303",label:"蚌山区"},{value:"340304",label:"禹会区"},{value:"340311",label:"淮上区"},{value:"340321",label:"怀远县"},{value:"340322",label:"五河县"},{value:"340323",label:"固镇县"},{value:"340371",label:"蚌埠市高新技术开发区"},{value:"340372 ",label:"蚌埠市经济开发区"}]},{value:"340400",label:"淮南市",children:[{value:"340402",label:"大通区"},{value:"340403",label:"田家庵区"},{value:"340404",label:"谢家集区"},{value:"340405",label:"八公山区"},{value:"340406",label:"潘集区"},{value:"340421",label:"凤台县"},{value:"340422",label:"寿县"}]},{value:"340500",label:"马鞍山市",children:[{value:"340503",label:"花山区"},{value:"340504",label:"雨山区"},{value:"340521",label:"当涂县"},{value:"340506",label:"博望区"},{value:"340522",label:"含山县"},{value:"340523",label:"和县"}]},{value:"340600",label:"淮北市",children:[{value:"340602",label:"杜集区"},{value:"340603",label:"相山区"},{value:"340604",label:"烈山区"},{value:"340621",label:"濉溪县"}]},{value:"340700",label:"铜陵市",children:[{value:"340705",label:"铜官区"},{value:"340706",label:"义安区"},{value:"340711",label:"郊区"},{value:"340722",label:"枞阳县"}]},{value:"340800",label:"安庆市",children:[{value:"340802",label:"迎江区"},{value:"340803",label:"大观区"},{value:"340811",label:"宜秀区"},{value:"340822",label:"怀宁县"},{value:"340824",label:"潜山县"},{value:"340825",label:"太湖县"},{value:"340826",label:"宿松县"},{value:"340827",label:"望江县"},{value:"340828",label:"岳西县"},{value:"340881",label:"桐城市"},{value:"340871",label:"安徽安庆经济开发区"}]},{value:"341000",label:"黄山市",children:[{value:"341002",label:"屯溪区"},{value:"341003",label:"黄山区"},{value:"341004",label:"徽州区"},{value:"341021",label:"歙县"},{value:"341022",label:"休宁县"},{value:"341023",label:"黟县"},{value:"341024",label:"祁门县"}]},{value:"341100",label:"滁州市",children:[{value:"341102",label:"琅琊区"},{value:"341103",label:"南谯区"},{value:"341122",label:"来安县"},{value:"341124",label:"全椒县"},{value:"341125",label:"定远县"},{value:"341126",label:"凤阳县"},{value:"341181",label:"天长市"},{value:"341182",label:"明光市"},{value:"341171",label:"苏滁现代产业园"},{value:"341172",label:"滁州经济技术开发区"}]},{value:"341200",label:"阜阳市",children:[{value:"341202",label:"颍州区"},{value:"341203",label:"颍东区"},{value:"341204",label:"颍泉区"},{value:"341221",label:"临泉县"},{value:"341222",label:"太和县"},{value:"341225",label:"阜南县"},{value:"341226",label:"颍上县"},{value:"341282",label:"界首市"},{value:"341272",label:"阜阳经济技术开发区"},{value:"341271",label:"阜阳合肥现代产业园区"}]},{value:"341300",label:"宿州市",children:[{value:"341302",label:"埇桥区"},{value:"341321",label:"砀山县"},{value:"341322",label:"萧县"},{value:"341323",label:"灵璧县"},{value:"341324",label:"泗县"},{value:"341371",label:"宿州马鞍山现代产业园区"},{value:"341372",label:"宿州经济技术开发区"}]},{value:"341500",label:"六安市",children:[{value:"341502",label:"金安区"},{value:"341503",label:"裕安区"},{value:"341504",label:"叶集区"},{value:"341522",label:"霍邱县"},{value:"341523",label:"舒城县"},{value:"341524",label:"金寨县"},{value:"341525",label:"霍山县"}]},{value:"341600",label:"亳州市",children:[{value:"341602",label:"谯城区"},{value:"341621",label:"涡阳县"},{value:"341622",label:"蒙城县"},{value:"341623",label:"利辛县"}]},{value:"341700",label:"池州市",children:[{value:"341702",label:"贵池区"},{value:"341721",label:"东至县"},{value:"341722",label:"石台县"},{value:"341723",label:"青阳县"}]},{value:"341800",label:"宣城市",children:[{value:"341802",label:"宣州区"},{value:"341821",label:"郎溪县"},{value:"341822",label:"广德县"},{value:"341823",label:"泾县"},{value:"341824",label:"绩溪县"},{value:"341825",label:"旌德县"},{value:"341881",label:"宁国市"},{value:"341871",label:"宣城市经济开发区"}]}]},{value:'350000',label:'福建省',children:[{value:"350100",label:"福州市",children:[{value:"350102",label:"鼓楼区"},{value:"350103",label:"台江区"},{value:"350104",label:"仓山区"},{value:"350105",label:"马尾区"},{value:"350111",label:"晋安区"},{value:"350121",label:"闽侯县"},{value:"350122",label:"连江县"},{value:"350123",label:"罗源县"},{value:"350124",label:"闽清县"},{value:"350125",label:"永泰县"},{value:"350128",label:"平潭县"},{value:"350181",label:"福清市"},{value:"350182",label:"长乐市"}]},{value:"350200",label:"厦门市",children:[{value:"350203",label:"思明区"},{value:"350205",label:"海沧区"},{value:"350206",label:"湖里区"},{value:"350211",label:"集美区"},{value:"350212",label:"同安区"},{value:"350213",label:"翔安区"}]},{value:"350300",label:"莆田市",children:[{value:"350302",label:"城厢区"},{value:"350303",label:"涵江区"},{value:"350304",label:"荔城区"},{value:"350305",label:"秀屿区"},{value:"350322",label:"仙游县"}]},{value:"350400",label:"三明市",children:[{value:"350402",label:"梅列区"},{value:"350403",label:"三元区"},{value:"350421",label:"明溪县"},{value:"350423",label:"清流县"},{value:"350424",label:"宁化县"},{value:"350425",label:"大田县"},{value:"350426",label:"尤溪县"},{value:"350427",label:"沙县"},{value:"350428",label:"将乐县"},{value:"350429",label:"泰宁县"},{value:"350430",label:"建宁县"},{value:"350481",label:"永安市"}]},{value:"350500",label:"泉州市",children:[{value:"350502",label:"鲤城区"},{value:"350503",label:"丰泽区"},{value:"350504",label:"洛江区"},{value:"350505",label:"泉港区"},{value:"350521",label:"惠安县"},{value:"350524",label:"安溪县"},{value:"350525",label:"永春县"},{value:"350526",label:"德化县"},{value:"350527",label:"金门县"},{value:"350581",label:"石狮市"},{value:"350582",label:"晋江市"},{value:"350583",label:"南安市"}]},{value:"350600",label:"漳州市",children:[{value:"350602",label:"芗城区"},{value:"350603",label:"龙文区"},{value:"350622",label:"云霄县"},{value:"350623",label:"漳浦县"},{value:"350624",label:"诏安县"},{value:"350625",label:"长泰县"},{value:"350626",label:"东山县"},{value:"350627",label:"南靖县"},{value:"350628",label:"平和县"},{value:"350629",label:"华安县"},{value:"350681",label:"龙海市"}]},{value:"350700",label:"南平市",children:[{value:"350702",label:"延平区"},{value:"350721",label:"顺昌县"},{value:"350722",label:"浦城县"},{value:"350723",label:"光泽县"},{value:"350724",label:"松溪县"},{value:"350725",label:"政和县"},{value:"350781",label:"邵武市"},{value:"350782",label:"武夷山市"},{value:"350783",label:"建瓯市"},{value:"350703",label:"建阳区"}]},{value:"350800",label:"龙岩市",children:[{value:"350802",label:"新罗区"},{value:"350821",label:"长汀县"},{value:"350803",label:"永定区"},{value:"350823",label:"上杭县"},{value:"350824",label:"武平县"},{value:"350825",label:"连城县"},{value:"350881",label:"漳平市"}]},{value:"350900",label:"宁德市",children:[{value:"350902",label:"蕉城区"},{value:"350921",label:"霞浦县"},{value:"350922",label:"古田县"},{value:"350923",label:"屏南县"},{value:"350924",label:"寿宁县"},{value:"350925",label:"周宁县"},{value:"350926",label:"柘荣县"},{value:"350981",label:"福安市"},{value:"350982",label:"福鼎市"}]}]},{value:'360000',label:'江西省',children:[{value:"360100",label:"南昌市",children:[{value:"360102",label:"东湖区"},{value:"360103",label:"西湖区"},{value:"360104",label:"青云谱区"},{value:"360105",label:"湾里区"},{value:"360111",label:"青山湖区"},{value:"360121",label:"南昌县"},{value:"360112",label:"新建区"},{value:"360123",label:"安义县"},{value:"360124",label:"进贤县"}]},{value:"360200",label:"景德镇市",children:[{value:"360202",label:"昌江区"},{value:"360203",label:"珠山区"},{value:"360222",label:"浮梁县"},{value:"360281",label:"乐平市"}]},{value:"360300",label:"萍乡市",children:[{value:"360302",label:"安源区"},{value:"360313",label:"湘东区"},{value:"360321",label:"莲花县"},{value:"360322",label:"上栗县"},{value:"360323",label:"芦溪县"}]},{value:"360400",label:"九江市",children:[{value:"360402",label:"濂溪区"},{value:"360403",label:"浔阳区"},{value:"360404",label:"柴桑区"},{value:"360423",label:"武宁县"},{value:"360424",label:"修水县"},{value:"360425",label:"永修县"},{value:"360426",label:"德安县"},{value:"360428",label:"都昌县"},{value:"360429",label:"湖口县"},{value:"360430",label:"彭泽县"},{value:"360481",label:"瑞昌市"},{value:"360482",label:"共青城市"},{value:"360483",label:"庐山市"}]},{value:"360500",label:"新余市",children:[{value:"360502",label:"渝水区"},{value:"360521",label:"分宜县"}]},{value:"360600",label:"鹰潭市",children:[{value:"360602",label:"月湖区"},{value:"360622",label:"余江县"},{value:"360681",label:"贵溪市"}]},{value:"360700",label:"赣州市",children:[{value:"360702",label:"章贡区"},{value:"360704",label:"赣县区"},{value:"360722",label:"信丰县"},{value:"360723",label:"大余县"},{value:"360724",label:"上犹县"},{value:"360725",label:"崇义县"},{value:"360726",label:"安远县"},{value:"360727",label:"龙南县"},{value:"360728",label:"定南县"},{value:"360729",label:"全南县"},{value:"360730",label:"宁都县"},{value:"360731",label:"于都县"},{value:"360732",label:"兴国县"},{value:"360733",label:"会昌县"},{value:"360734",label:"寻乌县"},{value:"360735",label:"石城县"},{value:"360781",label:"瑞金市"},{value:"360703",label:"南康区"}]},{value:"360800",label:"吉安市",children:[{value:"360802",label:"吉州区"},{value:"360803",label:"青原区"},{value:"360821",label:"吉安县"},{value:"360822",label:"吉水县"},{value:"360823",label:"峡江县"},{value:"360824",label:"新干县"},{value:"360825",label:"永丰县"},{value:"360826",label:"泰和县"},{value:"360827",label:"遂川县"},{value:"360828",label:"万安县"},{value:"360829",label:"安福县"},{value:"360830",label:"永新县"},{value:"360881",label:"井冈山市"}]},{value:"360900",label:"宜春市",children:[{value:"360902",label:"袁州区"},{value:"360921",label:"奉新县"},{value:"360922",label:"万载县"},{value:"360923",label:"上高县"},{value:"360924",label:"宜丰县"},{value:"360925",label:"靖安县"},{value:"360926",label:"铜鼓县"},{value:"360981",label:"丰城市"},{value:"360982",label:"樟树市"},{value:"360983",label:"高安市"}]},{value:"361000",label:"抚州市",children:[{value:"361002",label:"临川区"},{value:"361021",label:"南城县"},{value:"361022",label:"黎川县"},{value:"361023",label:"南丰县"},{value:"361024",label:"崇仁县"},{value:"361025",label:"乐安县"},{value:"361026",label:"宜黄县"},{value:"361027",label:"金溪县"},{value:"361028",label:"资溪县"},{value:"361003",label:"东乡区"},{value:"361030",label:"广昌县"}]},{value:"361100",label:"上饶市",children:[{value:"361102",label:"信州区"},{value:"361121",label:"上饶县"},{value:"361103",label:"广丰区"},{value:"361123",label:"玉山县"},{value:"361124",label:"铅山县"},{value:"361125",label:"横峰县"},{value:"361126",label:"弋阳县"},{value:"361127",label:"余干县"},{value:"361128",label:"鄱阳县"},{value:"361129",label:"万年县"},{value:"361130",label:"婺源县"},{value:"361181",label:"德兴市"}]}]},{value:'370000',label:'山东省',children:[{value:"370100",label:"济南市",children:[{value:"370102",label:"历下区"},{value:"370103",label:"市中区"},{value:"370104",label:"槐荫区"},{value:"370105",label:"天桥区"},{value:"370112",label:"历城区"},{value:"370113",label:"长清区"},{value:"370124",label:"平阴县"},{value:"370125",label:"济阳县"},{value:"370126",label:"商河县"},{value:"370114",label:"章丘区"},{value:"370171",label:"济南高新技术产业开发区"}]},{value:"370200",label:"青岛市",children:[{value:"370202",label:"市南区"},{value:"370203",label:"市北区"},{value:"370211",label:"黄岛区"},{value:"370212",label:"崂山区"},{value:"370213",label:"李沧区"},{value:"370214",label:"城阳区"},{value:"370281",label:"胶州市"},{value:"370215",label:"即墨区"},{value:"370283",label:"平度市"},{value:"370285",label:"莱西市"},{value:"370271",label:"青岛高新技术产业开发区"}]},{value:"370300",label:"淄博市",children:[{value:"370302",label:"淄川区"},{value:"370303",label:"张店区"},{value:"370304",label:"博山区"},{value:"370305",label:"临淄区"},{value:"370306",label:"周村区"},{value:"370321",label:"桓台县"},{value:"370322",label:"高青县"},{value:"370323",label:"沂源县"}]},{value:"370400",label:"枣庄市",children:[{value:"370402",label:"市中区"},{value:"370403",label:"薛城区"},{value:"370404",label:"峄城区"},{value:"370405",label:"台儿庄区"},{value:"370406",label:"山亭区"},{value:"370481",label:"滕州市"}]},{value:"370500",label:"东营市",children:[{value:"370502",label:"东营区"},{value:"370503",label:"河口区"},{value:"370521",label:"垦利县"},{value:"370522",label:"利津县"},{value:"370523",label:"广饶县"},{value:"370589",label:"西城区"},{value:"370571",label:"东营经济技术开发区"},{value:"370572",label:"东营港经济开发区"}]},{value:"370600",label:"烟台市",children:[{value:"370602",label:"芝罘区"},{value:"370611",label:"福山区"},{value:"370612",label:"牟平区"},{value:"370613",label:"莱山区"},{value:"370634",label:"长岛县"},{value:"370681",label:"龙口市"},{value:"370682",label:"莱阳市"},{value:"370683",label:"莱州市"},{value:"370684",label:"蓬莱市"},{value:"370685",label:"招远市"},{value:"370686",label:"栖霞市"},{value:"370687",label:"海阳市"},{value:"370671",label:"烟台高新技术产业开发区"},{value:"370672",label:"烟台经济技术开发区"}]},{value:"370700",label:"潍坊市",children:[{value:"370702",label:"潍城区"},{value:"370703",label:"寒亭区"},{value:"370704",label:"坊子区"},{value:"370705",label:"奎文区"},{value:"370724",label:"临朐县"},{value:"370725",label:"昌乐县"},{value:"370772",label:"潍坊滨海经济技术开发区"},{value:"370781",label:"青州市"},{value:"370782",label:"诸城市"},{value:"370783",label:"寿光市"},{value:"370784",label:"安丘市"},{value:"370785",label:"高密市"},{value:"370786",label:"昌邑市"}]},{value:"370800",label:"济宁市",children:[{value:"370811",label:"任城区"},{value:"370826",label:"微山县"},{value:"370827",label:"鱼台县"},{value:"370828",label:"金乡县"},{value:"370829",label:"嘉祥县"},{value:"370830",label:"汶上县"},{value:"370831",label:"泗水县"},{value:"370832",label:"梁山县"},{value:"370881",label:"曲阜市"},{value:"370812",label:"兖州区"},{value:"370883",label:"邹城市"},{value:"370871",label:"济宁高新技术产业开发区"}]},{value:"370900",label:"泰安市",children:[{value:"370902",label:"泰山区"},{value:"370903",label:"岱岳区"},{value:"370921",label:"宁阳县"},{value:"370923",label:"东平县"},{value:"370982",label:"新泰市"},{value:"370983",label:"肥城市"}]},{value:"371000",label:"威海市",children:[{value:"371002",label:"环翠区"},{value:"371003",label:"文登区"},{value:"371082",label:"荣成市"},{value:"371083",label:"乳山市"},{value:"371071",label:"威海火炬高技术产业开发区"},{value:"371072",label:"威海经济技术开发区"},{value:"371073",label:"威海临港经济技术开发区"}]},{value:"371100",label:"日照市",children:[{value:"371102",label:"东港区"},{value:"371103",label:"岚山区"},{value:"371121",label:"五莲县"},{value:"371122",label:"莒县"},{value:"371171",label:"日照经济技术开发区"},{value:"371172",label:"日照国际海洋城"}]},{value:"371200",label:"莱芜市",children:[{value:"371202",label:"莱城区"},{value:"371203",label:"钢城区"}]},{value:"371300",label:"临沂市",children:[{value:"371302",label:"兰山区"},{value:"371311",label:"罗庄区"},{value:"371312",label:"河东区"},{value:"371321",label:"沂南县"},{value:"371322",label:"郯城县"},{value:"371323",label:"沂水县"},{value:"371324",label:"兰陵县"},{value:"371325",label:"费县"},{value:"371326",label:"平邑县"},{value:"371327",label:"莒南县"},{value:"371328",label:"蒙阴县"},{value:"371329",label:"临沭县"},{value:"371371",label:"临沂高新技术产业开发区"},{value:"371373",label:"临沂临港经济开发区"},{value:"371372",label:"临沂经济技术开发区"}]},{value:"371400",label:"德州市",children:[{value:"371402",label:"德城区"},{value:"371403",label:"陵城区"},{value:"371422",label:"宁津县"},{value:"371423",label:"庆云县"},{value:"371424",label:"临邑县"},{value:"371425",label:"齐河县"},{value:"371426",label:"平原县"},{value:"371427",label:"夏津县"},{value:"371428",label:"武城县"},{value:"371481",label:"乐陵市"},{value:"371482",label:"禹城市"},{value:"371471",label:"德州经济技术开发区"},{value:"371472",label:"德州运河经济开发区"}]},{value:"371500",label:"聊城市",children:[{value:"371502",label:"东昌府区"},{value:"371521",label:"阳谷县"},{value:"371522",label:"莘县"},{value:"371523",label:"茌平县"},{value:"371524",label:"东阿县"},{value:"371525",label:"冠县"},{value:"371526",label:"高唐县"},{value:"371581",label:"临清市"}]},{value:"371600",label:"滨州市",children:[{value:"371602",label:"滨城区"},{value:"371621",label:"惠民县"},{value:"371622",label:"阳信县"},{value:"371623",label:"无棣县"},{value:"371603",label:"沾化区"},{value:"371625",label:"博兴县"},{value:"371626",label:"邹平县"}]},{value:"371700",label:"菏泽市",children:[{value:"371702",label:"牡丹区"},{value:"371721",label:"曹县"},{value:"371722",label:"单县"},{value:"371723",label:"成武县"},{value:"371724",label:"巨野县"},{value:"371725",label:"郓城县"},{value:"371726",label:"鄄城县"},{value:"371727",label:"定陶区"},{value:"371728",label:"东明县"},{value:"371771",label:"菏泽经济技术开发区"},{value:"371772",label:"菏泽高新技术开发区"}]}]},{value:'410000',label:'河南省',children:[{value:"410100",label:"郑州市",children:[{value:"410102",label:"中原区"},{value:"410103",label:"二七区"},{value:"410104",label:"管城回族区"},{value:"410105",label:"金水区"},{value:"410106",label:"上街区"},{value:"410108",label:"惠济区"},{value:"410122",label:"中牟县"},{value:"410181",label:"巩义市"},{value:"410182",label:"荥阳市"},{value:"410183",label:"新密市"},{value:"410184",label:"新郑市"},{value:"410185",label:"登封市"},{value:"410171",label:"郑州经济技术开发区"},{value:"410172",label:"郑州高新技术产业开发区"},{value:"410173",label:"郑州航空港经济综合实验区"}]},{value:"410200",label:"开封市",children:[{value:"410202",label:"龙亭区"},{value:"410203",label:"顺河回族区"},{value:"410204",label:"鼓楼区"},{value:"410205",label:"禹王台区"},{value:"410211",label:"金明区"},{value:"410221",label:"杞县"},{value:"410222",label:"通许县"},{value:"410223",label:"尉氏县"},{value:"410225",label:"兰考县"},{value:"410212",label:"祥符区"}]},{value:"410300",label:"洛阳市",children:[{value:"410302",label:"老城区"},{value:"410303",label:"西工区"},{value:"410304",label:"廛河回族区"},{value:"410305",label:"涧西区"},{value:"410306",label:"吉利区"},{value:"410307",label:"洛龙区"},{value:"410322",label:"孟津县"},{value:"410323",label:"新安县"},{value:"410324",label:"栾川县"},{value:"410325",label:"嵩县"},{value:"410326",label:"汝阳县"},{value:"410327",label:"宜阳县"},{value:"410328",label:"洛宁县"},{value:"410329",label:"伊川县"},{value:"410381",label:"偃师市"},{value:"410371",label:"洛阳高新技术产业开发区"},{value:"471005",label:"其它区"}]},{value:"410400",label:"平顶山市",children:[{value:"410402",label:"新华区"},{value:"410403",label:"卫东区"},{value:"410404",label:"石龙区"},{value:"410411",label:"湛河区"},{value:"410421",label:"宝丰县"},{value:"410422",label:"叶县"},{value:"410423",label:"鲁山县"},{value:"410425",label:"郏县"},{value:"410481",label:"舞钢市"},{value:"410482",label:"汝州市"},{value:"410471",label:"平顶山高新技术产业开发区"},{value:"410472",label:"平顶山市新城区"}]},{value:"410500",label:"安阳市",children:[{value:"410502",label:"文峰区"},{value:"410503",label:"北关区"},{value:"410505",label:"殷都区"},{value:"410506",label:"龙安区"},{value:"410522",label:"安阳县"},{value:"410523",label:"汤阴县"},{value:"410526",label:"滑县"},{value:"410527",label:"内黄县"},{value:"410581",label:"林州市"},{value:"410571",label:"安阳高新技术产业开发区"}]},{value:"410600",label:"鹤壁市",children:[{value:"410602",label:"鹤山区"},{value:"410603",label:"山城区"},{value:"410611",label:"淇滨区"},{value:"410621",label:"浚县"},{value:"410622",label:"淇县"},{value:"410671",label:"鹤壁经济技术开发区"}]},{value:"410700",label:"新乡市",children:[{value:"410702",label:"红旗区"},{value:"410703",label:"卫滨区"},{value:"410704",label:"凤泉区"},{value:"410711",label:"牧野区"},{value:"410721",label:"新乡县"},{value:"410724",label:"获嘉县"},{value:"410725",label:"原阳县"},{value:"410726",label:"延津县"},{value:"410727",label:"封丘县"},{value:"410728",label:"长垣县"},{value:"410781",label:"卫辉市"},{value:"410782",label:"辉县市"},{value:"410771",label:"新乡高新技术产业开发区"},{value:"410773",label:"新乡市平原城乡一体化示范区"},{value:"410772",label:"新乡经济技术开发区"}]},{value:"410800",label:"焦作市",children:[{value:"410802",label:"解放区"},{value:"410803",label:"中站区"},{value:"410804",label:"马村区"},{value:"410811",label:"山阳区"},{value:"410821",label:"修武县"},{value:"410822",label:"博爱县"},{value:"410823",label:"武陟县"},{value:"410825",label:"温县"},{value:"410882",label:"沁阳市"},{value:"410883",label:"孟州市"},{value:"410871",label:"焦作城乡一体化示范区"}]},{value:"410900",label:"濮阳市",children:[{value:"410902",label:"华龙区"},{value:"410922",label:"清丰县"},{value:"410923",label:"南乐县"},{value:"410926",label:"范县"},{value:"410927",label:"台前县"},{value:"410928",label:"濮阳县"},{value:"410971",label:"河南濮阳工业园区"},{value:"410972",label:"濮阳经济技术开发区"}]},{value:"411000",label:"许昌市",children:[{value:"411002",label:"魏都区"},{value:"411003",label:"建安区"},{value:"411024",label:"鄢陵县"},{value:"411025",label:"襄城县"},{value:"411081",label:"禹州市"},{value:"411082",label:"长葛市"},{value:"411071",label:"许昌经济技术开发区"}]},{value:"411100",label:"漯河市",children:[{value:"411102",label:"源汇区"},{value:"411103",label:"郾城区"},{value:"411104",label:"召陵区"},{value:"411121",label:"舞阳县"},{value:"411122",label:"临颍县"},{value:"411171",label:"漯河经济技术开发区"}]},{value:"411200",label:"三门峡市",children:[{value:"411202",label:"湖滨区"},{value:"411221",label:"渑池县"},{value:"411222",label:"陕县"},{value:"411224",label:"卢氏县"},{value:"411281",label:"义马市"},{value:"411282",label:"灵宝市"},{value:"411203",label:"陕州区"},{value:"411271",label:"河南三门峡经济开发区"}]},{value:"411300",label:"南阳市",children:[{value:"411302",label:"宛城区"},{value:"411303",label:"卧龙区"},{value:"411321",label:"南召县"},{value:"411322",label:"方城县"},{value:"411323",label:"西峡县"},{value:"411324",label:"镇平县"},{value:"411325",label:"内乡县"},{value:"411326",label:"淅川县"},{value:"411327",label:"社旗县"},{value:"411328",label:"唐河县"},{value:"411329",label:"新野县"},{value:"411330",label:"桐柏县"},{value:"411381",label:"邓州市"},{value:"411371",label:"南阳高新技术产业开发区"},{value:"411372",label:"南阳市城乡一体化示范区"}]},{value:"411400",label:"商丘市",children:[{value:"411402",label:"梁园区"},{value:"411403",label:"睢阳区"},{value:"411421",label:"民权县"},{value:"411422",label:"睢县"},{value:"411423",label:"宁陵县"},{value:"411424",label:"柘城县"},{value:"411425",label:"虞城县"},{value:"411426",label:"夏邑县"},{value:"411481",label:"永城市"},{value:"411471",label:"豫东综合物流产业聚集区"},{value:"411472",label:"河南商丘经济开发"}]},{value:"411500",label:"信阳市",children:[{value:"411502",label:"浉河区"},{value:"411503",label:"平桥区"},{value:"411521",label:"罗山县"},{value:"411522",label:"光山县"},{value:"411523",label:"新县"},{value:"411524",label:"商城县"},{value:"411525",label:"固始县"},{value:"411526",label:"潢川县"},{value:"411527",label:"淮滨县"},{value:"411528",label:"息县"},{value:"411571",label:"信阳高新技术产业开发区"}]},{value:"411600",label:"周口市",children:[{value:"411602",label:"川汇区"},{value:"411621",label:"扶沟县"},{value:"411622",label:"西华县"},{value:"411623",label:"商水县"},{value:"411624",label:"沈丘县"},{value:"411625",label:"郸城县"},{value:"411626",label:"淮阳县"},{value:"411627",label:"太康县"},{value:"411628",label:"鹿邑县"},{value:"411681",label:"项城市"},{value:"411671",label:"河南周口经济开发区"}]},{value:"411700",label:"驻马店市",children:[{value:"411702",label:"驿城区"},{value:"411721",label:"西平县"},{value:"411722",label:"上蔡县"},{value:"411723",label:"平舆县"},{value:"411724",label:"正阳县"},{value:"411725",label:"确山县"},{value:"411726",label:"泌阳县"},{value:"411727",label:"汝南县"},{value:"411628",label:"遂平县"},{value:"411729",label:"新蔡县"},{value:"411771",label:"河南驻马店经济开发区"}]}]},{value:'420000',label:'湖北省',children:[{value:"420100",label:"武汉市",children:[{value:"420101",label:"市辖区"},{value:"420102",label:"江岸区"},{value:"420103",label:"江汉区"},{value:"420104",label:"硚口区"},{value:"420105",label:"汉阳区"},{value:"420106",label:"武昌区"},{value:"420107",label:"青山区"},{value:"420111",label:"洪山区"},{value:"420112",label:"东西湖区"},{value:"420113",label:"汉南区"},{value:"420114",label:"蔡甸区"},{value:"420115",label:"江夏区"},{value:"420116",label:"黄陂区"},{value:"420117",label:"新洲区"}]},{value:"420200",label:"黄石市",children:[{value:"420201",label:"市辖区"},{value:"420202",label:"黄石港区"},{value:"420203",label:"西塞山区"},{value:"420204",label:"下陆区"},{value:"420205",label:"铁山区"},{value:"420222",label:"阳新县"},{value:"420281",label:"大冶市"}]},{value:"420300",label:"十堰市",children:[{value:"420301",label:"市辖区"},{value:"420302",label:"茅箭区"},{value:"420303",label:"张湾区"},{value:"420304",label:"郧阳区"},{value:"420322",label:"郧西县"},{value:"420323",label:"竹山县"},{value:"420324",label:"竹溪县"},{value:"420325",label:"房县"},{value:"420381",label:"丹江口市"}]},{value:"420500",label:"宜昌市",children:[{value:"420501",label:"市辖区"},{value:"420502",label:"西陵区"},{value:"420503",label:"伍家岗区"},{value:"420504",label:"点军区"},{value:"420505",label:"猇亭区"},{value:"420506",label:"夷陵区"},{value:"420525",label:"远安县"},{value:"420526",label:"兴山县"},{value:"420527",label:"秭归县"},{value:"420528",label:"长阳土家族自治县"},{value:"420529",label:"五峰土家族自治县"},{value:"420581",label:"宜都市"},{value:"420582",label:"当阳市"},{value:"420583",label:"枝江市"}]},{value:"420600",label:"襄阳市",children:[{value:"420601",label:"市辖区"},{value:"420602",label:"襄城区"},{value:"420606",label:"樊城区"},{value:"420607",label:"襄州区"},{value:"420624",label:"南漳县"},{value:"420625",label:"谷城县"},{value:"420626",label:"保康县"},{value:"420682",label:"老河口市"},{value:"420683",label:"枣阳市"},{value:"420684",label:"宜城市"}]},{value:"420700",label:"鄂州市",children:[{value:"420701",label:"市辖区"},{value:"420702",label:"梁子湖区"},{value:"420703",label:"华容区"},{value:"420704",label:"鄂城区"}]},{value:"420800",label:"荆门市",children:[{value:"420801",label:"市辖区"},{value:"420802",label:"东宝区"},{value:"420804",label:"掇刀区"},{value:"420821",label:"京山县"},{value:"420822",label:"沙洋县"},{value:"420881",label:"钟祥市"}]},{value:"420900",label:"孝感市",children:[{value:"420901",label:"市辖区"},{value:"420902",label:"孝南区"},{value:"420921",label:"孝昌县"},{value:"420922",label:"大悟县"},{value:"420923",label:"云梦县"},{value:"420981",label:"应城市"},{value:"420982",label:"安陆市"},{value:"420984",label:"汉川市"}]},{value:"421000",label:"荆州市",children:[{value:"421001",label:"市辖区"},{value:"421002",label:"沙市区"},{value:"421003",label:"荆州区"},{value:"421022",label:"公安县"},{value:"421023",label:"监利县"},{value:"421024",label:"江陵县"},{value:"421071",label:"荆州经济技术开发区"},{value:"421081",label:"石首市"},{value:"421083",label:"洪湖市"},{value:"421087",label:"松滋市"}]},{value:"421100",label:"黄冈市",children:[{value:"421101",label:"市辖区"},{value:"421102",label:"黄州区"},{value:"421121",label:"团风县"},{value:"421122",label:"红安县"},{value:"421123",label:"罗田县"},{value:"421124",label:"英山县"},{value:"421125",label:"浠水县"},{value:"421126",label:"蕲春县"},{value:"421127",label:"黄梅县"},{value:"421171",label:"龙感湖管理区"},{value:"421181",label:"麻城市"},{value:"421182",label:"武穴市"}]},{value:"421200",label:"咸宁市",children:[{value:"421201",label:"市辖区"},{value:"421202",label:"咸安区"},{value:"421221",label:"嘉鱼县"},{value:"421222",label:"通城县"},{value:"421223",label:"崇阳县"},{value:"421224",label:"通山县"},{value:"421281",label:"赤壁市"}]},{value:"421300",label:"随州市",children:[{value:"421301",label:"市辖区"},{value:"421303",label:"曾都区"},{value:"421321",label:"随县"},{value:"421381",label:"广水市"}]},{value:"422800",label:"恩施土家族苗族自治州",children:[{value:"422801",label:"恩施市"},{value:"422802",label:"利川市"},{value:"422822",label:"建始县"},{value:"422823",label:"巴东县"},{value:"422825",label:"宣恩县"},{value:"422826",label:"咸丰县"},{value:"422827",label:"来凤县"},{value:"422828",label:"鹤峰县"}]},{value:"429000",label:"省直辖县级行政区划",children:[{value:"429004",label:"仙桃市"},{value:"429005",label:"潜江市"},{value:"429006",label:"天门市"},{value:"429021",label:"神农架林区"}]}]},{value:'430000',label:'湖南省',children:[{value:"430100",label:"长沙市",children:[{value:"430101",label:"市辖区"},{value:"430102",label:"芙蓉区"},{value:"430103",label:"天心区"},{value:"430104",label:"岳麓区"},{value:"430105",label:"开福区"},{value:"430111",label:"雨花区"},{value:"430112",label:"望城区"},{value:"430121",label:"长沙县"},{value:"430181",label:"浏阳市"},{value:"430182",label:"宁乡市"}]},{value:"430200",label:"株洲市",children:[{value:"430201",label:"市辖区"},{value:"430202",label:"荷塘区"},{value:"430203",label:"芦淞区"},{value:"430204",label:"石峰区"},{value:"430211",label:"天元区"},{value:"430221",label:"株洲县"},{value:"430223",label:"攸县"},{value:"430224",label:"茶陵县"},{value:"430225",label:"炎陵县"},{value:"430271",label:"云龙示范区"},{value:"430281",label:"醴陵市"}]},{value:"430300",label:"湘潭市",children:[{value:"430301",label:"市辖区"},{value:"430302",label:"雨湖区"},{value:"430304",label:"岳塘区"},{value:"430321",label:"湘潭县"},{value:"430371",label:"湖南湘潭高新技术产业园区"},{value:"430372",label:"湘潭昭山示范区"},{value:"430373",label:"湘潭九华示范区"},{value:"430381",label:"湘乡市"},{value:"430382",label:"韶山市"}]},{value:"430400",label:"衡阳市",children:[{value:"430401",label:"市辖区"},{value:"430405",label:"珠晖区"},{value:"430406",label:"雁峰区"},{value:"430407",label:"石鼓区"},{value:"430408",label:"蒸湘区"},{value:"430412",label:"南岳区"},{value:"430421",label:"衡阳县"},{value:"430422",label:"衡南县"},{value:"430423",label:"衡山县"},{value:"430424",label:"衡东县"},{value:"430426",label:"祁东县"},{value:"430471",label:"衡阳综合保税区"},{value:"430472",label:"湖南衡阳高新技术产业园区"},{value:"430473",label:"湖南衡阳松木经济开发区"},{value:"430481",label:"耒阳市"},{value:"430482",label:"常宁市"}]},{value:"430500",label:"邵阳市",children:[{value:"430501",label:"市辖区"},{value:"430502",label:"双清区"},{value:"430503",label:"大祥区"},{value:"430511",label:"北塔区"},{value:"430521",label:"邵东县"},{value:"430522",label:"新邵县"},{value:"430523",label:"邵阳县"},{value:"430524",label:"隆回县"},{value:"430525",label:"洞口县"},{value:"430527",label:"绥宁县"},{value:"430528",label:"新宁县"},{value:"430529",label:"城步苗族自治县"},{value:"430581",label:"武冈市"}]},{value:"430600",label:"岳阳市",children:[{value:"430601",label:"市辖区"},{value:"430602",label:"岳阳楼区"},{value:"430603",label:"云溪区"},{value:"430611",label:"君山区"},{value:"430621",label:"岳阳县"},{value:"430623",label:"华容县"},{value:"430624",label:"湘阴县"},{value:"430626",label:"平江县"},{value:"430671",label:"岳阳市屈原管理区"},{value:"430681",label:"汨罗市"},{value:"430682",label:"临湘市"}]},{value:"430700",label:"常德市",children:[{value:"430701",label:"市辖区"},{value:"430702",label:"武陵区"},{value:"430703",label:"鼎城区"},{value:"430721",label:"安乡县"},{value:"430722",label:"汉寿县"},{value:"430723",label:"澧县"},{value:"430724",label:"临澧县"},{value:"430725",label:"桃源县"},{value:"430726",label:"石门县"},{value:"430771",label:"常德市西洞庭管理区"},{value:"430781",label:"津市市"}]},{value:"430800",label:"张家界市",children:[{value:"430801",label:"市辖区"},{value:"430802",label:"永定区"},{value:"430811",label:"武陵源区"},{value:"430821",label:"慈利县"},{value:"430822",label:"桑植县"}]},{value:"430900",label:"益阳市",children:[{value:"430901",label:"市辖区"},{value:"430902",label:"资阳区"},{value:"430903",label:"赫山区"},{value:"430921",label:"南县"},{value:"430922",label:"桃江县"},{value:"430923",label:"安化县"},{value:"430971",label:"益阳市大通湖管理区"},{value:"430972",label:"湖南益阳高新技术产业园区"},{value:"430981",label:"沅江市"}]},{value:"431000",label:"郴州市",children:[{value:"431001",label:"市辖区"},{value:"431002",label:"北湖区"},{value:"431003",label:"苏仙区"},{value:"431021",label:"桂阳县"},{value:"431022",label:"宜章县"},{value:"431023",label:"永兴县"},{value:"431024",label:"嘉禾县"},{value:"431025",label:"临武县"},{value:"431026",label:"汝城县"},{value:"431027",label:"桂东县"},{value:"431028",label:"安仁县"},{value:"431081",label:"资兴市"}]},{value:"431100",label:"永州市",children:[{value:"431101",label:"市辖区"},{value:"431102",label:"零陵区"},{value:"431103",label:"冷水滩区"},{value:"431121",label:"祁阳县"},{value:"431122",label:"东安县"},{value:"431123",label:"双牌县"},{value:"431124",label:"道县"},{value:"431125",label:"江永县"},{value:"431126",label:"宁远县"},{value:"431127",label:"蓝山县"},{value:"431128",label:"新田县"},{value:"431129",label:"江华瑶族自治县"},{value:"431171",label:"永州经济技术开发区"},{value:"431172",label:"永州市金洞管理区"},{value:"431173",label:"永州市回龙圩管理区"}]},{value:"431200",label:"怀化市",children:[{value:"431201",label:"市辖区"},{value:"431202",label:"鹤城区"},{value:"431221",label:"中方县"},{value:"431222",label:"沅陵县"},{value:"431223",label:"辰溪县"},{value:"431224",label:"溆浦县"},{value:"431225",label:"会同县"},{value:"431226",label:"麻阳苗族自治县"},{value:"431227",label:"新晃侗族自治县"},{value:"431228",label:"芷江侗族自治县"},{value:"431229",label:"靖州苗族侗族自治县"},{value:"431230",label:"通道侗族自治县"},{value:"431271",label:"怀化市洪江管理区"},{value:"431281",label:"洪江市"}]},{value:"431300",label:"娄底市",children:[{value:"431301",label:"市辖区"},{value:"431302",label:"娄星区"},{value:"431321",label:"双峰县"},{value:"431322",label:"新化县"},{value:"431381",label:"冷水江市"},{value:"431382",label:"涟源市"}]},{value:"433100",label:"湘西土家族苗族自治州",children:[{value:"433101",label:"吉首市"},{value:"433122",label:"泸溪县"},{value:"433123",label:"凤凰县"},{value:"433124",label:"花垣县"},{value:"433125",label:"保靖县"},{value:"433126",label:"古丈县"},{value:"433127",label:"永顺县"},{value:"433130",label:"龙山县"},{value:"433172",label:"湖南吉首经济开发区"},{value:"433173",label:"湖南永顺经济开发区"}]}]},{value:'440000',label:'广东省',children:[{value:"440100",label:"广州市",children:[{value:"440101",label:"市辖区"},{value:"440103",label:"荔湾区"},{value:"440104",label:"越秀区"},{value:"440105",label:"海珠区"},{value:"440106",label:"天河区"},{value:"440111",label:"白云区"},{value:"440112",label:"黄埔区"},{value:"440113",label:"番禺区"},{value:"440114",label:"花都区"},{value:"440115",label:"南沙区"},{value:"440117",label:"从化区"},{value:"440118",label:"增城区"}]},{value:"440200",label:"韶关市",children:[{value:"440201",label:"市辖区"},{value:"440203",label:"武江区"},{value:"440204",label:"浈江区"},{value:"440205",label:"曲江区"},{value:"440222",label:"始兴县"},{value:"440224",label:"仁化县"},{value:"440229",label:"翁源县"},{value:"440232",label:"乳源瑶族自治县"},{value:"440233",label:"新丰县"},{value:"440281",label:"乐昌市"},{value:"440282",label:"南雄市"}]},{value:"440300",label:"深圳市",children:[{value:"440301",label:"市辖区"},{value:"440303",label:"罗湖区"},{value:"440304",label:"福田区"},{value:"440305",label:"南山区"},{value:"440306",label:"宝安区"},{value:"440307",label:"龙岗区"},{value:"440308",label:"盐田区"},{value:"440309",label:"龙华区"},{value:"440310",label:"坪山区"}]},{value:"440400",label:"珠海市",children:[{value:"440401",label:"市辖区"},{value:"440402",label:"香洲区"},{value:"440403",label:"斗门区"},{value:"440404",label:"金湾区"}]},{value:"440500",label:"汕头市",children:[{value:"440501",label:"市辖区"},{value:"440507",label:"龙湖区"},{value:"440511",label:"金平区"},{value:"440512",label:"濠江区"},{value:"440513",label:"潮阳区"},{value:"440514",label:"潮南区"},{value:"440515",label:"澄海区"},{value:"440523",label:"南澳县"}]},{value:"440600",label:"佛山市",children:[{value:"440601",label:"市辖区"},{value:"440604",label:"禅城区"},{value:"440605",label:"南海区"},{value:"440606",label:"顺德区"},{value:"440607",label:"三水区"},{value:"440608",label:"高明区"}]},{value:"440700",label:"江门市",children:[{value:"440701",label:"市辖区"},{value:"440703",label:"蓬江区"},{value:"440704",label:"江海区"},{value:"440705",label:"新会区"},{value:"440781",label:"台山市"},{value:"440783",label:"开平市"},{value:"440784",label:"鹤山市"},{value:"440785",label:"恩平市"}]},{value:"440800",label:"湛江市",children:[{value:"440801",label:"市辖区"},{value:"440802",label:"赤坎区"},{value:"440803",label:"霞山区"},{value:"440804",label:"坡头区"},{value:"440811",label:"麻章区"},{value:"440823",label:"遂溪县"},{value:"440825",label:"徐闻县"},{value:"440881",label:"廉江市"},{value:"440882",label:"雷州市"},{value:"440883",label:"吴川市"}]},{value:"440900",label:"茂名市",children:[{value:"440901",label:"市辖区"},{value:"440902",label:"茂南区"},{value:"440904",label:"电白区"},{value:"440981",label:"高州市"},{value:"440982",label:"化州市"},{value:"440983",label:"信宜市"}]},{value:"441200",label:"肇庆市",children:[{value:"441201",label:"市辖区"},{value:"441202",label:"端州区"},{value:"441203",label:"鼎湖区"},{value:"441204",label:"高要区"},{value:"441223",label:"广宁县"},{value:"441224",label:"怀集县"},{value:"441225",label:"封开县"},{value:"441226",label:"德庆县"},{value:"441284",label:"四会市"}]},{value:"441300",label:"惠州市",children:[{value:"441301",label:"市辖区"},{value:"441302",label:"惠城区"},{value:"441303",label:"惠阳区"},{value:"441322",label:"博罗县"},{value:"441323",label:"惠东县"},{value:"441324",label:"龙门县"}]},{value:"441400",label:"梅州市",children:[{value:"441401",label:"市辖区"},{value:"441402",label:"梅江区"},{value:"441403",label:"梅县区"},{value:"441422",label:"大埔县"},{value:"441423",label:"丰顺县"},{value:"441424",label:"五华县"},{value:"441426",label:"平远县"},{value:"441427",label:"蕉岭县"},{value:"441481",label:"兴宁市"}]},{value:"441500",label:"汕尾市",children:[{value:"441501",label:"市辖区"},{value:"441502",label:"城区"},{value:"441521",label:"海丰县"},{value:"441523",label:"陆河县"},{value:"441581",label:"陆丰市"}]},{value:"441600",label:"河源市",children:[{value:"441601",label:"市辖区"},{value:"441602",label:"源城区"},{value:"441621",label:"紫金县"},{value:"441622",label:"龙川县"},{value:"441623",label:"连平县"},{value:"441624",label:"和平县"},{value:"441625",label:"东源县"}]},{value:"441700",label:"阳江市",children:[{value:"441701",label:"市辖区"},{value:"441702",label:"江城区"},{value:"441704",label:"阳东区"},{value:"441721",label:"阳西县"},{value:"441781",label:"阳春市"}]},{value:"441800",label:"清远市",children:[{value:"441801",label:"市辖区"},{value:"441802",label:"清城区"},{value:"441803",label:"清新区"},{value:"441821",label:"佛冈县"},{value:"441823",label:"阳山县"},{value:"441825",label:"连山壮族瑶族自治县"},{value:"441826",label:"连南瑶族自治县"},{value:"441881",label:"英德市"},{value:"441882",label:"连州市"}]},{value:"441900",label:"东莞市"},{value:"442000",label:"中山市"},{value:"445100",label:"潮州市",children:[{value:"445101",label:"市辖区"},{value:"445102",label:"湘桥区"},{value:"445103",label:"潮安区"},{value:"445122",label:"饶平县"}]},{value:"445200",label:"揭阳市",children:[{value:"445201",label:"市辖区"},{value:"445202",label:"榕城区"},{value:"445203",label:"揭东区"},{value:"445222",label:"揭西县"},{value:"445224",label:"惠来县"},{value:"445281",label:"普宁市"}]},{value:"445300",label:"云浮市",children:[{value:"445301",label:"市辖区"},{value:"445302",label:"云城区"},{value:"445303",label:"云安区"},{value:"445321",label:"新兴县"},{value:"445322",label:"郁南县"},{value:"445381",label:"罗定市"}]}]},{value:'450000',label:'广西壮族',children:[{value:"450100",label:"南宁市",children:[{value:"450101",label:"市辖区"},{value:"450102",label:"兴宁区"},{value:"450103",label:"青秀区"},{value:"450105",label:"江南区"},{value:"450107",label:"西乡塘区"},{value:"450108",label:"良庆区"},{value:"450109",label:"邕宁区"},{value:"450110",label:"武鸣区"},{value:"450123",label:"隆安县"},{value:"450124",label:"马山县"},{value:"450125",label:"上林县"},{value:"450126",label:"宾阳县"},{value:"450127",label:"横县"}]},{value:"450200",label:"柳州市",children:[{value:"450201",label:"市辖区"},{value:"450202",label:"城中区"},{value:"450203",label:"鱼峰区"},{value:"450204",label:"柳南区"},{value:"450205",label:"柳北区"},{value:"450206",label:"柳江区"},{value:"450222",label:"柳城县"},{value:"450223",label:"鹿寨县"},{value:"450224",label:"融安县"},{value:"450225",label:"融水苗族自治县"},{value:"450226",label:"三江侗族自治县"}]},{value:"450300",label:"桂林市",children:[{value:"450301",label:"市辖区"},{value:"450302",label:"秀峰区"},{value:"450303",label:"叠彩区"},{value:"450304",label:"象山区"},{value:"450305",label:"七星区"},{value:"450311",label:"雁山区"},{value:"450312",label:"临桂区"},{value:"450321",label:"阳朔县"},{value:"450323",label:"灵川县"},{value:"450324",label:"全州县"},{value:"450325",label:"兴安县"},{value:"450326",label:"永福县"},{value:"450327",label:"灌阳县"},{value:"450328",label:"龙胜各族自治县"},{value:"450329",label:"资源县"},{value:"450330",label:"平乐县"},{value:"450331",label:"荔浦县"},{value:"450332",label:"恭城瑶族自治县"}]},{value:"450400",label:"梧州市",children:[{value:"450401",label:"市辖区"},{value:"450403",label:"万秀区"},{value:"450405",label:"长洲区"},{value:"450406",label:"龙圩区"},{value:"450421",label:"苍梧县"},{value:"450422",label:"藤县"},{value:"450423",label:"蒙山县"},{value:"450481",label:"岑溪市"}]},{value:"450500",label:"北海市",children:[{value:"450501",label:"市辖区"},{value:"450502",label:"海城区"},{value:"450503",label:"银海区"},{value:"450512",label:"铁山港区"},{value:"450521",label:"合浦县"}]},{value:"450600",label:"防城港市",children:[{value:"450601",label:"市辖区"},{value:"450602",label:"港口区"},{value:"450603",label:"防城区"},{value:"450621",label:"上思县"},{value:"450681",label:"东兴市"}]},{value:"450700",label:"钦州市",children:[{value:"450701",label:"市辖区"},{value:"450702",label:"钦南区"},{value:"450703",label:"钦北区"},{value:"450721",label:"灵山县"},{value:"450722",label:"浦北县"}]},{value:"450800",label:"贵港市",children:[{value:"450801",label:"市辖区"},{value:"450802",label:"港北区"},{value:"450803",label:"港南区"},{value:"450804",label:"覃塘区"},{value:"450821",label:"平南县"},{value:"450881",label:"桂平市"}]},{value:"450900",label:"玉林市",children:[{value:"450901",label:"市辖区"},{value:"450902",label:"玉州区"},{value:"450903",label:"福绵区"},{value:"450921",label:"容县"},{value:"450922",label:"陆川县"},{value:"450923",label:"博白县"},{value:"450924",label:"兴业县"},{value:"450981",label:"北流市"}]},{value:"451000",label:"百色市",children:[{value:"451001",label:"市辖区"},{value:"451002",label:"右江区"},{value:"451021",label:"田阳县"},{value:"451022",label:"田东县"},{value:"451023",label:"平果县"},{value:"451024",label:"德保县"},{value:"451026",label:"那坡县"},{value:"451027",label:"凌云县"},{value:"451028",label:"乐业县"},{value:"451029",label:"田林县"},{value:"451030",label:"西林县"},{value:"451031",label:"隆林各族自治县"},{value:"451081",label:"靖西市"}]},{value:"451100",label:"贺州市",children:[{value:"451101",label:"市辖区"},{value:"451102",label:"八步区"},{value:"451103",label:"平桂区"},{value:"451121",label:"昭平县"},{value:"451122",label:"钟山县"},{value:"451123",label:"富川瑶族自治县"}]},{value:"451200",label:"河池市",children:[{value:"451201",label:"市辖区"},{value:"451202",label:"金城江区"},{value:"451203",label:"宜州区"},{value:"451221",label:"南丹县"},{value:"451222",label:"天峨县"},{value:"451223",label:"凤山县"},{value:"451224",label:"东兰县"},{value:"451225",label:"罗城仫佬族自治县"},{value:"451226",label:"环江毛南族自治县"},{value:"451227",label:"巴马瑶族自治县"},{value:"451228",label:"都安瑶族自治县"},{value:"451229",label:"大化瑶族自治县"}]},{value:"451300",label:"来宾市",children:[{value:"451301",label:"市辖区"},{value:"451302",label:"兴宾区"},{value:"451321",label:"忻城县"},{value:"451322",label:"象州县"},{value:"451323",label:"武宣县"},{value:"451324",label:"金秀瑶族自治县"},{value:"451381",label:"合山市"}]},{value:"451400",label:"崇左市",children:[{value:"451401",label:"市辖区"},{value:"451402",label:"江州区"},{value:"451421",label:"扶绥县"},{value:"451422",label:"宁明县"},{value:"451423",label:"龙州县"},{value:"451424",label:"大新县"},{value:"451425",label:"天等县"},{value:"451481",label:"凭祥市"}]}]},{value:'460000',label:'海南省',children:[{value:"460100",label:"海口市",children:[{value:"460101",label:"市辖区"},{value:"460105",label:"秀英区"},{value:"460106",label:"龙华区"},{value:"460107",label:"琼山区"},{value:"460108",label:"美兰区"}]},{value:"460200",label:"三亚市",children:[{value:"460201",label:"市辖区"},{value:"460202",label:"海棠区"},{value:"460203",label:"吉阳区"},{value:"460204",label:"天涯区"},{value:"460205",label:"崖州区"}]},{value:"460300",label:"三沙市",children:[{value:"460321",label:"西沙群岛"},{value:"460322",label:"南沙群岛"},{value:"460323",label:"中沙群岛的岛礁及其海域"}]},{value:"460400",label:"儋州市"},{value:"469000",label:"省直辖县级行政区划",children:[{value:"469001",label:"五指山市"},{value:"469002",label:"琼海市"},{value:"469005",label:"文昌市"},{value:"469006",label:"万宁市"},{value:"469007",label:"东方市"},{value:"469021",label:"定安县"},{value:"469022",label:"屯昌县"},{value:"469023",label:"澄迈县"},{value:"469024",label:"临高县"},{value:"469025",label:"白沙黎族自治县"},{value:"469026",label:"昌江黎族自治县"},{value:"469027",label:"乐东黎族自治县"},{value:"469028",label:"陵水黎族自治县"},{value:"469029",label:"保亭黎族苗族自治县"},{value:"469030",label:"琼中黎族苗族自治县"}]}]},{value:'500000',label:'重庆',children:[{value:"500100",label:"市辖区",children:[{value:"500101",label:"万州区"},{value:"500102",label:"涪陵区"},{value:"500103",label:"渝中区"},{value:"500104",label:"大渡口区"},{value:"500105",label:"江北区"},{value:"500106",label:"沙坪坝区"},{value:"500107",label:"九龙坡区"},{value:"500108",label:"南岸区"},{value:"500109",label:"北碚区"},{value:"500110",label:"綦江区"},{value:"500111",label:"大足区"},{value:"500112",label:"渝北区"},{value:"500113",label:"巴南区"},{value:"500114",label:"黔江区"},{value:"500115",label:"长寿区"},{value:"500116",label:"江津区"},{value:"500117",label:"合川区"},{value:"500118",label:"永川区"},{value:"500119",label:"南川区"},{value:"500120",label:"璧山区"},{value:"500151",label:"铜梁区"},{value:"500152",label:"潼南区"},{value:"500153",label:"荣昌区"},{value:"500154",label:"开州区"},{value:"500155",label:"梁平区"},{value:"500156",label:"武隆区"}]},{value:"500200",label:"县",children:[{value:"500229",label:"城口县"},{value:"500230",label:"丰都县"},{value:"500231",label:"垫江县"},{value:"500233",label:"忠县"},{value:"500235",label:"云阳县"},{value:"500236",label:"奉节县"},{value:"500237",label:"巫山县"},{value:"500238",label:"巫溪县"},{value:"500240",label:"石柱土家族自治县"},{value:"500241",label:"秀山土家族苗族自治县"},{value:"500242",label:"酉阳土家族苗族自治县"},{value:"500243",label:"彭水苗族土家族自治县"}]}]},{value:'510000',label:'四川省',children:[{value:"510100",label:"成都市",children:[{value:"510101",label:"市辖区"},{value:"510104",label:"锦江区"},{value:"510105",label:"青羊区"},{value:"510106",label:"金牛区"},{value:"510107",label:"武侯区"},{value:"510108",label:"成华区"},{value:"510112",label:"龙泉驿区"},{value:"510113",label:"青白江区"},{value:"510114",label:"新都区"},{value:"510115",label:"温江区"},{value:"510116",label:"双流区"},{value:"510117",label:"郫都区"},{value:"510121",label:"金堂县"},{value:"510129",label:"大邑县"},{value:"510131",label:"蒲江县"},{value:"510132",label:"新津县"},{value:"510181",label:"都江堰市"},{value:"510182",label:"彭州市"},{value:"510183",label:"邛崃市"},{value:"510184",label:"崇州市"},{value:"510185",label:"简阳市"}]},{value:"510300",label:"自贡市",children:[{value:"510301",label:"市辖区"},{value:"510302",label:"自流井区"},{value:"510303",label:"贡井区"},{value:"510304",label:"大安区"},{value:"510311",label:"沿滩区"},{value:"510321",label:"荣县"},{value:"510322",label:"富顺县"}]},{value:"510400",label:"攀枝花市",children:[{value:"510401",label:"市辖区"},{value:"510402",label:"东区"},{value:"510403",label:"西区"},{value:"510411",label:"仁和区"},{value:"510421",label:"米易县"},{value:"510422",label:"盐边县"}]},{value:"510500",label:"泸州市",children:[{value:"510501",label:"市辖区"},{value:"510502",label:"江阳区"},{value:"510503",label:"纳溪区"},{value:"510504",label:"龙马潭区"},{value:"510521",label:"泸县"},{value:"510522",label:"合江县"},{value:"510524",label:"叙永县"},{value:"510525",label:"古蔺县"}]},{value:"510600",label:"德阳市",children:[{value:"510601",label:"市辖区"},{value:"510603",label:"旌阳区"},{value:"510604",label:"罗江区"},{value:"510623",label:"中江县"},{value:"510681",label:"广汉市"},{value:"510682",label:"什邡市"},{value:"510683",label:"绵竹市"}]},{value:"510700",label:"绵阳市",children:[{value:"510701",label:"市辖区"},{value:"510703",label:"涪城区"},{value:"510704",label:"游仙区"},{value:"510705",label:"安州区"},{value:"510722",label:"三台县"},{value:"510723",label:"盐亭县"},{value:"510725",label:"梓潼县"},{value:"510726",label:"北川羌族自治县"},{value:"510727",label:"平武县"},{value:"510781",label:"江油市"}]},{value:"510800",label:"广元市",children:[{value:"510801",label:"市辖区"},{value:"510802",label:"利州区"},{value:"510811",label:"昭化区"},{value:"510812",label:"朝天区"},{value:"510821",label:"旺苍县"},{value:"510822",label:"青川县"},{value:"510823",label:"剑阁县"},{value:"510824",label:"苍溪县"}]},{value:"510900",label:"遂宁市",children:[{value:"510901",label:"市辖区"},{value:"510903",label:"船山区"},{value:"510904",label:"安居区"},{value:"510921",label:"蓬溪县"},{value:"510922",label:"射洪县"},{value:"510923",label:"大英县"}]},{value:"511000",label:"内江市",children:[{value:"511001",label:"市辖区"},{value:"511002",label:"市中区"},{value:"511011",label:"东兴区"},{value:"511024",label:"威远县"},{value:"511025",label:"资中县"},{value:"511071",label:"内江经济开发区"},{value:"511083",label:"隆昌市"}]},{value:"511100",label:"乐山市",children:[{value:"511101",label:"市辖区"},{value:"511102",label:"市中区"},{value:"511111",label:"沙湾区"},{value:"511112",label:"五通桥区"},{value:"511113",label:"金口河区"},{value:"511123",label:"犍为县"},{value:"511124",label:"井研县"},{value:"511126",label:"夹江县"},{value:"511129",label:"沐川县"},{value:"511132",label:"峨边彝族自治县"},{value:"511133",label:"马边彝族自治县"},{value:"511181",label:"峨眉山市"}]},{value:"511300",label:"南充市",children:[{value:"511301",label:"市辖区"},{value:"511302",label:"顺庆区"},{value:"511303",label:"高坪区"},{value:"511304",label:"嘉陵区"},{value:"511321",label:"南部县"},{value:"511322",label:"营山县"},{value:"511323",label:"蓬安县"},{value:"511324",label:"仪陇县"},{value:"511325",label:"西充县"},{value:"511381",label:"阆中市"}]},{value:"511400",label:"眉山市",children:[{value:"511401",label:"市辖区"},{value:"511402",label:"东坡区"},{value:"511403",label:"彭山区"},{value:"511421",label:"仁寿县"},{value:"511423",label:"洪雅县"},{value:"511424",label:"丹棱县"},{value:"511425",label:"青神县"}]},{value:"511500",label:"宜宾市",children:[{value:"511501",label:"市辖区"},{value:"511502",label:"翠屏区"},{value:"511503",label:"南溪区"},{value:"511521",label:"宜宾县"},{value:"511523",label:"江安县"},{value:"511524",label:"长宁县"},{value:"511525",label:"高县"},{value:"511526",label:"珙县"},{value:"511527",label:"筠连县"},{value:"511528",label:"兴文县"},{value:"511529",label:"屏山县"}]},{value:"511600",label:"广安市",children:[{value:"511601",label:"市辖区"},{value:"511602",label:"广安区"},{value:"511603",label:"前锋区"},{value:"511621",label:"岳池县"},{value:"511622",label:"武胜县"},{value:"511623",label:"邻水县"},{value:"511681",label:"华蓥市"}]},{value:"511700",label:"达州市",children:[{value:"511701",label:"市辖区"},{value:"511702",label:"通川区"},{value:"511703",label:"达川区"},{value:"511722",label:"宣汉县"},{value:"511723",label:"开江县"},{value:"511724",label:"大竹县"},{value:"511725",label:"渠县"},{value:"511771",label:"达州经济开发区"},{value:"511781",label:"万源市"}]},{value:"511800",label:"雅安市",children:[{value:"511801",label:"市辖区"},{value:"511802",label:"雨城区"},{value:"511803",label:"名山区"},{value:"511822",label:"荥经县"},{value:"511823",label:"汉源县"},{value:"511824",label:"石棉县"},{value:"511825",label:"天全县"},{value:"511826",label:"芦山县"},{value:"511827",label:"宝兴县"}]},{value:"511900",label:"巴中市",children:[{value:"511901",label:"市辖区"},{value:"511902",label:"巴州区"},{value:"511903",label:"恩阳区"},{value:"511921",label:"通江县"},{value:"511922",label:"南江县"},{value:"511923",label:"平昌县"},{value:"511971",label:"巴中经济开发区"}]},{value:"512000",label:"资阳市",children:[{value:"512001",label:"市辖区"},{value:"512002",label:"雁江区"},{value:"512021",label:"安岳县"},{value:"512022",label:"乐至县"}]},{value:"513200",label:"阿坝藏族羌族自治州",children:[{value:"513201",label:"马尔康市"},{value:"513221",label:"汶川县"},{value:"513222",label:"理县"},{value:"513223",label:"茂县"},{value:"513224",label:"松潘县"},{value:"513225",label:"九寨沟县"},{value:"513226",label:"金川县"},{value:"513227",label:"小金县"},{value:"513228",label:"黑水县"},{value:"513230",label:"壤塘县"},{value:"513231",label:"阿坝县"},{value:"513232",label:"若尔盖县"},{value:"513233",label:"红原县"}]},{value:"513300",label:"甘孜藏族自治州",children:[{value:"513301",label:"康定市"},{value:"513322",label:"泸定县"},{value:"513323",label:"丹巴县"},{value:"513324",label:"九龙县"},{value:"513325",label:"雅江县"},{value:"513326",label:"道孚县"},{value:"513327",label:"炉霍县"},{value:"513328",label:"甘孜县"},{value:"513329",label:"新龙县"},{value:"513330",label:"德格县"},{value:"513331",label:"白玉县"},{value:"513332",label:"石渠县"},{value:"513333",label:"色达县"},{value:"513334",label:"理塘县"},{value:"513335",label:"巴塘县"},{value:"513336",label:"乡城县"},{value:"513337",label:"稻城县"},{value:"513338",label:"得荣县"}]},{value:"513400",label:"凉山彝族自治州",children:[{value:"513401",label:"西昌市"},{value:"513422",label:"木里藏族自治县"},{value:"513423",label:"盐源县"},{value:"513424",label:"德昌县"},{value:"513425",label:"会理县"},{value:"513426",label:"会东县"},{value:"513427",label:"宁南县"},{value:"513428",label:"普格县"},{value:"513429",label:"布拖县"},{value:"513430",label:"金阳县"},{value:"513431",label:"昭觉县"},{value:"513432",label:"喜德县"},{value:"513433",label:"冕宁县"},{value:"513434",label:"越西县"},{value:"513435",label:"甘洛县"},{value:"513436",label:"美姑县"},{value:"513437",label:"雷波县"}]}]},{value:'520000',label:'贵州省',children:[{value:"520100",label:"贵阳市",children:[{value:"520101",label:"市辖区"},{value:"520102",label:"南明区"},{value:"520103",label:"云岩区"},{value:"520111",label:"花溪区"},{value:"520112",label:"乌当区"},{value:"520113",label:"白云区"},{value:"520115",label:"观山湖区"},{value:"520121",label:"开阳县"},{value:"520122",label:"息烽县"},{value:"520123",label:"修文县"},{value:"520181",label:"清镇市"}]},{value:"520200",label:"六盘水市",children:[{value:"520201",label:"钟山区"},{value:"520203",label:"六枝特区"},{value:"520221",label:"水城县"},{value:"520281",label:"盘州市"}]},{value:"520300",label:"遵义市",children:[{value:"520301",label:"市辖区"},{value:"520302",label:"红花岗区"},{value:"520303",label:"汇川区"},{value:"520304",label:"播州区"},{value:"520322",label:"桐梓县"},{value:"520323",label:"绥阳县"},{value:"520324",label:"正安县"},{value:"520325",label:"道真仡佬族苗族自治县"},{value:"520326",label:"务川仡佬族苗族自治县"},{value:"520327",label:"凤冈县"},{value:"520328",label:"湄潭县"},{value:"520329",label:"余庆县"},{value:"520330",label:"习水县"},{value:"520381",label:"赤水市"},{value:"520382",label:"仁怀市"}]},{value:"520400",label:"安顺市",children:[{value:"520401",label:"市辖区"},{value:"520402",label:"西秀区"},{value:"520403",label:"平坝区"},{value:"520422",label:"普定县"},{value:"520423",label:"镇宁布依族苗族自治县"},{value:"520424",label:"关岭布依族苗族自治县"},{value:"520425",label:"紫云苗族布依族自治县"}]},{value:"520500",label:"毕节市",children:[{value:"520501",label:"市辖区"},{value:"520502",label:"七星关区"},{value:"520521",label:"大方县"},{value:"520522",label:"黔西县"},{value:"520523",label:"金沙县"},{value:"520524",label:"织金县"},{value:"520525",label:"纳雍县"},{value:"520526",label:"威宁彝族回族苗族自治县"},{value:"520527",label:"赫章县"}]},{value:"520600",label:"铜仁市",children:[{value:"520601",label:"市辖区"},{value:"520602",label:"碧江区"},{value:"520603",label:"万山区"},{value:"520621",label:"江口县"},{value:"520622",label:"玉屏侗族自治县"},{value:"520623",label:"石阡县"},{value:"520624",label:"思南县"},{value:"520625",label:"印江土家族苗族自治县"},{value:"520626",label:"德江县"},{value:"520627",label:"沿河土家族自治县"},{value:"520628",label:"松桃苗族自治县"}]},{value:"522300",label:"黔西南布依族苗族自治州",children:[{value:"522301",label:"兴义市"},{value:"522322",label:"兴仁县"},{value:"522323",label:"普安县"},{value:"522324",label:"晴隆县"},{value:"522325",label:"贞丰县"},{value:"522326",label:"望谟县"},{value:"522327",label:"册亨县"},{value:"522328",label:"安龙县"}]},{value:"522600",label:"黔东南苗族侗族自治州",children:[{value:"522601",label:"凯里市"},{value:"522622",label:"黄平县"},{value:"522623",label:"施秉县"},{value:"522624",label:"三穗县"},{value:"522625",label:"镇远县"},{value:"522626",label:"岑巩县"},{value:"522627",label:"天柱县"},{value:"522628",label:"锦屏县"},{value:"522629",label:"剑河县"},{value:"522630",label:"台江县"},{value:"522631",label:"黎平县"},{value:"522632",label:"榕江县"},{value:"522633",label:"从江县"},{value:"522634",label:"雷山县"},{value:"522635",label:"麻江县"},{value:"522636",label:"丹寨县"}]},{value:"522700",label:"黔南布依族苗族自治州",children:[{value:"522701",label:"都匀市"},{value:"522702",label:"福泉市"},{value:"522722",label:"荔波县"},{value:"522723",label:"贵定县"},{value:"522725",label:"瓮安县"},{value:"522726",label:"独山县"},{value:"522727",label:"平塘县"},{value:"522728",label:"罗甸县"},{value:"522729",label:"长顺县"},{value:"522730",label:"龙里县"},{value:"522731",label:"惠水县"},{value:"522732",label:"三都水族自治县"}]}]},{value:'530000',label:'云南省',children:[{value:"530100",label:"昆明市",children:[{value:"530101",label:"市辖区"},{value:"530102",label:"五华区"},{value:"530103",label:"盘龙区"},{value:"530111",label:"官渡区"},{value:"530112",label:"西山区"},{value:"530113",label:"东川区"},{value:"530114",label:"呈贡区"},{value:"530115",label:"晋宁区"},{value:"530124",label:"富民县"},{value:"530125",label:"宜良县"},{value:"530126",label:"石林彝族自治县"},{value:"530127",label:"嵩明县"},{value:"530128",label:"禄劝彝族苗族自治县"},{value:"530129",label:"寻甸回族彝族自治县"},{value:"530181",label:"安宁市"}]},{value:"530300",label:"曲靖市",children:[{value:"530301",label:"市辖区"},{value:"530302",label:"麒麟区"},{value:"530303",label:"沾益区"},{value:"530321",label:"马龙县"},{value:"530322",label:"陆良县"},{value:"530323",label:"师宗县"},{value:"530324",label:"罗平县"},{value:"530325",label:"富源县"},{value:"530326",label:"会泽县"},{value:"530381",label:"宣威市"}]},{value:"530400",label:"玉溪市",children:[{value:"530401",label:"市辖区"},{value:"530402",label:"红塔区"},{value:"530403",label:"江川区"},{value:"530422",label:"澄江县"},{value:"530423",label:"通海县"},{value:"530424",label:"华宁县"},{value:"530425",label:"易门县"},{value:"530426",label:"峨山彝族自治县"},{value:"530427",label:"新平彝族傣族自治县"},{value:"530428",label:"元江哈尼族彝族傣族自治县"}]},{value:"530500",label:"保山市",children:[{value:"530501",label:"市辖区"},{value:"530502",label:"隆阳区"},{value:"530521",label:"施甸县"},{value:"530523",label:"龙陵县"},{value:"530524",label:"昌宁县"},{value:"530581",label:"腾冲市"}]},{value:"530600",label:"昭通市",children:[{value:"530601",label:"市辖区"},{value:"530602",label:"昭阳区"},{value:"530621",label:"鲁甸县"},{value:"530622",label:"巧家县"},{value:"530623",label:"盐津县"},{value:"530624",label:"大关县"},{value:"530625",label:"永善县"},{value:"530626",label:"绥江县"},{value:"530627",label:"镇雄县"},{value:"530628",label:"彝良县"},{value:"530629",label:"威信县"},{value:"530630",label:"水富县"}]},{value:"530700",label:"丽江市",children:[{value:"530701",label:"市辖区"},{value:"530702",label:"古城区"},{value:"530721",label:"玉龙纳西族自治县"},{value:"530722",label:"永胜县"},{value:"530723",label:"华坪县"},{value:"530724",label:"宁蒗彝族自治县"}]},{value:"530800",label:"普洱市",children:[{value:"530801",label:"市辖区"},{value:"530802",label:"思茅区"},{value:"530821",label:"宁洱哈尼族彝族自治县"},{value:"530822",label:"墨江哈尼族自治县"},{value:"530823",label:"景东彝族自治县"},{value:"530824",label:"景谷傣族彝族自治县"},{value:"530825",label:"镇沅彝族哈尼族拉祜族自治县"},{value:"530826",label:"江城哈尼族彝族自治县"},{value:"530827",label:"孟连傣族拉祜族佤族自治县"},{value:"530828",label:"澜沧拉祜族自治县"},{value:"530829",label:"西盟佤族自治县"}]},{value:"530900",label:"临沧市",children:[{value:"530901",label:"市辖区"},{value:"530902",label:"临翔区"},{value:"530921",label:"凤庆县"},{value:"530922",label:"云县"},{value:"530923",label:"永德县"},{value:"530924",label:"镇康县"},{value:"530925",label:"双江拉祜族佤族布朗族傣族自治县"},{value:"530926",label:"耿马傣族佤族自治县"},{value:"530927",label:"沧源佤族自治县"}]},{value:"532300",label:"楚雄彝族自治州",children:[{value:"532301",label:"楚雄市"},{value:"532322",label:"双柏县"},{value:"532323",label:"牟定县"},{value:"532324",label:"南华县"},{value:"532325",label:"姚安县"},{value:"532326",label:"大姚县"},{value:"532327",label:"永仁县"},{value:"532328",label:"元谋县"},{value:"532329",label:"武定县"},{value:"532331",label:"禄丰县"}]},{value:"532500",label:"红河哈尼族彝族自治州",children:[{value:"532501",label:"个旧市"},{value:"532502",label:"开远市"},{value:"532503",label:"蒙自市"},{value:"532504",label:"弥勒市"},{value:"532523",label:"屏边苗族自治县"},{value:"532524",label:"建水县"},{value:"532525",label:"石屏县"},{value:"532527",label:"泸西县"},{value:"532528",label:"元阳县"},{value:"532529",label:"红河县"},{value:"532530",label:"金平苗族瑶族傣族自治县"},{value:"532531",label:"绿春县"},{value:"532532",label:"河口瑶族自治县"}]},{value:"532600",label:"文山壮族苗族自治州",children:[{value:"532601",label:"文山市"},{value:"532622",label:"砚山县"},{value:"532623",label:"西畴县"},{value:"532624",label:"麻栗坡县"},{value:"532625",label:"马关县"},{value:"532626",label:"丘北县"},{value:"532627",label:"广南县"},{value:"532628",label:"富宁县"}]},{value:"532800",label:"西双版纳傣族自治州",children:[{value:"532801",label:"景洪市"},{value:"532822",label:"勐海县"},{value:"532823",label:"勐腊县"}]},{value:"532900",label:"大理白族自治州",children:[{value:"532901",label:"大理市"},{value:"532922",label:"漾濞彝族自治县"},{value:"532923",label:"祥云县"},{value:"532924",label:"宾川县"},{value:"532925",label:"弥渡县"},{value:"532926",label:"南涧彝族自治县"},{value:"532927",label:"巍山彝族回族自治县"},{value:"532928",label:"永平县"},{value:"532929",label:"云龙县"},{value:"532930",label:"洱源县"},{value:"532931",label:"剑川县"},{value:"532932",label:"鹤庆县"}]},{value:"533100",label:"德宏傣族景颇族自治州",children:[{value:"533102",label:"瑞丽市"},{value:"533103",label:"芒市"},{value:"533122",label:"梁河县"},{value:"533123",label:"盈江县"},{value:"533124",label:"陇川县"}]},{value:"533300",label:"怒江傈僳族自治州",children:[{value:"533301",label:"泸水市"},{value:"533323",label:"福贡县"},{value:"533324",label:"贡山独龙族怒族自治县"},{value:"533325",label:"兰坪白族普米族自治县"}]},{value:"533400",label:"迪庆藏族自治州",children:[{value:"533401",label:"香格里拉市"},{value:"533422",label:"德钦县"},{value:"533423",label:"维西傈僳族自治县"}]}]},{value:'540000',label:'西藏',children:[{value:"540100",label:"拉萨市",children:[{value:"540101",label:"市辖区"},{value:"540102",label:"城关区"},{value:"540103",label:"堆龙德庆区"},{value:"540121",label:"林周县"},{value:"540122",label:"当雄县"},{value:"540123",label:"尼木县"},{value:"540124",label:"曲水县"},{value:"540126",label:"达孜县"},{value:"540127",label:"墨竹工卡县"},{value:"540171",label:"格尔木藏青工业园区"},{value:"540172",label:"拉萨经济技术开发区"},{value:"540173",label:"西藏文化旅游创意园区"},{value:"540174",label:"达孜工业园区"}]},{value:"540200",label:"日喀则市",children:[{value:"540202",label:"桑珠孜区"},{value:"540221",label:"南木林县"},{value:"540222",label:"江孜县"},{value:"540223",label:"定日县"},{value:"540224",label:"萨迦县"},{value:"540225",label:"拉孜县"},{value:"540226",label:"昂仁县"},{value:"540227",label:"谢通门县"},{value:"540228",label:"白朗县"},{value:"540229",label:"仁布县"},{value:"540230",label:"康马县"},{value:"540231",label:"定结县"},{value:"540232",label:"仲巴县"},{value:"540233",label:"亚东县"},{value:"540234",label:"吉隆县"},{value:"540235",label:"聂拉木县"},{value:"540236",label:"萨嘎县"},{value:"540237",label:"岗巴县"}]},{value:"540300",label:"昌都市",children:[{value:"540302",label:"卡若区"},{value:"540321",label:"江达县"},{value:"540322",label:"贡觉县"},{value:"540323",label:"类乌齐县"},{value:"540324",label:"丁青县"},{value:"540325",label:"察雅县"},{value:"540326",label:"八宿县"},{value:"540327",label:"左贡县"},{value:"540328",label:"芒康县"},{value:"540329",label:"洛隆县"},{value:"540330",label:"边坝县"}]},{value:"540400",label:"林芝市",children:[{value:"540402",label:"巴宜区"},{value:"540421",label:"工布江达县"},{value:"540422",label:"米林县"},{value:"540423",label:"墨脱县"},{value:"540424",label:"波密县"},{value:"540425",label:"察隅县"},{value:"540426",label:"朗县"}]},{value:"540500",label:"山南市",children:[{value:"540501",label:"市辖区"},{value:"540502",label:"乃东区"},{value:"540521",label:"扎囊县"},{value:"540522",label:"贡嘎县"},{value:"540523",label:"桑日县"},{value:"540524",label:"琼结县"},{value:"540525",label:"曲松县"},{value:"540526",label:"措美县"},{value:"540527",label:"洛扎县"},{value:"540528",label:"加查县"},{value:"540529",label:"隆子县"},{value:"540530",label:"错那县"},{value:"540531",label:"浪卡子县"}]},{value:"542400",label:"那曲地区",children:[{value:"542421",label:"那曲县"},{value:"542422",label:"嘉黎县"},{value:"542423",label:"比如县"},{value:"542424",label:"聂荣县"},{value:"542425",label:"安多县"},{value:"542426",label:"申扎县"},{value:"542427",label:"索县"},{value:"542428",label:"班戈县"},{value:"542429",label:"巴青县"},{value:"542430",label:"尼玛县"},{value:"542431",label:"双湖县"}]},{value:"542500",label:"阿里地区",children:[{value:"542521",label:"普兰县"},{value:"542522",label:"札达县"},{value:"542523",label:"噶尔县"},{value:"542524",label:"日土县"},{value:"542525",label:"革吉县"},{value:"542526",label:"改则县"},{value:"542527",label:"措勤县"}]}]},{value:'610000',label:'陕西省',children:[{value:"610100",label:"西安市",children:[{value:"610101",label:"市辖区"},{value:"610102",label:"新城区"},{value:"610103",label:"碑林区"},{value:"610104",label:"莲湖区"},{value:"610111",label:"灞桥区"},{value:"610112",label:"未央区"},{value:"610113",label:"雁塔区"},{value:"610114",label:"阎良区"},{value:"610115",label:"临潼区"},{value:"610116",label:"长安区"},{value:"610117",label:"高陵区"},{value:"610118",label:"鄠邑区"},{value:"610122",label:"蓝田县"},{value:"610124",label:"周至县"}]},{value:"610200",label:"铜川市",children:[{value:"610201",label:"市辖区"},{value:"610202",label:"王益区"},{value:"610203",label:"印台区"},{value:"610204",label:"耀州区"},{value:"610222",label:"宜君县"}]},{value:"610300",label:"宝鸡市",children:[{value:"610301",label:"市辖区"},{value:"610302",label:"渭滨区"},{value:"610303",label:"金台区"},{value:"610304",label:"陈仓区"},{value:"610322",label:"凤翔县"},{value:"610323",label:"岐山县"},{value:"610324",label:"扶风县"},{value:"610326",label:"眉县"},{value:"610327",label:"陇县"},{value:"610328",label:"千阳县"},{value:"610329",label:"麟游县"},{value:"610330",label:"凤县"},{value:"610331",label:"太白县"}]},{value:"610400",label:"咸阳市",children:[{value:"610401",label:"市辖区"},{value:"610402",label:"秦都区"},{value:"610403",label:"杨陵区"},{value:"610404",label:"渭城区"},{value:"610422",label:"三原县"},{value:"610423",label:"泾阳县"},{value:"610424",label:"乾县"},{value:"610425",label:"礼泉县"},{value:"610426",label:"永寿县"},{value:"610427",label:"彬县"},{value:"610428",label:"长武县"},{value:"610429",label:"旬邑县"},{value:"610430",label:"淳化县"},{value:"610431",label:"武功县"},{value:"610481",label:"兴平市"}]},{value:"610500",label:"渭南市",children:[{value:"610501",label:"市辖区"},{value:"610502",label:"临渭区"},{value:"610503",label:"华州区"},{value:"610522",label:"潼关县"},{value:"610523",label:"大荔县"},{value:"610524",label:"合阳县"},{value:"610525",label:"澄城县"},{value:"610526",label:"蒲城县"},{value:"610527",label:"白水县"},{value:"610528",label:"富平县"},{value:"610581",label:"韩城市"},{value:"610582",label:"华阴市"}]},{value:"610600",label:"延安市",children:[{value:"610601",label:"市辖区"},{value:"610602",label:"宝塔区"},{value:"610603",label:"安塞区"},{value:"610621",label:"延长县"},{value:"610622",label:"延川县"},{value:"610623",label:"子长县"},{value:"610625",label:"志丹县"},{value:"610626",label:"吴起县"},{value:"610627",label:"甘泉县"},{value:"610628",label:"富县"},{value:"610629",label:"洛川县"},{value:"610630",label:"宜川县"},{value:"610631",label:"黄龙县"},{value:"610632",label:"黄陵县"}]},{value:"610700",label:"汉中市",children:[{value:"610701",label:"市辖区"},{value:"610702",label:"汉台区"},{value:"610703",label:"南郑区"},{value:"610722",label:"城固县"},{value:"610723",label:"洋县"},{value:"610724",label:"西乡县"},{value:"610725",label:"勉县"},{value:"610726",label:"宁强县"},{value:"610727",label:"略阳县"},{value:"610728",label:"镇巴县"},{value:"610729",label:"留坝县"},{value:"610730",label:"佛坪县"}]},{value:"610800",label:"榆林市",children:[{value:"610801",label:"市辖区"},{value:"610802",label:"榆阳区"},{value:"610803",label:"横山区"},{value:"610822",label:"府谷县"},{value:"610824",label:"靖边县"},{value:"610825",label:"定边县"},{value:"610826",label:"绥德县"},{value:"610827",label:"米脂县"},{value:"610828",label:"佳县"},{value:"610829",label:"吴堡县"},{value:"610830",label:"清涧县"},{value:"610831",label:"子洲县"},{value:"610881",label:"神木市"}]},{value:"610900",label:"安康市",children:[{value:"610901",label:"市辖区"},{value:"610902",label:"汉滨区"},{value:"610921",label:"汉阴县"},{value:"610922",label:"石泉县"},{value:"610923",label:"宁陕县"},{value:"610924",label:"紫阳县"},{value:"610925",label:"岚皋县"},{value:"610926",label:"平利县"},{value:"610927",label:"镇坪县"},{value:"610928",label:"旬阳县"},{value:"610929",label:"白河县"}]},{value:"611000",label:"商洛市",children:[{value:"611001",label:"市辖区"},{value:"611002",label:"商州区"},{value:"611021",label:"洛南县"},{value:"611022",label:"丹凤县"},{value:"611023",label:"商南县"},{value:"611024",label:"山阳县"},{value:"611025",label:"镇安县"},{value:"611026",label:"柞水县"}]}]},{value:'620000',label:'甘肃省',children:[{value:"620100",label:"兰州市",children:[{value:"620101",label:"市辖区"},{value:"620102",label:"城关区"},{value:"620103",label:"七里河区"},{value:"620104",label:"西固区"},{value:"620105",label:"安宁区"},{value:"620111",label:"红古区"},{value:"620121",label:"永登县"},{value:"620122",label:"皋兰县"},{value:"620123",label:"榆中县"},{value:"620171",label:"兰州新区"}]},{value:"620200",label:"嘉峪关市",children:[{value:"620201",label:"市辖区"}]},{value:"620300",label:"金昌市",children:[{value:"620301",label:"市辖区"},{value:"620302",label:"金川区"},{value:"620321",label:"永昌县"}]},{value:"620400",label:"白银市",children:[{value:"620401",label:"市辖区"},{value:"620402",label:"白银区"},{value:"620403",label:"平川区"},{value:"620421",label:"靖远县"},{value:"620422",label:"会宁县"},{value:"620423",label:"景泰县"}]},{value:"620500",label:"天水市",children:[{value:"620501",label:"市辖区"},{value:"620502",label:"秦州区"},{value:"620503",label:"麦积区"},{value:"620521",label:"清水县"},{value:"620522",label:"秦安县"},{value:"620523",label:"甘谷县"},{value:"620524",label:"武山县"},{value:"620525",label:"张家川回族自治县"}]},{value:"620600",label:"武威市",children:[{value:"620601",label:"市辖区"},{value:"620602",label:"凉州区"},{value:"620621",label:"民勤县"},{value:"620622",label:"古浪县"},{value:"620623",label:"天祝藏族自治县"}]},{value:"620700",label:"张掖市",children:[{value:"620701",label:"市辖区"},{value:"620702",label:"甘州区"},{value:"620721",label:"肃南裕固族自治县"},{value:"620722",label:"民乐县"},{value:"620723",label:"临泽县"},{value:"620724",label:"高台县"},{value:"620725",label:"山丹县"}]},{value:"620800",label:"平凉市",children:[{value:"620801",label:"市辖区"},{value:"620802",label:"崆峒区"},{value:"620821",label:"泾川县"},{value:"620822",label:"灵台县"},{value:"620823",label:"崇信县"},{value:"620824",label:"华亭县"},{value:"620825",label:"庄浪县"},{value:"620826",label:"静宁县"},{value:"620871",label:"平凉工业园区"}]},{value:"620900",label:"酒泉市",children:[{value:"620901",label:"市辖区"},{value:"620902",label:"肃州区"},{value:"620921",label:"金塔县"},{value:"620922",label:"瓜州县"},{value:"620923",label:"肃北蒙古族自治县"},{value:"620924",label:"阿克塞哈萨克族自治县"},{value:"620981",label:"玉门市"},{value:"620982",label:"敦煌市"}]},{value:"621000",label:"庆阳市",children:[{value:"621001",label:"市辖区"},{value:"621002",label:"西峰区"},{value:"621021",label:"庆城县"},{value:"621022",label:"环县"},{value:"621023",label:"华池县"},{value:"621024",label:"合水县"},{value:"621025",label:"正宁县"},{value:"621026",label:"宁县"},{value:"621027",label:"镇原县"}]},{value:"621100",label:"定西市",children:[{value:"621101",label:"市辖区"},{value:"621102",label:"安定区"},{value:"621121",label:"通渭县"},{value:"621122",label:"陇西县"},{value:"621123",label:"渭源县"},{value:"621124",label:"临洮县"},{value:"621125",label:"漳县"},{value:"621126",label:"岷县"}]},{value:"621200",label:"陇南市",children:[{value:"621201",label:"市辖区"},{value:"621202",label:"武都区"},{value:"621221",label:"成县"},{value:"621222",label:"文县"},{value:"621223",label:"宕昌县"},{value:"621224",label:"康县"},{value:"621225",label:"西和县"},{value:"621226",label:"礼县"},{value:"621227",label:"徽县"},{value:"621228",label:"两当县"}]},{value:"622900",label:"临夏回族自治州",children:[{value:"622901",label:"临夏市"},{value:"622921",label:"临夏县"},{value:"622922",label:"康乐县"},{value:"622923",label:"永靖县"},{value:"622924",label:"广河县"},{value:"622925",label:"和政县"},{value:"622926",label:"东乡族自治县"},{value:"622927",label:"积石山保安族东乡族撒拉族自治县"}]},{value:"623000",label:"甘南藏族自治州",children:[{value:"623001",label:"合作市"},{value:"623021",label:"临潭县"},{value:"623022",label:"卓尼县"},{value:"623023",label:"舟曲县"},{value:"623024",label:"迭部县"},{value:"623025",label:"玛曲县"},{value:"623026",label:"碌曲县"},{value:"623027",label:"夏河县"}]}]},{value:'630000',label:'青海省',children:[{value:"630100",label:"西宁市",children:[{value:"630101",label:"市辖区"},{value:"630102",label:"城东区"},{value:"630103",label:"城中区"},{value:"630104",label:"城西区"},{value:"630105",label:"城北区"},{value:"630121",label:"大通回族土族自治县"},{value:"630122",label:"湟中县"},{value:"630123",label:"湟源县"}]},{value:"630200",label:"海东市",children:[{value:"630202",label:"乐都区"},{value:"630203",label:"平安区"},{value:"630222",label:"民和回族土族自治县"},{value:"630223",label:"互助土族自治县"},{value:"630224",label:"化隆回族自治县"},{value:"630225",label:"循化撒拉族自治县"}]},{value:"632200",label:"海北藏族自治州",children:[{value:"632221",label:"门源回族自治县"},{value:"632222",label:"祁连县"},{value:"632223",label:"海晏县"},{value:"632224",label:"刚察县"}]},{value:"632300",label:"黄南藏族自治州",children:[{value:"632321",label:"同仁县"},{value:"632322",label:"尖扎县"},{value:"632323",label:"泽库县"},{value:"632324",label:"河南蒙古族自治县"}]},{value:"632500",label:"海南藏族自治州",children:[{value:"632521",label:"共和县"},{value:"632522",label:"同德县"},{value:"632523",label:"贵德县"},{value:"632524",label:"兴海县"},{value:"632525",label:"贵南县"}]},{value:"632600",label:"果洛藏族自治州",children:[{value:"632621",label:"玛沁县"},{value:"632622",label:"班玛县"},{value:"632623",label:"甘德县"},{value:"632624",label:"达日县"},{value:"632625",label:"久治县"},{value:"632626",label:"玛多县"}]},{value:"632700",label:"玉树藏族自治州",children:[{value:"632701",label:"玉树市"},{value:"632722",label:"杂多县"},{value:"632723",label:"称多县"},{value:"632724",label:"治多县"},{value:"632725",label:"囊谦县"},{value:"632726",label:"曲麻莱县"}]},{value:"632800",label:"海西蒙古族藏族自治州",children:[{value:"632801",label:"格尔木市"},{value:"632802",label:"德令哈市"},{value:"632821",label:"乌兰县"},{value:"632822",label:"都兰县"},{value:"632823",label:"天峻县"},{value:"632857",label:"大柴旦行政委员会"},{value:"632858",label:"冷湖行政委员会"},{value:"632859",label:"茫崖行政委员会"}]}]},{value:'640000',label:'宁夏',children:[{value:"640100",label:"银川市",children:[{value:"640101",label:"市辖区"},{value:"640104",label:"兴庆区"},{value:"640105",label:"西夏区"},{value:"640106",label:"金凤区"},{value:"640121",label:"永宁县"},{value:"640122",label:"贺兰县"},{value:"640181",label:"灵武市"}]},{value:"640200",label:"石嘴山市",children:[{value:"640201",label:"市辖区"},{value:"640202",label:"大武口区"},{value:"640205",label:"惠农区"},{value:"640221",label:"平罗县"}]},{value:"640300",label:"吴忠市",children:[{value:"640301",label:"市辖区"},{value:"640302",label:"利通区"},{value:"640303",label:"红寺堡区"},{value:"640323",label:"盐池县"},{value:"640324",label:"同心县"},{value:"640381",label:"青铜峡市"}]},{value:"640400",label:"固原市",children:[{value:"640401",label:"市辖区"},{value:"640402",label:"原州区"},{value:"640422",label:"西吉县"},{value:"640423",label:"隆德县"},{value:"640424",label:"泾源县"},{value:"640425",label:"彭阳县"}]},{value:"640500",label:"中卫市",children:[{value:"640501",label:"市辖区"},{value:"640502",label:"沙坡头区"},{value:"640521",label:"中宁县"},{value:"640522",label:"海原县"}]}]},{value:'650000',label:'新疆',children:[{value:"650100",label:"乌鲁木齐市",children:[{value:"650101",label:"市辖区"},{value:"650102",label:"天山区"},{value:"650103",label:"沙依巴克区"},{value:"650104",label:"新市区"},{value:"650105",label:"水磨沟区"},{value:"650106",label:"头屯河区"},{value:"650107",label:"达坂城区"},{value:"650109",label:"米东区"},{value:"650121",label:"乌鲁木齐县"},{value:"650171",label:"乌鲁木齐经济技术开发区"},{value:"650172",label:"乌鲁木齐高新技术产业开发区"}]},{value:"650200",label:"克拉玛依市",children:[{value:"650201",label:"市辖区"},{value:"650202",label:"独山子区"},{value:"650203",label:"克拉玛依区"},{value:"650204",label:"白碱滩区"},{value:"650205",label:"乌尔禾区"}]},{value:"650400",label:"吐鲁番市",children:[{value:"650402",label:"高昌区"},{value:"650421",label:"鄯善县"},{value:"650422",label:"托克逊县"}]},{value:"650500",label:"哈密市",children:[{value:"650502",label:"伊州区"},{value:"650521",label:"巴里坤哈萨克自治县"},{value:"650522",label:"伊吾县"}]},{value:"652300",label:"昌吉回族自治州",children:[{value:"652301",label:"昌吉市"},{value:"652302",label:"阜康市"},{value:"652323",label:"呼图壁县"},{value:"652324",label:"玛纳斯县"},{value:"652325",label:"奇台县"},{value:"652327",label:"吉木萨尔县"},{value:"652328",label:"木垒哈萨克自治县"}]},{value:"652700",label:"博尔塔拉蒙古自治州",children:[{value:"652701",label:"博乐市"},{value:"652702",label:"阿拉山口市"},{value:"652722",label:"精河县"},{value:"652723",label:"温泉县"}]},{value:"652800",label:"巴音郭楞蒙古自治州",children:[{value:"652801",label:"库尔勒市"},{value:"652822",label:"轮台县"},{value:"652823",label:"尉犁县"},{value:"652824",label:"若羌县"},{value:"652825",label:"且末县"},{value:"652826",label:"焉耆回族自治县"},{value:"652827",label:"和静县"},{value:"652828",label:"和硕县"},{value:"652829",label:"博湖县"},{value:"652871",label:"库尔勒经济技术开发区"}]},{value:"652900",label:"阿克苏地区",children:[{value:"652901",label:"阿克苏市"},{value:"652922",label:"温宿县"},{value:"652923",label:"库车县"},{value:"652924",label:"沙雅县"},{value:"652925",label:"新和县"},{value:"652926",label:"拜城县"},{value:"652927",label:"乌什县"},{value:"652928",label:"阿瓦提县"},{value:"652929",label:"柯坪县"}]},{value:"653000",label:"克孜勒苏柯尔克孜自治州",children:[{value:"653001",label:"阿图什市"},{value:"653022",label:"阿克陶县"},{value:"653023",label:"阿合奇县"},{value:"653024",label:"乌恰县"}]},{value:"653100",label:"喀什地区",children:[{value:"653101",label:"喀什市"},{value:"653121",label:"疏附县"},{value:"653122",label:"疏勒县"},{value:"653123",label:"英吉沙县"},{value:"653124",label:"泽普县"},{value:"653125",label:"莎车县"},{value:"653126",label:"叶城县"},{value:"653127",label:"麦盖提县"},{value:"653128",label:"岳普湖县"},{value:"653129",label:"伽师县"},{value:"653130",label:"巴楚县"},{value:"653131",label:"塔什库尔干塔吉克自治县"}]},{value:"653200",label:"和田地区",children:[{value:"653201",label:"和田市"},{value:"653221",label:"和田县"},{value:"653222",label:"墨玉县"},{value:"653223",label:"皮山县"},{value:"653224",label:"洛浦县"},{value:"653225",label:"策勒县"},{value:"653226",label:"于田县"},{value:"653227",label:"民丰县"}]},{value:"654000",label:"伊犁哈萨克自治州",children:[{value:"654002",label:"伊宁市"},{value:"654003",label:"奎屯市"},{value:"654004",label:"霍尔果斯市"},{value:"654021",label:"伊宁县"},{value:"654022",label:"察布查尔锡伯自治县"},{value:"654023",label:"霍城县"},{value:"654024",label:"巩留县"},{value:"654025",label:"新源县"},{value:"654026",label:"昭苏县"},{value:"654027",label:"特克斯县"},{value:"654028",label:"尼勒克县"}]},{value:"654200",label:"塔城地区",children:[{value:"654201",label:"塔城市"},{value:"654202",label:"乌苏市"},{value:"654221",label:"额敏县"},{value:"654223",label:"沙湾县"},{value:"654224",label:"托里县"},{value:"654225",label:"裕民县"},{value:"654226",label:"和布克赛尔蒙古自治县"}]},{value:"654300",label:"阿勒泰地区",children:[{value:"654301",label:"阿勒泰市"},{value:"654321",label:"布尔津县"},{value:"654322",label:"富蕴县"},{value:"654323",label:"福海县"},{value:"654324",label:"哈巴河县"},{value:"654325",label:"青河县"},{value:"654326",label:"吉木乃县"}]},{value:"659000",label:"自治区直辖县级行政区划",children:[{value:"659001",label:"石河子市"},{value:"659002",label:"阿拉尔市"},{value:"659003",label:"图木舒克市"},{value:"659004",label:"五家渠市"},{value:"659006",label:"铁门关市"}]}]},{value:'660000',label:'台湾省',children:[{value:"660100",label:"台北市",children:[{value:"660101",label:"中正区"},{value:"660102",label:"大同区"},{value:"660103",label:"中山区"},{value:"660104",label:"松山区"},{value:"660105",label:"大安区"},{value:"660106",label:"万华区"},{value:"660107",label:"信义区"},{value:"660108",label:"士林区"},{value:"660109",label:"北投区"},{value:"660110",label:"内湖区"},{value:"660111",label:"南港区"},{value:"660112",label:"文山区"}]},{value:"660200",label:"高雄市",children:[{value:"660201",label:"新兴区"},{value:"660202",label:"前金区"},{value:"660203",label:"芩雅区"},{value:"660204",label:"盐埕区"},{value:"660205",label:"鼓山区"},{value:"660206",label:"旗津区"},{value:"660207",label:"前镇区"},{value:"660208",label:"三民区"},{value:"660209",label:"左营区"},{value:"660210",label:"楠梓区"},{value:"660211",label:"小港区"}]},{value:"660300",label:"台南市",children:[{value:"660301",label:"中西区"},{value:"660302",label:"东区"},{value:"660303",label:"南区"},{value:"660304",label:"北区"},{value:"660305",label:"安平区"},{value:"660306",label:"安南区"}]},{value:"660400",label:"台中市",children:[{value:"660401",label:"中区"},{value:"660402",label:"东区"},{value:"660403",label:"南区"},{value:"660404",label:"西区"},{value:"660405",label:"北区"},{value:"660406",label:"北屯区"},{value:"660407",label:"西屯区"},{value:"660408",label:"南屯区"}]},{value:"660500",label:"金门县",children:[{value:"660501",label:"金门县"}]},{value:"660600",label:"南投县",children:[{value:"660601",label:"南投县",}]},{value:"660700",label:"基隆市",children:[{value:"660701",label:"仁爱区"},{value:"660702",label:"信义区"},{value:"660703",label:"中正区"},{value:"660704",label:"中山区"},{value:"660705",label:"安乐区"},{value:"660706",label:"暖暖区"},{value:"660707",label:"七堵区"}]},{value:"660800",label:"新竹市",children:[{value:"660801",label:"东区"},{value:"660802",label:"北区"},{value:"660803",label:"香山区"}]},{value:"660900",label:"嘉义市",children:[{value:"660901",label:"东区"},{value:"660902",label:"西区"}]},{value:"661000",label:"新北市",children:[{value:"661001",label:"新北市"}]},{value:"661100",label:"宜兰县",children:[{value:"661100",label:"宜兰县"}]},{value:"661200",label:"新竹县",children:[{value:"661201",label:"新竹县"}]},{value:"661300",label:"桃园县",children:[{value:"661301",label:"桃园县"}]},{value:"661400",label:"苗栗县",children:[{value:"661401",label:"苗栗县"}]},{value:"661500",label:"彰化县",children:[{value:"661501",label:"彰化县"}]},{value:"661600",label:"嘉义县",children:[{value:"661601",label:"嘉义县"}]},{value:"661700",label:"云林县",children:[{value:"661701",label:"云林县"}]},{value:"661800",label:"屏东县",children:[{value:"661801",label:"屏东县"}]},{value:"661900",label:"台东县",children:[{value:"661901",label:"台东县"}]},{value:"662000",label:"花莲县",children:[{value:"662001",label:"花莲县"}]},{value:"662100",label:"澎湖县",children:[{value:"662101",label:"澎湖县"}]}]},{value:'670000',label:'香港',children:[{value:"670100",label:"香港岛",children:[{value:"670101",label:"中西区"},{value:"670102",label:"湾仔区"},{value:"670103",label:"东区"},{value:"670104",label:"南区"}]},{value:"670200",label:"九龙半岛",children:[{value:"670201",label:"九龙城区"},{value:"670202",label:"油尖旺区"},{value:"670203",label:"深水埗区"},{value:"670204",label:"黄大仙区"},{value:"670205",label:"观塘区"}]},{value:"670300",label:"新界",children:[{value:"670301",label:"北区"},{value:"670302",label:"大埔区"},{value:"670303",label:"沙田区"},{value:"670304",label:"西贡区"},{value:"670305",label:"元朗区"},{value:"670306",label:"屯门区"},{value:"670307",label:"荃湾区"},{value:"670308",label:"葵青区"},{value:"670309",label:"离岛区"}]}]},{value:'680000',label:'澳门',children:[{value:"680100",label:"澳门半岛",children:[{value:"680101",label:"花地玛堂区"},{value:"680102",label:"圣安多尼堂区"},{value:"680103",label:"大堂区"},{value:"680104",label:"望德堂区"},{value:"680105",label:"风顺堂区"}]},{value:"680200",label:"离岛",children:[{value:"680201",label:"嘉模堂区"},{value:"680202",label:"圣方济各堂区"}]}]}];export default cityData \ No newline at end of file diff --git a/components/w-picker/date-picker.vue b/components/w-picker/date-picker.vue new file mode 100644 index 0000000..c0154d5 --- /dev/null +++ b/components/w-picker/date-picker.vue @@ -0,0 +1,742 @@ + ++ ++ + ++ + + ++ ++ + + + + + ++ + ++ + +重新上传 ++ ++ + +{{text}} +{{`${imagelist.length}/${imgsize}`}} ++ + + + + + diff --git a/components/w-picker/half-picker.vue b/components/w-picker/half-picker.vue new file mode 100644 index 0000000..0fdfb33 --- /dev/null +++ b/components/w-picker/half-picker.vue @@ -0,0 +1,345 @@ + ++ ++ +{{item}}年 ++ ++ +{{item}}年 ++ +{{item}}月 ++ ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ +{{item}}时 ++ ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ +{{item}}时 ++ +{{item}}分 ++ ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ +{{item}}时 ++ +{{item}}分 ++ +{{item}}秒 ++ + + + + + diff --git a/components/w-picker/linkage-picker.vue b/components/w-picker/linkage-picker.vue new file mode 100644 index 0000000..290422d --- /dev/null +++ b/components/w-picker/linkage-picker.vue @@ -0,0 +1,274 @@ + ++ ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ +{{item}} ++ + + + + + + diff --git a/components/w-picker/range-picker.vue b/components/w-picker/range-picker.vue new file mode 100644 index 0000000..7dd8b5b --- /dev/null +++ b/components/w-picker/range-picker.vue @@ -0,0 +1,344 @@ + ++ ++ +{{item[nodeKey]}} ++ + + + + + diff --git a/components/w-picker/region-picker.vue b/components/w-picker/region-picker.vue new file mode 100644 index 0000000..34c1f40 --- /dev/null +++ b/components/w-picker/region-picker.vue @@ -0,0 +1,183 @@ + ++ ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ +- ++ +{{item}}年 ++ +{{item}}月 ++ +{{item}}日 ++ + + + + + + diff --git a/components/w-picker/selector-picker.vue b/components/w-picker/selector-picker.vue new file mode 100644 index 0000000..6ce2ced --- /dev/null +++ b/components/w-picker/selector-picker.vue @@ -0,0 +1,129 @@ + ++ ++ +{{item.label}} ++ +{{item.label}} ++ +{{item.label}} ++ + + + + + diff --git a/components/w-picker/shortterm-picker.vue b/components/w-picker/shortterm-picker.vue new file mode 100644 index 0000000..d133cf4 --- /dev/null +++ b/components/w-picker/shortterm-picker.vue @@ -0,0 +1,250 @@ + ++ ++ +{{item[nodeKey]}} ++ + + + + + diff --git a/components/w-picker/time-picker.vue b/components/w-picker/time-picker.vue new file mode 100644 index 0000000..b00b0ab --- /dev/null +++ b/components/w-picker/time-picker.vue @@ -0,0 +1,218 @@ + ++ ++ +{{item.label}} ++ +{{item.label}}时 ++ +{{item.label}}分 ++ + + + + + + diff --git a/components/w-picker/w-picker.css b/components/w-picker/w-picker.css new file mode 100644 index 0000000..fb42e78 --- /dev/null +++ b/components/w-picker/w-picker.css @@ -0,0 +1,26 @@ +.w-picker-flex2{ + flex:2; +} +.w-picker-flex1{ + flex:1; +} +.w-picker-view { + width: 100%; + height: 476upx; + overflow: hidden; + background-color: rgba(255, 255, 255, 1); + z-index: 666; +} +.d-picker-view{ + height: 100%; +} + +.w-picker-item { + text-align: center; + width: 100%; + height: 88upx; + line-height: 88upx; + text-overflow: ellipsis; + white-space: nowrap; + font-size: 30upx; +} \ No newline at end of file diff --git a/components/w-picker/w-picker.vue b/components/w-picker/w-picker.vue new file mode 100644 index 0000000..d8f7d76 --- /dev/null +++ b/components/w-picker/w-picker.vue @@ -0,0 +1,340 @@ + ++ ++ +{{item}}时 ++ +{{item}}分 ++ +{{item}}秒 ++ + + + + + diff --git a/components/wfalls-flow.vue b/components/wfalls-flow.vue new file mode 100644 index 0000000..e30ab36 --- /dev/null +++ b/components/wfalls-flow.vue @@ -0,0 +1,183 @@ + ++ + ++ +取消 ++ 确定 ++ + ++ + ++ + ++ + ++ + ++ + ++ + ++ ++ + + + + + diff --git a/components/xt-verify-code.vue b/components/xt-verify-code.vue new file mode 100644 index 0000000..8ca8948 --- /dev/null +++ b/components/xt-verify-code.vue @@ -0,0 +1,280 @@ + ++ ++ ++ {{item.status==1?'审核中':'已驳回'}} + ++ + ++ + ++ +{{item.title}} ++ ++ ++ {{item.coach_name}} ++ {{item.distance}} + ++ + + + + + + + diff --git a/dynamic/pages/detail.vue b/dynamic/pages/detail.vue new file mode 100644 index 0000000..1c588b5 --- /dev/null +++ b/dynamic/pages/detail.vue @@ -0,0 +1,1384 @@ + ++ + + ++ + ++ + ++ {{ code[index] | codeFormat(isPassword) }} ++ + + + + + diff --git a/dynamic/pages/follow.vue b/dynamic/pages/follow.vue new file mode 100644 index 0000000..11afe49 --- /dev/null +++ b/dynamic/pages/follow.vue @@ -0,0 +1,206 @@ + ++ + ++ + + ++ 回到首页 ++ ++ + + + ++ + ++ + + + ++ + + ++ ++ ++ ++ + ++ ++ ++ {{detail.coach_info.coach_name}} + +{{textType[detail.coach_info.work_status]}} + ++ +预约 ++ {{detail.follow_status?'已关注':'关注'}} + +{{detail.title}} ++ + {{detail.text.substring(0,42) + '...'}} + + 展开 + ++ + + + ++ + + 收起 +{{detail.text}} ++ + + +{{detail.friend_time}} ++ {{detail.distance}} + ++ + +全部评论 + ++ ++ +评论千万条, 礼貌第一条 ++ ++ + ++ ++ +{{item.nickName}} ++ 审核中 + +{{item.friend_time}} +{{item.text}} ++ ++ + + ++ + + + + ++ + + ++ + + + + + + ++ + ++ + ++ ++ ++ ++ ++ + ++ {{detail.coach_info.coach_name}} + +{{textType[detail.coach_info.work_status]}} + ++ +预约 + ++ {{detail.follow_status?'已关注':'关注'}} + ++ +{{detail.title}} ++ + {{detail.text.substring(0,42) + '...'}} + + 展开 + ++ + + + ++ + + 收起 +{{detail.text}} ++ + + +{{detail.friend_time}} ++ {{detail.distance}} + ++ ++ + + ++ ++ + {{!detail.thumbs_num ? '点赞' : detail.thumbs_num}} + ++ + {{!detail.comment_num ? '评论' : detail.comment_num}} + ++ + + + ++ ++ + + ++ ++ + + + + + ++ ++ ++ {{detail.coach_info.coach_name}} ++ 不想看Ta的作品 + + + + + +分享该动态 + + +取消 + ++ + + + ++ ++ + +全部评论 + ++ ++ ++ +评论千万条, 礼貌第一条 ++ ++ + ++ ++ +{{item.nickName}} ++ 审核中 + +{{item.friend_time}} +{{item.text}} ++ ++ ++ + + ++ + ++ ++ ++ + ++ ++ {{detail.coach_info.coach_name}} + 从业{{detail.coach_info.work_time}}年 +更多详情 ++ + ++ ++ + ++ {{item.title}} + +{{item.total_sale}}人选择 ++ ++ +¥{{item.init_price}} + +¥{{item.price}} / + {{item.time_long}}分钟 ++ ++ + + + ++ ++ + + +合计: ++ ¥{{carList.car_price}} + +提交订单 + ++ + + + + + + diff --git a/dynamic/pages/technician/comment.vue b/dynamic/pages/technician/comment.vue new file mode 100644 index 0000000..6887ac3 --- /dev/null +++ b/dynamic/pages/technician/comment.vue @@ -0,0 +1,194 @@ + ++ ++ + ++ +{{item.coach_name}} + ++ {{item.distance}} + ++ +已接单 ++ {{item.order_num}} + +粉丝数 ++ {{item.fans_num}} + ++ ++ + + + + + + + diff --git a/dynamic/pages/technician/detail.vue b/dynamic/pages/technician/detail.vue new file mode 100644 index 0000000..f9a56e6 --- /dev/null +++ b/dynamic/pages/technician/detail.vue @@ -0,0 +1,1342 @@ + ++ ++ + ++ ++ ++ +{{item.nickName}} +审核中 + +评论了你的动态 +{{item.friend_time}} + ++ {{item.text}} ++ ++ + + + + + + + + + diff --git a/dynamic/pages/technician/edit.vue b/dynamic/pages/technician/edit.vue new file mode 100644 index 0000000..dde2995 --- /dev/null +++ b/dynamic/pages/technician/edit.vue @@ -0,0 +1,273 @@ + ++ + + ++ 回到首页 ++ ++ + + + ++ ++ + ++ ++ ++ ++ + ++ ++ + ++ {{detail.coach_info.coach_name}} + +{{textType[detail.coach_info.work_status]}} + ++ ++ {{detail.status==1?'审核中': '已驳回'}} + ++ +预约 ++ {{detail.follow_status?'已关注':'关注'}} + +{{detail.title}} ++ + {{detail.text.substring(0,42) + '...'}} + + 展开 + ++ + + + ++ + + 收起 +{{detail.text}} ++ + + +{{detail.friend_time}} ++ {{detail.distance}} + ++ + +全部评论 ++ ++ +评论千万条, 礼貌第一条 ++ ++ + ++ ++ +{{item.nickName}} ++ 审核中 + +{{item.friend_time}} +{{item.text}} ++ ++ + + ++ ++ + ++ + + + + + + ++ + ++ + ++ + + ++ ++ ++ ++ + ++ {{detail.coach_info.coach_name}} + +{{textType[detail.coach_info.work_status]}} + ++ ++ ++ {{detail.status==1?'审核中': '已驳回'}} + ++ 全部评论 + ++ +预约 + ++ {{detail.follow_status?'已关注':'关注'}} + ++ +{{detail.title}} ++ + {{detail.text.substring(0,42) + '...'}} + + 展开 + ++ + + + ++ + + 收起 +{{detail.text}} ++ + + +{{detail.friend_time}} ++ {{detail.distance}} + ++ + ++ + + ++ + ++ + {{!detail.thumbs_num ? '点赞' : detail.thumbs_num}} + ++ + {{!detail.comment_num ? '评论' : detail.comment_num}} + ++ ++ + + + + + + + ++ +编辑 + +删除 + +驳回原因 + +取消 + ++ + + + ++ + +驳回原因 ++ +{{detail.check_text}} ++ + + + ++ + +全部评论 + ++ ++ ++ +评论千万条, 礼貌第一条 ++ ++ + ++ ++ +{{item.nickName}} ++ 审核中 + +{{item.friend_time}} +{{item.text}} ++ ++ ++ + + ++ + + ++ ++ ++ + ++ ++ {{detail.coach_info.coach_name}} + 从业{{detail.coach_info.work_time}}年 +更多详情 ++ + ++ ++ + ++ {{item.title}} + +{{item.total_sale}}人选择 ++ ++ +¥{{item.init_price}} + +¥{{item.price}} / + {{item.time_long}}分钟 ++ ++ + + + ++ ++ + + +合计: ++ ¥{{carList.car_price}} + +提交订单 + ++ + + + + + + diff --git a/dynamic/pages/technician/follow.vue b/dynamic/pages/technician/follow.vue new file mode 100644 index 0000000..4557753 --- /dev/null +++ b/dynamic/pages/technician/follow.vue @@ -0,0 +1,130 @@ + ++ ++ ++ ++ ++ ++ + + + + + + ++ {{subForm.lat ? subForm.address : '添加地点'}} + + ++ + ++ + + + + + diff --git a/dynamic/pages/technician/list.vue b/dynamic/pages/technician/list.vue new file mode 100644 index 0000000..0832e84 --- /dev/null +++ b/dynamic/pages/technician/list.vue @@ -0,0 +1,341 @@ + ++ ++ + ++ +{{item.nickName}} +开始关注了你 +{{item.friend_time}} ++ ++ + + + + + + + diff --git a/dynamic/pages/technician/thumbs.vue b/dynamic/pages/technician/thumbs.vue new file mode 100644 index 0000000..56de56e --- /dev/null +++ b/dynamic/pages/technician/thumbs.vue @@ -0,0 +1,126 @@ + ++ + ++ ++ ++ ++ + ++ {{count.thumbs_num < 100 ? count.thumbs_num : '99+'}} + +收获的赞 ++ ++ + ++ {{count.follow_num < 100 ? count.follow_num : '99+'}} + +新增关注 ++ ++ + ++ {{count.comment_num < 100 ? count.comment_num : '99+'}} + +收获的评论 ++ ++ +我的发布 ++ {{statusList[statusInd].title}} + ++ ++ {{item.title}} + ++ + ++ + + + + + + + diff --git a/jweixin-module/README.md b/jweixin-module/README.md new file mode 100644 index 0000000..7c91d7b --- /dev/null +++ b/jweixin-module/README.md @@ -0,0 +1,30 @@ +# jweixin-module + +微信JS-SDK + +## 安装 + +### NPM + +```shell +npm install jweixin-module --save +``` + +### UMD + +```http +https://unpkg.com/jweixin-module/out/index.js +``` + +## 使用 + +```js +var jweixin = require('jweixin-module') +jweixin.ready(function(){ + // TODO +}); +``` + +## 完整API + +>[微信JS-SDK说明文档](https://mp.weixin.qq.com/wiki?t=resource/res_main&id=mp1421141115) diff --git a/jweixin-module/lib/index.js b/jweixin-module/lib/index.js new file mode 100644 index 0000000..ae4baaf --- /dev/null +++ b/jweixin-module/lib/index.js @@ -0,0 +1 @@ +!function(e,n){"function"==typeof define&&(define.amd||define.cmd)?define(function(){return n(e)}):n(e,!0)}(window,function(o,e){if(!o.jWeixin){var n,c={config:"preVerifyJSAPI",onMenuShareTimeline:"menu:share:timeline",onMenuShareAppMessage:"menu:share:appmessage",onMenuShareQQ:"menu:share:qq",onMenuShareWeibo:"menu:share:weiboApp",onMenuShareQZone:"menu:share:QZone",previewImage:"imagePreview",getLocation:"geoLocation",openProductSpecificView:"openProductViewWithPid",addCard:"batchAddCard",openCard:"batchViewCard",chooseWXPay:"getBrandWCPayRequest",openEnterpriseRedPacket:"getRecevieBizHongBaoRequest",startSearchBeacons:"startMonitoringBeacons",stopSearchBeacons:"stopMonitoringBeacons",onSearchBeacons:"onBeaconsInRange",consumeAndShareCard:"consumedShareCard",openAddress:"editAddress"},a=function(){var e={};for(var n in c)e[c[n]]=n;return e}(),i=o.document,t=i.title,r=navigator.userAgent.toLowerCase(),s=navigator.platform.toLowerCase(),d=!(!s.match("mac")&&!s.match("win")),u=-1!=r.indexOf("wxdebugger"),l=-1!=r.indexOf("micromessenger"),p=-1!=r.indexOf("android"),f=-1!=r.indexOf("iphone")||-1!=r.indexOf("ipad"),m=(n=r.match(/micromessenger\/(\d+\.\d+\.\d+)/)||r.match(/micromessenger\/(\d+\.\d+)/))?n[1]:"",g={initStartTime:L(),initEndTime:0,preVerifyStartTime:0,preVerifyEndTime:0},h={version:1,appId:"",initTime:0,preVerifyTime:0,networkType:"",isPreVerifyOk:1,systemType:f?1:p?2:-1,clientVersion:m,url:encodeURIComponent(location.href)},v={},S={_completes:[]},y={state:0,data:{}};O(function(){g.initEndTime=L()});var I=!1,_=[],w={config:function(e){B("config",v=e);var t=!1!==v.check;O(function(){if(t)M(c.config,{verifyJsApiList:C(v.jsApiList),verifyOpenTagList:C(v.openTagList)},function(){S._complete=function(e){g.preVerifyEndTime=L(),y.state=1,y.data=e},S.success=function(e){h.isPreVerifyOk=0},S.fail=function(e){S._fail?S._fail(e):y.state=-1};var t=S._completes;return t.push(function(){!function(){if(!(d||u||v.debug||m<"6.0.2"||h.systemType<0)){var i=new Image;h.appId=v.appId,h.initTime=g.initEndTime-g.initStartTime,h.preVerifyTime=g.preVerifyEndTime-g.preVerifyStartTime,w.getNetworkType({isInnerInvoke:!0,success:function(e){h.networkType=e.networkType;var n="https://open.weixin.qq.com/sdk/report?v="+h.version+"&o="+h.isPreVerifyOk+"&s="+h.systemType+"&c="+h.clientVersion+"&a="+h.appId+"&n="+h.networkType+"&i="+h.initTime+"&p="+h.preVerifyTime+"&u="+h.url;i.src=n}})}}()}),S.complete=function(e){for(var n=0,i=t.length;n", + "+ ++ + ++ +{{item.nickName}} +赞了你的动态 +{{item.friend_time}} ++ + ++ + ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " ", + " " + ], + "abiFilters" : [ "armeabi-v7a", "arm64-v8a" ], + "autoSdkPermissions" : true + }, + "icons" : { + // 改为自己的 logo + "android" : { + "hdpi" : "unpackage/res/icons/72x72.png", + "xhdpi" : "unpackage/res/icons/96x96.png", + "xxhdpi" : "unpackage/res/icons/144x144.png", + "xxxhdpi" : "unpackage/res/icons/192x192.png" + }, + "ios" : { + "appstore" : "unpackage/res/icons/1024x1024.png", + "iphone" : { + "app@2x" : "unpackage/res/icons/120x120.png", + "app@3x" : "unpackage/res/icons/180x180.png", + "spotlight@2x" : "unpackage/res/icons/80x80.png", + "spotlight@3x" : "unpackage/res/icons/120x120.png", + "settings@2x" : "unpackage/res/icons/58x58.png", + "settings@3x" : "unpackage/res/icons/87x87.png", + "notification@2x" : "unpackage/res/icons/40x40.png", + "notification@3x" : "unpackage/res/icons/60x60.png" + }, + "ipad" : { + "app" : "unpackage/res/icons/76x76.png", + "app@2x" : "unpackage/res/icons/152x152.png", + "proapp@2x" : "unpackage/res/icons/167x167.png", + "spotlight" : "unpackage/res/icons/40x40.png", + "spotlight@2x" : "unpackage/res/icons/80x80.png", + "settings" : "unpackage/res/icons/29x29.png", + "settings@2x" : "unpackage/res/icons/58x58.png", + "notification" : "unpackage/res/icons/20x20.png", + "notification@2x" : "unpackage/res/icons/40x40.png" + } + } + }, + "ios" : { + "capabilities" : { + "entitlements" : { + "com.apple.developer.associated-domains" : [ "applinks:testapps.cncnconnect.com" ] // 改为自己的 + } + }, + "dSYMs" : false, + "privacyDescription" : { + // ios隐私信息访问许可描述 + "NSPhotoLibraryUsageDescription" : "允许手机存储权限读写相册,注册服务人员/退款时需从相册中选择图片", + "NSPhotoLibraryAddUsageDescription" : "允许手机存储权限读写相册,用于保存图片", + "NSCameraUsageDescription" : "需要访问相册,以便于上传服务人员资格证书、工作形象照等功能", + "NSLocationWhenInUseUsageDescription" : "允许获取您的位置信息,以便获取您附近的服务人员,更好的为您服务", + "NSLocationAlwaysUsageDescription" : "允许获取您的位置信息,以便获取您附近的服务人员,更好的为您服务", + "NSLocationAlwaysAndWhenInUseUsageDescription" : "允许获取您的位置信息,以便获取您附近的服务人员,更好的为您服务" + } + } + } + }, + "nativePlugins" : {}, + "_spaceID" : "8a1db412-049f-4be6-894a-755ffe5ebe5b" +} diff --git a/package (2).json b/package (2).json new file mode 100644 index 0000000..f7d3409 --- /dev/null +++ b/package (2).json @@ -0,0 +1,17 @@ +{ + "id": "jarvis-timePickerPopup", + "name": "时间范围弹窗选择器", + "displayName": "时间范围弹窗选择器", + "version": "1.0.0", + "description": "时间范围弹窗选择器:使用uni-popup+picker-view实现", + "keywords": [ + "时间选择器", + "时间范围" + ], + "dcloudext": { + "category": [ + "前端组件", + "通用组件" + ] + } +} \ No newline at end of file diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 0000000..1861f19 --- /dev/null +++ b/package-lock.json @@ -0,0 +1,16 @@ +{ + "requires": true, + "lockfileVersion": 1, + "dependencies": { + "jweixin-module": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/jweixin-module/-/jweixin-module-1.6.0.tgz", + "integrity": "sha512-dGk9cf+ipipHmtzYmKZs5B2toX+p4hLyllGLF6xuC8t+B05oYxd8fYoaRz0T30U2n3RUv8a4iwvjhA+OcYz52w==" + }, + "vue-i18n": { + "version": "8.28.2", + "resolved": "https://registry.npmjs.org/vue-i18n/-/vue-i18n-8.28.2.tgz", + "integrity": "sha512-C5GZjs1tYlAqjwymaaCPDjCyGo10ajUphiwA922jKt9n7KPpqR7oM1PCwYzhB/E7+nT3wfdG3oRre5raIT1rKA==" + } + } +} diff --git a/package.json b/package.json new file mode 100644 index 0000000..5bd9dac --- /dev/null +++ b/package.json @@ -0,0 +1,6 @@ +{ + "dependencies": { + "jweixin-module": "^1.6.0", + "vue-i18n": "^8.18.2" + } +} diff --git a/pages.json b/pages.json new file mode 100644 index 0000000..4cf9bfa --- /dev/null +++ b/pages.json @@ -0,0 +1,807 @@ +{ + "pages": [{ + "path": "pages/service", + "style": { + "navigationBarTitleText": "首页", + //#ifndef H5 + "navigationStyle": "custom", + //#endif + "enablePullDownRefresh": true + } + }, + { + "path": "pages/map", + "style": { + "navigationBarTitleText": "技师", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/technician", + "style": { + "navigationBarTitleText": "", + "navigationStyle": "custom", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/shopstore", + "style": { + "navigationBarTitleText": "门店", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/dynamic", + "style": { + "navigationBarTitleText": "", + "navigationStyle": "custom", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/order", + "style": { + "navigationBarTitleText": "订单", + //#ifndef H5 + "navigationStyle": "custom", + //#endif + "enablePullDownRefresh": true + } + }, + { + "path": "pages/mine", + "style": { + "navigationBarTitleText": "我的", + //#ifndef H5 + "navigationStyle": "custom", + //#endif + "enablePullDownRefresh": true + } + } + //#ifndef MP-WEIXIN + , { + "path": "pages/login", // app H5登陆页面 + "style": { + "navigationBarTitleText": "", + "navigationStyle": "custom", + "navigationBarTextStyle": "black", + "navigationBarBackgroundColor": "#ffffff" + } + }, + { + "path" : "pages/test", + "style" : + { + "navigationBarTitleText" : "", + "enablePullDownRefresh" : false + } + } + //#endif + ], + "subPackages": [ + // 用户端 + { + "root": "user/", + "pages": [{ + "path": "pages/detail", + "style": { + "navigationBarTitleText": "服务详情" + } + }, + { + "path": "pages/article", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/protocol", + "style": { + "navigationBarTitleText": "隐私政策" + } + }, + { + "path": "pages/information", + "style": { + "navigationBarTitleText": "服务协议" + } + }, + { + "path": "pages/collect", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/technician-info", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/merchant-info", + "style": { + "navigationBarTitleText": "商户信息" + } + }, + { + "path": "pages/comment", + "style": { + "navigationBarTitleText": "评论", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/order", + "style": { + "navigationBarTitleText": "下单" + } + }, + { + "path": "pages/choose-time", + "style": { + "navigationBarTitleText": "选择时间" + } + }, + { + "path": "pages/choose-technician", + "style": { + "navigationBarTitleText": "", + "navigationStyle": "custom", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/address/list", + "style": { + "navigationBarTitleText": "地址列表", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/address/edit", + "style": { + "navigationBarTitleText": "添加新地址" + } + }, + { + "path": "pages/order/bell-list", + "style": { + "navigationBarTitleText": "加钟订单", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/order/sign", + "style": { + "navigationBarTitleText": "签名确认" + } + }, + { + "path": "pages/order/detail", + "style": { + "navigationBarTitleText": "订单详情" + } + }, + { + "path": "pages/order/refund", + "style": { + "navigationBarTitleText": "申请退款" + } + }, + { + "path": "pages/order/evaluate", + "style": { + "navigationBarTitleText": "评价" + } + }, + { + "path": "pages/refund/list", + "style": { + "navigationBarTitleText": "售后/退款", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/refund/detail", + "style": { + "navigationBarTitleText": "售后详情" + } + }, { + "path": "pages/channel/apply", + "style": { + "navigationBarTitleText": "" + } + }, { + "path": "pages/channel/income", + "style": { + "navigationBarTitleText": "我是渠道商", + "enablePullDownRefresh": true + } + }, { + "path": "pages/channel/poster", + "style": { + "navigationBarTitleText": "渠道码" + } + }, { + "path": "pages/salesman/apply", + "style": { + "navigationBarTitleText": "" + } + }, { + "path": "pages/salesman/income", + "style": { + "navigationBarTitleText": "我是业务员", + "enablePullDownRefresh": true + } + }, { + "path": "pages/salesman/record", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/service/list", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/service/cate", + "style": { + "navigationBarTitleText": "全部分类" + } + }, { + "path": "pages/common/web", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/common/video", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/coupon/list", + "style": { + "navigationBarTitleText": "我的卡券", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/coupon/use", + "style": { + "navigationBarTitleText": "选择卡券", + "enablePullDownRefresh": true + } + }, { + "path": "pages/coupon/share", + "style": { + "navigationBarTitleText": "分享有奖", + "enablePullDownRefresh": true + } + }, { + "path": "pages/coupon/poster", + "style": { + "navigationBarTitleText": "我的邀请码" + } + }, { + "path": "pages/stored/list", + "style": { + "navigationBarTitleText": "余额充值", + "enablePullDownRefresh": true + } + }, { + "path": "pages/stored/choose-technician", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/stored/commission", + "style": { + "navigationBarTitleText": "佣金流水", + "enablePullDownRefresh": true + } + }, { + "path": "pages/stored/record", + "style": { + "navigationBarTitleText": "充值记录", + "enablePullDownRefresh": true + } + }, { + "path": "pages/stored/consume", + "style": { + "navigationBarTitleText": "消费明细", + "enablePullDownRefresh": true + } + }, { + "path": "pages/stored/poster", + "style": { + "navigationBarTitleText": "邀请好友" + } + }, { + "path": "pages/distribution/apply", + "style": { + "navigationBarTitleText": "申请分销商" + } + }, { + "path": "pages/distribution/income", + "style": { + "navigationBarTitleText": "我的收入", + "enablePullDownRefresh": true + } + }, { + "path": "pages/distribution/record", + "style": { + "navigationBarTitleText": "提现记录", + "enablePullDownRefresh": true + } + }, { + "path": "pages/distribution/team", + "style": { + "navigationBarTitleText": "我的邀请", + "enablePullDownRefresh": true + } + }, { + "path": "pages/distribution/poster", + "style": { + "navigationBarTitleText": "推广海报" + } + }, + { + "path": "pages/distribution/bind-technician", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/distribution/share-set", + "style": { + "navigationBarTitleText": "分享设置" + } + }, + { + "path": "pages/distribution/agent", + "style": { + "navigationBarTitleText": "选择代理商" + } + }, { + "path": "pages/cash-out", + "style": { + "navigationBarTitleText": "提现" + } + }, + //#ifndef MP-WEIXIN + { + "path": "pages/alipay-account", + "style": { + "navigationBarTitleText": "绑定支付宝账号" + } + }, + //#endif + { + "path": "pages/alipay-result", + "style": { + "navigationBarTitleText": "支付宝支付", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/apply-result", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/app-download", + "style": { + "navigationBarTitleText": "APP下载", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/phone-code", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/phone", + "style": { + "navigationBarTitleText": "绑定手机号" + } + }, + { + "path": "pages/setting", + "style": { + "navigationBarTitleText": "设置" + } + }, + { + "path": "pages/shield", + "style": { + "navigationBarTitleText": "屏蔽列表", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/logout", + "style": { + "navigationBarTitleText": "注销账户" + } + }, + { + "path": "pages/feedback/box", + "style": { + "navigationBarTitleText": "问题反馈" + } + }, + { + "path": "pages/feedback/list", + "style": { + "navigationBarTitleText": "反馈记录", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/feedback/detail", + "style": { + "navigationBarTitleText": "反馈详情" + } + }, + { + "path": "pages/feedback/success", + "style": { + "navigationBarTitleText": "提交结果" + } + }, + { + "path": "pages/bell/list", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/bell/order", + "style": { + "navigationBarTitleText": "下单" + } + }, + { + "path": "pages/gzh", + "style": { + "navigationBarTitleText": "关注公众号" + } + } + ] + }, + // 代理端 + { + "root": "agent/", + "pages": [{ + "path": "pages/index", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/account", + "style": { + "navigationBarTitleText": "账号设置" + } + }, { + "path": "pages/apply", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/income/commission", + "style": { + "navigationBarTitleText": "分佣明细", + "enablePullDownRefresh": true + } + }, { + "path": "pages/order/list", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/order/change", + "style": { + "navigationBarTitleText": "拒单管理", + "enablePullDownRefresh": true + } + }, { + "path": "pages/order/detail", + "style": { + "navigationBarTitleText": "订单详情" + } + }, { + "path": "pages/refund/list", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/refund/detail", + "style": { + "navigationBarTitleText": "退款详情" + } + }, { + "path": "pages/technician/list", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician/user", + "style": { + "navigationBarTitleText": "选择用户", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician/apply", + "style": { + "navigationBarTitleText": "" + } + }, { + "path": "pages/poster/channel", + "style": { + "navigationBarTitleText": "邀请渠道商" + } + }, { + "path": "pages/poster/salesman", + "style": { + "navigationBarTitleText": "邀请业务员" + } + }] + }, + // 技-师 + { + "root": "technician/", + "pages": [{ + "path": "pages/apply", + "style": { + "navigationBarTitleText": "" + } + }, + { + "path": "pages/order/recorder", + "style": { + "navigationBarTitleText": "测试录音" + } + }, + { + "path": "pages/edit", + "style": { + "navigationBarTitleText": "编辑信息" + } + }, + { + "path": "pages/time-manage", + "style": { + "navigationBarTitleText": "时间管理" + } + }, + { + "path": "pages/time-set", + "style": { + "navigationBarTitleText": "出行设置" + } + }, + { + "path": "pages/income/index", + "style": { + "navigationBarTitleText": "服务费提现", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/income/cash-integral", + "style": { + "navigationBarTitleText": "储值返佣明细", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/income/commission-list", + "style": { + "navigationBarTitleText": "分成明细", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/income/commission-detail", + "style": { + "navigationBarTitleText": "收益详情" + } + }, + { + "path": "pages/order/label", + "style": { + "navigationBarTitleText": "评价客户" + } + }, + { + "path": "pages/order/list", + "style": { + "navigationBarTitleText": "订单管理", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/order/detail", + "style": { + "navigationBarTitleText": "订单详情" + } + }, + { + "path": "pages/car-fare", + "style": { + "navigationBarTitleText": "车费明细" + } + }, + { + "path": "pages/shop/detail", + "style": { + "navigationBarTitleText": "", + "navigationStyle": "custom", + "enablePullDownRefresh": true + } + }, + { + "path": "pages/shop/list", + "style": { + "navigationBarTitleText": "物料商城", + "enablePullDownRefresh": true + } + }, { + "path": "pages/bad-comments/box", + "style": { + "navigationBarTitleText": "差评申诉" + } + }, { + "path": "pages/bad-comments/list", + "style": { + "navigationBarTitleText": "申诉记录", + "enablePullDownRefresh": true + } + }, { + "path": "pages/bad-comments/choice", + "style": { + "navigationBarTitleText": "选择订单", + "enablePullDownRefresh": true + } + }, { + "path": "pages/bad-comments/success", + "style": { + "navigationBarTitleText": "提交结果" + } + }, { + "path": "pages/level", + "style": { + "navigationBarTitleText": "等级管理" + } + }, { + "path": "pages/shield", + "style": { + "navigationBarTitleText": "拉黑用户", + "enablePullDownRefresh": true + } + } + ] + }, + // 门店 + { + "root": "shopstore/", + "pages": [{ + "path": "pages/store-info", + "style": { + "navigationBarTitleText": "" + } + }, { + "path": "pages/detail", + "style": { + "navigationBarTitleText": "商家详情", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician", + "style": { + "navigationBarTitleText": "", + "enablePullDownRefresh": true + } + }, { + "path": "pages/service", + "style": { + "navigationBarTitleText": "推荐服务", + "enablePullDownRefresh": true + } + }] + }, + // 动态 + { + "root": "dynamic/", + "pages": [{ + "path": "pages/technician/edit", + "style": { + "navigationBarTitleText": "发布动态" + } + }, { + "path": "pages/technician/comment", + "style": { + "navigationBarTitleText": "收获的评论", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician/detail", + "style": { + "navigationBarTitleText": "动态详情", + "navigationStyle": "custom", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician/follow", + "style": { + "navigationBarTitleText": "新增关注", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician/list", + "style": { + "navigationBarTitleText": "动态发布", + "enablePullDownRefresh": true + } + }, { + "path": "pages/technician/thumbs", + "style": { + "navigationBarTitleText": "收获的赞", + "enablePullDownRefresh": true + } + }, { + "path": "pages/detail", + "style": { + "navigationBarTitleText": "动态详情", + "navigationStyle": "custom", + "enablePullDownRefresh": true + } + }, { + "path": "pages/follow", + "style": { + "navigationBarTitleText": "我的关注", + "enablePullDownRefresh": true + } + }] + } + ], + "globalStyle": { + "navigationBarTextStyle": "white", + "navigationBarTitleText": "", + "navigationBarBackgroundColor": "#F4F6F8", + "backgroundColor": "#F8F8F8", + "onReachBottomDistance": 140 + }, + "condition": { //模式配置,仅开发期间生效 + "current": 0, //当前激活的模式(list 的索引项) + "list": [{ + "name": "", //模式名称 + "path": "", //启动页面,必选 + "query": "" //启动参数,在页面的onLoad函数里面得到 + }] + }, + "requiredPrivateInfos": [ + "getLocation", + "chooseLocation" + ] +} \ No newline at end of file diff --git a/pages/dynamic.vue b/pages/dynamic.vue new file mode 100644 index 0000000..b6b208f --- /dev/null +++ b/pages/dynamic.vue @@ -0,0 +1,396 @@ + + + + + + + + + + \ No newline at end of file diff --git a/pages/login.vue b/pages/login.vue new file mode 100644 index 0000000..a7bb915 --- /dev/null +++ b/pages/login.vue @@ -0,0 +1,326 @@ + ++ ++ + ++ ++ ++ + ++ ++ + 发动态 + ++ ++ ++ + + + ++ + + + + + ++ + + + + + + + + + + ++ +发布图片 + +发布视频 + +取消 ++ + + + + + + \ No newline at end of file diff --git a/pages/map.vue b/pages/map.vue new file mode 100644 index 0000000..b5d6ef3 --- /dev/null +++ b/pages/map.vue @@ -0,0 +1,866 @@ + ++ + + + ++ + + ++ ++ + + Hi欢迎来到{{configInfo.app_text}} +微信登录(注册) + + +Sign in with Apple + + ++ + ++ +温馨提示 ++ 登录即表示您已详细阅读并同意 + 《隐私政策》 + 与 + 《服务协议》 + + ++ +取消 +确定 + ++ + + + + + + + \ No newline at end of file diff --git a/pages/mine.vue b/pages/mine.vue new file mode 100644 index 0000000..b5b7fc3 --- /dev/null +++ b/pages/mine.vue @@ -0,0 +1,1530 @@ + ++ ++ ++ ++ + ++ + ++ {{location&&location.address ?location.address : isLoad ? '定位失败' : '定位中...'}} + + ++ ++ ++ + + 地图 ++ ++ + + 列表 ++ ++ ++ ++ ++ + + + ++ + ++ ++ + ++ ++ ++ + + + ++ + + + ++ + + + ++ + + ++ +{{$t('action.attendantName')}}性别 + ++ +{{item.title}} + +从业年份 + ++ +{{item.title}} + +上门时间 + ++ {{check.service_time || '选择期望上门时间'}} + + +个性筛选 + + ++ + +重置 +确定 ++ + + ++ ++ + ++ +{{detail.coach_name || '-'}} ++ + +{{detail.distance}} ++ ++ {{textType[detail.text_type]}} + ++ +最早可约 ++ ++ {{detail.near_time}} + + + {{detail.store_name}} + ++ ++ + +{{detail.star || 0}} ++ 已服务{{detail.order_num||0}}单 ++ 从业{{detail.work_time}}年 ++ ++ +{{detail.text}} ++ + + ++ + + + + + + + + + + + + \ No newline at end of file diff --git a/pages/order.vue b/pages/order.vue new file mode 100644 index 0000000..ab2271e --- /dev/null +++ b/pages/order.vue @@ -0,0 +1,417 @@ + ++ ++ + + + + + + + ++ + + ++ ++ ++ ++ ++ 代理商 + ++ ++ 立即登录 + ++ ++ ++ ++ ++ {{ userInfo.nickName || '默认用户' }} + ++ + ++ ++ + {{ mineInfo.coach_status === 2 ? mineInfo.coach_level && mineInfo.coach_level.length > 0 && mineInfo.coach_level.title ? mineInfo.coach_level.title : $t('action.attendantName') : '普通用户' }} + ++ + + + ++ ++ + ++ 尊享VIP会员 ++ ++ +账户余额 +¥{{ mineInfo.balance || '0.00' }} ++ +立即充值 ++ + + + + ++ ++ ++ ++ ++ +我的收藏 +{{ mineInfo.collect_count || 0 }} + 人 + ++ ++ ++ ++ ++ +我的优惠劵 +{{ mineInfo.coupon_count || 0 }} + 张 + ++ ++ +常用工具 ++ ++ + + ++ + + ++ ++ ++ +{{ item.text }} ++ + ++ {{ item.text }} ++ ++ 切换管理员 ++ + ++ ++ 切换{{$t('action.attendantName')}}端 ++ + ++ + ++ + +位置更新 ++ + +时间管理 ++ + +一键报警 ++ + ++ + ++ + + ++ ++ + + ++ +{{coachInfo.coach_name}} +个人信息 + ++ ++ 已认证 ++ {{coachInfo.is_work ? textType[coachInfo.text_type] : '请假中'}} + ++ {{coachInfo.coach_level.title}} + ++ ++ {{coachInfo.auth_status==0?'补充剩余资料才可以上线接单哟':coachInfo.auth_status==1?'认证审核中':'认证已驳回'}} + ++ ++ 去认证 ++ ++ ++ ++ + + 当前 + ++ {{coachInfo.address}} + ++ +实时定位 + ++ + ++ + +取消授权 ++ +¥ ++ {{coachInfo.service_price || 0}} + ++ +服务收入 +去提现 + ++ +¥ ++ {{coachInfo.car_price || 0}} + ++ +车费 ++ 去提现 ++ + ++ +我的订单 ++ ++ ++ ++ {{item.number < 100 ? item.number : '99+'}} + ++ + {{ item.text }} ++ ++ +其他功能 ++ ++ ++ {{ item.text }} ++ 待签约 ++ + + + + + + + + + + + + + + diff --git a/pages/service.vue b/pages/service.vue new file mode 100644 index 0000000..6b00534 --- /dev/null +++ b/pages/service.vue @@ -0,0 +1,793 @@ + ++ ++ + + + + + + ++ + + + ++ +加钟服务 + ++ + +订单号:{{item.order_code}} + + ++ {{statusType[item.pay_type]}} + ++ + ++ + + ++ ++ + + ++ ++ {{aitem.goods_name}} + +x{{aitem.num}} ++ +服务{{$t('action.attendantName')}} + ++ {{item.coach_info ? item.coach_info.coach_name : '-'}} + +已退x{{aitem.refund_num}} + +预约时间 +{{item.start_time}} + +总计: + +¥ + +{{item.pay_price}} ++ ++ + + ++ + + + ++ + + + + + ++ + + + ++ + + ++ ++ + + + ++ + + + + + + + + + + + diff --git a/pages/shopstore.vue b/pages/shopstore.vue new file mode 100644 index 0000000..34921ea --- /dev/null +++ b/pages/shopstore.vue @@ -0,0 +1,382 @@ + ++ ++ + + + + + + ++ ++ ++ ++ ++ + {{ item.text }} + ++ + + ++ ++ ++ + {{`推荐${$t('action.attendantName')}`}} ++ 查看更多 ++ ++ ++ + ++ + + ++ ++ + + +{{item.coach_name}} ++ +新人 + +30天接单{{item.order_count||0}} + ++ ++ + ++ + + ++ ++ + + +{{item.coach_name}} ++ + +{{item.star}} ++ +新人 + +30天接单{{item.order_count||0}} + ++ ++ ++ ++ + 推荐项目 ++ + + ++ + ++ + + + + ++ + ++ + + ++ + + + + + ++ ++ 成功领取 + ++ 卡券将放入“我的-我的卡券” + ++ ++ ++ ++ ++ ++ ++ {{item.discount}} + ++ {{item.full*1>0?`满${item.full}可用`:`立减`}} + ++ ++ {{item.title}} + ++ ++ 领取到卡包 + ++ + + + + + + + + + + + + \ No newline at end of file diff --git a/pages/technician.vue b/pages/technician.vue new file mode 100644 index 0000000..12ea15f --- /dev/null +++ b/pages/technician.vue @@ -0,0 +1,587 @@ + ++ + ++ + ++ ++ + + + + ++ + + ++ ++ + ++ ++ +{{item.title}} ++ {{item.work_status==1?'营业中':'休息中'}} + ++ ++ ++ +{{item.star}} +{{item.start_time && item.end_time?`${item.start_time} - ${item.end_time}`:'暂未设置'}} + +{{item.total_num}}+次服务 ++ ++ ++ 好评率 {{item.positive_rate}}%接单率 + {{item.order_rate}}% +{{item.distance}} ++ ++ + + + + + ++ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/pages/test.vue b/pages/test.vue new file mode 100644 index 0000000..10caad8 --- /dev/null +++ b/pages/test.vue @@ -0,0 +1,82 @@ + ++ + ++ ++ ++ + ++ {{location&&location.address ?location.address : isLoad ? '定位失败' : '定位中...'}} + + ++ ++ + ++ ++ ++ ++ ++ + ++ {{cityIndex === -1 ? '未知' : cityList[cityIndex].title.length > 3 ? cityList[cityIndex].title.substring(0,3) + '...':cityList[cityIndex].title}} + +请选择 ++ ++ ++ ++ + + + ++ ++ ++ ++ + + + ++ + + + + + + + + + + ++ + ++ + 很抱歉,该城市未开通, 点击左上角切换其他城市下单服务 + ++ ++ 知道了 ++ + + + + + + + + + + + + \ No newline at end of file diff --git a/shopstore/pages/detail.vue b/shopstore/pages/detail.vue new file mode 100644 index 0000000..82ebcab --- /dev/null +++ b/shopstore/pages/detail.vue @@ -0,0 +1,409 @@ + ++ + + + + + + \ No newline at end of file diff --git a/shopstore/pages/service.vue b/shopstore/pages/service.vue new file mode 100644 index 0000000..f188dd7 --- /dev/null +++ b/shopstore/pages/service.vue @@ -0,0 +1,107 @@ + ++ ++ + +{{detail.info.title || '-'}} ++ ++ + 营业执照: + +{{detail.info.attestation}} ++ ++ + 营业时间: ++ {{detail.info.start_time && detail.info.end_time ?`${detail.info.start_time} - ${detail.info.end_time}`:'暂未设置'}} + ++ ++ + ++ {{detail.info.address || `暂未设置门店地址`}} + + ++ ++ ++ + + ++ + + + ++ + + +推荐项目 +查看更多 ++ + ++ + + ++ +{{$t('action.attendantName')}}展示 +查看更多 ++ ++ + ++ + + ++ ++ + + +{{item.coach_name}} ++ + ++ ++ + ++ ++ +{{item.nickName}} ++ + +{{item.create_time}} ++ +{{item}} ++ +{{item.text}} ++ ++ + + + + + +分享 ++ + + + + + \ No newline at end of file diff --git a/shopstore/pages/store-info.vue b/shopstore/pages/store-info.vue new file mode 100644 index 0000000..3587e43 --- /dev/null +++ b/shopstore/pages/store-info.vue @@ -0,0 +1,130 @@ + ++ ++ + ++ + + + + + + + + diff --git a/shopstore/pages/technician.vue b/shopstore/pages/technician.vue new file mode 100644 index 0000000..7ef0137 --- /dev/null +++ b/shopstore/pages/technician.vue @@ -0,0 +1,303 @@ + ++ + ++ + ++ + +{{detail.attestation}} ++ ++ +{{detail.total_num}}+ +服务次数 ++ +{{detail.order_rate}}% +接单率 ++ +{{detail.positive_rate}}% +好评率 ++ +营业执照 ++ ++ ++ +商家简介 +{{detail.text}} ++ + + + + + + + \ No newline at end of file diff --git a/siteinfo.js b/siteinfo.js new file mode 100644 index 0000000..fbeb92b --- /dev/null +++ b/siteinfo.js @@ -0,0 +1,8 @@ +module.exports = { + // 预约按摩 多城市 + "uniacid": "666", + "multiid": "0", + "version": "3.0", + "gzh_appid": "wx88bf27358c22f867", + "siteroot": "https://tianjin.tianjinhualong.cn/index.php" +} diff --git a/static/coupon/btn.png b/static/coupon/btn.png new file mode 100644 index 0000000..0ee1366 Binary files /dev/null and b/static/coupon/btn.png differ diff --git a/static/coupon/coupon.png b/static/coupon/coupon.png new file mode 100644 index 0000000..7f2f454 Binary files /dev/null and b/static/coupon/coupon.png differ diff --git a/static/coupon/line.png b/static/coupon/line.png new file mode 100644 index 0000000..db7cb69 Binary files /dev/null and b/static/coupon/line.png differ diff --git a/static/coupon/menu.png b/static/coupon/menu.png new file mode 100644 index 0000000..7524602 Binary files /dev/null and b/static/coupon/menu.png differ diff --git a/static/coupon/picture.png b/static/coupon/picture.png new file mode 100644 index 0000000..9ffeda8 Binary files /dev/null and b/static/coupon/picture.png differ diff --git a/static/coupon/wechat-moments.png b/static/coupon/wechat-moments.png new file mode 100644 index 0000000..095e2d8 Binary files /dev/null and b/static/coupon/wechat-moments.png differ diff --git a/static/coupon/wechat.png b/static/coupon/wechat.png new file mode 100644 index 0000000..71c2cca Binary files /dev/null and b/static/coupon/wechat.png differ diff --git a/static/img/axg.png b/static/img/axg.png new file mode 100644 index 0000000..5bcfeb1 Binary files /dev/null and b/static/img/axg.png differ diff --git a/static/img/icon_project.png b/static/img/icon_project.png new file mode 100644 index 0000000..73fa2e6 Binary files /dev/null and b/static/img/icon_project.png differ diff --git a/static/img/icon_technician.png b/static/img/icon_technician.png new file mode 100644 index 0000000..501cfef Binary files /dev/null and b/static/img/icon_technician.png differ diff --git a/static/img/qs_dingdan.png b/static/img/qs_dingdan.png new file mode 100644 index 0000000..60b54f0 Binary files /dev/null and b/static/img/qs_dingdan.png differ diff --git a/static/logo-120.png b/static/logo-120.png new file mode 100644 index 0000000..d7a6f5c Binary files /dev/null and b/static/logo-120.png differ diff --git a/static/logo-180.png b/static/logo-180.png new file mode 100644 index 0000000..3a36a87 Binary files /dev/null and b/static/logo-180.png differ diff --git a/static/logo-40.png b/static/logo-40.png new file mode 100644 index 0000000..d6b66c4 Binary files /dev/null and b/static/logo-40.png differ diff --git a/static/logo-58.png b/static/logo-58.png new file mode 100644 index 0000000..af0a7ba Binary files /dev/null and b/static/logo-58.png differ diff --git a/static/logo-60.png b/static/logo-60.png new file mode 100644 index 0000000..47882fb Binary files /dev/null and b/static/logo-60.png differ diff --git a/static/logo-80.png b/static/logo-80.png new file mode 100644 index 0000000..314a0d8 Binary files /dev/null and b/static/logo-80.png differ diff --git a/static/logo-87.png b/static/logo-87.png new file mode 100644 index 0000000..2a073a1 Binary files /dev/null and b/static/logo-87.png differ diff --git a/static/logo.png b/static/logo.png new file mode 100644 index 0000000..c4d3557 Binary files /dev/null and b/static/logo.png differ diff --git a/static/mine/Add.png b/static/mine/Add.png new file mode 100644 index 0000000..da6f25e Binary files /dev/null and b/static/mine/Add.png differ diff --git a/static/mine/Wallet.png b/static/mine/Wallet.png new file mode 100644 index 0000000..b4a6c2f Binary files /dev/null and b/static/mine/Wallet.png differ diff --git a/static/mine/auth.png b/static/mine/auth.png new file mode 100644 index 0000000..4194edf Binary files /dev/null and b/static/mine/auth.png differ diff --git a/static/mine/balance.png b/static/mine/balance.png new file mode 100644 index 0000000..6c060cc Binary files /dev/null and b/static/mine/balance.png differ diff --git a/static/mine/bg.jpg b/static/mine/bg.jpg new file mode 100644 index 0000000..d6381a2 Binary files /dev/null and b/static/mine/bg.jpg differ diff --git a/static/mine/cfmx.png b/static/mine/cfmx.png new file mode 100644 index 0000000..c9fef6e Binary files /dev/null and b/static/mine/cfmx.png differ diff --git a/static/mine/cftx.png b/static/mine/cftx.png new file mode 100644 index 0000000..2f07744 Binary files /dev/null and b/static/mine/cftx.png differ diff --git a/static/mine/coupon.png b/static/mine/coupon.png new file mode 100644 index 0000000..1cb8b0e Binary files /dev/null and b/static/mine/coupon.png differ diff --git a/static/mine/default_user.png b/static/mine/default_user.png new file mode 100644 index 0000000..0d54c70 Binary files /dev/null and b/static/mine/default_user.png differ diff --git a/static/mine/dengji.png b/static/mine/dengji.png new file mode 100644 index 0000000..c019fb6 Binary files /dev/null and b/static/mine/dengji.png differ diff --git a/static/mine/dizhiguanli.png b/static/mine/dizhiguanli.png new file mode 100644 index 0000000..9a76468 Binary files /dev/null and b/static/mine/dizhiguanli.png differ diff --git a/static/mine/dongtai.png b/static/mine/dongtai.png new file mode 100644 index 0000000..052e99e Binary files /dev/null and b/static/mine/dongtai.png differ diff --git a/static/mine/fencheng.png b/static/mine/fencheng.png new file mode 100644 index 0000000..3167c51 Binary files /dev/null and b/static/mine/fencheng.png differ diff --git a/static/mine/fenxiao.png b/static/mine/fenxiao.png new file mode 100644 index 0000000..ca00da1 Binary files /dev/null and b/static/mine/fenxiao.png differ diff --git a/static/mine/fx.png b/static/mine/fx.png new file mode 100644 index 0000000..dc0c0ac Binary files /dev/null and b/static/mine/fx.png differ diff --git a/static/mine/guanli.png b/static/mine/guanli.png new file mode 100644 index 0000000..49f77e4 Binary files /dev/null and b/static/mine/guanli.png differ diff --git a/static/mine/guanzhu.png b/static/mine/guanzhu.png new file mode 100644 index 0000000..ec48d31 Binary files /dev/null and b/static/mine/guanzhu.png differ diff --git a/static/mine/hetong.png b/static/mine/hetong.png new file mode 100644 index 0000000..28d4f34 Binary files /dev/null and b/static/mine/hetong.png differ diff --git a/static/mine/jishizhaopin.png b/static/mine/jishizhaopin.png new file mode 100644 index 0000000..098cf4c Binary files /dev/null and b/static/mine/jishizhaopin.png differ diff --git a/static/mine/lianxikefu.png b/static/mine/lianxikefu.png new file mode 100644 index 0000000..b5cefaf Binary files /dev/null and b/static/mine/lianxikefu.png differ diff --git a/static/mine/pingbi.png b/static/mine/pingbi.png new file mode 100644 index 0000000..bbd93d1 Binary files /dev/null and b/static/mine/pingbi.png differ diff --git a/static/mine/pingjia.png b/static/mine/pingjia.png new file mode 100644 index 0000000..3fb30c9 Binary files /dev/null and b/static/mine/pingjia.png differ diff --git a/static/mine/qiehuan.png b/static/mine/qiehuan.png new file mode 100644 index 0000000..3b7f02c Binary files /dev/null and b/static/mine/qiehuan.png differ diff --git a/static/mine/qudao.png b/static/mine/qudao.png new file mode 100644 index 0000000..13fc599 Binary files /dev/null and b/static/mine/qudao.png differ diff --git a/static/mine/setTime2.png b/static/mine/setTime2.png new file mode 100644 index 0000000..ce48bd5 Binary files /dev/null and b/static/mine/setTime2.png differ diff --git a/static/mine/shens.png b/static/mine/shens.png new file mode 100644 index 0000000..1268d83 Binary files /dev/null and b/static/mine/shens.png differ diff --git a/static/mine/shop.png b/static/mine/shop.png new file mode 100644 index 0000000..8ebf915 Binary files /dev/null and b/static/mine/shop.png differ diff --git a/static/mine/tel.png b/static/mine/tel.png new file mode 100644 index 0000000..3822fef Binary files /dev/null and b/static/mine/tel.png differ diff --git a/static/mine/tuikuan.png b/static/mine/tuikuan.png new file mode 100644 index 0000000..2c9c5e4 Binary files /dev/null and b/static/mine/tuikuan.png differ diff --git a/static/mine/vip.png b/static/mine/vip.png new file mode 100644 index 0000000..b584d36 Binary files /dev/null and b/static/mine/vip.png differ diff --git a/static/mine/yewu.png b/static/mine/yewu.png new file mode 100644 index 0000000..8f38dc6 Binary files /dev/null and b/static/mine/yewu.png differ diff --git a/static/mine/yijianfank.png b/static/mine/yijianfank.png new file mode 100644 index 0000000..d51c048 Binary files /dev/null and b/static/mine/yijianfank.png differ diff --git a/static/mine/youhui.png b/static/mine/youhui.png new file mode 100644 index 0000000..9658f12 Binary files /dev/null and b/static/mine/youhui.png differ diff --git a/static/tab/dingdan_nor.png b/static/tab/dingdan_nor.png new file mode 100644 index 0000000..6c8bd35 Binary files /dev/null and b/static/tab/dingdan_nor.png differ diff --git a/static/tab/dingdan_sel.png b/static/tab/dingdan_sel.png new file mode 100644 index 0000000..9795c5b Binary files /dev/null and b/static/tab/dingdan_sel.png differ diff --git a/static/tab/find_nor.png b/static/tab/find_nor.png new file mode 100644 index 0000000..238f346 Binary files /dev/null and b/static/tab/find_nor.png differ diff --git a/static/tab/find_sel.png b/static/tab/find_sel.png new file mode 100644 index 0000000..22ef546 Binary files /dev/null and b/static/tab/find_sel.png differ diff --git a/static/tab/jishi_nor.png b/static/tab/jishi_nor.png new file mode 100644 index 0000000..6722394 Binary files /dev/null and b/static/tab/jishi_nor.png differ diff --git a/static/tab/jishi_sel.png b/static/tab/jishi_sel.png new file mode 100644 index 0000000..ca9c592 Binary files /dev/null and b/static/tab/jishi_sel.png differ diff --git a/static/tab/shouye_nor.png b/static/tab/shouye_nor.png new file mode 100644 index 0000000..6726e9b Binary files /dev/null and b/static/tab/shouye_nor.png differ diff --git a/static/tab/shouye_sel.png b/static/tab/shouye_sel.png new file mode 100644 index 0000000..4483309 Binary files /dev/null and b/static/tab/shouye_sel.png differ diff --git a/static/tab/store_nor.png b/static/tab/store_nor.png new file mode 100644 index 0000000..0ed1e3b Binary files /dev/null and b/static/tab/store_nor.png differ diff --git a/static/tab/store_sel.png b/static/tab/store_sel.png new file mode 100644 index 0000000..86b8e83 Binary files /dev/null and b/static/tab/store_sel.png differ diff --git a/static/tab/wode_nor.png b/static/tab/wode_nor.png new file mode 100644 index 0000000..ea30390 Binary files /dev/null and b/static/tab/wode_nor.png differ diff --git a/static/tab/wode_sel.png b/static/tab/wode_sel.png new file mode 100644 index 0000000..767f860 Binary files /dev/null and b/static/tab/wode_sel.png differ diff --git a/store/index.js b/store/index.js new file mode 100644 index 0000000..c5590ad --- /dev/null +++ b/store/index.js @@ -0,0 +1,10 @@ +import Vue from "vue" +import Vuex from "vuex" +Vue.use(Vuex) +const files = require.context('./modules', false, /\.js$/) +const modules = {} +files.keys().forEach(key => { + modules[key.replace(/(\.\/|\.js)/g, '')] = files(key).default +}) + +export default new Vuex.Store({modules}) \ No newline at end of file diff --git a/store/modules/config.js b/store/modules/config.js new file mode 100644 index 0000000..e633b9a --- /dev/null +++ b/store/modules/config.js @@ -0,0 +1,235 @@ +import $util from "@/utils/index.js" +import $api from "@/api/index.js" +export default { + state: { + merchantAuth: 0, // 技-师列表是否显示商家 + old_attendant_name: '技师', + configInfo: { + id: 0, + isIos: uni.getSystemInfoSync().system.includes('iOS'), + navBarHeight: uni.getSystemInfoSync().statusBarHeight * 1 + 44, + curSysHeight: '', + tabbarHeight: '', + methodObj: { + 1: 'call', + 2: 'miniProgram', + 3: 'web', + 4: 'navigateTo' + }, + tabBar: [], + }, + play_method: [{ + method: 'onPlay', + msg: '开始播放', + status: true, + }, { + method: 'onStop', + msg: '结束播放', + status: false, + }, { + method: 'onError', + msg: '报错Error', + status: false, + }, { + method: 'onEnded', + msg: '自然结束播放', + status: false, + }], + audioBg: {}, + audioType: 'countdown_voice', + playBg: false, + isHaveAudio: false + }, + mutations: { + //修改信息 + updateConfigItem(state, item) { + let { + key, + val + } = item + state[key] = val + if (key !== 'configInfo') return + uni.setStorageSync('configInfo', val) + let src = val[state.audioType] + if (state.isHaveAudio) { + state.audioBg.src = src || '' + return + } + if (!val.countdown_voice && !val.service_start_recording && !val.service_end_recording) return + state.audioBg = uni.createInnerAudioContext(); + state.isHaveAudio = true + state.audioBg.src = src + // #ifndef APP-PLUS + state.audioBg.obeyMuteSwitch = false + // #endif + state.play_method.map(item => { + state.audioBg[item.method](() => { + console.log('bg=>', item.msg) + state.playBg = item.status; + }) + }) + } + }, + actions: { + // 获取基本配置 + async getConfigInfo({ + commit, + state + }, param) { + let config = await $api.base.configInfo() + if (!config.primaryColor) { + config.primaryColor = '#A40035' + } + if (!config.subColor) { + config.subColor = '#F1C06B' + } + if (!config.user_image) { + config.user_image = 'https://lbqny.migugu.com/admin/anmo/mine/bg.png' + } + if (!config.coach_image) { + config.coach_image = 'https://lbqny.migugu.com/admin/anmo/mine/bg.png' + } + if (!config.service_btn_color) { + config.service_btn_color = '#282B34' + } + if (!config.service_font_color) { + config.service_font_color = '#EBDDB1' + } + if (!config.user_font_color) { + config.user_font_color = '#ffffff' + } + if (!config.coach_font_color) { + config.coach_font_color = '#ffffff' + } + + let base_config = $util.pick(state.configInfo, ['isIos', 'navBarHeight', 'curSysHeight', + 'tabbarHeight', 'methodObj', 'tabBar' + ]) + + let tabBar = [{ + id: 1, + name: '首页', + default_img: '../static/tab/shouye_nor.png', + selected_img: '../static/tab/shouye_sel.png' + }, { + id: 2, + name: '技师', + default_img: '../static/tab/jishi_nor.png', + selected_img: '../static/tab/jishi_sel.png' + }, { + id: 4, + name: '订单', + default_img: '../static/tab/dingdan_nor.png', + selected_img: '../static/tab/dingdan_sel.png' + }, { + id: 5, + name: '我的', + default_img: '../static/tab/wode_nor.png', + selected_img: '../static/tab/wode_sel.png' + }] + + + let tInd = tabBar.findIndex(item => { + return item.id == 2 + }) + tabBar[tInd].name = config.attendant_name + + // let authArr = ['map', 'dynamic', 'store'] + // let authArr = ['dynamic', 'store'] + let authArr = [] // tabbar 权限 + let authObj = { + dynamic: { + id: 3, + name: '动态', + default_img: '../static/tab/find_nor.png', + selected_img: '../static/tab/find_sel.png', + ind: config.attendant_name + }, + store: { + id: 6, + name: '门店', + default_img: '../static/tab/store_nor.png', + selected_img: '../static/tab/store_sel.png', + ind: '首页' + }, + map: { + id: 7, + name: '地图找人', + default_img: '../static/tab/jishi_nor.png', + selected_img: '../static/tab/jishi_sel.png', + ind: config.attendant_name + } + } + + let plugNum = 0 + let { + plugAuth + } = config + for (let i in plugAuth) { + plugAuth[i] = plugAuth[i] == 1 || plugAuth[i] ? false : true + if (authArr.includes(i)) { + if (plugAuth[i]) { + plugNum++ + } + let addInd = tabBar.findIndex(item => { + return item.name == authObj[i].name + }) + let spliceInd = tabBar.findIndex(item => { + return item.name == authObj[i].ind + }) + if (plugAuth[i] && addInd == -1) { + tabBar.splice(spliceInd + 1, 0, authObj[i]) + } + if (!plugAuth[i] && addInd !== -1) { + tabBar.splice(addInd, 1) + } + } + } + config.plugAuth = plugAuth + + + //if (plugNum > 1) { + //tabBar.splice(tabBar.findIndex(item => { + //return item.name == '订单' + //}), 1) + //} + + base_config.tabBar = tabBar + let data = Object.assign({}, config, base_config) + commit('updateConfigItem', { + key: 'configInfo', + val: data + }) + + }, + toPlayAudio({ + commit, + state + }, param) { + state.audioType = param.key + let src = state.configInfo[param.key] + if (!src) return + if (state.isHaveAudio) { + state.audioBg.src = src + } else { + state.audioBg = uni.createInnerAudioContext(); + state.isHaveAudio = true + state.audioBg.src = src + // #ifndef APP-PLUS + state.audioBg.obeyMuteSwitch = false + // #endif + state.play_method.map(item => { + state.audioBg[item.method](() => { + console.log('bg=>', item.msg) + state.playBg = item.status; + }) + }) + } + + if (state.playBg) { + state.audioBg.stop() + } + state.audioBg.play() + } + } +} \ No newline at end of file diff --git a/store/modules/dynamic.js b/store/modules/dynamic.js new file mode 100644 index 0000000..9bda587 --- /dev/null +++ b/store/modules/dynamic.js @@ -0,0 +1,83 @@ +import $util from "@/utils/index.js" +import $api from "@/api/index.js" +export default { + state: { + pageActive: false, + activeIndex: 0, + haveOperItem: false, + tabList: [{ + title: '推荐', + id: 0, + }, { + title: '关注', + id: 1, + number: 0 + }], + param: { + page: 1, + coach_name: '' + }, + list: { + data: [], + last_page: 1, + current_page: 1 + }, + follow_dynamic_num: 0, + coach_status: -1 + }, + mutations: { + async updateDynamicItem(state, item) { + let { + key, + val + } = item + state[key] = val + } + }, + actions: { + async getDynamicIndex({ + commit, + state + }, param) { + let d = await $api.dynamic.getFollowData(param) + commit('updateDynamicItem', { + key: 'follow_dynamic_num', + val: d.num + }) + commit('updateDynamicItem', { + key: 'coach_status', + val: d.coach_status + }) + let tabList = $util.deepCopy(state.tabList) + tabList[1].number = d.num + commit('updateDynamicItem', { + key: 'tabList', + val: tabList + }) + }, + async getDynamicList({ + commit, + state + }, param) { + let methodModel = state.activeIndex == 0 ? 'dynamicList' : 'followDynamicList' + let d = await $api.dynamic[methodModel](param) + let oldList = state.list; + let newList = d; + let list = {} + if (param.page == 1) { + list = newList; + } else { + newList.data = oldList.data.concat(newList.data) + list = newList; + } + commit('updateDynamicItem', { + key: 'param', + val: param + }) + commit('updateDynamicItem', { + key: 'list', + val: list + }) + } + }, +} diff --git a/store/modules/map.js b/store/modules/map.js new file mode 100644 index 0000000..cf2708a --- /dev/null +++ b/store/modules/map.js @@ -0,0 +1,153 @@ +import $api from "@/api/index.js" +import $store from "@/store/index.js" +export default { + state: { + pageActive: false, + sexList: [{ + id: -1, + title: '全部' + }, { + id: 0, + title: '男' + }, { + id: 1, + title: '女' + }], + yearList: [{ + id: 1, + title: '1-3年', + year: [1, 3] + }, { + id: 2, + title: '3-5年', + year: [3, 5] + }, { + id: 3, + title: '5-10年', + year: [5, 10] + }, { + id: 4, + title: '10年以上', + year: [10, 200] + }], + map: { + latitude: 0, + longitude: 0, + scale: 16, + controls: [] + }, + covers: [], + service_cate: [], + param: { + page: 1, + sex: -1, + year: 1, + cate_id: 0, + activeIndex: 0, + coach_name: '', + service_time: '' + }, + check: { + sex: -1, + year: 1, + coach_name: '', + service_time: '' + }, + mapList: [], + list: { + data: [], + last_page: 1, + current_page: 1 + }, + mapType: 'map' + }, + mutations: { + async updateMapItem(state, item) { + let { + key, + val + } = item + state[key] = val + } + }, + actions: { + async getMapIndex({ + commit, + state + }, param) { + let d = await $api.service.serviceCateList(param) + d.unshift({ + id: 0, + title: '全部' + }) + commit('updateMapItem', { + key: 'service_cate', + val: d + }) + }, + async getMapList({ + commit, + state + }, param) { + let d = await $api.service.mapCoachList(param) + let map = Object.assign({}, state.map, { + latitude: param.lat, + longitude: param.lng, + }) + let arr = [] + d.map((item, index) => { + arr.push({ + id: index, + latitude: item.lat, + longitude: item.lng, + iconPath: item.work_img, + width: 30, + height: 30 + }) + }) + arr.unshift({ + id: '-1', + latitude: param.lat, + longitude: param.lng, + iconPath: 'https://mapapi.qq.com/web/lbs/visualizationApi/demo/img/big.png', + width: 20, + height: 25, + }) + commit('updateMapItem', { + key: 'map', + val: map + }) + commit('updateMapItem', { + key: 'covers', + val: arr + }) + commit('updateMapItem', { + key: 'mapList', + val: d + }) + }, + async getMapCoachList({ + commit, + state + }, param) { + let { + coach_format = 1 + } = $store.state.config.configInfo + let methodModel = coach_format == 1 ? 'serviceCoachList' : 'typeServiceCoachList' + let d = await $api.service[methodModel](param) + let oldList = state.list; + let newList = d; + let list = {} + if (param.page == 1) { + list = newList; + } else { + newList.data = oldList.data.concat(newList.data) + list = newList; + } + commit('updateMapItem', { + key: 'list', + val: list + }) + } + }, +} \ No newline at end of file diff --git a/store/modules/order.js b/store/modules/order.js new file mode 100644 index 0000000..27b52b5 --- /dev/null +++ b/store/modules/order.js @@ -0,0 +1,99 @@ +import $util from "@/utils/index.js" +import $api from "@/api/index.js" +import { + req +} from '@/utils/req.js'; +export default { + state: { + pageActive: false, + // pay_type 1待支付,2待服务,3技-师接单,4技-师出发,5技-师到达,6服务中,7服务完成 + activeIndex: 0, + tabList: [{ + title: '全部', + id: 0 + }, { + title: '待支付', + id: 1, + // number: 10 + }, { + title: '待服务', + id: 5 + }, { + title: '服务中', + id: 6 + }, { + title: '已完成', + id: 7 + }], + param: { + page: 1, + pay_type: 0, + }, + list: { + data: [], + last_page: 1, + current_page: 1 + }, + carList: {}, + haveOperItem: false, + bellOrderParams: {}, + alipayOrderParams: {}, + recorder: null, + recorder_status: false, + recorder_order_id: 0 + }, + mutations: { + updateOrderItem(state, item) { + let { + key, + val + } = item + state[key] = val + } + }, + actions: { + async getOrderList({ + commit, + state + }, param) { + let d = await $api.order.orderList(param) + let oldList = state.list; + let newList = d; + let list = {} + if (param.page == 1) { + let { + current_page = 0 + } = newList + if (!current_page) { + newList = { + data: [], + last_page: 1, + current_page: 1 + } + } + list = newList; + } else { + newList.data = oldList.data.concat(newList.data) + list = newList; + } + commit('updateOrderItem', { + key: 'list', + val: list + }) + }, + // 获取购物车数据 + async getCarList({ + commit, + state + }, param) { + let carList = await $api.order.carInfo(param) + carList.list.map(item => { + item.checked = false + }) + commit('updateOrderItem', { + key: 'carList', + val: carList + }) + }, + } +} \ No newline at end of file diff --git a/store/modules/service.js b/store/modules/service.js new file mode 100644 index 0000000..692e641 --- /dev/null +++ b/store/modules/service.js @@ -0,0 +1,128 @@ +import $api from "@/api/index.js" +import $util from "@/utils/index.js" +import $store from "@/store/index.js" +export default { + state: { + pageActive: false, + activeIndex: 0, + tabList: [{ + title: '全部', + sort: 'top desc', + }, { + title: '价格', + sort: 'price', + sign: 0, + is_sign: 1, + }, { + title: '销量', + sort: 'total_sale', + sign: 0, + is_sign: 1, + }, { + title: '好评度', + sort: 'star', + sign: 0, + is_sign: 1, + }], + param: { + page: 1, + sort: '' + }, + list: { + data: [], + last_page: 1, + current_page: 1 + }, + banner: [], + service_cate: [], + service_all_cate: [], + recommend_list: [], + recommend_style: 1 + }, + mutations: { + async updateServiceItem(state, item) { + let { + key, + val + } = item + state[key] = val + } + }, + actions: { + async getServiceIndex({ + commit, + state + }, param) { + let d = await $api.service.index(param); + let { + banner = [], + service_cate = [], + recommend_list = [], + recommend_style = 1, + coach_apply_show = 0 + } = d + let all_cate = $util.deepCopy(service_cate) + commit('updateServiceItem', { + key: 'service_all_cate', + val: all_cate + }) + let cateLen = all_cate.length + if (coach_apply_show) { + service_cate.splice(cateLen > 4 ? 4 : cateLen - 1, 0, { + id: 0, + title: $store.state.config.configInfo.attendant_name + '入驻', + cover: 'https://lbqny.migugu.com/admin/anmo/technician/default_technician.png', + url: '/technician/pages/apply' + }) + } + let num = ((coach_apply_show && cateLen > 28) || (!coach_apply_show && cateLen > 29)) ? 29 : + coach_apply_show ? cateLen + 1 : cateLen + console.log(coach_apply_show, num, "======num") + service_cate = service_cate.slice(0, num) + if ((cateLen > (coach_apply_show ? 28 : 29))) { + service_cate.push({ + id: 0, + title: '全部分类', + cover: '', + icon: 'iconfenleiyingyongtongzhi2', + url: '/user/pages/service/cate' + }) + } + commit('updateServiceItem', { + key: 'banner', + val: banner + }) + commit('updateServiceItem', { + key: 'service_cate', + val: service_cate + }) + commit('updateServiceItem', { + key: 'recommend_list', + val: recommend_list + }) + commit('updateServiceItem', { + key: 'recommend_style', + val: recommend_style + }) + }, + async getServiceList({ + commit, + state + }, param) { + let d = await $api.service.serviceList(param) + let oldList = state.list; + let newList = d; + let list = {} + if (param.page == 1) { + list = newList; + } else { + newList.data = oldList.data.concat(newList.data) + list = newList; + } + commit('updateServiceItem', { + key: 'list', + val: list + }) + } + }, +} \ No newline at end of file diff --git a/store/modules/shopstore.js b/store/modules/shopstore.js new file mode 100644 index 0000000..2f2c6e7 --- /dev/null +++ b/store/modules/shopstore.js @@ -0,0 +1,51 @@ +import $util from "@/utils/index.js" +import $api from "@/api/index.js" +export default { + state: { + pageActive: false, + haveOperItem: false, + param: { + page: 1, + coach_name: '' + }, + list: { + data: [], + last_page: 1, + current_page: 1 + } + }, + mutations: { + async updateShopstoreItem(state, item) { + let { + key, + val + } = item + state[key] = val + } + }, + actions: { + async getShopstoreList({ + commit, + state + }, param) { + let d = await $api.shopstore.storeList(param) + let oldList = state.list; + let newList = d; + let list = {} + if (param.page == 1) { + list = newList; + } else { + newList.data = oldList.data.concat(newList.data) + list = newList; + } + commit('updateShopstoreItem', { + key: 'param', + val: param + }) + commit('updateShopstoreItem', { + key: 'list', + val: list + }) + } + }, +} diff --git a/store/modules/technician.js b/store/modules/technician.js new file mode 100644 index 0000000..9ce78f2 --- /dev/null +++ b/store/modules/technician.js @@ -0,0 +1,100 @@ +import $api from "@/api/index.js" +import $store from "@/store/index.js" +export default { + state: { + pageActive: false, + activeIndex: 0, + haveOperItem: false, + tabList: [{ + title: '全部', + id: 0, + }, { + title: '可服务', + id: 1, + }, { + title: '服务中', + id: 2 + }, { + title: '可预约', + id: 3 + }], + cityId: 0, + cityIndex: -1, + cityList: [], + param: { + page: 1, + ser_id: 0, + coach_name: '' + }, + list: { + data: [], + last_page: 1, + current_page: 1 + } + }, + mutations: { + async updateTechnicianItem(state, item) { + let { + key, + val + } = item + state[key] = val + } + }, + actions: { + async getCityList({ + commit, + state + }, param) { + let { + change = 0 + } = param + let params = JSON.parse(JSON.stringify(param)) + delete params.change + let d = await $api.base.getCity(params); + let { + cityId = 0 + } = state + let ind = d.findIndex(v => { + return change || !cityId ? v.is_select : v.id == cityId + }) + commit('updateTechnicianItem', { + key: 'cityList', + val: d + }) + let cityIndex = ind + // let cityIndex = ind === -1 ? 0 : ind + commit('updateTechnicianItem', { + key: 'cityIndex', + val: cityIndex + }) + commit('updateTechnicianItem', { + key: 'cityId', + val: d && d.length > 0 && cityIndex !== -1 ? d[cityIndex].id : 0 + }) + }, + async getServiceCoachList({ + commit, + state + }, param) { + let { + coach_format = 1 + } = $store.state.config.configInfo + let methodModel = coach_format == 1 ? 'serviceCoachList' : 'typeServiceCoachList' + let d = await $api.service[methodModel](param) + let oldList = state.list; + let newList = d; + let list = {} + if (param.page == 1) { + list = newList; + } else { + newList.data = oldList.data.concat(newList.data) + list = newList; + } + commit('updateTechnicianItem', { + key: 'list', + val: list + }) + } + }, +} diff --git a/store/modules/user.js b/store/modules/user.js new file mode 100644 index 0000000..5be052e --- /dev/null +++ b/store/modules/user.js @@ -0,0 +1,208 @@ +import $util from "@/utils/index.js" +import $api from "@/api/index.js" +import $store from "@/store/index.js" +import { + req +} from '@/utils/req.js'; +export default { + state: { + autograph: '', + userInfo: {}, + appLogin: '', + loginType: '', + loginPage: '', + isGzhLogin: false, + locationChange: false, + locationChangeUnix: 0, + commonOptions: { + id: 0, + pid: 0, + coupon_atv_id: 0, + admin_id: 0, + coach_id: 0, + channel_id: 0, + }, + location: {}, + isShowAuth: true, + mineInfo: {}, // 用户个人中心 + userPageType: 1, // 1用户,2技-师 + coachInfo: {}, + haveShieldOper: 0, + personVerifyUrl: '', + fddExtsign: '', + }, + mutations: { + //更新内容 + async updateUserItem(state, item) { + let { + key, + val + } = item + if (key == 'userInfo' && val.id) { + let { + phone = '', + create_time, + alipay_number = '' + } = val + if (phone) { + val.split_phone = phone.substring(0, 3) + '****' + phone.substring(7, 11) + } + val.create_date = $util.formatTime(create_time * 1000, 'YY-M-D') + if (alipay_number) { + let len = alipay_number.length + val.split_alipay_number = alipay_number.substring(0, len > 3 ? 3 : 1) + '***' + if (len > 6) { + val.split_alipay_number += alipay_number.substring(len == 6 ? len - 2 : + len - 3, len) + } + } + } + + if (key == 'mineInfo') { + let { + id: mine_id = -1 + } = val + + if (mine_id == -1) { + let stoerArr = ['userInfo', 'location', 'appLogin', 'loginType', 'isShowLogin', + 'isGzhLogin' + ] + stoerArr.map(key => { + state[key] = key == 'isShowLogin' ? true : '' + uni.setStorageSync(key, key == 'isShowLogin' ? true : '') + }) + } + } + + if (['autograph', 'userInfo', 'location', 'appLogin', 'loginType', 'isShowLogin', 'isGzhLogin'] + .includes(key)) { + uni.setStorageSync(key, val) + } + + + if (key === 'locationChange' && val == true) { + let locationChangeUnix = $util.DateToUnix($util.formatTime(new Date(), 'YY-M-D h:m:s')) + state.locationChangeUnix = locationChangeUnix + } + + state[key] = val + } + }, + actions: { + //获取个人信息 + async getUserInfo({ + commit, + state + }, param) { + let data = await $api.user.userInfo() + commit('updateUserItem', { + key: 'userInfo', + val: data + }) + }, + //获取用户个人中心数据 + async getMineInfo({ + commit, + state + }, param) { + let data = await $api.mine.index() + let { + id = 0, + fx_status + } = data + if (!id) { + data = { + id: -1 + } + } + let { + fx_check = 0 + } = $store.state.config.configInfo + data.is_fx = !fx_check || (fx_check && fx_status == 2) + commit('updateUserItem', { + key: 'mineInfo', + val: data + }) + }, + //获取技-师信息 + async getCoachInfo({ + commit, + state + }, param) { + let data = await $api.technician.coachInfo() + commit('updateUserItem', { + key: 'coachInfo', + val: data + }) + }, + // 获取用户信息 + async getAuthUserProfile({ + commit, + state + }, param) { + let { + nickName, + avatarUrl + } = param + await $api.user.userUpdate(param) + let data = Object.assign({}, state.userInfo, { + nickName, + avatarUrl + }) + commit('updateUserItem', { + key: 'userInfo', + val: data + }) + }, + // 获取手机号 + async getAuthPhone({ + commit, + state + }, { + e = { + detail: {} + }, + must = false + } = {}) { + let { + encryptedData = '', iv = '' + } = e.detail; + let phone = '' + if (encryptedData && iv) { + let phone = await $api.user.reportPhone({ + encryptedData, + iv + }) + let data = Object.assign({}, state.userInfo, { + phone + }) + commit('updateUserItem', { + key: 'userInfo', + val: data + }) + return phone; + } + }, + // 更新公共参数 + async updateCommonOptions({ + commit, + state + }, param) { + let target = {} + if (param.scene) { + let res = await $api.base.getWxCodeData({ + code_id: param.scene + }) + target = Object.assign({}, state.commonOptions, res.data) + } else { + target = Object.assign({}, state.commonOptions, param) + } + let data = $util.pick(target, ['id', 'pid', 'coupon_atv_id', 'admin_id', 'channel_id', 'coach_id']) + commit('updateUserItem', { + key: 'commonOptions', + val: data + }) + return target + } + } +} \ No newline at end of file diff --git a/styles/1px.wxss b/styles/1px.wxss new file mode 100644 index 0000000..809cb42 --- /dev/null +++ b/styles/1px.wxss @@ -0,0 +1,102 @@ +/* 1px方案,改变border的颜色即可 */ +.b-1px, .b-1px-t, .b-1px-b, .b-1px-tb, .b-1px-l, .b-1px-r { + position: relative; +} + +.b-1px:before { + content: " "; + position: absolute; + left: 0; + top: 0; + width: 200%; + border: 1px solid #eee; + color: #eee; + height: 200%; + transform-origin: left top; + transform: scale(0.5); + box-sizing: border-box; +} + +.b-1px-t:before { + content: " "; + position: absolute; + left: 0; + top: 0; + right: 0; + height: 1px; + border-top: 1px solid #eee; + color: #eee; + transform-origin: 0 0; + transform: scaley(0.5); + box-sizing: border-box; +} + +.b-1px-b:after { + content: " "; + position: absolute; + left: 0; + bottom: 0; + right: 0; + height: 1px; + border-bottom: 1px solid #eee; + color: #eee; + transform-origin: 0 100%; + transform: scaley(0.5); + box-sizing: border-box; +} + +.b-1px-tb:before { + content: " "; + position: absolute; + left: 0; + top: 0; + right: 0; + height: 1px; + border-top: 1px solid #eee; + color: #eee; + transform-origin: 0 0; + transform: scaley(0.5); + box-sizing: border-box; +} + +.b-1px-tb:after { + content: " "; + position: absolute; + left: 0; + bottom: 0; + right: 0; + height: 1px; + border-bottom: 1px solid #eee; + color: #eee; + transform-origin: 0 100%; + transform: scaley(0.5); + box-sizing: border-box; +} + +.b-1px-l::before { + content: " "; + position: absolute; + left: 0; + top: 0; + width: 1px; + bottom: 0; + border-left: 1px solid #eee; + color: #eee; + transform-origin: 0 0; + transform: scalex(0.5); + box-sizing: border-box; +} + +.b-1px-r::after { + content: " "; + position: absolute; + right: 0; + top: 0; + width: 1px; + bottom: 0; + border-right: 1px solid #eee; + color: #eee; + transform-origin: 100% 0; + transform: scalex(0.5); + box-sizing: border-box; +} \ No newline at end of file diff --git a/styles/avatar.wxss b/styles/avatar.wxss new file mode 100644 index 0000000..84d45dc --- /dev/null +++ b/styles/avatar.wxss @@ -0,0 +1,54 @@ +/* 头像 */ +.avatar { + margin: 0; + padding: 0; + display: inline-flex; + text-align: center; + justify-content: center; + align-items: center; + /* background: #f4f6f8; */ + color: #fff; + white-space: nowrap; + position: relative; + width: 120rpx; + height: 120rpx; + background-size: cover; + background-position: center; + vertical-align: middle; +} + +.avatar.lg { + width: 160rpx; + height: 160rpx; +} + +.avatar.md { + width: 100rpx; + height: 100rpx; +} + +.avatar.sm { + width: 80rpx; + height: 80rpx; +} + +.avatar-group { + direction: ltl; + unicode-bidi: bidi-override; + display: inline-block; +} + +.avatar-group .avatar { + width: 48rpx; + height: 48rpx; + font-size: 1em; + border-radius: 50%; + margin-left: -20rpx; + border: 4rpx solid white; + vertical-align: middle; + transform: rotateZ(360deg); +} + +.avatar-group .avatar:nth-child(1) { + margin-left: 0rpx; +} diff --git a/styles/base.wxss b/styles/base.wxss new file mode 100644 index 0000000..8251159 --- /dev/null +++ b/styles/base.wxss @@ -0,0 +1,187 @@ + +/* 字体大小 */ +.f-little{font-size: 18rpx;} +.f-icontext{font-size: 22rpx;}/* 很小的文字,一般和图标一起使用 */ +.f-caption{font-size: 24rpx;}/* 辅助描述性文字 */ +.f-desc{font-size: 26rpx;}/* 段落字体 */ +.f-paragraph{font-size: 28rpx;}/* 段落字体 */ +.f-mini-title{font-size: 30rpx;} +.f-title{font-size: 32rpx;}/* 标题 */ +.f-st-title{font-size: 34rpx;}/* 大点的标题 */ +.f-sm-title{font-size: 36rpx;}/* 大点的标题 */ +.f-md-title{font-size: 40rpx;}/* 大点的标题 */ +.f-lg-title{font-size: 42rpx;}/* 大点的标题 */ +.f-big-title{font-size: 46rpx;}/* 大点的标题 */ + + +/* 字体颜色 */ +.c-base{color:#ffffff;}/* 白色 */ +.c-base-rgba{color:rgba(255, 255, 255, 0.6)}/* 白色 */ +.c-black{color: #000000;}/* 黑色 */ +.c-title{color: #232A24}/* 标题/副标题 */ +.c-desc{color:#3D2C1B;}/* 辅助描述性文字 */ +.c-caption{color:#999999;}/* 辅助描述性文字 */ +.c-disable{color: #c7c7c7;}/* 按钮文字禁用 */ +.c-paragraph{color:#666666;}/* 段落字体 */ +.c-success{color:#1BCA62;}/* 成功/链接文字 */ +.c-alipay{color:#01AAF2;}/* 支付宝支付文字 */ +.c-balance{color:#FA7917;}/* 🈷余额支付文字 */ +.c-tips{color:#ffd753;}/* 失效 */ +.c-warning{color:#E82F21;}/* 警告/非法 */ +.c-nodata{color:#cccccc;}/* 链接文字 */ +.c-orange{color:#ff4a00;}/* 首页价格文字 */ +.c-vip{color:#d9cf9a;}/* 充值文字 */ +.c-grey{color:#b9b9b9;}/* 灰色文字 */ +.c-shadow{text-shadow:2rpx 2rpx 2rpx #808080;}/* 字体阴影 */ + + + +/* 填充色 */ +.fill-base{background:#ffffff;}/* 默认 */ +.fill-black{background:#000000;}/* 默认 */ +.fill-body{background:#F7F8FA;}/* 页面 */ +.fill-primary{background:#19c865;}/* 主题色/主要活动按钮 */ +.fill-caption{background:#ffd753;}/* 辅助色 */ +.fill-warning{background:#f12c20;}/* 警告/非法 */ +.fill-second{background:#efeff4;}/* 区块分割线 */ +.fill-space{background: #FCFCFC;}/* 次要活动按钮 */ + +/* 阴影 */ +.box-shadow{box-shadow: 0px 3px 6px 0px rgba(227, 227, 227, 0.47);} +.box-shadow-mini{box-shadow: 2rpx 0 10rpx rgba(4,0,0,0.08);} + +/* 字体样式 */ +text{vertical-align: middle;}/* 上下居中 */ +.text-left{text-align: left;}/* 左对齐 */ +.text-center { text-align: center}/* 中对齐 */ +.text-right {text-align: right}/* 右对齐 */ +.text-justify{text-align: justify;}/* 两端对齐,谨慎使用 */ +.text-justify::after{content: '';width: 100%;display: inline-block;} +.text-delete {text-decoration: line-through}/* 删除线 */ +.text-underline{text-decoration: underline}/* 下划线 */ +.text-bold{ font-weight:bold;}/* 加粗 */ +.text-normal{ font-weight:normal;} + + +/* 文本溢出省略 */ +.ellipsis{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;} +.ellipsis-2{display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp:2;overflow: hidden;} +.ellipsis-3{display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp:3;overflow: hidden;} +.ellipsis-4{display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp:4;overflow: hidden;} + +/* 最大宽度 */ +.max-100{max-width: 100rpx;} +.max-150{max-width: 150rpx;} +.max-200{max-width: 200rpx;} +.max-270{max-width: 270rpx;} +.max-280{max-width: 280rpx;} +.max-300{max-width: 300rpx;} +.max-350{max-width: 350rpx;} +.max-380{max-width: 380rpx;} +.max-400{max-width: 400rpx;} +.max-446{max-width: 446rpx;} +.max-450{max-width: 450rpx;} +.max-470{max-width: 470rpx;} +.max-500{max-width: 500rpx;} +.max-510{max-width: 510rpx;} +.max-520{max-width: 520rpx;} +.max-540{max-width: 540rpx;} +.max-550{max-width: 550rpx;} +.max-566{max-width: 566rpx;} +.max-580{max-width: 580rpx;} + +/* 外间距 */ +.mg-sm{margin:10rpx;} +.mg-md{margin:20rpx;} +.mg-lg{margin:30rpx;} + +.mt-sm{margin-top:10rpx;} +.mt-md{margin-top:20rpx;} +.mt-lg{margin-top:30rpx;} + +.mr-sm{margin-right:10rpx;} +.mr-md{margin-right:20rpx;} +.mr-lg{margin-right:30rpx;} + +.mb-sm{margin-bottom:10rpx;} +.mb-md{margin-bottom:20rpx;} +.mb-lg{margin-bottom:30rpx;} + +.ml-sm{margin-left:10rpx;} +.ml-md{margin-left:20rpx;} +.ml-lg{margin-left:30rpx;} + + +/* 内间距 */ +.pd-sm{padding:10rpx;} +.pd-md{padding:20rpx;} +.pd-lg{padding:30rpx;} + +.pt-sm{padding-top:10rpx;} +.pt-md{padding-top:20rpx;} +.pt-lg{padding-top:30rpx;} + +.pr-sm{padding-right:10rpx;} +.pr-md{padding-right:20rpx;} +.pr-lg{padding-right:30rpx;} + +.pb-sm{padding-bottom:10rpx;} +.pb-md{padding-bottom:20rpx;} +.pb-lg{padding-bottom:30rpx;} + +.pl-sm{padding-left:10rpx;} +.pl-md{padding-left:20rpx;} +.pl-lg{padding-left:30rpx;} + + +/* 图标尺寸 */ +.icon-xs{width:32rpx; height:32rpx;display: block;font-size: 32rpx;} +.icon-sm{width:44rpx; height:44rpx;display: block;font-size: 44rpx;} +.icon-md{width:60rpx; height:60rpx;display: block;font-size: 60rpx;} +.icon-lg{width:80rpx; height:80rpx;display: block;font-size: 80rpx;} + + +/* 组件间距 */ +.space-sm{height: 10rpx;} +.space-md{height: 20rpx;} +.space-lg{height: 30rpx;} +.space-ht{height: 190rpx;} +.space-body{height: 150rpx;} +.space-safe{height: calc(env(safe-area-inset-bottom) / 2);padding-bottom: calc( env(safe-area-inset-bottom) / 2);} +.space-footer{height: 30rpx;height: calc(30rpx + env(safe-area-inset-bottom) / 2);padding-bottom: calc( env(safe-area-inset-bottom) / 2);} +.space-tabbar-footer{height: 100rpx;height: calc(100rpx + env(safe-area-inset-bottom) / 2);padding-bottom: calc( env(safe-area-inset-bottom) / 2);} +.space-max-footer{height: 180rpx;height: calc(180rpx + env(safe-area-inset-bottom) / 2);padding-bottom: calc(env(safe-area-inset-bottom) / 2);} +.space{height: 1rpx ;background: rgba(216, 216, 216, 0.5);} + + +/* 圆角 */ +.radius{border-radius: 5000rpx;} +.radius-5 {border-radius: 5rpx;} +.radius-10 {border-radius: 10rpx;} +.radius-16 {border-radius: 16rpx;} +.radius-18 {border-radius: 18rpx;} +.radius-20 {border-radius: 20rpx;} +.radius-24 {border-radius: 24rpx;} +.radius-26 {border-radius: 26rpx;} +.radius-32 {border-radius: 32rpx;} +.radius-34 {border-radius: 34rpx;} + +/* 旋转 */ +.rotate-45{transform: rotate(45deg);} +.rotate-90{transform: rotate(90deg);} +.rotate-180{transform: rotate(180deg);} +.rotate-270{transform: rotate(270deg);} + +/* 定位 */ +.rel{position: relative;} +.abs{position: absolute;} +.fix{position: fixed;width: 100%;z-index: 100;} +.fixed-top{position: fixed;left: 0;right: 0;top: 0;z-index: 100;} +.fixed-bottom{position: fixed;left: 0;right: 0;bottom: 0;z-index: 100;} + +/* 灰度 */ +.grayscale {-webkit-filter: grayscale(100%);filter: grayscale(100%);} + + +/* 字体颜色 */ +.icon-font-color{-webkit-background-clip: text;-webkit-text-fill-color: transparent;} \ No newline at end of file diff --git a/styles/button.wxss b/styles/button.wxss new file mode 100644 index 0000000..1ad5b36 --- /dev/null +++ b/styles/button.wxss @@ -0,0 +1,104 @@ +/* button样式修改 */ +button { + font-size: 30rpx; + border-radius: 15rpx; + /* line-height: 96rpx; */ + padding: 0rpx; + margin: 0rpx; + color: #fff; + background: transparent; +} + +button::after { + border-color: transparent; + border-radius: 30rpx; +} + +button.plain::after { + border-color: currentColor; +} + +button[type='grey'] { + color: #999999; + background: #EEEEEE; +} + +/* 订单按钮 */ +button.order { + min-width: 140rpx; + padding: 0 20rpx; + line-height: 52rpx; + color: #5B5B5B; + background: #fff; + border-radius: 8rpx; + border: 1rpx solid #979797; + transform: rotateZ(360deg); + font-size: 26rpx; + font-weight: bold; + display: inline-flex; + align-items: center; + justify-content: center; + margin-left: 20rpx +} + + +/* 购物车按钮 */ +button.reduce, +button.add { + width: 38rpx; + height: 38rpx; + border-radius: 10rpx; + border: 1rpx solid #EEEEEE; + transform: rotateZ(360deg); + display: flex; + align-items: center; + justify-content: center; + overflow: hidden; +} + +button.reduce .iconfont, +button.add .iconfont { + font-size: 24rpx; + line-height: 24rpx; + overflow: hidden; +} + +button.addreduce, +input.addreduce { + min-width: 60rpx; + padding: 0 10rpx; + height: 38rpx; + color: #666666; + font-size: 28rpx; + display: flex; + align-items: center; + justify-content: center; + margin: 0rpx 10rpx; +} + +input.addreduce { + text-align: center; + max-width: 150rpx; +} + + +/* 按钮按下 */ +.button-hover { + opacity: 0.6; +} + +/* 清除按钮默认样式 */ +.clear-btn { + margin: 0; + padding: 0; + background: transparent; + border-radius: 0rpx; + line-height: 1.5; + border: none; + text-align: left; + color: #333; +} + +.clear-btn::after { + border: none; +} diff --git a/styles/icon.wxss b/styles/icon.wxss new file mode 100644 index 0000000..87980da --- /dev/null +++ b/styles/icon.wxss @@ -0,0 +1,1657 @@ +@font-face { + font-family: 'iconfont'; /* Project id 4110196 */ + src: url('https://at.alicdn.com/t/c/font_4110196_r2eepy29ecm.woff2?t=1690765463726') format('woff2'), + url('https://at.alicdn.com/t/c/font_4110196_r2eepy29ecm.woff?t=1690765463726') format('woff'), + url('https://at.alicdn.com/t/c/font_4110196_r2eepy29ecm.ttf?t=1690765463726') format('truetype'); +} +@font-face { + font-family: "iconfont"; /* Project id 2649930 */ + src: url('https://at.alicdn.com/t/c/font_2649930_kwmue8hcdxj.woff2?t=1685093547270') format('woff2'), + url('https://at.alicdn.com/t/c/font_2649930_kwmue8hcdxj.woff?t=1685093547270') format('woff'), + url('https://at.alicdn.com/t/c/font_2649930_kwmue8hcdxj.ttf?t=1685093547270') format('truetype'); +} + +.iconfont { + font-family: "iconfont" !important; + font-size: 16px; + line-height:1; + font-style: normal; + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.icon-kzz:before { + content: "\e90c"; +} + +.icon-kpk:before { + content: "\e932"; +} + +.icon-kzj:before { + content: "\e819"; +} + +.icon-khz:before { + content: "\e9b1"; +} + +.icon-kpb:before { + content: "\e9c3"; +} + +.icon-kdt:before { + content: "\e9c9"; +} + +.icon-khydj:before { + content: "\e97f"; +} + +.icon-kcpss:before { + content: "\e982"; +} + +.icon-kcfmx:before { + content: "\e90d"; +} + +.icon-ksc1:before { + content: "\e945"; +} + +.icon-ksc:before { + content: "\e9c0"; +} + +.icon-kqh1:before { + content: "\e929"; +} + +.icon-kdd2:before { + content: "\e81d"; +} + +.icon-kqh:before { + content: "\e856"; +} + +.icon-kdqr:before { + content: "\e911"; +} + +.icon-kwd:before { + content: "\e918"; +} + +.icon-ktg:before { + content: "\e919"; +} + +.icon-kfs:before { + content: "\e921"; +} + +.icon-shouyi:before { + content: "\e92a"; +} + +.icon-kefu:before { + content: "\e95c"; +} + +.icon-ksy:before { + content: "\e922"; +} + +.icon-qichuyue:before { + content: "\e66e"; +} + +.icon-kfkjy1:before { + content: "\f917"; +} + +.icon-kdzf:before { + content: "\e9a5"; +} + +.icon-kfkjy:before { + content: "\e937"; +} + +.icon-kye:before { + content: "\faf6"; +} + +.icon-khhr2:before { + content: "\e956"; +} + +.icon-kjs:before { + content: "\e917"; +} + +.icon-kqds1:before { + content: "\e9ef"; +} + +.icon-khhr:before { + content: "\e972"; +} + +.icon-dd:before { + content: "\e97b"; +} + +.icon-kqds:before { + content: "\e850"; +} + +.icon-kyhj:before { + content: "\e889"; +} + +.icon-kll:before { + content: "\e831"; +} + +.icon-kdd:before { + content: "\e80d"; +} + +.icon-kpj:before { + content: "\e66f"; +} + +.icon-dizhi:before { + content: "\e871"; +} + +.icon-shijian:before { + content: "\e909"; +} + +.icon-shuxian:before { + content: "\e908"; +} + +.icon-tech:before { + content: "\e905"; +} + +.icon-tuijian:before { + content: "\e906"; +} + +.icon-tuijian1:before { + content: "\e907"; +} + +.icon-czsg:before { + content: "\e902"; +} + +.icon-csmt:before { + content: "\e901"; +} + +.icon-qcbz:before { + content: "\e904"; +} + +.icon-sybp:before { + content: "\e903"; +} + +.icondianqianhetong:before { + content: "\e7b2"; +} + +.iconduanxinyanzhengma:before { + content: "\e61e"; +} + +.iconshoujitianchong:before { + content: "\e6e3"; +} + +.iconemiyanzhengma:before { + content: "\e61b"; +} + +.iconbiaoqianye-dituzhaoren1:before { + content: "\e7ac"; +} + +.iconbiaoqianye-dituzhaoren2:before { + content: "\e7ae"; +} + +.icondituzhaoren2:before { + content: "\e7a1"; +} + +.iconshimingrenzheng:before { + content: "\e7a3"; +} + +.iconzizhirenzheng:before { + content: "\e7a7"; +} + +.iconshaixuan:before { + content: "\e7a8"; +} + +.iconliebiaomoshi2:before { + content: "\e7aa"; +} + +.iconhetongguanli:before { + content: "\e66d"; +} + +.iconfenleiyingyongtongzhi2:before { + content: "\e6a9"; +} + +.iconjingjirenshuoming:before { + content: "\e79f"; +} + +.iconxiangxiazhankai:before { + content: "\e8f2"; +} + +.iconyinhangqia:before { + content: "\e622"; +} + +.icontixingshixin:before { + content: "\ec72"; +} + +.iconwoyaofabu:before { + content: "\e79e"; +} + +.icondaijiedan1:before { + content: "\e78c"; +} + +.iconyijiedan1:before { + content: "\e792"; +} + +.iconyiwancheng1:before { + content: "\e79d"; +} + +.iconedit-fill:before { + content: "\eb5c"; +} + +.iconbianzu-8_2x:before { + content: "\e606"; +} + +.iconbianzu-8_2x_1_:before { + content: "\e607"; +} + +.iconjinrong_financebeifen-2_2x:before { + content: "\e619"; +} + +.iconshangjia_1:before { + content: "\e78f"; +} + +.iconbangdingqudaoshang:before { + content: "\e767"; +} + +.iconbangdingyewuyuan:before { + content: "\e780"; +} + +.icondaizhuandan:before { + content: "\e791"; +} + +.icondaifuwu4:before { + content: "\e795"; +} + +.iconjujuetuikuan:before { + content: "\e796"; +} + +.iconjishidaoda1:before { + content: "\e799"; +} + +.iconjishichufa1:before { + content: "\e79b"; +} + +.iconjishijiedan1:before { + content: "\e79c"; +} + +.icontixianshenqing1:before { + content: "\e7a0"; +} + +.icontixianjilu1:before { + content: "\e7a2"; +} + +.iconlianxifangshi:before { + content: "\e7a4"; +} + +.icontongyituikuan:before { + content: "\e7a5"; +} + +.iconyongjinxinxi1:before { + content: "\e7a6"; +} + +.iconwodeshouyi2:before { + content: "\e7a9"; +} + +.iconyiwancheng:before { + content: "\e7ab"; +} + +.iconwodeyaoqing1:before { + content: "\e7ad"; +} + +.iconzhanghaoshezhi:before { + content: "\e7b0"; +} + +.iconshenqingzhong:before { + content: "\e7b3"; +} + +.iconpeiwanguan2:before { + content: "\e760"; +} + +.iconpeiwanguan1:before { + content: "\e77f"; +} + +.iconshangcheng2:before { + content: "\e75e"; +} + +.icondaipinglun:before { + content: "\e755"; +} + +.icondaifukuan:before { + content: "\e756"; +} + +.icondaifuwu3:before { + content: "\e758"; +} + +.icondizhi2:before { + content: "\e759"; +} + +.icondituzhaoren1:before { + content: "\e75c"; +} + +.icondingdan11:before { + content: "\e75f"; +} + +.icongexingbiaoqian:before { + content: "\e765"; +} + +.iconhezuohuoban:before { + content: "\e766"; +} + +.icondizhiguanli3:before { + content: "\e768"; +} + +.iconfuwuzhong3:before { + content: "\e76c"; +} + +.iconjishixiangqing:before { + content: "\e772"; +} + +.iconjishi11:before { + content: "\e774"; +} + +.iconlianxikefu3:before { + content: "\e783"; +} + +.icondianpu:before { + content: "\e784"; +} + +.iconpinglun3:before { + content: "\e785"; +} + +.iconqiehuan:before { + content: "\e78b"; +} + +.iconshoucang23:before { + content: "\e78d"; +} + +.iconshenqingjishi3:before { + content: "\e78e"; +} + +.iconwode12:before { + content: "\e793"; +} + +.icontuikuan3:before { + content: "\e794"; +} + +.iconwoshiqudao2:before { + content: "\e797"; +} + +.iconwentifankui4:before { + content: "\e798"; +} + +.iconshoucang13:before { + content: "\e79a"; +} + +.iconbuxihuan-xuanzhong:before { + content: "\e753"; +} + +.iconbuxihuan:before { + content: "\e754"; +} + +.icondizhiguanli2:before { + content: "\e757"; +} + +.iconfaxian-1:before { + content: "\e75b"; +} + +.iconfaxian-2:before { + content: "\e75d"; +} + +.iconhehuoren1:before { + content: "\e762"; +} + +.iconpeiwanguan:before { + content: "\e76a"; +} + +.iconpinglun2:before { + content: "\e76b"; +} + +.iconshangchuantupian:before { + content: "\e76d"; +} + +.iconshezhi:before { + content: "\e76e"; +} + +.iconshenqingfenxiaoyuan:before { + content: "\e76f"; +} + +.iconshouye12:before { + content: "\e770"; +} + +.iconshichang:before { + content: "\e771"; +} + +.iconshouye2:before { + content: "\e777"; +} + +.iconwentifankui3:before { + content: "\e778"; +} + +.iconwode-1:before { + content: "\e77a"; +} + +.iconwode-2:before { + content: "\e781"; +} + +.iconxiaoxi2:before { + content: "\e786"; +} + +.iconwoshiqudaoshang:before { + content: "\e782"; +} + +.iconwoyaoruzhu:before { + content: "\e788"; +} + +.iconxiaoxi1:before { + content: "\e789"; +} + +.iconxiangqing2:before { + content: "\e78a"; +} + +.iconshoucang22:before { + content: "\e72b"; +} + +.iconshoucang12:before { + content: "\e730"; +} + +.icondizhi_1:before { + content: "\e737"; +} + +.icondadianhua_1:before { + content: "\e73d"; +} + +.iconshipin2:before { + content: "\e735"; +} + +.iconbangdingjishi1:before { + content: "\e723"; +} + +.icondaifuwu2:before { + content: "\e72a"; +} + +.icondaipingjia2:before { + content: "\e72c"; +} + +.icondaizhifu2:before { + content: "\e72d"; +} + +.icondizhi1:before { + content: "\e72e"; +} + +.icondizhiguanli1:before { + content: "\e72f"; +} + +.icondingdan1:before { + content: "\e731"; +} + +.icondianming:before { + content: "\e732"; +} + +.iconfuwuzhong2:before { + content: "\e733"; +} + +.icongongsi:before { + content: "\e734"; +} + +.iconjingxiaoshang:before { + content: "\e736"; +} + +.iconjuli3:before { + content: "\e738"; +} + +.iconjishi1:before { + content: "\e739"; +} + +.iconlianxikefu2:before { + content: "\e73a"; +} + +.iconmendian1:before { + content: "\e73b"; +} + +.iconpingjia:before { + content: "\e73c"; +} + +.iconqiehuanjishiduan2:before { + content: "\e740"; +} + +.iconputonghuiyuan:before { + content: "\e741"; +} + +.iconshijian1:before { + content: "\e742"; +} + +.iconshenqingjishi2:before { + content: "\e743"; +} + +.iconshoucang:before { + content: "\e745"; +} + +.iconshouye1:before { + content: "\e746"; +} + +.iconwentifankui2:before { + content: "\e747"; +} + +.icontuiguanghaibao1:before { + content: "\e748"; +} + +.iconwode11:before { + content: "\e749"; +} + +.iconwodeshouyi1:before { + content: "\e74b"; +} + +.iconwodefensi:before { + content: "\e74c"; +} + +.iconwoshiqudao1:before { + content: "\e74d"; +} + +.iconyingyezhizhao:before { + content: "\e74e"; +} + +.iconshenqingfenxiaoshang:before { + content: "\e74f"; +} + +.icontuikuan2:before { + content: "\e750"; +} + +.iconyingyeshijian:before { + content: "\e751"; +} + +.iconzuizaokeyue1:before { + content: "\e752"; +} + +.icon-hezuoguanxi:before { + content: "\e8a9"; +} + +.iconpinglun1:before { + content: "\e70d"; +} + +.iconjuli2:before { + content: "\e70e"; +} + +.iconshoucang11:before { + content: "\e713"; +} + +.iconshoucang21:before { + content: "\e715"; +} + +.iconxiangqing1:before { + content: "\e716"; +} + +.iconcamera-fill:before { + content: "\e711"; +} + +.icondaipingjia1:before { + content: "\e718"; +} + +.icondaifuwu1:before { + content: "\e719"; +} + +.icondaizhifu1:before { + content: "\e71a"; +} + +.icondizhi:before { + content: "\e71b"; +} + +.iconlianxikefu1:before { + content: "\e71c"; +} + +.iconhehuoren:before { + content: "\e71d"; +} + +.iconpingbiyonghu:before { + content: "\e71e"; +} + +.iconshenqingjishi1:before { + content: "\e71f"; +} + +.icontixianjilu:before { + content: "\e720"; +} + +.icontuikuan1:before { + content: "\e721"; +} + +.iconfuwuzhong1:before { + content: "\e722"; +} + +.iconwentifankui1:before { + content: "\e724"; +} + +.iconwodeyaoqing:before { + content: "\e725"; +} + +.iconqiehuanjishiduan1:before { + content: "\e726"; +} + +.iconwodeyouhuiquan:before { + content: "\e727"; +} + +.iconwoshiqudao:before { + content: "\e728"; +} + +.iconyongjinliushui:before { + content: "\e729"; +} + +.icondingdan4:before { + content: "\e709"; +} + +.iconpingfen1:before { + content: "\e70a"; +} + +.iconjuli1:before { + content: "\e70b"; +} + +.iconanmo3:before { + content: "\e70c"; +} + +.iconshangjia:before { + content: "\e70f"; +} + +.iconshijian:before { + content: "\e710"; +} + +.iconshouye31:before { + content: "\e712"; +} + +.iconwode3:before { + content: "\e714"; +} + +.iconzuizaokeyue:before { + content: "\e717"; +} + +.icon-account:before { + content: "\e610"; +} + +.icon-alipay-fill:before { + content: "\e669"; +} + +.iconshipin:before { + content: "\e618"; +} + +.iconshang:before { + content: "\e862"; +} + +.iconxia:before { + content: "\e863"; +} + +.icon-android:before { + content: "\e63d"; +} + +.icon-play-video:before { + content: "\e66e"; +} + +.icon-shield:before { + content: "\e65d"; +} + +.icondingdanguanli:before { + content: "\e700"; +} + +.iconshouhuodepinglun:before { + content: "\e703"; +} + +.iconxinzengguanzhu:before { + content: "\e706"; +} + +.icontixianshenqing:before { + content: "\e707"; +} + +.iconyongjinxinxi:before { + content: "\e708"; +} + +.iconkeyuyue:before { + content: "\e6ff"; +} + +.icon-bofang:before { + content: "\e621"; +} + +.icon-caidan:before { + content: "\e790"; +} + +.icon-edit:before { + content: "\ec7c"; +} + +.icon-kefuwu:before { + content: "\e702"; +} + +.icon-dongtai2:before { + content: "\e6f7"; +} + +.icon-dongtai1:before { + content: "\e6fb"; +} + +.icon-shoucang-fill:before { + content: "\e6fc"; +} + +.icon-shoucang:before { + content: "\e6fd"; +} + +.icon-pinglun:before { + content: "\e6fe"; +} + +.iconshengji:before { + content: "\e6f4"; +} + +.icon-required:before { + content: "\e649"; +} + +.iconchefeitixianjilu:before { + content: "\e6f0"; +} + +.icondengjiguanli:before { + content: "\e6f1"; +} + +.iconyanzhengma:before { + content: "\e624"; +} + +.icondangqianweizhi:before { + content: "\e6de"; +} + +.iconshijianguanli2:before { + content: "\e6df"; +} + +.iconweizhigengxin1:before { + content: "\e6e0"; +} + +.iconyijianbaojing:before { + content: "\e6e1"; +} + +.icontishishuoming:before { + content: "\e64c"; +} + +.iconshuyi_shuoming:before { + content: "\e668"; +} + +.icon-alipay:before { + content: "\e68a"; +} + +.icon-level-line:before { + content: "\e6dd"; +} + +.icon-level-icon:before { + content: "\e6d4"; +} + +.icon-xiuxi:before { + content: "\e667"; +} + +.icon-jiedan:before { + content: "\e625"; +} + +.icon-zaixian:before { + content: "\e89d"; +} + +.icon-caiwuguanli:before { + content: "\e617"; +} + +.icon-guanbi-fill:before { + content: "\e85f"; +} + +.iconwodeshoucang:before { + content: "\e6c8"; +} + +.iconwodekaquan:before { + content: "\e6c9"; +} + +.iconshouye:before { + content: "\e6e2"; +} + +.icontushucxuanzebofangtiaozhuan:before { + content: "\e677"; +} + +.icongengduo1:before { + content: "\e644"; +} + +.iconbianjiziliao:before { + content: "\e6c4"; +} + +.iconchapingshensu:before { + content: "\e6c5"; +} + +.iconchefeimingxi:before { + content: "\e6c6"; +} + +.iconchongzhijine:before { + content: "\e6c7"; +} + +.iconfenchengmingxi:before { + content: "\e6ca"; +} + +.iconfenxiang:before { + content: "\e6cb"; +} + +.iconjifenmingxi:before { + content: "\e6cc"; +} + +.iconguanbi:before { + content: "\e6cd"; +} + +.iconqiehuanyonghuduan:before { + content: "\e6ce"; +} + +.iconjiazhongtongji:before { + content: "\e6cf"; +} + +.iconriqi:before { + content: "\e6d0"; +} + +.iconshangchuanzhaopian:before { + content: "\e6d1"; +} + +.iconsousuo:before { + content: "\e6d2"; +} + +.iconshijianguanli1:before { + content: "\e6d3"; +} + +.iconweizhigengxin:before { + content: "\e6d5"; +} + +.iconwentifankui:before { + content: "\e6d6"; +} + +.iconwuliaoshangcheng:before { + content: "\e6d7"; +} + +.iconyejimingxi:before { + content: "\e6d9"; +} + +.iconzhuxiaozhanghu:before { + content: "\e6db"; +} + +.iconwoyaojieyue:before { + content: "\e6dc"; +} + +.icongengduo:before { + content: "\e6b8"; +} + +.iconguan:before { + content: "\e6bc"; +} + +.iconkai:before { + content: "\e6c1"; +} + +.icon-weixin:before { + content: "\e627"; +} + +.icon-apple:before { + content: "\e60f"; +} + +.icongerenxinxi:before { + content: "\e616"; +} + +.iconzhiweixiangqing:before { + content: "\e6e5"; +} + +.icon-account-line:before { + content: "\e688"; +} + +.icon-person-accounts:before { + content: "\e6ba"; +} + +.icon-chaifenyemian:before { + content: "\e6c0"; +} + +.icon-diy:before { + content: "\e629"; +} + +.icon-zuzhi:before { + content: "\eaaa"; +} + +.icon-qudao:before { + content: "\e63b"; +} + +.iconjishijiedan:before { + content: "\e6b9"; +} + +.iconerweima3:before { + content: "\e84c"; +} + +.iconerweima:before { + content: "\e623"; +} + +.iconjishidaoda:before { + content: "\e6b3"; +} + +.iconjishichufa:before { + content: "\e6b5"; +} + +.iconjishifuwu:before { + content: "\e6b6"; +} + +.iconjishiwancheng:before { + content: "\e6bd"; +} + +.iconyijiedan:before { + content: "\e6be"; +} + +.icondaijiedan:before { + content: "\e6bf"; +} + +.iconjingbao:before { + content: "\e636"; +} + +.iconanmo1:before { + content: "\e857"; +} + +.iconanmo2:before { + content: "\e858"; +} + +.iconchongzhi:before { + content: "\e859"; +} + +.iconbodadianhua:before { + content: "\e85a"; +} + +.icondaipingjia:before { + content: "\e85b"; +} + +.icondizhiguanli:before { + content: "\e85c"; +} + +.icondingdan2:before { + content: "\e85d"; +} + +.iconfuwuzhong:before { + content: "\e85e"; +} + +.iconjifen3:before { + content: "\e860"; +} + +.icondingdan3:before { + content: "\e861"; +} + +.iconjuli:before { + content: "\e867"; +} + +.iconlianxikefu:before { + content: "\e868"; +} + +.iconbangdingjishi:before { + content: "\e869"; +} + +.iconpinglun:before { + content: "\e86a"; +} + +.iconqiehuanjishiduan:before { + content: "\e86b"; +} + +.icondaizhifu:before { + content: "\e86c"; +} + +.icondaifuwu:before { + content: "\e86d"; +} + +.iconshaixuanshang-1:before { + content: "\e870"; +} + +.iconshijianguanli:before { + content: "\e873"; +} + +.iconshipin1:before { + content: "\e875"; +} + +.iconshoucang1:before { + content: "\e876"; +} + +.iconshenqingjishi:before { + content: "\e877"; +} + +.iconshoucangjishi:before { + content: "\e878"; +} + +.iconshouye21:before { + content: "\e879"; +} + +.iconshouye11:before { + content: "\e87a"; +} + +.iconpingfen:before { + content: "\e87b"; +} + +.icontuikuan:before { + content: "\e87c"; +} + +.icontuiguanghaibao:before { + content: "\e87d"; +} + +.iconwodeshouyi:before { + content: "\e87e"; +} + +.iconxiangqing:before { + content: "\e87f"; +} + +.iconwodetuandui1:before { + content: "\e880"; +} + +.iconshaixuanxia-1:before { + content: "\e881"; +} + +.iconsousuo1:before { + content: "\e883"; +} + +.iconshoucang2:before { + content: "\e884"; +} + +.iconwode2:before { + content: "\e885"; +} + +.iconyaoqingyouli:before { + content: "\e886"; +} + +.iconwode1:before { + content: "\e887"; +} + +.icon-down-fill:before { + content: "\e665"; +} + +.icon-up-fill:before { + content: "\e666"; +} + +.iconweixin:before { + content: "\e64f"; +} + +.icon-share:before { + content: "\e638"; +} + +.iconnan-xiaotu:before { + content: "\e7b1"; +} + +.iconnv-xiaotu:before { + content: "\e7b4"; +} + +.icontongzhi:before { + content: "\e64e"; +} + +.iconsanjiao_xia:before { + content: "\e671"; +} + +.iconbalance:before { + content: "\e763"; +} + +.iconweixinzhifu1:before { + content: "\e764"; +} + +.iconqianbao:before { + content: "\e829"; +} + +.iconhuiyuanka:before { + content: "\e7af"; +} + +.icon-liuyanguanli:before { + content: "\e6bb"; +} + +.iconguanzhu:before { + content: "\e68c"; +} + +.iconguanzhuxuanzhong:before { + content: "\e689"; +} + +.iconyduixingxingkongxin:before { + content: "\e779"; +} + +.iconyduixingxingshixin:before { + content: "\e77b"; +} + +.icon-yuyue:before { + content: "\e6da"; +} + +.icon-yingxiao:before { + content: "\e701"; +} + +.icon-gouwuche-fill:before { + content: "\e600"; +} + +.icon-dingwei-fill:before { + content: "\e602"; +} + +.icon-left:before { + content: "\e604"; +} + +.icon-right:before { + content: "\e608"; +} + +.icon-close:before { + content: "\e609"; +} + +.icon-add:before { + content: "\e611"; +} + +.icon-gouwudai:before { + content: "\e73e"; +} + +.icon-caiwu:before { + content: "\e6a7"; +} + +.icon-kehu:before { + content: "\e6ad"; +} + +.icon-member:before { + content: "\e761"; +} + +.icon-shenhe:before { + content: "\e695"; +} + +.icon-xitong:before { + content: "\e6a8"; +} + +.icon-daifukuan:before { + content: "\e787"; +} + +.icon-dingdanguanli:before { + content: "\e632"; +} + +.icon-shangpin:before { + content: "\e63c"; +} + +.icon-dianpu:before { + content: "\e66c"; +} + +.icon-daihexiao:before { + content: "\e6f8"; +} + +.icon-yiwancheng:before { + content: "\e6f9"; +} + +.icon-pingjia:before { + content: "\e77e"; +} + +.icon-home:before { + content: "\e775"; +} + +.icon-home-fill:before { + content: "\e776"; +} + +.icon-dingwei:before { + content: "\e612"; +} + +.icon-shouhouguanli:before { + content: "\e773"; +} + +.icon-jishi:before { + content: "\e652"; +} + +.icon-wodeshouhou:before { + content: "\e60d"; +} + +.icon-tongzhi-fill:before { + content: "\e615"; +} + +.icon-jishi-fill:before { + content: "\e601"; +} + +.icon-tuichu:before { + content: "\e603"; +} + +.icon-camera:before { + content: "\e60e"; +} + +.icon-down:before { + content: "\e60a"; +} + +.icon-xuanze:before { + content: "\e77c"; +} + +.icon-xuanze-fill:before { + content: "\e77d"; +} + +.icon-switch:before { + content: "\e642"; +} + +.icon-switch-on:before { + content: "\e643"; +} + +.icon-jian-fill:before { + content: "\e61f"; +} + +.icon-jian:before { + content: "\e6fa"; +} + +.icon-radio-fill:before { + content: "\e620"; +} + +.icon-gouwudai-fill:before { + content: "\e6d8"; +} + +.icon-eyeclose:before { + content: "\e6ab"; +} + +.icon-eyeopen:before { + content: "\e6ac"; +} + +.icon-mima:before { + content: "\e69e"; +} + +.icon-username:before { + content: "\e6b7"; +} + +.icon-mine:before { + content: "\e6f5"; +} + +.icon-mine-fill:before { + content: "\e6f6"; +} + +.icon-tongzhi:before { + content: "\e60b"; +} + +.icon-jia-bold:before { + content: "\e613"; +} + +.icon-jian-bold:before { + content: "\e614"; +} + +.icon-tianjia:before { + content: "\e653"; +} + +.icon-zhuanhuan:before { + content: "\e6c2"; +} + +.icon-xiaochengxu:before { + content: "\e6c3"; +} + +.icon-warn:before { + content: "\e6a5"; +} + +.icon-weirenzheng:before { + content: "\e63a"; +} + +.icon-biaoqian:before { + content: "\e60c"; +} + +.icon-shuaxin:before { + content: "\e654"; +} diff --git a/styles/index.wxss b/styles/index.wxss new file mode 100644 index 0000000..b9a2929 --- /dev/null +++ b/styles/index.wxss @@ -0,0 +1,9 @@ +@import './1px.wxss'; +@import './avatar.wxss'; +@import './base.wxss'; +@import './button.wxss'; +@import './icon.wxss'; +@import './layout.wxss'; +@import './navbar.wxss'; +@import './popup.wxss'; +@import './pages.wxss'; diff --git a/styles/layout.wxss b/styles/layout.wxss new file mode 100644 index 0000000..b9ecb6d --- /dev/null +++ b/styles/layout.wxss @@ -0,0 +1,60 @@ +/*flex布局,可以自己定义适合自己的*/ +.flex { + display: flex; +} + +.flex-1 { + flex: 1; +} + +.flex-column { + display: flex; + flex-direction: column; +} + +.flex-warp { + display: flex; + flex-wrap: wrap; +} + +.flex-center { + display: flex; + align-items: center; + justify-content: center; +} + +.flex-between { + display: flex; + align-items: center; + justify-content: space-between; +} + +.flex-x-center { + display: flex; + justify-content: center; +} + +.flex-x-between { + display: flex; + justify-content: space-between; +} + +.flex-y-center { + display: flex; + align-items: center; +} + +.flex-y-start { + display: flex; + align-items: flex-start; +} + +.flex-y-end { + display: flex; + align-items: flex-end; +} + +.flex-y-baseline { + display: flex; + align-items: baseline; +} diff --git a/styles/navbar.wxss b/styles/navbar.wxss new file mode 100644 index 0000000..a701bbd --- /dev/null +++ b/styles/navbar.wxss @@ -0,0 +1,100 @@ +/* ios_自定义navBar */ +.back-user-ios { + width: 87px; + height: 32px; + border-radius: 32px; + margin-top: 6px; + display: flex; + align-items: center; + justify-content: center; + background: #fff; + border: 1px solid #eeeeee; + margin-left: 24rpx; + transform: rotateZ(360deg); +} + +.back-user-ios .back-user_avatar { + width: 24px; + height: 24px; + border-radius: 50%; + background: #f4f6f8; +} + +.back-user-ios .back-user_text { + font-size: 11px; + line-height: 44px; + margin-left: 5px; +} + +/* .nav_c_text { + line-height: 44px; + font-size: 16px; +} */ + +/* android_自定义navBar */ +.back-user-android { + /* #ifdef MP-BAIDU */ + width: 74.5px; + height: 28px; + border-radius: 28px; + margin-top: 5px; + /* #endif */ + /* #ifndef MP-BAIDU */ + width: 87px; + height: 32px; + border-radius: 32px; + margin-top: 6px; + /* #endif */ + display: flex; + align-items: center; + justify-content: center; + background: #fff; + border: 1px solid #eeeeee; + margin-left: 24rpx; + transform: rotateZ(360deg); +} + + +.back-user-android .back-user_avatar { + /* #ifdef MP-BAIDU */ + width: 20px; + height: 20px; + /* #endif */ + /* #ifndef MP-BAIDU */ + width: 24px; + height: 24px; + /* #endif */ + border-radius: 50%; + background: #f4f6f8; +} + + +.back-user-android .back-user_text { + /* #ifdef MP-BAIDU */ + font-size: 10px; + line-height: 28px; + margin-left: 3px; + /* #endif */ + /* #ifndef MP-BAIDU */ + font-size: 11px; + line-height: 44px; + margin-left: 5px; + /* #endif */ +} + +.back-user-ios.none, +.back-user-android.none { + color: #fff; + background: none; +} + +.nav_c_text { + /* #ifdef MP-BAIDU */ + line-height: 36px; + font-size: 15px; + /* #endif */ + /* #ifndef MP-BAIDU */ + line-height: 44px; + font-size: 16px; + /* #endif */ +} diff --git a/styles/pages.wxss b/styles/pages.wxss new file mode 100644 index 0000000..55603f1 --- /dev/null +++ b/styles/pages.wxss @@ -0,0 +1,440 @@ +.page-height { + width: 100%; + height: 100vh; + background: #fff; +} + +/* 单选/多选按钮 */ +.pay-icon { + font-size: 40rpx; +} + +/* 分享按钮 */ +.common-share-btn { + right: 30rpx; + bottom: 140rpx; + width: 90rpx; + height: 90rpx; + margin-bottom: calc(env(safe-area-inset-bottom) / 2); + + .iconfont { + font-size: 40rpx; + } +} + +.common-share-btn.detail { + bottom: 170rpx; +} + +.map-info { + .iconjuli { + font-size: 42rpx; + } + + .icon-down { + transform: scale(0.5); + } +} + +/* 海报 */ +.hideCanvasView { + position: relative; + + .hideCanvas { + position: absolute; + left: -9999rpx; + top: -9999rpx + } +} + +/* 技-师页面 */ +.pages-technician { + .fix-info { + height: 225rpx; + + .space-top { + width: 100%; + height: 40rpx; + top: 0; + } + + .search-info { + width: 100%; + top: 0; + + .city-info { + width: 170rpx; + + .iconfont { + font-size: 20rpx; + transform: scale(0.5); + } + } + } + } + + .fix-info.choose { + height: 135rpx; + } + + + .choose-city-popup { + padding: 0 32rpx 0 30rpx; + + .city-img { + width: 688rpx; + height: 364rpx; + } + + .text { + top: 256rpx; + left: 78rpx; + width: 606rpx; + } + + .flex-between { + margin-top: 25rpx; + + .item-btn { + width: 238rpx; + height: 85rpx; + background: #F9F9F9; + } + } + + } +} + + +/* 订单相关页面 */ +.order-pages { + + .service-type-item { + min-width: 143rpx; + height: 59rpx; + padding: 0 10rpx; + background: #F5F5F5; + border-radius: 8rpx + } + + .address-info { + .address-icon { + width: 64rpx; + height: 64rpx; + + .iconfont { + font-size: 38rpx; + } + } + + .username { + font-size: 30rpx; + } + } + + .store-info { + + .item-icon { + width: 40rpx; + height: 40rpx; + + .iconfont { + font-size: 28rpx; + } + + .item-icon { + top: 0; + left: 0; + opacity: 0.1; + } + } + } + + + + .item-child { + .bell-tag { + top: 0; + left: 0; + width: 120rpx; + height: 40rpx; + border-radius: 16rpx 0 16rpx 0; + } + + .grayscale { + + .c-title, + .c-warning { + color: #999; + } + } + + .cover { + width: 155rpx; + height: 155rpx; + } + + .refund-img { + width: 196rpx; + height: 196rpx; + } + + .refund-img:nth-child(3n) { + margin-right: 0 + } + } + + .item-textarea { + width: 570rpx; + height: 300rpx; + } + + .menu-list { + margin-top: -30rpx; + + .menu-title { + height: 90rpx; + + .iconfont { + font-size: 24rpx; + } + } + + .menu-line { + width: 80%; + top: 76rpx; + left: 10%; + } + + .item-child { + width: 20%; + margin: 10rpx 0; + + .item-img { + width: 72rpx; + height: 72rpx; + z-index: 9; + border: 1px solid #666; + + .iconfont { + font-size: 40rpx; + } + } + } + + } + + .add-bell { + .menu-line { + width: 70%; + top: 76rpx; + left: 15%; + } + + .item-child { + width: 33.33%; + } + + } + + .order-agent-info { + color: #4A4A4A; + + .coach-img { + width: 94rpx; + height: 94rpx; + } + + .title { + width: 200rpx; + font-weight: bold; + } + + .text { + color: #777; + font-size: 26rpx; + } + } + + .copy-btn { + width: 60rpx; + height: 32rpx; + border: 1rpx solid #fff; + transform: rotateZ(360deg); + } + + .copy-btn.fill { + color: 333; + borderColor: #eee; + background: #eee; + padding: 2rpx 6rpx; + } + + .copy-btn.span { + padding: 2rpx 6rpx; + } + + .footer-info { + + bottom: 0; + + .item-btn { + min-width: 150rpx; + height: 64rpx; + padding: 0 10rpx; + background: #EEEEEE; + } + + } + +} + + +/* 申请表单相关页面 */ +.apply-pages { + .apply-form { + + .item-text { + width: 200rpx; + height: 30rpx; + line-height: 30rpx; + font-size: 30rpx; + color: #1F1F1F; + } + + .item-input { + min-height: 30rpx; + line-height: 30rpx; + padding: 25rpx 0; + font-size: 26rpx; + color: #A9A9A9; + } + + .item-input.text { + padding: 30rpx 0; + } + + .item-textarea { + width: 630rpx; + height: 400rpx; + color: #A9A9A9; + } + + .icon-switch, + .icon-switch-on { + font-size: 90rpx; + line-height: 46rpx; + } + } +} + +/* 储值明细记录 */ +.stored-record-pages { + .list-time { + z-index: 99999; + + .item-child { + width: 50%; + height: 95rpx; + + .iconfont { + font-size: 28rpx; + } + } + } + + movable-area, + movable-view { + width: 686rpx; + height: 148rpx; + overflow: hidden; + } + + .touch-item { + font-size: 14px; + display: flex; + justify-content: space-between; + width: 686rpx; + height: 100%; + overflow: hidden + } + + .content { + width: 100%; + -webkit-transition: all 0.4s; + transition: all 0.4s; + -webkit-transform: translateX(270rpx); + transform: translateX(270rpx); + margin-left: -270rpx; + } + + .delete-btn { + width: 120rpx; + height: 100%; + color: #fff; + border-radius: 0 15rpx 15rpx 0; + -webkit-transform: translateX(270rpx); + transform: translateX(270rpx); + -webkit-transition: all 0.4s; + transition: all 0.4s; + } + + .touch-move-active .content, + .touch-move-active .delete-btn { + -webkit-transform: translateX(0); + transform: translateX(0); + } + + .popup-choose-time { + .item-child { + width: 50%; + } + } +} + +.container { + width: 100%; +} + +/* 技-师等级 */ +.technician-level { + height: 333rpx; + background: linear-gradient(206deg, #464749 0%, #020202 30%, #000000 100%); + border-radius: 16rpx; + transform: rotateZ(360deg); + overflow: hidden; + + .icon-level-icon { + font-size: 505rpx; + top: -86rpx; + left: 40rpx; + z-index: -1; + } + + .level-icon-img { + top: 22rpx; + right: 41rpx; + width: 111rpx; + height: 111rpx; + } + + .level-title { + font-size: 38rpx; + color: #F9F9F9; + } + + .level-line { + width: 100%; + height: 20rpx; + background: #2D333C; + } + + .level-line.cur { + top: 0; + left: 0; + } + + .f-icontext { + color: rgba(255, 255, 255, 0.7); + } +} \ No newline at end of file diff --git a/styles/popup.wxss b/styles/popup.wxss new file mode 100644 index 0000000..9bfac09 --- /dev/null +++ b/styles/popup.wxss @@ -0,0 +1,72 @@ +.common-popup-content { + width: 620rpx; + height: auto; + padding: 50rpx; + display: flex; + align-items: center; + justify-content: center; + flex-direction: column; + + .title { + font-size: 40rpx; + font-family: Microsoft YaHei; + font-weight: bold; + color: #333; + } + + .desc, + .name { + font-size: 24rpx; + font-family: Microsoft YaHei; + font-weight: 400; + color: #666; + margin-top: 5rpx; + } + + .name { + color: #999; + margin-top: 15rpx; + } + + .image { + width: 200rpx; + height: 200rpx; + border-radius: 15rpx; + margin-top: 40rpx; + } + + .image.middle { + width: 300rpx; + height: 300rpx; + } + + .input { + width: 480rpx; + height: 110rpx; + background: #F7F7F7; + } + .textarea { + width: 480rpx; + height: 300rpx; + background: #F7F7F7; + } + + .button { + display: flex; + align-items: center; + justify-content: center; + margin-top: 50rpx; + + .item-child { + width: 240rpx; + height: 90rpx; + color: #666; + background: #EEEEEE; + border-radius: 45rpx; + margin: 0 20rpx; + display: flex; + align-items: center; + justify-content: center; + } + } +} diff --git a/technician/pages/apply.vue b/technician/pages/apply.vue new file mode 100644 index 0000000..fc5b116 --- /dev/null +++ b/technician/pages/apply.vue @@ -0,0 +1,704 @@ + ++ + ++ ++ ++ ++ + + ++ ++ ++ ++ + + + ++ + + + + + + + + + + + + + + \ No newline at end of file diff --git a/technician/pages/bad-comments/box.vue b/technician/pages/bad-comments/box.vue new file mode 100644 index 0000000..ef458d8 --- /dev/null +++ b/technician/pages/bad-comments/box.vue @@ -0,0 +1,159 @@ + ++ + ++ + + ++ ++ ++ +{{max_level || 0}} ++ ++ ++ 您的姓名 + +您的性别 ++ +{{item}} + +您的生日 ++ ++ ++ +{{form.birthday||'请选择'}} + +手机号 ++ + ++ + ++ {{authTime>0?`重新获取(${authTime}s)`:'获取验证码'}} + +意向工作城市 ++ + ++ ++ +{{cityIndex!=-1?cityList[cityIndex].title:'请选择'}} + ++ +工作形象照 +图片建议尺寸: 750 * 750 +请上传本人近期照片,图片大小不超过10M ++ ++ ++ 平台不会通过任何渠道泄露您的个人信息,请放心输入 + ++ ++ + + + + + diff --git a/technician/pages/bad-comments/choice.vue b/technician/pages/bad-comments/choice.vue new file mode 100644 index 0000000..50fdd89 --- /dev/null +++ b/technician/pages/bad-comments/choice.vue @@ -0,0 +1,232 @@ + ++ ++ ++ +* +选择关联订单 ++ ++ +关联订单 ++ +{{ orderInfo.id ? '重新选择':'请选择'}} + ++ ++ ++ + +{{item.goods_name}} ++ +预约时间 +{{orderInfo.start_time}} ++ +¥ +{{item.true_price}} ++ ++ + +* +申诉理由 ++ + + ++ + + + + + diff --git a/technician/pages/bad-comments/list.vue b/technician/pages/bad-comments/list.vue new file mode 100644 index 0000000..95f2758 --- /dev/null +++ b/technician/pages/bad-comments/list.vue @@ -0,0 +1,147 @@ + ++ ++ ++ + ++ + + ++ ++ ++ ++ + + 订单号 {{item.order_code}} ++ ++ + +{{citem.goods_name}} ++ +预约时间 +{{item.start_time}} ++ +¥ +{{citem.true_price}} ++ + + ++ + + + + + diff --git a/technician/pages/bad-comments/success.vue b/technician/pages/bad-comments/success.vue new file mode 100644 index 0000000..2fb7c1e --- /dev/null +++ b/technician/pages/bad-comments/success.vue @@ -0,0 +1,65 @@ + ++ ++ + ++ ++ +订单号 {{item.order_code}} +未处理 +已处理 ++ +申诉理由 +{{item.content}} ++ +处理结果 +{{item.reply_content || '无'}} ++ ++ + + + + + + + diff --git a/technician/pages/car-fare.vue b/technician/pages/car-fare.vue new file mode 100644 index 0000000..e3f8d6e --- /dev/null +++ b/technician/pages/car-fare.vue @@ -0,0 +1,220 @@ + ++ ++ 提交成功 +您已经成功提交申请,申诉结果可在申诉记录里查看。 +查看申诉记录 ++ + + + + + diff --git a/technician/pages/edit.vue b/technician/pages/edit.vue new file mode 100644 index 0000000..911f566 --- /dev/null +++ b/technician/pages/edit.vue @@ -0,0 +1,700 @@ + ++ ++ ++ + ++ + ++ + + ++ ++ +订单号 {{item.order_code}} ++ {{ item.trip_end_address | addressMatch}} + ++ +起 +{{item.trip_start_address}} ++ +终 +{{item.trip_end_address}} +出发时间 {{item.serout_time}} +到达时间 {{item.arrive_time}} ++ + ++ +金额 +(往返车费): +{{item.car_price}}元 ++ ++ ++ + + + + + + + + \ No newline at end of file diff --git a/technician/pages/income/cash-integral.vue b/technician/pages/income/cash-integral.vue new file mode 100644 index 0000000..d3925fa --- /dev/null +++ b/technician/pages/income/cash-integral.vue @@ -0,0 +1,532 @@ + ++ + ++ ++ +姓名 + ++ +性别 ++ +{{item}} + ++ +生日 ++ ++ ++ {{form.birthday||'请选择'}} + + ++ +手机号 + ++ +验证码 ++ + ++ {{authTime>0?`重新获取(${authTime}s)`:'获取验证码'}} + ++ +从业年份 + ++ + +意向工作城市 ++ ++ ++ {{cityIndex!=-1?cityList[cityIndex].title:'请选择'}} + + ++ +挂靠门店 ++ ++ ++ +{{storeIndex!=-1?storeList[storeIndex].title:'请选择'}} + + ++ +所在地址 ++ ++ +{{form.address || `点击右边图标设置`}} + ++ ++ + +{{$t('action.attendantName')}}简介 + ++ {{form.text.length>300?300:form.text.length}}/300 + ++ ++ +身份证号 + ++ ++ +身份证照片 +图片大小不超过10M ++ ++ + + ++ + ++ +资格证书 +图片大小不超过10M ++ ++ ++ ++ +工作形象照 +图片建议尺寸: 750 * 750,大小不超过10M ++ ++ ++ ++ +个人生活照 +图片建议尺寸: 750 * n,大小不超过10M ++ ++ ++ ++ +个人视频介绍 +视频大小不超过50M ++ ++ ++ 编辑资料将进入重新审核,审核通过之前将显示原资料 + ++ + + ++ + + + + + + + diff --git a/technician/pages/income/commission-detail.vue b/technician/pages/income/commission-detail.vue new file mode 100644 index 0000000..a92df09 --- /dev/null +++ b/technician/pages/income/commission-detail.vue @@ -0,0 +1,289 @@ + ++ + ++ ++ ++ +查询时间 ++ {{ prev_time | handleTimeText(1) }} + ++ ++ +¥{{count.total_cash||0}} +累计佣金 ++ +{{count.total_integral||0}} +累计积分 ++ ++ ++ ++ +{{item.month_text}} + +共计佣金¥{{item.total_cash}} + +共计积分 {{item.total_integral}} ++ ++ +{{ prev_time | handleTimeText(2) }} + +共计佣金¥{{count.cash}} + +共计积分 {{count.integral}} ++ ++ + ++ ++ +充值金额 ++ {{item.user_cash}} + ++ {{item.type==0?item.integral:`¥${item.integral}`}} + +积分 +充值用户 +{{item.nickName || '-'}} + +充值时间 ++ {{item.create_time}} + ++ ++ + + + + + ++ ++ ++ ++ + + ++ +{{activeIndex==0?'选择月份':'自定义时间'}} +最长可查找时间跨度一年的交易 ++ 清除 ++ ++ +开始月份 ++ {{check_time.month || '选择月份'}} + ++ ++ +开始时间 ++ {{check_time.start_time || '选择时间'}} + ++ +结束时间 ++ {{check_time.end_time || '选择时间'}} + ++ ++ 确定 ++ + + ++ + + + + + + \ No newline at end of file diff --git a/technician/pages/income/commission-list.vue b/technician/pages/income/commission-list.vue new file mode 100644 index 0000000..23b8bf2 --- /dev/null +++ b/technician/pages/income/commission-list.vue @@ -0,0 +1,554 @@ + ++ + ++ +订单号 + {{detail.order_code}} + +项目明细 ++ {{item.goods_name}}x{{item.true_num}} + +¥{{item.true_total_price}} ++ +服务时间 +{{detail.time_text}} ++ +项目总金额 +¥{{detail.init_service_price}} ++ +物料费 +¥{{detail.material_price}} + ++ ¥{{detail.init_material_price}} ++ +卡券优惠 +-¥{{detail.discount}} ++ +分成比例 +{{detail.coach_balance}}% ++ +应得收益 + + + {{`${detail.coach_text} =`}} + + ++ + + + + +加钟明细 ++ ++ {{aitem.goods_name}}{{aindex==0?` (第${index*1+1}次加钟)`:''}}x{{aitem.num}} + +¥{{aitem.price}} ++ +项目总金额 +¥{{item.true_service_price}} ++ +物料费 +¥{{item.material_price}} ++ +分成比例 +{{item.coach_balance}}% ++ +分摊扣费 +-¥{{item.total_share_cash}} ++ ++ 应得收益 + + + {{`${item.add_coach_text} =`}} + + ++ +加钟收益 + + {{`${detail.add_coach_text} =`}} + + ++ + +车费明细 ++ +车费收益 +¥{{detail.true_car_price}} ++ + + + + ++ +实际收益 + + {{`${detail.total_order_text} =`}} + + ++ + + ++ +应得收益计算规则 ++ ++ 应得收益 = (项目总金额 - 卡券优惠) * 分成比例 + ++ 应得收益 = (项目总金额 + 物料费 - 卡券优惠) * 分成比例 - 物料费 + ++ +知道了 ++ + ++ +加钟收益计算规则 ++ ++ 应得收益 = 项目总金额 * 分成比例 - 分摊扣费 + ++ 应得收益 = (项目总金额 + 物料费) * 分成比例 - 物料费 - 分摊扣费 + ++ +知道了 ++ + + + + + + diff --git a/technician/pages/income/index.vue b/technician/pages/income/index.vue new file mode 100644 index 0000000..7ed7823 --- /dev/null +++ b/technician/pages/income/index.vue @@ -0,0 +1,149 @@ + ++ ++ ++ ++ +查询时间 ++ {{ prev_time | handleTimeText(1) }} + ++ ++ +¥{{count[item.key]||0}} +{{item.title}} ++ ++ ++ ++ +{{item.month_text}} + +实际收益¥{{item.total_cash}} + +共{{item.total_count}}笔订单 ++ ++ +{{ prev_time | handleTimeText(2)}} + +实际收益¥{{count.service_cash}} + +共{{count.count}}笔订单 ++ ++ ++ 订单号 {{item.order_code}} + +查看详情 +{{item.create_time}} ++ +订单收益 +¥ ++ {{item.coach_cash}} + ++ ++ + + + + + ++ ++ ++ ++ + + ++ +{{activeIndex==0?'选择月份':'自定义时间'}} +最长可查找时间跨度一年的交易 ++ 清除 ++ ++ +开始月份 ++ {{check_time.month || '选择月份'}} + ++ ++ +开始时间 ++ {{check_time.start_time || '选择时间'}} + ++ +结束时间 ++ {{check_time.end_time || '选择时间'}} + ++ ++ 确定 ++ + + + ++ ++ +{{countList[countInd].title}} ++ {{countList[countInd].text}} + ++ +知道了 ++ + + + + + + diff --git a/technician/pages/level.vue b/technician/pages/level.vue new file mode 100644 index 0000000..a388723 --- /dev/null +++ b/technician/pages/level.vue @@ -0,0 +1,443 @@ + ++ ++ + 可提现金额(元) +¥ ++ {{detail.cap_cash}} + +每月提现不限次数 +提现 + ++ + + ++ +{{detail.extract_total_price}} +总收入(元) ++ +{{detail.no_received}} +未入账(元) ++ +提现记录 ++ +提现中 {{detail.extract_ing_price}}元 + ++ + + + + + + + \ No newline at end of file diff --git a/technician/pages/order/detail.vue b/technician/pages/order/detail.vue new file mode 100644 index 0000000..a82c794 --- /dev/null +++ b/technician/pages/order/detail.vue @@ -0,0 +1,1137 @@ + ++ + + + ++ ++ + ++ + + ++ ++ ++ ++ ++ {{aindex==0?levelList[index-1].title : levelList[index+1].title}} + ++ ++ ++ + {{item.title}} + ++ + ++ ++ {{item.title}} + ++ {{ index < curLevelInd ? '已解锁': index == curLevelInd ? '当前等级' : '未解锁' }} + ++ + ++ + + +{{item.data.title}} +{{item.data.next_level_title}} ++ +{{aindex<2 || aindex==item.data.differ_text.length-1? aitem: `、${aitem}` }} ++ + ++ ++ {{coach_level[item.key]}}{{item.unit||''}} + +{{item.text}} ++ +规则说明 ++ + ++ ++ {{index==1 && bindex > 0?'¥':''}}{{bitem}}{{bindex > 0 ?unitArr[index] : ''}} + ++ + + + ++ +规则说明 ++ 在折算周期(T)内,{{$t('action.attendantName')}}完成以下维度的考核指标后,{{$t('action.attendantName')}}可以在T+1个周期按照该等级算提成比例,例如折算周期为每月,{{$t('action.attendantName')}}在这个月内完成了多少,会在月底30号系统核算,满足某个等级标准之后,会在下一个月的1号生效 + ++ 最低业绩:{{$t('action.attendantName')}}服务的所有服务订单和加钟订单,不包含车费。 + ++ 加钟率:加钟订单金额/最低业绩 + ++ 服务时长:{{$t('action.attendantName')}}接单服务的时间 + ++ 在线时长:{{$t('action.attendantName')}}在线工作的时间 + ++ 积分:若储值返佣设置勾选了返积分,则{{$t('action.attendantName')}}邀请用户充值将获得积分,积分和金额按照1:1比例换算 + ++ +知道了 ++ + + + + + + + \ No newline at end of file diff --git a/technician/pages/order/label.vue b/technician/pages/order/label.vue new file mode 100644 index 0000000..33bcb00 --- /dev/null +++ b/technician/pages/order/label.vue @@ -0,0 +1,188 @@ + ++ + + ++ + + +{{statusType[detail.pay_type]}} +请在 +内完成支付,逾期未支付,订单将自动取消 + + + + ++ + ++ ++ + +{{item.title}} ++ + ++ +服务内容 ++ + ++ + + ++ ++ + + ++ ++ {{aitem.goods_name}} + +已退x{{aitem.refund_num}} +服务时长:{{aitem.time_long}}分钟 +物料费:¥{{aitem.material_price}} + ++ +¥ ++ {{aitem.price}} + +x{{aitem.num}} ++ + + ++ {{detail.store_info.title}} + ++ ++ + ++ {{detail.store_info.address || `暂未设置门店地址`}} + + ++ ++ ++ + + ++ + + + ++ +下单人 ++ +{{detail.address_info.user_name}} +查看标签 + ++ +联系方式 ++ + +拨打电话 ++ +服务地址 ++ ++ {{`${detail.address_info.address}${detail.address_info.address_info}`}} + + ++ + +立刻导航去 ++ +订单备注 +{{detail.text}} ++ + ++ +下单时间 +{{detail.create_time}} ++ +服务时间 +{{detail.start_time}} ++ +服务时长 +{{detail.time_long}}分钟 ++ ++ +车费详情 +{{carType[detail.car_type]}} + +全程{{detail.distance}} ++ +出行费用 +出租车 ¥{{detail.car_price}} ++ +服务项目费用 +¥{{detail.init_service_price}} ++ +物料费 +¥{{detail.material_price}} ++ +卡券优惠 +-¥{{detail.discount}} ++ +支付方式 +{{payType[detail.pay_model]}} ++ ++ 总计: +¥{{detail.pay_price}} ++ + ++ +订单编号: ++ +{{detail.order_code}} +复制 ++ + + + ++ ++ + + + ++ + + + + ++ + + + + ++ + + + ++ + + ++ + + ++ + +客户标签 ++ + + ++ +暂无评价标签 ++ ++ +{{item.title}} ++ + + + + ++ +拒绝接单 +请确认是否拒接接单 + ++ ++ {{coach_refund_text.length>200?200:coach_refund_text.length}}/200 ++ +取消 +确定 ++ + + + + + + + ++ +{{popupInfo.title}} ++ + +拍照打卡: ++ ++ ++ +当前地点: ++ {{popupInfo.location.address || '点击获取定位'}} + ++ +取消 +确定 ++ + + + + + + diff --git a/technician/pages/order/list.vue b/technician/pages/order/list.vue new file mode 100644 index 0000000..553266d --- /dev/null +++ b/technician/pages/order/list.vue @@ -0,0 +1,914 @@ + ++ + +推荐标签 +点击添加标签 ++ + +暂无标签 ++ ++ + +{{item.title}} ++ +已选标签 ++ + +暂无选中标签 ++ ++ + {{item.title}} ++ + + + + ++ + + + + + + \ No newline at end of file diff --git a/technician/pages/order/recorder.vue b/technician/pages/order/recorder.vue new file mode 100644 index 0000000..565b190 --- /dev/null +++ b/technician/pages/order/recorder.vue @@ -0,0 +1,184 @@ + ++ + + ++ + ++ + + + ++ +加钟服务 + ++ + +订单号:{{item.order_code}} ++ {{statusType[item.pay_type]}} + ++ + ++ + + ++ ++ + + + ++ ++ {{aitem.goods_name}} + +已退x{{aitem.refund_num}} +服务时间:{{item.start_time}} ++ +¥ ++ {{aitem.price}} + +x{{aitem.num}} ++ +总计: + +¥{{item.pay_price}} ++ + + ++ + + + ++ + + + ++ + + + ++ + + ++ ++ + + + + + + ++ +拒绝接单 +请确认是否拒接接单 + ++ ++ {{coach_refund_text.length>200?200:coach_refund_text.length}}/200 ++ +取消 +确定 ++ + + + ++ +{{popupInfo.title}} ++ + +拍照打卡: ++ ++ ++ +当前地点: ++ {{popupInfo.location.address || '点击获取定位'}} + ++ +取消 +确定 ++ + + + + + + ++ +温馨提示 +屏蔽客户之后,该客户将不能在列表看到您的信息,会影响你的接单,可以在{{$t('action.attendantName')}}端 - + 屏蔽客户页面移除屏蔽客户,确认屏蔽吗? ++ +我再想想 +确定 ++ + + + + + + + \ No newline at end of file diff --git a/technician/pages/shield.vue b/technician/pages/shield.vue new file mode 100644 index 0000000..2b3b7b0 --- /dev/null +++ b/technician/pages/shield.vue @@ -0,0 +1,162 @@ + +H5 录音 +保存录音文件 +{{recorder}} + --------------------------------------------------------------------------------------------------- ++ + +data.data ---- {{recorder.data}} +data.type---------{{recorder.data.type || '------'}} ++ + + + + + + + diff --git a/technician/pages/shop/detail.vue b/technician/pages/shop/detail.vue new file mode 100644 index 0000000..2681297 --- /dev/null +++ b/technician/pages/shop/detail.vue @@ -0,0 +1,239 @@ + ++ ++ +{{item.nickName}} +拉黑时间: ++ {{item.create_time}} + +移除列表 ++ ++ + + + + + + + diff --git a/technician/pages/shop/list.vue b/technician/pages/shop/list.vue new file mode 100644 index 0000000..cd796d1 --- /dev/null +++ b/technician/pages/shop/list.vue @@ -0,0 +1,357 @@ + ++ ++ + ++ ++ + + + + +{{shopInfo.name}} ++ +¥ +{{shopInfo.price}} ++ + ++ 分享 ++ +商品详情 ++ + +加载中... ++ + ++ + + + + + diff --git a/technician/pages/time-manage.vue b/technician/pages/time-manage.vue new file mode 100644 index 0000000..bbd4f40 --- /dev/null +++ b/technician/pages/time-manage.vue @@ -0,0 +1,294 @@ + ++ ++ ++ + ++ + ++ +{{item.name}} ++ +更多 ++ + ++ ++ ++ ++ + +{{item.name}} ++ +¥ +{{item.price}} ++ ++ +类别 ++ ++ ++ ++ +{{item.name}} ++ +重置 +确定 ++ ++ + + + + + + + + + diff --git a/technician/pages/time-set.vue b/technician/pages/time-set.vue new file mode 100644 index 0000000..12536e3 --- /dev/null +++ b/technician/pages/time-set.vue @@ -0,0 +1,437 @@ + ++ + +是否接单 ++ {{form.is_work==1?'接单':'休息'}} + ++ + ++ +选择接单时间 ++ ++ +开始时间 ++ {{form.start_time || '选择时间'}} + ++ +结束时间 ++ {{form | handleStartEndTime(toDay)}}{{form.end_time || '选择时间'}} + ++ ++ +设置不可接单时间 +(只能设置近{{dayList.length}}天的时间) ++ + ++ ++ +{{item.time_text}} +{{isTimes(item.time_str) || item.status == 0 ? '不可预约' : '可预约'}} ++ + + + + + + + + + + + \ No newline at end of file diff --git a/uni.scss b/uni.scss new file mode 100644 index 0000000..b04ded9 --- /dev/null +++ b/uni.scss @@ -0,0 +1,103 @@ +/** + * 这里是uni-app内置的常用样式变量 + * + * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量 + * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App + * + */ + +/** + * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能 + * + * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件 + */ + +/* 颜色变量 */ +@mixin bg_color($color) { + background-color: $color; + [data-theme="theme1"] & { + background-color:#F3C149; + } +} + +// 背景 +$-background-main-color:#F8F8F8;//主色 +$-background-deputy-color:#FFFFFF;//副色 +$-background-secondary-color:#373A3F;//次色 +$-background-select-vehicle-color:#1258E6;//车辆 +$-background-select-make-color:linear-gradient(-90deg, #F7B433, #F3C149);//挂号人默认背景 + +// 文本 +$-text-main-color:#3175FE;//主色 +$-text-deputy-color:#999999;//副色 +$-text-secondary-color:#333333;//副色 + +//按钮 +$-button-main-color:#373A3F;//主色 +$-button-deputy-color:#C9CDD4;//副色 + + + + + + +/* 行为相关颜色 */ +$uni-color-primary: #007aff; +$uni-color-success: #4cd964; +$uni-color-warning: #f0ad4e; +$uni-color-error: #dd524d; + +/* 文字基本颜色 */ +$uni-text-color:#333;//基本色 +$uni-text-color-inverse:#fff;//反色 +$uni-text-color-grey:#999;//辅助灰色,如加载更多的提示信息 +$uni-text-color-placeholder: #808080; +$uni-text-color-disable:#c0c0c0; + +/* 背景颜色 */ +$uni-bg-color:#ffffff; +$uni-bg-color-grey:#f8f8f8; +$uni-bg-color-hover:#f1f1f1;//点击状态颜色 +$uni-bg-color-mask:rgba(0, 0, 0, 0.4);//遮罩颜色 + +/* 边框颜色 */ +$uni-border-color:#c8c7cc; + +/* 尺寸变量 */ + +/* 文字尺寸 */ +$uni-font-size-sm:24rpx; +$uni-font-size-base:28rpx; +$uni-font-size-lg:32rpx; + +/* 图片尺寸 */ +$uni-img-size-sm:40rpx; +$uni-img-size-base:52rpx; +$uni-img-size-lg:80rpx; + +/* Border Radius */ +$uni-border-radius-sm: 4rpx; +$uni-border-radius-base: 6rpx; +$uni-border-radius-lg: 12rpx; +$uni-border-radius-circle: 50%; + +/* 水平间距 */ +$uni-spacing-row-sm: 10px; +$uni-spacing-row-base: 20rpx; +$uni-spacing-row-lg: 30rpx; + +/* 垂直间距 */ +$uni-spacing-col-sm: 8rpx; +$uni-spacing-col-base: 16rpx; +$uni-spacing-col-lg: 24rpx; + +/* 透明度 */ +$uni-opacity-disabled: 0.3; // 组件禁用态的透明度 + +/* 文章场景相关 */ +$uni-color-title: #2C405A; // 文章标题颜色 +$uni-font-size-title:40rpx; +$uni-color-subtitle: #555555; // 二级标题颜色 +$uni-font-size-subtitle:36rpx; +$uni-color-paragraph: #3F536E; // 文章段落颜色 +$uni-font-size-paragraph:30rpx; \ No newline at end of file diff --git a/uni_modules/lime-painter/changelog.md b/uni_modules/lime-painter/changelog.md new file mode 100644 index 0000000..84871a5 --- /dev/null +++ b/uni_modules/lime-painter/changelog.md @@ -0,0 +1,153 @@ +## 1.9.3.4(2022-06-20) +- fix: 修复 因创建节点速度问题导致顺序出错。 +- fix: 修复 微信小程序 PC 无法显示本地图片 +- fix: 修复 flex-box 对齐问题 +- feat: 增加 `text-shadow` +- feat: 重写 `text` 对齐方式 +- chore: 更新文档 +## 1.9.3.3(2022-06-17) +- fix: 修复 支付宝小程序 canvas 2d 存在ctx.draw问题导致报错 +- fix: 修复 支付宝小程序 toDataURL 存在权限问题改用 `toTempFilePath` +- fix: 修复 支付宝小程序 image size 问题导致 `objectFit` 无效 +## 1.9.3.2(2022-06-14) +- fix: 修复 image 设置背景色不生效问题 +- fix: 修复 nvue 环境判断缺少参数问题 +## 1.9.3.1(2022-06-14) +- fix: 修复 bottom 定位不对问题 +- fix: 修复 因小数导致计算出错换行问题 +- feat: 增加 `useCORS` h5端图片跨域 在设置请求头无效果后试一下设置这个值 +- chore: 更新文档 +## 1.9.3(2022-06-13) +- feat: 增加 `zIndex` +- feat: 增加 `flex-box` 该功能处于原始阶段,非常简陋。 +- tips: QQ小程序 vue3 不支持, 为 uni 官方BUG +## 1.9.2.9(2022-06-10) +- fix: 修复`text-align`及`margin`居中问题 +## 1.9.2.8(2022-06-10) +- fix: 修复 Nvue `canvasToTempFilePathSync` 不生效问题 +## 1.9.2.7(2022-06-10) +- fix: 修复 margin及padding的bug +- fix: 修复 Nvue `isCanvasToTempFilePath` 不生效问题 +## 1.9.2.6(2022-06-09) +- fix: 修复 Nvue 不显示 +- feat: 增加支持字体渐变 +```html ++ +白天出租出行免车费设置 + ({{timeFrom.day_time ? timeFrom.day_time : '00:00~00:00'}} ) + + ++ + ++ 设置时间 + ++ + ++ {{item}}公里 + ++ +夜晚出租出行免车费设置 + ({{timeFrom.night_time ? timeFrom.night_time : '00:00~00:00'}}) + + ++ + + ++ 设置时间 + ++ + + ++ {{item}}公里 + ++ +温馨提示 ++ + ++ 1.此处设置的免车费公里数是客户距离你的直线距离,直线距离 + 和车行距离在地理位置特殊性上可能有一定误差,望大家设置 + 距离时知晓。 + 2.设置的免出行费只针对出租车 + 3.设置后请点击下方[确定] 按钮生效 + 4、全国默认1公里免车费,可自行调整公里数 + + ++ + + + + + + +``` +## 1.9.2.5(2022-06-09) +- chore: 更变获取父级宽度的设定 +- chore: `pathType` 在canvas 2d 默认为 `url` +## 1.9.2.4(2022-06-08) +- fix: 修复 `pathType` 不生效问题 +## 1.9.2.3(2022-06-08) +- fix: 修复 `canvasToTempFilePath` 漏写 `success` 参数 +## 1.9.2.2(2022-06-07) +- chore: 更新文档 +## 1.9.2.1(2022-06-07) +- fix: 修复 vue3 赋值给this再传入导致image无法绘制 +- fix: 修复 `canvasToTempFilePathSync` 时机问题 +- feat: canvas 2d 更改图片生成方式 `toDataURL` +## 1.9.2(2022-05-30) +- fix: 修复 `canvasToTempFilePathSync` 在 vue3 下只生成一次 +## 1.9.1.7(2022-05-28) +- fix: 修复 `qrcode`显示不全问题 +## 1.9.1.6(2022-05-28) +- fix: 修复 `canvasToTempFilePathSync` 会重复多次问题 +- fix: 修复 `view` css `backgroundImage` 图片下载失败导致 子节点不渲染 +## 1.9.1.5(2022-05-27) +- fix: 修正支付宝小程序 canvas 2d版本号 2.7.15 +## 1.9.1.4(2022-05-22) +- fix: 修复字节小程序无法使用xml方式 +- fix: 修复字节小程序无法使用base64(非2D情况下工具上无法显示) +- fix: 修复支付宝小程序 `canvasToTempFilePath` 报错 +## 1.9.1.3(2022-04-29) +- fix: 修复vue3打包后uni对象为空后的报错 +## 1.9.1.2(2022-04-25) +- fix: 删除多余文件 +## 1.9.1.1(2022-04-25) +- fix: 修复图片不显示问题 +## 1.9.1(2022-04-12) +- fix: 因四舍五入导致有些机型错位 +- fix: 修复无views报错 +- chore: nvue下因ios无法读取插件内static文件,改由下载方式 +## 1.9.0(2022-03-20) +- fix: 因无法固定尺寸导致生成图片不全 +- fix: 特定情况下text判断无效 +- chore: 本地化APP Nvue webview +## 1.8.9(2022-02-20) +- fix: 修复 小程序下载最多10次并发的问题 +- fix: 修复 APP端无法获取本地图片 +- fix: 修复 APP Nvue端不执行问题 +- chore: 增加图片缓存机制 +## 1.8.8.8(2022-01-27) +- fix: 修复 主动调用尺寸问题 +## 1.8.8.6(2022-01-26) +- fix: 修复 nvue 下无宽度时获取父级宽度 +- fix: 修复 ios app 无法渲染问题 +## 1.8.8(2022-01-23) +- fix: 修复 主动调用时无节点问题 +- fix: 修复 `box-shadow` 颜色问题 +- fix: 修复 `transform:rotate` 角度位置问题 +- feat: 增加 `overflow:hidden` +## 1.8.7(2022-01-07) +- fix: 修复 image 方向为 `right` 时原始宽高问题 +- feat: 支持 view 设置背景图 `background-image: url(xxx)` +- chore: 去掉可选链 +## 1.8.6(2021-11-28) +- feat: 支持`view`对`inline-block`的子集使用`text-align` +## 1.8.5.5(2021-08-17) +- chore: 更新文档,删除 replace +- fix: 修复 text 值为 number时报错 +## 1.8.5.4(2021-08-16) +- fix: 字节小程序兼容 +## 1.8.5.3(2021-08-15) +- fix: 修复线性渐变与css现实效果不一致的问题 +- chore: 更新文档 +## 1.8.5.2(2021-08-13) +- chore: 增加`background-image`、`background-repeat` 能力,主要用于背景纹理的绘制,并不是代替`image`。例如:大面积的重复平铺的水印 +- 注意:这个功能H5暂时无法使用,因为[官方的API有BUG](https://ask.dcloud.net.cn/question/128793),待官方修复!!! +## 1.8.5.1(2021-08-10) +- fix: 修复因`margin`报错问题 +## 1.8.5(2021-08-09) +- chore: 增加margin支持`auto`,以达到居中效果 +## 1.8.4(2021-08-06) +- chore: 增加判断缓存文件条件 +- fix: 修复css 多余空格报错问题 +## 1.8.3(2021-08-04) +- tips: 1.6.x 以下的版本升级到1.8.x后要为每个元素都加上定位:position: 'absolute' +- fix: 修复只有一个view子元素时不计算高度的问题 +## 1.8.2(2021-08-03) +- fix: 修复 path-type 为 `url` 无效问题 +- fix: 修复 qrcode `text` 为空时报错问题 +- fix: 修复 image `src` 动态设置时不生效问题 +- feat: 增加 css 属性 `min-width` `max-width` +## 1.8.1(2021-08-02) +- fix: 修复无法加载本地图片 +## 1.8.0(2021-08-02) +- chore 文档更新 +- 使用旧版的同学不要升级! +## 1.8.0-beta(2021-07-30) +- ## 全新布局方式 不兼容旧版! +- chore: 布局方式变更 +- tips: 微信canvas 2d 不支持真机调试 +## 1.6.6(2021-07-09) +- chore: 统一命名规范,无须主动引入组件 +## 1.6.5(2021-06-08) +- chore: 去掉console +## 1.6.4(2021-06-07) +- fix: 修复 数字 为纯字符串时不转换的BUG +## 1.6.3(2021-06-06) +- fix: 修复 PC 端放大的BUG +## 1.6.2(2021-05-31) +- fix: 修复 报`adaptor is not a function`错误 +- fix: 修复 text 多行高度 +- fix: 优化 默认文字的基准线 +- feat: `@progress`事件,监听绘制进度 +## 1.6.1(2021-02-28) +- 删除多余节点 +## 1.6.0(2021-02-26) +- 调整为uni_modules目录规范 +- 修复:transform的rotate不能为负数问题 +- 新增:`pathType` 指定生成图片返回的路径类型,可选值有 `base64`、`url` diff --git a/uni_modules/lime-painter/components/common/relation.js b/uni_modules/lime-painter/components/common/relation.js new file mode 100644 index 0000000..c68661c --- /dev/null +++ b/uni_modules/lime-painter/components/common/relation.js @@ -0,0 +1,147 @@ +const styles = (v ='') => v.split(';').filter(v => v && !/^[\n\s]+$/.test(v)).map(v => { + const key = v.slice(0, v.indexOf(':')) + const value = v.slice(v.indexOf(':')+1) + return { + [key + .replace(/-([a-z])/g, function() { return arguments[1].toUpperCase()}) + .replace(/\s+/g, '') + ]: value.replace(/^\s+/, '').replace(/\s+$/, '') || '' + } + }) +export function parent(parent) { + return { + provide() { + return { + [parent]: this + } + }, + data() { + return { + el: { + css: {}, + views: [] + }, + } + }, + watch: { + css: { + handler(v) { + if(this.canvasId) { + this.el.css = (typeof v == 'object' ? v : v && Object.assign(...styles(v))) || {} + this.canvasWidth = this.el.css && this.el.css.width || this.canvasWidth + this.canvasHeight = this.el.css && this.el.css.height || this.canvasHeight + } + }, + immediate: true + } + } + } +} +export function children(parent, options = {}) { + const indexKey = options.indexKey || 'index' + return { + inject: { + [parent]: { + default: null + } + }, + watch: { + el: { + handler(v, o) { + if(JSON.stringify(v) != JSON.stringify(o)) + this.bindRelation() + }, + deep: true, + immediate: true + }, + src: { + handler(v, o) { + if(v != o) + this.bindRelation() + }, + immediate: true + }, + text: { + handler(v, o) { + if(v != o) this.bindRelation() + }, + immediate: true + }, + css: { + handler(v, o) { + if(v != o) + this.el.css = (typeof v == 'object' ? v : v && Object.assign(...styles(v))) || {} + }, + immediate: true + }, + replace: { + handler(v, o) { + if(JSON.stringify(v) != JSON.stringify(o)) + this.bindRelation() + }, + deep: true, + immediate: true + } + }, + created() { + if(!this._uid) { + this._uid = this._.uid + } + Object.defineProperty(this, 'parent', { + get: () => this[parent] || [], + }) + Object.defineProperty(this, 'index', { + get: () => { + this.bindRelation(); + const {parent: {el: {views=[]}={}}={}} = this + return views.indexOf(this.el) + }, + }); + this.el.type = this.type + + this.bindRelation() + }, + // #ifdef VUE3 + beforeUnmount() { + this.removeEl() + }, + // #endif + // #ifdef VUE2 + beforeDestroy() { + this.removeEl() + }, + // #endif + methods: { + removeEl() { + if (this.parent) { + this.parent.el.views = this.parent.el.views.filter( + (item) => item._uid !== this._uid + ); + } + }, + bindRelation() { + if(!this.el._uid) { + this.el._uid = this._uid + } + if(['text','qrcode'].includes(this.type)) { + this.el.text = this.$slots && this.$slots.default && this.$slots.default[0].text || `${this.text || ''}`.replace(/\\n/g, '\n') + } + if(this.type == 'image') { + this.el.src = this.src + } + if (!this.parent) { + return; + } + let views = this.parent.el.views || []; + if(views.indexOf(this.el) !== -1) { + this.parent.el.views = views.map(v => v._uid == this._uid ? this.el : v) + } else { + this.parent.el.views = [...views, this.el]; + } + } + }, + mounted() { + // this.bindRelation() + }, + } +} \ No newline at end of file diff --git a/uni_modules/lime-painter/components/l-painter-image/l-painter-image.vue b/uni_modules/lime-painter/components/l-painter-image/l-painter-image.vue new file mode 100644 index 0000000..f1ce13e --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter-image/l-painter-image.vue @@ -0,0 +1,27 @@ + + + + + + + diff --git a/uni_modules/lime-painter/components/l-painter-qrcode/l-painter-qrcode.vue b/uni_modules/lime-painter/components/l-painter-qrcode/l-painter-qrcode.vue new file mode 100644 index 0000000..4620d3f --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter-qrcode/l-painter-qrcode.vue @@ -0,0 +1,26 @@ + + + + + + diff --git a/uni_modules/lime-painter/components/l-painter-text/l-painter-text.vue b/uni_modules/lime-painter/components/l-painter-text/l-painter-text.vue new file mode 100644 index 0000000..1af0484 --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter-text/l-painter-text.vue @@ -0,0 +1,28 @@ + + + + + + + diff --git a/uni_modules/lime-painter/components/l-painter-view/l-painter-view.vue b/uni_modules/lime-painter/components/l-painter-view/l-painter-view.vue new file mode 100644 index 0000000..4451e23 --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter-view/l-painter-view.vue @@ -0,0 +1,29 @@ + + + + + + + diff --git a/uni_modules/lime-painter/components/l-painter/l-painter.vue b/uni_modules/lime-painter/components/l-painter/l-painter.vue new file mode 100644 index 0000000..9406fd0 --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter/l-painter.vue @@ -0,0 +1,409 @@ + + + + + + + + diff --git a/uni_modules/lime-painter/components/l-painter/nvue.js b/uni_modules/lime-painter/components/l-painter/nvue.js new file mode 100644 index 0000000..9ce594d --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter/nvue.js @@ -0,0 +1,218 @@ +// #ifdef APP-NVUE +import { sleep, getImageInfo, isBase64, useNvue, networkReg } from './utils'; +const dom = weex.requireModule('dom') +import {version } from '../../package.json' + +export default { + data() { + return { + tempFilePath: [], + isInitFile: false, + osName: uni.getSystemInfoSync().osName + } + }, + created() { + // if (this.hybrid) return + // useNvue('_doc/uni_modules/lime-painter/', version, this.timeout).then(res => { + // this.isInitFile = true + // }) + }, + methods: { + getParentWeith() { + return new Promise(resolve => { + dom.getComponentRect(this.$refs.limepainter, (res) => { + this.parentWidth = Math.ceil(res.size.width) + this.canvasWidth = this.canvasWidth || this.parentWidth ||300 + this.canvasHeight = res.size.height || this.canvasHeight||150 + resolve(res.size) + }) + }) + }, + onPageFinish() { + this.webview = this.$refs.webview + this.webview.evalJS(`init(${this.dpr})`) + }, + onMessage(e) { + const res = e.detail.data[0] || null; + if (res.event) { + if (res.event == 'inited') { + this.inited = true + } + if(res.event == 'fail'){ + this.$emit('fail', res) + } + if (res.event == 'layoutChange') { + const data = typeof res.data == 'string' ? JSON.parse(res.data) : res.data + this.canvasWidth = Math.ceil(data.width); + this.canvasHeight = Math.ceil(data.height); + } + if (res.event == 'progressChange') { + this.progress = res.data * 1 + } + if (res.event == 'file') { + this.tempFilePath.push(res.data) + if (this.tempFilePath.length > 7) { + this.tempFilePath.shift() + } + return + } + if (res.event == 'success') { + if (res.data) { + this.tempFilePath.push(res.data) + if (this.tempFilePath.length > 8) { + this.tempFilePath.shift() + } + if (this.isCanvasToTempFilePath) { + this.setFilePath(this.tempFilePath.join(''), {isEmit:true}) + } + } else { + this.$emit('fail', 'canvas no data') + } + return + } + this.$emit(res.event, JSON.parse(res.data)); + } else if (res.file) { + this.file = res.data; + } else{ + console.info(res[0]) + } + }, + getWebViewInited() { + if (this.inited) return Promise.resolve(this.inited); + return new Promise((resolve) => { + this.$watch( + 'inited', + async val => { + if (val) { + resolve(val) + } + }, { + immediate: true + } + ); + }) + }, + getTempFilePath() { + if (this.tempFilePath.length == 8) return Promise.resolve(this.tempFilePath) + return new Promise((resolve) => { + this.$watch( + 'tempFilePath', + async val => { + if (val.length == 8) { + resolve(val.join('')) + } + } + ); + }) + }, + getWebViewDone() { + if (this.progress == 1) return Promise.resolve(this.progress); + return new Promise((resolve) => { + this.$watch( + 'progress', + async val => { + if (val == 1) { + this.$emit('done') + this.done = true + resolve(val) + } + }, { + immediate: true + } + ); + }) + }, + async render(args) { + try { + await this.getSize(args) + const {width} = args.css || args + if(!width && this.parentWidth) { + Object.assign(args, {width: this.parentWidth}) + } + const newNode = await this.calcImage(args); + await this.getWebViewInited() + this.webview.evalJS(`source(${JSON.stringify(newNode)})`) + await this.getWebViewDone() + await sleep(this.afterDelay) + if (this.isCanvasToTempFilePath) { + const params = { + fileType: this.fileType, + quality: this.quality + } + this.webview.evalJS(`save(${JSON.stringify(params)})`) + } + return Promise.resolve() + } catch (e) { + this.$emit('fail', e) + } + }, + getfile(e){ + let url = plus.io.convertLocalFileSystemURL( e ) + return new Promise((resolve,reject)=>{ + plus.io.resolveLocalFileSystemURL(url, entry => { + var reader = null; + entry.file( file => { + reader = new plus.io.FileReader(); + reader.onloadend = ( read )=> { + resolve(read.target.result) + }; + reader.readAsDataURL( file ); + }, function ( error ) { + alert( error.message ); + } ); + },err=>{ + resolve(e) + }) + }) + }, + async calcImage(args) { + let node = JSON.parse(JSON.stringify(args)) + const urlReg = /url\((.+)\)/ + const {backgroundImage} = node.css||{} + const isBG = backgroundImage && urlReg.exec(backgroundImage)[1] + const url = node.url || node.src || isBG + if(['text', 'qrcode'].includes(node.type)) { + return node + } + if ((node.type === "image" || isBG) && url && !isBase64(url) && (this.osName == 'ios' ? true : !networkReg.test(url))) { + let {path} = await getImageInfo(url) + if(this.osName == 'ios') { + path = await this.getfile(path) + } + if (isBG) { + node.css.backgroundImage = `url(${path})` + } else { + node.src = path + } + } else if (node.views && node.views.length) { + for (let i = 0; i < node.views.length; i++) { + node.views[i] = await this.calcImage(node.views[i]) + } + } + return node + }, + async canvasToTempFilePath(args = {}) { + if (!this.inited) { + return this.$emit('fail', 'no init') + } + this.tempFilePath = [] + if (args.fileType == 'jpg') { + args.fileType = 'jpeg' + } + this.webview.evalJS(`save(${JSON.stringify(args)})`) + try { + let tempFilePath = await this.getTempFilePath() + tempFilePath = await this.setFilePath(tempFilePath) + args.success({ + errMsg: "canvasToTempFilePath:ok", + tempFilePath + }) + } catch (e) { + args.fail({ + error: e + }) + } + } + } +} +// #endif \ No newline at end of file diff --git a/uni_modules/lime-painter/components/l-painter/painter.js b/uni_modules/lime-painter/components/l-painter/painter.js new file mode 100644 index 0000000..b0813bc --- /dev/null +++ b/uni_modules/lime-painter/components/l-painter/painter.js @@ -0,0 +1 @@ +var t=function(){return t=Object.assign||function(t){for(var e,i=1,n=arguments.length;i+ + + + + + + ++ + ++ 0&&r[r.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1] =360&&(s-=360);s<0&&(s+=360);if(0===(s=Math.round(s)))return{x0:Math.round(e/2)+n,y0:i+r,x1:Math.round(e/2)+n,y1:r};if(180===s)return{x0:Math.round(e/2)+n,y0:r,x1:Math.round(e/2)+n,y1:i+r};if(90===s)return{x0:n,y0:Math.round(i/2)+r,x1:e+n,y1:Math.round(i/2)+r};if(270===s)return{x0:e+n,y0:Math.round(i/2)+r,x1:n,y1:Math.round(i/2)+r};var a=Math.round(180*Math.asin(e/Math.sqrt(Math.pow(e,2)+Math.pow(i,2)))/Math.PI);if(s===a)return{x0:n,y0:i+r,x1:e+n,y1:r};if(s===180-a)return{x0:n,y0:r,x1:e+n,y1:i+r};if(s===180+a)return{x0:e+n,y0:r,x1:n,y1:i+r};if(s===360-a)return{x0:e+n,y0:i+r,x1:n,y1:r};var h=0,d=0,c=0,l=0;if(s180-a&&s<180||s>180&&s<180+a||s>360-a){var f=s*Math.PI/180,u=s360-a?i/2:-i/2,p=Math.tan(f)*u,g=s180-a&&s<180?e/2-p:-e/2-p;h=-(c=p+(v=Math.pow(Math.sin(f),2)*g)),d=-(l=u+v/Math.tan(f))}if(s>a&&s<90||s>90&&s<90+a||s>180+a&&s<270||s>270&&s<360-a){var v;f=(90-s)*Math.PI/180,p=s>a&&s<90||s>90&&s<90+a?e/2:-e/2,u=Math.tan(f)*p,g=s>a&&s<90||s>270&&s<360-a?i/2-u:-i/2-u;h=-(c=p+(v=Math.pow(Math.sin(f),2)*g)/Math.tan(f)),d=-(l=u+v)}return h=Math.round(h+e/2)+n,d=Math.round(i/2-d)+r,c=Math.round(c+e/2)+n,l=Math.round(i/2-l)+r,{x0:h,y0:d,x1:c,y1:l}}(r,t,e,i,n),a=s.x0,h=s.y0,d=s.x1,c=s.y1,l=o.createLinearGradient(a,h,d,c),f=r.match(/linear-gradient\((.+)\)/)[1],u=F(f.substring(f.indexOf(",")+1)),p=0;p t.length)&&(e=t.length);for(var i=0,n=new Array(e);i =t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function Y(t){return"number"==typeof t}function $(t){return"auto"===t||null===t}function D(t){return/%$/.test(t)}var X,_=0,N=function(){function t(){j(this,"elements",[]),j(this,"afterElements",[]),j(this,"beforeElements",[]),j(this,"ids",[]),j(this,"width",0),j(this,"height",0),j(this,"top",0),j(this,"left",0),j(this,"pre",null),j(this,"offsetX",0),j(this,"offsetY",0),_++,this.id=_}var e=t.prototype;return e.fixedBind=function(t,e){void 0===e&&(e=0),this.container=e?t.parent:t.root,this.container.fixedLine=this,this.fixedAdd(t)},e.fixedAdd=function(t){this.elements.push(t);var e=t.computedStyle.zIndex;(void 0===e?0:e)>=0?this.afterElements.push(t):this.beforeElements.push(t),this.refreshLayout()},e.bind=function(t){this.container=t.parent,this.container.line=null,this.container.lines?(this.container.lines.push(this),this.pre=this.getPreLine(),this.top=this.pre.top+this.pre.height,this.left=this.container.contentSize.left):(this.top=this.container.contentSize.top,this.left=this.container.contentSize.left,this.container.lines=[this]),this.isInline=t.isInline(),this.container.line=this,this.outerWidth=t.parent&&t.parent.contentSize.width?t.parent.contentSize.width:1/0,this.add(t)},e.getPreLine=function(){return this.container.lines[this.container.lines.length-2]},e.canIEnter=function(t){return!((100*t.offsetSize.width+100*this.width)/100>this.outerWidth)||(this.closeLine(),!1)},e.closeLine=function(){delete this.container.line},e.add=function(t){this.ids.push(t.id),this.elements.push(t),this.refreshWidthHeight(t)},e.refreshWidthHeight=function(t){t.offsetSize.height>this.height&&(this.height=t.offsetSize.height),this.width+=t.offsetSize.width||0,(this.container.lineMaxWidth||0) this[this.key.height]&&(this[this.key.height]=t.offsetSize[this.key.height]),this[this.key.width]+=t.offsetSize[this.key.width],(this.container.lineMaxWidth||0) 1?0:"flex-end"===t.style.alignSelf?this.container.contentSize[this.key.contentHeight]-t.contentSize[this.key.height]:"center"===t.style.alignSelf?(this.container.contentSize[this.key.contentHeight]-t.contentSize[this.key.height])/2:0},n}(N),q=y,J=v,Q=g,Z=b,K=x,et=m,it=S,nt=z,rt=B,ot=0,st={left:null,top:null,width:null,height:null},at=function(){function t(t,e,i,n){var r=this;j(this,"id",ot++),j(this,"style",{left:null,top:null,width:null,height:null}),j(this,"computedStyle",{}),j(this,"originStyle",{}),j(this,"children",{}),j(this,"layoutBox",C({},st)),j(this,"contentSize",C({},st)),j(this,"clientSize",C({},st)),j(this,"borderSize",C({},st)),j(this,"offsetSize",C({},st)),this.ctx=n,this.root=i,e&&(this.parent=e),this.name=t.name||t.type,this.attributes=this.getAttributes(t);var o=this.getComputedStyle(t,null==e?void 0:e.computedStyle);this.isAbsolute=o.position==nt,this.isFixed=o.position==rt,this.originStyle=o,Object.keys(o).forEach((function(t){Object.defineProperty(r.style,t,{configurable:!0,enumerable:!0,get:function(){return o[t]},set:function(e){o[t]=e}})}));var s={contentSize:C({},this.contentSize),clientSize:C({},this.clientSize),borderSize:C({},this.borderSize),offsetSize:C({},this.offsetSize)};Object.keys(s).forEach((function(t){Object.keys(r[t]).forEach((function(e){Object.defineProperty(r[t],e,{configurable:!0,enumerable:!0,get:function(){return s[t][e]},set:function(i){s[t][e]=i}})}))})),this.computedStyle=this.style}var e=t.prototype;return e.add=function(t){t.parent=this,this.children[t.id]=t},e.getChildren=function(){var t=this;return Object.keys(this.children).map((function(e){return t.children[e]}))},e.getLineRect=function(t,e){var i={width:0,height:0},n=e?e.lines:this.parent&&this.parent.lines;return n&&n.find((function(e){return e.ids.includes(t)}))||i},e.getComputedStyle=function(t,e){var i=["color","fontSize","lineHeight","verticalAlign","fontWeight","textAlign"],n=t.css,r=void 0===n?{}:n,o=t.type,s=void 0===o?Q:o,a=C({},M);if([J,q,Z].includes(s)&&!r.display&&(a.display=et),e)for(var h=0;h =0&&l<0,Y=d>=0&&u<0;return i==s[0]&&(this[i].left=t.left+a+v+C+(U?2*-l:0),this[i].top=t.top+d+b+P+(Y?2*-u:0),this[i].width=t.width+(this[i].widthAdd?0:E),this[i].height=t.height+(this[i].heightAdd?0:H),this[i].widthAdd=E,this[i].heightAdd=H),i==s[1]&&(this[i].left=t.left+a+C+(U<0?-l:0),this[i].top=t.top+d+P+(Y?-u:0),this[i].width=t.width+v+m,this[i].height=t.height+b+S),i==s[2]&&(this[i].left=t.left+a+C/2+(U<0?-l:0),this[i].top=t.top+d+P/2+(Y?-u:0),this[i].width=t.width+v+m+C/2+A/2,this[i].height=t.height+b+S+O/2+P/2),i==s[3]&&(this[i].left=t.left+(U<0?-l:0),this[i].top=t.top+(Y?-u:0),this[i].width=t.width+v+m+C+A+a+l,this[i].height=t.height+b+S+O+P+u+d),this[i]},e.layoutBoxUpdate=function(t,e,i,n){var r=this;if(void 0===i&&(i=-1),"border-box"==e.boxSizing){var o=e||{},a=o.border,h=(a=void 0===a?{}:a).borderWidth,d=void 0===h?0:h,c=o.borderTop,l=(c=void 0===c?{}:c).borderTopWidth,f=void 0===l?d:l,u=o.borderBottom,p=(u=void 0===u?{}:u).borderBottomWidth,g=void 0===p?d:p,v=o.borderRight,y=(v=void 0===v?{}:v).borderRightWidth,b=void 0===y?d:y,x=o.borderLeft,m=(x=void 0===x?{}:x).borderLeftWidth,w=void 0===m?d:m,S=o.padding,z=(S=void 0===S?{}:S).paddingTop,B=void 0===z?0:z,M=S.paddingRight,I=void 0===M?0:M,k=S.paddingBottom,P=void 0===k?0:k,W=S.paddingLeft,R=void 0===W?0:W;i||(t.width-=R+I+b+w),1!==i||n||(t.height-=B+P+f+g)}this.layoutBox&&(s.forEach((function(i){return r.layoutBox[i]=r.getOffsetSize(t,e,i)})),this.layoutBox=Object.assign({},this.layoutBox,this.layoutBox.borderSize))},e.getBoxPosition2=function(){var t=this.computedStyle,e=this.fixedLine,i=this.lines,n=t.left,r=void 0===n?0:n,o=t.top,s=void 0===o?0:o,a=t.padding||{},h=a.paddingBottom,d=void 0===h?0:h,c=a.paddingRight,l=void 0===c?0:c,f=C({},this.contentSize,{left:r,top:s}),u=this.contentSize.top-this.offsetSize.top,p=this.contentSize.left-this.offsetSize.left;if(this.root.fixedLine&&!this.root.isDone){this.root.isDone=!0;for(var g,v=U(this.root.fixedLine.elements);!(g=v()).done;){var y=g.value;y.setPosition(y,this.root.offsetSize),y.getBoxPosition2()}}if(e)for(var b,x=U(e.elements);!(b=x()).done;){var m=b.value;m.setPosition(m,f),m.style.left+=r+p+l,m.style.top+=s+u+d,m.getBoxPosition2()}if(i)for(var w,S=U(i);!(w=S()).done;){w.value.layout(f.top+u,f.left+p)}return this.layoutBoxUpdate(f,t),this.layoutBox},e.getBoxState=function(t,e){return this.isBlock(t)||this.isBlock(e)},e.isBlock=function(t){return void 0===t&&(t=this),t&&t.style.display==K},e.isFlex=function(t){return void 0===t&&(t=this),t&&t.style.display==it},e.isInFlow=function(){return!(this.isAbsolute||this.isFixed)},e.inFlexBox=function(t){return void 0===t&&(t=this),!!t.isInFlow()&&(!!t.parent&&(!(!t.parent||t.parent.style.display!==it)||void 0))},e.isInline=function(t){return void 0===t&&(t=this),t&&t.style.display==et},e.contrastSize=function(t,e,i){var n=t;return i&&(n=Math.min(n,i)),e&&(n=Math.max(n,e)),n},e.measureText=function(t,e){var i=this.ctx.measureText(t),n=i.width,r=i.actualBoundingBoxAscent,o=i.actualBoundingBoxDescent;return{ascent:r,descent:o,width:n,fontHeight:r+o||.7*e+1}},e.getBoxWidthHeight=function(){var t,e=this,i=this.name,n=this.computedStyle,r=this.attributes,o=this.parent,s=void 0===o?{}:o,a=this.ctx,h=this.getChildren(),d=n.left,c=void 0===d?0:d,l=n.top,f=void 0===l?0:l,u=n.bottom,p=n.right,g=n.width,v=void 0===g?0:g,y=n.minWidth,b=n.maxWidth,x=n.minHeight,m=n.maxHeight,w=n.height,S=void 0===w?0:w,z=n.fontSize,B=void 0===z?14:z,M=n.fontWeight,I=n.fontFamily,k=n.fontStyle,P=n.position,W=n.lineClamp,R=n.lineHeight,L=n.padding,T=void 0===L?{}:L,A=n.margin,F=void 0===A?{}:A,j=n.border,C=(j=void 0===j?{}:j).borderWidth,E=void 0===C?0:C,H=n.borderRight,U=(H=void 0===H?{}:H).borderRightWidth,Y=void 0===U?E:U,$=n.borderLeft,X=($=void 0===$?{}:$).borderLeftWidth,_=void 0===X?E:X,V=s.contentSize&&s.contentSize.width,Z=s.contentSize&&s.contentSize.height;if(D(v)&&V&&(v=O(v,V)),D(v)&&!V&&(v=null),D(S)&&Z&&(S=O(S,Z)),D(S)&&!Z&&(S=null),D(y)&&V&&(y=O(y,V)),D(b)&&V&&(b=O(b,V)),D(x)&&Z&&(x=O(x,Z)),D(m)&&Z&&(m=O(m,Z)),n.padding&&null!=(t=s.contentSize)&&t.width)for(var K in n.padding)Object.hasOwnProperty.call(n.padding,K)&&(n.padding[K]=O(n.padding[K],V));var tt=T.paddingRight,et=void 0===tt?0:tt,it=T.paddingLeft,rt=void 0===it?0:it;if(n.margin&&[n.margin.marginLeft,n.margin.marginRight].includes("auto"))if(v){var ot=V&&V-v-et-rt-_-Y||0;n.margin.marginLeft==n.margin.marginRight?n.margin.marginLeft=n.margin.marginRight=ot/2:"auto"==n.margin.marginLeft?n.margin.marginLeft=ot:n.margin.marginRight=ot}else n.margin.marginLeft=n.margin.marginRight=0;var st=F.marginRight,at=void 0===st?0:st,ht=F.marginLeft,dt={width:v,height:S,left:0,top:0},ct=rt+et+_+Y+(void 0===ht?0:ht)+at;if(i==J&&!this.attributes.widths){var lt=r.text||"";a.save(),a.setFonts({fontFamily:I,fontSize:B,fontWeight:M,fontStyle:k});var ft=new Map;lt.split("\n").map((function(t){var i=t.split("").map((function(t){var i=ft.get(t);if(i)return i;var n=e.measureText(t,B).width;return ft.set(t,n),n})),n=e.measureText(t,B),r=n.fontHeight,o=n.ascent,s=n.descent;e.attributes.fontHeight=r,e.attributes.ascent=o,e.attributes.descent=s,e.attributes.widths||(e.attributes.widths=[]),e.attributes.widths.push({widths:i,total:i.reduce((function(t,e){return t+e}),0)})})),a.restore()}if(i==q&&null==v){var ut=r.width,pt=r.height;dt.width=this.contrastSize(Math.round(ut*S/pt)||0,y,b),this.layoutBoxUpdate(dt,n,0)}if(i==J&&null==v){var gt=this.attributes.widths,vt=Math.max.apply(Math,gt.map((function(t){return t.total})));if(s&&V>0&&(vt>V||this.isBlock(this))&&!this.isAbsolute&&!this.isFixed)vt=V-ct;dt.width=this.contrastSize(vt,y,b),this.layoutBoxUpdate(dt,n,0)}if(i==J&&!this.attributes.lines){var yt=this.attributes.widths.length;this.attributes.widths.forEach((function(t){return t.widths.reduce((function(t,e,i){return t+e>dt.width?(yt++,e):t+e}),0)})),yt=W&&yt>W?W:yt,this.attributes.lines=yt}if(i==q&&null==S){var bt=r.width,xt=r.height;dt.height=this.contrastSize(O(dt.width*xt/bt)||0,x,m),this.layoutBoxUpdate(dt,n,1)}i==J&&null==S&&(R=O(R,B),dt.height=this.contrastSize(O(this.attributes.lines*R),x,m),this.layoutBoxUpdate(dt,n,1,!0)),s&&s.children&&V&&([Q,J].includes(i)&&this.isFlex()||i==Q&&this.isBlock(this)&&!this.isInFlow())&&(dt.width=this.contrastSize(V-ct,y,b),this.layoutBoxUpdate(dt,n)),v&&!D(v)&&(dt.width=this.contrastSize(v,y,b),this.layoutBoxUpdate(dt,n,0)),S&&!D(S)&&(dt.height=this.contrastSize(dt.height,x,m),this.layoutBoxUpdate(dt,n,1));var mt=0;if(h.length){var wt=null;h.forEach((function(t,i){t.getBoxWidthHeight();var r=h[i+1];if(r&&r.isInFlow()&&(t.next=r),t.isInFlow()&&!t.inFlexBox()){var o=e.getBoxState(wt,t);e.line&&e.line.canIEnter(t)&&!o?e.line.add(t):(new N).bind(t),wt=t}else t.inFlexBox()?e.line&&(e.line.canIEnter(t)||"nowrap"==n.flexWrap)?e.line.add(t):(new G).bind(t):t.isFixed?e.root.fixedLine?e.root.fixedLine.fixedAdd(t):(new N).fixedBind(t):e.fixedLine?e.fixedLine.fixedAdd(t):(new N).fixedBind(t,1)})),this.lines&&(mt=this.lines.reduce((function(t,e){return t+e.height}),0))}var St=0,zt=0;if(!v&&(this.isAbsolute||this.isFixed)&&V){var Bt=P==nt?V:this.root.width,Mt=Bt-(D(c)?O(c,Bt):c)-(D(p)?O(p,Bt):p);St=n.left?Mt:this.lineMaxWidth}if(!S&&(null!=f?f:this.isAbsolute||this.isFixed&&Z)){var It=P==nt?Z:this.root.height,kt=It-(D(f)?O(f,It):f)-(D(u)?O(u,It):u);zt=n.top?kt:0}if(v&&!D(v)||dt.width||(dt.width=St||this.contrastSize((this.isBlock(this)&&!this.isInFlow()?V||s.lineMaxWidth:this.lineMaxWidth)||this.lineMaxWidth,y,b),this.layoutBoxUpdate(dt,n,0)),S||!mt&&!zt||(dt.height=zt||this.contrastSize(mt,x,m),this.layoutBoxUpdate(dt,n)),n.borderRadius&&this.borderSize&&this.borderSize.width)for(var K in n.borderRadius)Object.hasOwnProperty.call(n.borderRadius,K)&&(n.borderRadius[K]=O(n.borderRadius[K],this.borderSize.width));return this.layoutBox},e.layout=function(){return this.getBoxWidthHeight(),this.root.offsetSize=this.offsetSize,this.getBoxPosition2(),this.offsetSize},t}(),ht=function(){var t,e,i,n,r,o,s=[0,11,15,19,23,27,31,16,18,20,22,24,26,28,20,22,24,24,26,28,28,22,24,24,26,26,28,28,24,24,26,26,26,28,28,24,26,26,26,28,28],a=[3220,1468,2713,1235,3062,1890,2119,1549,2344,2936,1117,2583,1330,2470,1667,2249,2028,3780,481,4011,142,3098,831,3445,592,2517,1776,2234,1951,2827,1070,2660,1345,3177],h=[30660,29427,32170,30877,26159,25368,27713,26998,21522,20773,24188,23371,17913,16590,20375,19104,13663,12392,16177,14854,9396,8579,11994,11245,5769,5054,7399,6608,1890,597,3340,2107],d=[1,0,19,7,1,0,16,10,1,0,13,13,1,0,9,17,1,0,34,10,1,0,28,16,1,0,22,22,1,0,16,28,1,0,55,15,1,0,44,26,2,0,17,18,2,0,13,22,1,0,80,20,2,0,32,18,2,0,24,26,4,0,9,16,1,0,108,26,2,0,43,24,2,2,15,18,2,2,11,22,2,0,68,18,4,0,27,16,4,0,19,24,4,0,15,28,2,0,78,20,4,0,31,18,2,4,14,18,4,1,13,26,2,0,97,24,2,2,38,22,4,2,18,22,4,2,14,26,2,0,116,30,3,2,36,22,4,4,16,20,4,4,12,24,2,2,68,18,4,1,43,26,6,2,19,24,6,2,15,28,4,0,81,20,1,4,50,30,4,4,22,28,3,8,12,24,2,2,92,24,6,2,36,22,4,6,20,26,7,4,14,28,4,0,107,26,8,1,37,22,8,4,20,24,12,4,11,22,3,1,115,30,4,5,40,24,11,5,16,20,11,5,12,24,5,1,87,22,5,5,41,24,5,7,24,30,11,7,12,24,5,1,98,24,7,3,45,28,15,2,19,24,3,13,15,30,1,5,107,28,10,1,46,28,1,15,22,28,2,17,14,28,5,1,120,30,9,4,43,26,17,1,22,28,2,19,14,28,3,4,113,28,3,11,44,26,17,4,21,26,9,16,13,26,3,5,107,28,3,13,41,26,15,5,24,30,15,10,15,28,4,4,116,28,17,0,42,26,17,6,22,28,19,6,16,30,2,7,111,28,17,0,46,28,7,16,24,30,34,0,13,24,4,5,121,30,4,14,47,28,11,14,24,30,16,14,15,30,6,4,117,30,6,14,45,28,11,16,24,30,30,2,16,30,8,4,106,26,8,13,47,28,7,22,24,30,22,13,15,30,10,2,114,28,19,4,46,28,28,6,22,28,33,4,16,30,8,4,122,30,22,3,45,28,8,26,23,30,12,28,15,30,3,10,117,30,3,23,45,28,4,31,24,30,11,31,15,30,7,7,116,30,21,7,45,28,1,37,23,30,19,26,15,30,5,10,115,30,19,10,47,28,15,25,24,30,23,25,15,30,13,3,115,30,2,29,46,28,42,1,24,30,23,28,15,30,17,0,115,30,10,23,46,28,10,35,24,30,19,35,15,30,17,1,115,30,14,21,46,28,29,19,24,30,11,46,15,30,13,6,115,30,14,23,46,28,44,7,24,30,59,1,16,30,12,7,121,30,12,26,47,28,39,14,24,30,22,41,15,30,6,14,121,30,6,34,47,28,46,10,24,30,2,64,15,30,17,4,122,30,29,14,46,28,49,10,24,30,24,46,15,30,4,18,122,30,13,32,46,28,48,14,24,30,42,32,15,30,20,4,117,30,40,7,47,28,43,22,24,30,10,67,15,30,19,6,118,30,18,31,47,28,34,34,24,30,20,61,15,30],c=[255,0,1,25,2,50,26,198,3,223,51,238,27,104,199,75,4,100,224,14,52,141,239,129,28,193,105,248,200,8,76,113,5,138,101,47,225,36,15,33,53,147,142,218,240,18,130,69,29,181,194,125,106,39,249,185,201,154,9,120,77,228,114,166,6,191,139,98,102,221,48,253,226,152,37,179,16,145,34,136,54,208,148,206,143,150,219,189,241,210,19,92,131,56,70,64,30,66,182,163,195,72,126,110,107,58,40,84,250,133,186,61,202,94,155,159,10,21,121,43,78,212,229,172,115,243,167,87,7,112,192,247,140,128,99,13,103,74,222,237,49,197,254,24,227,165,153,119,38,184,180,124,17,68,146,217,35,32,137,46,55,63,209,91,149,188,207,205,144,135,151,178,220,252,190,97,242,86,211,171,20,42,93,158,132,60,57,83,71,109,65,162,31,45,67,216,183,123,164,118,196,23,73,236,127,12,111,246,108,161,59,82,41,157,85,170,251,96,134,177,187,204,62,90,203,89,95,176,156,169,160,81,11,245,22,235,122,117,44,215,79,174,213,233,230,231,173,232,116,214,244,234,168,80,88,175],l=[1,2,4,8,16,32,64,128,29,58,116,232,205,135,19,38,76,152,45,90,180,117,234,201,143,3,6,12,24,48,96,192,157,39,78,156,37,74,148,53,106,212,181,119,238,193,159,35,70,140,5,10,20,40,80,160,93,186,105,210,185,111,222,161,95,190,97,194,153,47,94,188,101,202,137,15,30,60,120,240,253,231,211,187,107,214,177,127,254,225,223,163,91,182,113,226,217,175,67,134,17,34,68,136,13,26,52,104,208,189,103,206,129,31,62,124,248,237,199,147,59,118,236,197,151,51,102,204,133,23,46,92,184,109,218,169,79,158,33,66,132,21,42,84,168,77,154,41,82,164,85,170,73,146,57,114,228,213,183,115,230,209,191,99,198,145,63,126,252,229,215,179,123,246,241,255,227,219,171,75,150,49,98,196,149,55,110,220,165,87,174,65,130,25,50,100,200,141,7,14,28,56,112,224,221,167,83,166,81,162,89,178,121,242,249,239,195,155,43,86,172,69,138,9,18,36,72,144,61,122,244,245,247,243,251,235,203,139,11,22,44,88,176,125,250,233,207,131,27,54,108,216,173,71,142,0],f=[],u=[],p=[],g=[],v=[],y=2;function b(t,e){var i;t>e&&(i=t,t=e,e=i),i=e,i*=e,i+=e,i>>=1,g[i+=t]=1}function x(t,i){var n;for(p[t+e*i]=1,n=-2;n<2;n++)p[t+n+e*(i-2)]=1,p[t-2+e*(i+n+1)]=1,p[t+2+e*(i+n)]=1,p[t+n+1+e*(i+2)]=1;for(n=0;n<2;n++)b(t-1,i+n),b(t+1,i-n),b(t-n,i-1),b(t+n,i+1)}function m(t){for(;t>=255;)t=((t-=255)>>8)+(255&t);return t}var w=[];function S(t,e,i,n){var r,o,s;for(r=0;r e&&(i=t,t=e,e=i),i=e,i+=e*e,i>>=1,g[i+=t]}function B(t){var i,n,r,o;switch(t){case 0:for(n=0;n >1&1,i=0;i =5&&(i+=3+v[e]-5);for(e=3;e t||3*v[e-3]>=4*v[e]||3*v[e+3]>=4*v[e])&&(i+=40);return i}function I(){var t,i,n,r,o,s=0,a=0;for(i=0;i e*e;)h-=e*e,d++;for(s+=10*d,t=0;t 1)for(W=s[t],k=e-7;;){for(M=e-7;M>W-3&&(x(M,k),!(M 6)for(W=a[t-7],P=17,M=0;M<6;M++)for(k=0;k<3;k++,P--)1&(P>11?t>>P-12:W>>P)?(p[5-M+e*(2-k+e-11)]=1,p[2-k+e-11+e*(5-M)]=1):(b(5-M,2-k+e-11),b(2-k+e-11,5-M));for(k=0;k =(M=r*(i+n)+n)-2&&(R=M-2,t>9&&R--),O=R,t>9){for(f[O+2]=0,f[O+3]=0;O--;)W=f[O],f[O+3]|=255&W<<4,f[O+2]=W>>4;f[2]|=255&R<<4,f[1]=R>>4,f[0]=64|R>>12}else{for(f[O+1]=0,f[O+2]=0;O--;)W=f[O],f[O+2]|=255&W<<4,f[O+1]=W>>4;f[1]|=255&R<<4,f[0]=64|R>>4}for(O=R+3-(t<10);O 0;L--)w[L]=w[L]?w[L-1]^l[m(c[w[L]]+O)]:w[L-1];w[0]=l[m(c[w[0]]+O)]}for(O=0;O<=o;O++)w[O]=c[w[O]];for(P=M,k=0,O=0;O>=1)1&k&&(p[e-1-P+8*e]=1,P<6?p[8+e*P]=1:p[8+e*(P+1)]=1);for(P=0;P<7;P++,k>>=1)1&k&&(p[8+e*(e-7+P)]=1,P?p[6-P+8*e]=1:p[7+8*e]=1);return p}(v)},utf16to8:function(t){var e,i,n,r;for(e="",n=t.length,i=0;i =1&&r<=127?e+=t.charAt(i):r>2047?(e+=String.fromCharCode(224|r>>12&15),e+=String.fromCharCode(128|r>>6&63),e+=String.fromCharCode(128|r>>0&63)):(e+=String.fromCharCode(192|r>>6&31),e+=String.fromCharCode(128|r>>0&63));return e},draw:function(t,i,n,r,o){i.drawView(n,r);var s=i.ctx,a=n.contentSize,h=a.width,d=a.height,c=a.left,l=a.top;r.borderRadius,r.backgroundColor;var f=r.color,u=void 0===f?"#000000":f;r.border,n.contentSize.left,n.borderSize.left,n.contentSize.top,n.borderSize.top;if(y=o||y,s){s.save(),i.setOpacity(r),i.setTransform(n,r);var p=Math.min(h,d);t=this.utf16to8(t);var g=this.getFrame(t),v=p/e;s.setFillStyle(u);for(var b=0;b =s||"cover"==n&&o =s)&&(a=e.width/i.width);var h=i.width*a,d=i.height*a,c=r||[],l=c[0],f=c[1],u=/^\d+px|rpx$/.test(l)?O(l,e.width):(e.width-h)*(L(l)?O(l,1):{left:0,center:.5,right:1}[l||"center"]),p=/^\d+px|rpx$/.test(f)?O(f,e.height):(e.height-d)*(L(f)?O(f,1):{top:0,center:.5,bottom:1}[f||"center"]),g=function(t,e){return[(t-u)/a,(e-p)/a]},v=g(0,0),y=v[0],b=v[1],x=g(e.width,e.height),m=x[0],w=x[1];return{sx:Math.max(y,0),sy:Math.max(b,0),sw:Math.min(m-y,i.width),sh:Math.min(w-b,i.height),dx:Math.max(u,0),dy:Math.max(p,0),dw:Math.min(h,e.width),dh:Math.min(d,e.height)}}({objectFit:u,objectPosition:v},n.contentSize,t),r=i.sx,s=i.sy,a=i.sh,h=i.sw,d=i.dx,c=i.dy,l=i.dh,f=i.dw;k==o.MP_BAIDU?e.drawImage(t.src,d+w,c+S,f,l,r,s,h,a):e.drawImage(t.src,r,s,h,a,d+w,c+S,f,l)}else e.drawImage(t.src,w,S,x,m)},I=function(){e.restore(),W.drawView(n,r,!1,!0,!1),h(1)},P=function(t){M(t),I()},P(t),[2]}))}))}))];case 1:return h.sent(),[2]}}))}))},n.prototype.drawText=function(t,e,i,n){var r=this.ctx,o=e.borderSize,s=e.contentSize,a=e.left,h=e.top,d=s.width,c=s.height,l=s.left-o.left,f=s.top-o.top,u=i.color,p=void 0===u?"#000000":u,g=i.lineHeight,v=void 0===g?"1.4em":g,y=i.fontSize,b=void 0===y?14:y,x=i.fontWeight,m=i.fontFamily,w=i.fontStyle,S=i.textAlign,z=void 0===S?"left":S,B=i.verticalAlign,M=void 0===B?pt:B,I=i.backgroundColor,k=i.lineClamp,P=i.backgroundClip,W=i.textShadow,R=i.textDecoration;if(this.drawView(e,i,P!=ct),v=O(v,b),t){switch(r.save(),this.setShadow({boxShadow:W}),a+=l,h+=f,r.setFonts({fontFamily:m,fontSize:b,fontWeight:x,fontStyle:w}),r.setTextBaseline(pt),r.setTextAlign(z),P?this.setBackground(I,d,c,a,h):r.setFillStyle(p),z){case vt:break;case yt:a+=.5*d;break;case bt:a+=d}var L=n.lines*v,T=Math.ceil((c-L)/2);switch(T<0&&(T=0),M){case ut:break;case pt:h+=T;break;case gt:h+=2*T}var A=n.fontHeight,F=n.descent,j=(v-A)/2,C=function(t){var e=r.measureText(t),i=e.actualBoundingBoxDescent,n=void 0===i?0:i,o=e.actualBoundingBoxAscent,s=void 0===o?0:o,a=n+s||.7*b+1;return M==ut?{fix:s,height:a,lineY:v-a}:M==pt?{fix:v/2+n/4,height:a,lineY:(v-a)/2}:M==gt?{fix:v-n,height:a,lineY:0}:{fix:0,height:0,lineY:0}},E=function(t,e,i){var o=t;switch(z){case vt:o+=i;break;case yt:o=(t-=i/2)+i;break;case bt:o=t,t-=i}if(R){r.setLineWidth(b/13),r.beginPath();var s=.1*n.fontHeight;/\bunderline\b/.test(R)&&(F||(e+=j/2),r.moveTo(t,e+s),r.lineTo(o,e+s)),/\boverline\b/.test(R)&&(F||(e-=j/2),r.moveTo(t,e-n.fontHeight-s),r.lineTo(o,e-n.fontHeight-s)),/\bline-through\b/.test(R)&&(r.moveTo(t,e-.5*n.fontHeight),r.lineTo(o,e-.5*n.fontHeight)),r.closePath(),r.setStrokeStyle(p),r.stroke()}};if(!n.widths||1==n.widths.length&&n.widths[0].total<=s.width){var H=C(t),U=H.fix,Y=H.lineY;return r.fillText(t,a,h+U),E(a,(h+=v)-Y,n&&n.widths&&n.widths[0].total||n.text),r.restore(),void this.setBorder(e,i)}for(var $=t.split(""),D=h,X=a,_="",N=0,V=0;V<=$.length;V++){var G=$[V]||"",q="\n"===G,J=""==G,Q=_+(G=q?"":G),Z=r.measureText(Q).width;if(N>=k)break;if(X=a,Z>s.width||q||J){if(N++,_=J&&Z<=s.width?Q:_,N===k&&Z>d){for(;r.measureText("".concat(_,"...")).width>s.width&&!(_.length<=1);)_=_.substring(0,_.length-1);_+="..."}var K=C(_);U=K.fix,Y=K.lineY;if(r.fillText(_,X,h+U),E(X,(h+=v)-Y,Z),_=G,h>D+c)break}else _=Q}r.restore()}},n.prototype.source=function(t){var n;return e(this,void 0,void 0,(function(){var e,r,o,s=this;return i(this,(function(i){switch(i.label){case 0:if(this.node=null,e=+new Date,"{}"==JSON.stringify(t))return[2];if(!t.type)for(r in t.type=ft,t.css=t.css||{},t)["views","children","type","css"].includes(r)||(t.css[r]=t[r],delete t[r]);return(null===(n=t.css)||void 0===n?void 0:n.width)||t.css||(t.css={}),[4,this.create(t)];case 1:return o=i.sent(),this.size=(null==o?void 0:o.layout())||{},this.node=o,this.onEffectFinished().then((function(t){return s.lifecycle("onEffectSuccess",t)})).catch((function(t){return s.lifecycle("onEffectFail",t)})),console.log("布局用时:"+(+new Date-e)+"ms"),[2,this.size]}}))}))},n.prototype.getImageInfo=function(t){return this.imageBus[t]||(this.imageBus[t]=this.createImage(t,this.useCORS)),this.imageBus[t]},n.prototype.create=function(n,r){var o,s;return e(this,void 0,void 0,(function(){var e,a,h,d,c,l,f,u,p,g,v,y,b,x,m,S,z;return i(this,(function(i){switch(i.label){case 0:if(e=n.type==dt,a=[ct,lt].includes(n.type),h=n.css||{},d=h.backgroundImage,c=h.display,e&&!n.src&&!n.url||a&&!n.text)return[2];if(c==w)return[2];if(a&&(n.text=String(n.text)),!(e||n.type==ft&&d))return[3,4];l=e?n.src:"",f=/url\((.+)\)/,d&&(null===(o=f.exec(d))||void 0===o?void 0:o[1])&&(l=(null===(s=f.exec(d))||void 0===s?void 0:s[1])||""),i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.getImageInfo(l)];case 2:return u=i.sent(),p=u.width,g=u.height,!(v=u.path)&&e?[2]:(v&&(n.attributes=Object.assign(n.attributes||{},{width:p,height:g,path:v,src:v,naturalSrc:l})),[3,4]);case 3:return y=i.sent(),n.type!=ft?[2]:(this.lifecycle("onEffectFail",t(t({},y),{src:l})),[3,4]);case 4:if(this.count+=1,b=new at(n,r,this.root,this.ctx),!(x=n.views||n.children))return[3,8];m=0,i.label=5;case 5:return m/^data:image\/(\w+);base64/.test(path); +export function sleep(delay) { + return new Promise(resolve => setTimeout(resolve, delay)) +} +const isDev = ['devtools'].includes(uni.getSystemInfoSync().platform) +// 缓存图片 +let cache = {} +export function isNumber(value) { + return /^-?\d+(\.\d+)?$/.test(value); +} +export function toPx(value, baseSize, isDecimal = false) { + // 如果是数字 + if (typeof value === 'number') { + return value + } + // 如果是字符串数字 + if (isNumber(value)) { + return value * 1 + } + // 如果有单位 + if (typeof value === 'string') { + const reg = /^-?([0-9]+)?([.]{1}[0-9]+){0,1}(em|rpx|px|%)$/g + const results = reg.exec(value); + if (!value || !results) { + return 0; + } + const unit = results[3]; + value = parseFloat(value); + let res = 0; + if (unit === 'rpx') { + res = uni.upx2px(value); + } else if (unit === 'px') { + res = value * 1; + } else if (unit === '%') { + res = value * toPx(baseSize) / 100; + } else if (unit === 'em') { + res = value * toPx(baseSize || 14); + } + return isDecimal ? res.toFixed(2) * 1 : Math.round(res); + } + return 0 +} + +// 计算版本 +export function compareVersion(v1, v2) { + v1 = v1.split('.') + v2 = v2.split('.') + const len = Math.max(v1.length, v2.length) + while (v1.length < len) { + v1.push('0') + } + while (v2.length < len) { + v2.push('0') + } + for (let i = 0; i < len; i++) { + const num1 = parseInt(v1[i], 10) + const num2 = parseInt(v2[i], 10) + + if (num1 > num2) { + return 1 + } else if (num1 < num2) { + return -1 + } + } + return 0 +} +// #ifdef MP +export const prefix = () => { + // #ifdef MP-TOUTIAO + return tt + // #endif + // #ifdef MP-WEIXIN + return wx + // #endif + // #ifdef MP-BAIDU + return swan + // #endif + // #ifdef MP-ALIPAY + return my + // #endif + // #ifdef MP-QQ + return qq + // #endif + // #ifdef MP-360 + return qh + // #endif +} +// #endif + + +const base64ToArrayBuffer = (data) => { + // #ifndef MP-WEIXIN || APP-PLUS + /** + * Base64Binary.decode(base64_string); + * Base64Binary.decodeArrayBuffer(base64_string); + */ + const Base64Binary = { + _keyStr: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=", + /* will return a Uint8Array type */ + decodeArrayBuffer(input) { + const bytes = (input.length / 4) * 3; + const ab = new ArrayBuffer(bytes); + this.decode(input, ab); + return ab; + }, + removePaddingChars(input) { + const lkey = this._keyStr.indexOf(input.charAt(input.length - 1)); + if (lkey == 64) { + return input.substring(0, input.length - 1); + } + return input; + }, + decode(input, arrayBuffer) { + //get last chars to see if are valid + input = this.removePaddingChars(input); + input = this.removePaddingChars(input); + + const bytes = parseInt((input.length / 4) * 3, 10); + + let uarray; + let chr1, chr2, chr3; + let enc1, enc2, enc3, enc4; + let i = 0; + let j = 0; + + if (arrayBuffer) + uarray = new Uint8Array(arrayBuffer); + else + uarray = new Uint8Array(bytes); + + input = input.replace(/[^A-Za-z0-9\+\/\=]/g, ""); + + for (i = 0; i < bytes; i += 3) { + //get the 3 octects in 4 ascii chars + enc1 = this._keyStr.indexOf(input.charAt(j++)); + enc2 = this._keyStr.indexOf(input.charAt(j++)); + enc3 = this._keyStr.indexOf(input.charAt(j++)); + enc4 = this._keyStr.indexOf(input.charAt(j++)); + + chr1 = (enc1 << 2) | (enc2 >> 4); + chr2 = ((enc2 & 15) << 4) | (enc3 >> 2); + chr3 = ((enc3 & 3) << 6) | enc4; + + uarray[i] = chr1; + if (enc3 != 64) uarray[i + 1] = chr2; + if (enc4 != 64) uarray[i + 2] = chr3; + } + return uarray; + } + } + return Base64Binary.decodeArrayBuffer(data) + // #endif + // #ifdef MP-WEIXIN || APP-PLUS + return uni.base64ToArrayBuffer(data) + // #endif +} + + +/** + * base64转路径 + * @param {Object} base64 + */ +export function base64ToPath(base64) { + const [, format] = /^data:image\/(\w+);base64,/.exec(base64) || []; + + return new Promise((resolve, reject) => { + // #ifdef MP + const fs = uni.getFileSystemManager() + //自定义文件名 + if (!format) { + reject(new Error('ERROR_BASE64SRC_PARSE')) + } + const time = new Date().getTime(); + let pre = prefix() + const filePath = `${pre.env.USER_DATA_PATH}/${time}.${format}` + //let buffer = base64ToArrayBuffer(bodyData) + fs.writeFile({ + filePath, + data: base64.split(',')[1], //base64.replace(/^data:\S+\/\S+;base64,/, ''), + encoding: 'base64', + // data: buffer, + // encoding: 'binary', + success() { + resolve(filePath) + }, + fail(err) { + reject(err) + } + }) + // #endif + + // #ifdef H5 + // mime类型 + let mimeString = base64.split(',')[0].split(':')[1].split(';')[0]; + //base64 解码 + let byteString = atob(base64.split(',')[1]); + //创建缓冲数组 + let arrayBuffer = new ArrayBuffer(byteString.length); + //创建视图 + let intArray = new Uint8Array(arrayBuffer); + for (let i = 0; i < byteString.length; i++) { + intArray[i] = byteString.charCodeAt(i); + } + resolve(URL.createObjectURL(new Blob([intArray], { + type: mimeString + }))) + // #endif + + // #ifdef APP-PLUS + const bitmap = new plus.nativeObj.Bitmap('bitmap' + Date.now()) + bitmap.loadBase64Data(base64, () => { + if (!format) { + reject(new Error('ERROR_BASE64SRC_PARSE')) + } + const time = new Date().getTime(); + const filePath = `_doc/uniapp_temp/${time}.${format}` + bitmap.save(filePath, {}, + () => { + bitmap.clear() + resolve(filePath) + }, + (error) => { + bitmap.clear() + reject(error) + }) + }, (error) => { + bitmap.clear() + reject(error) + }) + // #endif + }) +} + +/** + * 路径转base64 + * @param {Object} string + */ +export function pathToBase64(path) { + if (/^data:/.test(path)) return path + return new Promise((resolve, reject) => { + // #ifdef H5 + let image = new Image(); + image.setAttribute("crossOrigin", 'Anonymous'); + image.onload = function() { + let canvas = document.createElement('canvas'); + canvas.width = this.naturalWidth; + canvas.height = this.naturalHeight; + canvas.getContext('2d').drawImage(image, 0, 0); + let result = canvas.toDataURL('image/png') + resolve(result); + canvas.height = canvas.width = 0 + } + image.src = path + '?v=' + Math.random() + image.onerror = (error) => { + reject(error); + }; + // #endif + + // #ifdef MP + if (uni.canIUse('getFileSystemManager')) { + uni.getFileSystemManager().readFile({ + filePath: path, + encoding: 'base64', + success: (res) => { + resolve('data:image/png;base64,' + res.data) + }, + fail: (error) => { + reject(error) + } + }) + } + // #endif + + // #ifdef APP-PLUS + plus.io.resolveLocalFileSystemURL(getLocalFilePath(path), (entry) => { + entry.file((file) => { + const fileReader = new plus.io.FileReader() + fileReader.onload = (data) => { + resolve(data.target.result) + } + fileReader.onerror = (error) => { + reject(error) + } + fileReader.readAsDataURL(file) + }, reject) + }, reject) + // #endif + }) +} + + + +export function getImageInfo(path, useCORS) { + return new Promise(async (resolve, reject) => { + let src = path + if (cache[path] && cache[path].errMsg) { + resolve(cache[path]) + } else { + try { + // if (!isBase64 && PLATFORM == UNI_PLATFORM.PLUS && !/^\/?(static|_doc)\//.test(src)) { + // src = await downloadFile(path) as string + // } else + // #ifdef MP || APP-PLUS + if (isBase64(path)) { + src = await base64ToPath(path) + } + // #endif + // #ifdef H5 + if(useCORS) { + src = await pathToBase64(path) + } + // #endif + + } catch (error) { + reject({ + ...error, + src + }) + } + uni.getImageInfo({ + src, + success: (image) => { + const localReg = /^\.|^\/(?=[^\/])/; + // #ifdef MP-WEIXIN || MP-BAIDU || MP-QQ || MP-TOUTIAO + image.path = localReg.test(src) ? `/${image.path}` : image.path; + // #endif + // #ifdef H5 + image.path = image.path.replace(/^\./, window.location.origin) + // #endif + if (isDev) { + resolve(image) + } else { + cache[path] = image + resolve(cache[path]) + } + }, + fail(err) { + reject({ + err, + path + }) + } + }) + } + }) +} + +export function downloadFile(url) { + if (!url) return Promise.reject({ + err: 'no url' + }) + return new Promise((resolve, reject) => { + if (cache[url]) { + return reject() + } + cache[url] = 1 + uni.downloadFile({ + url, + success(res) { + resolve(res) + }, + fail(err) { + reject(err) + } + }) + }) +} + +// #ifdef APP-PLUS +const getLocalFilePath = (path) => { + if (path.indexOf('_www') === 0 || path.indexOf('_doc') === 0 || path.indexOf('_documents') === 0 || path + .indexOf('_downloads') === 0) { + return path + } + if (path.indexOf('file://') === 0) { + return path + } + if (path.indexOf('/storage/emulated/0/') === 0) { + return path + } + if (path.indexOf('/') === 0) { + const localFilePath = plus.io.convertAbsoluteFileSystem(path) + if (localFilePath !== path) { + return localFilePath + } else { + path = path.substr(1) + } + } + return '_www/' + path +} +const getFile = (url) => { + return new Promise((resolve, rejcet) => { + plus.io.resolveLocalFileSystemURL(url, resolve, (err) => { + resolve(false) + }) + }) +} +const createFile = ({ + fs, + url, + target, + name +}) => { + return new Promise((resolve, reject) => { + plus.io.resolveLocalFileSystemURL(url, res1 => { + fs.root.getDirectory(target, { + create: true + }, fileEntry => { + const success = () => { + res1.remove() + resolve() + } + getFile(target + name).then(res => { + if (res) { + res.remove((res2) => { + res1.moveTo(fileEntry, name, success, reject) + }) + } + res1.moveTo(fileEntry, name, success, reject) + }) + }) + }, reject) + }) +} +export function useNvue(target, version, timeout) { + return new Promise((resolve, reject) => { + plus.io.requestFileSystem(plus.io.PRIVATE_DOC, async (fs) => { + try { + cache['lime-painter'] = 0 + let names = ['uni.webview.1.5.3.js', 'painter.js', 'index.html'] + let urls = ['https://gitee.com/dcloud/uni-app/raw/dev/dist/', + 'https://static-6d65bd90-8508-4d6c-abbc-a4ef5c8e49e7.bspapp.com/lime-painter/' + ] + const oldVersion = plus.storage.getItem('lime-painter') + const isFile = await getFile(`${target}${names[1]}`) + if (isFile && oldVersion && compareVersion(oldVersion, version) >= 0) { + resolve() + } else { + for (var i = 0; i < names.length; i++) { + const name = names[i] + const file = await downloadFile(urls[i >= 1 ? 1 : 0] + name) + await createFile({ + fs, + url: file.tempFilePath, + target, + name: name.includes('uni.webview') ? 'uni.webview.js' : name + }) + } + plus.storage.setItem('lime-painter', version) + cache['lime-painter'] = version + resolve() + } + } catch (e) { + let index = parseInt(timeout / 20) + while (!cache['lime-painter'] && index) { + await sleep(20) + index-- + } + if (cache['lime-painter']) { + resolve() + } else { + reject(e) + } + } + }, reject) + }) +} +// #endif diff --git a/uni_modules/lime-painter/components/lime-painter/index.vue b/uni_modules/lime-painter/components/lime-painter/index.vue new file mode 100644 index 0000000..ba53413 --- /dev/null +++ b/uni_modules/lime-painter/components/lime-painter/index.vue @@ -0,0 +1,2 @@ + + \ No newline at end of file diff --git a/uni_modules/lime-painter/package.json b/uni_modules/lime-painter/package.json new file mode 100644 index 0000000..f973fc3 --- /dev/null +++ b/uni_modules/lime-painter/package.json @@ -0,0 +1,96 @@ +{ + "id": "lime-painter", + "displayName": "海报画板", + "version": "1.9.3.4", + "description": "一款canvas海报组件,更优雅的海报生成方案", + "keywords": [ + "海报", + "canvas", + "生成海报", + "生成二维码", + "JSON" +], + "repository": "https://gitee.com/liangei/lime-painter", + "engines": { + "HBuilderX": "^3.4.14" + }, + "dcloudext": { + "category": [ + "前端组件", + "通用组件" + ], + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "305716444" + }, + "declaration": { + "ads": "无", + "data": "无", + "permissions": "无" + }, + "npmurl": "" + }, + "uni_modules": { + "dependencies": [], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y" + }, + "client": { + "App": { + "app-vue": "y", + "app-nvue": "y" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "u", + "Edge": "u", + "Firefox": "u", + "Safari": "y" + }, + "小程序": { + "微信": "y", + "阿里": "y", + "百度": "y", + "字节跳动": "y", + "QQ": "y", + "钉钉": "u", + "快手": "u", + "飞书": "u", + "京东": "u", + "小红书": "u" + }, + "快应用": { + "华为": "u", + "联盟": "u" + }, + "Vue": { + "vue2": "y", + "vue3": "y" + } + } + } + }, + "name": "lime-painter", + "main": "index.js", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "author": "", + "license": "ISC" +} diff --git a/uni_modules/lime-painter/readme.md b/uni_modules/lime-painter/readme.md new file mode 100644 index 0000000..3bd8e41 --- /dev/null +++ b/uni_modules/lime-painter/readme.md @@ -0,0 +1,910 @@ +# Painter 画板 测试版 + +> uniapp 海报画板,更优雅的海报生成方案 +> [查看更多 站点 1](https://limeui.qcoon.cn/#/painter) +> [查看更多 站点 2](http://liangei.gitee.io/limeui/#/painter) +> Q 群:806744170 + +## 平台兼容 + +| H5 | 微信小程序 | 支付宝小程序 | 百度小程序 | 头条小程序 | QQ 小程序 | App | +| --- | ---------- | ------------ | ---------- | ---------- | --------- | --- | +| √ | √ | √ | 未测 | √ | √ | √ | + +## 安装 +在市场导入[海报画板](https://ext.dcloud.net.cn/plugin?id=2389)uni_modules版本的即可,无需`import` + +## 代码演示 + +### 基本用法 + +- 插件提供 JSON 及 XML 的方式绘制海报 +- 参考了 css 块状流布局模拟 css schema 方式。 +- 使用JSON的方式时,请使用驼峰key + + +#### 方式一 XML + +- 提供`l-painter-view`、`l-painter-text`、`l-painter-image`、`l-painter-qrcode`四种类型组件 +- 通过 `css` 属性绘制样式,与 style 使用方式保持一致。 + +```html + + +``` + +#### 方式二 JSON + +- 在 json 里四种类型组件的`type`为`view`、`text`、`image`、`qrcode` +- 通过 `board` 设置海报所需的 JSON 数据进行绘制或`ref`获取组件实例调用组件内的`render(json)` +- 所有类型的 schema 都具有`css`字段,css 的 key 值使用**驼峰**如:`lineHeight` + +```html ++ + + +``` + +```js +data() { + return { + poster: { + css: { + // 根节点若无尺寸,自动获取父级节点 + width: '750rpx' + }, + views: [ + { + css: { + background: "#07c160", + height: "120rpx", + width: "120rpx", + display: "inline-block" + }, + type: "view" + }, + { + css: { + background: "#1989fa", + height: "120rpx", + width: "120rpx", + borderTopRightRadius: "60rpx", + borderBottomLeftRadius: "60rpx", + display: "inline-block", + margin: "0 30rpx" + }, + views: [], + type: "view" + }, + { + css: { + background: "#ff9d00", + height: "120rpx", + width: "120rpx", + borderRadius: "50%", + display: "inline-block" + }, + views: [], + type: "view" + }, + ] + } + } +} +``` + +### View 容器 + +- 类似于 `div` 可以嵌套承载更多的 view、text、image,qrcode 共同构建一颗完整的节点树 +- 在 JSON 里具有 `views` 的数组字段,用于嵌套承载节点。 + +#### 方式一 XML + +```html + + +``` + +#### 方式二 JSON + +```js +{ + css: {}, + views: [ + { + type: 'view', + css: { + background: '#f0f0f0', + paddingTop: '100rpx' + }, + views: [ + { + type: 'view', + css: { + background: '#d9d9d9', + width: '33.33%', + height: '100rpx', + display: 'inline-block' + } + }, + { + type: 'view', + css: { + background: '#bfbfbf', + width: '66.66%', + height: '100rpx', + display: 'inline-block' + } + } + ], + + } + ] +} +``` + +### Text 文本 + +- 通过 `text` 属性填写文本内容。 +- 支持`\n`换行符 +- 支持省略号,使用 css 的`line-clamp`设置行数,当文字内容超过会显示省略号。 +- 支持`text-decoration` + +#### 方式一 XML + +```html ++ ++ + + +``` + +#### 方式二 JSON + +```js +// 基础用法 +{ + type: 'text', + text: '登鹳雀楼\n白日依山尽,黄河入海流\n欲穷千里目,更上一层楼', +}, +{ + type: 'text', + text: '登鹳雀楼\n白日依山尽,黄河入海流\n欲穷千里目,更上一层楼', + css: { + // 设置居中对齐 + textAlign: 'center', + // 设置中划线 + textDecoration: 'line-through' + } +}, +{ + type: 'text', + text: '登鹳雀楼\n白日依山尽,黄河入海流\n欲穷千里目,更上一层楼', + css: { + // 设置右对齐 + textAlign: 'right', + } +}, +{ + type: 'text', + text: '登鹳雀楼\n白日依山尽,黄河入海流\n欲穷千里目,更上一层楼', + css: { + // 设置行数,超出显示省略号 + lineClamp: 3, + // 渐变文字 + background: 'linear-gradient(,#ff971b 0%, #1989fa 100%)', + backgroundClip: 'text' + } +} +``` + +### Image 图片 + +- 通过 `src` 属性填写图片路径。 +- 图片路径支持:网络图片,本地 static 里的图片路径,缓存路径 +- 通过 `css` 的 `object-fit`属性可以设置图片的填充方式,可选值见下方 CSS 表格。 +- 通过 `css` 的 `object-position`配合 `object-fit` 可以设置图片的对齐方式,类似于`background-position`,详情见下方 CSS 表格。 +- 使用网络图片时:小程序需要去公众平台配置 [downloadFile](https://mp.weixin.qq.com/) 域名 +- 使用网络图片时:**H5 和 Nvue 需要决跨域问题** + +#### 方式一 XML + +```html ++ ++ + + + + + +``` + +#### 方式二 JSON + +```js +// 基础用法 +{ + type: 'image', + src: 'https://m.360buyimg.com/babel/jfs/t1/196317/32/13733/288158/60f4ea39E6fb378ed/d69205b1a8ed3c97.jpg', + css: { + width: '200rpx', + height: '200rpx' + } +}, +// 填充方式 +// css objectFit 设置 填充方式 见下方表格 +{ + type: 'image', + src: 'https://m.360buyimg.com/babel/jfs/t1/196317/32/13733/288158/60f4ea39E6fb378ed/d69205b1a8ed3c97.jpg', + css: { + width: '200rpx', + height: '200rpx', + objectFit: 'contain' + } +}, +// css objectPosition 设置 图片的对齐方式 +{ + type: 'image', + src: 'https://m.360buyimg.com/babel/jfs/t1/196317/32/13733/288158/60f4ea39E6fb378ed/d69205b1a8ed3c97.jpg', + css: { + width: '200rpx', + height: '200rpx', + objectFit: 'contain', + objectPosition: '50% 50%' + } +} +``` + +### Qrcode 二维码 + +- 通过`text`属性填写需要生成二维码的文本。 +- 通过 `css` 里的 `color` 可设置生成码点的颜色。 +- 通过 `css` 里的 `background`可设置背景色。 +- 通过 `css `里的 `width`、`height`设置尺寸。 + +#### 方式一 XML + +```html ++ + + + + + + +``` + +#### 方式二 JSON + +```js +{ + type: 'qrcode', + text: 'limeui.qcoon.cn', + css: { + width: '200rpx', + height: '200rpx', + } +} +``` + +### 生成图片 + +- 1、通过设置`isCanvasToTempFilePath`自动生成图片并在 `@success` 事件里接收海报临时路径 +- 2、通过调用内部方法生成图片: + +```html ++ ...code +``` + +```js +this.$refs.painter.canvasToTempFilePathSync({ + fileType: "jpg", + // 如果返回的是base64是无法使用 saveImageToPhotosAlbum,需要设置 pathType为url + pathType: 'url', + quality: 1, + success: (res) => { + console.log(res.tempFilePath); + // 非H5 保存到相册 + // H5 提示用户长按图另存 + uni.saveImageToPhotosAlbum({ + filePath: res.tempFilePath, + success: function () { + console.log('save success'); + } + }); + }, +}); +``` + +### 主动调用方式 + +- 通过获取组件实例内部的`render`函数 传递`JSON`即可 + +```html ++``` + +```js +// 渲染 +this.$refs.painter.render(jsonSchema); +// 生成图片 +this.$refs.painter.canvasToTempFilePathSync({ + fileType: "jpg", + // 如果返回的是base64是无法使用 saveImageToPhotosAlbum,需要设置 pathType为url + pathType: 'url', + quality: 1, + success: (res) => { + console.log(res.tempFilePath); + // 非H5 保存到相册 + uni.saveImageToPhotosAlbum({ + filePath: res.tempFilePath, + success: function () { + console.log('save success'); + } + }); + }, +}); +``` + + +### H5跨域 +- 一般是需要后端或管理OSS资源的大佬处理 +- 一般OSS的处理方式: + +1、设置来源 +```cmd +* +``` + +2、允许Methods +```html +GET +``` + +3、允许Headers +```html +access-control-allow-origin:* +``` + +4、最后如果还是不行,可试下给插件设置`useCORS` +```html + +``` + + + +### 海报示例 + +- 提供一份示例,只把插件当成生成图片的工具,非必要不要在弹窗里使用。 +- 通过设置`isCanvasToTempFilePath`主动生成图片,再由 `@success` 事件接收海报临时路径 +- 设置`custom-style="position: fixed; left: 200%"`样式把画板移到屏幕之外,达到隐藏画板的效果。 +- **注意**:受平台影响海报画板最好不要隐藏,可能会无法生成图片。 + +#### 方式一 XML + +```html + + + +``` + +```js +data() { + return { + path: '' + } +} +``` + +#### 方式二 JSON + +```html ++ + ++ + + ++ + ++ + + + + ++ + + + + ++ + + +``` + +```js +data() { + return { + path: '', + poster: { + css: { + width: "750rpx", + paddingBottom: "40rpx", + background: "linear-gradient(,#000 0%, #ff5000 100%)" + }, + views: [ + { + src: "https://fastly.jsdelivr.net/gh/liangei/image@latest/avatar-1.jpeg", + type: "image", + css: { + background: "#fff", + objectFit: "cover", + marginLeft: "40rpx", + marginTop: "40rpx", + width: "84rpx", + border: "2rpx solid #fff", + boxSizing: "border-box", + height: "84rpx", + borderRadius: "50%" + } + }, + { + type: "view", + css: { + marginTop: "40rpx", + paddingLeft: "20rpx", + display: "inline-block" + }, + views: [ + { + text: "隔壁老王", + type: "text", + css: { + display: "block", + paddingBottom: "10rpx", + color: "#fff", + fontSize: "32rpx", + fontWeight: "bold" + } + }, + { + text: "为您挑选了一个好物", + type: "text", + css: { + color: "rgba(255,255,255,.7)", + fontSize: "24rpx" + }, + } + ], + }, + { + css: { + marginLeft: "40rpx", + marginTop: "30rpx", + padding: "32rpx", + boxSizing: "border-box", + background: "#fff", + borderRadius: "16rpx", + width: "670rpx", + boxShadow: "0 20rpx 58rpx rgba(0,0,0,.15)" + }, + views: [ + { + src: "https://m.360buyimg.com/babel/jfs/t1/196317/32/13733/288158/60f4ea39E6fb378ed/d69205b1a8ed3c97.jpg", + type: "image", + css: { + objectFit: "cover", + objectPosition: "50% 50%", + width: "606rpx", + height: "606rpx" + }, + }, { + css: { + marginTop: "32rpx", + color: "#FF0000", + fontWeight: "bold", + fontSize: "28rpx", + lineHeight: "1em" + }, + views: [{ + text: "¥", + type: "text", + css: { + verticalAlign: "bottom" + }, + }, { + text: "39", + type: "text", + css: { + verticalAlign: "bottom", + fontSize: "58rpx" + }, + }, { + text: ".39", + type: "text", + css: { + verticalAlign: "bottom" + }, + }, { + text: "¥59.99", + type: "text", + css: { + verticalAlign: "bottom", + paddingLeft: "10rpx", + fontWeight: "normal", + textDecoration: "line-through", + color: "#999999" + } + }], + + type: "view" + }, { + css: { + marginTop: "32rpx", + fontSize: "26rpx", + color: "#8c5400" + }, + views: [{ + text: "自营", + type: "text", + css: { + color: "#212121", + background: "#ffb400" + }, + }, { + text: "30天最低价", + type: "text", + css: { + marginLeft: "16rpx", + background: "#fff4d9", + textDecoration: "line-through" + }, + }, { + text: "满减优惠", + type: "text", + css: { + marginLeft: "16rpx", + background: "#fff4d9" + }, + }, { + text: "超高好评", + type: "text", + css: { + marginLeft: "16rpx", + background: "#fff4d9" + }, + + }], + + type: "view" + }, { + css: { + marginTop: "30rpx" + }, + views: [ + { + text: "360儿童电话手表9X 智能语音问答定位支付手表 4G全网通20米游泳级防水视频通话拍照手表男女孩星空蓝", + type: "text", + css: { + paddingRight: "32rpx", + boxSizing: "border-box", + lineClamp: 2, + color: "#333333", + lineHeight: "1.8em", + fontSize: "36rpx", + width: "478rpx" + }, + }, { + text: "limeui.qcoon.cn", + type: "qrcode", + css: { + width: "128rpx", + height: "128rpx", + }, + + }], + type: "view" + }], + type: "view" + } + ] + } + } +} +``` + +### Nvue +- 必须为HBX 3.4.11及以上 + + +### 原生小程序 + +- 插件里的`painter.js`支持在原生小程序中使用 +- new Painter 之后在`source`里传入 JSON +- 再调用`render`绘制海报 +- 如需生成图片,请查看微信小程序 cavnas 的[canvasToTempFilePath](https://developers.weixin.qq.com/miniprogram/dev/api/canvas/wx.canvasToTempFilePath.html) + +```html + +``` + +```js +import { Painter } from "./painter"; +page({ + data: { + poster: { + css: { + width: "750rpx", + }, + views: [ + { + type: "view", + css: { + background: "#d2d4c8", + paddingTop: "100rpx", + }, + views: [ + { + type: "view", + css: { + background: "#5f7470", + width: "33.33%", + height: "100rpx", + display: "inline-block", + }, + }, + { + type: "view", + css: { + background: "#889696", + width: "33.33%", + height: "100rpx", + display: "inline-block", + }, + }, + { + type: "view", + css: { + background: "#b8bdb5", + width: "33.33%", + height: "100rpx", + display: "inline-block", + }, + }, + ], + }, + ], + }, + }, + async onLoad() { + const res = await this.getCentext(); + const painter = new Painter(res); + // 返回计算布局后的整个内容尺寸 + const { width, height } = await painter.source(this.data.poster); + // 得到计算后的尺寸后 可给canvas尺寸赋值,达到动态响应效果 + // 渲染 + await painter.render(); + }, + // 获取canvas 2d + // 非2d也可以使用这里只是举个例子 + getCentext() { + return new Promise((resolve) => { + wx.createSelectorQuery() + .select(`#painter`) + .node() + .exec((res) => { + let { node: canvas } = res[0]; + resolve({ + canvas, + context: canvas.getContext("2d"), + width: canvas.width, + height: canvas.height, + pixelRatio: 2, + }); + }); + }); + }, +}); +``` + +### 旧版(1.6.x)更新 + +- 由于 1.8.x 版放弃了以定位的方式,所以 1.6.x 版更新之后要每个样式都加上`position: absolute` +- 旧版的 `image` mode 模式被放弃,使用`object-fit` +- 旧版的 `isRenderImage` 改成 `is-canvas-to-temp-filePath` +- 旧版的 `maxLines` 改成 `line-clamp` + +## API + +### Props + +| 参数 | 说明 | 类型 | 默认值 | +| -------------------------- | ------------------------------------------------------------ | ---------------- | ------------ | +| board | JSON 方式的海报元素对象集 | object | - | +| css | 海报最外层的样式,可以理解为`body` | object | 参数请向下看 | +| custom-style | canvas 自定义样式 | string | | +| is-canvas-to-temp-filePath | 是否生成图片,在`@success`事件接收图片地址 | boolean | `false` | +| after-delay | 生成图片错乱,可延时生成图片 | number | `100` | +| type | canvas 类型,对微信头条支付宝小程序可有效,可选值:`2d`,`''` | string | `2d` | +| file-type | 生成图片的后缀类型, 可选值:`png`、`jpg` | string | `png` | +| path-type | 生成图片路径类型,可选值`url`、`base64` | string | `-` | +| pixel-ratio | 生成图片的像素密度,默认为对应手机的像素密度,`nvue`无效 | number | `-` | +| width | **废弃** 画板的宽度,一般只用于通过内部方法时加上 | number | `` | +| height | **废弃** 画板的高度 ,同上 | number | `` | + +### css +| 属性名 | 支持的值或类型 | 默认值 | +| ----------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------- | +| (min\max)width | 支持`%`、`rpx`、`px` | - | +| height | 同上 | - | +| color | `string` | - | +| position | 定位,可选值:`absolute`、`fixed` | - | +| ↳ left、top、right、bottom | 配合`position`才生效,支持`%`、`rpx`、`px` | - | +| margin | 可简写或各方向分别写,如:`margin-top`,支持`auto`、`rpx`、`px` | - | +| padding | 可简写或各方向分别写,支持`rpx`、`px` | - | +| border | 可简写或各个值分开写:`border-width`、`border-style` 、`border-color`,简写请按顺序写 | - | +| line-clamp | `number`,超过行数显示省略号 | - | +| vertical-align | 文字垂直对齐,可选值:`bottom`、`top`、`middle` | `middle` | +| line-height | 文字行高,支持`rpx`、`px`、`em` | `1.4em` | +| font-weight | 文字粗细,可选值:`normal`、`bold` | `normal` | +| font-size | 文字大小,`string`,支持`rpx`、`px` | `14px` | +| text-decoration | 文本修饰,可选值:`underline` 、`line-through`、`overline` | - | +| text-align | 文本水平对齐,可选值:`right` 、`center` | `left` | +| display | 框类型,可选值:`block`、`inline-block`、`flex`、`none`,当为`none`时是不渲染该段, `flex`功能简陋。 | - | +| flex | 配合 display: flex; 属性定义了在分配多余空间,目前只用为数值如: flex: 1 | - | +| align-self | 配合 display: flex; 单个项目垂直轴对齐方式: `flex-start` `flex-end` `center` | `flex-start` | +| justify-content | 配合 display: flex; 水平轴对齐方式: `flex-start` `flex-end` `center` | `flex-start` | +| align-items | 配合 display: flex; 垂直轴对齐方式: `flex-start` `flex-end` `center` | `flex-start` | +| border-radius | 圆角边框,支持`%`、`rpx`、`px` | - | +| box-sizing | 可选值:`border-box` | - | +| box-shadow | 投影 | - | +| background(color) | 支持渐变,但必须写百分比!如:`linear-gradient(,#ff971b 0%, #ff5000 100%)`、`radial-gradient(#0ff 15%, #f0f 60%)`,目前 radial-gradient 渐变的圆心为元素中点,半径为最长边,不支持设置 | - | +| background-clip | 文字渐变,配合`background`背景渐变,设置`background-clip: text` 达到文字渐变效果 | - | +| background-image | view 元素背景:`url(src)`,若只是设置背景图,请不要设置`background-repeat` | - | +| background-repeat | 设置是否及如何重复背景纹理,可选值:`repeat`、`repeat-x`、`repeat-y`、`no-repeat` | `repeat` | +| [object-fit](https://developer.mozilla.org/zh-CN/docs/Web/CSS/object-fit/) | 图片元素适应容器方式,类似于`mode`,可选值:`cover`、 `contain`、 `fill`、 `none` | - | +| [object-position](https://developer.mozilla.org/zh-CN/docs/Web/CSS/object-position) | 图片的对齐方式,配合`object-fit`使用 | - | + +### 图片填充模式 object-fit + +| 名称 | 含义 | +| ------- | ------------------------------------------------------ | +| contain | 保持宽高缩放图片,使图片的长边能完全显示出来 | +| cover | 保持宽高缩放图片,使图片的短边能完全显示出来,裁剪长边 | +| fill | 拉伸图片,使图片填满元素 | +| none | 保持图片原有尺寸 | + +### 事件 Events + +| 事件名 | 说明 | 返回值 | +| -------- | ---------------------------------------------------------------- | ------ | +| success | 生成图片成功,若使用`is-canvas-to-temp-filePath` 可以接收图片地址 | path | +| fail | 生成图片失败 | error | +| done | 绘制成功 | | +| progress | 绘制进度 | number | + +### 内部函数 Ref +| 事件名 | 说明 | 返回值 | +| -------- | ---------------------------------------------------------------- | ------ | +| render(object) | 渲染器,传入JSON 绘制海报 | promise | +| [canvasToTempFilePath](https://uniapp.dcloud.io/api/canvas/canvasToTempFilePath.html#canvastotempfilepath)(object) | 把当前画布指定区域的内容导出生成指定大小的图片,并返回文件临时路径。 | | +| canvasToTempFilePathSync(object) | 同步接口,同上 | | + + +## 常见问题 + +- 1、H5 端使用网络图片需要解决跨域问题。 +- 2、小程序使用网络图片需要去公众平台增加下载白名单!二级域名也需要配! +- 3、H5 端生成图片是 base64,有时显示只有一半可以使用原生标签`` +- 4、发生保存图片倾斜变形或提示 native buffer exceed size limit 时,使用 pixel-ratio="2"参数,降分辨率。 +- 5、h5 保存图片不需要调接口,提示用户长按图片保存。 +- 6、画板不能隐藏,包括`v-if`,`v-show`、`display:none`、`opacity:0`,另外也不要把画板放在弹窗里。如果需要隐藏画板请设置 `custom-style="position: fixed; left: 200%"` +- 7、微信小程序 canvas 2d **不支持真机调试**,请使用真机预览方式。 +- 8、微信小程序打开调试时可以生但并闭无法生成时,这种情况一般是没有在公众号配置download域名 +- 9、HBX 3.4.5之前的版本不支持vue3 +- 10、在微信开发工具上 canvas 层级最高无法zindex,并不影响真机 +- 11、请不要导入非uni_modules插件 +- 华为手机 APP 上无法生成图片,请使用 HBX2.9.11++(已过时,忽略这条) +- IOS APP 请勿使用 HBX2.9.3.20201014 的版本!这个版本无法生成图片。(已过时,忽略这条) +- 苹果微信 7.0.20 存在闪退和图片无法 onload 为微信 bug(已过时,忽略这条) + +## 打赏 + +如果你觉得本插件,解决了你的问题,赠人玫瑰,手留余香。 + +![输入图片说明](https://static-6d65bd90-8508-4d6c-abbc-a4ef5c8e49e7.bspapp.com/image/222521_bb543f96_518581.jpeg "微信图片编辑_20201122220352.jpg") +![输入图片说明](https://static-6d65bd90-8508-4d6c-abbc-a4ef5c8e49e7.bspapp.com/image/wxplay.jpg "wxplay.jpg") \ No newline at end of file diff --git a/uni_modules/lime-painter/static/index.html b/uni_modules/lime-painter/static/index.html new file mode 100644 index 0000000..fdf884e --- /dev/null +++ b/uni_modules/lime-painter/static/index.html @@ -0,0 +1,119 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/uni_modules/lime-painter/static/painter.js b/uni_modules/lime-painter/static/painter.js new file mode 100644 index 0000000..2910063 --- /dev/null +++ b/uni_modules/lime-painter/static/painter.js @@ -0,0 +1 @@ +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).Painter={})}(this,(function(t){"use strict";var e=function(){return e=Object.assign||function(t){for(var e,i=1,n=arguments.length;i 0&&o[o.length-1])||6!==r[0]&&2!==r[0])){s=0;continue}if(3===r[0]&&(!o||r[1]>o[0]&&r[1] =360&&(s-=360);s<0&&(s+=360);if(0===(s=Math.round(s)))return{x0:Math.round(e/2)+n,y0:i+o,x1:Math.round(e/2)+n,y1:o};if(180===s)return{x0:Math.round(e/2)+n,y0:o,x1:Math.round(e/2)+n,y1:i+o};if(90===s)return{x0:n,y0:Math.round(i/2)+o,x1:e+n,y1:Math.round(i/2)+o};if(270===s)return{x0:e+n,y0:Math.round(i/2)+o,x1:n,y1:Math.round(i/2)+o};var a=Math.round(180*Math.asin(e/Math.sqrt(Math.pow(e,2)+Math.pow(i,2)))/Math.PI);if(s===a)return{x0:n,y0:i+o,x1:e+n,y1:o};if(s===180-a)return{x0:n,y0:o,x1:e+n,y1:i+o};if(s===180+a)return{x0:e+n,y0:o,x1:n,y1:i+o};if(s===360-a)return{x0:e+n,y0:i+o,x1:n,y1:o};var h=0,d=0,c=0,l=0;if(s180-a&&s<180||s>180&&s<180+a||s>360-a){var f=s*Math.PI/180,u=s360-a?i/2:-i/2,p=Math.tan(f)*u,g=s180-a&&s<180?e/2-p:-e/2-p;h=-(c=p+(v=Math.pow(Math.sin(f),2)*g)),d=-(l=u+v/Math.tan(f))}if(s>a&&s<90||s>90&&s<90+a||s>180+a&&s<270||s>270&&s<360-a){var v;f=(90-s)*Math.PI/180,p=s>a&&s<90||s>90&&s<90+a?e/2:-e/2,u=Math.tan(f)*p,g=s>a&&s<90||s>270&&s<360-a?i/2-u:-i/2-u;h=-(c=p+(v=Math.pow(Math.sin(f),2)*g)/Math.tan(f)),d=-(l=u+v)}return h=Math.round(h+e/2)+n,d=Math.round(i/2-d)+o,c=Math.round(c+e/2)+n,l=Math.round(i/2-l)+o,{x0:h,y0:d,x1:c,y1:l}}(o,t,e,i,n),a=s.x0,h=s.y0,d=s.x1,c=s.y1,l=r.createLinearGradient(a,h,d,c),f=o.match(/linear-gradient\((.+)\)/)[1],u=U(f.substring(f.indexOf(",")+1)),p=0;p t.length)&&(e=t.length);for(var i=0,n=new Array(e);i =t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function N(t){return"number"==typeof t}function V(t){return"auto"===t||null===t}function G(t){return/%$/.test(t)}var q,J=0,Q=function(){function t(){Y(this,"elements",[]),Y(this,"afterElements",[]),Y(this,"beforeElements",[]),Y(this,"ids",[]),Y(this,"width",0),Y(this,"height",0),Y(this,"top",0),Y(this,"left",0),Y(this,"pre",null),Y(this,"offsetX",0),Y(this,"offsetY",0),J++,this.id=J}var e=t.prototype;return e.fixedBind=function(t,e){void 0===e&&(e=0),this.container=e?t.parent:t.root,this.container.fixedLine=this,this.fixedAdd(t)},e.fixedAdd=function(t){this.elements.push(t);var e=t.computedStyle.zIndex;(void 0===e?0:e)>=0?this.afterElements.push(t):this.beforeElements.push(t),this.refreshLayout()},e.bind=function(t){this.container=t.parent,this.container.line=null,this.container.lines?(this.container.lines.push(this),this.pre=this.getPreLine(),this.top=this.pre.top+this.pre.height,this.left=this.container.contentSize.left):(this.top=this.container.contentSize.top,this.left=this.container.contentSize.left,this.container.lines=[this]),this.isInline=t.isInline(),this.container.line=this,this.outerWidth=t.parent&&t.parent.contentSize.width?t.parent.contentSize.width:1/0,this.add(t)},e.getPreLine=function(){return this.container.lines[this.container.lines.length-2]},e.canIEnter=function(t){return!((100*t.offsetSize.width+100*this.width)/100>this.outerWidth)||(this.closeLine(),!1)},e.closeLine=function(){delete this.container.line},e.add=function(t){this.ids.push(t.id),this.elements.push(t),this.refreshWidthHeight(t)},e.refreshWidthHeight=function(t){t.offsetSize.height>this.height&&(this.height=t.offsetSize.height),this.width+=t.offsetSize.width||0,(this.container.lineMaxWidth||0) this[this.key.height]&&(this[this.key.height]=t.offsetSize[this.key.height]),this[this.key.width]+=t.offsetSize[this.key.width],(this.container.lineMaxWidth||0) 1?0:"flex-end"===t.style.alignSelf?this.container.contentSize[this.key.contentHeight]-t.contentSize[this.key.height]:"center"===t.style.alignSelf?(this.container.contentSize[this.key.contentHeight]-t.contentSize[this.key.height])/2:0},n}(Q),et=b,it=y,nt=v,ot=x,rt=m,st=w,at=z,ht=M,dt=B,ct=0,lt={left:null,top:null,width:null,height:null},ft=function(){function t(t,e,i,n){var o=this;Y(this,"id",ct++),Y(this,"style",{left:null,top:null,width:null,height:null}),Y(this,"computedStyle",{}),Y(this,"originStyle",{}),Y(this,"children",{}),Y(this,"layoutBox",$({},lt)),Y(this,"contentSize",$({},lt)),Y(this,"clientSize",$({},lt)),Y(this,"borderSize",$({},lt)),Y(this,"offsetSize",$({},lt)),this.ctx=n,this.root=i,e&&(this.parent=e),this.name=t.name||t.type,this.attributes=this.getAttributes(t);var r=this.getComputedStyle(t,null==e?void 0:e.computedStyle);this.isAbsolute=r.position==ht,this.isFixed=r.position==dt,this.originStyle=r,Object.keys(r).forEach((function(t){Object.defineProperty(o.style,t,{configurable:!0,enumerable:!0,get:function(){return r[t]},set:function(e){r[t]=e}})}));var s={contentSize:$({},this.contentSize),clientSize:$({},this.clientSize),borderSize:$({},this.borderSize),offsetSize:$({},this.offsetSize)};Object.keys(s).forEach((function(t){Object.keys(o[t]).forEach((function(e){Object.defineProperty(o[t],e,{configurable:!0,enumerable:!0,get:function(){return s[t][e]},set:function(i){s[t][e]=i}})}))})),this.computedStyle=this.style}var e=t.prototype;return e.add=function(t){t.parent=this,this.children[t.id]=t},e.getChildren=function(){var t=this;return Object.keys(this.children).map((function(e){return t.children[e]}))},e.getLineRect=function(t,e){var i={width:0,height:0},n=e?e.lines:this.parent&&this.parent.lines;return n&&n.find((function(e){return e.ids.includes(t)}))||i},e.getComputedStyle=function(t,e){var i=["color","fontSize","lineHeight","verticalAlign","fontWeight","textAlign"],n=t.css,o=void 0===n?{}:n,r=t.type,s=void 0===r?nt:r,a=$({},P);if([it,et,ot].includes(s)&&!o.display&&(a.display=st),e)for(var h=0;h =0&&l<0,Y=d>=0&&u<0;return i==a[0]&&(this[i].left=t.left+s+v+C+(U?2*-l:0),this[i].top=t.top+d+b+P+(Y?2*-u:0),this[i].width=t.width+(this[i].widthAdd?0:E),this[i].height=t.height+(this[i].heightAdd?0:H),this[i].widthAdd=E,this[i].heightAdd=H),i==a[1]&&(this[i].left=t.left+s+C+(U<0?-l:0),this[i].top=t.top+d+P+(Y?-u:0),this[i].width=t.width+v+m,this[i].height=t.height+b+S),i==a[2]&&(this[i].left=t.left+s+C/2+(U<0?-l:0),this[i].top=t.top+d+P/2+(Y?-u:0),this[i].width=t.width+v+m+C/2+A/2,this[i].height=t.height+b+S+O/2+P/2),i==a[3]&&(this[i].left=t.left+(U<0?-l:0),this[i].top=t.top+(Y?-u:0),this[i].width=t.width+v+m+C+A+s+l,this[i].height=t.height+b+S+O+P+u+d),this[i]},e.layoutBoxUpdate=function(t,e,i,n){var o=this;if(void 0===i&&(i=-1),"border-box"==e.boxSizing){var r=e||{},s=r.border,h=(s=void 0===s?{}:s).borderWidth,d=void 0===h?0:h,c=r.borderTop,l=(c=void 0===c?{}:c).borderTopWidth,f=void 0===l?d:l,u=r.borderBottom,p=(u=void 0===u?{}:u).borderBottomWidth,g=void 0===p?d:p,v=r.borderRight,y=(v=void 0===v?{}:v).borderRightWidth,b=void 0===y?d:y,x=r.borderLeft,m=(x=void 0===x?{}:x).borderLeftWidth,w=void 0===m?d:m,S=r.padding,z=(S=void 0===S?{}:S).paddingTop,M=void 0===z?0:z,B=S.paddingRight,I=void 0===B?0:B,k=S.paddingBottom,P=void 0===k?0:k,W=S.paddingLeft,R=void 0===W?0:W;i||(t.width-=R+I+b+w),1!==i||n||(t.height-=M+P+f+g)}this.layoutBox&&(a.forEach((function(i){return o.layoutBox[i]=o.getOffsetSize(t,e,i)})),this.layoutBox=Object.assign({},this.layoutBox,this.layoutBox.borderSize))},e.getBoxPosition2=function(){var t=this.computedStyle,e=this.fixedLine,i=this.lines,n=t.left,o=void 0===n?0:n,r=t.top,s=void 0===r?0:r,a=t.padding||{},h=a.paddingBottom,d=void 0===h?0:h,c=a.paddingRight,l=void 0===c?0:c,f=$({},this.contentSize,{left:o,top:s}),u=this.contentSize.top-this.offsetSize.top,p=this.contentSize.left-this.offsetSize.left;if(this.root.fixedLine&&!this.root.isDone){this.root.isDone=!0;for(var g,v=X(this.root.fixedLine.elements);!(g=v()).done;){var y=g.value;y.setPosition(y,this.root.offsetSize),y.getBoxPosition2()}}if(e)for(var b,x=X(e.elements);!(b=x()).done;){var m=b.value;m.setPosition(m,f),m.style.left+=o+p+l,m.style.top+=s+u+d,m.getBoxPosition2()}if(i)for(var w,S=X(i);!(w=S()).done;){w.value.layout(f.top+u,f.left+p)}return this.layoutBoxUpdate(f,t),this.layoutBox},e.getBoxState=function(t,e){return this.isBlock(t)||this.isBlock(e)},e.isBlock=function(t){return void 0===t&&(t=this),t&&t.style.display==rt},e.isFlex=function(t){return void 0===t&&(t=this),t&&t.style.display==at},e.isInFlow=function(){return!(this.isAbsolute||this.isFixed)},e.inFlexBox=function(t){return void 0===t&&(t=this),!!t.isInFlow()&&(!!t.parent&&(!(!t.parent||t.parent.style.display!==at)||void 0))},e.isInline=function(t){return void 0===t&&(t=this),t&&t.style.display==st},e.contrastSize=function(t,e,i){var n=t;return i&&(n=Math.min(n,i)),e&&(n=Math.max(n,e)),n},e.measureText=function(t,e){var i=this.ctx.measureText(t),n=i.width,o=i.actualBoundingBoxAscent,r=i.actualBoundingBoxDescent;return{ascent:o,descent:r,width:n,fontHeight:o+r||.7*e+1}},e.getBoxWidthHeight=function(){var t,e=this,i=this.name,n=this.computedStyle,o=this.attributes,r=this.parent,s=void 0===r?{}:r,a=this.ctx,h=this.getChildren(),d=n.left,c=void 0===d?0:d,l=n.top,f=void 0===l?0:l,u=n.bottom,p=n.right,g=n.width,v=void 0===g?0:g,y=n.minWidth,b=n.maxWidth,x=n.minHeight,m=n.maxHeight,w=n.height,S=void 0===w?0:w,z=n.fontSize,M=void 0===z?14:z,B=n.fontWeight,I=n.fontFamily,k=n.fontStyle,P=n.position,W=n.lineClamp,R=n.lineHeight,O=n.padding,T=void 0===O?{}:O,L=n.margin,A=void 0===L?{}:L,F=n.border,C=(F=void 0===F?{}:F).borderWidth,E=void 0===C?0:C,H=n.borderRight,U=(H=void 0===H?{}:H).borderRightWidth,Y=void 0===U?E:U,$=n.borderLeft,D=($=void 0===$?{}:$).borderLeftWidth,_=void 0===D?E:D,X=s.contentSize&&s.contentSize.width,N=s.contentSize&&s.contentSize.height;if(G(v)&&X&&(v=j(v,X)),G(v)&&!X&&(v=null),G(S)&&N&&(S=j(S,N)),G(S)&&!N&&(S=null),G(y)&&X&&(y=j(y,X)),G(b)&&X&&(b=j(b,X)),G(x)&&N&&(x=j(x,N)),G(m)&&N&&(m=j(m,N)),n.padding&&null!=(t=s.contentSize)&&t.width)for(var V in n.padding)Object.hasOwnProperty.call(n.padding,V)&&(n.padding[V]=j(n.padding[V],X));var q=T.paddingRight,J=void 0===q?0:q,Z=T.paddingLeft,tt=void 0===Z?0:Z;if(n.margin&&[n.margin.marginLeft,n.margin.marginRight].includes("auto"))if(v){var ot=X&&X-v-J-tt-_-Y||0;n.margin.marginLeft==n.margin.marginRight?n.margin.marginLeft=n.margin.marginRight=ot/2:"auto"==n.margin.marginLeft?n.margin.marginLeft=ot:n.margin.marginRight=ot}else n.margin.marginLeft=n.margin.marginRight=0;var rt=A.marginRight,st=void 0===rt?0:rt,at=A.marginLeft,dt={width:v,height:S,left:0,top:0},ct=tt+J+_+Y+(void 0===at?0:at)+st;if(i==it&&!this.attributes.widths){var lt=o.text||"";a.save(),a.setFonts({fontFamily:I,fontSize:M,fontWeight:B,fontStyle:k});var ft=new Map;lt.split("\n").map((function(t){var i=t.split("").map((function(t){var i=ft.get(t);if(i)return i;var n=e.measureText(t,M).width;return ft.set(t,n),n})),n=e.measureText(t,M),o=n.fontHeight,r=n.ascent,s=n.descent;e.attributes.fontHeight=o,e.attributes.ascent=r,e.attributes.descent=s,e.attributes.widths||(e.attributes.widths=[]),e.attributes.widths.push({widths:i,total:i.reduce((function(t,e){return t+e}),0)})})),a.restore()}if(i==et&&null==v){var ut=o.width,pt=o.height;dt.width=this.contrastSize(Math.round(ut*S/pt)||0,y,b),this.layoutBoxUpdate(dt,n,0)}if(i==it&&null==v){var gt=this.attributes.widths,vt=Math.max.apply(Math,gt.map((function(t){return t.total})));if(s&&X>0&&(vt>X||this.isBlock(this))&&!this.isAbsolute&&!this.isFixed)vt=X-ct;dt.width=this.contrastSize(vt,y,b),this.layoutBoxUpdate(dt,n,0)}if(i==it&&!this.attributes.lines){var yt=this.attributes.widths.length;this.attributes.widths.forEach((function(t){return t.widths.reduce((function(t,e,i){return t+e>dt.width?(yt++,e):t+e}),0)})),yt=W&&yt>W?W:yt,this.attributes.lines=yt}if(i==et&&null==S){var bt=o.width,xt=o.height;dt.height=this.contrastSize(j(dt.width*xt/bt)||0,x,m),this.layoutBoxUpdate(dt,n,1)}i==it&&null==S&&(R=j(R,M),dt.height=this.contrastSize(j(this.attributes.lines*R),x,m),this.layoutBoxUpdate(dt,n,1,!0)),s&&s.children&&X&&([nt,it].includes(i)&&this.isFlex()||i==nt&&this.isBlock(this)&&!this.isInFlow())&&(dt.width=this.contrastSize(X-ct,y,b),this.layoutBoxUpdate(dt,n)),v&&!G(v)&&(dt.width=this.contrastSize(v,y,b),this.layoutBoxUpdate(dt,n,0)),S&&!G(S)&&(dt.height=this.contrastSize(dt.height,x,m),this.layoutBoxUpdate(dt,n,1));var mt=0;if(h.length){var wt=null;h.forEach((function(t,i){t.getBoxWidthHeight();var o=h[i+1];if(o&&o.isInFlow()&&(t.next=o),t.isInFlow()&&!t.inFlexBox()){var r=e.getBoxState(wt,t);e.line&&e.line.canIEnter(t)&&!r?e.line.add(t):(new Q).bind(t),wt=t}else t.inFlexBox()?e.line&&(e.line.canIEnter(t)||"nowrap"==n.flexWrap)?e.line.add(t):(new K).bind(t):t.isFixed?e.root.fixedLine?e.root.fixedLine.fixedAdd(t):(new Q).fixedBind(t):e.fixedLine?e.fixedLine.fixedAdd(t):(new Q).fixedBind(t,1)})),this.lines&&(mt=this.lines.reduce((function(t,e){return t+e.height}),0))}var St=0,zt=0;if(!v&&(this.isAbsolute||this.isFixed)&&X){var Mt=P==ht?X:this.root.width,Bt=Mt-(G(c)?j(c,Mt):c)-(G(p)?j(p,Mt):p);St=n.left?Bt:this.lineMaxWidth}if(!S&&(null!=f?f:this.isAbsolute||this.isFixed&&N)){var It=P==ht?N:this.root.height,kt=It-(G(f)?j(f,It):f)-(G(u)?j(u,It):u);zt=n.top?kt:0}if(v&&!G(v)||dt.width||(dt.width=St||this.contrastSize((this.isBlock(this)&&!this.isInFlow()?X||s.lineMaxWidth:this.lineMaxWidth)||this.lineMaxWidth,y,b),this.layoutBoxUpdate(dt,n,0)),S||!mt&&!zt||(dt.height=zt||this.contrastSize(mt,x,m),this.layoutBoxUpdate(dt,n)),n.borderRadius&&this.borderSize&&this.borderSize.width)for(var V in n.borderRadius)Object.hasOwnProperty.call(n.borderRadius,V)&&(n.borderRadius[V]=j(n.borderRadius[V],this.borderSize.width));return this.layoutBox},e.layout=function(){return this.getBoxWidthHeight(),this.root.offsetSize=this.offsetSize,this.getBoxPosition2(),this.offsetSize},t}(),ut=function(){var t,e,i,n,o,r,s=[0,11,15,19,23,27,31,16,18,20,22,24,26,28,20,22,24,24,26,28,28,22,24,24,26,26,28,28,24,24,26,26,26,28,28,24,26,26,26,28,28],a=[3220,1468,2713,1235,3062,1890,2119,1549,2344,2936,1117,2583,1330,2470,1667,2249,2028,3780,481,4011,142,3098,831,3445,592,2517,1776,2234,1951,2827,1070,2660,1345,3177],h=[30660,29427,32170,30877,26159,25368,27713,26998,21522,20773,24188,23371,17913,16590,20375,19104,13663,12392,16177,14854,9396,8579,11994,11245,5769,5054,7399,6608,1890,597,3340,2107],d=[1,0,19,7,1,0,16,10,1,0,13,13,1,0,9,17,1,0,34,10,1,0,28,16,1,0,22,22,1,0,16,28,1,0,55,15,1,0,44,26,2,0,17,18,2,0,13,22,1,0,80,20,2,0,32,18,2,0,24,26,4,0,9,16,1,0,108,26,2,0,43,24,2,2,15,18,2,2,11,22,2,0,68,18,4,0,27,16,4,0,19,24,4,0,15,28,2,0,78,20,4,0,31,18,2,4,14,18,4,1,13,26,2,0,97,24,2,2,38,22,4,2,18,22,4,2,14,26,2,0,116,30,3,2,36,22,4,4,16,20,4,4,12,24,2,2,68,18,4,1,43,26,6,2,19,24,6,2,15,28,4,0,81,20,1,4,50,30,4,4,22,28,3,8,12,24,2,2,92,24,6,2,36,22,4,6,20,26,7,4,14,28,4,0,107,26,8,1,37,22,8,4,20,24,12,4,11,22,3,1,115,30,4,5,40,24,11,5,16,20,11,5,12,24,5,1,87,22,5,5,41,24,5,7,24,30,11,7,12,24,5,1,98,24,7,3,45,28,15,2,19,24,3,13,15,30,1,5,107,28,10,1,46,28,1,15,22,28,2,17,14,28,5,1,120,30,9,4,43,26,17,1,22,28,2,19,14,28,3,4,113,28,3,11,44,26,17,4,21,26,9,16,13,26,3,5,107,28,3,13,41,26,15,5,24,30,15,10,15,28,4,4,116,28,17,0,42,26,17,6,22,28,19,6,16,30,2,7,111,28,17,0,46,28,7,16,24,30,34,0,13,24,4,5,121,30,4,14,47,28,11,14,24,30,16,14,15,30,6,4,117,30,6,14,45,28,11,16,24,30,30,2,16,30,8,4,106,26,8,13,47,28,7,22,24,30,22,13,15,30,10,2,114,28,19,4,46,28,28,6,22,28,33,4,16,30,8,4,122,30,22,3,45,28,8,26,23,30,12,28,15,30,3,10,117,30,3,23,45,28,4,31,24,30,11,31,15,30,7,7,116,30,21,7,45,28,1,37,23,30,19,26,15,30,5,10,115,30,19,10,47,28,15,25,24,30,23,25,15,30,13,3,115,30,2,29,46,28,42,1,24,30,23,28,15,30,17,0,115,30,10,23,46,28,10,35,24,30,19,35,15,30,17,1,115,30,14,21,46,28,29,19,24,30,11,46,15,30,13,6,115,30,14,23,46,28,44,7,24,30,59,1,16,30,12,7,121,30,12,26,47,28,39,14,24,30,22,41,15,30,6,14,121,30,6,34,47,28,46,10,24,30,2,64,15,30,17,4,122,30,29,14,46,28,49,10,24,30,24,46,15,30,4,18,122,30,13,32,46,28,48,14,24,30,42,32,15,30,20,4,117,30,40,7,47,28,43,22,24,30,10,67,15,30,19,6,118,30,18,31,47,28,34,34,24,30,20,61,15,30],c=[255,0,1,25,2,50,26,198,3,223,51,238,27,104,199,75,4,100,224,14,52,141,239,129,28,193,105,248,200,8,76,113,5,138,101,47,225,36,15,33,53,147,142,218,240,18,130,69,29,181,194,125,106,39,249,185,201,154,9,120,77,228,114,166,6,191,139,98,102,221,48,253,226,152,37,179,16,145,34,136,54,208,148,206,143,150,219,189,241,210,19,92,131,56,70,64,30,66,182,163,195,72,126,110,107,58,40,84,250,133,186,61,202,94,155,159,10,21,121,43,78,212,229,172,115,243,167,87,7,112,192,247,140,128,99,13,103,74,222,237,49,197,254,24,227,165,153,119,38,184,180,124,17,68,146,217,35,32,137,46,55,63,209,91,149,188,207,205,144,135,151,178,220,252,190,97,242,86,211,171,20,42,93,158,132,60,57,83,71,109,65,162,31,45,67,216,183,123,164,118,196,23,73,236,127,12,111,246,108,161,59,82,41,157,85,170,251,96,134,177,187,204,62,90,203,89,95,176,156,169,160,81,11,245,22,235,122,117,44,215,79,174,213,233,230,231,173,232,116,214,244,234,168,80,88,175],l=[1,2,4,8,16,32,64,128,29,58,116,232,205,135,19,38,76,152,45,90,180,117,234,201,143,3,6,12,24,48,96,192,157,39,78,156,37,74,148,53,106,212,181,119,238,193,159,35,70,140,5,10,20,40,80,160,93,186,105,210,185,111,222,161,95,190,97,194,153,47,94,188,101,202,137,15,30,60,120,240,253,231,211,187,107,214,177,127,254,225,223,163,91,182,113,226,217,175,67,134,17,34,68,136,13,26,52,104,208,189,103,206,129,31,62,124,248,237,199,147,59,118,236,197,151,51,102,204,133,23,46,92,184,109,218,169,79,158,33,66,132,21,42,84,168,77,154,41,82,164,85,170,73,146,57,114,228,213,183,115,230,209,191,99,198,145,63,126,252,229,215,179,123,246,241,255,227,219,171,75,150,49,98,196,149,55,110,220,165,87,174,65,130,25,50,100,200,141,7,14,28,56,112,224,221,167,83,166,81,162,89,178,121,242,249,239,195,155,43,86,172,69,138,9,18,36,72,144,61,122,244,245,247,243,251,235,203,139,11,22,44,88,176,125,250,233,207,131,27,54,108,216,173,71,142,0],f=[],u=[],p=[],g=[],v=[],y=2;function b(t,e){var i;t>e&&(i=t,t=e,e=i),i=e,i*=e,i+=e,i>>=1,g[i+=t]=1}function x(t,i){var n;for(p[t+e*i]=1,n=-2;n<2;n++)p[t+n+e*(i-2)]=1,p[t-2+e*(i+n+1)]=1,p[t+2+e*(i+n)]=1,p[t+n+1+e*(i+2)]=1;for(n=0;n<2;n++)b(t-1,i+n),b(t+1,i-n),b(t-n,i-1),b(t+n,i+1)}function m(t){for(;t>=255;)t=((t-=255)>>8)+(255&t);return t}var w=[];function S(t,e,i,n){var o,r,s;for(o=0;o e&&(i=t,t=e,e=i),i=e,i+=e*e,i>>=1,g[i+=t]}function M(t){var i,n,o,r;switch(t){case 0:for(n=0;n >1&1,i=0;i =5&&(i+=3+v[e]-5);for(e=3;e t||3*v[e-3]>=4*v[e]||3*v[e+3]>=4*v[e])&&(i+=40);return i}function I(){var t,i,n,o,r,s=0,a=0;for(i=0;i e*e;)h-=e*e,d++;for(s+=10*d,t=0;t 1)for(W=s[t],k=e-7;;){for(B=e-7;B>W-3&&(x(B,k),!(B 6)for(W=a[t-7],P=17,B=0;B<6;B++)for(k=0;k<3;k++,P--)1&(P>11?t>>P-12:W>>P)?(p[5-B+e*(2-k+e-11)]=1,p[2-k+e-11+e*(5-B)]=1):(b(5-B,2-k+e-11),b(2-k+e-11,5-B));for(k=0;k =(B=o*(i+n)+n)-2&&(R=B-2,t>9&&R--),O=R,t>9){for(f[O+2]=0,f[O+3]=0;O--;)W=f[O],f[O+3]|=255&W<<4,f[O+2]=W>>4;f[2]|=255&R<<4,f[1]=R>>4,f[0]=64|R>>12}else{for(f[O+1]=0,f[O+2]=0;O--;)W=f[O],f[O+2]|=255&W<<4,f[O+1]=W>>4;f[1]|=255&R<<4,f[0]=64|R>>4}for(O=R+3-(t<10);O0;T--)w[T]=w[T]?w[T-1]^l[m(c[w[T]]+O)]:w[T-1];w[0]=l[m(c[w[0]]+O)]}for(O=0;O<=r;O++)w[O]=c[w[O]];for(P=B,k=0,O=0;O>=1)1&k&&(p[e-1-P+8*e]=1,P<6?p[8+e*P]=1:p[8+e*(P+1)]=1);for(P=0;P<7;P++,k>>=1)1&k&&(p[8+e*(e-7+P)]=1,P?p[6-P+8*e]=1:p[7+8*e]=1);return p}(v)},utf16to8:function(t){var e,i,n,o;for(e="",n=t.length,i=0;i =1&&o<=127?e+=t.charAt(i):o>2047?(e+=String.fromCharCode(224|o>>12&15),e+=String.fromCharCode(128|o>>6&63),e+=String.fromCharCode(128|o>>0&63)):(e+=String.fromCharCode(192|o>>6&31),e+=String.fromCharCode(128|o>>0&63));return e},draw:function(t,i,n,o,r){i.drawView(n,o);var s=i.ctx,a=n.contentSize,h=a.width,d=a.height,c=a.left,l=a.top;o.borderRadius,o.backgroundColor;var f=o.color,u=void 0===f?"#000000":f;o.border,n.contentSize.left,n.borderSize.left,n.contentSize.top,n.borderSize.top;if(y=r||y,s){s.save(),i.setOpacity(o),i.setTransform(n,o);var p=Math.min(h,d);t=this.utf16to8(t);var g=this.getFrame(t),v=p/e;s.setFillStyle(u);for(var b=0;b =s||"cover"==n&&r =s)&&(a=e.width/i.width);var h=i.width*a,d=i.height*a,c=o||[],l=c[0],f=c[1],u=/^\d+px|rpx$/.test(l)?j(l,e.width):(e.width-h)*(C(l)?j(l,1):{left:0,center:.5,right:1}[l||"center"]),p=/^\d+px|rpx$/.test(f)?j(f,e.height):(e.height-d)*(C(f)?j(f,1):{top:0,center:.5,bottom:1}[f||"center"]),g=function(t,e){return[(t-u)/a,(e-p)/a]},v=g(0,0),y=v[0],b=v[1],x=g(e.width,e.height),m=x[0],w=x[1];return{sx:Math.max(y,0),sy:Math.max(b,0),sw:Math.min(m-y,i.width),sh:Math.min(w-b,i.height),dx:Math.max(u,0),dy:Math.max(p,0),dw:Math.min(h,e.width),dh:Math.min(d,e.height)}}({objectFit:u,objectPosition:v},e.contentSize,t),o=n.sx,r=n.sy,a=n.sh,h=n.sw,d=n.dx,c=n.dy,l=n.dh,f=n.dw;T==s.MP_BAIDU?i.drawImage(t.src,d+w,c+S,f,l,o,r,h,a):i.drawImage(t.src,o,r,h,a,d+w,c+S,f,l)}else i.drawImage(t.src,w,S,x,m)},P=function(){i.restore(),R.drawView(e,o,!1,!0,!1),h(1)},W=function(t){B(t),P()},W(t),[2]}))}))}))];case 1:return h.sent(),[2]}}))}))},t.prototype.drawText=function(t,e,i,n){var o=this.ctx,r=e.borderSize,s=e.contentSize,a=e.left,h=e.top,d=s.width,c=s.height,l=s.left-r.left,f=s.top-r.top,u=i.color,p=void 0===u?"#000000":u,g=i.lineHeight,v=void 0===g?"1.4em":g,y=i.fontSize,b=void 0===y?14:y,x=i.fontWeight,m=i.fontFamily,w=i.fontStyle,S=i.textAlign,z=void 0===S?"left":S,M=i.verticalAlign,B=void 0===M?xt:M,I=i.backgroundColor,k=i.lineClamp,P=i.backgroundClip,W=i.textShadow,R=i.textDecoration;if(this.drawView(e,i,P!=gt),v=j(v,b),t){switch(o.save(),this.setShadow({boxShadow:W}),a+=l,h+=f,o.setFonts({fontFamily:m,fontSize:b,fontWeight:x,fontStyle:w}),o.setTextBaseline(xt),o.setTextAlign(z),P?this.setBackground(I,d,c,a,h):o.setFillStyle(p),z){case wt:break;case St:a+=.5*d;break;case zt:a+=d}var O=n.lines*v,T=Math.ceil((c-O)/2);switch(T<0&&(T=0),B){case bt:break;case xt:h+=T;break;case mt:h+=2*T}var L=n.fontHeight,A=n.descent,F=(v-L)/2,C=function(t){var e=o.measureText(t),i=e.actualBoundingBoxDescent,n=void 0===i?0:i,r=e.actualBoundingBoxAscent,s=void 0===r?0:r,a=n+s||.7*b+1;return B==bt?{fix:s,height:a,lineY:v-a}:B==xt?{fix:v/2+n/4,height:a,lineY:(v-a)/2}:B==mt?{fix:v-n,height:a,lineY:0}:{fix:0,height:0,lineY:0}},E=function(t,e,i){var r=t;switch(z){case wt:r+=i;break;case St:r=(t-=i/2)+i;break;case zt:r=t,t-=i}if(R){o.setLineWidth(b/13),o.beginPath();var s=.1*n.fontHeight;/\bunderline\b/.test(R)&&(A||(e+=F/2),o.moveTo(t,e+s),o.lineTo(r,e+s)),/\boverline\b/.test(R)&&(A||(e-=F/2),o.moveTo(t,e-n.fontHeight-s),o.lineTo(r,e-n.fontHeight-s)),/\bline-through\b/.test(R)&&(o.moveTo(t,e-.5*n.fontHeight),o.lineTo(r,e-.5*n.fontHeight)),o.closePath(),o.setStrokeStyle(p),o.stroke()}};if(!n.widths||1==n.widths.length&&n.widths[0].total<=s.width){var H=C(t),U=H.fix,Y=H.lineY;return o.fillText(t,a,h+U),E(a,(h+=v)-Y,n&&n.widths&&n.widths[0].total||n.text),o.restore(),void this.setBorder(e,i)}for(var $=t.split(""),D=h,_=a,X="",N=0,V=0;V<=$.length;V++){var G=$[V]||"",q="\n"===G,J=""==G,Q=X+(G=q?"":G),Z=o.measureText(Q).width;if(N>=k)break;if(_=a,Z>s.width||q||J){if(N++,X=J&&Z<=s.width?Q:X,N===k&&Z>d){for(;o.measureText("".concat(X,"...")).width>s.width&&!(X.length<=1);)X=X.substring(0,X.length-1);X+="..."}var K=C(X);U=K.fix,Y=K.lineY;if(o.fillText(X,_,h+U),E(_,(h+=v)-Y,Z),X=G,h>D+c)break}else X=Q}o.restore()}},t.prototype.source=function(t){var e;return i(this,void 0,void 0,(function(){var i,o,r,s=this;return n(this,(function(n){switch(n.label){case 0:if(this.node=null,i=+new Date,"{}"==JSON.stringify(t))return[2];if(!t.type)for(o in t.type=yt,t.css=t.css||{},t)["views","children","type","css"].includes(o)||(t.css[o]=t[o],delete t[o]);return(null===(e=t.css)||void 0===e?void 0:e.width)||t.css||(t.css={}),[4,this.create(t)];case 1:return r=n.sent(),this.size=(null==r?void 0:r.layout())||{},this.node=r,this.onEffectFinished().then((function(t){return s.lifecycle("onEffectSuccess",t)})).catch((function(t){return s.lifecycle("onEffectFail",t)})),console.log("布局用时:"+(+new Date-i)+"ms"),[2,this.size]}}))}))},t.prototype.getImageInfo=function(t){return this.imageBus[t]||(this.imageBus[t]=this.createImage(t,this.useCORS)),this.imageBus[t]},t.prototype.create=function(t,o){var r,s;return i(this,void 0,void 0,(function(){var i,a,h,d,c,l,f,u,p,g,v,y,b,x,m,w,z;return n(this,(function(n){switch(n.label){case 0:if(i=t.type==pt,a=[gt,vt].includes(t.type),h=t.css||{},d=h.backgroundImage,c=h.display,i&&!t.src&&!t.url||a&&!t.text)return[2];if(c==S)return[2];if(a&&(t.text=String(t.text)),!(i||t.type==yt&&d))return[3,4];l=i?t.src:"",f=/url\((.+)\)/,d&&(null===(r=f.exec(d))||void 0===r?void 0:r[1])&&(l=(null===(s=f.exec(d))||void 0===s?void 0:s[1])||""),n.label=1;case 1:return n.trys.push([1,3,,4]),[4,this.getImageInfo(l)];case 2:return u=n.sent(),p=u.width,g=u.height,!(v=u.path)&&i?[2]:(v&&(t.attributes=Object.assign(t.attributes||{},{width:p,height:g,path:v,src:v,naturalSrc:l})),[3,4]);case 3:return y=n.sent(),t.type!=yt?[2]:(this.lifecycle("onEffectFail",e(e({},y),{src:l})),[3,4]);case 4:if(this.count+=1,b=new ft(t,o,this.root,this.ctx),!(x=t.views||t.children))return[3,8];m=0,n.label=5;case 5:return m0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("navigateTo",{url:encodeURI(n)})},navigateBack:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.delta;r("navigateBack",{delta:parseInt(n)||1})},switchTab:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("switchTab",{url:encodeURI(n)})},reLaunch:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("reLaunch",{url:encodeURI(n)})},redirectTo:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=e.url;r("redirectTo",{url:encodeURI(n)})},getEnv:function(e){o()?e({nvue:!0}):window.plus?e({plus:!0}):e({h5:!0})},postMessage:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};r("postMessage",e.data||{})}},d=/uni-app/i.test(navigator.userAgent),s=/Html5Plus/i.test(navigator.userAgent),w=/complete|loaded|interactive/;var u=window.my&&navigator.userAgent.indexOf("AlipayClient")>-1;var g=window.swan&&window.swan.webView&&/swan/i.test(navigator.userAgent);var c=window.qq&&window.qq.miniProgram&&/QQ/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);var v=window.tt&&window.tt.miniProgram&&/toutiaomicroapp/i.test(navigator.userAgent);var m=window.wx&&window.wx.miniProgram&&/micromessenger/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);var p=window.qa&&/quickapp/i.test(navigator.userAgent);var f=window.ks&&window.ks.miniProgram&&/micromessenger/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);var l=window.tt&&window.tt.miniProgram&&/Lark|Feishu/i.test(navigator.userAgent);var _=window.jd&&window.jd.miniProgram&&/micromessenger/i.test(navigator.userAgent)&&/miniProgram/i.test(navigator.userAgent);for(var E,b=function(){window.UniAppJSBridge=!0,document.dispatchEvent(new CustomEvent("UniAppJSBridgeReady",{bubbles:!0,cancelable:!0}))},h=[function(e){if(d||s)return window.__dcloud_weex_postMessage||window.__dcloud_weex_?document.addEventListener("DOMContentLoaded",e):window.plus&&w.test(document.readyState)?setTimeout(e,0):document.addEventListener("plusready",e),a},function(e){if(m)return window.WeixinJSBridge&&window.WeixinJSBridge.invoke?setTimeout(e,0):document.addEventListener("WeixinJSBridgeReady",e),window.wx.miniProgram},function(e){if(c)return window.QQJSBridge&&window.QQJSBridge.invoke?setTimeout(e,0):document.addEventListener("QQJSBridgeReady",e),window.qq.miniProgram},function(e){if(u){document.addEventListener("DOMContentLoaded",e);var n=window.my;return{navigateTo:n.navigateTo,navigateBack:n.navigateBack,switchTab:n.switchTab,reLaunch:n.reLaunch,redirectTo:n.redirectTo,postMessage:n.postMessage,getEnv:n.getEnv}}},function(e){if(g)return document.addEventListener("DOMContentLoaded",e),window.swan.webView},function(e){if(v)return document.addEventListener("DOMContentLoaded",e),window.tt.miniProgram},function(e){if(p){window.QaJSBridge&&window.QaJSBridge.invoke?setTimeout(e,0):document.addEventListener("QaJSBridgeReady",e);var n=window.qa;return{navigateTo:n.navigateTo,navigateBack:n.navigateBack,switchTab:n.switchTab,reLaunch:n.reLaunch,redirectTo:n.redirectTo,postMessage:n.postMessage,getEnv:n.getEnv}}},function(e){if(f)return window.WeixinJSBridge&&window.WeixinJSBridge.invoke?setTimeout(e,0):document.addEventListener("WeixinJSBridgeReady",e),window.ks.miniProgram},function(e){if(l)return document.addEventListener("DOMContentLoaded",e),window.tt.miniProgram},function(e){if(_)return window.JDJSBridgeReady&&window.JDJSBridgeReady.invoke?setTimeout(e,0):document.addEventListener("JDJSBridgeReady",e),window.jd.miniProgram},function(e){return document.addEventListener("DOMContentLoaded",e),a}],y=0;y + + + + + + \ No newline at end of file diff --git a/uni_modules/mumu-recorder/package.json b/uni_modules/mumu-recorder/package.json new file mode 100644 index 0000000..00d5e90 --- /dev/null +++ b/uni_modules/mumu-recorder/package.json @@ -0,0 +1,87 @@ +{ + "id": "mumu-recorder", + "displayName": "h5录音组件,调用H5原生功能使用麦克风进行录音", + "version": "1.0.1", + "description": "演示案例中模仿了微信的长按发送语音,与普通录音demo。", + "keywords": [ + "录音", + "麦克风", + "模仿微信" +], + "repository": "", + "engines": { + "HBuilderX": "^3.1.0" + }, + "dcloudext": { + "category": [ + "前端组件", + "通用组件" + ], + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "无", + "permissions": "麦克风" + }, + "npmurl": "" + }, + "uni_modules": { + "dependencies": [], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y" + }, + "client": { + "Vue": { + "vue2": "y", + "vue3": "y" + }, + "App": { + "app-vue": "n", + "app-nvue": "n" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "n", + "Edge": "y", + "Firefox": "y", + "Safari": "y" + }, + "小程序": { + "微信": "u", + "阿里": "u", + "百度": "u", + "字节跳动": "u", + "QQ": "u", + "钉钉": "u", + "快手": "u", + "飞书": "u", + "京东": "u", + "小红书": "u" + }, + "快应用": { + "华为": "u", + "联盟": "u" + } + } + } + } +} \ No newline at end of file diff --git a/uni_modules/mumu-recorder/readme.md b/uni_modules/mumu-recorder/readme.md new file mode 100644 index 0000000..1f888e5 --- /dev/null +++ b/uni_modules/mumu-recorder/readme.md @@ -0,0 +1,117 @@ +## 插件简绍 + +### 实现原理 + +> 通过 navigator.mediaDevices.getUserMedia(需要https环境) 这个api调用麦克风,获取到到音频流数据。 +> +> 通过 MediaRecorder 这个构造函数对音频流进行接收,完成录制后会返回一个存储`Blob`内容的录制数据。 + + +### 使用环境 + +需要https环境才能使用,本地测试可以在 manifest.json 中点击源码展示,找到h5 ,添加:"devServer" : { "https" : true} + +**请勿使用 UC浏览器 与 夸克等阿里旗下的浏览器,发现他们使用的内核都较低,无法正常获取音频流,并且都有对接音频流截取的插件,导致无法正常获取音频流的数据。在微信中可以正常使用,推荐在微信内打开演示案例 ** + +需要https环境才能使用!!! + +需要https环境才能使用!!! + +需要https环境才能使用!!! + +### 插件使用 + +**插件已支持 uni_modules 支持组件easycom,以下代码演示的是普通使用** + +``` html + ++ + +``` + +``` javascript +// js + import MumuRecorder from '@/uni_modules/mumu-recorder/components/mumu-recorder/mumu-recorder.vue' + export default { + components: { MumuRecorder }, + data() { + return { + status: false, + recorder: null + } + }, + onLoad() { + + }, + methods: { + handlerSave() { + let tag = document.createElement('a') + tag.href = this.recorder.localUrl + tag.download = '录音' + tag.click() + }, + handlerOnCahnger() { + if (this.status) { + this.$refs.recorder.stop() + } else { + this.$refs.recorder.start() + } + this.status = !this.status + }, + handlerSuccess(res) { + console.log(res) + this.recorder = res + }, + handlerError(code) { + switch (code) { + case '101': + uni.showModal({ + content: '当前浏览器版本较低,请更换浏览器使用,推荐在微信中打开。' + }) + break; + case '201': + uni.showModal({ + content: '麦克风权限被拒绝,请刷新页面后授权麦克风权限。' + }) + break + default: + uni.showModal({ + content: '未知错误,请刷新页面重试' + }) + break + } + } + } + } +``` + +### 相关API + +##### 组件内部方法($refs 调用) + +| 方法名 | 说明 | 参数 | +| ------ | -------- | ---- | +| start | 开始录音 | 无 | +| stop | 结束录音 | 无 | + + + +##### 事件(Events) + +| 事件名 | 说明 | 回调参数 | +| ------- | -------------------- | ------------------------------------------------------------ | +| success | 停止录音后调用此事件 | 返回录音数据,是一个对象+ {{!status?'开始录音':'结束录音'}} + ++
{ data: 音频的 blob 数据,上传请使用这个
duration: 当前音频长度
localUrl: 当前音频的本地链接,可直接通过 audio 标签进行播放 } | +| error | 组件内部发生错误 | 错误码:<100 当前不是https环境> <101 浏览器不支持> <201 麦克风权限被拒绝> <500 未知错误> | + +### 案例演示 + +![enter description here](https://h5plugin.mumudev.top/public/recorder/qrcode.png) + +## 支持作者 + +![支持作者](https://student.mumudev.top/wxMP.jpg) \ No newline at end of file diff --git a/uni_modules/uni-popup/changelog.md b/uni_modules/uni-popup/changelog.md new file mode 100644 index 0000000..b4bfd61 --- /dev/null +++ b/uni_modules/uni-popup/changelog.md @@ -0,0 +1,78 @@ +## 1.8.8(2024-02-20) +- 修复 uni-popup 在微信小程序下出现文字向上闪动的bug +## 1.8.7(2024-02-02) +- 新增 uni-popup-dialog 新增属性focus:input模式下,是否自动自动聚焦 +## 1.8.6(2024-01-30) +- 新增 uni-popup-dialog 新增属性maxLength:限制输入框字数 +## 1.8.5(2024-01-26) +- 新增 uni-popup-dialog 新增属性showClose:控制关闭按钮的显示 +## 1.8.4(2023-11-15) +- 新增 uni-popup 支持uni-app-x 注意暂时仅支持 `maskClick` `@open` `@close` +## 1.8.3(2023-04-17) +- 修复 uni-popup 重复打开时的 bug +## 1.8.2(2023-02-02) +- uni-popup-dialog 组件新增 inputType 属性 +## 1.8.1(2022-12-01) +- 修复 nvue 下 v-show 报错 +## 1.8.0(2022-11-29) +- 优化 主题样式 +## 1.7.9(2022-04-02) +- 修复 弹出层内部无法滚动的bug +## 1.7.8(2022-03-28) +- 修复 小程序中高度错误的bug +## 1.7.7(2022-03-17) +- 修复 快速调用open出现问题的Bug +## 1.7.6(2022-02-14) +- 修复 safeArea 属性不能设置为false的bug +## 1.7.5(2022-01-19) +- 修复 isMaskClick 失效的bug +## 1.7.4(2022-01-19) +- 新增 cancelText \ confirmText 属性 ,可自定义文本 +- 新增 maskBackgroundColor 属性 ,可以修改蒙版颜色 +- 优化 maskClick属性 更新为 isMaskClick ,解决微信小程序警告的问题 +## 1.7.3(2022-01-13) +- 修复 设置 safeArea 属性不生效的bug +## 1.7.2(2021-11-26) +- 优化 组件示例 +## 1.7.1(2021-11-26) +- 修复 vuedoc 文字错误 +## 1.7.0(2021-11-19) +- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) +- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-popup](https://uniapp.dcloud.io/component/uniui/uni-popup) +## 1.6.2(2021-08-24) +- 新增 支持国际化 +## 1.6.1(2021-07-30) +- 优化 vue3下事件警告的问题 +## 1.6.0(2021-07-13) +- 组件兼容 vue3,如何创建vue3项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) +## 1.5.0(2021-06-23) +- 新增 mask-click 遮罩层点击事件 +## 1.4.5(2021-06-22) +- 修复 nvue 平台中间弹出后,点击内容,再点击遮罩无法关闭的Bug +## 1.4.4(2021-06-18) +- 修复 H5平台中间弹出后,点击内容,再点击遮罩无法关闭的Bug +## 1.4.3(2021-06-08) +- 修复 错误的 watch 字段 +- 修复 safeArea 属性不生效的问题 +- 修复 点击内容,再点击遮罩无法关闭的Bug +## 1.4.2(2021-05-12) +- 新增 组件示例地址 +## 1.4.1(2021-04-29) +- 修复 组件内放置 input 、textarea 组件,无法聚焦的问题 +## 1.4.0 (2021-04-29) +- 新增 type 属性的 left\right 值,支持左右弹出 +- 新增 open(String:type) 方法参数 ,可以省略 type 属性 ,直接传入类型打开指定弹窗 +- 新增 backgroundColor 属性,可定义主窗口背景色,默认不显示背景色 +- 新增 safeArea 属性,是否适配底部安全区 +- 修复 App\h5\微信小程序底部安全区占位不对的Bug +- 修复 App 端弹出等待的Bug +- 优化 提升低配设备性能,优化动画卡顿问题 +- 优化 更简单的组件自定义方式 +## 1.2.9(2021-02-05) +- 优化 组件引用关系,通过uni_modules引用组件 +## 1.2.8(2021-02-05) +- 调整为uni_modules目录规范 +## 1.2.7(2021-02-05) +- 调整为uni_modules目录规范 +- 新增 支持 PC 端 +- 新增 uni-popup-message 、uni-popup-dialog扩展组件支持 PC 端 diff --git a/uni_modules/uni-popup/components/uni-popup-dialog/keypress.js b/uni_modules/uni-popup/components/uni-popup-dialog/keypress.js new file mode 100644 index 0000000..6ef26a2 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup-dialog/keypress.js @@ -0,0 +1,45 @@ +// #ifdef H5 +export default { + name: 'Keypress', + props: { + disable: { + type: Boolean, + default: false + } + }, + mounted () { + const keyNames = { + esc: ['Esc', 'Escape'], + tab: 'Tab', + enter: 'Enter', + space: [' ', 'Spacebar'], + up: ['Up', 'ArrowUp'], + left: ['Left', 'ArrowLeft'], + right: ['Right', 'ArrowRight'], + down: ['Down', 'ArrowDown'], + delete: ['Backspace', 'Delete', 'Del'] + } + const listener = ($event) => { + if (this.disable) { + return + } + const keyName = Object.keys(keyNames).find(key => { + const keyName = $event.key + const value = keyNames[key] + return value === keyName || (Array.isArray(value) && value.includes(keyName)) + }) + if (keyName) { + // 避免和其他按键事件冲突 + setTimeout(() => { + this.$emit(keyName, {}) + }, 0) + } + } + document.addEventListener('keyup', listener) + this.$once('hook:beforeDestroy', () => { + document.removeEventListener('keyup', listener) + }) + }, + render: () => {} +} +// #endif diff --git a/uni_modules/uni-popup/components/uni-popup-dialog/uni-popup-dialog.vue b/uni_modules/uni-popup/components/uni-popup-dialog/uni-popup-dialog.vue new file mode 100644 index 0000000..68a1ce2 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup-dialog/uni-popup-dialog.vue @@ -0,0 +1,294 @@ + ++ + + + + + diff --git a/uni_modules/uni-popup/components/uni-popup-message/uni-popup-message.vue b/uni_modules/uni-popup/components/uni-popup-message/uni-popup-message.vue new file mode 100644 index 0000000..91370a8 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup-message/uni-popup-message.vue @@ -0,0 +1,143 @@ + + + + + + diff --git a/uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue b/uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue new file mode 100644 index 0000000..f7e667c --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup-share/uni-popup-share.vue @@ -0,0 +1,187 @@ + ++ +{{titleText}} ++ ++ +{{content}} ++ ++ + ++ + ++ +{{closeText}} ++ +{{okText}} ++ + + + + diff --git a/uni_modules/uni-popup/components/uni-popup/i18n/en.json b/uni_modules/uni-popup/components/uni-popup/i18n/en.json new file mode 100644 index 0000000..7f1bd06 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/i18n/en.json @@ -0,0 +1,7 @@ +{ + "uni-popup.cancel": "cancel", + "uni-popup.ok": "ok", + "uni-popup.placeholder": "pleace enter", + "uni-popup.title": "Hint", + "uni-popup.shareTitle": "Share to" +} diff --git a/uni_modules/uni-popup/components/uni-popup/i18n/index.js b/uni_modules/uni-popup/components/uni-popup/i18n/index.js new file mode 100644 index 0000000..de7509c --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/i18n/index.js @@ -0,0 +1,8 @@ +import en from './en.json' +import zhHans from './zh-Hans.json' +import zhHant from './zh-Hant.json' +export default { + en, + 'zh-Hans': zhHans, + 'zh-Hant': zhHant +} diff --git a/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json b/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json new file mode 100644 index 0000000..5e3003c --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hans.json @@ -0,0 +1,7 @@ +{ + "uni-popup.cancel": "取消", + "uni-popup.ok": "确定", + "uni-popup.placeholder": "请输入", + "uni-popup.title": "提示", + "uni-popup.shareTitle": "分享到" +} diff --git a/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hant.json b/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hant.json new file mode 100644 index 0000000..13e39eb --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/i18n/zh-Hant.json @@ -0,0 +1,7 @@ +{ + "uni-popup.cancel": "取消", + "uni-popup.ok": "確定", + "uni-popup.placeholder": "請輸入", + "uni-popup.title": "提示", + "uni-popup.shareTitle": "分享到" +} diff --git a/uni_modules/uni-popup/components/uni-popup/keypress.js b/uni_modules/uni-popup/components/uni-popup/keypress.js new file mode 100644 index 0000000..62dda46 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/keypress.js @@ -0,0 +1,45 @@ +// #ifdef H5 +export default { + name: 'Keypress', + props: { + disable: { + type: Boolean, + default: false + } + }, + mounted () { + const keyNames = { + esc: ['Esc', 'Escape'], + tab: 'Tab', + enter: 'Enter', + space: [' ', 'Spacebar'], + up: ['Up', 'ArrowUp'], + left: ['Left', 'ArrowLeft'], + right: ['Right', 'ArrowRight'], + down: ['Down', 'ArrowDown'], + delete: ['Backspace', 'Delete', 'Del'] + } + const listener = ($event) => { + if (this.disable) { + return + } + const keyName = Object.keys(keyNames).find(key => { + const keyName = $event.key + const value = keyNames[key] + return value === keyName || (Array.isArray(value) && value.includes(keyName)) + }) + if (keyName) { + // 避免和其他按键事件冲突 + setTimeout(() => { + this.$emit(keyName, {}) + }, 0) + } + } + document.addEventListener('keyup', listener) + // this.$once('hook:beforeDestroy', () => { + // document.removeEventListener('keyup', listener) + // }) + }, + render: () => {} +} +// #endif diff --git a/uni_modules/uni-popup/components/uni-popup/popup.js b/uni_modules/uni-popup/components/uni-popup/popup.js new file mode 100644 index 0000000..c4e5781 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/popup.js @@ -0,0 +1,26 @@ + +export default { + data() { + return { + + } + }, + created(){ + this.popup = this.getParent() + }, + methods:{ + /** + * 获取父元素实例 + */ + getParent(name = 'uniPopup') { + let parent = this.$parent; + let parentName = parent.$options.name; + while (parentName !== name) { + parent = parent.$parent; + if (!parent) return false + parentName = parent.$options.name; + } + return parent; + }, + } +} diff --git a/uni_modules/uni-popup/components/uni-popup/uni-popup.uvue b/uni_modules/uni-popup/components/uni-popup/uni-popup.uvue new file mode 100644 index 0000000..5eb8d5b --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/uni-popup.uvue @@ -0,0 +1,90 @@ + ++ {{shareTitleText}} + ++ ++ + ++ {{item.text}} ++ + ++ + + + + + \ No newline at end of file diff --git a/uni_modules/uni-popup/components/uni-popup/uni-popup.vue b/uni_modules/uni-popup/components/uni-popup/uni-popup.vue new file mode 100644 index 0000000..5d9e9d2 --- /dev/null +++ b/uni_modules/uni-popup/components/uni-popup/uni-popup.vue @@ -0,0 +1,479 @@ + ++ ++ + + + + + diff --git a/uni_modules/uni-popup/package.json b/uni_modules/uni-popup/package.json new file mode 100644 index 0000000..6427510 --- /dev/null +++ b/uni_modules/uni-popup/package.json @@ -0,0 +1,87 @@ +{ + "id": "uni-popup", + "displayName": "uni-popup 弹出层", + "version": "1.8.8", + "description": " Popup 组件,提供常用的弹层", + "keywords": [ + "uni-ui", + "弹出层", + "弹窗", + "popup", + "弹框" + ], + "repository": "https://github.com/dcloudio/uni-ui", + "engines": { + "HBuilderX": "" + }, + "directories": { + "example": "../../temps/example_temps" + }, + "dcloudext": { + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "无", + "permissions": "无" + }, + "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui", + "type": "component-vue" + }, + "uni_modules": { + "dependencies": [ + "uni-scss", + "uni-transition" + ], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y" + }, + "client": { + "App": { + "app-vue": "y", + "app-nvue": "y" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "y", + "Edge": "y", + "Firefox": "y", + "Safari": "y" + }, + "小程序": { + "微信": "y", + "阿里": "y", + "百度": "y", + "字节跳动": "y", + "QQ": "y" + }, + "快应用": { + "华为": "u", + "联盟": "u" + }, + "Vue": { + "vue2": "y", + "vue3": "y" + } + } + } + } +} diff --git a/uni_modules/uni-popup/readme.md b/uni_modules/uni-popup/readme.md new file mode 100644 index 0000000..fdad4b3 --- /dev/null +++ b/uni_modules/uni-popup/readme.md @@ -0,0 +1,17 @@ + + +## Popup 弹出层 +> **组件名:uni-popup** +> 代码块: `uPopup` +> 关联组件:`uni-transition` + + +弹出层组件,在应用中弹出一个消息提示窗口、提示框等 + +### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-popup) +#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 + + + + + diff --git a/uni_modules/uni-scss/changelog.md b/uni_modules/uni-scss/changelog.md new file mode 100644 index 0000000..b863bb0 --- /dev/null +++ b/uni_modules/uni-scss/changelog.md @@ -0,0 +1,8 @@ +## 1.0.3(2022-01-21) +- 优化 组件示例 +## 1.0.2(2021-11-22) +- 修复 / 符号在 vue 不同版本兼容问题引起的报错问题 +## 1.0.1(2021-11-22) +- 修复 vue3中scss语法兼容问题 +## 1.0.0(2021-11-18) +- init diff --git a/uni_modules/uni-scss/index.scss b/uni_modules/uni-scss/index.scss new file mode 100644 index 0000000..1744a5f --- /dev/null +++ b/uni_modules/uni-scss/index.scss @@ -0,0 +1 @@ +@import './styles/index.scss'; diff --git a/uni_modules/uni-scss/package.json b/uni_modules/uni-scss/package.json new file mode 100644 index 0000000..7cc0ccb --- /dev/null +++ b/uni_modules/uni-scss/package.json @@ -0,0 +1,82 @@ +{ + "id": "uni-scss", + "displayName": "uni-scss 辅助样式", + "version": "1.0.3", + "description": "uni-sass是uni-ui提供的一套全局样式 ,通过一些简单的类名和sass变量,实现简单的页面布局操作,比如颜色、边距、圆角等。", + "keywords": [ + "uni-scss", + "uni-ui", + "辅助样式" +], + "repository": "https://github.com/dcloudio/uni-ui", + "engines": { + "HBuilderX": "^3.1.0" + }, + "dcloudext": { + "category": [ + "JS SDK", + "通用 SDK" + ], + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "无", + "permissions": "无" + }, + "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui" + }, + "uni_modules": { + "dependencies": [], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y" + }, + "client": { + "App": { + "app-vue": "y", + "app-nvue": "u" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "y", + "Edge": "y", + "Firefox": "y", + "Safari": "y" + }, + "小程序": { + "微信": "y", + "阿里": "y", + "百度": "y", + "字节跳动": "y", + "QQ": "y" + }, + "快应用": { + "华为": "n", + "联盟": "n" + }, + "Vue": { + "vue2": "y", + "vue3": "y" + } + } + } + } +} diff --git a/uni_modules/uni-scss/readme.md b/uni_modules/uni-scss/readme.md new file mode 100644 index 0000000..b7d1c25 --- /dev/null +++ b/uni_modules/uni-scss/readme.md @@ -0,0 +1,4 @@ +`uni-sass` 是 `uni-ui`提供的一套全局样式 ,通过一些简单的类名和`sass`变量,实现简单的页面布局操作,比如颜色、边距、圆角等。 + +### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-sass) +#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/uni_modules/uni-scss/styles/index.scss b/uni_modules/uni-scss/styles/index.scss new file mode 100644 index 0000000..ffac4fe --- /dev/null +++ b/uni_modules/uni-scss/styles/index.scss @@ -0,0 +1,7 @@ +@import './setting/_variables.scss'; +@import './setting/_border.scss'; +@import './setting/_color.scss'; +@import './setting/_space.scss'; +@import './setting/_radius.scss'; +@import './setting/_text.scss'; +@import './setting/_styles.scss'; diff --git a/uni_modules/uni-scss/styles/setting/_border.scss b/uni_modules/uni-scss/styles/setting/_border.scss new file mode 100644 index 0000000..12a11c3 --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_border.scss @@ -0,0 +1,3 @@ +.uni-border { + border: 1px $uni-border-1 solid; +} \ No newline at end of file diff --git a/uni_modules/uni-scss/styles/setting/_color.scss b/uni_modules/uni-scss/styles/setting/_color.scss new file mode 100644 index 0000000..1ededd9 --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_color.scss @@ -0,0 +1,66 @@ + +// TODO 暂时不需要 class ,需要用户使用变量实现 ,如果使用类名其实并不推荐 +// @mixin get-styles($k,$c) { +// @if $k == size or $k == weight{ +// font-#{$k}:#{$c} +// }@else{ +// #{$k}:#{$c} +// } +// } +$uni-ui-color:( + // 主色 + primary: $uni-primary, + primary-disable: $uni-primary-disable, + primary-light: $uni-primary-light, + // 辅助色 + success: $uni-success, + success-disable: $uni-success-disable, + success-light: $uni-success-light, + warning: $uni-warning, + warning-disable: $uni-warning-disable, + warning-light: $uni-warning-light, + error: $uni-error, + error-disable: $uni-error-disable, + error-light: $uni-error-light, + info: $uni-info, + info-disable: $uni-info-disable, + info-light: $uni-info-light, + // 中性色 + main-color: $uni-main-color, + base-color: $uni-base-color, + secondary-color: $uni-secondary-color, + extra-color: $uni-extra-color, + // 背景色 + bg-color: $uni-bg-color, + // 边框颜色 + border-1: $uni-border-1, + border-2: $uni-border-2, + border-3: $uni-border-3, + border-4: $uni-border-4, + // 黑色 + black:$uni-black, + // 白色 + white:$uni-white, + // 透明 + transparent:$uni-transparent +) !default; +@each $key, $child in $uni-ui-color { + .uni-#{"" + $key} { + color: $child; + } + .uni-#{"" + $key}-bg { + background-color: $child; + } +} +.uni-shadow-sm { + box-shadow: $uni-shadow-sm; +} +.uni-shadow-base { + box-shadow: $uni-shadow-base; +} +.uni-shadow-lg { + box-shadow: $uni-shadow-lg; +} +.uni-mask { + background-color:$uni-mask; +} diff --git a/uni_modules/uni-scss/styles/setting/_radius.scss b/uni_modules/uni-scss/styles/setting/_radius.scss new file mode 100644 index 0000000..9a0428b --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_radius.scss @@ -0,0 +1,55 @@ +@mixin radius($r,$d:null ,$important: false){ + $radius-value:map-get($uni-radius, $r) if($important, !important, null); + // Key exists within the $uni-radius variable + @if (map-has-key($uni-radius, $r) and $d){ + @if $d == t { + border-top-left-radius:$radius-value; + border-top-right-radius:$radius-value; + }@else if $d == r { + border-top-right-radius:$radius-value; + border-bottom-right-radius:$radius-value; + }@else if $d == b { + border-bottom-left-radius:$radius-value; + border-bottom-right-radius:$radius-value; + }@else if $d == l { + border-top-left-radius:$radius-value; + border-bottom-left-radius:$radius-value; + }@else if $d == tl { + border-top-left-radius:$radius-value; + }@else if $d == tr { + border-top-right-radius:$radius-value; + }@else if $d == br { + border-bottom-right-radius:$radius-value; + }@else if $d == bl { + border-bottom-left-radius:$radius-value; + } + }@else{ + border-radius:$radius-value; + } +} + +@each $key, $child in $uni-radius { + @if($key){ + .uni-radius-#{"" + $key} { + @include radius($key) + } + }@else{ + .uni-radius { + @include radius($key) + } + } +} + +@each $direction in t, r, b, l,tl, tr, br, bl { + @each $key, $child in $uni-radius { + @if($key){ + .uni-radius-#{"" + $direction}-#{"" + $key} { + @include radius($key,$direction,false) + } + }@else{ + .uni-radius-#{$direction} { + @include radius($key,$direction,false) + } + } + } +} diff --git a/uni_modules/uni-scss/styles/setting/_space.scss b/uni_modules/uni-scss/styles/setting/_space.scss new file mode 100644 index 0000000..3c89528 --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_space.scss @@ -0,0 +1,56 @@ + +@mixin fn($space,$direction,$size,$n) { + @if $n { + #{$space}-#{$direction}: #{$size*$uni-space-root}px + } @else { + #{$space}-#{$direction}: #{-$size*$uni-space-root}px + } +} +@mixin get-styles($direction,$i,$space,$n){ + @if $direction == t { + @include fn($space, top,$i,$n); + } + @if $direction == r { + @include fn($space, right,$i,$n); + } + @if $direction == b { + @include fn($space, bottom,$i,$n); + } + @if $direction == l { + @include fn($space, left,$i,$n); + } + @if $direction == x { + @include fn($space, left,$i,$n); + @include fn($space, right,$i,$n); + } + @if $direction == y { + @include fn($space, top,$i,$n); + @include fn($space, bottom,$i,$n); + } + @if $direction == a { + @if $n { + #{$space}:#{$i*$uni-space-root}px; + } @else { + #{$space}:#{-$i*$uni-space-root}px; + } + } +} + +@each $orientation in m,p { + $space: margin; + @if $orientation == m { + $space: margin; + } @else { + $space: padding; + } + @for $i from 0 through 16 { + @each $direction in t, r, b, l, x, y, a { + .uni-#{$orientation}#{$direction}-#{$i} { + @include get-styles($direction,$i,$space,true); + } + .uni-#{$orientation}#{$direction}-n#{$i} { + @include get-styles($direction,$i,$space,false); + } + } + } +} \ No newline at end of file diff --git a/uni_modules/uni-scss/styles/setting/_styles.scss b/uni_modules/uni-scss/styles/setting/_styles.scss new file mode 100644 index 0000000..689afec --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_styles.scss @@ -0,0 +1,167 @@ +/* #ifndef APP-NVUE */ + +$-color-white:#fff; +$-color-black:#000; +@mixin base-style($color) { + color: #fff; + background-color: $color; + border-color: mix($-color-black, $color, 8%); + &:not([hover-class]):active { + background: mix($-color-black, $color, 10%); + border-color: mix($-color-black, $color, 20%); + color: $-color-white; + outline: none; + } +} +@mixin is-color($color) { + @include base-style($color); + &[loading] { + @include base-style($color); + &::before { + margin-right:5px; + } + } + &[disabled] { + &, + &[loading], + &:not([hover-class]):active { + color: $-color-white; + border-color: mix(darken($color,10%), $-color-white); + background-color: mix($color, $-color-white); + } + } + +} +@mixin base-plain-style($color) { + color:$color; + background-color: mix($-color-white, $color, 90%); + border-color: mix($-color-white, $color, 70%); + &:not([hover-class]):active { + background: mix($-color-white, $color, 80%); + color: $color; + outline: none; + border-color: mix($-color-white, $color, 50%); + } +} +@mixin is-plain($color){ + &[plain] { + @include base-plain-style($color); + &[loading] { + @include base-plain-style($color); + &::before { + margin-right:5px; + } + } + &[disabled] { + &, + &:active { + color: mix($-color-white, $color, 40%); + background-color: mix($-color-white, $color, 90%); + border-color: mix($-color-white, $color, 80%); + } + } + } +} + + +.uni-btn { + margin: 5px; + color: #393939; + border:1px solid #ccc; + font-size: 16px; + font-weight: 200; + background-color: #F9F9F9; + // TODO 暂时处理边框隐藏一边的问题 + overflow: visible; + &::after{ + border: none; + } + + &:not([type]),&[type=default] { + color: #999; + &[loading] { + background: none; + &::before { + margin-right:5px; + } + } + + + + &[disabled]{ + color: mix($-color-white, #999, 60%); + &, + &[loading], + &:active { + color: mix($-color-white, #999, 60%); + background-color: mix($-color-white,$-color-black , 98%); + border-color: mix($-color-white, #999, 85%); + } + } + + &[plain] { + color: #999; + background: none; + border-color: $uni-border-1; + &:not([hover-class]):active { + background: none; + color: mix($-color-white, $-color-black, 80%); + border-color: mix($-color-white, $-color-black, 90%); + outline: none; + } + &[disabled]{ + &, + &[loading], + &:active { + background: none; + color: mix($-color-white, #999, 60%); + border-color: mix($-color-white, #999, 85%); + } + } + } + } + + &:not([hover-class]):active { + color: mix($-color-white, $-color-black, 50%); + } + + &[size=mini] { + font-size: 16px; + font-weight: 200; + border-radius: 8px; + } + + + + &.uni-btn-small { + font-size: 14px; + } + &.uni-btn-mini { + font-size: 12px; + } + + &.uni-btn-radius { + border-radius: 999px; + } + &[type=primary] { + @include is-color($uni-primary); + @include is-plain($uni-primary) + } + &[type=success] { + @include is-color($uni-success); + @include is-plain($uni-success) + } + &[type=error] { + @include is-color($uni-error); + @include is-plain($uni-error) + } + &[type=warning] { + @include is-color($uni-warning); + @include is-plain($uni-warning) + } + &[type=info] { + @include is-color($uni-info); + @include is-plain($uni-info) + } +} +/* #endif */ diff --git a/uni_modules/uni-scss/styles/setting/_text.scss b/uni_modules/uni-scss/styles/setting/_text.scss new file mode 100644 index 0000000..a34d08f --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_text.scss @@ -0,0 +1,24 @@ +@mixin get-styles($k,$c) { + @if $k == size or $k == weight{ + font-#{$k}:#{$c} + }@else{ + #{$k}:#{$c} + } +} + +@each $key, $child in $uni-headings { + /* #ifndef APP-NVUE */ + .uni-#{$key} { + @each $k, $c in $child { + @include get-styles($k,$c) + } + } + /* #endif */ + /* #ifdef APP-NVUE */ + .container .uni-#{$key} { + @each $k, $c in $child { + @include get-styles($k,$c) + } + } + /* #endif */ +} diff --git a/uni_modules/uni-scss/styles/setting/_variables.scss b/uni_modules/uni-scss/styles/setting/_variables.scss new file mode 100644 index 0000000..557d3d7 --- /dev/null +++ b/uni_modules/uni-scss/styles/setting/_variables.scss @@ -0,0 +1,146 @@ +// @use "sass:math"; +@import '../tools/functions.scss'; +// 间距基础倍数 +$uni-space-root: 2 !default; +// 边框半径默认值 +$uni-radius-root:5px !default; +$uni-radius: () !default; +// 边框半径断点 +$uni-radius: map-deep-merge( + ( + 0: 0, + // TODO 当前版本暂时不支持 sm 属性 + // 'sm': math.div($uni-radius-root, 2), + null: $uni-radius-root, + 'lg': $uni-radius-root * 2, + 'xl': $uni-radius-root * 6, + 'pill': 9999px, + 'circle': 50% + ), + $uni-radius +); +// 字体家族 +$body-font-family: 'Roboto', sans-serif !default; +// 文本 +$heading-font-family: $body-font-family !default; +$uni-headings: () !default; +$letterSpacing: -0.01562em; +$uni-headings: map-deep-merge( + ( + 'h1': ( + size: 32px, + weight: 300, + line-height: 50px, + // letter-spacing:-0.01562em + ), + 'h2': ( + size: 28px, + weight: 300, + line-height: 40px, + // letter-spacing: -0.00833em + ), + 'h3': ( + size: 24px, + weight: 400, + line-height: 32px, + // letter-spacing: normal + ), + 'h4': ( + size: 20px, + weight: 400, + line-height: 30px, + // letter-spacing: 0.00735em + ), + 'h5': ( + size: 16px, + weight: 400, + line-height: 24px, + // letter-spacing: normal + ), + 'h6': ( + size: 14px, + weight: 500, + line-height: 18px, + // letter-spacing: 0.0125em + ), + 'subtitle': ( + size: 12px, + weight: 400, + line-height: 20px, + // letter-spacing: 0.00937em + ), + 'body': ( + font-size: 14px, + font-weight: 400, + line-height: 22px, + // letter-spacing: 0.03125em + ), + 'caption': ( + 'size': 12px, + 'weight': 400, + 'line-height': 20px, + // 'letter-spacing': 0.03333em, + // 'text-transform': false + ) + ), + $uni-headings +); + + + +// 主色 +$uni-primary: #2979ff !default; +$uni-primary-disable:lighten($uni-primary,20%) !default; +$uni-primary-light: lighten($uni-primary,25%) !default; + +// 辅助色 +// 除了主色外的场景色,需要在不同的场景中使用(例如危险色表示危险的操作)。 +$uni-success: #18bc37 !default; +$uni-success-disable:lighten($uni-success,20%) !default; +$uni-success-light: lighten($uni-success,25%) !default; + +$uni-warning: #f3a73f !default; +$uni-warning-disable:lighten($uni-warning,20%) !default; +$uni-warning-light: lighten($uni-warning,25%) !default; + +$uni-error: #e43d33 !default; +$uni-error-disable:lighten($uni-error,20%) !default; +$uni-error-light: lighten($uni-error,25%) !default; + +$uni-info: #8f939c !default; +$uni-info-disable:lighten($uni-info,20%) !default; +$uni-info-light: lighten($uni-info,25%) !default; + +// 中性色 +// 中性色用于文本、背景和边框颜色。通过运用不同的中性色,来表现层次结构。 +$uni-main-color: #3a3a3a !default; // 主要文字 +$uni-base-color: #6a6a6a !default; // 常规文字 +$uni-secondary-color: #909399 !default; // 次要文字 +$uni-extra-color: #c7c7c7 !default; // 辅助说明 + +// 边框颜色 +$uni-border-1: #F0F0F0 !default; +$uni-border-2: #EDEDED !default; +$uni-border-3: #DCDCDC !default; +$uni-border-4: #B9B9B9 !default; + +// 常规色 +$uni-black: #000000 !default; +$uni-white: #ffffff !default; +$uni-transparent: rgba($color: #000000, $alpha: 0) !default; + +// 背景色 +$uni-bg-color: #f7f7f7 !default; + +/* 水平间距 */ +$uni-spacing-sm: 8px !default; +$uni-spacing-base: 15px !default; +$uni-spacing-lg: 30px !default; + +// 阴影 +$uni-shadow-sm:0 0 5px rgba($color: #d8d8d8, $alpha: 0.5) !default; +$uni-shadow-base:0 1px 8px 1px rgba($color: #a5a5a5, $alpha: 0.2) !default; +$uni-shadow-lg:0px 1px 10px 2px rgba($color: #a5a4a4, $alpha: 0.5) !default; + +// 蒙版 +$uni-mask: rgba($color: #000000, $alpha: 0.4) !default; diff --git a/uni_modules/uni-scss/styles/tools/functions.scss b/uni_modules/uni-scss/styles/tools/functions.scss new file mode 100644 index 0000000..ac6f63e --- /dev/null +++ b/uni_modules/uni-scss/styles/tools/functions.scss @@ -0,0 +1,19 @@ +// 合并 map +@function map-deep-merge($parent-map, $child-map){ + $result: $parent-map; + @each $key, $child in $child-map { + $parent-has-key: map-has-key($result, $key); + $parent-value: map-get($result, $key); + $parent-type: type-of($parent-value); + $child-type: type-of($child); + $parent-is-map: $parent-type == map; + $child-is-map: $child-type == map; + + @if (not $parent-has-key) or ($parent-type != $child-type) or (not ($parent-is-map and $child-is-map)){ + $result: map-merge($result, ( $key: $child )); + }@else { + $result: map-merge($result, ( $key: map-deep-merge($parent-value, $child) )); + } + } + @return $result; +}; diff --git a/uni_modules/uni-scss/theme.scss b/uni_modules/uni-scss/theme.scss new file mode 100644 index 0000000..80ee62f --- /dev/null +++ b/uni_modules/uni-scss/theme.scss @@ -0,0 +1,31 @@ +// 间距基础倍数 +$uni-space-root: 2; +// 边框半径默认值 +$uni-radius-root:5px; +// 主色 +$uni-primary: #2979ff; +// 辅助色 +$uni-success: #4cd964; +// 警告色 +$uni-warning: #f0ad4e; +// 错误色 +$uni-error: #dd524d; +// 描述色 +$uni-info: #909399; +// 中性色 +$uni-main-color: #303133; +$uni-base-color: #606266; +$uni-secondary-color: #909399; +$uni-extra-color: #C0C4CC; +// 背景色 +$uni-bg-color: #f5f5f5; +// 边框颜色 +$uni-border-1: #DCDFE6; +$uni-border-2: #E4E7ED; +$uni-border-3: #EBEEF5; +$uni-border-4: #F2F6FC; + +// 常规色 +$uni-black: #000000; +$uni-white: #ffffff; +$uni-transparent: rgba($color: #000000, $alpha: 0); diff --git a/uni_modules/uni-scss/variables.scss b/uni_modules/uni-scss/variables.scss new file mode 100644 index 0000000..1c062d4 --- /dev/null +++ b/uni_modules/uni-scss/variables.scss @@ -0,0 +1,62 @@ +@import './styles/setting/_variables.scss'; +// 间距基础倍数 +$uni-space-root: 2; +// 边框半径默认值 +$uni-radius-root:5px; + +// 主色 +$uni-primary: #2979ff; +$uni-primary-disable:mix(#fff,$uni-primary,50%); +$uni-primary-light: mix(#fff,$uni-primary,80%); + +// 辅助色 +// 除了主色外的场景色,需要在不同的场景中使用(例如危险色表示危险的操作)。 +$uni-success: #18bc37; +$uni-success-disable:mix(#fff,$uni-success,50%); +$uni-success-light: mix(#fff,$uni-success,80%); + +$uni-warning: #f3a73f; +$uni-warning-disable:mix(#fff,$uni-warning,50%); +$uni-warning-light: mix(#fff,$uni-warning,80%); + +$uni-error: #e43d33; +$uni-error-disable:mix(#fff,$uni-error,50%); +$uni-error-light: mix(#fff,$uni-error,80%); + +$uni-info: #8f939c; +$uni-info-disable:mix(#fff,$uni-info,50%); +$uni-info-light: mix(#fff,$uni-info,80%); + +// 中性色 +// 中性色用于文本、背景和边框颜色。通过运用不同的中性色,来表现层次结构。 +$uni-main-color: #3a3a3a; // 主要文字 +$uni-base-color: #6a6a6a; // 常规文字 +$uni-secondary-color: #909399; // 次要文字 +$uni-extra-color: #c7c7c7; // 辅助说明 + +// 边框颜色 +$uni-border-1: #F0F0F0; +$uni-border-2: #EDEDED; +$uni-border-3: #DCDCDC; +$uni-border-4: #B9B9B9; + +// 常规色 +$uni-black: #000000; +$uni-white: #ffffff; +$uni-transparent: rgba($color: #000000, $alpha: 0); + +// 背景色 +$uni-bg-color: #f7f7f7; + +/* 水平间距 */ +$uni-spacing-sm: 8px; +$uni-spacing-base: 15px; +$uni-spacing-lg: 30px; + +// 阴影 +$uni-shadow-sm:0 0 5px rgba($color: #d8d8d8, $alpha: 0.5); +$uni-shadow-base:0 1px 8px 1px rgba($color: #a5a5a5, $alpha: 0.2); +$uni-shadow-lg:0px 1px 10px 2px rgba($color: #a5a4a4, $alpha: 0.5); + +// 蒙版 +$uni-mask: rgba($color: #000000, $alpha: 0.4); diff --git a/uni_modules/uni-transition/changelog.md b/uni_modules/uni-transition/changelog.md new file mode 100644 index 0000000..70c1cd4 --- /dev/null +++ b/uni_modules/uni-transition/changelog.md @@ -0,0 +1,22 @@ +## 1.3.2(2023-05-04) +- 修复 NVUE 平台报错的问题 +## 1.3.1(2021-11-23) +- 修复 init 方法初始化问题 +## 1.3.0(2021-11-19) +- 优化 组件UI,并提供设计资源,详见:[https://uniapp.dcloud.io/component/uniui/resource](https://uniapp.dcloud.io/component/uniui/resource) +- 文档迁移,详见:[https://uniapp.dcloud.io/component/uniui/uni-transition](https://uniapp.dcloud.io/component/uniui/uni-transition) +## 1.2.1(2021-09-27) +- 修复 init 方法不生效的 Bug +## 1.2.0(2021-07-30) +- 组件兼容 vue3,如何创建 vue3 项目,详见 [uni-app 项目支持 vue3 介绍](https://ask.dcloud.net.cn/article/37834) +## 1.1.1(2021-05-12) +- 新增 示例地址 +- 修复 示例项目缺少组件的 Bug +## 1.1.0(2021-04-22) +- 新增 通过方法自定义动画 +- 新增 custom-class 非 NVUE 平台支持自定义 class 定制样式 +- 优化 动画触发逻辑,使动画更流畅 +- 优化 支持单独的动画类型 +- 优化 文档示例 +## 1.0.2(2021-02-05) +- 调整为 uni_modules 目录规范 diff --git a/uni_modules/uni-transition/components/uni-transition/createAnimation.js b/uni_modules/uni-transition/components/uni-transition/createAnimation.js new file mode 100644 index 0000000..8f89b18 --- /dev/null +++ b/uni_modules/uni-transition/components/uni-transition/createAnimation.js @@ -0,0 +1,131 @@ +// const defaultOption = { +// duration: 300, +// timingFunction: 'linear', +// delay: 0, +// transformOrigin: '50% 50% 0' +// } +// #ifdef APP-NVUE +const nvueAnimation = uni.requireNativePlugin('animation') +// #endif +class MPAnimation { + constructor(options, _this) { + this.options = options + // 在iOS10+QQ小程序平台下,传给原生的对象一定是个普通对象而不是Proxy对象,否则会报parameter should be Object instead of ProxyObject的错误 + this.animation = uni.createAnimation({ + ...options + }) + this.currentStepAnimates = {} + this.next = 0 + this.$ = _this + + } + + _nvuePushAnimates(type, args) { + let aniObj = this.currentStepAnimates[this.next] + let styles = {} + if (!aniObj) { + styles = { + styles: {}, + config: {} + } + } else { + styles = aniObj + } + if (animateTypes1.includes(type)) { + if (!styles.styles.transform) { + styles.styles.transform = '' + } + let unit = '' + if(type === 'rotate'){ + unit = 'deg' + } + styles.styles.transform += `${type}(${args+unit}) ` + } else { + styles.styles[type] = `${args}` + } + this.currentStepAnimates[this.next] = styles + } + _animateRun(styles = {}, config = {}) { + let ref = this.$.$refs['ani'].ref + if (!ref) return + return new Promise((resolve, reject) => { + nvueAnimation.transition(ref, { + styles, + ...config + }, res => { + resolve() + }) + }) + } + + _nvueNextAnimate(animates, step = 0, fn) { + let obj = animates[step] + if (obj) { + let { + styles, + config + } = obj + this._animateRun(styles, config).then(() => { + step += 1 + this._nvueNextAnimate(animates, step, fn) + }) + } else { + this.currentStepAnimates = {} + typeof fn === 'function' && fn() + this.isEnd = true + } + } + + step(config = {}) { + // #ifndef APP-NVUE + this.animation.step(config) + // #endif + // #ifdef APP-NVUE + this.currentStepAnimates[this.next].config = Object.assign({}, this.options, config) + this.currentStepAnimates[this.next].styles.transformOrigin = this.currentStepAnimates[this.next].config.transformOrigin + this.next++ + // #endif + return this + } + + run(fn) { + // #ifndef APP-NVUE + this.$.animationData = this.animation.export() + this.$.timer = setTimeout(() => { + typeof fn === 'function' && fn() + }, this.$.durationTime) + // #endif + // #ifdef APP-NVUE + this.isEnd = false + let ref = this.$.$refs['ani'] && this.$.$refs['ani'].ref + if(!ref) return + this._nvueNextAnimate(this.currentStepAnimates, 0, fn) + this.next = 0 + // #endif + } +} + + +const animateTypes1 = ['matrix', 'matrix3d', 'rotate', 'rotate3d', 'rotateX', 'rotateY', 'rotateZ', 'scale', 'scale3d', + 'scaleX', 'scaleY', 'scaleZ', 'skew', 'skewX', 'skewY', 'translate', 'translate3d', 'translateX', 'translateY', + 'translateZ' +] +const animateTypes2 = ['opacity', 'backgroundColor'] +const animateTypes3 = ['width', 'height', 'left', 'right', 'top', 'bottom'] +animateTypes1.concat(animateTypes2, animateTypes3).forEach(type => { + MPAnimation.prototype[type] = function(...args) { + // #ifndef APP-NVUE + this.animation[type](...args) + // #endif + // #ifdef APP-NVUE + this._nvuePushAnimates(type, args) + // #endif + return this + } +}) + +export function createAnimation(option, _this) { + if(!_this) return + clearTimeout(_this.timer) + return new MPAnimation(option, _this) +} diff --git a/uni_modules/uni-transition/components/uni-transition/uni-transition.vue b/uni_modules/uni-transition/components/uni-transition/uni-transition.vue new file mode 100644 index 0000000..bfbba93 --- /dev/null +++ b/uni_modules/uni-transition/components/uni-transition/uni-transition.vue @@ -0,0 +1,286 @@ + + ++ + ++ + ++ ++ + + + + + + + + + + + diff --git a/uni_modules/uni-transition/package.json b/uni_modules/uni-transition/package.json new file mode 100644 index 0000000..ea995a2 --- /dev/null +++ b/uni_modules/uni-transition/package.json @@ -0,0 +1,84 @@ +{ + "id": "uni-transition", + "displayName": "uni-transition 过渡动画", + "version": "1.3.2", + "description": "元素的简单过渡动画", + "keywords": [ + "uni-ui", + "uniui", + "动画", + "过渡", + "过渡动画" +], + "repository": "https://github.com/dcloudio/uni-ui", + "engines": { + "HBuilderX": "" + }, + "directories": { + "example": "../../temps/example_temps" + }, +"dcloudext": { + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "无", + "permissions": "无" + }, + "npmurl": "https://www.npmjs.com/package/@dcloudio/uni-ui", + "type": "component-vue" + }, + "uni_modules": { + "dependencies": ["uni-scss"], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y" + }, + "client": { + "App": { + "app-vue": "y", + "app-nvue": "y" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "y", + "Edge": "y", + "Firefox": "y", + "Safari": "y" + }, + "小程序": { + "微信": "y", + "阿里": "y", + "百度": "y", + "字节跳动": "y", + "QQ": "y" + }, + "快应用": { + "华为": "u", + "联盟": "u" + }, + "Vue": { + "vue2": "y", + "vue3": "y" + } + } + } + } +} \ No newline at end of file diff --git a/uni_modules/uni-transition/readme.md b/uni_modules/uni-transition/readme.md new file mode 100644 index 0000000..2f8a77e --- /dev/null +++ b/uni_modules/uni-transition/readme.md @@ -0,0 +1,11 @@ + + +## Transition 过渡动画 +> **组件名:uni-transition** +> 代码块: `uTransition` + + +元素过渡动画 + +### [查看文档](https://uniapp.dcloud.io/component/uniui/uni-transition) +#### 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839 \ No newline at end of file diff --git a/uni_modules/v-sign/changelog.md b/uni_modules/v-sign/changelog.md new file mode 100644 index 0000000..17deb52 --- /dev/null +++ b/uni_modules/v-sign/changelog.md @@ -0,0 +1,48 @@ +## 0.5.2(2022-06-10) +- canvas 默认设置 disable-scroll 属性为true, 当在 canvas 中移动时且有绑定手势事件时,禁止屏幕滚动以及下拉刷新 +## 0.5.1(2022-05-27) +- 取消属性 width, height 默认值 +## 0.5.0(2022-05-27) +- 新增 v-sgin 组件获取坐标信息数组方法 `getLineData` +- 新增 v-sign 组件事件触发 @clear, @revoke, @end +- 修复撤销操作重设背景色导致线条消失问题 +## 0.4.0(2022-05-15) +- 新增属性 bgColor 设置画布背景色,修复导出图片无背景色问题 +## 0.3.4(2022-03-30) +修复 v-sign-action 子组件 svg 加载报错 +## 0.3.3(2022-03-30) +修复 v-sign-action 子组件 svg 加载报错 +## 0.3.2(2022-01-12) +- 修复多组件共存绘制问题 +## 0.3.1(2021-12-14) +- 【新增】保存 png 图片方法 saveImage; +- 【修改】 控件子组件保存按钮动作由保存为临时文件路径改为保存图片 +## 0.3.0(2021-12-11) +- 添加颜色选择器组件 +## 0.2.0(2021-12-10) +- 修改为 uni_modules 规范 +## 0.1.7 (2021-12-09) + +- 画笔组件优化 + +## 0.1.6 (2021-12-08) + +- 画笔样式优化 + +## 0.1.5 (2021-12-08) + +- 画笔子组件样式修改,支持circle、line 两种样式 + +## 0.1.4 (2021-12-08) + +- 添加画笔子组件 + +## 0.1.3 (2021-12-02) + +- 添加按钮控件子组件 + +## 0.1.0 (2021-11-28) + +- 支持线宽、颜色自定义,自定义画布样式 +- 支持画布清空、撤回、保存图片 +- 事件 init 暴露清空、撤回、保存图片方法 \ No newline at end of file diff --git a/uni_modules/v-sign/components/v-sign-action/v-sign-action.vue b/uni_modules/v-sign/components/v-sign-action/v-sign-action.vue new file mode 100644 index 0000000..e8760d2 --- /dev/null +++ b/uni_modules/v-sign/components/v-sign-action/v-sign-action.vue @@ -0,0 +1,168 @@ + + + + + + + + diff --git a/uni_modules/v-sign/components/v-sign-color/v-sign-color.vue b/uni_modules/v-sign/components/v-sign-color/v-sign-color.vue new file mode 100644 index 0000000..f335349 --- /dev/null +++ b/uni_modules/v-sign/components/v-sign-color/v-sign-color.vue @@ -0,0 +1,212 @@ + ++ ++ {{ item.label }} ++ + + + + + diff --git a/uni_modules/v-sign/components/v-sign-pen/v-sign-pen.vue b/uni_modules/v-sign/components/v-sign-pen/v-sign-pen.vue new file mode 100644 index 0000000..41786a3 --- /dev/null +++ b/uni_modules/v-sign/components/v-sign-pen/v-sign-pen.vue @@ -0,0 +1,215 @@ + ++ ++ ++ {{ tick && currentIndex === index ? '✓' : '' }} + ++ + + + + + diff --git a/uni_modules/v-sign/components/v-sign/v-sign.vue b/uni_modules/v-sign/components/v-sign/v-sign.vue new file mode 100644 index 0000000..0d2d529 --- /dev/null +++ b/uni_modules/v-sign/components/v-sign/v-sign.vue @@ -0,0 +1,326 @@ + +{{ label }} ++ ++ ++ ++ + + + + + + + diff --git a/uni_modules/v-sign/package.json b/uni_modules/v-sign/package.json new file mode 100644 index 0000000..18e537c --- /dev/null +++ b/uni_modules/v-sign/package.json @@ -0,0 +1,84 @@ +{ + "id": "v-sign", + "displayName": "canvas 手写 签名 签字 画板组件", + "version": "0.5.2", + "description": "基于 canvas 实现;1. 支持线条自定义样式;2. 支持撤回、清空、导出图片等功能;3. 内置按钮、画笔等子组件。", + "keywords": [ + "canvas", + "签名", + "签字", + "电子签名", + "signature" +], + "repository": "https://github.com/jizai1125/v-sign", + "engines": { + "HBuilderX": "^3.1.0" + }, + "dcloudext": { + "category": [ + "前端组件", + "通用组件" + ], + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "插件不采集任何数据", + "permissions": "无" + }, + "npmurl": "" + }, + "uni_modules": { + "dependencies": [], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y" + }, + "client": { + "Vue": { + "vue2": "y", + "vue3": "n" + }, + "App": { + "app-vue": "u", + "app-nvue": "u" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "y", + "Edge": "y", + "Firefox": "y", + "Safari": "y" + }, + "小程序": { + "微信": "y", + "阿里": "y", + "百度": "y", + "字节跳动": "y", + "QQ": "y" + }, + "快应用": { + "华为": "u", + "联盟": "u" + } + } + } + } +} \ No newline at end of file diff --git a/uni_modules/v-sign/readme.md b/uni_modules/v-sign/readme.md new file mode 100644 index 0000000..696e33d --- /dev/null +++ b/uni_modules/v-sign/readme.md @@ -0,0 +1,245 @@ +# v-sign 手写签名 + +**如有问题或者建议,欢迎留言或加群联系我(群号:736123963)!!!将保持维护!!!** + + + +## 快速使用 + +基础示例,具体说明见下方 API,**若需要使用内置子组件,见下方子组件说明。** + +```html + ++ + + +``` + +## API + +### 属性 (Props) + +| 属性名 | 类型 | 默认值 | 说明 | +| :---------: | :-----------: | :-----------: | :--------------------------: | +| cid | String | v-sign-时间戳 | canvas id | +| width | String/Number | - | canvas 宽度,Number 单位 rpx | +| height | String/Number | - | canvas 高度,Number 单位 rpx | +| customStyle | Object | - | canvas 自定义样式 | +| lineWidth | Number | 4 | 线宽,单位 px | +| lineColor | String | #333 | 线颜色 | +| bgColor | String | #fff | 画布背景颜色 | + +### 事件(Events) + +| 事件称名 | 说明 | 返回值 | +| :------: | :------------------------------------------------------------: | :--------------------------------: | +| @init | 创建完 canvas 实例后触发,向外提供 canvas 实例,撤回,清空方法 | Object:具体见下方事件回调参数说明 | +| @clear | 清空画布后触发 | - | +| @revoke | 撤销操作后触发 | 坐标信息数组 | +| @end | 每次绘制结束后触发 | 坐标信息数组 | + +### 事件回调参数说明 + +#### **`init(ctx: SignContext)`** + +可以通过该事件回调暴露的 clear、revoke 等方法操作画布。 + +```java +interface SignContext { + // canvas 实例 + ctx: object; + // 清空画布 + clear(): void; + // 撤回 + revoke(): void; + // 保存 png 图片,文件名 filename 配置仅支持 h5 + saveImage(filename: string): Promise