Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
U
uni-pdtravel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
panyongping
uni-pdtravel
Commits
5a75068b
Commit
5a75068b
authored
May 26, 2021
by
潘永坪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
支付联调
parent
cf0a1f06
Changes
16
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
16 changed files
with
493 additions
and
70 deletions
+493
-70
index.vue
pages/index/index.vue
+8
-3
payment.vue
pages/payment/payment.vue
+133
-16
main.js.map
unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map
+1
-1
index.js.map
...ge/dist/dev/.sourcemap/mp-weixin/pages/index/index.js.map
+1
-1
payment.js.map
...ist/dev/.sourcemap/mp-weixin/pages/payment/payment.js.map
+1
-1
index.axml
unpackage/dist/dev/mp-alipay/pages/index/index.axml
+1
-1
index.js
unpackage/dist/dev/mp-alipay/pages/index/index.js
+5
-0
payment.axml
unpackage/dist/dev/mp-alipay/pages/payment/payment.axml
+1
-1
payment.js
unpackage/dist/dev/mp-alipay/pages/payment/payment.js
+148
-15
app.json
unpackage/dist/dev/mp-weixin/app.json
+2
-1
index.js
unpackage/dist/dev/mp-weixin/pages/index/index.js
+5
-0
index.wxml
unpackage/dist/dev/mp-weixin/pages/index/index.wxml
+1
-1
payment.js
unpackage/dist/dev/mp-weixin/pages/payment/payment.js
+160
-27
payment.wxml
unpackage/dist/dev/mp-weixin/pages/payment/payment.wxml
+1
-1
project.config.json
unpackage/dist/dev/mp-weixin/project.config.json
+1
-1
project.private.config.json
unpackage/dist/dev/mp-weixin/project.private.config.json
+24
-0
No files found.
pages/index/index.vue
View file @
5a75068b
...
...
@@ -53,12 +53,12 @@
<!--
<button
@
click=
"getUserInfo()"
>
授权获取头像昵称
</button>
-->
<view
class=
"bottom"
>
<!--#ifdef MP-WEIXIN -->
<
web-view
src=
"https://wx.pangdly.com"
></web-view
>
<
!--
<web-view
src=
"https://wx.pangdly.com"
></web-view>
--
>
<!--#endif-->
<!--#ifdef MP-ALIPAY -->
<
web-view
src=
"https://wx.pangdly.com?appId=2021001194629244&ticket=123456"
></web-view
>
<
!--
<web-view
src=
"https://wx.pangdly.com?appId=2021001194629244&ticket=123456"
></web-view>
--
>
<!--#endif-->
<button
@
click=
"aaa()"
>
456
</button>
</view>
</view>
</
template
>
...
...
@@ -116,6 +116,11 @@
}
})
},
aaa
(){
uni
.
navigateTo
({
url
:
'../payment/payment'
});
}
}
}
...
...
pages/payment/payment.vue
View file @
5a75068b
<
template
>
<view>
<div
class=
"middle"
v-show=
"bodyShow"
>
<div
class=
"main"
>
<!-- --------------------------------------复票----------------------------------------------- -->
<div
v-if=
"orderList!=''"
v-for=
"item of orderList"
:key=
"item.id"
class=
"product"
>
<p>
<span>
{{
item
.
merchantName
}}
(
{{
item
.
productName
}}
)
</span>
<span>
<small
style=
"font-size: 0.24rem;"
>
¥
</small>
{{
item
.
unitPrice
}}
<i>
x
</i>
{{
item
.
orderNum
}}
<br
/>
<small
style=
"margin-top: 0.15rem;font-size: 0.22rem;display: inline-block;color:#f45803;"
v-if=
"item.depositReceived"
>
押金:
{{
item
.
depositReceived
}}
</small>
</span>
</p>
<p
class=
"coupon"
v-if=
"item.pdDiscountMoney"
>
<span>
券
</span>
<i>
<small
style=
"font-size: 0.24rem;"
>
-¥
</small>
{{
item
.
pdDiscountMoney
}}
</i>
</p>
</div>
<!-- --------------------------------------单票----------------------------------------------- -->
<div
v-if=
"orderList==''"
class=
"product"
>
<p>
<span>
{{
merchantName
}}
(
{{
productName
}}
)
</span>
<span
style=
"text-align: right;"
>
<small
style=
"font-size: 0.24rem;"
>
¥
</small>
{{
unitPrice
}}
<i>
x
</i>
{{
orderNum
}}
<br
/>
<small
style=
"margin-top: 0.15rem;font-size: 0.22rem;display: inline-block;color:#f45803;"
v-if=
"depositReceived"
>
押金:
{{
depositReceived
}}
</small>
</span>
</p>
<p
class=
"coupon"
v-if=
"pdDiscountMoney"
>
<span>
券
</span>
<i>
<small
style=
"font-size: 0.24rem;"
>
-¥
</small>
{{
pdDiscountMoney
}}
</i>
</p>
</div>
<p
class=
"mainP3"
>
<span>
实际支付
</span>
<span>
<!--
<i>
¥
{{
totalMoney
}}
</i>
-->
<i>
<small
style=
"font-size: 0.28rem;"
>
¥
</small>
{{
pdOrderMoney
}}
</i>
</span>
</p>
<div
class=
"mainDiv"
>
<span>
<img
src=
"@/assets/img/common/weixin.png"
style=
"width: 0.7rem;"
/>
</span>
<div>
<p>
微信支付
</p>
</div>
<span>
<img
src=
"@/assets/img/common/input.png"
style=
"width: 0.32rem;"
/>
</span>
</div>
</div>
</div>
<div
class=
"bottom"
v-show=
"bodyShow"
>
<p>
<span>
实付款
</span>
<span>
<i>
¥
</i>
{{
pdOrderMoney
}}
</span>
</p>
<p>
<a
href=
"tel:400-072-0368"
>
<img
src=
"@/assets/img/combination/kefu11.png"
style=
"width: 0.31rem;"
/>
</a>
<a
@
click=
"weChatPay()"
>
去支付
</a>
</p>
</div>
</view>
</
template
>
...
...
@@ -12,22 +111,40 @@
}
},
onLoad
(
option
){
let
data
=
{
orderId
:
"z001622021317935817023873227d6b1"
,
//订单Id
userId
:
"oh2UV1lyYABHMZ1rMlgjhVHyyYDQ"
,
//用户Id
payType
:
42
,
//支付类型
}
this
.
$request
(
"orderc/order/findOrderInfo?debug=true"
,
data
).
then
((
res
)
=>
{
if
(
res
.
code
==
"00"
)
{
uni
.
requestPayment
({
provider
:
'wxpay'
,
timeStamp
:
option
.
timeS
tamp
,
nonceStr
:
option
.
nonceS
tr
,
package
:
option
.
package
,
signType
:
option
.
signType
,
paySign
:
option
.
payS
ign
,
timeStamp
:
res
.
data
.
times
tamp
,
nonceStr
:
res
.
data
.
nonces
tr
,
package
:
res
.
data
.
package
,
signType
:
res
.
data
.
signType
,
paySign
:
res
.
data
.
s
ign
,
success
:
function
(
res
)
{
uni
.
redirectTo
({
url
:
'paySuccess?orderId=123456'
})
},
fail
:
function
(
err
)
{
uni
.
showToast
(
err
)
uni
.
showToast
({
title
:
err
.
errMsg
,
duration
:
2000
})
}
})
}
else
{
uni
.
showToast
({
title
:
res
.
message
})
}
})
},
...
...
unpackage/dist/dev/.sourcemap/mp-weixin/common/main.js.map
View file @
5a75068b
This diff is collapsed.
Click to expand it.
unpackage/dist/dev/.sourcemap/mp-weixin/pages/index/index.js.map
View file @
5a75068b
This diff is collapsed.
Click to expand it.
unpackage/dist/dev/.sourcemap/mp-weixin/pages/payment/payment.js.map
View file @
5a75068b
This diff is collapsed.
Click to expand it.
unpackage/dist/dev/mp-alipay/pages/index/index.axml
View file @
5a75068b
<view class="bottom"><web-view src="https://wx.pangdly.com?appId=2021001194629244&ticket=123456"></web-view></view>
\ No newline at end of file
<view class="bottom"><button data-event-opts="{{[['tap',[['aaa']]]]}}" onTap="__e">456</button></view>
\ No newline at end of file
unpackage/dist/dev/mp-alipay/pages/index/index.js
View file @
5a75068b
...
...
@@ -253,6 +253,11 @@ var _default =
console
.
log
(
res
);
}
});
},
aaa
:
function
aaa
()
{
uni
.
navigateTo
({
url
:
'../payment/payment'
});
}
}
};
exports
.
default
=
_default
;
/* WEBPACK VAR INJECTION */
}.
call
(
this
,
__webpack_require__
(
/*! ./node_modules/@dcloudio/uni-mp-alipay/dist/index.js */
1
)[
"default"
]))
...
...
unpackage/dist/dev/mp-alipay/pages/payment/payment.axml
View file @
5a75068b
<view></view>
\ No newline at end of file
<view><view hidden="{{!(bodyShow)}}" class="middle _div"><view class="main _div"><block a:for="{{orderList}}" a:for-item="item" a:for-index="__i0__" a:key="id"><block a:if="{{orderList!=''}}"><view class="product _div"><view class="_p"><label class="_span">{{''+item.merchantName+"("+item.productName+')'}}</label><label class="_span"><view style="font-size:0.24rem;" class="_small">¥</view>{{item.unitPrice+''}}<view class="_i">x</view>{{''+item.orderNum}}<view class="_br"></view><block a:if="{{item.depositReceived}}"><view style="margin-top:0.15rem;font-size:0.22rem;display:inline-block;color:#f45803;" class="_small">{{"押金:"+item.depositReceived}}</view></block></label></view><block a:if="{{item.pdDiscountMoney}}"><view class="coupon _p"><label class="_span">券</label><view class="_i"><view style="font-size:0.24rem;" class="_small">-¥</view>{{item.pdDiscountMoney+''}}</view></view></block></view></block></block><block a:if="{{orderList==''}}"><view class="product _div"><view class="_p"><label class="_span">{{''+merchantName+"("+productName+')'}}</label><label style="text-align:right;" class="_span"><view style="font-size:0.24rem;" class="_small">¥</view>{{unitPrice+''}}<view class="_i">x</view>{{''+orderNum}}<view class="_br"></view><block a:if="{{depositReceived}}"><view style="margin-top:0.15rem;font-size:0.22rem;display:inline-block;color:#f45803;" class="_small">{{"押金:"+depositReceived}}</view></block></label></view><block a:if="{{pdDiscountMoney}}"><view class="coupon _p"><label class="_span">券</label><view class="_i"><view style="font-size:0.24rem;" class="_small">-¥</view>{{pdDiscountMoney+''}}</view></view></block></view></block><view class="mainP3 _p"><label class="_span">实际支付</label><label class="_span"><view class="_i"><view style="font-size:0.28rem;" class="_small">¥</view>{{pdOrderMoney+''}}</view></label></view><view class="mainDiv _div"><label class="_span"><image style="width:0.7rem;" src="{{$root.m0}}" class="_img"></image></label><view class="_div"><view class="_p">微信支付</view></view><label class="_span"><image style="width:0.32rem;" src="{{$root.m1}}" class="_img"></image></label></view></view></view><view hidden="{{!(bodyShow)}}" class="bottom _div"><view class="_p"><label class="_span">实付款</label><label class="_span"><view class="_i">¥</view>{{pdOrderMoney+''}}</label></view><view class="_p"><navigator href="tel:400-072-0368" class="_a"><image style="width:0.31rem;" src="{{$root.m2}}" class="_img"></image></navigator><navigator data-event-opts="{{[['tap',[['weChatPay']]]]}}" onTap="__e" class="_a">去支付</navigator></view></view></view>
\ No newline at end of file
unpackage/dist/dev/mp-alipay/pages/payment/payment.js
View file @
5a75068b
...
...
@@ -95,6 +95,22 @@ var render = function() {
var
_vm
=
this
var
_h
=
_vm
.
$createElement
var
_c
=
_vm
.
_self
.
_c
||
_h
var
m0
=
__webpack_require__
(
!
(
function
webpackMissingModule
()
{
var
e
=
new
Error
(
"Cannot find module '@/assets/img/common/weixin.png'"
);
e
.
code
=
'MODULE_NOT_FOUND'
;
throw
e
;
}()))
var
m1
=
__webpack_require__
(
!
(
function
webpackMissingModule
()
{
var
e
=
new
Error
(
"Cannot find module '@/assets/img/common/input.png'"
);
e
.
code
=
'MODULE_NOT_FOUND'
;
throw
e
;
}()))
var
m2
=
__webpack_require__
(
!
(
function
webpackMissingModule
()
{
var
e
=
new
Error
(
"Cannot find module '@/assets/img/combination/kefu11.png'"
);
e
.
code
=
'MODULE_NOT_FOUND'
;
throw
e
;
}()))
_vm
.
$mp
.
data
=
Object
.
assign
(
{},
{
$root
:
{
m0
:
m0
,
m1
:
m1
,
m2
:
m2
}
}
)
}
var
recyclableRender
=
false
var
staticRenderFns
=
[]
...
...
@@ -134,6 +150,105 @@ __webpack_require__.r(__webpack_exports__);
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
//
var
_default
=
{
data
:
function
data
()
{
...
...
@@ -142,22 +257,40 @@ var _default =
},
onLoad
:
function
onLoad
(
option
)
{
var
data
=
{
orderId
:
"z001622021317935817023873227d6b1"
,
//订单Id
userId
:
"oh2UV1lyYABHMZ1rMlgjhVHyyYDQ"
,
//用户Id
payType
:
42
//支付类型
};
this
.
$request
(
"orderc/order/findOrderInfo?debug=true"
,
data
).
then
(
function
(
res
)
{
if
(
res
.
code
==
"00"
)
{
uni
.
requestPayment
({
provider
:
'wxpay'
,
timeStamp
:
option
.
timeS
tamp
,
nonceStr
:
option
.
nonceS
tr
,
package
:
option
.
package
,
signType
:
option
.
signType
,
paySign
:
option
.
payS
ign
,
timeStamp
:
res
.
data
.
times
tamp
,
nonceStr
:
res
.
data
.
nonces
tr
,
package
:
res
.
data
.
package
,
signType
:
res
.
data
.
signType
,
paySign
:
res
.
data
.
s
ign
,
success
:
function
success
(
res
)
{
uni
.
redirectTo
({
url
:
'paySuccess?orderId=123456'
});
},
fail
:
function
fail
(
err
)
{
uni
.
showToast
(
err
);
uni
.
showToast
({
title
:
err
.
errMsg
,
duration
:
2000
});
}
});
}
else
{
uni
.
showToast
({
title
:
res
.
message
});
}
});
}
};
exports
.
default
=
_default
;
/* WEBPACK VAR INJECTION */
}.
call
(
this
,
__webpack_require__
(
/*! ./node_modules/@dcloudio/uni-mp-alipay/dist/index.js */
1
)[
"default"
]))
...
...
unpackage/dist/dev/mp-weixin/app.json
View file @
5a75068b
...
...
@@ -15,5 +15,6 @@
"desc"
:
"请点击确定"
}
},
"usingComponents"
:
{}
"usingComponents"
:
{},
"sitemapLocation"
:
"sitemap.json"
}
\ No newline at end of file
unpackage/dist/dev/mp-weixin/pages/index/index.js
View file @
5a75068b
...
...
@@ -253,6 +253,11 @@ var _default =
console
.
log
(
res
);
}
});
},
aaa
:
function
aaa
()
{
uni
.
navigateTo
({
url
:
'../payment/payment'
});
}
}
};
exports
.
default
=
_default
;
/* WEBPACK VAR INJECTION */
}.
call
(
this
,
__webpack_require__
(
/*! ./node_modules/@dcloudio/uni-mp-weixin/dist/index.js */
1
)[
"default"
]))
...
...
unpackage/dist/dev/mp-weixin/pages/index/index.wxml
View file @
5a75068b
<view class="bottom"><web-view src="https://wx.pangdly.com"></web-view></view>
\ No newline at end of file
<view class="bottom"><button data-event-opts="{{[['tap',[['aaa']]]]}}" bindtap="__e">456</button></view>
\ No newline at end of file
unpackage/dist/dev/mp-weixin/pages/payment/payment.js
View file @
5a75068b
This diff is collapsed.
Click to expand it.
unpackage/dist/dev/mp-weixin/pages/payment/payment.wxml
View file @
5a75068b
<view></view>
\ No newline at end of file
<view><view hidden="{{!(bodyShow)}}" class="middle _div"><view class="main _div"><block wx:for="{{orderList}}" wx:for-item="item" wx:for-index="__i0__" wx:key="id"><block wx:if="{{orderList!=''}}"><view class="product _div"><view class="_p"><label class="_span">{{''+item.merchantName+"("+item.productName+')'}}</label><label class="_span"><view style="font-size:0.24rem;" class="_small">¥</view>{{item.unitPrice+''}}<view class="_i">x</view>{{''+item.orderNum}}<view class="_br"></view><block wx:if="{{item.depositReceived}}"><view style="margin-top:0.15rem;font-size:0.22rem;display:inline-block;color:#f45803;" class="_small">{{"押金:"+item.depositReceived}}</view></block></label></view><block wx:if="{{item.pdDiscountMoney}}"><view class="coupon _p"><label class="_span">券</label><view class="_i"><view style="font-size:0.24rem;" class="_small">-¥</view>{{item.pdDiscountMoney+''}}</view></view></block></view></block></block><block wx:if="{{orderList==''}}"><view class="product _div"><view class="_p"><label class="_span">{{''+merchantName+"("+productName+')'}}</label><label style="text-align:right;" class="_span"><view style="font-size:0.24rem;" class="_small">¥</view>{{unitPrice+''}}<view class="_i">x</view>{{''+orderNum}}<view class="_br"></view><block wx:if="{{depositReceived}}"><view style="margin-top:0.15rem;font-size:0.22rem;display:inline-block;color:#f45803;" class="_small">{{"押金:"+depositReceived}}</view></block></label></view><block wx:if="{{pdDiscountMoney}}"><view class="coupon _p"><label class="_span">券</label><view class="_i"><view style="font-size:0.24rem;" class="_small">-¥</view>{{pdDiscountMoney+''}}</view></view></block></view></block><view class="mainP3 _p"><label class="_span">实际支付</label><label class="_span"><view class="_i"><view style="font-size:0.28rem;" class="_small">¥</view>{{pdOrderMoney+''}}</view></label></view><view class="mainDiv _div"><label class="_span"><image style="width:0.7rem;" src="{{$root.m0}}" class="_img"></image></label><view class="_div"><view class="_p">微信支付</view></view><label class="_span"><image style="width:0.32rem;" src="{{$root.m1}}" class="_img"></image></label></view></view></view><view hidden="{{!(bodyShow)}}" class="bottom _div"><view class="_p"><label class="_span">实付款</label><label class="_span"><view class="_i">¥</view>{{pdOrderMoney+''}}</label></view><view class="_p"><navigator href="tel:400-072-0368" class="_a"><image style="width:0.31rem;" src="{{$root.m2}}" class="_img"></image></navigator><navigator data-event-opts="{{[['tap',[['weChatPay']]]]}}" bindtap="__e" class="_a">去支付</navigator></view></view></view>
\ No newline at end of file
unpackage/dist/dev/mp-weixin/project.config.json
View file @
5a75068b
...
...
@@ -4,7 +4,7 @@
"ignore"
:
[]
},
"setting"
:
{
"urlCheck"
:
tru
e
,
"urlCheck"
:
fals
e
,
"es6"
:
true
,
"enhance"
:
false
,
"postcss"
:
true
,
...
...
unpackage/dist/dev/mp-weixin/project.private.config.json
0 → 100644
View file @
5a75068b
{
"setting"
:
{},
"condition"
:
{
"plugin"
:
{
"list"
:
[]
},
"game"
:
{
"list"
:
[]
},
"gamePlugin"
:
{
"list"
:
[]
},
"miniprogram"
:
{
"list"
:
[
{
"name"
:
"pages/payment/payment"
,
"pathName"
:
"pages/payment/payment"
,
"query"
:
""
,
"scene"
:
null
}
]
}
}
}
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment