Commit 0028bd9750986a55e79cbf4bab6add873f76f046

Authored by 史婷婷
1 parent a99f36c3

feat: 客户资信管理-筛选-日期交互优化

Showing 1 changed file with 425 additions and 415 deletions
@@ -6,7 +6,8 @@ @@ -6,7 +6,8 @@
6 cancelButton="none" bgColor="#F3F3F3" textColor="rgba(0,0,0,0.4)" @confirm="search" 6 cancelButton="none" bgColor="#F3F3F3" textColor="rgba(0,0,0,0.4)" @confirm="search"
7 @input="onSearchInput" /> 7 @input="onSearchInput" />
8 <view class="tool-icons"> 8 <view class="tool-icons">
9 - <image v-if="$auth.hasPermi('customer-credit-manage:customer-credit-plan:add')" class="tool-icon" src="/static/images/dev_manage/add_icon.png" @click="onAdd" /> 9 + <image v-if="$auth.hasPermi('customer-credit-manage:customer-credit-plan:add')" class="tool-icon"
  10 + src="/static/images/dev_manage/add_icon.png" @click="onAdd" />
10 <image class="tool-icon" src="/static/images/dev_manage/filter_icon.png" @click="openFilter" /> 11 <image class="tool-icon" src="/static/images/dev_manage/filter_icon.png" @click="openFilter" />
11 </view> 12 </view>
12 </view> 13 </view>
@@ -22,22 +23,24 @@ @@ -22,22 +23,24 @@
22 <view class="card-header"> 23 <view class="card-header">
23 <text class="title omit2">{{ item.companyName }}</text> 24 <text class="title omit2">{{ item.companyName }}</text>
24 <view class="status-box"> 25 <view class="status-box">
25 - <text  
26 - :class="['status', `status_${item.status}`]">{{ getDicName('AUDIT_STATUS', item.status, dicOptions.AUDIT_STATUS) }}</text>  
27 - <text  
28 - v-if="item.frozenStatus === '冻结'"  
29 - :class="['status2']">{{ item.frozenStatus === '冻结' ? '已冻结' : '' }}</text> 26 + <text :class="['status', `status_${item.status}`]">{{ getDicName('AUDIT_STATUS',
  27 + item.status, dicOptions.AUDIT_STATUS) }}</text>
  28 + <text v-if="item.frozenStatus === '冻结'" :class="['status2']">{{ item.frozenStatus ===
  29 + '冻结' ? '已冻结' : '' }}</text>
30 </view> 30 </view>
31 </view> 31 </view>
32 <view class="info-row"> 32 <view class="info-row">
33 - <text>企业类型</text><text>{{ getDicName('ENTERPRISE_TYPE', item.enterpriseType, dicOptions.ENTERPRISE_TYPE) || '-' }}</text> 33 + <text>企业类型</text><text>{{ getDicName('ENTERPRISE_TYPE', item.enterpriseType,
  34 + dicOptions.ENTERPRISE_TYPE) || '-' }}</text>
34 </view> 35 </view>
35 <view class="info-row"> 36 <view class="info-row">
36 <text>区域</text><text>{{ item.regionName || '-' }}</text> 37 <text>区域</text><text>{{ item.regionName || '-' }}</text>
37 </view> 38 </view>
38 <view class="info-row"> 39 <view class="info-row">
39 <text>客户分类</text><text 40 <text>客户分类</text><text
40 - :class="[item.companySuggestedCategory ? 'category' : '', getCategoryClass(getDicName('CUSTOMER_CATEGORY', item.companySuggestedCategory, dicOptions.CUSTOMER_CATEGORY))]">{{ getDicName('CUSTOMER_CATEGORY', item.companySuggestedCategory, dicOptions.CUSTOMER_CATEGORY) || '-' }}</text> 41 + :class="[item.companySuggestedCategory ? 'category' : '', getCategoryClass(getDicName('CUSTOMER_CATEGORY', item.companySuggestedCategory, dicOptions.CUSTOMER_CATEGORY))]">{{
  42 + getDicName('CUSTOMER_CATEGORY', item.companySuggestedCategory,
  43 + dicOptions.CUSTOMER_CATEGORY) || '-' }}</text>
41 </view> 44 </view>
42 <view class="info-row"> 45 <view class="info-row">
43 <text>登记日期</text><text>{{ item.registerDate || '-' }}</text> 46 <text>登记日期</text><text>{{ item.registerDate || '-' }}</text>
@@ -67,7 +70,8 @@ @@ -67,7 +70,8 @@
67 </view> 70 </view>
68 <view class="form-item"> 71 <view class="form-item">
69 <view class="label">登记日期</view> 72 <view class="label">登记日期</view>
70 - <uni-datetime-picker type="daterange" v-model="model.dateRange" start="2023-01-01" /> 73 + <uni-datetime-picker type="daterange" v-model="model.dateRange" start="2023-01-01"
  74 + @change="onDateChange($event, model)" />
71 </view> 75 </view>
72 </view> 76 </view>
73 </template> 77 </template>
@@ -76,491 +80,497 @@ @@ -76,491 +80,497 @@
76 </template> 80 </template>
77 81
78 <script> 82 <script>
79 - import CardList from '@/components/card/index.vue'  
80 - import FilterModal from '@/components/filter/index.vue'  
81 - import SingleSelectSheet from '@/components/single-select/index.vue'  
82 - import {  
83 - queryApi  
84 - } from '@/api/credit_manage.js'  
85 - import {  
86 - getDicByCodes  
87 - } from '@/utils/dic'  
88 - import {  
89 - getDicName  
90 - } from '@/utils/dic.js'  
91 -  
92 - export default {  
93 - components: {  
94 - CardList,  
95 - FilterModal,  
96 - SingleSelectSheet  
97 - },  
98 - data() { 83 +import CardList from '@/components/card/index.vue'
  84 +import FilterModal from '@/components/filter/index.vue'
  85 +import SingleSelectSheet from '@/components/single-select/index.vue'
  86 +import {
  87 + queryApi
  88 +} from '@/api/credit_manage.js'
  89 +import {
  90 + getDicByCodes
  91 +} from '@/utils/dic'
  92 +import {
  93 + getDicName
  94 +} from '@/utils/dic.js'
  95 +
  96 +export default {
  97 + components: {
  98 + CardList,
  99 + FilterModal,
  100 + SingleSelectSheet
  101 + },
  102 + data() {
  103 + return {
  104 + searchKeyword: '',
  105 + searchKeywordDebounced: '',
  106 + tabs: [],
  107 + // 给到 card 的筛选值
  108 + query: {
  109 + status: '',
  110 + companySuggestedCategory: '',
  111 + dateRange: []
  112 + },
  113 + extraParams: {},
  114 +
  115 + // 批量选择
  116 + rowKey: 'id',
  117 + currentItems: [],
  118 +
  119 + // 筛选弹框
  120 + filterVisible: false,
  121 + filterForm: {
  122 + status: '',
  123 + companySuggestedCategory: '',
  124 + dateRange: []
  125 + },
  126 + dicOptions: {
  127 + CUSTOMER_CATEGORY: [],
  128 + AUDIT_STATUS: [],
  129 + ENTERPRISE_TYPE: [],
  130 + CREDIT_ZONE: []
  131 + },
  132 + statusLocal: [],
  133 + categoryLocal: []
  134 + }
  135 + },
  136 + computed: {
  137 + extraCombined() {
99 return { 138 return {
100 - searchKeyword: '',  
101 - searchKeywordDebounced: '',  
102 - tabs: [],  
103 - // 给到 card 的筛选值  
104 - query: {  
105 - status: '',  
106 - companySuggestedCategory: '',  
107 - dateRange: []  
108 - },  
109 - extraParams: {},  
110 -  
111 - // 批量选择  
112 - rowKey: 'id',  
113 - currentItems: [],  
114 -  
115 - // 筛选弹框  
116 - filterVisible: false,  
117 - filterForm: {  
118 - status: '',  
119 - companySuggestedCategory: '',  
120 - dateRange: []  
121 - },  
122 - dicOptions: {  
123 - CUSTOMER_CATEGORY: [],  
124 - AUDIT_STATUS: [],  
125 - ENTERPRISE_TYPE: [],  
126 - CREDIT_ZONE: []  
127 - },  
128 - statusLocal: [],  
129 - categoryLocal: []  
130 - }  
131 - },  
132 - computed: {  
133 - extraCombined() {  
134 - return {  
135 - companyName: this.searchKeywordDebounced || undefined  
136 - } 139 + companyName: this.searchKeywordDebounced || undefined
137 } 140 }
138 - },  
139 - watch: {  
140 - extraCombined: {  
141 - deep: true,  
142 - handler(v) {  
143 - this.extraParams = v  
144 - },  
145 - immediate: true 141 + }
  142 + },
  143 + watch: {
  144 + extraCombined: {
  145 + deep: true,
  146 + handler(v) {
  147 + this.extraParams = v
146 }, 148 },
147 - 149 + immediate: true
148 }, 150 },
149 - created() {  
150 - this.loadAllDicData() 151 +
  152 + },
  153 + created() {
  154 + this.loadAllDicData()
  155 + },
  156 + onLoad() { },
  157 + // 页面触底兜底:当页面自身滚动到底部时,转调卡片组件加载更多
  158 + onReachBottom() {
  159 + if (this.$refs && this.$refs.cardRef && this.$refs.cardRef.onLoadMore) {
  160 + this.$refs.cardRef.onLoadMore()
  161 + }
  162 + },
  163 + beforeDestroy() {
  164 + if (this.searchDebounceTimer) {
  165 + clearTimeout(this.searchDebounceTimer)
  166 + this.searchDebounceTimer = null
  167 + }
  168 + },
  169 + methods: {
  170 + onCardLoaded({
  171 + items
  172 + }) {
  173 + this.currentItems = items
151 }, 174 },
152 - onLoad() {},  
153 - // 页面触底兜底:当页面自身滚动到底部时,转调卡片组件加载更多  
154 - onReachBottom() {  
155 - if (this.$refs && this.$refs.cardRef && this.$refs.cardRef.onLoadMore) {  
156 - this.$refs.cardRef.onLoadMore()  
157 - } 175 + onCardError() {
  176 + uni.showToast({
  177 + title: '列表加载失败',
  178 + icon: 'none'
  179 + })
158 }, 180 },
159 - beforeDestroy() {  
160 - if (this.searchDebounceTimer) {  
161 - clearTimeout(this.searchDebounceTimer) 181 + // 输入实时搜索:1200ms 防抖,仅在停止输入超过阈值后刷新
  182 + onSearchInput(val) {
  183 + if (this.searchDebounceTimer) clearTimeout(this.searchDebounceTimer)
  184 + this.searchDebounceTimer = setTimeout(() => {
  185 + this.searchKeywordDebounced = this.searchKeyword
162 this.searchDebounceTimer = null 186 this.searchDebounceTimer = null
  187 + }, 1200)
  188 + },
  189 + // uni-search-bar 确认搜索:更新关键字并触发 CardList 刷新
  190 + search(e) {
  191 + const val = e && e.value != null ? e.value : this.searchKeyword
  192 + this.searchKeyword = val
  193 + this.searchKeywordDebounced = val
  194 + },
  195 + onAdd() {
  196 + uni.navigateTo({
  197 + url: '/pages/credit_manage/add'
  198 + })
  199 + },
  200 + openFilter() {
  201 + this.filterVisible = true
  202 + },
  203 + onFilterReset(payload) {
  204 + this.filterForm = payload
  205 + },
  206 + onFilterConfirm(payload) {
  207 + if ((payload.status === '' || payload.status == null) && this.filterForm.status !== '') {
  208 + payload.status = this.filterForm.status
  209 + }
  210 + if ((payload.companySuggestedCategory === '' || payload.companySuggestedCategory == null) && this
  211 + .filterForm
  212 + .companySuggestedCategory !== '') {
  213 + payload.companySuggestedCategory = this.filterForm.companySuggestedCategory
  214 + }
  215 + this.query = {
  216 + ...payload
163 } 217 }
164 }, 218 },
165 - methods: {  
166 - onCardLoaded({  
167 - items  
168 - }) {  
169 - this.currentItems = items  
170 - },  
171 - onCardError() {  
172 - uni.showToast({  
173 - title: '列表加载失败',  
174 - icon: 'none'  
175 - })  
176 - },  
177 - // 输入实时搜索:1200ms 防抖,仅在停止输入超过阈值后刷新  
178 - onSearchInput(val) {  
179 - if (this.searchDebounceTimer) clearTimeout(this.searchDebounceTimer)  
180 - this.searchDebounceTimer = setTimeout(() => {  
181 - this.searchKeywordDebounced = this.searchKeyword  
182 - this.searchDebounceTimer = null  
183 - }, 1200)  
184 - },  
185 - // uni-search-bar 确认搜索:更新关键字并触发 CardList 刷新  
186 - search(e) {  
187 - const val = e && e.value != null ? e.value : this.searchKeyword  
188 - this.searchKeyword = val  
189 - this.searchKeywordDebounced = val  
190 - },  
191 - onAdd() {  
192 - uni.navigateTo({  
193 - url: '/pages/credit_manage/add'  
194 - })  
195 - },  
196 - openFilter() {  
197 - this.filterVisible = true  
198 - },  
199 - onFilterReset(payload) {  
200 - this.filterForm = payload  
201 - },  
202 - onFilterConfirm(payload) {  
203 - if ((payload.status === '' || payload.status == null) && this.filterForm.status !== '') {  
204 - payload.status = this.filterForm.status  
205 - }  
206 - if ((payload.companySuggestedCategory === '' || payload.companySuggestedCategory == null) && this  
207 - .filterForm  
208 - .companySuggestedCategory !== '') {  
209 - payload.companySuggestedCategory = this.filterForm.companySuggestedCategory  
210 - }  
211 - this.query = {  
212 - ...payload  
213 - }  
214 - },  
215 - onStatusChange(e) {  
216 - const raw = e && e.detail && e.detail.value !== undefined ?  
217 - e.detail.value :  
218 - (e && e.value !== undefined ? e.value : '')  
219 - this.filterForm.status = raw  
220 - },  
221 - onCategoryChange(e) {  
222 - const raw = e && e.detail && e.detail.value !== undefined ? e.detail.value : (e && e.value !== undefined ?  
223 - e.value : '')  
224 - this.filterForm.companySuggestedCategory = raw  
225 - },  
226 -  
227 - // 列表接口(真实请求)  
228 - fetchList({ 219 + onStatusChange(e) {
  220 + const raw = e && e.detail && e.detail.value !== undefined ?
  221 + e.detail.value :
  222 + (e && e.value !== undefined ? e.value : '')
  223 + this.filterForm.status = raw
  224 + },
  225 + onCategoryChange(e) {
  226 + const raw = e && e.detail && e.detail.value !== undefined ? e.detail.value : (e && e.value !== undefined ?
  227 + e.value : '')
  228 + this.filterForm.companySuggestedCategory = raw
  229 + },
  230 + onDateChange(e, model) {
  231 + // 确保同步更新 filterForm,避免数据不同步
  232 + this.filterForm.dateRange = e
  233 + },
  234 + // 列表接口(真实请求)
  235 + fetchList({
  236 + pageIndex,
  237 + pageSize,
  238 + query,
  239 + extra
  240 + }) {
  241 + const params = {
229 pageIndex, 242 pageIndex,
230 pageSize, 243 pageSize,
231 - query,  
232 - extra  
233 - }) {  
234 - const params = {  
235 - pageIndex,  
236 - pageSize,  
237 - ...extra,  
238 - ...query  
239 - }  
240 - if (Array.isArray(params.dateRange) && params.dateRange.length === 2) {  
241 - params.registerDateStart = params.dateRange[0] + ' 00:00:00'  
242 - params.registerDateEnd = params.dateRange[1] + ' 23:59:59'  
243 - delete params.dateRange  
244 - }  
245 - if (this.searchKeywordDebounced) {  
246 - params.companyName = this.searchKeywordDebounced  
247 - }  
248 - return queryApi(params)  
249 - .then(res => {  
250 - const _data = res.data || {};  
251 - const records = _data.datas || [];  
252 - const totalCount = _data.totalCount || 0;  
253 - const hasNext = _data.hasNext || false  
254 - return {  
255 - records,  
256 - totalCount,  
257 - hasNext  
258 - }  
259 - })  
260 - .catch(err => {  
261 - console.error('fetchList error', err)  
262 - this.onCardError()  
263 - return {  
264 - records: [],  
265 - totalCount: 0,  
266 - hasNext: false  
267 - }  
268 - })  
269 - },  
270 - loadAllDicData() {  
271 - const dicCodes = ['CUSTOMER_CATEGORY', 'AUDIT_STATUS', 'ENTERPRISE_TYPE', 'CREDIT_ZONE']  
272 - return getDicByCodes(dicCodes).then(results => {  
273 - this.dicOptions.CUSTOMER_CATEGORY = results.CUSTOMER_CATEGORY.data || []  
274 - this.dicOptions.AUDIT_STATUS = results.AUDIT_STATUS.data || []  
275 - this.dicOptions.ENTERPRISE_TYPE = results.ENTERPRISE_TYPE.data || []  
276 - this.dicOptions.CREDIT_ZONE = results.CREDIT_ZONE.data || [];  
277 - this.categoryLocal = (this.dicOptions.CUSTOMER_CATEGORY || []).map(it => ({  
278 - value: it.code,  
279 - text: it.name  
280 - }))  
281 - this.statusLocal = (this.dicOptions.AUDIT_STATUS || []).map(it => ({  
282 - value: it.code,  
283 - text: it.name  
284 - }))  
285 - }).catch(() => {  
286 - this.dicOptions = {  
287 - CUSTOMER_CATEGORY: [],  
288 - AUDIT_STATUS: [],  
289 - ENTERPRISE_TYPE: [],  
290 - CREDIT_ZONE: [] 244 + ...extra,
  245 + ...query
  246 + }
  247 + if (Array.isArray(params.dateRange) && params.dateRange.length === 2) {
  248 + params.registerDateStart = params.dateRange[0] + ' 00:00:00'
  249 + params.registerDateEnd = params.dateRange[1] + ' 23:59:59'
  250 + delete params.dateRange
  251 + }
  252 + if (this.searchKeywordDebounced) {
  253 + params.companyName = this.searchKeywordDebounced
  254 + }
  255 + return queryApi(params)
  256 + .then(res => {
  257 + const _data = res.data || {};
  258 + const records = _data.datas || [];
  259 + const totalCount = _data.totalCount || 0;
  260 + const hasNext = _data.hasNext || false
  261 + return {
  262 + records,
  263 + totalCount,
  264 + hasNext
291 } 265 }
292 - this.categoryLocal = []  
293 - this.statusLocal = []  
294 }) 266 })
295 - },  
296 - onCardClick(item) {  
297 - const id = (item && (item.id || item.code)) || ''  
298 - if (!id) return  
299 - const query = '?id=' + encodeURIComponent(id)  
300 - uni.navigateTo({  
301 - url: '/pages/credit_manage/detail' + query 267 + .catch(err => {
  268 + console.error('fetchList error', err)
  269 + this.onCardError()
  270 + return {
  271 + records: [],
  272 + totalCount: 0,
  273 + hasNext: false
  274 + }
302 }) 275 })
303 - },  
304 - getDicName: getDicName,  
305 - getCategoryClass(categoryName) {  
306 - if (!categoryName) return ''  
307 - if (categoryName.includes('A') || categoryName.includes('a')) {  
308 - return 'category_A'  
309 - } else if (categoryName.includes('B') || categoryName.includes('b')) {  
310 - return 'category_B'  
311 - } else if (categoryName.includes('C') || categoryName.includes('c')) {  
312 - return 'category_C'  
313 - } else if (categoryName.includes('D') || categoryName.includes('d')) {  
314 - return 'category_D' 276 + },
  277 + loadAllDicData() {
  278 + const dicCodes = ['CUSTOMER_CATEGORY', 'AUDIT_STATUS', 'ENTERPRISE_TYPE', 'CREDIT_ZONE']
  279 + return getDicByCodes(dicCodes).then(results => {
  280 + this.dicOptions.CUSTOMER_CATEGORY = results.CUSTOMER_CATEGORY.data || []
  281 + this.dicOptions.AUDIT_STATUS = results.AUDIT_STATUS.data || []
  282 + this.dicOptions.ENTERPRISE_TYPE = results.ENTERPRISE_TYPE.data || []
  283 + this.dicOptions.CREDIT_ZONE = results.CREDIT_ZONE.data || [];
  284 + this.categoryLocal = (this.dicOptions.CUSTOMER_CATEGORY || []).map(it => ({
  285 + value: it.code,
  286 + text: it.name
  287 + }))
  288 + this.statusLocal = (this.dicOptions.AUDIT_STATUS || []).map(it => ({
  289 + value: it.code,
  290 + text: it.name
  291 + }))
  292 + }).catch(() => {
  293 + this.dicOptions = {
  294 + CUSTOMER_CATEGORY: [],
  295 + AUDIT_STATUS: [],
  296 + ENTERPRISE_TYPE: [],
  297 + CREDIT_ZONE: []
315 } 298 }
  299 + this.categoryLocal = []
  300 + this.statusLocal = []
  301 + })
  302 + },
  303 + onCardClick(item) {
  304 + const id = (item && (item.id || item.code)) || ''
  305 + if (!id) return
  306 + const query = '?id=' + encodeURIComponent(id)
  307 + uni.navigateTo({
  308 + url: '/pages/credit_manage/detail' + query
  309 + })
  310 + },
  311 + getDicName: getDicName,
  312 + getCategoryClass(categoryName) {
  313 + if (!categoryName) return ''
  314 + if (categoryName.includes('A') || categoryName.includes('a')) {
  315 + return 'category_A'
  316 + } else if (categoryName.includes('B') || categoryName.includes('b')) {
  317 + return 'category_B'
  318 + } else if (categoryName.includes('C') || categoryName.includes('c')) {
  319 + return 'category_C'
  320 + } else if (categoryName.includes('D') || categoryName.includes('d')) {
  321 + return 'category_D'
316 } 322 }
317 -  
318 } 323 }
  324 +
319 } 325 }
  326 +}
320 </script> 327 </script>
321 328
322 <style lang="scss" scoped> 329 <style lang="scss" scoped>
323 - .page { 330 +.page {
  331 + display: flex;
  332 + flex-direction: column;
  333 + height: 100vh;
  334 +}
  335 +
  336 +.dev-list-fixed {
  337 + position: fixed;
  338 + top: 96rpx;
  339 + left: 0;
  340 + right: 0;
  341 + z-index: 2;
  342 + background: #fff;
  343 +
  344 + .search-row {
324 display: flex; 345 display: flex;
325 - flex-direction: column;  
326 - height: 100vh;  
327 - } 346 + align-items: center;
  347 + padding: 16rpx 32rpx;
328 348
329 - .dev-list-fixed {  
330 - position: fixed;  
331 - top: 96rpx;  
332 - left: 0;  
333 - right: 0;  
334 - z-index: 2;  
335 - background: #fff; 349 + .uni-searchbar {
  350 + padding: 0;
  351 + flex: 1;
  352 + }
336 353
337 - .search-row { 354 + .tool-icons {
338 display: flex; 355 display: flex;
339 - align-items: center;  
340 - padding: 16rpx 32rpx;  
341 356
342 - .uni-searchbar {  
343 - padding: 0;  
344 - flex: 1; 357 + .tool-icon {
  358 + width: 48rpx;
  359 + height: 48rpx;
  360 + display: block;
  361 + margin-left: 32rpx;
345 } 362 }
  363 + }
  364 + }
346 365
347 - .tool-icons {  
348 - display: flex; 366 +}
349 367
350 - .tool-icon {  
351 - width: 48rpx;  
352 - height: 48rpx;  
353 - display: block;  
354 - margin-left: 32rpx;  
355 - }  
356 - }  
357 - } 368 +/* 仅当前页覆盖 uni-search-bar 盒子高度 */
  369 +::v-deep .uni-searchbar__box {
  370 + height: 80rpx !important;
  371 + justify-content: start;
358 372
  373 + .uni-searchbar__box-search-input {
  374 + font-size: 32rpx !important;
359 } 375 }
  376 +}
360 377
361 - /* 仅当前页覆盖 uni-search-bar 盒子高度 */  
362 - ::v-deep .uni-searchbar__box {  
363 - height: 80rpx !important;  
364 - justify-content: start; 378 +.list-box {
  379 + flex: 1;
  380 + padding-top: 132rpx;
365 381
366 - .uni-searchbar__box-search-input {  
367 - font-size: 32rpx !important;  
368 - } 382 + &.pad-batch {
  383 + padding-bottom: 144rpx;
369 } 384 }
370 385
371 - .list-box {  
372 - flex: 1;  
373 - padding-top: 132rpx; 386 + .card {
  387 + position: relative;
  388 + }
374 389
375 - &.pad-batch {  
376 - padding-bottom: 144rpx;  
377 - } 390 + .card-header {
  391 + margin-bottom: 28rpx;
  392 + position: relative;
378 393
379 - .card {  
380 - position: relative; 394 + .title {
  395 + font-size: 36rpx;
  396 + font-weight: 600;
  397 + line-height: 50rpx;
  398 + color: rgba(0, 0, 0, 0.9);
  399 + width: 578rpx;
381 } 400 }
382 401
383 - .card-header {  
384 - margin-bottom: 28rpx;  
385 - position: relative; 402 + .status-box {
  403 + position: absolute;
  404 + top: -32rpx;
  405 + right: -32rpx;
386 406
387 - .title {  
388 - font-size: 36rpx; 407 + .status {
  408 + display: block;
  409 + height: 48rpx;
  410 + line-height: 48rpx;
389 font-weight: 600; 411 font-weight: 600;
390 - line-height: 50rpx;  
391 - color: rgba(0,0,0,0.9);  
392 - width: 578rpx;  
393 - }  
394 -  
395 - .status-box {  
396 - position: absolute;  
397 - top: -32rpx;  
398 - right: -32rpx;  
399 -  
400 - .status {  
401 - display: block;  
402 - height: 48rpx;  
403 - line-height: 48rpx;  
404 - font-weight: 600;  
405 - color: #fff;  
406 - font-size: 24rpx;  
407 - padding: 0 14rpx;  
408 - border-radius: 6rpx;  
409 - margin-bottom: 8rpx;  
410 -  
411 - &.status_AUDIT {  
412 - background: $theme-primary;  
413 - }  
414 -  
415 - &.status_PASS {  
416 - background: #2BA471;  
417 - } 412 + color: #fff;
  413 + font-size: 24rpx;
  414 + padding: 0 14rpx;
  415 + border-radius: 6rpx;
  416 + margin-bottom: 8rpx;
  417 +
  418 + &.status_AUDIT {
  419 + background: $theme-primary;
  420 + }
418 421
419 - &.status_REFUSE {  
420 - background: #D54941;  
421 - } 422 + &.status_PASS {
  423 + background: #2BA471;
  424 + }
422 425
423 - &.status_CANCEL {  
424 - background: #E7E7E7;  
425 - color: rgba(0,0,0,0.9);  
426 - } 426 + &.status_REFUSE {
  427 + background: #D54941;
427 } 428 }
428 429
429 - .status2 {  
430 - display: block;  
431 - font-weight: 600;  
432 - line-height: 48rpx;  
433 - height: 48rpx;  
434 - color: #fff;  
435 - font-size: 24rpx;  
436 - padding: 0 14rpx;  
437 - border-radius: 6rpx; 430 + &.status_CANCEL {
438 background: #E7E7E7; 431 background: #E7E7E7;
439 - color: rgba(0,0,0,0.9);  
440 - 432 + color: rgba(0, 0, 0, 0.9);
441 } 433 }
  434 + }
  435 +
  436 + .status2 {
  437 + display: block;
  438 + font-weight: 600;
  439 + line-height: 48rpx;
  440 + height: 48rpx;
  441 + color: #fff;
  442 + font-size: 24rpx;
  443 + padding: 0 14rpx;
  444 + border-radius: 6rpx;
  445 + background: #E7E7E7;
  446 + color: rgba(0, 0, 0, 0.9);
442 447
443 } 448 }
444 449
445 } 450 }
446 451
447 - .info-row {  
448 - display: flex;  
449 - align-items: center;  
450 - color: rgba(0, 0, 0, 0.6);  
451 - font-size: 28rpx;  
452 - margin-bottom: 24rpx; 452 + }
  453 +
  454 + .info-row {
  455 + display: flex;
  456 + align-items: center;
  457 + color: rgba(0, 0, 0, 0.6);
  458 + font-size: 28rpx;
  459 + margin-bottom: 24rpx;
  460 +
  461 + &:last-child {
  462 + margin-bottom: 0;
  463 + }
  464 +
  465 + text {
  466 + width: 60%;
  467 + line-height: 32rpx;
453 468
454 &:last-child { 469 &:last-child {
455 - margin-bottom: 0; 470 + color: rgba(0, 0, 0, 0.9);
  471 + width: 40%;
456 } 472 }
457 473
458 - text {  
459 - width: 60%;  
460 - line-height: 32rpx; 474 + &.category {
  475 + display: inline-block;
  476 + padding: 4rpx 12rpx;
  477 + border-radius: 6rpx;
  478 + font-size: 24rpx;
  479 + width: auto;
461 480
462 - &:last-child {  
463 - color: rgba(0, 0, 0, 0.9);  
464 - width: 40%; 481 + &.category_A {
  482 + background: #FFF0ED;
  483 + color: #D54941;
465 } 484 }
466 485
467 - &.category {  
468 - display: inline-block;  
469 - padding: 4rpx 12rpx;  
470 - border-radius: 6rpx;  
471 - font-size: 24rpx;  
472 - width: auto;  
473 - &.category_A {  
474 - background: #FFF0ED;  
475 - color: #D54941;  
476 - }  
477 - &.category_B {  
478 - background: #FFF1E9;  
479 - color: #E37318;  
480 - }  
481 - &.category_C {  
482 - background: #F2F3FF;  
483 - color: $theme-primary;  
484 - }  
485 - &.category_D {  
486 - background: #E3F9E9;  
487 - color: #2BA471;  
488 - } 486 + &.category_B {
  487 + background: #FFF1E9;
  488 + color: #E37318;
  489 + }
  490 +
  491 + &.category_C {
  492 + background: #F2F3FF;
  493 + color: $theme-primary;
489 } 494 }
490 - }  
491 495
  496 + &.category_D {
  497 + background: #E3F9E9;
  498 + color: #2BA471;
  499 + }
  500 + }
492 } 501 }
  502 +
493 } 503 }
  504 +}
494 505
495 - .filter-form {  
496 - .form-item {  
497 - margin-bottom: 24rpx;  
498 - } 506 +.filter-form {
  507 + .form-item {
  508 + margin-bottom: 24rpx;
  509 + }
499 510
500 - .label {  
501 - margin-bottom: 20rpx;  
502 - color: rgba(0, 0, 0, 0.9);  
503 - height: 44rpx;  
504 - line-height: 44rpx;  
505 - font-size: 30rpx; 511 + .label {
  512 + margin-bottom: 20rpx;
  513 + color: rgba(0, 0, 0, 0.9);
  514 + height: 44rpx;
  515 + line-height: 44rpx;
  516 + font-size: 30rpx;
  517 + }
  518 +
  519 + .fake-select {
  520 + height: 80rpx;
  521 + line-height: 80rpx;
  522 + padding: 0 20rpx;
  523 + background: #f3f3f3;
  524 + border-radius: 12rpx;
  525 +
  526 + .placeholder {
  527 + color: #999;
506 } 528 }
507 529
508 - .fake-select { 530 + .value {
  531 + color: #333;
  532 + }
  533 + }
  534 +}
  535 +
  536 +/* 深度覆盖 uni-data-checkbox(mode=tag)内部的 tag 展示与间距 */
  537 +::v-deep .filter-form .uni-data-checklist .checklist-group {
  538 + .checklist-box {
  539 + &.is--tag {
  540 + width: 212rpx;
  541 + margin-top: 0;
  542 + margin-bottom: 24rpx;
  543 + margin-right: 24rpx;
509 height: 80rpx; 544 height: 80rpx;
510 - line-height: 80rpx;  
511 - padding: 0 20rpx;  
512 - background: #f3f3f3; 545 + padding: 0;
513 border-radius: 12rpx; 546 border-radius: 12rpx;
  547 + background-color: #f3f3f3;
  548 + border-color: #f3f3f3;
514 549
515 - .placeholder {  
516 - color: #999; 550 + &:nth-child(3n) {
  551 + margin-right: 0;
517 } 552 }
518 553
519 - .value {  
520 - color: #333; 554 + .checklist-content {
  555 + display: flex;
  556 + justify-content: center;
521 } 557 }
522 - }  
523 - }  
524 -  
525 - /* 深度覆盖 uni-data-checkbox(mode=tag)内部的 tag 展示与间距 */  
526 - ::v-deep .filter-form .uni-data-checklist .checklist-group {  
527 - .checklist-box {  
528 - &.is--tag {  
529 - width: 212rpx;  
530 - margin-top: 0;  
531 - margin-bottom: 24rpx;  
532 - margin-right: 24rpx;  
533 - height: 80rpx;  
534 - padding: 0;  
535 - border-radius: 12rpx;  
536 - background-color: #f3f3f3;  
537 - border-color: #f3f3f3;  
538 -  
539 - &:nth-child(3n) {  
540 - margin-right: 0;  
541 - }  
542 -  
543 - .checklist-content {  
544 - display: flex;  
545 - justify-content: center;  
546 - }  
547 558
548 - .checklist-text {  
549 - color: rgba(0, 0, 0, 0.9);  
550 - font-size: 28rpx;  
551 - } 559 + .checklist-text {
  560 + color: rgba(0, 0, 0, 0.9);
  561 + font-size: 28rpx;
552 } 562 }
  563 + }
553 564
554 - &.is-checked {  
555 - background-color: $theme-primary-plain-bg !important;  
556 - border-color: $theme-primary-plain-bg !important; 565 + &.is-checked {
  566 + background-color: $theme-primary-plain-bg !important;
  567 + border-color: $theme-primary-plain-bg !important;
557 568
558 - .checklist-text {  
559 - color: $theme-primary !important;  
560 - } 569 + .checklist-text {
  570 + color: $theme-primary !important;
561 } 571 }
562 } 572 }
563 -  
564 } 573 }
565 574
  575 +}
566 </style> 576 </style>