|
@@ -206,38 +206,22 @@ export default {
|
|
|
this.$http
|
|
this.$http
|
|
|
.post('/asset/gift', {
|
|
.post('/asset/gift', {
|
|
|
assetId: this.$route.query.id,
|
|
assetId: this.$route.query.id,
|
|
|
- toUserId: this.$route.query.toUserId
|
|
|
|
|
|
|
+ toUserId: this.$route.query.toUserId,
|
|
|
|
|
+ projectId: this.$store.state.projectId
|
|
|
})
|
|
})
|
|
|
.then(res => {
|
|
.then(res => {
|
|
|
this.orderId = res.id;
|
|
this.orderId = res.id;
|
|
|
this.$nextTick(() => {
|
|
this.$nextTick(() => {
|
|
|
if (this.payType === 'ALIPAY') {
|
|
if (this.payType === 'ALIPAY') {
|
|
|
- // document.location.replace(
|
|
|
|
|
- // resolveUrl(this.$baseUrl, 'payOrder/gift/alipay?id=' + res.id)
|
|
|
|
|
- // );
|
|
|
|
|
- this.$http
|
|
|
|
|
- .get(`/payOrder/gift/${this.inApp ? 'alipay_app' : 'alipay_h5'}?id=${res.id}`)
|
|
|
|
|
- .then(res => {
|
|
|
|
|
- this.hrefUrl = 'alipays://platformapi/startapp?saId=10000007&qrcode=' + res;
|
|
|
|
|
- // window.open(
|
|
|
|
|
- // 'alipays://platformapi/startapp?saId=10000007&qrcode=' + res,
|
|
|
|
|
- // '_blank'
|
|
|
|
|
- // );
|
|
|
|
|
- this.$nextTick(() => {
|
|
|
|
|
- document.getElementById('pay').click();
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ document.location.replace(
|
|
|
|
|
+ resolveUrl(this.$baseUrl, 'payOrder/gift/alipay?id=' + res.id)
|
|
|
|
|
+ );
|
|
|
|
|
+ this.$toast.loading({
|
|
|
|
|
+ message: '加载中...',
|
|
|
|
|
+ forbidClick: true
|
|
|
|
|
+ });
|
|
|
|
|
|
|
|
- this.$toast.loading({
|
|
|
|
|
- message: '加载中...',
|
|
|
|
|
- forbidClick: true
|
|
|
|
|
- });
|
|
|
|
|
- this.getOrder(true);
|
|
|
|
|
- })
|
|
|
|
|
- .catch(e => {
|
|
|
|
|
- if (e.error) {
|
|
|
|
|
- this.$toast(e.error);
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ this.getOrder(true);
|
|
|
} else if (this.payType === 'WEIXIN') {
|
|
} else if (this.payType === 'WEIXIN') {
|
|
|
if (this.inWeixin) {
|
|
if (this.inWeixin) {
|
|
|
this.$toast.loading('加载中');
|
|
this.$toast.loading('加载中');
|