|
|
@@ -1,52 +1,25 @@
|
|
|
<!-- 交易市场-预售转让-预售中签-详情 -->
|
|
|
<template>
|
|
|
- <app-drawer title="商品详情" v-model:show="show" :width="800" :refresh="refresh">
|
|
|
- <div class="g-detail__desc">
|
|
|
- <template v-for="(url, index) in detailBanners" :key="index">
|
|
|
- <img :src="url" alt="" />
|
|
|
+ <app-drawer title="商品详情" v-model:show="show" :width="600" :refresh="refresh">
|
|
|
+ <AppTableDetails :title="selectedRow.goodscode + ' ' + selectedRow.goodsname" :label-width="100" :data="selectedRow"
|
|
|
+ :cell-props="detailProps" :column="2">
|
|
|
+ <!-- 预售定金 -->
|
|
|
+ <template #earnest>
|
|
|
+ {{ earnest }}
|
|
|
</template>
|
|
|
- </div>
|
|
|
- <div class="g-detail__buy">
|
|
|
- <div class="topic">
|
|
|
- <div class="topic-left">
|
|
|
- <span class="price-text">发行价</span>
|
|
|
- <span class="price-unit">¥</span>
|
|
|
- <span class="price-integer">{{ selectedRow.refprice?.toFixed(2) }}</span>
|
|
|
- </div>
|
|
|
- <div class="topic-right">
|
|
|
- <span>开始:{{ selectedRow.starttime }}</span>
|
|
|
- <span>结束:{{ selectedRow.endtime }}</span>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="title">
|
|
|
- <el-tag type="danger" round>摇号中签</el-tag>
|
|
|
- <span>{{ selectedRow.sellname }}</span>
|
|
|
- <span>{{ selectedRow.goodscode }}/{{ selectedRow.goodsname }}</span>
|
|
|
- </div>
|
|
|
- <div class="qty">
|
|
|
- <span>总量:{{ selectedRow.presaleqty }}</span>
|
|
|
- </div>
|
|
|
- <div class="info">
|
|
|
- <ul>
|
|
|
- <li>
|
|
|
- <span>预售定金</span>
|
|
|
- <span>{{ earnest }}</span>
|
|
|
- </li>
|
|
|
- <li>
|
|
|
- <span>转让定金</span>
|
|
|
- <span>{{ parsePercent(selectedRow.transferdepositratio) }}</span>
|
|
|
- </li>
|
|
|
- </ul>
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- <div class="g-detail__desc">
|
|
|
+ <!-- 转让定金 -->
|
|
|
+ <template #transferdepositratio>
|
|
|
+ {{ parsePercent(selectedRow.transferdepositratio) }}
|
|
|
+ </template>
|
|
|
+ </AppTableDetails>
|
|
|
+ <div style="margin-top: 20px;">
|
|
|
<template v-for="(url, index) in detailImages" :key="index">
|
|
|
<img :src="url" alt="" />
|
|
|
</template>
|
|
|
</div>
|
|
|
- <template #footer v-if="selectedRow.presalestatus === 2">
|
|
|
+ <template #footer>
|
|
|
<el-button type="info" @click="onCancel(false)">取消</el-button>
|
|
|
- <el-button type="primary" @click="onSubmit">我要认购</el-button>
|
|
|
+ <el-button type="primary" @click="onSubmit" v-if="selectedRow.presalestatus === 2">我要认购</el-button>
|
|
|
<component ref="componentRef" v-bind="{ selectedRow }" :is="componentMap.get(componentId)"
|
|
|
@closed="closeComponent" v-if="componentId" />
|
|
|
</template>
|
|
|
@@ -58,12 +31,13 @@ import { shallowRef, computed, PropType, defineAsyncComponent } from 'vue'
|
|
|
import { getFileUrl, parsePercent } from '@/filters'
|
|
|
import { useComponent } from '@/hooks/component'
|
|
|
import AppDrawer from '@pc/components/base/drawer/index.vue'
|
|
|
+import AppTableDetails from '@pc/components/base/table-details/index.vue'
|
|
|
|
|
|
const componentMap = new Map<string, unknown>([
|
|
|
['delisting', defineAsyncComponent(() => import('./delisting/index.vue'))], // 摘牌
|
|
|
])
|
|
|
|
|
|
-const { componentRef, componentId, openComponent, closeComponent } = useComponent(false)
|
|
|
+const { componentRef, componentId, openComponent, closeComponent } = useComponent()
|
|
|
|
|
|
const props = defineProps({
|
|
|
selectedRow: {
|
|
|
@@ -72,11 +46,15 @@ const props = defineProps({
|
|
|
}
|
|
|
})
|
|
|
|
|
|
-// 商品banner
|
|
|
-const detailBanners = computed(() => {
|
|
|
- const bannerpicurl = props.selectedRow.bannerpicurl ?? ''
|
|
|
- return bannerpicurl?.split(',').map((path) => getFileUrl(path))
|
|
|
-})
|
|
|
+const detailProps = [
|
|
|
+ { prop: 'refprice', label: '发行价:' },
|
|
|
+ { prop: 'sellname', label: '销售方:' },
|
|
|
+ { prop: 'starttime', label: '开始时间:' },
|
|
|
+ { prop: 'earnest', label: '预售定金:' },
|
|
|
+ { prop: 'endtime', label: '结束时间:' },
|
|
|
+ { prop: 'transferdepositratio', label: '转让定金:' },
|
|
|
+ { prop: 'presaleqty', label: '总量:' },
|
|
|
+]
|
|
|
|
|
|
// 预售定金
|
|
|
const earnest = computed(() => {
|