|
@@ -26,7 +26,18 @@
|
|
<el-col :span="17" class="centerInfo">
|
|
<el-col :span="17" class="centerInfo">
|
|
<el-image :src="infoUrl"></el-image>
|
|
<el-image :src="infoUrl"></el-image>
|
|
<el-col :span="24" class="message">
|
|
<el-col :span="24" class="message">
|
|
- xinxi
|
|
|
|
|
|
+ <el-col :span="12" class="messageLeft">
|
|
|
|
+ <p>项目名称</p>
|
|
|
|
+ <p>产品名称:{{ dealDetails.product_name }}</p>
|
|
|
|
+ <p>发布时间:{{ dealDetails.meta | getDate }}</p>
|
|
|
|
+ <p>产品说明:{{ dealDetails.description }}</p>
|
|
|
|
+ </el-col>
|
|
|
|
+ <el-col :span="12" class="messageRight">
|
|
|
|
+ <p :span="24">购买人:{{ dealDetails.username }}</p>
|
|
|
|
+ <el-col :span="24" v-if="dealDetails.pic">
|
|
|
|
+ <el-image style="width:100%;height:400px;" :src="dealDetails.pic"></el-image>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-col>
|
|
</el-col>
|
|
</el-col>
|
|
</el-col>
|
|
</el-col>
|
|
</el-col>
|
|
</el-col>
|
|
@@ -47,7 +58,7 @@
|
|
|
|
|
|
<script>
|
|
<script>
|
|
import { mapState, createNamespacedHelpers } from 'vuex';
|
|
import { mapState, createNamespacedHelpers } from 'vuex';
|
|
-const { mapActions } = createNamespacedHelpers('transaction');
|
|
|
|
|
|
+const { mapActions: transaction } = createNamespacedHelpers('transaction');
|
|
export default {
|
|
export default {
|
|
name: 'dealDetail',
|
|
name: 'dealDetail',
|
|
props: {},
|
|
props: {},
|
|
@@ -66,12 +77,30 @@ export default {
|
|
},
|
|
},
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- ...mapActions(['fetch']),
|
|
|
|
|
|
+ ...transaction(['fetch']),
|
|
async search() {
|
|
async search() {
|
|
let res = await this.fetch(this.id);
|
|
let res = await this.fetch(this.id);
|
|
res.data.status = parseInt(res.data.status);
|
|
res.data.status = parseInt(res.data.status);
|
|
|
|
+ // this.$set(this, `dealDetails`, res.data);
|
|
|
|
+ // if (res.data.status == 0) {
|
|
|
|
+ // res.data.status = res.data.status + 1;
|
|
|
|
+ // } else if (res.data.status == 1) {
|
|
|
|
+ // res.data.status = res.data.status + 1;
|
|
|
|
+ // } else if (res.data.status == 2) {
|
|
|
|
+ // res.data.status = res.data.status + 1;
|
|
|
|
+ // }
|
|
|
|
+ res.data.status = res.data.status + 1;
|
|
this.$set(this, `dealDetails`, res.data);
|
|
this.$set(this, `dealDetails`, res.data);
|
|
- console.log(res);
|
|
|
|
|
|
+ },
|
|
|
|
+ },
|
|
|
|
+ filters: {
|
|
|
|
+ getDate(meta) {
|
|
|
|
+ let createdAt = _.get(meta, `createdAt`);
|
|
|
|
+ let date = new Date(createdAt)
|
|
|
|
+ .toLocaleDateString()
|
|
|
|
+ .replace('/', '-')
|
|
|
|
+ .replace('/', '-');
|
|
|
|
+ return date;
|
|
},
|
|
},
|
|
},
|
|
},
|
|
};
|
|
};
|
|
@@ -161,6 +190,48 @@ export default {
|
|
left: 14%;
|
|
left: 14%;
|
|
width: 77%;
|
|
width: 77%;
|
|
height: 455px;
|
|
height: 455px;
|
|
|
|
+ overflow: hidden;
|
|
|
|
+}
|
|
|
|
+// .main .two .info .center .centerInfo .message .messageLeft {
|
|
|
|
+// }
|
|
|
|
+.main .two .info .center .centerInfo .message .messageLeft p:first-child {
|
|
|
|
+ text-align: center;
|
|
|
|
+ font-size: 30px;
|
|
|
|
+ font-family: 黑体;
|
|
|
|
+ letter-spacing: 10px;
|
|
|
|
+ padding: 0 0 15px 0;
|
|
|
|
+}
|
|
|
|
+.main .two .info .center .centerInfo .message .messageLeft p:nth-child(2) {
|
|
|
|
+ font-size: 22px;
|
|
|
|
+ font-family: 黑体;
|
|
|
|
+ padding: 0 10px 15px 10px;
|
|
|
|
+ overflow: hidden;
|
|
|
|
+ text-overflow: ellipsis;
|
|
|
|
+ white-space: nowrap;
|
|
|
|
+}
|
|
|
|
+.main .two .info .center .centerInfo .message .messageLeft p:nth-child(3) {
|
|
|
|
+ font-size: 22px;
|
|
|
|
+ font-family: 黑体;
|
|
|
|
+ padding: 0 10px 15px 10px;
|
|
|
|
+}
|
|
|
|
+.main .two .info .center .centerInfo .message .messageLeft p:nth-child(4) {
|
|
|
|
+ font-size: 22px;
|
|
|
|
+ font-family: 黑体;
|
|
|
|
+ padding: 0 10px 15px 10px;
|
|
|
|
+ overflow: hidden;
|
|
|
|
+ text-overflow: ellipsis;
|
|
|
|
+ -webkit-line-clamp: 12;
|
|
|
|
+ word-break: break-all;
|
|
|
|
+ display: -webkit-box;
|
|
|
|
+ -webkit-box-orient: vertical;
|
|
|
|
+ line-height: 27px;
|
|
|
|
+}
|
|
|
|
+// .main .two .info .center .centerInfo .message .messageRight {
|
|
|
|
+// }
|
|
|
|
+.main .two .info .center .centerInfo .message .messageRight p {
|
|
|
|
+ font-size: 30px;
|
|
|
|
+ font-family: 黑体;
|
|
|
|
+ padding: 0 10px 15px 10px;
|
|
}
|
|
}
|
|
.main .two .info .right {
|
|
.main .two .info .right {
|
|
width: 20px;
|
|
width: 20px;
|