提交 d069d0ba 编写于 作者: liangliang.yu's avatar liangliang.yu

feat: point data upload

上级 6320d2c3
...@@ -50,3 +50,12 @@ export const createOrderSzV2 = (data) => { ...@@ -50,3 +50,12 @@ export const createOrderSzV2 = (data) => {
data, data,
}); });
}; };
export const uploadPointData = data => {
return request({
url: '/tis/insurance/promotion_channel/report_data',
method: 'POST',
withCredentials: true,
data,
});
};
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
</template> </template>
<script> <script>
import { getLanZhouFlag} from '@/api/question'; import { getLanZhouFlag, uploadPointData} from '@/api/question';
export default { export default {
data() { data() {
return { return {
...@@ -21,12 +21,21 @@ export default { ...@@ -21,12 +21,21 @@ export default {
}, },
}, },
mounted() { mounted() {
const {externalOrderNo} = this.$route.query; const {externalOrderNo, channelCode} = this.$route.query;
if(channelCode) {
this.uploadPointData(channelCode);
}
if(externalOrderNo) { if(externalOrderNo) {
this.getJumpPageStatus(externalOrderNo); this.getJumpPageStatus(externalOrderNo);
} }
}, },
methods: { methods: {
uploadPointData(channelCode) {
uploadPointData({channelCode});
},
getJumpPageStatus(externalOrderNo) { getJumpPageStatus(externalOrderNo) {
getLanZhouFlag(externalOrderNo).then(res => { getLanZhouFlag(externalOrderNo).then(res => {
if (res.code === '000000') { if (res.code === '000000') {
......
...@@ -201,7 +201,7 @@ ...@@ -201,7 +201,7 @@
</template> </template>
<script> <script>
import { createOrderSzV2 } from '@/api/question'; import { createOrderSzV2, uploadPointData } from '@/api/question';
import { getBanner, getCardTypes } from '@/api/entitlement'; import { getBanner, getCardTypes } from '@/api/entitlement';
import DatePicker from './date-picker.vue'; import DatePicker from './date-picker.vue';
let that; let that;
...@@ -280,7 +280,10 @@ export default { ...@@ -280,7 +280,10 @@ export default {
mounted() { mounted() {
document.title = '惠民保癌筛权益领取'; document.title = '惠民保癌筛权益领取';
that = this; that = this;
const { externalOrderNo, projectEquityNo } = this.$route.query; const { externalOrderNo, projectEquityNo, channelCode } = this.$route.query;
if(channelCode) {
this.uploadPointData(channelCode);
}
this.projectEquityNo = projectEquityNo; this.projectEquityNo = projectEquityNo;
this.externalOrderNo = externalOrderNo; this.externalOrderNo = externalOrderNo;
// this.$loading.show(); // this.$loading.show();
...@@ -288,6 +291,11 @@ export default { ...@@ -288,6 +291,11 @@ export default {
this.loadCardTypes(); this.loadCardTypes();
}, },
methods: { methods: {
uploadPointData(channelCode) {
uploadPointData({channelCode});
},
async loadCardTypes() { async loadCardTypes() {
const { data } = await getCardTypes(); const { data } = await getCardTypes();
this.cardTypes = data || []; this.cardTypes = data || [];
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册