| | |
| | | :colspan="getColspan(priceItem)" |
| | | class="feature-value" |
| | | > |
| | | <div class="order-methods"> |
| | | <span |
| | | v-for="method in priceItem.priceSettings" |
| | | :key="method" |
| | | class="method-item" |
| | | > |
| | | ✓ {{ getPriceSettingText(method) }} |
| | | </span> |
| | | </div> |
| | | {{ priceItem.priceSettings.map((m:any) => getPriceSettingText(m)).join('、') }} |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | |
| | | :colspan="getColspan(priceItem)" |
| | | class="feature-value" |
| | | > |
| | | <div class="price-info"> |
| | | <div |
| | | v-if="priceItem.priceSettings.includes('POINTS') && priceItem.pointsAmount > 0" |
| | | class="price-item" |
| | | > |
| | | <div class="price-lable-icon"> |
| | | <el-icon class="price-icon points"><Coin /></el-icon> |
| | | <span class="price-label">积分</span> |
| | | </div> |
| | | <span class="price-value points">{{ formatNumber(priceItem.pointsAmount) }} / {{ getPriceUnitText(priceItem.priceUnit) }}</span> |
| | | </div> |
| | | <div |
| | | v-if="priceItem.priceSettings.includes('CURRENCY') && priceItem.currencyAmount > 0" |
| | | class="price-item" |
| | | > |
| | | <div class="price-lable-icon"> |
| | | <span class="price-icon currency">¥</span> |
| | | <span class="price-label">货币</span> |
| | | </div> |
| | | <span class="price-value currency">{{ formatNumber(priceItem.currencyAmount) }} / {{ getPriceUnitText(priceItem.priceUnit) }}</span> |
| | | </div> |
| | | <div |
| | | v-if="priceItem.priceSettings.includes('FREE')" |
| | | class="price-item" |
| | | > |
| | | <span class="price-label">费用</span> |
| | | <span class="price-value free">免费</span> |
| | | </div> |
| | | <div |
| | | v-if="priceItem.priceSettings.includes('AGREEMENT')" |
| | | class="price-item" |
| | | > |
| | | <span class="price-label">协议:</span> |
| | | <span class="price-value agreement">每{{ getPriceUnitText(priceItem.priceUnit) }}</span> |
| | | </div> |
| | | </div> |
| | | {{ renderPrice(priceItem) }} |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | |
| | | <table class="order-info-table"> |
| | | <tbody> |
| | | <tr> |
| | | <td class="label">订单编号:</td> |
| | | <td class="value">{{ orderStatus.id }}</td> |
| | | <td class="label">申请时间:</td> |
| | | <td class="label">订单编号</td> |
| | | <td class="value"> |
| | | {{ orderStatus.id }} |
| | | <el-link type="primary" @click="goBuyerCenter" style="margin-left: 8px">点击查看</el-link> |
| | | </td> |
| | | <td class="label">申请时间</td> |
| | | <td class="value">{{ orderStatus.applyTime }}</td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label">产品名称:</td> |
| | | <td class="label">产品名称</td> |
| | | <td class="value">{{ orderStatus.productName }}</td> |
| | | <td class="label">提供者:</td> |
| | | <td class="label">提供者</td> |
| | | <td class="value">{{ orderStatus.provider }}</td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label">订单状态:</td> |
| | | <td class="label">订单状态</td> |
| | | <td class="value">{{ statusText(orderStatus.status) }}</td> |
| | | <td></td> |
| | | <td class="value link"> |
| | |
| | | |
| | | <script setup lang="ts"> |
| | | import { ref, watch, computed, onMounted } from 'vue' |
| | | import { useRouter } from 'vue-router' |
| | | import { ElMessage } from 'element-plus' |
| | | import { useRoute } from 'vue-router' |
| | | import productPricingApi from '@/api/productPricingApi' |
| | |
| | | import workFlowApi from '@/api/workFlowApi' |
| | | |
| | | const route = useRoute() |
| | | const router = useRouter() |
| | | |
| | | interface PriceItem { |
| | | id: number |
| | |
| | | |
| | | const viewOrder = () => { |
| | | window.alert('这里可跳转到订单详情页(示例)') |
| | | } |
| | | |
| | | const goBuyerCenter = () => { |
| | | router.push({ name: 'tradeBuyerCenter', query: { t: String(Date.now()) } }) |
| | | } |
| | | |
| | | const selectedCount = computed(() => orderSuites.value.filter(s => s.selected).length) |
| | |
| | | PRIVATE_INCREMENT: '私有增量包', |
| | | PUBLIC_INCREMENT: '公有增量包', |
| | | OTA: 'OTA服务', |
| | | CLOUD: '云服务' |
| | | CLOUD: '云服务', |
| | | RESOURCE_PACKAGE: '资源包', |
| | | PERSONAL: '个人' |
| | | } |
| | | return map[salesForm] || salesForm |
| | | } |
| | |
| | | return map[unit] || unit |
| | | } |
| | | |
| | | // 统一渲染价格:去除“积分/货币/费用/协议”等类型前缀,仅输出纯价格文本 |
| | | const renderPrice = (priceItem: PriceItem) => { |
| | | const segments: string[] = [] |
| | | if (priceItem.priceSettings.includes('POINTS') && priceItem.pointsAmount > 0) { |
| | | segments.push(`${formatNumber(priceItem.pointsAmount)} / ${getPriceUnitText(priceItem.priceUnit)}`) |
| | | } |
| | | if (priceItem.priceSettings.includes('CURRENCY') && priceItem.currencyAmount > 0) { |
| | | segments.push(`${formatNumber(priceItem.currencyAmount)} / ${getPriceUnitText(priceItem.priceUnit)}`) |
| | | } |
| | | if (priceItem.priceSettings.includes('FREE')) { |
| | | segments.push('免费') |
| | | } |
| | | if (priceItem.priceSettings.includes('AGREEMENT')) { |
| | | segments.push(`每${getPriceUnitText(priceItem.priceUnit)}`) |
| | | } |
| | | return segments.join(';') |
| | | } |
| | | |
| | | // 获取分组后的表头数据 |
| | | const getGroupedHeaders = (tabData: PriceItem[]) => { |
| | | const groups: Record<string, { count: number; productSuite: string }> = {} |