From a81784463f06d04e3b94b6ae6b03f12927973808 Mon Sep 17 00:00:00 2001 From: wjt <1797368093@qq.com> Date: 星期四, 20 六月 2024 16:19:44 +0800 Subject: [PATCH] 申请记录页面 --- policy/applyRecord/applyRecord.scss | 104 +++++++++ policy/reportPage/reportPage.vue | 15 + policy/applyRecord/applyRecord.vue | 131 +++++++++++ policy/reportRecord/reportRecord.vue | 119 ++++++++++ policy/components/index.vue | 7 policy/reportDetails/reportDetails.scss | 66 ++++++ policy/reportDetails/reportDetails.vue | 109 +++++++++ pages.json | 14 + policy/reportRecord/reportRecord.scss | 81 +++++++ 9 files changed, 636 insertions(+), 10 deletions(-) diff --git a/pages.json b/pages.json index 28497cb..94f97e3 100644 --- a/pages.json +++ b/pages.json @@ -85,6 +85,20 @@ { "navigationBarTitleText" : "涓婃姤缁撴灉" } + }, + { + "path" : "reportRecord/reportRecord", + "style" : + { + "navigationBarTitleText" : "涓婃姤璁板綍" + } + }, + { + "path" : "applyRecord/applyRecord", + "style" : + { + "navigationBarTitleText" : "鐢宠璁板綍" + } } ] } diff --git a/policy/applyRecord/applyRecord.scss b/policy/applyRecord/applyRecord.scss new file mode 100644 index 0000000..673bb9b --- /dev/null +++ b/policy/applyRecord/applyRecord.scss @@ -0,0 +1,104 @@ +.page-box{ + padding-bottom: 40rpx; + .list{ + margin: 20rpx 32rpx; + .list-item{ + padding: 24rpx; + background-color: white; + border-radius: 10rpx; + margin-bottom: 20rpx; + .top-title{ + display: flex; + justify-content: space-between; + align-items: center; + font-size: 32rpx; + margin-bottom: 28rpx; + .status{ + font-size: 28rpx; + color: #B4B9BF; + } + .status1{ + color: #FE7B32; + } + .status2{ + color: #3EB47A; + } + .status3{ + color: #1171E0; + } + .status4{ + color: #EB4746; + } + } + .user-info{ + font-size: 28rpx; + color: #4A4E60; + display: flex; + justify-content: flex-start; + align-items: center; + .driver{ + width: 2rpx; + height: 20rpx; + background: #F1F1F1; + margin: 0 20rpx; + } + } + .set-line{ + font-size: 26rpx; + color: #4A4E60; + margin-top: 12rpx; + text{ + color: #C3C6CD; + } + } + .line{ + border-bottom: 3rpx dotted #F4F4F4; + margin: 24rpx 0; + } + .set-line1{ + font-size: 24rpx; + color: #4A4E60; + margin-top: 12rpx; + text{ + color: #C3C6CD; + } + } + .button{ + background-color: #1171E0; + display: inline-block; + color: white; + padding: 10rpx 36rpx; + border-radius: 10rpx; + } + .set-start{ + align-items: flex-end; + } + } + } + .down{ + position: fixed; + background: white; + width: 100%; + bottom: 0; + padding: 32rpx 22rpx 40rpx; + text-align: center; + box-sizing: border-box; + .button{ + border-radius: 20rpx; + border: 2rpx solid #ABD2FF; + background: #F0F8FF; + color: #1171E0; + padding: 20rpx 0; + } + } + .set-search{ + margin: 0 32rpx 0; + padding-top: 26rpx; + + } + .border{ + border-bottom: 2rpx solid #F6F6F6; + margin: 20rpx 0 0; + } + +} \ No newline at end of file diff --git a/policy/applyRecord/applyRecord.vue b/policy/applyRecord/applyRecord.vue new file mode 100644 index 0000000..9eeb076 --- /dev/null +++ b/policy/applyRecord/applyRecord.vue @@ -0,0 +1,131 @@ +<template> + <view class="page-box"> + <u-sticky bgColor="white"> + <view class="set-search"> + <u-search placeholder="璇疯緭鍏ョ敵璇疯褰曞叧閿瘝 " shape="square" :showAction="false"></u-search> + </view> + <view class="border"></view> + <u-tabs :list="list1" @click="click" :scrollable="false" bgColor="white"></u-tabs> + </u-sticky> + <view class="list"> + <view class="list-item" @click="goReport"> + <view class="top-title"> + <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> + <text class="status">宸茬粨鏉�</text> + </view> + <view class="user-info"> + <text>鐜嬫�濋洦</text> + <view class="driver"></view> + <text>鎵ф硶涓�澶ч槦</text> + </view> + <view class="set-line"> + <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃 + </view> + <view class="line"></view> + <view class="set-flex set-start set-flex-content-between"> + <view> + <view class="set-line1"> + <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00 + </view> + <view class="set-line1"> + <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12 + </view> + </view> + + </view> + </view> + <view class="list-item"> + <view class="top-title"> + <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> + <text class="status">宸茬粨鏉�</text> + </view> + <view class="user-info"> + <text>鐜嬫�濋洦</text> + <view class="driver"></view> + <text>鎵ф硶涓�澶ч槦</text> + </view> + <view class="set-line"> + <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃 + </view> + <view class="line"></view> + <view class="set-flex set-start set-flex-content-between"> + <view> + <view class="set-line1"> + <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00 + </view> + <view class="set-line1"> + <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12 + </view> + </view> + + </view> + </view> + <view class="list-item"> + <view class="top-title"> + <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> + <text class="status">宸茬粨鏉�</text> + </view> + <view class="user-info"> + <text>鐜嬫�濋洦</text> + <view class="driver"></view> + <text>鎵ф硶涓�澶ч槦</text> + </view> + <view class="set-line"> + <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃 + </view> + <view class="line"></view> + <view class="set-flex set-start set-flex-content-between"> + <view> + <view class="set-line1"> + <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00 + </view> + <view class="set-line1"> + <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12 + </view> + </view> + + </view> + </view> + </view> + </view> +</template> + +<script> + export default { + data() { + return { + list1: [{ + name: '鍏ㄩ儴', + }, { + name: '寰呭鎵�', + }, { + name: '寰呮墽琛�', + }, { + name: '寰呬笂鎶�', + }, { + name: '宸叉嫆缁�', + }, { + name: '宸茬粨鏉�', + }] + } + }, + methods: { + goReport() { + uni.navigateTo({ + url: `/policy/reportDetails/reportDetails` + }) + }, + click() { + + } + } + } +</script> +<style> + page { + background-color: #F4F4F4; + } +</style> +<style lang="scss" scoped> + @import "./applyRecord.scss"; +</style> \ No newline at end of file diff --git a/policy/components/index.vue b/policy/components/index.vue index cf7193e..00c4bf3 100644 --- a/policy/components/index.vue +++ b/policy/components/index.vue @@ -22,7 +22,7 @@ <u-button @click="applyPulicy">鎵ф硶鐢宠</u-button> <u-button v-if="isJudge">鎵ф硶瀹℃壒</u-button> <u-button @click="report">鎵ф硶缁撴灉涓婃姤</u-button> - <u-button>璁板綍鏌ヨ</u-button> + <u-button @click="applyRecord">璁板綍鏌ヨ</u-button> <u-button @click="goDataLook">鏁版嵁鐪嬫澘</u-button> </view> </view> @@ -65,6 +65,11 @@ uni.navigateTo({ url: '/policy/reportPage/reportPage' }) + }, + applyRecord() { + uni.navigateTo({ + url: '/policy/applyRecord/applyRecord' + }) } } } diff --git a/policy/reportDetails/reportDetails.scss b/policy/reportDetails/reportDetails.scss new file mode 100644 index 0000000..3f70ea9 --- /dev/null +++ b/policy/reportDetails/reportDetails.scss @@ -0,0 +1,66 @@ +.page-box{ + padding-bottom: 220rpx; +} +.box{ + margin: 32rpx; + background-color: white; + border-radius: 10rpx; + padding: 24rpx; + + .form-item{ + display: flex; + justify-content: space-between; + align-items: center; + font-size: 30rpx; + border-bottom: 2rpx solid #F4F4F4; + padding-bottom: 24rpx; + margin-bottom: 24rpx; + .label{ + color: #7E8596; + } + + } + .form-input-item{ + margin-bottom: 24rpx; + } + .form-input-item:last-child{ + margin-bottom: 0; + } + .form-item:last-child{ + margin: 0; + padding: 0; + border: none; + } + .form-label{ + margin-bottom: 16rpx; + color: #4A4E60; + } + .require::after{ + content: '*'; + color: #FF7500; + } + /deep/ .u-textarea{ + background-color: #F4F4F4; + border: none; + .u-textarea__count{ + background: none !important; + } + } + +} + .down{ + position: fixed; + background: white; + width: 100%; + bottom: 0; + padding: 32rpx 22rpx 40rpx; + text-align: center; + box-sizing: border-box; + .button{ + border-radius: 20rpx; + border: 2rpx solid #1171E0; + background: #1171E0; + color: white; + padding: 20rpx 0; + } + } \ No newline at end of file diff --git a/policy/reportDetails/reportDetails.vue b/policy/reportDetails/reportDetails.vue index 8183fd0..ad98574 100644 --- a/policy/reportDetails/reportDetails.vue +++ b/policy/reportDetails/reportDetails.vue @@ -1,6 +1,53 @@ <template> - <view> - + <view class="page-box"> + <view class="box"> + <view class="form"> + <view class="form-item"> + <view class="label">鎵ф硶涓婚</view> + <view class="input">24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view> + </view> + <view class="form-item"> + <view class="label">鎵ф硶瀵硅薄</view> + <view class="input">24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view> + </view> + <view class="form-item"> + <view class="label">鎵ф硶鏃堕棿</view> + <view class="input">24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view> + </view> + <view class="form-item"> + <view class="label">鎵ф硶绫诲瀷</view> + <view class="input">24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view> + </view> + <view class="form-item"> + <view class="label">鎵ф硶浜哄憳</view> + <view class="input">24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view> + </view> + <view class="form-item"> + <view class="label">鎵ф硶閮ㄩ棬</view> + <view class="input">24骞�5鏈堜唤娑堥槻绐佸嚮妫�鏌�</view> + </view> + </view> + </view> + <view class="box"> + <view class="form-input"> + <view class="form-input-item"> + <view class="form-label require">鎵ф硶缁撴灉</view> + <u-textarea count v-model="form.reasoon" maxlength="500"></u-textarea> + </view> + <view class="form-input-item"> + <view class="form-label require">鎵ф硶鐓х墖</view> + <view> + <u-upload :fileList="fileList1" @afterRead="afterRead" @delete="deletePic" name="1" multiple + :maxCount="10"></u-upload> + </view> + </view> + </view> + </view> + <view class="down"> + <view class="button"> + 涓婃姤璁板綍 + </view> + </view> </view> </template> @@ -8,15 +55,65 @@ export default { data() { return { - + form: { + reasoon: '' + }, + fileList1: [] } }, methods: { - + // 鍒犻櫎鍥剧墖 + deletePic(event) { + this[`fileList${event.name}`].splice(event.index, 1) + }, + // 鏂板鍥剧墖 + async afterRead(event) { + // 褰撹缃� multiple 涓� true 鏃�, file 涓烘暟缁勬牸寮忥紝鍚﹀垯涓哄璞℃牸寮� + let lists = [].concat(event.file) + let fileListLen = this[`fileList${event.name}`].length + lists.map((item) => { + this[`fileList${event.name}`].push({ + ...item, + status: 'uploading', + message: '涓婁紶涓�' + }) + }) + for (let i = 0; i < lists.length; i++) { + const result = await this.uploadFilePromise(lists[i].url) + let item = this[`fileList${event.name}`][fileListLen] + this[`fileList${event.name}`].splice(fileListLen, 1, Object.assign(item, { + status: 'success', + message: '', + url: result + })) + fileListLen++ + } + }, + uploadFilePromise(url) { + return new Promise((resolve, reject) => { + let a = uni.uploadFile({ + url: 'http://192.168.2.21:7001/upload', // 浠呬负绀轰緥锛岄潪鐪熷疄鐨勬帴鍙e湴鍧� + filePath: url, + name: 'file', + formData: { + user: 'test' + }, + success: (res) => { + setTimeout(() => { + resolve(res.data.data) + }, 1000) + } + }); + }) + }, } } </script> - <style> - + page { + background-color: #F4F4F4; + } </style> +<style lang="scss" scoped> + @import "./reportDetails.scss"; +</style> \ No newline at end of file diff --git a/policy/reportPage/reportPage.vue b/policy/reportPage/reportPage.vue index a1aebde..442e8fc 100644 --- a/policy/reportPage/reportPage.vue +++ b/policy/reportPage/reportPage.vue @@ -1,7 +1,7 @@ <template> <view class="page-box"> <view class="list"> - <view class="list-item"> + <view class="list-item" @click="goReport"> <view class="top-title"> <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> <text class="status">寰呬笂鎶�</text> @@ -87,7 +87,7 @@ </view> </view> <view class="down"> - <view class="button"> + <view class="button" @click="goRecord"> 涓婃姤璁板綍 </view> </view> @@ -102,7 +102,16 @@ } }, methods: { - + goReport() { + uni.navigateTo({ + url: `/policy/reportRecord/reportRecord` + }) + }, + goRecord() { + uni.navigateTo({ + url: `/policy/reportRecord/reportRecord` + }) + } } } </script> diff --git a/policy/reportRecord/reportRecord.scss b/policy/reportRecord/reportRecord.scss new file mode 100644 index 0000000..e3fbbf3 --- /dev/null +++ b/policy/reportRecord/reportRecord.scss @@ -0,0 +1,81 @@ +.page-box{ + .list{ + margin: 20rpx 32rpx; + .list-item{ + padding: 24rpx; + background-color: white; + border-radius: 10rpx; + margin-bottom: 20rpx; + .top-title{ + display: flex; + justify-content: space-between; + align-items: center; + font-size: 32rpx; + margin-bottom: 28rpx; + .status{ + font-size: 28rpx; + color: #B4B9BF; + } + } + .user-info{ + font-size: 28rpx; + color: #4A4E60; + display: flex; + justify-content: flex-start; + align-items: center; + .driver{ + width: 2rpx; + height: 20rpx; + background: #F1F1F1; + margin: 0 20rpx; + } + } + .set-line{ + font-size: 26rpx; + color: #4A4E60; + margin-top: 12rpx; + text{ + color: #C3C6CD; + } + } + .line{ + border-bottom: 3rpx dotted #F4F4F4; + margin: 24rpx 0; + } + .set-line1{ + font-size: 24rpx; + color: #4A4E60; + margin-top: 12rpx; + text{ + color: #C3C6CD; + } + } + .button{ + background-color: #1171E0; + display: inline-block; + color: white; + padding: 10rpx 36rpx; + border-radius: 10rpx; + } + .set-start{ + align-items: flex-end; + } + } + } + .down{ + position: fixed; + background: white; + width: 100%; + bottom: 0; + padding: 32rpx 22rpx 40rpx; + text-align: center; + box-sizing: border-box; + .button{ + border-radius: 20rpx; + border: 2rpx solid #ABD2FF; + background: #F0F8FF; + color: #1171E0; + padding: 20rpx 0; + } + } +} \ No newline at end of file diff --git a/policy/reportRecord/reportRecord.vue b/policy/reportRecord/reportRecord.vue new file mode 100644 index 0000000..b0da701 --- /dev/null +++ b/policy/reportRecord/reportRecord.vue @@ -0,0 +1,119 @@ +<template> + <view class="page-box"> + <u-sticky bgColor="white"> + <u-tabs :list="list1" @click="click" :scrollable="false" bgColor="white"></u-tabs> + </u-sticky> + <view class="list"> + <view class="list-item" @click="goReport"> + <view class="top-title"> + <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> + <text class="status">宸茬粨鏉�</text> + </view> + <view class="user-info"> + <text>鐜嬫�濋洦</text> + <view class="driver"></view> + <text>鎵ф硶涓�澶ч槦</text> + </view> + <view class="set-line"> + <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃 + </view> + <view class="line"></view> + <view class="set-flex set-start set-flex-content-between"> + <view> + <view class="set-line1"> + <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00 + </view> + <view class="set-line1"> + <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12 + </view> + </view> + + </view> + </view> + <view class="list-item"> + <view class="top-title"> + <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> + <text class="status">宸茬粨鏉�</text> + </view> + <view class="user-info"> + <text>鐜嬫�濋洦</text> + <view class="driver"></view> + <text>鎵ф硶涓�澶ч槦</text> + </view> + <view class="set-line"> + <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃 + </view> + <view class="line"></view> + <view class="set-flex set-start set-flex-content-between"> + <view> + <view class="set-line1"> + <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00 + </view> + <view class="set-line1"> + <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12 + </view> + </view> + + </view> + </view> + <view class="list-item"> + <view class="top-title"> + <text>24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</text> + <text class="status">宸茬粨鏉�</text> + </view> + <view class="user-info"> + <text>鐜嬫�濋洦</text> + <view class="driver"></view> + <text>鎵ф硶涓�澶ч槦</text> + </view> + <view class="set-line"> + <text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃 + </view> + <view class="line"></view> + <view class="set-flex set-start set-flex-content-between"> + <view> + <view class="set-line1"> + <text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00 + </view> + <view class="set-line1"> + <text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12 + </view> + </view> + + </view> + </view> + </view> + </view> +</template> + +<script> + export default { + data() { + return { + list1: [{ + name: '寰呬笂鎶�', + }, { + name: '宸蹭笂鎶�', + }] + } + }, + methods: { + goReport() { + uni.navigateTo({ + url: `/policy/reportDetails/reportDetails` + }) + }, + click() { + + } + } + } +</script> +<style> + page{ + background-color: #F4F4F4; + } +</style> +<style lang="scss" scoped> +@import "./reportRecord.scss"; +</style> -- Gitblit v1.9.1