发起桌台,以及待支付订单支付
<p>[TOC]</p>
<h5>简要描述</h5>
<ul>
<li>发起桌台,以及待支付订单支付接口</li>
</ul>
<h5>请求URL</h5>
<ul>
<li><code>https://food.taihuyun.vip/api/foodcash.order/payBytable?applet_id=1&shop_id=1&token=8014374705939b271a346001006d8aa5</code></li>
</ul>
<h5>请求方式</h5>
<ul>
<li>POST</li>
</ul>
<h5>参数</h5>
<table>
<thead>
<tr>
<th style="text-align: left;">参数名</th>
<th style="text-align: left;">必选</th>
<th style="text-align: left;">类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align: left;">applet_id</td>
<td style="text-align: left;">是</td>
<td style="text-align: left;">string</td>
<td>应用程序ID</td>
</tr>
<tr>
<td style="text-align: left;">shop_id</td>
<td style="text-align: left;">是</td>
<td style="text-align: left;">string</td>
<td>门店ID</td>
</tr>
<tr>
<td style="text-align: left;">token</td>
<td style="text-align: left;">是</td>
<td style="text-align: left;">string</td>
<td>用户身份验证的令牌</td>
</tr>
</tbody>
</table>
<h5>返回示例</h5>
<ul>
<li>一卡通实体卡支付</li>
</ul>
<pre><code>curl --location --request POST 'https://food.taihuyun.vip/api/foodcash.order/payBytable?applet_id=1&shop_id=1&token=8014374705939b271a346001006d8aa5' \
--data-raw '{
"pay_mode":9,
"order_ids":"1141",
"pay_price":90,
"card_id":"",
"card_no":"666666",
"card_open_id":"R4r316_WymxGqSuMU7Dgcw",
"password":"123456",
"card_pay_mode":"0",
"card_pay_wallet":"0",
"card_combo_wallets":"[]",
"card_combo_amounts":"[]"
}'</code></pre>
<ul>
<li>扫码支付</li>
</ul>
<pre><code>curl --location --request POST 'https://food.taihuyun.vip/api/foodcash.order/payBytable?applet_id=1&shop_id=1&token=8014374705939b271a346001006d8aa5' \
--data-raw '{
"pay_mode":8,
"order_ids":"1141",
"pay_price":90,
"card_id":"1673086349532169355",
"card_no":"666666",
"card_open_id":"R4r316_WymxGqSuMU7Dgcw",
"password":"123456",
"card_pay_mode":"0",
"card_pay_wallet":"0",
"card_combo_wallets":[],
"card_combo_amounts":[]
}'
</code></pre>
<h5>返回参数</h5>
<ul>
<li>返回状态代码: 200</li>
</ul>
<pre><code>{
"code": 1,
"msg": "success",
"data": {
"transaction_id": "ceskbbm56qv8v5htthn0",
"need_code": false
}
}</code></pre>
<table>
<thead>
<tr>
<th style="text-align: left;">参数名</th>
<th style="text-align: left;">类型</th>
<th>说明</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align: left;">transaction_id</td>
<td style="text-align: left;">string</td>
<td>交易编号</td>
</tr>
<tr>
<td style="text-align: left;">pay_mode</td>
<td style="text-align: left;">int</td>
<td>支付途径</td>
</tr>
<tr>
<td style="text-align: left;">pay_price</td>
<td style="text-align: left;">int</td>
<td>支付金额</td>
</tr>
<tr>
<td style="text-align: left;">card_id</td>
<td style="text-align: left;">string</td>
<td>卡ID</td>
</tr>
<tr>
<td style="text-align: left;">card_no</td>
<td style="text-align: left;">string</td>
<td>卡号</td>
</tr>
<tr>
<td style="text-align: left;">password</td>
<td style="text-align: left;">string</td>
<td>密码</td>
</tr>
</tbody>
</table>
<h5>备注</h5>
<ul>
<li>
<p>支付途径:
0:微信,
1:余额(目前不用)
2:后付
3:现金
小程序端:6:一卡通 小程序
pc端:8 一卡通扫码,9:一卡通实体卡
支付宝:11
银联: 21
单位挂单:50
房间挂单:51</p>
</li>
<li>更多返回错误代码请看基本参数中的参数说明</li>
</ul>