From 508bc3a8aacd5bfa7efda14147bdc51905c3bbf7 Mon Sep 17 00:00:00 2001 From: YuanWen Date: Fri, 30 Oct 2026 10:14:49 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=BF=81=E7=A7=BB=E9=A1=B9=E7=9B=AE?= =?UTF-8?q?=E5=88=B0=20yjyf-app=20=E7=9B=AE=E5=BD=95=E5=B9=B6=E6=9B=B4?= =?UTF-8?q?=E6=96=B0=E9=A6=96=E9=A1=B5=E8=B7=AF=E7=94=B1=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 67 ++++++++ pages/index/index.vue | 52 ------ server/application/api/controller/Auth.php | 2 +- tests/config_check.js | 2 +- tests/page_flow.js | 4 +- tests/phase2_verify.js | 2 +- tests/phase3_merchant.js | 2 +- App.vue => yjyf-app/App.vue | 32 ++-- index.html => yjyf-app/index.html | 0 main.js => yjyf-app/main.js | 0 manifest.json => yjyf-app/manifest.json | 0 pages.json => yjyf-app/pages.json | 6 +- {pages => yjyf-app/pages}/address/list.vue | 0 {pages => yjyf-app/pages}/coupon/coupon.vue | 2 +- .../pages/index/index.vue | 7 +- {pages => yjyf-app/pages}/login/login.vue | 2 +- {pages => yjyf-app/pages}/master/apply.vue | 0 {pages => yjyf-app/pages}/master/credit.vue | 0 {pages => yjyf-app/pages}/master/hall.vue | 0 {pages => yjyf-app/pages}/master/orders.vue | 0 {pages => yjyf-app/pages}/master/quote.vue | 0 {pages => yjyf-app/pages}/master/wallet.vue | 0 .../pages}/master/workbench.vue | 2 +- {pages => yjyf-app/pages}/merchant/apply.vue | 0 {pages => yjyf-app/pages}/merchant/batch.vue | 0 .../pages}/merchant/invoice.vue | 0 {pages => yjyf-app/pages}/merchant/orders.vue | 0 .../pages}/merchant/workbench.vue | 2 +- {pages => yjyf-app/pages}/message/message.vue | 0 {pages => yjyf-app/pages}/mine/mine.vue | 2 +- {pages => yjyf-app/pages}/order/create.vue | 0 {pages => yjyf-app/pages}/order/detail.vue | 2 +- {pages => yjyf-app/pages}/order/list.vue | 0 {pages => yjyf-app/pages}/order/quick.vue | 0 {pages => yjyf-app/pages}/order/review.vue | 0 {pages => yjyf-app/pages}/service/detail.vue | 0 {pages => yjyf-app/pages}/service/list.vue | 0 .../static}/icons/appliance.png | Bin {static => yjyf-app/static}/icons/bath.png | Bin {static => yjyf-app/static}/icons/curtain.png | Bin {static => yjyf-app/static}/icons/door.png | Bin {static => yjyf-app/static}/icons/fitness.png | Bin {static => yjyf-app/static}/icons/frame.png | Bin {static => yjyf-app/static}/icons/kitchen.png | Bin {static => yjyf-app/static}/icons/lamp.png | Bin {static => yjyf-app/static}/icons/lock.png | Bin {static => yjyf-app/static}/icons/more.png | Bin {static => yjyf-app/static}/icons/rack.png | Bin {static => yjyf-app/static}/icons/shower.png | Bin {static => yjyf-app/static}/icons/sofa.png | Bin {static => yjyf-app/static}/icons/tv.png | Bin {static => yjyf-app/static}/icons/water.png | Bin {static => yjyf-app/static}/logo.png | Bin .../uni.promisify.adaptor.js | 0 uni.scss => yjyf-app/uni.scss | 152 +++++++++--------- {utils => yjyf-app/utils}/api.js | 0 {utils => yjyf-app/utils}/request.js | 0 {utils => yjyf-app/utils}/role.js | 0 {utils => yjyf-app/utils}/wxlogin.js | 0 59 files changed, 176 insertions(+), 164 deletions(-) create mode 100644 README.md delete mode 100644 pages/index/index.vue rename App.vue => yjyf-app/App.vue (94%) rename index.html => yjyf-app/index.html (100%) rename main.js => yjyf-app/main.js (100%) rename manifest.json => yjyf-app/manifest.json (100%) rename pages.json => yjyf-app/pages.json (97%) rename {pages => yjyf-app/pages}/address/list.vue (100%) rename {pages => yjyf-app/pages}/coupon/coupon.vue (98%) rename YJYF/YJYF.vue => yjyf-app/pages/index/index.vue (99%) rename {pages => yjyf-app/pages}/login/login.vue (99%) rename {pages => yjyf-app/pages}/master/apply.vue (100%) rename {pages => yjyf-app/pages}/master/credit.vue (100%) rename {pages => yjyf-app/pages}/master/hall.vue (100%) rename {pages => yjyf-app/pages}/master/orders.vue (100%) rename {pages => yjyf-app/pages}/master/quote.vue (100%) rename {pages => yjyf-app/pages}/master/wallet.vue (100%) rename {pages => yjyf-app/pages}/master/workbench.vue (99%) rename {pages => yjyf-app/pages}/merchant/apply.vue (100%) rename {pages => yjyf-app/pages}/merchant/batch.vue (100%) rename {pages => yjyf-app/pages}/merchant/invoice.vue (100%) rename {pages => yjyf-app/pages}/merchant/orders.vue (100%) rename {pages => yjyf-app/pages}/merchant/workbench.vue (99%) rename {pages => yjyf-app/pages}/message/message.vue (100%) rename {pages => yjyf-app/pages}/mine/mine.vue (99%) rename {pages => yjyf-app/pages}/order/create.vue (100%) rename {pages => yjyf-app/pages}/order/detail.vue (99%) rename {pages => yjyf-app/pages}/order/list.vue (100%) rename {pages => yjyf-app/pages}/order/quick.vue (100%) rename {pages => yjyf-app/pages}/order/review.vue (100%) rename {pages => yjyf-app/pages}/service/detail.vue (100%) rename {pages => yjyf-app/pages}/service/list.vue (100%) rename {static => yjyf-app/static}/icons/appliance.png (100%) rename {static => yjyf-app/static}/icons/bath.png (100%) rename {static => yjyf-app/static}/icons/curtain.png (100%) rename {static => yjyf-app/static}/icons/door.png (100%) rename {static => yjyf-app/static}/icons/fitness.png (100%) rename {static => yjyf-app/static}/icons/frame.png (100%) rename {static => yjyf-app/static}/icons/kitchen.png (100%) rename {static => yjyf-app/static}/icons/lamp.png (100%) rename {static => yjyf-app/static}/icons/lock.png (100%) rename {static => yjyf-app/static}/icons/more.png (100%) rename {static => yjyf-app/static}/icons/rack.png (100%) rename {static => yjyf-app/static}/icons/shower.png (100%) rename {static => yjyf-app/static}/icons/sofa.png (100%) rename {static => yjyf-app/static}/icons/tv.png (100%) rename {static => yjyf-app/static}/icons/water.png (100%) rename {static => yjyf-app/static}/logo.png (100%) rename uni.promisify.adaptor.js => yjyf-app/uni.promisify.adaptor.js (100%) rename uni.scss => yjyf-app/uni.scss (96%) rename {utils => yjyf-app/utils}/api.js (100%) rename {utils => yjyf-app/utils}/request.js (100%) rename {utils => yjyf-app/utils}/role.js (100%) rename {utils => yjyf-app/utils}/wxlogin.js (100%) diff --git a/README.md b/README.md new file mode 100644 index 0000000..9e0fa5b --- /dev/null +++ b/README.md @@ -0,0 +1,67 @@ +# 优匠优服(YJYF)同城服务平台 + +## 一、项目架构概述 +本项目采用 **前后端分离的全栈工程架构**: +- **移动/小程序客户端**:位于 `yjyf-app/`,基于 **uni-app (Vue) + SCSS**,适配微信小程序、H5、App 等。 +- **服务端接口与后台**:位于 `server/`,基于 **FastAdmin / ThinkPHP 5.x**,提供 RESTful API 与 RBAC 运营管理后台。 +- **数据库**:位于 `db/`,MySQL 5.7+ / 8.0(utf8mb4 字符集),提供完整的阶段演进建表 SQL。 + +--- + +## 二、标准项目目录结构 + +```text +yjyf/ +├── yjyf-app/ # 小程序/移动客户端源码(uni-app 前端工程) +│ ├── pages/ # 业务页面目录 +│ │ ├── index/ # 平台主页(pages/index/index) +│ │ ├── service/ # 服务分类列表、服务详情、价格测算 +│ │ ├── order/ # 订单模块(快速下单、确认订单、订单详情、评价) +│ │ ├── master/ # 师傅端(资质入驻、接单大厅、工作台、报价管理、钱包、信用) +│ │ ├── merchant/ # 商户端(商家入驻、商家工作台、批量下单、企业订单、发票) +│ │ ├── address/ # 用户服务地址管理 +│ │ ├── coupon/ # 领券中心与我的优惠券 +│ │ ├── message/ # 消息通知中心 +│ │ ├── mine/ # 个人中心(角色切换、设置) +│ │ └── login/ # 统一登录与微信静默/授权登录 +│ ├── static/ # 静态资源(保留 logo.png 与 icons/ 服务图标库) +│ │ └── icons/ # 扁平双色矢量服务类目图标 +│ ├── utils/ # 前端核心工具库 +│ │ ├── api.js # 接口清单(与后端 api 控制器一一映射) +│ │ ├── request.js # 网络请求封装(Token 鉴权、响应拦截、统一异常提示) +│ │ ├── role.js # 角色上下文状态管理(user / master / merchant) +│ │ └── wxlogin.js # 微信静默授权登录 +│ ├── App.vue # uni-app 入口组件 +│ ├── main.js # Vue 初始化入口 +│ ├── pages.json # 页面路由与窗口配置 +│ ├── manifest.json # 跨端发行与 AppID 配置 +│ └── uni.scss # 全局主题样式变量 +├── server/ # 后端服务端源码(FastAdmin / ThinkPHP) +│ ├── application/ # 业务应用模块 +│ │ ├── admin/ # 后台管理控制器与视图(订单、师傅、商户、结算、提现等) +│ │ ├── api/ # 客户端 RESTful API 控制器(Home, Order, Master, Merchant 等) +│ │ └── common/ # 公共模型、类库、业务枚举(如 OrderStatus) +│ ├── public/ # Web 入口目录(admin.php, index.php) +│ ├── addons/ # FastAdmin 插件扩展 +│ ├── composer.json # 后端依赖配置 +│ └── think # ThinkPHP 命令行脚手架 +├── db/ # 数据库架构与演进脚本 +│ ├── schema_phase1.sql ~ schema_phase10_admin_config_zh.sql +│ └── README_phase5.md # 数据同源与后台模块部署规范 +├── tests/ # 接口与业务闭环自动化测试套件 +└── scripts/ # 运维补丁与部署脚本 +``` + +--- + +## 三、开发与运行指引 + +### 1. 小程序端开发(HBuilderX) +- 在 **HBuilderX** 中打开 `yjyf-app/` 文件夹(或在命令行通过相关 CLI 启动构建); +- 配置 `yjyf-app/manifest.json` 中的微信小程序 AppID; +- 点击「运行」→「运行到小程序模拟器」→「微信开发者工具」。 + +### 2. 路由与多角色规范 +- 所有页面统一存放于 `yjyf-app/pages/{模块名}/{页面名}.vue`; +- 启动页统一为 `pages/index/index`; +- 系统支持 `user`(个人业主)、`master`(维修师傅)、`merchant`(合作商户)三种身份,前端调用 `/api/auth/switchRole` 实现安全角色切换。 diff --git a/pages/index/index.vue b/pages/index/index.vue deleted file mode 100644 index 4ca2b92..0000000 --- a/pages/index/index.vue +++ /dev/null @@ -1,52 +0,0 @@ - - - - - diff --git a/server/application/api/controller/Auth.php b/server/application/api/controller/Auth.php index 4f8f333..3888397 100644 --- a/server/application/api/controller/Auth.php +++ b/server/application/api/controller/Auth.php @@ -196,7 +196,7 @@ class Auth extends Base } } - $redirect = '/YJYF/YJYF'; + $redirect = '/pages/index/index'; if ($role === 'master') { $redirect = '/pages/master/workbench'; } elseif ($role === 'merchant') { diff --git a/tests/config_check.js b/tests/config_check.js index 9ea0f5e..0a8b7b5 100644 --- a/tests/config_check.js +++ b/tests/config_check.js @@ -7,7 +7,7 @@ const fs = require('fs'); const path = require('path'); const { execFileSync } = require('child_process'); -const ROOT = '/Users/linda/Desktop/project/uni-preset-vue-vite-ts shanchan/yjyf'; +const ROOT = process.env.APP_ROOT || process.env.CLIENT_ROOT || path.resolve(__dirname, '../yjyf-app'); const API = 'https://yjyf.gzyakj.com.cn/api'; const HOST = '8.137.181.63'; diff --git a/tests/page_flow.js b/tests/page_flow.js index beb3d62..3ba7346 100644 --- a/tests/page_flow.js +++ b/tests/page_flow.js @@ -49,8 +49,8 @@ const sql = (s) => execFileSync('ssh', ['-o', 'BatchMode=yes', 'root@8.137.181.6 r = await api('/auth/login', { method: 'POST', data: { mobile: uM, code: '999999' } }); chk(r.code !== 1, '错误验证码被拒 → toast 文案可展示', r.msg); - // ── 页面 2:YJYF/YJYF 首页 ───────────────────────────────── - page('页面2 首页 YJYF/YJYF'); + // ── 页面 2:pages/index/index 首页 ───────────────────────────────── + page('页面2 首页 pages/index/index'); r = await api('/home/index', { token: uToken }); chk(r.code === 1 && r.data.cats.length === 15, '首页 15 个类目渲染数据就绪', '实际 ' + (r.data.cats || []).length); chk(r.data.cats.every(c => c.name && c.icon), '每个类目都有 name + icon(图标库可匹配)'); diff --git a/tests/phase2_verify.js b/tests/phase2_verify.js index 7f238f0..ff167ad 100644 --- a/tests/phase2_verify.js +++ b/tests/phase2_verify.js @@ -128,7 +128,7 @@ const sql = (s) => execFileSync('ssh', ['-o', 'BatchMode=yes', 'root@8.137.181.6 sec('切回业主身份'); r = await api('/auth/switchRole', { method: 'POST', token: token, data: { role: 'user' } }); - chk(r.code === 1 && r.data.redirect === '/YJYF/YJYF', '切回业主成功', r.data && r.data.redirect); + chk(r.code === 1 && r.data.redirect === '/pages/index/index', '切回业主成功', r.data && r.data.redirect); r = await api('/auth/switchRole', { method: 'POST', token: token, data: { role: 'xxx' } }); chk(r.code !== 1, '非法角色参数被拦截', r.msg); diff --git a/tests/phase3_merchant.js b/tests/phase3_merchant.js index 94738b7..7d4a49e 100644 --- a/tests/phase3_merchant.js +++ b/tests/phase3_merchant.js @@ -124,7 +124,7 @@ const sql = (s) => execFileSync('ssh', ['-o', 'BatchMode=yes', 'root@8.137.181.6 chk(r.data.merchant.contact === '新经理', '资料已更新'); r = await api('/auth/switchRole', { method: 'POST', token: token, data: { role: 'user' } }); - chk(r.code === 1 && r.data.redirect === '/YJYF/YJYF', '切回个人用户', r.data && r.data.redirect); + chk(r.code === 1 && r.data.redirect === '/pages/index/index', '切回个人用户', r.data && r.data.redirect); r = await api('/auth/profile', { token: token }); chk(r.data.is_merchant === true && Number(r.data.merchant.id) === Number(merchantId), 'profile 携带商家身份', 'merchant_id=' + r.data.merchant.id); diff --git a/App.vue b/yjyf-app/App.vue similarity index 94% rename from App.vue rename to yjyf-app/App.vue index 99f6e28..8c2b732 100644 --- a/App.vue +++ b/yjyf-app/App.vue @@ -1,17 +1,17 @@ - - - diff --git a/index.html b/yjyf-app/index.html similarity index 100% rename from index.html rename to yjyf-app/index.html diff --git a/main.js b/yjyf-app/main.js similarity index 100% rename from main.js rename to yjyf-app/main.js diff --git a/manifest.json b/yjyf-app/manifest.json similarity index 100% rename from manifest.json rename to yjyf-app/manifest.json diff --git a/pages.json b/yjyf-app/pages.json similarity index 97% rename from pages.json rename to yjyf-app/pages.json index 9f24204..3ab5877 100644 --- a/pages.json +++ b/yjyf-app/pages.json @@ -1,7 +1,7 @@ { "pages": [ //pages数组中第一项表示应用启动页 { - "path": "YJYF/YJYF", + "path": "pages/index/index", "style": { "navigationStyle": "custom", "navigationBarTitleText": "优匠优服", @@ -117,10 +117,6 @@ "enablePullDownRefresh": true, "backgroundTextStyle": "dark" } - }, - { - "path": "pages/index/index", - "style": { "navigationBarTitleText": "uni-app" } } ], "globalStyle": { diff --git a/pages/address/list.vue b/yjyf-app/pages/address/list.vue similarity index 100% rename from pages/address/list.vue rename to yjyf-app/pages/address/list.vue diff --git a/pages/coupon/coupon.vue b/yjyf-app/pages/coupon/coupon.vue similarity index 98% rename from pages/coupon/coupon.vue rename to yjyf-app/pages/coupon/coupon.vue index 0907cdf..d2f8e13 100644 --- a/pages/coupon/coupon.vue +++ b/yjyf-app/pages/coupon/coupon.vue @@ -68,7 +68,7 @@ if (t === 'center') loadCenter(); else loadMine(); } function switchStatus(s) { status.value = s; loadMine(); } - function goOrder() { uni.reLaunch({ url: '/YJYF/YJYF' }); } + function goOrder() { uni.reLaunch({ url: '/pages/index/index' }); } async function loadCenter() { if (!isLogin()) { toLogin(); return; } diff --git a/YJYF/YJYF.vue b/yjyf-app/pages/index/index.vue similarity index 99% rename from YJYF/YJYF.vue rename to yjyf-app/pages/index/index.vue index 5ef1257..66e2d60 100644 --- a/YJYF/YJYF.vue +++ b/yjyf-app/pages/index/index.vue @@ -315,11 +315,12 @@ uni.setClipboardData({ data: link, success: () => toast('链接已复制') }) return } - if (link.indexOf('/YJYF/') === 0) { - uni.reLaunch({ url: link }) + const targetUrl = link.replace(/^\/YJYF\/YJYF/, '/pages/index/index') + if (targetUrl === '/pages/index/index') { + uni.reLaunch({ url: targetUrl }) return } - uni.navigateTo({ url: link }) + uni.navigateTo({ url: targetUrl }) } const onCloseBanner = () => { showBanners.value = false } const onOrder = () => { diff --git a/pages/login/login.vue b/yjyf-app/pages/login/login.vue similarity index 99% rename from pages/login/login.vue rename to yjyf-app/pages/login/login.vue index 8bb4572..c571ab4 100644 --- a/pages/login/login.vue +++ b/yjyf-app/pages/login/login.vue @@ -105,7 +105,7 @@ function routeAfterLogin() { if (role.value === 'user') { - uni.reLaunch({ url: '/YJYF/YJYF' }); + uni.reLaunch({ url: '/pages/index/index' }); return; } if (role.value === 'merchant') { diff --git a/pages/master/apply.vue b/yjyf-app/pages/master/apply.vue similarity index 100% rename from pages/master/apply.vue rename to yjyf-app/pages/master/apply.vue diff --git a/pages/master/credit.vue b/yjyf-app/pages/master/credit.vue similarity index 100% rename from pages/master/credit.vue rename to yjyf-app/pages/master/credit.vue diff --git a/pages/master/hall.vue b/yjyf-app/pages/master/hall.vue similarity index 100% rename from pages/master/hall.vue rename to yjyf-app/pages/master/hall.vue diff --git a/pages/master/orders.vue b/yjyf-app/pages/master/orders.vue similarity index 100% rename from pages/master/orders.vue rename to yjyf-app/pages/master/orders.vue diff --git a/pages/master/quote.vue b/yjyf-app/pages/master/quote.vue similarity index 100% rename from pages/master/quote.vue rename to yjyf-app/pages/master/quote.vue diff --git a/pages/master/wallet.vue b/yjyf-app/pages/master/wallet.vue similarity index 100% rename from pages/master/wallet.vue rename to yjyf-app/pages/master/wallet.vue diff --git a/pages/master/workbench.vue b/yjyf-app/pages/master/workbench.vue similarity index 99% rename from pages/master/workbench.vue rename to yjyf-app/pages/master/workbench.vue index a83994b..089bbc9 100644 --- a/pages/master/workbench.vue +++ b/yjyf-app/pages/master/workbench.vue @@ -114,7 +114,7 @@ function backToUser() { api.switchRole({ role: 'user' }).then((res) => { setRole('user'); - uni.reLaunch({ url: res.redirect || '/YJYF/YJYF' }); + uni.reLaunch({ url: res.redirect || '/pages/index/index' }); }).catch(() => {}); } diff --git a/pages/merchant/apply.vue b/yjyf-app/pages/merchant/apply.vue similarity index 100% rename from pages/merchant/apply.vue rename to yjyf-app/pages/merchant/apply.vue diff --git a/pages/merchant/batch.vue b/yjyf-app/pages/merchant/batch.vue similarity index 100% rename from pages/merchant/batch.vue rename to yjyf-app/pages/merchant/batch.vue diff --git a/pages/merchant/invoice.vue b/yjyf-app/pages/merchant/invoice.vue similarity index 100% rename from pages/merchant/invoice.vue rename to yjyf-app/pages/merchant/invoice.vue diff --git a/pages/merchant/orders.vue b/yjyf-app/pages/merchant/orders.vue similarity index 100% rename from pages/merchant/orders.vue rename to yjyf-app/pages/merchant/orders.vue diff --git a/pages/merchant/workbench.vue b/yjyf-app/pages/merchant/workbench.vue similarity index 99% rename from pages/merchant/workbench.vue rename to yjyf-app/pages/merchant/workbench.vue index a4e760d..602ad0a 100644 --- a/pages/merchant/workbench.vue +++ b/yjyf-app/pages/merchant/workbench.vue @@ -183,7 +183,7 @@ function backToUser() { api.switchRole({ role: 'user' }).then((res) => { setRole('user'); - uni.reLaunch({ url: res.redirect || '/YJYF/YJYF' }); + uni.reLaunch({ url: res.redirect || '/pages/index/index' }); }).catch(() => {}); } diff --git a/pages/message/message.vue b/yjyf-app/pages/message/message.vue similarity index 100% rename from pages/message/message.vue rename to yjyf-app/pages/message/message.vue diff --git a/pages/mine/mine.vue b/yjyf-app/pages/mine/mine.vue similarity index 99% rename from pages/mine/mine.vue rename to yjyf-app/pages/mine/mine.vue index 26e1146..c053ab5 100644 --- a/pages/mine/mine.vue +++ b/yjyf-app/pages/mine/mine.vue @@ -130,7 +130,7 @@ function toast(t) { uni.showToast({ title: t, icon: 'none' }); } function go(url) { uni.navigateTo({ url: url }); } - function backHome() { uni.reLaunch({ url: '/YJYF/YJYF' }); } + function backHome() { uni.reLaunch({ url: '/pages/index/index' }); } function callService() { uni.makePhoneCall({ phoneNumber: '4000000000' }); } async function load() { diff --git a/pages/order/create.vue b/yjyf-app/pages/order/create.vue similarity index 100% rename from pages/order/create.vue rename to yjyf-app/pages/order/create.vue diff --git a/pages/order/detail.vue b/yjyf-app/pages/order/detail.vue similarity index 99% rename from pages/order/detail.vue rename to yjyf-app/pages/order/detail.vue index 3a49aba..1b21a6c 100644 --- a/pages/order/detail.vue +++ b/yjyf-app/pages/order/detail.vue @@ -145,7 +145,7 @@ } function toast(t) { uni.showToast({ title: t, icon: 'none' }); } - function backHome() { uni.reLaunch({ url: '/YJYF/YJYF' }); } + function backHome() { uni.reLaunch({ url: '/pages/index/index' }); } function cancel() { uni.showModal({ diff --git a/pages/order/list.vue b/yjyf-app/pages/order/list.vue similarity index 100% rename from pages/order/list.vue rename to yjyf-app/pages/order/list.vue diff --git a/pages/order/quick.vue b/yjyf-app/pages/order/quick.vue similarity index 100% rename from pages/order/quick.vue rename to yjyf-app/pages/order/quick.vue diff --git a/pages/order/review.vue b/yjyf-app/pages/order/review.vue similarity index 100% rename from pages/order/review.vue rename to yjyf-app/pages/order/review.vue diff --git a/pages/service/detail.vue b/yjyf-app/pages/service/detail.vue similarity index 100% rename from pages/service/detail.vue rename to yjyf-app/pages/service/detail.vue diff --git a/pages/service/list.vue b/yjyf-app/pages/service/list.vue similarity index 100% rename from pages/service/list.vue rename to yjyf-app/pages/service/list.vue diff --git a/static/icons/appliance.png b/yjyf-app/static/icons/appliance.png similarity index 100% rename from static/icons/appliance.png rename to yjyf-app/static/icons/appliance.png diff --git a/static/icons/bath.png b/yjyf-app/static/icons/bath.png similarity index 100% rename from static/icons/bath.png rename to yjyf-app/static/icons/bath.png diff --git a/static/icons/curtain.png b/yjyf-app/static/icons/curtain.png similarity index 100% rename from static/icons/curtain.png rename to yjyf-app/static/icons/curtain.png diff --git a/static/icons/door.png b/yjyf-app/static/icons/door.png similarity index 100% rename from static/icons/door.png rename to yjyf-app/static/icons/door.png diff --git a/static/icons/fitness.png b/yjyf-app/static/icons/fitness.png similarity index 100% rename from static/icons/fitness.png rename to yjyf-app/static/icons/fitness.png diff --git a/static/icons/frame.png b/yjyf-app/static/icons/frame.png similarity index 100% rename from static/icons/frame.png rename to yjyf-app/static/icons/frame.png diff --git a/static/icons/kitchen.png b/yjyf-app/static/icons/kitchen.png similarity index 100% rename from static/icons/kitchen.png rename to yjyf-app/static/icons/kitchen.png diff --git a/static/icons/lamp.png b/yjyf-app/static/icons/lamp.png similarity index 100% rename from static/icons/lamp.png rename to yjyf-app/static/icons/lamp.png diff --git a/static/icons/lock.png b/yjyf-app/static/icons/lock.png similarity index 100% rename from static/icons/lock.png rename to yjyf-app/static/icons/lock.png diff --git a/static/icons/more.png b/yjyf-app/static/icons/more.png similarity index 100% rename from static/icons/more.png rename to yjyf-app/static/icons/more.png diff --git a/static/icons/rack.png b/yjyf-app/static/icons/rack.png similarity index 100% rename from static/icons/rack.png rename to yjyf-app/static/icons/rack.png diff --git a/static/icons/shower.png b/yjyf-app/static/icons/shower.png similarity index 100% rename from static/icons/shower.png rename to yjyf-app/static/icons/shower.png diff --git a/static/icons/sofa.png b/yjyf-app/static/icons/sofa.png similarity index 100% rename from static/icons/sofa.png rename to yjyf-app/static/icons/sofa.png diff --git a/static/icons/tv.png b/yjyf-app/static/icons/tv.png similarity index 100% rename from static/icons/tv.png rename to yjyf-app/static/icons/tv.png diff --git a/static/icons/water.png b/yjyf-app/static/icons/water.png similarity index 100% rename from static/icons/water.png rename to yjyf-app/static/icons/water.png diff --git a/static/logo.png b/yjyf-app/static/logo.png similarity index 100% rename from static/logo.png rename to yjyf-app/static/logo.png diff --git a/uni.promisify.adaptor.js b/yjyf-app/uni.promisify.adaptor.js similarity index 100% rename from uni.promisify.adaptor.js rename to yjyf-app/uni.promisify.adaptor.js diff --git a/uni.scss b/yjyf-app/uni.scss similarity index 96% rename from uni.scss rename to yjyf-app/uni.scss index 62eb87b..b9249e9 100644 --- a/uni.scss +++ b/yjyf-app/uni.scss @@ -1,76 +1,76 @@ -/** - * 这里是uni-app内置的常用样式变量 - * - * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量 - * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App - * - */ - -/** - * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能 - * - * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件 - */ - -/* 颜色变量 */ - -/* 行为相关颜色 */ -$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:12px; -$uni-font-size-base:14px; -$uni-font-size-lg:16px; - -/* 图片尺寸 */ -$uni-img-size-sm:20px; -$uni-img-size-base:26px; -$uni-img-size-lg:40px; - -/* Border Radius */ -$uni-border-radius-sm: 2px; -$uni-border-radius-base: 3px; -$uni-border-radius-lg: 6px; -$uni-border-radius-circle: 50%; - -/* 水平间距 */ -$uni-spacing-row-sm: 5px; -$uni-spacing-row-base: 10px; -$uni-spacing-row-lg: 15px; - -/* 垂直间距 */ -$uni-spacing-col-sm: 4px; -$uni-spacing-col-base: 8px; -$uni-spacing-col-lg: 12px; - -/* 透明度 */ -$uni-opacity-disabled: 0.3; // 组件禁用态的透明度 - -/* 文章场景相关 */ -$uni-color-title: #2C405A; // 文章标题颜色 -$uni-font-size-title:20px; -$uni-color-subtitle: #555555; // 二级标题颜色 -$uni-font-size-subtitle:26px; -$uni-color-paragraph: #3F536E; // 文章段落颜色 -$uni-font-size-paragraph:15px; +/** + * 这里是uni-app内置的常用样式变量 + * + * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量 + * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App + * + */ + +/** + * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能 + * + * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件 + */ + +/* 颜色变量 */ + +/* 行为相关颜色 */ +$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:12px; +$uni-font-size-base:14px; +$uni-font-size-lg:16px; + +/* 图片尺寸 */ +$uni-img-size-sm:20px; +$uni-img-size-base:26px; +$uni-img-size-lg:40px; + +/* Border Radius */ +$uni-border-radius-sm: 2px; +$uni-border-radius-base: 3px; +$uni-border-radius-lg: 6px; +$uni-border-radius-circle: 50%; + +/* 水平间距 */ +$uni-spacing-row-sm: 5px; +$uni-spacing-row-base: 10px; +$uni-spacing-row-lg: 15px; + +/* 垂直间距 */ +$uni-spacing-col-sm: 4px; +$uni-spacing-col-base: 8px; +$uni-spacing-col-lg: 12px; + +/* 透明度 */ +$uni-opacity-disabled: 0.3; // 组件禁用态的透明度 + +/* 文章场景相关 */ +$uni-color-title: #2C405A; // 文章标题颜色 +$uni-font-size-title:20px; +$uni-color-subtitle: #555555; // 二级标题颜色 +$uni-font-size-subtitle:26px; +$uni-color-paragraph: #3F536E; // 文章段落颜色 +$uni-font-size-paragraph:15px; diff --git a/utils/api.js b/yjyf-app/utils/api.js similarity index 100% rename from utils/api.js rename to yjyf-app/utils/api.js diff --git a/utils/request.js b/yjyf-app/utils/request.js similarity index 100% rename from utils/request.js rename to yjyf-app/utils/request.js diff --git a/utils/role.js b/yjyf-app/utils/role.js similarity index 100% rename from utils/role.js rename to yjyf-app/utils/role.js diff --git a/utils/wxlogin.js b/yjyf-app/utils/wxlogin.js similarity index 100% rename from utils/wxlogin.js rename to yjyf-app/utils/wxlogin.js