Showing
7 changed files
with
127 additions
and
17 deletions
| @@ -4,6 +4,7 @@ | @@ -4,6 +4,7 @@ | ||
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | + <view class="row" v-if="status === 'STANDARD'"><text class="label">正式合同规范性审核</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> | ||
| 7 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' | 8 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' |
| 8 | }}</text></view> | 9 | }}</text></view> |
| 9 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' | 10 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' |
| @@ -105,7 +106,7 @@ | @@ -105,7 +106,7 @@ | ||
| 105 | </template> | 106 | </template> |
| 106 | 107 | ||
| 107 | <script> | 108 | <script> |
| 108 | -import { getContractApi, deleteContractApi, uploadStandardContract, uploadSignedContractFile } from '@/api/contract' | 109 | +import { getContractApi, deleteContractApi, uploadStandardContract, uploadSignedContractFile, statusStyle} from '@/api/contract' |
| 109 | import ProductRel from './productRel.vue' | 110 | import ProductRel from './productRel.vue' |
| 110 | import DetailButtons from '@/components/detail-buttons/index.vue' | 111 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 111 | import FileUpload from '@/components/file-upload/index.vue' | 112 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -159,6 +160,7 @@ export default { | @@ -159,6 +160,7 @@ export default { | ||
| 159 | component: '', | 160 | component: '', |
| 160 | packaging: '' | 161 | packaging: '' |
| 161 | }, | 162 | }, |
| 163 | + statusStyle: statusStyle, | ||
| 162 | productList: [], | 164 | productList: [], |
| 163 | buttons: [{ | 165 | buttons: [{ |
| 164 | text: '编辑', | 166 | text: '编辑', |
| @@ -224,6 +226,14 @@ export default { | @@ -224,6 +226,14 @@ export default { | ||
| 224 | this.loadDetail() | 226 | this.loadDetail() |
| 225 | }, | 227 | }, |
| 226 | methods: { | 228 | methods: { |
| 229 | + getStatusCss(name) { | ||
| 230 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 231 | + const found = list.find(it => it && it.text === name) || {} | ||
| 232 | + return { | ||
| 233 | + color: found.color || '#000', | ||
| 234 | + backgroundColor: found.bgColor || '#000' | ||
| 235 | + } | ||
| 236 | + }, | ||
| 227 | onDelete() { | 237 | onDelete() { |
| 228 | uni.showModal({ | 238 | uni.showModal({ |
| 229 | title: '确认删除', | 239 | title: '确认删除', |
| @@ -380,7 +390,13 @@ export default { | @@ -380,7 +390,13 @@ export default { | ||
| 380 | flex-direction: column; | 390 | flex-direction: column; |
| 381 | height: 100%; | 391 | height: 100%; |
| 382 | } | 392 | } |
| 383 | - | 393 | +.info-status { |
| 394 | + padding: 4rpx 12rpx; | ||
| 395 | + border-radius: 6rpx; | ||
| 396 | + font-size: 24rpx; | ||
| 397 | + color: #fff; | ||
| 398 | + line-height: 40rpx; | ||
| 399 | +} | ||
| 384 | .scroll { | 400 | .scroll { |
| 385 | flex: 1; | 401 | flex: 1; |
| 386 | padding: 8rpx 0 144rpx; | 402 | padding: 8rpx 0 144rpx; |
| @@ -4,6 +4,7 @@ | @@ -4,6 +4,7 @@ | ||
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | + <view class="row" v-if="detail.status === 'STANDARD' || detail.status === 'FORMAL'"><text class="label">{{ detail.status === 'STANDARD' ? '标准合同' : '正式合同' }}规范性审核状态</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> | ||
| 7 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' | 8 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' |
| 8 | }}</text></view> | 9 | }}</text></view> |
| 9 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' | 10 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' |
| @@ -112,7 +113,7 @@ | @@ -112,7 +113,7 @@ | ||
| 112 | </template> | 113 | </template> |
| 113 | 114 | ||
| 114 | <script> | 115 | <script> |
| 115 | -import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract, uploadSignedContractFile } from '@/api/contract' | 116 | +import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract, uploadSignedContractFile, statusStyle } from '@/api/contract' |
| 116 | import ProductRel from './productRel.vue' | 117 | import ProductRel from './productRel.vue' |
| 117 | import DetailButtons from '@/components/detail-buttons/index.vue' | 118 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 118 | import FileUpload from '@/components/file-upload/index.vue' | 119 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -131,6 +132,7 @@ export default { | @@ -131,6 +132,7 @@ export default { | ||
| 131 | standardStandardized: '', | 132 | standardStandardized: '', |
| 132 | standardStandardizedName: '', | 133 | standardStandardizedName: '', |
| 133 | sheet: { visible: false, title: '请选择', options: [], value: '' }, | 134 | sheet: { visible: false, title: '请选择', options: [], value: '' }, |
| 135 | + statusStyle: statusStyle, | ||
| 134 | detail: { | 136 | detail: { |
| 135 | code: '', | 137 | code: '', |
| 136 | supplier: '', | 138 | supplier: '', |
| @@ -285,6 +287,14 @@ export default { | @@ -285,6 +287,14 @@ export default { | ||
| 285 | this.loadDetail() | 287 | this.loadDetail() |
| 286 | }, | 288 | }, |
| 287 | methods: { | 289 | methods: { |
| 290 | + getStatusCss(name) { | ||
| 291 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 292 | + const found = list.find(it => it && it.text === name) || {} | ||
| 293 | + return { | ||
| 294 | + color: found.color || '#000', | ||
| 295 | + backgroundColor: found.bgColor || '#000' | ||
| 296 | + } | ||
| 297 | + }, | ||
| 288 | onDelete() { | 298 | onDelete() { |
| 289 | uni.showModal({ | 299 | uni.showModal({ |
| 290 | title: '确认删除', | 300 | title: '确认删除', |
| @@ -462,7 +472,13 @@ export default { | @@ -462,7 +472,13 @@ export default { | ||
| 462 | flex-direction: column; | 472 | flex-direction: column; |
| 463 | height: 100%; | 473 | height: 100%; |
| 464 | } | 474 | } |
| 465 | - | 475 | +.info-status { |
| 476 | + padding: 4rpx 12rpx; | ||
| 477 | + border-radius: 6rpx; | ||
| 478 | + font-size: 24rpx; | ||
| 479 | + color: #fff; | ||
| 480 | + line-height: 40rpx; | ||
| 481 | +} | ||
| 466 | .scroll { | 482 | .scroll { |
| 467 | flex: 1; | 483 | flex: 1; |
| 468 | padding: 8rpx 0 144rpx; | 484 | padding: 8rpx 0 144rpx; |
| @@ -4,6 +4,7 @@ | @@ -4,6 +4,7 @@ | ||
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | + <view class="row" v-if="detail.status === 'STANDARD' || detail.status === 'FORMAL'"><text class="label">{{ detail.status === 'STANDARD' ? '标准合同' : '正式合同' }}规范性审核状态</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> | ||
| 7 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' | 8 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' |
| 8 | }}</text></view> | 9 | }}</text></view> |
| 9 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' | 10 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' |
| @@ -113,7 +114,7 @@ | @@ -113,7 +114,7 @@ | ||
| 113 | </template> | 114 | </template> |
| 114 | 115 | ||
| 115 | <script> | 116 | <script> |
| 116 | -import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract, uploadSignedContractFile } from '@/api/contract' | 117 | +import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract, uploadSignedContractFile, statusStyle } from '@/api/contract' |
| 117 | import ProductRel from './productRel.vue' | 118 | import ProductRel from './productRel.vue' |
| 118 | import DetailButtons from '@/components/detail-buttons/index.vue' | 119 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 119 | import FileUpload from '@/components/file-upload/index.vue' | 120 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -169,6 +170,7 @@ export default { | @@ -169,6 +170,7 @@ export default { | ||
| 169 | packaging: '' | 170 | packaging: '' |
| 170 | }, | 171 | }, |
| 171 | productList: [], | 172 | productList: [], |
| 173 | + statusStyle: statusStyle, | ||
| 172 | buttons: [{ | 174 | buttons: [{ |
| 173 | text: '编辑', | 175 | text: '编辑', |
| 174 | visible: true, | 176 | visible: true, |
| @@ -292,6 +294,14 @@ export default { | @@ -292,6 +294,14 @@ export default { | ||
| 292 | this.loadDetail() | 294 | this.loadDetail() |
| 293 | }, | 295 | }, |
| 294 | methods: { | 296 | methods: { |
| 297 | + getStatusCss(name) { | ||
| 298 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 299 | + const found = list.find(it => it && it.text === name) || {} | ||
| 300 | + return { | ||
| 301 | + color: found.color || '#000', | ||
| 302 | + backgroundColor: found.bgColor || '#000' | ||
| 303 | + } | ||
| 304 | + }, | ||
| 295 | onDelete() { | 305 | onDelete() { |
| 296 | uni.showModal({ | 306 | uni.showModal({ |
| 297 | title: '确认删除', | 307 | title: '确认删除', |
| @@ -472,7 +482,13 @@ export default { | @@ -472,7 +482,13 @@ export default { | ||
| 472 | flex-direction: column; | 482 | flex-direction: column; |
| 473 | height: 100%; | 483 | height: 100%; |
| 474 | } | 484 | } |
| 475 | - | 485 | +.info-status { |
| 486 | + padding: 4rpx 12rpx; | ||
| 487 | + border-radius: 6rpx; | ||
| 488 | + font-size: 24rpx; | ||
| 489 | + color: #fff; | ||
| 490 | + line-height: 40rpx; | ||
| 491 | +} | ||
| 476 | .scroll { | 492 | .scroll { |
| 477 | flex: 1; | 493 | flex: 1; |
| 478 | padding: 8rpx 0 144rpx; | 494 | padding: 8rpx 0 144rpx; |
| 1 | -<template> | 1 | +statusStyl<template> |
| 2 | <view class="page"> | 2 | <view class="page"> |
| 3 | <scroll-view class="scroll" scroll-y> | 3 | <scroll-view class="scroll" scroll-y> |
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | + <view class="row" v-if="status === 'STANDARD'"><text class="label">正式合同规范性审核</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> | ||
| 7 | <view class="row"><text class="label">承揽方</text><text class="value">{{ detail.supplierName || '-' | 8 | <view class="row"><text class="label">承揽方</text><text class="value">{{ detail.supplierName || '-' |
| 8 | }}</text></view> | 9 | }}</text></view> |
| 9 | <view class="row"><text class="label">定作方</text><text class="value">{{ detail.buyerName || '-' | 10 | <view class="row"><text class="label">定作方</text><text class="value">{{ detail.buyerName || '-' |
| @@ -103,7 +104,7 @@ | @@ -103,7 +104,7 @@ | ||
| 103 | </template> | 104 | </template> |
| 104 | 105 | ||
| 105 | <script> | 106 | <script> |
| 106 | -import { getContractApi, deleteContractApi, uploadStandardContract } from '@/api/contract' | 107 | +import { getContractApi, deleteContractApi, uploadStandardContract, statusStyle } from '@/api/contract' |
| 107 | import ProductRel from './productRel.vue' | 108 | import ProductRel from './productRel.vue' |
| 108 | import DetailButtons from '@/components/detail-buttons/index.vue' | 109 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 109 | import FileUpload from '@/components/file-upload/index.vue' | 110 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -159,6 +160,7 @@ export default { | @@ -159,6 +160,7 @@ export default { | ||
| 159 | packaging: '' | 160 | packaging: '' |
| 160 | }, | 161 | }, |
| 161 | productList: [], | 162 | productList: [], |
| 163 | + statusStyle: statusStyle, | ||
| 162 | buttons: [{ | 164 | buttons: [{ |
| 163 | text: '编辑', | 165 | text: '编辑', |
| 164 | visible: true, | 166 | visible: true, |
| @@ -216,6 +218,14 @@ export default { | @@ -216,6 +218,14 @@ export default { | ||
| 216 | this.loadDetail() | 218 | this.loadDetail() |
| 217 | }, | 219 | }, |
| 218 | methods: { | 220 | methods: { |
| 221 | + getStatusCss(name) { | ||
| 222 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 223 | + const found = list.find(it => it && it.text === name) || {} | ||
| 224 | + return { | ||
| 225 | + color: found.color || '#000', | ||
| 226 | + backgroundColor: found.bgColor || '#000' | ||
| 227 | + } | ||
| 228 | + }, | ||
| 219 | onDelete() { | 229 | onDelete() { |
| 220 | uni.showModal({ | 230 | uni.showModal({ |
| 221 | title: '确认删除', | 231 | title: '确认删除', |
| @@ -366,7 +376,13 @@ export default { | @@ -366,7 +376,13 @@ export default { | ||
| 366 | flex-direction: column; | 376 | flex-direction: column; |
| 367 | height: 100%; | 377 | height: 100%; |
| 368 | } | 378 | } |
| 369 | - | 379 | +.info-status { |
| 380 | + padding: 4rpx 12rpx; | ||
| 381 | + border-radius: 6rpx; | ||
| 382 | + font-size: 24rpx; | ||
| 383 | + color: #fff; | ||
| 384 | + line-height: 40rpx; | ||
| 385 | +} | ||
| 370 | .scroll { | 386 | .scroll { |
| 371 | flex: 1; | 387 | flex: 1; |
| 372 | padding: 8rpx 0 144rpx; | 388 | padding: 8rpx 0 144rpx; |
| @@ -4,8 +4,7 @@ | @@ -4,8 +4,7 @@ | ||
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | - <view class="row" v-if="status === 'STANDARD'"><text class="label">正式合同规范性审核状态</text><text | ||
| 8 | - class="value">{{ detail.standardApprovedName || '-' }}</text></view> | 7 | + <view class="row" v-if="status === 'STANDARD'"><text class="label">正式合同规范性审核</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> |
| 9 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || | 8 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || |
| 10 | '-'}}</text></view> | 9 | '-'}}</text></view> |
| 11 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || | 10 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || |
| @@ -109,7 +108,7 @@ | @@ -109,7 +108,7 @@ | ||
| 109 | </template> | 108 | </template> |
| 110 | 109 | ||
| 111 | <script> | 110 | <script> |
| 112 | -import { getContractApi, deleteContractApi, uploadStandardContract } from '@/api/contract' | 111 | +import { getContractApi, deleteContractApi, uploadStandardContract, statusStyle } from '@/api/contract' |
| 113 | import ProductRel from './productRel.vue' | 112 | import ProductRel from './productRel.vue' |
| 114 | import DetailButtons from '@/components/detail-buttons/index.vue' | 113 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 115 | import FileUpload from '@/components/file-upload/index.vue' | 114 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -198,6 +197,7 @@ export default { | @@ -198,6 +197,7 @@ export default { | ||
| 198 | event: 'auditDetail' | 197 | event: 'auditDetail' |
| 199 | }, | 198 | }, |
| 200 | ], | 199 | ], |
| 200 | + statusStyle: statusStyle, | ||
| 201 | } | 201 | } |
| 202 | }, | 202 | }, |
| 203 | computed: { | 203 | computed: { |
| @@ -222,6 +222,14 @@ export default { | @@ -222,6 +222,14 @@ export default { | ||
| 222 | this.loadDetail() | 222 | this.loadDetail() |
| 223 | }, | 223 | }, |
| 224 | methods: { | 224 | methods: { |
| 225 | + getStatusCss(name) { | ||
| 226 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 227 | + const found = list.find(it => it && it.text === name) || {} | ||
| 228 | + return { | ||
| 229 | + color: found.color || '#000', | ||
| 230 | + backgroundColor: found.bgColor || '#000' | ||
| 231 | + } | ||
| 232 | + }, | ||
| 225 | onUploadSubmit() { | 233 | onUploadSubmit() { |
| 226 | if (!this.fileInfo.id) { | 234 | if (!this.fileInfo.id) { |
| 227 | uni.showToast({ | 235 | uni.showToast({ |
| @@ -395,7 +403,13 @@ export default { | @@ -395,7 +403,13 @@ export default { | ||
| 395 | margin-bottom: 20rpx; | 403 | margin-bottom: 20rpx; |
| 396 | align-items: center; | 404 | align-items: center; |
| 397 | } | 405 | } |
| 398 | - | 406 | +.info-status { |
| 407 | + padding: 4rpx 12rpx; | ||
| 408 | + border-radius: 6rpx; | ||
| 409 | + font-size: 24rpx; | ||
| 410 | + color: #fff; | ||
| 411 | + line-height: 40rpx; | ||
| 412 | +} | ||
| 399 | .row:last-child { | 413 | .row:last-child { |
| 400 | margin-bottom: 0; | 414 | margin-bottom: 0; |
| 401 | } | 415 | } |
| @@ -4,6 +4,7 @@ | @@ -4,6 +4,7 @@ | ||
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | + <view class="row" v-if="detail.status === 'STANDARD' || detail.status === 'FORMAL'"><text class="label">{{ detail.status === 'STANDARD' ? '标准合同' : '正式合同' }}规范性审核状态</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> | ||
| 7 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' | 8 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' |
| 8 | }}</text></view> | 9 | }}</text></view> |
| 9 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' | 10 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' |
| @@ -107,7 +108,7 @@ | @@ -107,7 +108,7 @@ | ||
| 107 | </template> | 108 | </template> |
| 108 | 109 | ||
| 109 | <script> | 110 | <script> |
| 110 | -import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract } from '@/api/contract' | 111 | +import { getContractApi, deleteContractApi, uploadFormalContract, uploadStandardContract, statusStyle } from '@/api/contract' |
| 111 | import ProductRel from './productRel.vue' | 112 | import ProductRel from './productRel.vue' |
| 112 | import DetailButtons from '@/components/detail-buttons/index.vue' | 113 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 113 | import FileUpload from '@/components/file-upload/index.vue' | 114 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -160,6 +161,7 @@ export default { | @@ -160,6 +161,7 @@ export default { | ||
| 160 | packaging: '' | 161 | packaging: '' |
| 161 | }, | 162 | }, |
| 162 | productList: [], | 163 | productList: [], |
| 164 | + statusStyle: statusStyle, | ||
| 163 | buttons: [{ | 165 | buttons: [{ |
| 164 | text: '编辑', | 166 | text: '编辑', |
| 165 | visible: true, | 167 | visible: true, |
| @@ -429,6 +431,14 @@ export default { | @@ -429,6 +431,14 @@ export default { | ||
| 429 | this.detail = { ...this.detail } | 431 | this.detail = { ...this.detail } |
| 430 | this.productList = [] | 432 | this.productList = [] |
| 431 | } | 433 | } |
| 434 | + }, | ||
| 435 | + getStatusCss(name) { | ||
| 436 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 437 | + const found = list.find(it => it && it.text === name) || {} | ||
| 438 | + return { | ||
| 439 | + color: found.color || '#000', | ||
| 440 | + backgroundColor: found.bgColor || '#000' | ||
| 441 | + } | ||
| 432 | } | 442 | } |
| 433 | } | 443 | } |
| 434 | } | 444 | } |
| @@ -440,7 +450,13 @@ export default { | @@ -440,7 +450,13 @@ export default { | ||
| 440 | flex-direction: column; | 450 | flex-direction: column; |
| 441 | height: 100%; | 451 | height: 100%; |
| 442 | } | 452 | } |
| 443 | - | 453 | +.info-status { |
| 454 | + padding: 4rpx 12rpx; | ||
| 455 | + border-radius: 6rpx; | ||
| 456 | + font-size: 24rpx; | ||
| 457 | + color: #fff; | ||
| 458 | + line-height: 40rpx; | ||
| 459 | +} | ||
| 444 | .scroll { | 460 | .scroll { |
| 445 | flex: 1; | 461 | flex: 1; |
| 446 | padding: 8rpx 0 144rpx; | 462 | padding: 8rpx 0 144rpx; |
| @@ -4,6 +4,7 @@ | @@ -4,6 +4,7 @@ | ||
| 4 | <view class="detail-page"> | 4 | <view class="detail-page"> |
| 5 | <view class="section"> | 5 | <view class="section"> |
| 6 | <text class="row customer">{{ detail.code }}</text> | 6 | <text class="row customer">{{ detail.code }}</text> |
| 7 | + <view class="row" v-if="detail.status === 'STANDARD' || detail.status === 'FORMAL'"><text class="label">{{ detail.status === 'STANDARD' ? '标准合同' : '正式合同' }}规范性审核状态</text><text class="value"><span class="info-status" :style="detail.standardApprovedName ? getStatusCss(detail.standardApprovedName) : ''" >{{ detail.standardApprovedName || '-' }}</span></text></view> | ||
| 7 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' | 8 | <view class="row"><text class="label">供方</text><text class="value">{{ detail.supplierName || '-' |
| 8 | }}</text></view> | 9 | }}</text></view> |
| 9 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' | 10 | <view class="row"><text class="label">需方</text><text class="value">{{ detail.buyerName || '-' |
| @@ -113,7 +114,7 @@ | @@ -113,7 +114,7 @@ | ||
| 113 | </template> | 114 | </template> |
| 114 | 115 | ||
| 115 | <script> | 116 | <script> |
| 116 | -import { getContractApi, deleteContractApi, uploadFormalContract } from '@/api/contract' | 117 | +import { getContractApi, deleteContractApi, uploadFormalContract, statusStyle } from '@/api/contract' |
| 117 | import ProductRel from './productRel.vue' | 118 | import ProductRel from './productRel.vue' |
| 118 | import DetailButtons from '@/components/detail-buttons/index.vue' | 119 | import DetailButtons from '@/components/detail-buttons/index.vue' |
| 119 | import FileUpload from '@/components/file-upload/index.vue' | 120 | import FileUpload from '@/components/file-upload/index.vue' |
| @@ -168,6 +169,7 @@ export default { | @@ -168,6 +169,7 @@ export default { | ||
| 168 | component: '', | 169 | component: '', |
| 169 | packaging: '' | 170 | packaging: '' |
| 170 | }, | 171 | }, |
| 172 | + statusStyle: statusStyle, | ||
| 171 | productList: [], | 173 | productList: [], |
| 172 | buttons: [{ | 174 | buttons: [{ |
| 173 | text: '编辑', | 175 | text: '编辑', |
| @@ -285,6 +287,14 @@ export default { | @@ -285,6 +287,14 @@ export default { | ||
| 285 | this.loadDetail() | 287 | this.loadDetail() |
| 286 | }, | 288 | }, |
| 287 | methods: { | 289 | methods: { |
| 290 | + getStatusCss(name) { | ||
| 291 | + const list = Array.isArray(this.statusStyle) ? this.statusStyle : [] | ||
| 292 | + const found = list.find(it => it && it.text === name) || {} | ||
| 293 | + return { | ||
| 294 | + color: found.color || '#000', | ||
| 295 | + backgroundColor: found.bgColor || '#000' | ||
| 296 | + } | ||
| 297 | + }, | ||
| 288 | onDelete() { | 298 | onDelete() { |
| 289 | uni.showModal({ | 299 | uni.showModal({ |
| 290 | title: '确认删除', | 300 | title: '确认删除', |
| @@ -465,7 +475,13 @@ export default { | @@ -465,7 +475,13 @@ export default { | ||
| 465 | flex: 1; | 475 | flex: 1; |
| 466 | padding: 8rpx 0 144rpx; | 476 | padding: 8rpx 0 144rpx; |
| 467 | } | 477 | } |
| 468 | - | 478 | +.info-status { |
| 479 | + padding: 4rpx 12rpx; | ||
| 480 | + border-radius: 6rpx; | ||
| 481 | + font-size: 24rpx; | ||
| 482 | + color: #fff; | ||
| 483 | + line-height: 40rpx; | ||
| 484 | +} | ||
| 469 | .detail-page { | 485 | .detail-page { |
| 470 | background: #f3f3f3; | 486 | background: #f3f3f3; |
| 471 | } | 487 | } |