From eabd11b7775c7e6cf5adceb9fc5e39e36a6901ad Mon Sep 17 00:00:00 2001
From: BianLzhaoMin <11485688+bianliangzhaomin123@user.noreply.gitee.com>
Date: Thu, 19 Dec 2024 18:25:30 +0800
Subject: [PATCH] =?UTF-8?q?=E9=9C=80=E6=B1=82=E5=A4=A7=E5=8E=85=20?=
=?UTF-8?q?=E8=A3=85=E5=A4=87=E5=A4=A7=E5=8E=85=20=E9=9C=80=E6=B1=82?=
=?UTF-8?q?=E5=8F=91=E5=B8=83=20=E7=AD=89=E9=A1=B5=E9=9D=A2=E5=8A=9F?=
=?UTF-8?q?=E8=83=BD=E5=AE=8C=E5=96=84?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
package-lock.json | 17 +
package.json | 2 +
src/App.vue | 7 +-
src/components/Navbar/index.vue | 23 ++
src/components/SearchIpt/index.vue | 115 +++++++
src/components/TitleTip/index.vue | 29 ++
src/pages.json | 89 +++--
src/pages/demand-release/index.vue | 312 ++++++++++++++++++
.../components/details-model.vue | 2 +-
src/pages/goods-list/index.vue | 137 ++++++++
src/pages/index/index-old.vue | 115 +++++++
src/pages/index/index.vue | 242 ++++++++------
src/pages/lease-demand/index.vue | 247 +++++++++++++-
src/pages/login/index.vue | 3 +-
src/pages/message/index.vue | 3 -
src/pages/order/index.vue | 134 ++++++--
src/services/common/index.js | 11 +
src/services/demand/index.js | 32 ++
src/static/demand/header_bg.png | Bin 0 -> 122955 bytes
src/static/index/notice.png | Bin 0 -> 4039 bytes
src/static/index/to_do_list.png | Bin 0 -> 5035 bytes
src/static/tab-bar/car.png | Bin 0 -> 1949 bytes
src/static/tab-bar/home_sel.png | Bin 0 -> 3497 bytes
src/static/tab-bar/lease.png | Bin 0 -> 2931 bytes
src/static/tab-bar/lease_sel.png | Bin 0 -> 4596 bytes
src/static/tab-bar/message.png | Bin 0 -> 2323 bytes
src/static/tab-bar/user.png | Bin 0 -> 1964 bytes
src/static/tab-bar/user_sel.png | Bin 0 -> 3283 bytes
src/style/vant.scss | 4 +
29 files changed, 1359 insertions(+), 165 deletions(-)
create mode 100644 src/components/Navbar/index.vue
create mode 100644 src/components/SearchIpt/index.vue
create mode 100644 src/components/TitleTip/index.vue
create mode 100644 src/pages/demand-release/index.vue
create mode 100644 src/pages/goods-list/index.vue
create mode 100644 src/pages/index/index-old.vue
create mode 100644 src/services/common/index.js
create mode 100644 src/services/demand/index.js
create mode 100644 src/static/demand/header_bg.png
create mode 100644 src/static/index/notice.png
create mode 100644 src/static/index/to_do_list.png
create mode 100644 src/static/tab-bar/car.png
create mode 100644 src/static/tab-bar/home_sel.png
create mode 100644 src/static/tab-bar/lease.png
create mode 100644 src/static/tab-bar/lease_sel.png
create mode 100644 src/static/tab-bar/message.png
create mode 100644 src/static/tab-bar/user.png
create mode 100644 src/static/tab-bar/user_sel.png
diff --git a/package-lock.json b/package-lock.json
index f1e28a7..9b780f6 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -23,8 +23,10 @@
"@dcloudio/uni-mp-weixin": "3.0.0-4020420240722002",
"@dcloudio/uni-mp-xhs": "3.0.0-4020420240722002",
"@dcloudio/uni-quickapp-webview": "3.0.0-4020420240722002",
+ "@vant/area-data": "^2.0.0",
"less": "^4.2.1",
"less-loader": "^12.2.0",
+ "moment": "^2.30.1",
"pinia": "^2.3.0",
"pinia-plugin-persistedstate": "^4.1.3",
"vant": "^4.9.10",
@@ -4867,6 +4869,12 @@
"license": "MIT",
"peer": true
},
+ "node_modules/@vant/area-data": {
+ "version": "2.0.0",
+ "resolved": "https://repo.huaweicloud.com/repository/npm/@vant/area-data/-/area-data-2.0.0.tgz",
+ "integrity": "sha512-zgP4AA8z09S9QTNgVCCHo9cHjcybrv22RJDYPjuCkecn4SB98T5EoPQh2TwqbQXmUhbaOGgiZGy3OUaUxnY7qg==",
+ "license": "MIT"
+ },
"node_modules/@vant/auto-import-resolver": {
"version": "1.2.1",
"resolved": "https://repo.huaweicloud.com/repository/npm/@vant/auto-import-resolver/-/auto-import-resolver-1.2.1.tgz",
@@ -9820,6 +9828,15 @@
"integrity": "sha512-23g5BFj4zdQL/b6tor7Ji+QY4pEfNH784BMslY9Qb0UnJWRAt+lQGLYmRaM0KDBwIG23ffEBELhZDP2rhi9f/Q==",
"license": "MIT"
},
+ "node_modules/moment": {
+ "version": "2.30.1",
+ "resolved": "https://repo.huaweicloud.com/repository/npm/moment/-/moment-2.30.1.tgz",
+ "integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how==",
+ "license": "MIT",
+ "engines": {
+ "node": "*"
+ }
+ },
"node_modules/ms": {
"version": "2.1.3",
"resolved": "https://repo.huaweicloud.com/repository/npm/ms/-/ms-2.1.3.tgz",
diff --git a/package.json b/package.json
index 0b686ca..a2732cc 100644
--- a/package.json
+++ b/package.json
@@ -57,8 +57,10 @@
"@dcloudio/uni-mp-weixin": "3.0.0-4020420240722002",
"@dcloudio/uni-mp-xhs": "3.0.0-4020420240722002",
"@dcloudio/uni-quickapp-webview": "3.0.0-4020420240722002",
+ "@vant/area-data": "^2.0.0",
"less": "^4.2.1",
"less-loader": "^12.2.0",
+ "moment": "^2.30.1",
"pinia": "^2.3.0",
"pinia-plugin-persistedstate": "^4.1.3",
"vant": "^4.9.10",
diff --git a/src/App.vue b/src/App.vue
index 47f4b07..2beebda 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -32,8 +32,11 @@ scroll-view {
height: 100%;
overflow: hidden;
}
-.van-nav-bar__content {
- background-color: $uni-navbar-bg-color;
+:deep(.van-nav-bar__content) {
+ background-color: #75aea4;
+ .van-nav-bar__text {
+ color: #333;
+ }
}
.ellipsis {
diff --git a/src/components/Navbar/index.vue b/src/components/Navbar/index.vue
new file mode 100644
index 0000000..c822528
--- /dev/null
+++ b/src/components/Navbar/index.vue
@@ -0,0 +1,23 @@
+
+
+
+
+
+
+
diff --git a/src/components/SearchIpt/index.vue b/src/components/SearchIpt/index.vue
new file mode 100644
index 0000000..e9939c8
--- /dev/null
+++ b/src/components/SearchIpt/index.vue
@@ -0,0 +1,115 @@
+
+
+
+ {
+ isSelectShow = !isSelectShow
+ }
+ "
+ >
+ {{ activeTypeName }}
+
+
+
+ {
+ activeTypeName = '机具'
+ isSelectShow = !isSelectShow
+ }
+ "
+ >
+ 机具
+
+ {
+ activeTypeName = '需求'
+ isSelectShow = !isSelectShow
+ }
+ "
+ >
+ 需求
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/components/TitleTip/index.vue b/src/components/TitleTip/index.vue
new file mode 100644
index 0000000..5784cbc
--- /dev/null
+++ b/src/components/TitleTip/index.vue
@@ -0,0 +1,29 @@
+
+
+
+
+ 订单数据
+
+
+
+
+
+
diff --git a/src/pages.json b/src/pages.json
index 45bce25..6a486a3 100644
--- a/src/pages.json
+++ b/src/pages.json
@@ -7,16 +7,25 @@
"navigationBarTitleText": "登录"
}
},
+ // 首页
{
"path": "pages/index/index",
"style": {
- "navigationBarTitleText": "首页"
+ "navigationStyle": "custom"
}
},
+ // 租赁需求大厅
{
"path": "pages/lease-demand/index",
"style": {
- "navigationBarTitleText": "租赁需求"
+ "navigationStyle": "custom"
+ }
+ },
+ // 需求发布
+ {
+ "path": "pages/demand-release/index",
+ "style": {
+ "navigationStyle": "custom"
}
},
{
@@ -48,42 +57,56 @@
"style": {
"navigationBarTitleText": "订单结算"
}
+ },
+ // 装备列表大厅
+ {
+ "path": "pages/goods-list/index",
+ "style": {
+ "navigationStyle": "custom"
+ }
}
],
- // "tabBar": {
- // "color": "#2c2c2c",
- // "selectedColor": "#00ad9d",
- // "borderStyle": "black",
- // "backgroundColor": "#FFFFFF",
- // "iconWidth": "24px",
- // "list": [
- // {
- // "pagePath": "pages/index/index",
- // "text": "首页"
- // },
- // {
- // "pagePath": "pages/lease-demand/index",
- // "text": "租赁需求"
- // },
- // {
- // "pagePath": "pages/cart/index",
- // "text": "预约车"
- // },
- // {
- // "pagePath": "pages/message/index",
- // "text": "消息"
- // },
- // {
- // "pagePath": "pages/my/index",
- // "text": "我的"
- // }
- // ]
- // },
+ "tabBar": {
+ "color": "#2c2c2c",
+ "selectedColor": "#00ad9d",
+ "borderStyle": "black",
+ "backgroundColor": "#FFFFFF",
+ "iconWidth": "24px",
+ "list": [
+ {
+ "pagePath": "pages/index/index",
+ "text": "首页",
+ "iconPath": "static/tab-bar/home_sel.png"
+ },
+ {
+ "pagePath": "pages/lease-demand/index",
+ "text": "租赁需求",
+ "iconPath": "static/tab-bar/lease.png",
+ "selectedIconPath": "static/tab-bar/lease_sel.png"
+ },
+ {
+ "pagePath": "pages/cart/index",
+ "text": "预约车",
+ "iconPath": "static/tab-bar/car.png",
+ "visible": false
+ },
+ {
+ "pagePath": "pages/message/index",
+ "text": "消息",
+ "iconPath": "static/tab-bar/message.png"
+ },
+ {
+ "pagePath": "pages/my/index",
+ "text": "我的",
+ "iconPath": "static/tab-bar/user.png",
+ "selectedIconPath": "static/tab-bar/user_sel.png"
+ }
+ ]
+ },
"globalStyle": {
"navigationBarTextStyle": "#fff",
"navigationBarTitleText": "uni-app",
"navigationBarBackgroundColor": "#00a288",
- "backgroundColor": "#00a288",
- "navigationStyle": "custom"
+ "backgroundColor": "#00a288"
}
}
diff --git a/src/pages/demand-release/index.vue b/src/pages/demand-release/index.vue
new file mode 100644
index 0000000..7c87a57
--- /dev/null
+++ b/src/pages/demand-release/index.vue
@@ -0,0 +1,312 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 添加需求描述
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 提交
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/goods-details/components/details-model.vue b/src/pages/goods-details/components/details-model.vue
index 626d9ef..1ad89a4 100644
--- a/src/pages/goods-details/components/details-model.vue
+++ b/src/pages/goods-details/components/details-model.vue
@@ -89,7 +89,7 @@ const getDeviceDetailsData = async () => {
console.log(res, '装备详情')
}
const onRentNow = () => {
- uni.navigateTo({ url: '/pages/order/index' })
+ uni.navigateTo({ url: `/pages/order/index?id=${deviceInfo.value.maId}` })
}
onLoad(() => {
diff --git a/src/pages/goods-list/index.vue b/src/pages/goods-list/index.vue
new file mode 100644
index 0000000..dfcfb91
--- /dev/null
+++ b/src/pages/goods-list/index.vue
@@ -0,0 +1,137 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 使用年限
+
+
+
+ 租金
+
+
+
+ 上架时间
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/index/index-old.vue b/src/pages/index/index-old.vue
new file mode 100644
index 0000000..4092e11
--- /dev/null
+++ b/src/pages/index/index-old.vue
@@ -0,0 +1,115 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 使用年限
+
+
+
+ 租金
+
+
+
+ 上架时间
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/pages/index/index.vue b/src/pages/index/index.vue
index af12f65..5d74cf0 100644
--- a/src/pages/index/index.vue
+++ b/src/pages/index/index.vue
@@ -1,126 +1,178 @@
-
-
-
-
-
-
+
+
diff --git a/src/pages/lease-demand/index.vue b/src/pages/lease-demand/index.vue
index 8797bad..8cb6abd 100644
--- a/src/pages/lease-demand/index.vue
+++ b/src/pages/lease-demand/index.vue
@@ -1,18 +1,249 @@
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+ 发布机具需求信息
+
+
+
+
+
+
+ 使用年限
+
+
+
+ 租金
+
+
+
+ 上架时间
+
+
+
+
+
+
+
+
+
+
+ {{ d.leaseName }}
+
+
+ 剩余:
+
+
+
+ {{
+ timeData.days > 10 ? timeData.days : '0' + timeData.days
+ }}
+
+ 天
+
+ {{
+ timeData.hours > 10
+ ? timeData.hours
+ : '0' + timeData.hours
+ }}
+
+ 时
+ {{
+ timeData.minutes > 10
+ ? timeData.minutes
+ : '0' + timeData.minutes
+ }}
+
+ 分
+
+
+
+
+
+ 装备类目:
+
+
+
+ 租赁公司: {{ d.companyName }}
+ 联系电话: {{ d.personPhone }}
+
+
+ 联系人: {{ d.person }}
+ 预估租期(天): {{ d.leaseDay }}
+
+
+ 预估数量: {{ d.leaseTotalNum }}
+ 截止时间: {{ d.endTime }}
+
+
+
+
+ 需求详情
+
+ 接单
+
+
+
+
+
+
-
diff --git a/src/pages/login/index.vue b/src/pages/login/index.vue
index c3c8ed0..32ab9f4 100644
--- a/src/pages/login/index.vue
+++ b/src/pages/login/index.vue
@@ -56,7 +56,8 @@ const onSubmitLogin = async () => {
if (userResult.code === 200) {
showToast('登录成功')
setTimeout(() => {
- uni.navigateTo({ url: '/pages/index/index' })
+ // uni.navigateTo({ url: '/pages/index/index' })
+ uni.switchTab({ url: '/pages/index/index' })
}, 500)
}
}
diff --git a/src/pages/message/index.vue b/src/pages/message/index.vue
index 26f3927..a06d3d1 100644
--- a/src/pages/message/index.vue
+++ b/src/pages/message/index.vue
@@ -1,8 +1,5 @@
-
-
-