From b164c5b409665f1130d67a841f679b07fa1f5b6d Mon Sep 17 00:00:00 2001 From: yangsh Date: Mon, 12 Jan 2026 15:53:12 +0900 Subject: [PATCH] =?UTF-8?q?=EB=B2=84=ED=8A=BC=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/Config/Routes.php | 2 + app/Controllers/V2/M710.php | 23 +++++++++ app/Models/v2/M710Model.php | 19 +++++++ app/Views/pages/v2/m710/lists.php | 86 +++++++++++++++++++++++++++++++ 4 files changed, 130 insertions(+) diff --git a/app/Config/Routes.php b/app/Config/Routes.php index 4abad03..c8e9b19 100644 --- a/app/Config/Routes.php +++ b/app/Config/Routes.php @@ -231,6 +231,8 @@ $routes->group('', ['namespace' => 'App\Controllers\V2'], static function ($rout * 모바일 추가 서류 - API */ $routes->get('m710a/getResultList', 'M710::getResultList'); + $routes->get('m710a/excel', 'M710::excel'); + $routes->get('m710a/sendApi', 'M710::sendApi'); // 전송요청 api 저장 }); diff --git a/app/Controllers/V2/M710.php b/app/Controllers/V2/M710.php index 2420e9b..7429419 100644 --- a/app/Controllers/V2/M710.php +++ b/app/Controllers/V2/M710.php @@ -109,4 +109,27 @@ class M710 extends BaseController $e->getPrevious()->getTraceAsString(); } } + + + // 전송 api + public function sendApi() + { + try { + + $type = $this->request->getPost('type'); + + $this->model->updateSendApi($type); + + return $this->response->setJSON([ + 'code' => '0', + 'msg' => 'success', + ]); + + } catch (\Exception $e) { + return $this->response->setJSON([ + 'code' => '9', + 'msg' => $e->getMessage(), + ]); + } + } } \ No newline at end of file diff --git a/app/Models/v2/M710Model.php b/app/Models/v2/M710Model.php index 438e911..fd5e86e 100644 --- a/app/Models/v2/M710Model.php +++ b/app/Models/v2/M710Model.php @@ -671,6 +671,25 @@ class M710Model extends Model return $query->getResultArray(); } + // 전송요청 api 수정 + public function updateSendApi($type) + { + $sql = "UPDATE v2_stop_api_save_info SET status = 'wait' + WHERE type like CONCAT(?, '%') AND status = 'stop' + "; + + if ($this->db->query($sql, [$type]) === false) { + return [ + 'success' => false, + 'msg' => '저장 실패', + ]; + } + + return [ + 'success' => true, + ]; + } + public function insert_v2_stop_api_save_info($atcl_no, $vr_sq, $type, $fax_sq) { $sql = "INSERT INTO v2_stop_api_save_info(atcl_no,vr_sq,type,status,stop_dt,fax_sq)" . diff --git a/app/Views/pages/v2/m710/lists.php b/app/Views/pages/v2/m710/lists.php index af244d3..d76725c 100644 --- a/app/Views/pages/v2/m710/lists.php +++ b/app/Views/pages/v2/m710/lists.php @@ -248,6 +248,18 @@
+ + + +