|
@@ -43,7 +43,7 @@
|
|
|
<el-button type="primary" size="mini" @click="display = 'list'">返回</el-button>
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
- <techDetail :detailInfo="techDetail"></techDetail>
|
|
|
+ <techDetail :detailInfo="techDetail" @onSubmit="techSubmit"></techDetail>
|
|
|
</el-col>
|
|
|
</span>
|
|
|
<span v-else-if="column_name == '技术成果'">
|
|
@@ -51,7 +51,7 @@
|
|
|
<el-button type="primary" size="mini" @click="display = 'list'">返回</el-button>
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
- <achiDetail :detailInfo="achiDetail"></achiDetail>
|
|
|
+ <achiDetail :detailInfo="achiDetail" @onSubmit="techSubmit"></achiDetail>
|
|
|
</el-col>
|
|
|
</span>
|
|
|
<span v-else-if="column_name == '商务信息'">
|
|
@@ -59,7 +59,7 @@
|
|
|
<el-button type="primary" size="mini" @click="display = 'list'">返回</el-button>
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
- <busiDetail :detailInfo="busiDetail"></busiDetail>
|
|
|
+ <busiDetail :detailInfo="busiDetail" @onSubmit="techSubmit"></busiDetail>
|
|
|
</el-col>
|
|
|
</span>
|
|
|
<span v-else-if="column_name == '专家服务'">
|
|
@@ -67,7 +67,7 @@
|
|
|
<el-button type="primary" size="mini" @click="display = 'list'">返回</el-button>
|
|
|
</el-col>
|
|
|
<el-col :span="24">
|
|
|
- <expeDetail :detailInfo="expeDetail"></expeDetail>
|
|
|
+ <expeDetail :detailInfo="expeDetail" @onSubmit="expertSuubmit"></expeDetail>
|
|
|
</el-col>
|
|
|
</span>
|
|
|
</span>
|
|
@@ -92,6 +92,7 @@ import expeDetail from './detail/expeDetail.vue';
|
|
|
import { mapState, createNamespacedHelpers } from 'vuex';
|
|
|
const { mapActions: product } = createNamespacedHelpers('enterpriseproject');
|
|
|
const { mapActions: expertsuser } = createNamespacedHelpers('expertsuser');
|
|
|
+const { mapActions: transaction } = createNamespacedHelpers('transaction');
|
|
|
export default {
|
|
|
name: 'marketlists',
|
|
|
props: {},
|
|
@@ -148,6 +149,7 @@ export default {
|
|
|
methods: {
|
|
|
...product({ productList: 'newquery', productFetch: 'newfetch' }),
|
|
|
...expertsuser({ expertsuserList: 'query', expertsuserFetch: 'fetch' }),
|
|
|
+ ...transaction({ transactioncreate: 'create', transactionfetch: 'fetch' }),
|
|
|
// 查询栏目,列表,详情
|
|
|
async searchColumn() {
|
|
|
if (this.type == 0) {
|
|
@@ -217,6 +219,54 @@ export default {
|
|
|
this.display = 'detail';
|
|
|
this.searchDetail(column_name, id);
|
|
|
},
|
|
|
+ // 科技需求,技术成果,商务信息洽谈交易
|
|
|
+ async techSubmit({ data }) {
|
|
|
+ let form = {
|
|
|
+ userid: this.user.uid,
|
|
|
+ username: this.user.name,
|
|
|
+ product_id: data.id,
|
|
|
+ product_name: data.name,
|
|
|
+ market_userid: data.userid,
|
|
|
+ market_username: data.contacts,
|
|
|
+ status: '0',
|
|
|
+ };
|
|
|
+ if (!this.user.uid) {
|
|
|
+ this.$message({
|
|
|
+ dangerouslyUseHTMLString: true,
|
|
|
+ message: '<strong><a href="http://free.liaoningdoupo.com/platlive/webLogin" style="color:red;">游客身份无法与卖家对话,请先注册</a></strong>',
|
|
|
+ type: 'error',
|
|
|
+ });
|
|
|
+ return;
|
|
|
+ } else {
|
|
|
+ let res = await this.transactioncreate(form);
|
|
|
+ this.$checkRes(res, '购买申请成功', res.errmsg || '购买申请失败');
|
|
|
+ }
|
|
|
+ },
|
|
|
+ // 专家服务
|
|
|
+ async expertSuubmit({ data }) {
|
|
|
+ let form = {
|
|
|
+ userid: this.user.uid,
|
|
|
+ username: this.user.name,
|
|
|
+ product_id: data.id,
|
|
|
+ product_name: data.name,
|
|
|
+ market_userid: data.id,
|
|
|
+ market_username: data.name,
|
|
|
+ status: '0',
|
|
|
+ type: '1',
|
|
|
+ };
|
|
|
+ if (!this.user.uid) {
|
|
|
+ // this.$message.error('游客身份无法与卖家对话,请先注册');
|
|
|
+ this.$message({
|
|
|
+ dangerouslyUseHTMLString: true,
|
|
|
+ message: '<strong><a href="http://free.liaoningdoupo.com/platlive/webLogin" style="color:red;">游客身份无法与卖家对话,请先注册</a></strong>',
|
|
|
+ type: 'error',
|
|
|
+ });
|
|
|
+ return;
|
|
|
+ } else {
|
|
|
+ let res = await this.transactioncreate(form);
|
|
|
+ this.$checkRes(res, '购买申请成功', res.errmsg || '购买申请失败');
|
|
|
+ }
|
|
|
+ },
|
|
|
},
|
|
|
computed: {
|
|
|
...mapState(['user']),
|