增加後台圖檔旋轉功能。加強報名地址檢查。修正前台文字。增加前後台報名欄位。設定報名欄位TWID為UNIQUE。修正前台報名可以連續送出的問題。
This commit is contained in:
@ -54,6 +54,11 @@ class ImprovedHealthFillFormController extends Controller
|
||||
} else {
|
||||
$enable = false;
|
||||
}
|
||||
|
||||
$passCount = EventImprovedHealth::where('check_state', 2)->count();
|
||||
if ($passCount >= $eventInfo['limit']) {
|
||||
$enable = false;
|
||||
}
|
||||
}
|
||||
|
||||
return view('improved_health', [
|
||||
@ -96,6 +101,10 @@ class ImprovedHealthFillFormController extends Controller
|
||||
} else {
|
||||
throw new \Exception('活動已截止。');
|
||||
}
|
||||
$passCount = EventImprovedHealth::where('check_state', 2)->count();
|
||||
if ($passCount >= $eventInfo['limit']) {
|
||||
throw new \Exception('活動已截止。');
|
||||
}
|
||||
}
|
||||
|
||||
DB::beginTransaction();
|
||||
@ -116,6 +125,7 @@ class ImprovedHealthFillFormController extends Controller
|
||||
if ($eventItem->check_state == 2) {
|
||||
throw new \Exception('您已經登記審查通過。');
|
||||
}
|
||||
$eventItem->disease_type = $request->input('disease_type');
|
||||
$eventItem->hospital_name = $request->input('hospital_name');
|
||||
$eventItem->name = $request->input('name');
|
||||
$eventItem->phone = $request->input('phone');
|
||||
|
Reference in New Issue
Block a user