作者 开飞机的舒克

接口优化

... ... @@ -137,7 +137,7 @@ class Bind extends Api
/**
* @ApiTitle (活动现场[扫码])
* @ApiMethod (POST)
* @ApiParams (name="items_id", type="string", required=true, description="项目id")
* @ApiParams (name="id", type="string", required=true, description="项目id")
* @ApiParams (name="unique", type="string", required=true, description="条形码唯一标识")
* @ApiReturn ({
"code":"状态码",
... ... @@ -148,7 +148,7 @@ class Bind extends Api
}
})
*/
public function Ewm()
public function scanBarCode()
{
$id = $this->request->param('id');
$unique = $this->request->param('unique');
... ... @@ -168,7 +168,7 @@ class Bind extends Api
'study_id' => $study['id'],
'team_id' => $study['team_id'],
'score' => $item['score'],
'memo' => $study['name'] . '参加' . $item['title'] . '项目给' . $team['title'] . '加分',
'memo' => $study['name'] . '参加' . $item['title'] . '加分',
'createtime' => time()
]);
db('study')
... ...
... ... @@ -3133,7 +3133,7 @@
<div class="panel-heading" id="heading-9">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion9" href="#collapseOne9"> 活动现场[扫码] <span class="text-muted">/api/bind/Ewm</span></a>
<a data-toggle="collapse" data-parent="#accordion9" href="#collapseOne9"> 活动现场[扫码] <span class="text-muted">/api/bind/scanBarCode</span></a>
</h4>
</div>
<div id="collapseOne9" class="panel-collapse collapse">
... ... @@ -3189,7 +3189,7 @@
</thead>
<tbody>
<tr>
<td>items_id</td>
<td>id</td>
<td>string</td>
<td></td>
<td>项目id</td>
... ... @@ -3221,10 +3221,10 @@
</div>
</div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/bind/Ewm" method="POST" name="form9" id="form9">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/bind/scanBarCode" method="POST" name="form9" id="form9">
<div class="form-group">
<label class="control-label" for="items_id">items_id</label>
<input type="string" class="form-control input-sm" id="items_id" required placeholder="项目id" name="items_id">
<label class="control-label" for="id">id</label>
<input type="string" class="form-control input-sm" id="id" required placeholder="项目id" name="id">
</div>
<div class="form-group">
<label class="control-label" for="unique">unique</label>
... ... @@ -5200,7 +5200,7 @@
</div>
<div class="col-md-6" align="right">
Generated on 2023-03-17 14:41:33 <a href="./" target="_blank">校园活动</a>
Generated on 2023-03-17 14:45:40 <a href="./" target="_blank">校园活动</a>
</div>
</div>
... ...