人人商城

payment.html 32KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753
  1. {template 'common/header'}
  2. <div class="we7-page-title">
  3. 支付参数设置
  4. </div>
  5. {if $do == 'display'}
  6. <ul class="we7-page-tab">
  7. {loop $active_sub_permission $active_menu}
  8. {if permission_check_account_user($active_menu['permission_name'], false) && (empty($active_menu['is_display']) || is_array($active_menu['is_display']) && in_array($_W['account']['type'], $active_menu['is_display']))}
  9. <li {if $action == $active_menu['active']}class="active"{/if}><a href="{$active_menu['url']}">{$active_menu['title']}</a></li>
  10. {/if}
  11. {/loop}
  12. </ul>
  13. <div class="js-profile-payment" ng-controller="paymentCtrl" ng-cloak>
  14. <table class="table we7-table table-hover table-form">
  15. <col width="140px " />
  16. <col width="400px"/>
  17. <col />
  18. <col width="140px" />
  19. <tr>
  20. <th colspan="2" >支付参数</th>
  21. <th colspan="1" >参数配置状态</th>
  22. <th colspan="1" >支持状态</th>
  23. <th colspan="1" >操作</th>
  24. </tr>
  25. <tr>
  26. <td colspan="2">
  27. 货到支付
  28. </td>
  29. <td>无需配置</td>
  30. <td>
  31. {{ paysetting.delivery.support_set === true ? '未设置' : '已设置' }}
  32. </td>
  33. <td class="text-center">
  34. <div class="link-group">
  35. <a href="{php echo url('profile/payment/switch', array('type' => 'delivery'))}">支付支持</a>
  36. </div>
  37. </td>
  38. </tr>
  39. <tr>
  40. <td colspan="2">
  41. 余额支付
  42. </td>
  43. <td>无需配置</td>
  44. <td>
  45. {{ paysetting.credit.support_set === true ? '未设置' : '已设置' }}
  46. </td>
  47. <td class="text-center">
  48. <div class="link-group">
  49. <a href="{php echo url('profile/payment/switch', array('type' => 'credit'))}">支付支持</a>
  50. </div>
  51. </td>
  52. </tr>
  53. <tr>
  54. <td colspan="1">
  55. 混合支付
  56. </td>
  57. <td>
  58. <span class="related-info">
  59. 余额不足时,可用剩余余额付部分,用其它支付付剩余部分
  60. </span>
  61. </td>
  62. <td>无需配置</td>
  63. <td>
  64. {{ paysetting.mix.support_set === true ? '未设置' : '已设置' }}
  65. </td>
  66. <td class="text-center">
  67. <div class="link-group">
  68. <a href="{php echo url('profile/payment/switch', array('type' => 'mix'))}">支付支持</a>
  69. </div>
  70. </td>
  71. </tr>
  72. <tr>
  73. <td>
  74. 支付宝支付
  75. </td>
  76. <td>
  77. <div class="related-info">
  78. 开启支付宝支付
  79. </div>
  80. </td>
  81. <td>
  82. {{ paysetting.alipay.has_config === true ? '已配置' : '未配置' }}
  83. </td>
  84. <td>
  85. {{ paysetting.alipay.support_set === true ? '未设置' : '已设置' }}
  86. </td>
  87. <td class="text-center">
  88. <div class="link-group">
  89. <a href="javascript:;" data-toggle="modal" data-target="#zhifubao">
  90. {{ paysetting.alipay.has_config === true ? '修改配置' : '去配置' }}
  91. </a>
  92. <a href="{php echo url('profile/payment/switch', array('type' => 'alipay'))}" ng-if="paysetting.alipay.has_config === true">支付支持</a>
  93. </div>
  94. </td>
  95. </tr>
  96. <tr>
  97. <td>
  98. 微信支付
  99. </td>
  100. <td>
  101. <div class="related-info">
  102. <div>接口类型:新版(2014年9月之后申请的)</div>
  103. <div>支付账号:{$_W['uniaccount']['name']}</div>
  104. </div>
  105. </td>
  106. <td >
  107. {{ paysetting.wechat.has_config === true ? '已配置' : '未配置' }}
  108. </td>
  109. <td>
  110. {{ paysetting.wechat.support_set === true ? '未设置' : '已设置' }}
  111. </td>
  112. <td class="text-center">
  113. <div class="link-group">
  114. <a href="javascript:;" ng-click="check_wechat()">
  115. {{ paysetting.wechat.has_config === true ? '修改配置' : '去配置' }}
  116. </a>
  117. <a href="{php echo url('profile/payment/switch', array('type' => 'wechat'))}" ng-if="paysetting.wechat.has_config === true">支付支持</a>
  118. </div>
  119. </td>
  120. </tr>
  121. <tr>
  122. <td>
  123. 服务商支付
  124. </td>
  125. <td>
  126. <div class="related-info">
  127. </div>
  128. </td>
  129. <td>
  130. {{ paysetting.wechat_facilitator.has_config === true ? '已配置' : '未配置' }}
  131. </td>
  132. <td>无需设置</td>
  133. <td class="text-center">
  134. <div class="link-group">
  135. <a href="javascript:;" class="color-default" data-toggle="modal" data-target="#wechat_fa">
  136. {{ paysetting.wechat_facilitator.has_config === true ? '修改配置' : '去配置' }}
  137. </a>
  138. </div>
  139. </td>
  140. </tr>
  141. <tr>
  142. <td>
  143. 一码支付
  144. </td>
  145. <td>
  146. <div class="related-info">
  147. </div>
  148. </td>
  149. <td >
  150. {{ paysetting.jueqiymf.has_config === true ? '已配置' : '未配置' }}
  151. </td>
  152. <td>
  153. {{ paysetting.jueqiymf.support_set === true ? '未设置' : '已设置' }}
  154. </td>
  155. <td class="text-center">
  156. <div class="link-group">
  157. <a href="javascript:;" data-toggle="modal" data-target="#jueqiymf">
  158. {{ paysetting.jueqiymf.has_config === true ? '修改配置' : '去配置' }}
  159. </a>
  160. <a href="{php echo url('profile/payment/switch', array('type' => 'jueqiymf'))}" ng-if="paysetting.jueqiymf.has_config === true">支付支持</a>
  161. </div>
  162. </td>
  163. </tr>
  164. <tr>
  165. <td>
  166. 银联支付
  167. </td>
  168. <td>
  169. <div class="related-info">
  170. </div>
  171. </td>
  172. <td >
  173. {{ paysetting.unionpay.has_config === true ? '已配置' : '未配置' }}
  174. </td>
  175. <td>
  176. {{ paysetting.unionpay.support_set === true ? '未设置' : '已设置' }}
  177. </td>
  178. <td class="text-center">
  179. <div class="link-group">
  180. <a href="javascript:;" data-toggle="modal" data-target="#yinlian">
  181. {{ paysetting.unionpay.has_config === true ? '修改配置' : '去配置' }}
  182. </a>
  183. <a href="{php echo url('profile/payment/switch', array('type' => 'unionpay'))}" ng-if="paysetting.unionpay.has_config === true">支付支持</a>
  184. </div>
  185. </td>
  186. </tr>
  187. <tr>
  188. <td >
  189. 百度钱包支付
  190. </td>
  191. <td>
  192. <div class="related-info"></div>
  193. </td>
  194. <td >
  195. {{ paysetting.baifubao.has_config === true ? '已配置' : '未配置' }}
  196. </td>
  197. <td>
  198. {{ paysetting.baifubao.support_set === true ? '未设置' : '已设置' }}
  199. </td>
  200. <td class="text-center">
  201. <div class="link-group">
  202. <a href="javascript:;" data-toggle="modal" data-target="#baidu">
  203. {{ paysetting.baifubao.has_config === true ? '修改配置' : '去配置' }}
  204. </a>
  205. <a href="{php echo url('profile/payment/switch', array('type' => 'baifubao'))}" ng-if="paysetting.baifubao.has_config === true">支付支持</a>
  206. </div>
  207. </td>
  208. </tr>
  209. <tr>
  210. <td >
  211. 汇款支付
  212. </td>
  213. <td>
  214. <div class="related-info"></div>
  215. </td>
  216. <td>
  217. {{ paysetting.line.has_config === true ? '已配置' : '未配置' }}
  218. </td>
  219. <td>
  220. {{ paysetting.line.support_set === true ? '未设置' : '已设置' }}
  221. </td>
  222. <td class="text-center">
  223. <div class="link-group">
  224. <a href="javascript:;" data-toggle="modal" data-target="#huikuan">
  225. {{ paysetting.line.has_config === true ? '修改配置' : '去配置' }}
  226. </a>
  227. <a href="{php echo url('profile/payment/switch', array('type' => 'line'))}" ng-if="paysetting.line.has_config === true">支付支持</a>
  228. </div>
  229. </td>
  230. </tr>
  231. </table>
  232. <!--支付宝修改-->
  233. <div class="modal fade" id="zhifubao" tabindex="-1" role="dialog" aria-hidden="true">
  234. <div class="we7-modal-dialog modal-dialog">
  235. <div class="modal-content">
  236. <div class="modal-header">
  237. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  238. <div class="modal-title">支付宝支付</div>
  239. </div>
  240. <div class="modal-body">
  241. <div class="we7-form">
  242. <div class="form-group">
  243. <label for="" class="control-label col-sm-2">支付宝无线支付</label>
  244. <div class="form-controls col-sm-10">
  245. <div class="alert alert-warning">
  246. 您的支付宝账号必须支持手机网页即时到账接口, 才能使用手机支付功能,
  247. <a href="https://b.alipay.com/order/productDetail.htm?productId=2013080604609688" target="_blank" class="color-default">申请及详情请查看这里</a>.
  248. </div>
  249. </div>
  250. </div>
  251. <div class="form-group">
  252. <label for="" class="control-label col-sm-2">收款支付宝账号</label>
  253. <div class="form-controls col-sm-10">
  254. <div class="input-group">
  255. <input type="text" name="" class="form-control" placeholder="" ng-model="paysetting.alipay.account">
  256. <a herf="#" ng-click="aliaccounthelp = !aliaccounthelp" class="input-group-addon"><i class="fa fa-exclamation-circle"></i></a>
  257. </div>
  258. <span class="help-block" ng-show="aliaccounthelp">
  259. 如果开启兑换或交易功能,请填写真实有效的支付宝账号,用于收取用户以现金兑换交易积分的相关款项。如账号无效或安全码有误,将导致用户支付后无法正确对其积分账户自动充值,或进行正常的交易对其积分账户自动充值,或进行正常的交易。 如您没有支付宝帐号,
  260. <a href="https://memberprod.alipay.com/account/reg/enterpriseIndex.htm" target="_blank">请点击这里注册</a>
  261. </span>
  262. </div>
  263. </div>
  264. <div class="form-group">
  265. <label for="" class="control-label col-sm-2">合作者身份</label>
  266. <div class="form-controls col-sm-10">
  267. <div class="input-group">
  268. <input type="text" name="" class="form-control" placeholder="" ng-model="paysetting.alipay.partner">
  269. <a herf="#" ng-click="alipartnerhelp = !alipartnerhelp" class="input-group-addon"><i class="fa fa-exclamation-circle"></i></a>
  270. </div>
  271. <span class="help-block" ng-show="alipartnerhelp">
  272. 支付宝签约用户请在此处填写支付宝分配给您的合作者身份,签约用户的手续费按照您与支付宝官方的签约协议为准。
  273. <br>如果您还未签约,
  274. <a href="https://memberprod.alipay.com/account/reg/enterpriseIndex.htm" target="_blank">
  275. 请点击这里签约
  276. </a>;
  277. 如果已签约,
  278. <a href="https://b.alipay.com/order/pidKey.htm?pid=2088501719138773&amp;product=fastpay" target="_blank">
  279. 请点击这里获取PID、Key
  280. </a>;
  281. 如果在签约时出现合同模板冲突,请咨询0571-88158090
  282. </span>
  283. </div>
  284. </div>
  285. <div class="form-group">
  286. <label for="" class="control-label col-sm-2">校验密钥</label>
  287. <div class="form-controls col-sm-10">
  288. <div class="input-group">
  289. <input type="text" name="" class="form-control" placeholder="" ng-model="paysetting.alipay.secret">
  290. <a herf="#" ng-click="alisecrethelp = !alisecrethelp" class="input-group-addon"><i class="fa fa-exclamation-circle"></i></a>
  291. </div>
  292. <span class="help-block" ng-show="alisecrethelp">支付宝签约用户可以在此处填写支付宝分配给您的交易安全校验码,此校验码您可以到支付宝官方的商家服务功能处查看 </span>
  293. </div>
  294. </div>
  295. <div class="form-group">
  296. <label for="" class="control-label col-sm-2">模拟测试</label>
  297. <div class="form-controls col-sm-10">
  298. <a href="javascript:;" class="form-control-static color-default" ng-click="test_alipay()">模拟测试</a>
  299. <span class="help-block">本测试将模拟提交 0.01 元人民币的订单进行测试,如果提交后成功出现付款界面,说明您站点的支付宝功能可以正常使用</span>
  300. </div>
  301. </div>
  302. </div>
  303. </div>
  304. <div class="modal-footer">
  305. <button type="button" class="btn btn-primary" ng-click="saveEdit('alipay')">确定</button>
  306. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  307. </div>
  308. </div>
  309. </div>
  310. </div>
  311. <!-- 微信修改 -->
  312. <div class="modal fade" id="weixin" tabindex="-1" role="dialog" aria-hidden="true">
  313. <div class="we7-modal-dialog modal-dialog">
  314. <div class="modal-content">
  315. <div class="modal-header">
  316. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  317. <div class="modal-title">微信支付</div>
  318. </div>
  319. <div class="modal-body">
  320. <div class="we7-form">
  321. <div class="form-group">
  322. <label for="" class="control-label col-sm-2">微信支付</label>
  323. <div class="form-controls col-sm-10">
  324. <div class="alert alert-warning">
  325. 你必须向微信公众平台提交企业信息以及银行账户资料,审核通过并签约后才能使用微信支付功能,
  326. <a href="https://pay.weixin.qq.com/guide/webbased_payment.shtml" class="color-default" target="_blank">申请及详情请查看这里</a>
  327. </div>
  328. <div class="alert alert-warning">
  329. <p>微信支付的接口说明如下:</p>
  330. <br>
  331. <h4>JS API网页支付参数</h4>
  332. <p>支付授权目录: {$_W['siteroot']}payment/wechat/ 和 {$_W['siteroot']}app/</p>
  333. <p>支付请求实例: {$_W['siteroot']}payment/wechat/pay.php</p>
  334. <p>共享收货地址: 选择"是"</p>
  335. <br>
  336. <h4>Native原生支付</h4>
  337. <p>支付回调URL: {$_W['siteroot']}payment/wechat/native.php</p>
  338. <p>维权通知URL: {$_W['siteroot']}payment/wechat/rights.php</p>
  339. <p>警告通知URL: {$_W['siteroot']}payment/wechat/warning.php</p>
  340. </div>
  341. {if $accounts[$_W['acid']]['level'] > ACCOUNT_SERVICE}
  342. {if $accounts[$_W['acid']]['level'] == ACCOUNT_SERVICE_VERIFY}
  343. <input id='radio-11' type="radio" name='wechat[switch]' ng-checked='paysetting.wechat.switch == 1' ng-click="changeSwitch('wechat', 1)" value="1"/>
  344. <label for="radio-11">微信支付 </label>
  345. {/if}
  346. {if !empty($proxy_wechatpay_account['borrow'])}
  347. <input id='radio-12' type="radio" name='wechat[switch]' ng-checked='paysetting.wechat.switch == 2' ng-click="changeSwitch('wechat', 2)" value="2"/>
  348. <label for="radio-12">借用支付 </label>
  349. {/if}
  350. {if !empty($proxy_wechatpay_account['service'])}
  351. <input id='radio-13' type="radio" name='wechat[switch]' ng-checked='paysetting.wechat.switch == 3' ng-click="changeSwitch('wechat', 3)" value="3"/>
  352. <label for="radio-13">服务商支付 </label>
  353. {/if}
  354. {/if}
  355. <!-- <input id='radio-24' type="radio" name='wechat[switch]' ng-checked='paysetting.wechat.switch == 4 || paysetting.wechat.switch === false' ng-click="changeSwitch('wechat', 4)" value="4" checked=""/>
  356. <label for="radio-24">关闭 </label> -->
  357. </div>
  358. </div>
  359. {if $accounts[$_W['acid']]['level'] > ACCOUNT_SERVICE}
  360. {if $accounts[$_W['acid']]['level'] == ACCOUNT_SERVICE_VERIFY}
  361. <div ng-show="paysetting.wechat.switch == 1">
  362. <div class="form-group">
  363. <label for="" class="control-label col-sm-2">接口类型</label>
  364. <div class="form-controls col-sm-10">
  365. <input id='radio-15' type="radio" name='paysetting[wechat][version]' ng-checked='paysetting.wechat.version == 1' value="1" ng-click="changeVersion(1)"/>
  366. <label for="radio-15">旧版 </label>
  367. <input id='radio-25' type="radio" name='paysetting[wechat][version]' ng-checked='paysetting.wechat.version == 2' value="2" ng-click="changeVersion(2)"/>
  368. <label for="radio-25">新版(2014年9月之后申请的) </label>
  369. <span class="help-block">由于微信支付接口调整,需要根据申请时间来区分支付接口</span>
  370. </div>
  371. </div>
  372. <div class="form-group">
  373. <label for="" class="control-label col-sm-2">支付账号</label>
  374. <div class="form-controls col-sm-10">
  375. <a href="" class="form-control-static color-default">{$_W['account']['name']}</a>
  376. </div>
  377. </div>
  378. <div class="form-group">
  379. <label for="" class="control-label col-sm-2">身份标识<br>(appId)</label>
  380. <div class="form-controls col-sm-10">
  381. <input type="text" name="" disabled class="form-control" value="{$_W['account']['key']}" placeholder="">
  382. <span class="help-block">
  383. 公众号身份标识
  384. <a href="./index.php?c=account&amp;a=post&amp;uniacid=2">
  385. 请通过修改公众号信息来保存
  386. </a>
  387. </span>
  388. </div>
  389. </div>
  390. <div class="form-group">
  391. <label for="" class="control-label col-sm-2">身份密钥<br>(appSecret)</label>
  392. <div class="form-controls col-sm-10">
  393. <input type="text" disabled value="{$_W['account']['secret']}" name="" class="form-control" placeholder="">
  394. <span class="help-block">公众平台API(参考文档API 接口部分)的权限获取所需密钥Key
  395. <a href="./index.php?c=account&amp;a=post&amp;uniacid=2">
  396. 请通过修改公众号信息来保存
  397. </a>
  398. </span>
  399. </div>
  400. </div>
  401. <div ng-show="paysetting.wechat.version == 1">
  402. <div class="form-group">
  403. <label for="" class="control-label col-sm-2">商户身份</label>
  404. <div class="form-controls col-sm-10">
  405. <input type="text" class="form-control" ng-model="paysetting.wechat.partner" placeholder="">
  406. <span class="help-block">
  407. 财付通商户身份标识
  408. <br>
  409. 公众号支付请求中用于加密的密钥Key
  410. </span>
  411. </div>
  412. </div>
  413. <div class="form-group">
  414. <label for="" class="control-label col-sm-2">商户密钥</label>
  415. <div class="form-controls col-sm-10">
  416. <input type="text" name="" ng-model="paysetting.wechat.key" class="form-control" placeholder="">
  417. <span class="help-block">
  418. 财付通商户权限密钥
  419. </span>
  420. </div>
  421. </div>
  422. <div class="form-group">
  423. <label for="" class="control-label col-sm-2">通信秘钥</label>
  424. <div class="form-controls col-sm-10">
  425. <input type="text" name="" ng-model="paysetting.wechat.signkey" class="form-control" placeholder="">
  426. <span class="help-block">
  427. 财付通商户权限密钥
  428. </span>
  429. </div>
  430. </div>
  431. </div>
  432. <div ng-show="paysetting.wechat.version == 2">
  433. <div class="form-group">
  434. <label for="" class="control-label col-sm-2">微信支付商户号</label>
  435. <div class="form-controls col-sm-10">
  436. <input type="text" name="" ng-model="paysetting.wechat.mchid" class="form-control" placeholder="">
  437. <span class="help-block">
  438. 财付通商户权限密钥
  439. </span>
  440. </div>
  441. </div>
  442. <div class="form-group">
  443. <label for="" class="control-label col-sm-2">微信支付秘钥</label>
  444. <div class="form-controls col-sm-10">
  445. <div class="input-group">
  446. <input type="text" name="" ng-model="paysetting.wechat.apikey" class="form-control" placeholder="">
  447. <a href="javascript:;" class="input-group-addon" ng-click="tokenGen('wechat.apikey')">生成新的秘钥</a>
  448. </div>
  449. <span class="help-block">
  450. 财付通商户权限密钥
  451. </span>
  452. </div>
  453. </div>
  454. </div>
  455. </div>
  456. {/if}
  457. {if !empty($proxy_wechatpay_account['borrow'])}
  458. <div ng-show="paysetting.wechat.switch == 2">
  459. <div class="form-group">
  460. <label for="" class="control-label col-sm-2">借用公众号</label>
  461. <div class="form-controls col-sm-10">
  462. <select name="borrow" class="we7-select" ng-model="paysetting.wechat.borrow">
  463. <option value="" ng-selected="paysetting.wechat.borrow == 0 || paysetting.wechat.borrow == '' || paysetting.wechat.borrow == undefined">请选择要借用的公众号</option>
  464. <option value="{{key}}" ng-selected="paysetting.wechat.borrow == key" ng-repeat="(key, account) in config.borrows track by key">{{ account }}</option>
  465. </select>
  466. <span class="help-block">借用认证服务号支付权限完成支付。</span>
  467. </div>
  468. </div>
  469. </div>
  470. {/if}
  471. {if !empty($proxy_wechatpay_account['service'])}
  472. <div ng-show="paysetting.wechat.switch == 3">
  473. <div class="form-group">
  474. <label for="" class="control-label col-sm-2">服务商公众号</label>
  475. <div class="form-controls col-sm-10">
  476. <select name="service" class="we7-select" ng-model="paysetting.wechat.service">
  477. <option value="">请选择服务商公众号</option>
  478. <option value="{{key}}" ng-selected="paysetting.wechat.service == key" ng-repeat="(key, account) in config.services track by key">{{ account }}</option>
  479. </select>
  480. <span class="help-block">借用认证服务号支付权限完成支付。</span>
  481. </div>
  482. </div>
  483. <div class="form-group">
  484. <label for="" class="control-label col-sm-2">子商户号</label>
  485. <div class="form-controls col-sm-10">
  486. <input type="text" name="" ng-model="paysetting.wechat.sub_mch_id" class="form-control" placeholder="">
  487. <span class="help-block">
  488. 子商户的商户号
  489. </span>
  490. </div>
  491. </div>
  492. </div>
  493. {/if}
  494. {/if}
  495. </div>
  496. </div>
  497. <div class="modal-footer">
  498. <button type="button" class="btn btn-primary" ng-click='saveEdit("wechat")'>确定</button>
  499. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  500. </div>
  501. </div>
  502. </div>
  503. </div>
  504. <div class="modal fade" id="wechat_fa" tabindex="-1" role="dialog" aria-hidden="true">
  505. <div class="we7-modal-dialog modal-dialog">
  506. <div class="modal-content">
  507. <div class="modal-header">
  508. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  509. <div class="modal-title">服务商支付</div>
  510. </div>
  511. <div class="modal-body">
  512. <div class="we7-form">
  513. <div class="form-group">
  514. <label for="" class="control-label col-sm-2">服务商支付</label>
  515. <div class="form-controls col-sm-10">
  516. <input id='radio-111' type="radio" name='wechat_facilitator' value="true" ng-checked="paysetting.wechat_facilitator.switch === true" ng-click="changeSwitch('wechat_facilitator', true)"/>
  517. <label for="radio-111">开启 </label>
  518. <input id='radio-222' type="radio" name='wechat_facilitator' value="false" ng-checked="paysetting.wechat_facilitator.switch === false" ng-click="changeSwitch('wechat_facilitator', false)"/>
  519. <label for="radio-222">关闭 </label>
  520. <span class="help-block">设置为服务商,其他商户可以授权给服务商,让服务商完成支付。</span>
  521. </div>
  522. </div>
  523. <div class="form-group">
  524. <label for="" class="control-label col-sm-2">服务商商户号</label>
  525. <div class="form-controls col-sm-10">
  526. <input name="" ng-model="paysetting.wechat_facilitator.mchid" class="form-control" placeholder="" >
  527. <span class="help-block">需要填写申请为服务商的商户号。注:服务商的商户号与微信支付的商户号不是同一个号。</span>
  528. </div>
  529. </div>
  530. <div class="form-group">
  531. <label for="" class="control-label col-sm-2">商户支付密钥</label>
  532. <div class="form-controls col-sm-10">
  533. <input type="text" name="" ng-model="paysetting.wechat_facilitator.signkey" class="form-control" placeholder="">
  534. <span class="help-block">此商户秘钥为服务商商户号对应的支付秘钥,与微信支付的支付秘钥不相同。</span>
  535. </div>
  536. </div>
  537. </div>
  538. </div>
  539. <div class="modal-footer">
  540. <button type="button" class="btn btn-primary" ng-click="saveEdit('wechat_facilitator')">确定</button>
  541. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  542. </div>
  543. </div>
  544. </div>
  545. </div>
  546. <!--银联支付-->
  547. <div class="modal fade" id="yinlian" tabindex="-1" role="dialog" aria-hidden="true">
  548. <div class="we7-modal-dialog modal-dialog">
  549. <form action="{php echo url('profile/payment/save_setting', array('type' => 'unionpay'))}" enctype="multipart/form-data" method="post" id="form1" >
  550. <div class="modal-content">
  551. <div class="modal-header">
  552. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  553. <div class="modal-title">银联支付</div>
  554. </div>
  555. <div class="modal-body">
  556. <div class="we7-form">
  557. <div class="form-group">
  558. <label for="" class="control-label col-sm-2">商户私钥证书(签名)</label>
  559. <div class="form-controls col-sm-10">
  560. <input type="file" name="unionpay[signcertpath]" id="amend" {if $pay_setting['unionpay']['signcertexists'] !== false}style="display:none;"{/if} class="form-control" placeholder="">
  561. <span {if $pay_setting['unionpay']['signcertexists'] === false}style="display:none;"{/if}>证书已上传<input type="button" class="btn btn-success" onclick="amend.click()" value="修改"></span>
  562. </div>
  563. </div>
  564. <div class="form-group">
  565. <label for="" class="control-label col-sm-2">商户号</label>
  566. <div class="form-controls col-sm-10">
  567. <input type="text" name="unionpay[merid]" value="{$pay_setting['unionpay']['merid']}" class="form-control" placeholder="">
  568. </div>
  569. </div>
  570. <div class="form-group">
  571. <label for="" class="control-label col-sm-2">商户私钥证书密码</label>
  572. <div class="form-controls col-sm-10">
  573. <input type="text" name="unionpay[signcertpwd]" value="{$pay_setting['unionpay']['signcertpwd']}" class="form-control" placeholder="">
  574. </div>
  575. </div>
  576. </div>
  577. </div>
  578. <div class="modal-footer">
  579. <button type="submit" class="btn btn-primary">确定</button>
  580. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  581. </div>
  582. </div>
  583. </form>
  584. </div>
  585. </div>
  586. <div class="modal fade" id="jueqiymf" tabindex="-1" role="dialog" aria-hidden="true">
  587. <div class="we7-modal-dialog modal-dialog">
  588. <div class="modal-content">
  589. <div class="modal-header">
  590. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  591. <div class="modal-title">一码付</div>
  592. </div>
  593. <div class="modal-body">
  594. <div class="we7-form">
  595. <div class="form-group">
  596. <label for="" class="control-label col-sm-2">一码付后台地址</label>
  597. <div class="form-controls col-sm-10">
  598. <input type="text"ng-model="paysetting.jueqiymf.url" name="" class="form-control" placeholder="">
  599. </div>
  600. </div>
  601. <div class="form-group">
  602. <label for="" class="control-label col-sm-2">商户号</label>
  603. <div class="form-controls col-sm-10">
  604. <input type="text"ng-model="paysetting.jueqiymf.mchid" name="" class="form-control" placeholder="">
  605. </div>
  606. </div>
  607. </div>
  608. </div>
  609. <div class="modal-footer">
  610. <button type="button" class="btn btn-primary" ng-click="saveEdit('jueqiymf')">确定</button>
  611. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  612. </div>
  613. </div>
  614. </div>
  615. </div>
  616. <!--百度钱包-->
  617. <div class="modal fade" id="baidu" tabindex="-1" role="dialog" aria-hidden="true">
  618. <div class="we7-modal-dialog modal-dialog">
  619. <div class="modal-content">
  620. <div class="modal-header">
  621. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  622. <div class="modal-title">百度钱包</div>
  623. </div>
  624. <div class="modal-body">
  625. <div class="we7-form">
  626. <div class="form-group">
  627. <label for="" class="control-label col-sm-2">商户号</label>
  628. <div class="form-controls col-sm-10">
  629. <input type="text"ng-model="paysetting.baifubao.mchid" name="" class="form-control" placeholder="">
  630. </div>
  631. </div>
  632. <div class="form-group">
  633. <label for="" class="control-label col-sm-2">商户支付密钥</label>
  634. <div class="form-controls col-sm-10">
  635. <input type="text" name="" ng-model="paysetting.baifubao.signkey" class="form-control" placeholder="">
  636. </div>
  637. </div>
  638. </div>
  639. </div>
  640. <div class="modal-footer">
  641. <button type="button" class="btn btn-primary" ng-click="saveEdit('baifubao')">确定</button>
  642. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  643. </div>
  644. </div>
  645. </div>
  646. </div>
  647. <!--汇款-->
  648. <div class="modal fade" id="huikuan" tabindex="-1" role="dialog" aria-hidden="true">
  649. <div class="we7-modal-dialog modal-dialog">
  650. <div class="modal-content">
  651. <div class="modal-header">
  652. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  653. <div class="modal-title">汇款支付</div>
  654. </div>
  655. <div class="modal-body">
  656. <div class="we7-form">
  657. <div class="form-group">
  658. <label for="" class="control-label col-sm-2">账户信息</label>
  659. <div class="form-controls col-sm-10">
  660. <input type="text" id="" name="" ng-model="paysetting.line.message" class="form-control" placeholder="">
  661. </div>
  662. </div>
  663. </div>
  664. </div>
  665. <div class="modal-footer">
  666. <button type="button" class="btn btn-primary" ng-click="saveEdit('line')">确定</button>
  667. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  668. </div>
  669. </div>
  670. </div>
  671. </div>
  672. </div>
  673. {/if}
  674. {if $do == 'switch'}
  675. <ol class="breadcrumb we7-breadcrumb">
  676. <a href="{url 'profile/payment'}"><i class="wi wi-back-circle"></i> </a>
  677. <li>
  678. <a href="{url 'profile/payment'}">支付配置</a>
  679. </li>
  680. <li>
  681. <a href="javascript:;">支付支持</a></li>
  682. </li>
  683. </ol>
  684. <div class="js-profile-payment" ng-controller="paymentCtrl" ng-cloak>
  685. <table class="table we7-table table-hover table-form">
  686. <col width="140px " />
  687. <col width="400px"/>
  688. <col />
  689. <col width="140px" />
  690. <tr>
  691. <th colspan="5" >支付方式设置({$payment_types[$_GPC['type']]})</th>
  692. <th colspan="1" >操作</th>
  693. </tr>
  694. <tr>
  695. <td colspan="2">
  696. 充值
  697. </td>
  698. <td colspan="2">
  699. <label>
  700. <input name="" class="form-control" type="checkbox" style="display: none;" ng-click="switchStatus(config.paytype, 'recharge_switch')" ng-if="paysetting[config.paytype].recharge_set === true">
  701. <input name="" class="form-control" type="checkbox" style="display: none;" ng-else>
  702. <div ng-class="paysetting[config.paytype].recharge_switch === true || paysetting[config.paytype].recharge_switch === 'true' ? 'switch switchOn' : 'switch'"></div>
  703. </label>
  704. </td>
  705. <td colspan="2" ng-if="paysetting[config.paytype].recharge_set !== true">不可启用</td>
  706. <td colspan="2" ng-if="paysetting[config.paytype].recharge_set === true"></td>
  707. </tr>
  708. <tr>
  709. <td colspan="2">
  710. 支付
  711. </td>
  712. <td colspan="2">
  713. <label>
  714. <input name="" class="form-control" type="checkbox" style="display: none;" ng-click="switchStatus(config.paytype, 'pay_switch')">
  715. <div ng-class="paysetting[config.paytype].pay_switch === true || paysetting[config.paytype].pay_switch === 'true' ? 'switch switchOn' : 'switch'"></div>
  716. </label>
  717. </td>
  718. <td colspan="2"></td>
  719. </tr>
  720. </table>
  721. </div>
  722. {/if}
  723. <script>
  724. angular.module('profileApp').value('config', {
  725. 'paysetting' : {php echo json_encode($pay_setting)},
  726. 'paytype' : "{$_GPC['type']}",
  727. 'saveurl' : "{php echo url('profile/payment/save_setting')}",
  728. 'text_alipay_url' : "{php echo url('profile/payment/test_alipay')}",
  729. 'borrows' : {php echo json_encode($proxy_wechatpay_account['borrow'])},
  730. 'change_status': "{php echo url('profile/payment/change_status')}",
  731. 'services' : {php echo json_encode($proxy_wechatpay_account['service'])},
  732. 'get_setting_url' : "{php echo url('profile/payment/get_setting')}",
  733. 'account_level' : "{$accounts[$_W['acid']]['level']}"
  734. });
  735. angular.bootstrap($('.js-profile-payment'), ['profileApp']);
  736. </script>
  737. {template 'common/footer'}