From e5d3f0bb109d9c7a2f758b58c4cb249e657929fb Mon Sep 17 00:00:00 2001 From: "choi.jh" Date: Wed, 20 Aug 2025 11:19:44 +0900 Subject: [PATCH] dbmsv2 init...1 --- app/Config/Constants.php | 5 +- .../Admin/Equipment/PartController.php | 30 +- .../Admin/Equipment/ServerController.php | 2 +- app/Controllers/CLI/Payment.php | 2 +- app/Database/dbmsv2.vuerd.json | 1092 ++++++++++++++--- app/Database/dbmsv2_init.sql | 113 +- app/Entities/Customer/CustomerEntity.php | 2 +- app/Entities/Customer/PaymentEntity.php | 4 +- app/Helpers/CommonHelper.php | 2 +- app/Helpers/Customer/ClientHelper.php | 8 +- app/Helpers/Customer/PaymentHelper.php | 4 +- app/Helpers/Customer/ServiceHelper.php | 8 +- app/Helpers/Equipment/PartHelper.php | 14 + app/Language/en/Customer/Account.php | 2 +- app/Language/en/Customer/Coupon.php | 2 +- app/Language/en/Customer/Payment.php | 4 +- app/Language/en/Customer/Point.php | 2 +- app/Language/en/Customer/Service.php | 4 +- app/Language/en/Equipment/Ip.php | 4 +- app/Language/en/Equipment/Part.php | 23 + app/Language/en/Equipment/Server.php | 4 +- app/Models/Customer/AccountModel.php | 4 +- app/Models/Customer/ClientModel.php | 13 +- app/Models/Customer/CouponModel.php | 4 +- app/Models/Customer/PaymentModel.php | 8 +- app/Models/Customer/PointModel.php | 4 +- app/Models/Customer/ServiceModel.php | 24 +- app/Models/Equipment/CSModel.php | 10 +- app/Models/Equipment/IpModel.php | 8 +- app/Models/Equipment/PartModel.php | 9 +- app/Models/Equipment/ServerModel.php | 25 +- app/Models/Equipment/SwitchModel.php | 11 +- app/Services/CommonService.php | 2 +- app/Services/Customer/AccountService.php | 8 +- app/Services/Customer/CouponService.php | 8 +- app/Services/Customer/CustomerService.php | 6 +- app/Services/Customer/PaymentService.php | 20 +- app/Services/Customer/PointService.php | 8 +- app/Services/Customer/ServiceService.php | 11 +- app/Services/Equipment/CSService.php | 3 +- app/Services/Equipment/DomainService.php | 42 - app/Services/Equipment/EquipmentService.php | 6 +- app/Services/Equipment/IpService.php | 10 +- app/Services/Equipment/PartService.php | 44 +- app/Services/Equipment/ServerService.php | 6 +- app/Views/admin/welcome/new.php | 2 +- erp3.vuerd.json | 58 +- 47 files changed, 1271 insertions(+), 414 deletions(-) create mode 100644 app/Helpers/Equipment/PartHelper.php create mode 100644 app/Language/en/Equipment/Part.php delete mode 100644 app/Services/Equipment/DomainService.php diff --git a/app/Config/Constants.php b/app/Config/Constants.php index d255f00..ff0735b 100644 --- a/app/Config/Constants.php +++ b/app/Config/Constants.php @@ -384,7 +384,8 @@ define('SERVICE_UNPAID_ITEM_TYPE', $_ENV['SERVICE_UNPAID_ITEM_TYPE'] ?? $_SERVER define( 'SITE_PREFIX', [ - 'Client' => $_ENV['PREFIX_Client'] ?? $_SERVER['PREFIX_Client'] ?? 'C', - 'Service' => $_ENV['PREFIX_Service'] ?? $_SERVER['PREFIX_Service'] ?? 'S' + 'prime' => $_ENV['PREFIX_Client'] ?? $_SERVER['PREFIX_Client'] ?? 'PR', + 'itsolution' => $_ENV['PREFIX_Client'] ?? $_SERVER['PREFIX_Client'] ?? 'IT', + 'gdidc' => $_ENV['PREFIX_Client'] ?? $_SERVER['PREFIX_Client'] ?? 'GD', ], ); diff --git a/app/Controllers/Admin/Equipment/PartController.php b/app/Controllers/Admin/Equipment/PartController.php index ec25930..1c45123 100644 --- a/app/Controllers/Admin/Equipment/PartController.php +++ b/app/Controllers/Admin/Equipment/PartController.php @@ -1,18 +1,38 @@ content_title = lang("{$this->getService()->getClassName()}.title"); + $this->class_path .= $this->getService()->getClassName(); + $this->uri_path .= strtolower($this->getService()->getClassName('/')) . '/'; + // $this->view_path .= strtolower($this->getService()->getClassName()) . DIRECTORY_SEPARATOR; + } - //Index,FieldForm관련 + public function getService(): PartService + { + if (!$this->_service) { + $this->_service = new PartService(); + } + return $this->_service; + } + public function getHelper(): PartHelper + { + if (!$this->_helper) { + $this->_helper = new PartHelper(); + } + return $this->_helper; + } + //Index,FieldForm관 } diff --git a/app/Controllers/Admin/Equipment/ServerController.php b/app/Controllers/Admin/Equipment/ServerController.php index 4fa7a5d..863b1e4 100644 --- a/app/Controllers/Admin/Equipment/ServerController.php +++ b/app/Controllers/Admin/Equipment/ServerController.php @@ -55,7 +55,7 @@ class ServerController extends EquipmentController foreach (SERVICE_ITEM_TYPES as $item_type => $label) { $entity->setItemEntities( $item_type, - $this->getService()->getEntities(['serviceinfo_code' => $entity->getPK(), 'item_type' => $item_type]) + $this->getService()->getEntities(['serviceinfo_uid' => $entity->getPK(), 'item_type' => $item_type]) ); } //부모처리 diff --git a/app/Controllers/CLI/Payment.php b/app/Controllers/CLI/Payment.php index 4785454..e21b4b1 100644 --- a/app/Controllers/CLI/Payment.php +++ b/app/Controllers/CLI/Payment.php @@ -36,7 +36,7 @@ class Payment extends BaseController //결제일이 오늘보다 크고, 상태가 사용중인 서비스정보를 이용해서 결제정보에 신규 추가하기 foreach ($this->getServiceService()->getEntities(['billing_at' => date("Y-m-d"), 'status' => ServiceEntity::STATUS_NORMAL]) as $serviceEntity) { // echo $serviceEntity->getPK() . ":" . $serviceEntity->getBillingAt() . "\n"; - foreach ($this->getServiceItemService()->getEntities(['serviceinfo_code' => $serviceEntity->getPK()]) as $itemEntity) { + foreach ($this->getServiceItemService()->getEntities(['serviceinfo_uid' => $serviceEntity->getPK()]) as $itemEntity) { //결제정보 ServicePaymentService에 월별 결제만 신규등록 if ($itemEntity->getBillingCycle() == "month") { //결제정보 ServicePaymentService에 등록 diff --git a/app/Database/dbmsv2.vuerd.json b/app/Database/dbmsv2.vuerd.json index 143d3f7..eb67c19 100644 --- a/app/Database/dbmsv2.vuerd.json +++ b/app/Database/dbmsv2.vuerd.json @@ -4,9 +4,9 @@ "settings": { "width": 3000, "height": 3000, - "scrollTop": -1180, - "scrollLeft": -205, - "zoomLevel": 1, + "scrollTop": -991.0994, + "scrollLeft": -952.1533, + "zoomLevel": 0.79, "show": 511, "database": 4, "databaseName": "", @@ -55,21 +55,21 @@ "wmEgQA24OTZKcWDKf8tSK", "Pq5Jn2IXFEMjYVBvdAwWg", "fp3dQLQSGF28FCgdXZVk1", - "-6P0QeZZJQRJ5_ZQjzb1M", - "5p6IeLChVoXSw9jrqw-QW", - "e57qOlaGNqgfNVFBAoaDa", - "yNXavIEUyRz9ijpnoapzg", - "-innuV4-s0XLM5nzcY6qH", - "29R_28dluuNshr0cYiWmK", - "NMZvzyFkfEHAC1ky3ra_L", - "VroEhP44BVBCHx9WyFjhm", - "2UJ97eZArC3FeTkEjPTUl", - "uTwhO_6djzNzMFo8rwOSQ", "FjAORncWifI_a1aI6e0LJ", "qVSQf-uiaof7exFrBC68_", - "TkraffhuWi06www9bNecX", - "JHk1wOfFhz_GNJAEenhCO", - "B6ICbmerSrCvqCUoa9YlL" + "zOs903u-VzCEbWJraaxmw", + "1p3LjLIbD9DdTZWgCMHXw", + "NgATxxoCJLbTz8z474ksG", + "fEy_ujJc8f1yvtvsordhM", + "u_J2wFyhwkNzvwtpuwCLu", + "S-DADUvespt-XHt1mSG1Q", + "6VC4ptgKReRmeDlXuKRN1", + "xTe9A_4sfYrsFREUz7sNc", + "5R5vlOrsoLSG-j2m2_dj2", + "sWc1LMcA0iFU_8byUhUnv", + "UoS3Mvohv6zri0971LA1O", + "sXGbpO3Qip9Ed7NxK_Bdj", + "-Cg-8t54mL4p_RVJqoVEC" ], "indexIds": [], "memoIds": [] @@ -106,7 +106,7 @@ "w_EuwbTwtLEPAgYjS1aYq" ], "ui": { - "x": 1321.5003, + "x": 1419.5003, "y": 297.6737, "zIndex": 2, "widthName": 60, @@ -114,7 +114,7 @@ "color": "" }, "meta": { - "updateAt": 1755506747335, + "updateAt": 1755653491658, "createAt": 1745819764136 } }, @@ -123,8 +123,10 @@ "name": "clientinfo", "comment": "고객정보", "columnIds": [ - "n7IyDCZLDqfEo49XRYtYR", + "V6BuLrtFrGgCWaHSUkSLb", "hrPg0uHAdEjamOj--BVzO", + "n7IyDCZLDqfEo49XRYtYR", + "PBr9iDWm2BKjEwsrfY1Yn", "z-q_Ah0sghd0nR7VcCTLX", "n61V7aSxLmcIeQqsYgAEE", "5hP5ZiQGWDGf4HJrOiFb6", @@ -139,9 +141,11 @@ "JEk5AASiK6MpT9QBRWjMX" ], "seqColumnIds": [ - "n7IyDCZLDqfEo49XRYtYR", + "V6BuLrtFrGgCWaHSUkSLb", "_AcWUYKzNJd-V0fRHq8Cx", "hrPg0uHAdEjamOj--BVzO", + "n7IyDCZLDqfEo49XRYtYR", + "PBr9iDWm2BKjEwsrfY1Yn", "z-q_Ah0sghd0nR7VcCTLX", "FFviMCKUUVRlcZdx-Uqiq", "n61V7aSxLmcIeQqsYgAEE", @@ -164,15 +168,15 @@ "JEk5AASiK6MpT9QBRWjMX" ], "ui": { - "x": 865.9298, - "y": 818.2277, + "x": 696.3092, + "y": 832.1517, "zIndex": 2, "widthName": 60, "widthComment": 60, "color": "" }, "meta": { - "updateAt": 1755596145096, + "updateAt": 1755654904923, "createAt": 1745819764137 } }, @@ -183,7 +187,7 @@ "columnIds": [ "ia3c6jjHvbTOX0cX4gbJl", "10Ii30CtjhJA-dPVnX2Z-", - "7e7kPIVKM4VrUWTZADe-5", + "UdKStw4LaMSQ0QxI2PfV_", "jOM-6WvS4B5lGVJuNRQ9L", "tmkHXMc6fdNicHeig7nss", "foBGnViYEjNlWIAhXeuLw", @@ -198,6 +202,7 @@ "ia3c6jjHvbTOX0cX4gbJl", "nPYun5WHoy8uroXUBiqh8", "10Ii30CtjhJA-dPVnX2Z-", + "UdKStw4LaMSQ0QxI2PfV_", "7e7kPIVKM4VrUWTZADe-5", "jOM-6WvS4B5lGVJuNRQ9L", "tmkHXMc6fdNicHeig7nss", @@ -214,15 +219,15 @@ "_nE1H-douje4Wo8mZ4XUG" ], "ui": { - "x": 81.996, - "y": 81.6218, + "x": 49.0848, + "y": 67.6977, "zIndex": 2, "widthName": 64, "widthComment": 62, "color": "" }, "meta": { - "updateAt": 1755506070502, + "updateAt": 1755654895097, "createAt": 1745819764137 } }, @@ -231,9 +236,10 @@ "name": "serverinfo", "comment": "서버정보", "columnIds": [ + "RITMHZcQAJ7KvtxkTtMv-", + "JRdeV7n53lb1iSmmYnhHX", + "4iRyOhmW3b7kbiZT8lQyY", "34psXzS7RLX0sWXZyDGGf", - "hPz83FX0cU7HIyVRRr5sl", - "3fZMQ9qB1DO8y44eJRKdt", "m77kSp3scTgMhInPBjsc3", "9F6QpQqxeEggZ0FHM81O1", "tsDqk1dzwzUtvBzpjmarJ", @@ -260,10 +266,13 @@ "imjqFzOrKxNF9-aH171pe", "PPYMa0hTpupMnPEWZEVp6", "SlbGqJXf-rNePjMEvRIsr", - "34psXzS7RLX0sWXZyDGGf", + "RITMHZcQAJ7KvtxkTtMv-", "1R3FQnBR2tpSdfkj3jipU", + "JRdeV7n53lb1iSmmYnhHX", + "4iRyOhmW3b7kbiZT8lQyY", "hPz83FX0cU7HIyVRRr5sl", "3fZMQ9qB1DO8y44eJRKdt", + "34psXzS7RLX0sWXZyDGGf", "m77kSp3scTgMhInPBjsc3", "9F6QpQqxeEggZ0FHM81O1", "EKrwHre6e66jqAMnAW_KR", @@ -310,7 +319,7 @@ "color": "" }, "meta": { - "updateAt": 1755593063862, + "updateAt": 1755653857413, "createAt": 1745819764137 } }, @@ -363,7 +372,7 @@ "doERb3lIVeBW_D0NtNYX8": { "id": "doERb3lIVeBW_D0NtNYX8", "name": "lineinfo", - "comment": "회선 정보", + "comment": "회선정보", "columnIds": [ "7B0zaLoZnOoMNW8OHZlrQ", "oc5quhO8E3mqrBZKbIy_G", @@ -401,27 +410,27 @@ "ZgRRNC6OFpn87uomKBHbH" ], "ui": { - "x": 2302.2041, - "y": 1431.8748, + "x": 2303.2041, + "y": 1392.8748, "zIndex": 2, "widthName": 60, "widthComment": 60, "color": "" }, "meta": { - "updateAt": 1755566046122, + "updateAt": 1755654240788, "createAt": 1745819764138 } }, "ZLEpY5EjuZV21718zf-Y1": { "id": "ZLEpY5EjuZV21718zf-Y1", "name": "ipinfo", - "comment": " IP 정보", + "comment": " IP정보", "columnIds": [ "Id0h8QbOdlhPj9P1zTm5o", "f7_MGvRjkwL1xkCWrAgDR", - "ImCmrkHrB4nfB35PilQnf", - "6i-Ag5fvYugIDFg9tH3HA", + "60w6M5QqxGAvJa3EEMDbR", + "QznZ6PY_T3OGj3YD4GdOX", "6qd6rcTkraI_AbHcVbp6T", "dIY_dF7qvUpTGyBwlnHjG", "aWjaosOJdZd4AqZ-dk69F", @@ -435,6 +444,7 @@ "Id0h8QbOdlhPj9P1zTm5o", "SFj3q5xg6pcI4RSDKPSgI", "f7_MGvRjkwL1xkCWrAgDR", + "60w6M5QqxGAvJa3EEMDbR", "nIeV_YUzCUo3ZwJEtefBV", "ZPFSJbnNsml6U3UKwtSVX", "7j-v8422Rzf3ZoLGCDJGo", @@ -447,6 +457,7 @@ "sWwdum3AkxFncLEFPN1CM", "ImCmrkHrB4nfB35PilQnf", "6i-Ag5fvYugIDFg9tH3HA", + "QznZ6PY_T3OGj3YD4GdOX", "6qd6rcTkraI_AbHcVbp6T", "0ONL4QLQRyZ32MBJ7TN7u", "e6eWKMFnpXI-rPJZ_9tBt", @@ -468,7 +479,7 @@ "color": "" }, "meta": { - "updateAt": 1755584145808, + "updateAt": 1755654232567, "createAt": 1745819764138 } }, @@ -479,7 +490,7 @@ "columnIds": [ "9gNKhuq9UnDKyb9KuZ7cY", "J1dtvqmAyJxT6QtuZq7IA", - "YdLa5geill88c3UM5a_YR", + "7V8vH8k_wZV5zwh_OLNFs", "ALRvTZjYrv4K1ltFn30Mn", "TFkQ1ID6ShcMqf9wLGEP1", "DSAUgD7rG7Lzm2-jVWKA3", @@ -493,6 +504,7 @@ "G3KLXJzl6S28Y8pN8hfy2", "35XbdvgOzpNdasPnMcbkx", "J1dtvqmAyJxT6QtuZq7IA", + "7V8vH8k_wZV5zwh_OLNFs", "YdLa5geill88c3UM5a_YR", "ALRvTZjYrv4K1ltFn30Mn", "3EFy0j6PlKaha31ajJSsZ", @@ -511,15 +523,15 @@ "j6eibwPFvw27a38mAO3K_" ], "ui": { - "x": 79.2377, - "y": 461.9543, + "x": 50.1238, + "y": 435.372, "zIndex": 2, "widthName": 63, "widthComment": 60, "color": "" }, "meta": { - "updateAt": 1755506350656, + "updateAt": 1755654890491, "createAt": 1745819764140 } }, @@ -850,8 +862,8 @@ "columnIds": [ "GMPyqxaroK2OjQZnoCRwn", "s1Az-lXWK0NlVQqFEEK8o", - "QwfRq6xU7Vy-QoenynjXR", - "LRN5qjIRZ18UOhqFbBLuo", + "8mPFhDdUY8QLPvc8rNw1B", + "vxhl-9RMNJ8zU9oqzEWo8", "vbPIGWHquXROtCfId6RVF", "FhnUrn_dOrdhaBe_P3ty-", "SA3xJ9nRW8EWDCFoMjnj3", @@ -876,7 +888,9 @@ "wMsY1BXM9mKftyYax3Psx", "N-ESuxOk84rEdS2SzpVcx", "QwfRq6xU7Vy-QoenynjXR", + "8mPFhDdUY8QLPvc8rNw1B", "LRN5qjIRZ18UOhqFbBLuo", + "vxhl-9RMNJ8zU9oqzEWo8", "vbPIGWHquXROtCfId6RVF", "FhnUrn_dOrdhaBe_P3ty-", "SA3xJ9nRW8EWDCFoMjnj3", @@ -889,15 +903,15 @@ "n9ZWAQ9754sZ3MM4IxCAA" ], "ui": { - "x": 2294.4072, - "y": 467.0365, + "x": 2314.4072, + "y": 644.0365, "zIndex": 2278, "widthName": 60, "widthComment": 60, "color": "" }, "meta": { - "updateAt": 1755572503487, + "updateAt": 1755653438046, "createAt": 1748484896313 } }, @@ -906,9 +920,10 @@ "name": "serviceinfo", "comment": "서비스정보", "columnIds": [ - "1ZM86qoxmCcoKnqOpE2oj", + "nNWsAWbHfKWqx8EwxvuM1", "Vf3bNvvEPfu1zCs4rcHTU", - "0LanT5cVJX_uBb0Foh2NM", + "N-2m8O_JzS6-sDEcL5zTv", + "1ZM86qoxmCcoKnqOpE2oj", "50a08OnwVq9SXAXX5pq6s", "ptLUIGfIqm89XGRz_V2ww", "hQ5EOPiUpDbVpWQwawtw4", @@ -924,8 +939,10 @@ "seqColumnIds": [ "N_yJVoCN4oUEDhYqdzApb", "gJFdxac0XhNJmCQaua2XT", - "1ZM86qoxmCcoKnqOpE2oj", + "nNWsAWbHfKWqx8EwxvuM1", "Vf3bNvvEPfu1zCs4rcHTU", + "N-2m8O_JzS6-sDEcL5zTv", + "1ZM86qoxmCcoKnqOpE2oj", "NzxkmndrTbH7xb6fbnGV7", "x3mRYyi3hsNg-7bPbddVH", "KcB0lsCfyDNkaBkLXrHec", @@ -973,15 +990,15 @@ "2fzVlWt1Skh-391N_z9Ci" ], "ui": { - "x": 1527.5462, - "y": 951.5417, + "x": 1526.2804, + "y": 976.8582, "zIndex": 2395, "widthName": 60, "widthComment": 62, "color": "" }, "meta": { - "updateAt": 1755592449163, + "updateAt": 1755654974759, "createAt": 1748485662214 } }, @@ -1028,8 +1045,9 @@ "name": "switchinfo", "comment": "스위치정보", "columnIds": [ + "CKqk9KisacveOubGKDQHa", + "wi1XbZM3emknh42sOMkYq", "sVypeCGZk-JXvsbwc93Rw", - "Li6TetD-ZbH9MNKGAK0im", "QEXGVSZ3sjvmtUCdgXl6_", "4Koam7FHw2_rCXSUBEQJB", "d7HNONWncNoqDRCl4-Y0N", @@ -1041,8 +1059,11 @@ "ByQhiHPUZQBhgIaT774FJ", "Tf4tatgNo1vCFMiLXWWzk", "UqCsY6KiCJOOFtjCHoMVL", - "sVypeCGZk-JXvsbwc93Rw", + "CKqk9KisacveOubGKDQHa", + "GGL413h2VpSCaHyrCkWSA", "Li6TetD-ZbH9MNKGAK0im", + "wi1XbZM3emknh42sOMkYq", + "sVypeCGZk-JXvsbwc93Rw", "_KISusuMe8-oGta7xOaz0", "QEXGVSZ3sjvmtUCdgXl6_", "4Koam7FHw2_rCXSUBEQJB", @@ -1058,7 +1079,7 @@ "color": "" }, "meta": { - "updateAt": 1755505735092, + "updateAt": 1755653730437, "createAt": 1750898626895 } }, @@ -1343,7 +1364,7 @@ "comment": "CS정보(한서버 여러개 앞단 등록가능)", "columnIds": [ "PuLZie9O9warTXzmBPj3F", - "pcpeNmSmqH_DtbRLyaYv9", + "GtBqjKsmtYWvsd0fckBc0", "JtbW3CtPKBxnw4Fohhpci", "2KpyBHvmw6fmuTZhPAWYf", "qd1nPOkfMmY9uJDQBaaWq", @@ -1358,6 +1379,7 @@ "PuLZie9O9warTXzmBPj3F", "SlovGoAbswPj9pLEDGAO_", "pcpeNmSmqH_DtbRLyaYv9", + "GtBqjKsmtYWvsd0fckBc0", "JtbW3CtPKBxnw4Fohhpci", "2KpyBHvmw6fmuTZhPAWYf", "qd1nPOkfMmY9uJDQBaaWq", @@ -1379,7 +1401,7 @@ "color": "" }, "meta": { - "updateAt": 1755584135273, + "updateAt": 1755653784249, "createAt": 1755244574868 } }, @@ -1562,7 +1584,7 @@ "comment": "서버정보_part정보(CASECADE)", "columnIds": [ "XXQzeCrEymboccXMZCzMo", - "mOdd3p43Qb4VStgr1nWHB", + "IbWdZlEEF70bGqUDkU5ub", "l2g7xess8DY86_ZOm7Ca1", "mYEan5gjLS5bBthtFCc6w", "SioEINPlR0iyL87vqa4N-", @@ -1576,6 +1598,7 @@ "CvilrbKyyz1NnLPndNkb8", "x23F_sFvFpqLOXzldHBFn", "HZIdc4faH9k91g-JN-NhW", + "IbWdZlEEF70bGqUDkU5ub", "l2g7xess8DY86_ZOm7Ca1", "mYEan5gjLS5bBthtFCc6w", "SioEINPlR0iyL87vqa4N-", @@ -1595,7 +1618,7 @@ "color": "" }, "meta": { - "updateAt": 1755584198146, + "updateAt": 1755654072586, "createAt": 1755476453282 } }, @@ -1708,7 +1731,7 @@ "columnIds": [ "JnsH90ebD8YNwM8q_Ajat", "z86v6qGtWsrVhzZfUo_7d", - "QD0EVLU6BeTsEsNO3MAgd", + "wYamirJUg21s94uxd_YhW", "gbR9hOeDvjnrJAxI4vLf9", "PV9lD8qRmTrg8bMT4t3WG", "VP7GvkqWejNbQZc-tmlr_", @@ -1719,6 +1742,7 @@ "seqColumnIds": [ "JnsH90ebD8YNwM8q_Ajat", "z86v6qGtWsrVhzZfUo_7d", + "wYamirJUg21s94uxd_YhW", "QD0EVLU6BeTsEsNO3MAgd", "gbR9hOeDvjnrJAxI4vLf9", "PV9lD8qRmTrg8bMT4t3WG", @@ -1728,15 +1752,15 @@ "dNTE1M813GnbddEqp4esS" ], "ui": { - "x": 81.8513, - "y": 773.4195, + "x": 46.4083, + "y": 734.179, "zIndex": 5357, "widthName": 60, "widthComment": 62, "color": "" }, "meta": { - "updateAt": 1755506266044, + "updateAt": 1755654886662, "createAt": 1755488593741 } } @@ -1746,19 +1770,19 @@ "id": "mfHtgzc_Aeocr6xkgwYWh", "tableId": "Jq5Qkun2FzQhCGKANIVOZ", "name": "uid", - "comment": "", + "comment": "관리자정보", "dataType": "INT", "default": "", "options": 3, "ui": { "keys": 1, "widthName": 60, - "widthComment": 60, + "widthComment": 62, "widthDataType": 60, "widthDefault": 60 }, "meta": { - "updateAt": 1755483197547, + "updateAt": 1755653315672, "createAt": 1745819764136 } }, @@ -1829,7 +1853,7 @@ "comment": "", "dataType": "VARCHAR(50)", "default": "", - "options": 8, + "options": 0, "ui": { "keys": 0, "widthName": 60, @@ -1838,7 +1862,7 @@ "widthDefault": 60 }, "meta": { - "updateAt": 1755483204227, + "updateAt": 1755653515800, "createAt": 1745819764137 } }, @@ -2526,7 +2550,7 @@ "id": "2HB01q46-mugMjuOz85YG", "tableId": "ZMGIWLFEswObjH2Sx0NlW", "name": "uid", - "comment": "", + "comment": "PART정보", "dataType": "INT", "default": "", "options": 11, @@ -2538,7 +2562,7 @@ "widthDefault": 60 }, "meta": { - "updateAt": 1755483185843, + "updateAt": 1755654097863, "createAt": 1745819764138 } }, @@ -2686,7 +2710,7 @@ "id": "7B0zaLoZnOoMNW8OHZlrQ", "tableId": "doERb3lIVeBW_D0NtNYX8", "name": "uid", - "comment": "", + "comment": "회선정보", "dataType": "INT", "default": "", "options": 11, @@ -2698,7 +2722,7 @@ "widthDefault": 60 }, "meta": { - "updateAt": 1755483187930, + "updateAt": 1755654025344, "createAt": 1745819764138 } }, @@ -3246,7 +3270,7 @@ "id": "Id0h8QbOdlhPj9P1zTm5o", "tableId": "ZLEpY5EjuZV21718zf-Y1", "name": "uid", - "comment": "", + "comment": "IP정보", "dataType": "INT", "default": "", "options": 11, @@ -3258,7 +3282,7 @@ "widthDefault": 60 }, "meta": { - "updateAt": 1755483249621, + "updateAt": 1755654228667, "createAt": 1745820637059 } }, @@ -7549,16 +7573,16 @@ "comment": "switch코드", "dataType": "VARCHAR(20)", "default": "", - "options": 10, + "options": 12, "ui": { - "keys": 1, + "keys": 0, "widthName": 60, "widthComment": 60, "widthDataType": 75, "widthDefault": 60 }, "meta": { - "updateAt": 1755483621597, + "updateAt": 1755652973816, "createAt": 1750898653166 } }, @@ -7929,16 +7953,16 @@ "comment": "고객코드", "dataType": "VARCHAR(20)", "default": "", - "options": 10, + "options": 12, "ui": { - "keys": 1, + "keys": 0, "widthName": 60, "widthComment": 60, "widthDataType": 75, "widthDefault": 60 }, "meta": { - "updateAt": 1755483666038, + "updateAt": 1755652948880, "createAt": 1751880475984 } }, @@ -7949,16 +7973,16 @@ "comment": "서비스코드", "dataType": "VARCHAR(20)", "default": "", - "options": 10, + "options": 12, "ui": { - "keys": 1, + "keys": 0, "widthName": 60, "widthComment": 62, "widthDataType": 75, "widthDefault": 60 }, "meta": { - "updateAt": 1755483656473, + "updateAt": 1755653002089, "createAt": 1751959574914 } }, @@ -7969,16 +7993,16 @@ "comment": "서버코드", "dataType": "VARCHAR(20)", "default": "", - "options": 10, + "options": 12, "ui": { - "keys": 1, + "keys": 0, "widthName": 60, "widthComment": 60, "widthDataType": 75, "widthDefault": 60 }, "meta": { - "updateAt": 1755486588316, + "updateAt": 1755652936792, "createAt": 1755062321357 } }, @@ -11691,7 +11715,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 89, "widthComment": 62, "widthDataType": 75, @@ -11711,7 +11735,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 85, "widthComment": 60, "widthDataType": 75, @@ -11771,7 +11795,7 @@ "default": "", "options": 0, "ui": { - "keys": 2, + "keys": 0, "widthName": 85, "widthComment": 60, "widthDataType": 75, @@ -11831,7 +11855,7 @@ "default": "", "options": 0, "ui": { - "keys": 2, + "keys": 0, "widthName": 89, "widthComment": 62, "widthDataType": 75, @@ -12091,7 +12115,7 @@ "default": "", "options": 0, "ui": { - "keys": 2, + "keys": 0, "widthName": 85, "widthComment": 60, "widthDataType": 75, @@ -12111,7 +12135,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 60, "widthDataType": 75, @@ -12131,7 +12155,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 60, "widthDataType": 75, @@ -12171,7 +12195,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 60, "widthDataType": 75, @@ -12191,7 +12215,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 60, "widthDataType": 75, @@ -12251,7 +12275,7 @@ "default": "", "options": 0, "ui": { - "keys": 2, + "keys": 0, "widthName": 85, "widthComment": 60, "widthDataType": 75, @@ -12266,7 +12290,7 @@ "id": "l2g7xess8DY86_ZOm7Ca1", "tableId": "8GYAVBvZGaMFeq3QuXk_B", "name": "partinfo_uid", - "comment": "part정보", + "comment": "PART정보", "dataType": "INT", "default": "", "options": 8, @@ -12278,7 +12302,7 @@ "widthDefault": 60 }, "meta": { - "updateAt": 1755486711129, + "updateAt": 1755654089497, "createAt": 1755486693704 } }, @@ -12471,7 +12495,7 @@ "default": "", "options": 8, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 60, "widthDataType": 75, @@ -12491,7 +12515,7 @@ "default": "", "options": 0, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 93, "widthDataType": 75, @@ -12671,7 +12695,7 @@ "default": "", "options": 0, "ui": { - "keys": 2, + "keys": 0, "widthName": 82, "widthComment": 105, "widthDataType": 75, @@ -12781,6 +12805,386 @@ "updateAt": 1755593253840, "createAt": 1755593061849 } + }, + "V6BuLrtFrGgCWaHSUkSLb": { + "id": "V6BuLrtFrGgCWaHSUkSLb", + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "name": "uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 11, + "ui": { + "keys": 1, + "widthName": 60, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653221021, + "createAt": 1755652866378 + } + }, + "RITMHZcQAJ7KvtxkTtMv-": { + "id": "RITMHZcQAJ7KvtxkTtMv-", + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "name": "uid", + "comment": "서버정보", + "dataType": "INT", + "default": "", + "options": 11, + "ui": { + "keys": 1, + "widthName": 60, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653698995, + "createAt": 1755652920073 + } + }, + "CKqk9KisacveOubGKDQHa": { + "id": "CKqk9KisacveOubGKDQHa", + "tableId": "IsMoJXzvtuoOFFt93qS0w", + "name": "uid", + "comment": "스위치정보", + "dataType": "INT", + "default": "", + "options": 11, + "ui": { + "keys": 1, + "widthName": 60, + "widthComment": 62, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653638608, + "createAt": 1755652964105 + } + }, + "nNWsAWbHfKWqx8EwxvuM1": { + "id": "nNWsAWbHfKWqx8EwxvuM1", + "tableId": "B8haiEbPc1lRBWTv1g25G", + "name": "uid", + "comment": "서비스정보", + "dataType": "INT", + "default": "", + "options": 11, + "ui": { + "keys": 1, + "widthName": 60, + "widthComment": 62, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653350019, + "createAt": 1755652992101 + } + }, + "wYamirJUg21s94uxd_YhW": { + "id": "wYamirJUg21s94uxd_YhW", + "tableId": "PdXX5ghGi8ZK89G9OjtnQ", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653229465, + "createAt": 1755653051161 + } + }, + "7V8vH8k_wZV5zwh_OLNFs": { + "id": "7V8vH8k_wZV5zwh_OLNFs", + "tableId": "jO40Ej5EXImXnadoJo9bn", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653236252, + "createAt": 1755653122067 + } + }, + "UdKStw4LaMSQ0QxI2PfV_": { + "id": "UdKStw4LaMSQ0QxI2PfV_", + "tableId": "GDEF0_WuOpaYtsZxjn2zM", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653244344, + "createAt": 1755653143745 + } + }, + "8mPFhDdUY8QLPvc8rNw1B": { + "id": "8mPFhDdUY8QLPvc8rNw1B", + "tableId": "QCNA57Pi6A9dJDgybxS5v", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653297883, + "createAt": 1755653280042 + } + }, + "N-2m8O_JzS6-sDEcL5zTv": { + "id": "N-2m8O_JzS6-sDEcL5zTv", + "tableId": "B8haiEbPc1lRBWTv1g25G", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653373357, + "createAt": 1755653363963 + } + }, + "vxhl-9RMNJ8zU9oqzEWo8": { + "id": "vxhl-9RMNJ8zU9oqzEWo8", + "tableId": "QCNA57Pi6A9dJDgybxS5v", + "name": "serviceinfo_uid", + "comment": "서비스정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 80, + "widthComment": 62, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653435161, + "createAt": 1755653412891 + } + }, + "GGL413h2VpSCaHyrCkWSA": { + "id": "GGL413h2VpSCaHyrCkWSA", + "tableId": "IsMoJXzvtuoOFFt93qS0w", + "name": "uid", + "comment": "", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 0, + "widthName": 60, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653684946, + "createAt": 1755653684946 + } + }, + "wi1XbZM3emknh42sOMkYq": { + "id": "wi1XbZM3emknh42sOMkYq", + "tableId": "IsMoJXzvtuoOFFt93qS0w", + "name": "serverinfo_uid", + "comment": "서버정보", + "dataType": "INT", + "default": "", + "options": 0, + "ui": { + "keys": 2, + "widthName": 76, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653739474, + "createAt": 1755653724845 + } + }, + "GtBqjKsmtYWvsd0fckBc0": { + "id": "GtBqjKsmtYWvsd0fckBc0", + "tableId": "SEgsi7mbM-56Rsx5-qj8K", + "name": "serverinfo_uid", + "comment": "서버정보", + "dataType": "INT", + "default": "", + "options": 0, + "ui": { + "keys": 2, + "widthName": 76, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653797503, + "createAt": 1755653779889 + } + }, + "4iRyOhmW3b7kbiZT8lQyY": { + "id": "4iRyOhmW3b7kbiZT8lQyY", + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "name": "serviceinfo_uid", + "comment": "서비스정보", + "dataType": "INT", + "default": "", + "options": 0, + "ui": { + "keys": 2, + "widthName": 80, + "widthComment": 62, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653833897, + "createAt": 1755653818593 + } + }, + "JRdeV7n53lb1iSmmYnhHX": { + "id": "JRdeV7n53lb1iSmmYnhHX", + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 0, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653870106, + "createAt": 1755653851900 + } + }, + "60w6M5QqxGAvJa3EEMDbR": { + "id": "60w6M5QqxGAvJa3EEMDbR", + "tableId": "ZLEpY5EjuZV21718zf-Y1", + "name": "clientinfo_uid", + "comment": "고객정보", + "dataType": "INT", + "default": "", + "options": 0, + "ui": { + "keys": 2, + "widthName": 73, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653956180, + "createAt": 1755653938444 + } + }, + "QznZ6PY_T3OGj3YD4GdOX": { + "id": "QznZ6PY_T3OGj3YD4GdOX", + "tableId": "ZLEpY5EjuZV21718zf-Y1", + "name": "serverinfo_uid", + "comment": "서버정보", + "dataType": "INT", + "default": "", + "options": 0, + "ui": { + "keys": 2, + "widthName": 76, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755653994470, + "createAt": 1755653979090 + } + }, + "IbWdZlEEF70bGqUDkU5ub": { + "id": "IbWdZlEEF70bGqUDkU5ub", + "tableId": "8GYAVBvZGaMFeq3QuXk_B", + "name": "serverinfo_uid", + "comment": "서버정보", + "dataType": "INT", + "default": "", + "options": 8, + "ui": { + "keys": 2, + "widthName": 76, + "widthComment": 60, + "widthDataType": 60, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755654070123, + "createAt": 1755654048877 + } + }, + "PBr9iDWm2BKjEwsrfY1Yn": { + "id": "PBr9iDWm2BKjEwsrfY1Yn", + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "name": "site", + "comment": "Site구분", + "dataType": "VARCHAR(20)", + "default": "'prime'", + "options": 8, + "ui": { + "keys": 0, + "widthName": 60, + "widthComment": 60, + "widthDataType": 75, + "widthDefault": 60 + }, + "meta": { + "updateAt": 1755655622958, + "createAt": 1755654833478 + } } }, "relationshipEntities": { @@ -12794,8 +13198,8 @@ "columnIds": [ "7B0zaLoZnOoMNW8OHZlrQ" ], - "x": 2302.2041, - "y": 1579.8748, + "x": 2303.2041, + "y": 1540.8748, "direction": 1 }, "end": { @@ -12803,7 +13207,7 @@ "columnIds": [ "f7_MGvRjkwL1xkCWrAgDR" ], - "x": 2079.7956, + "x": 2025.7956, "y": 1600.8948, "direction": 2 }, @@ -12822,7 +13226,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1573.0003, + "x": 1672.0003, "y": 593.6737, "direction": 8 }, @@ -12831,8 +13235,8 @@ "columnIds": [ "Vf3bNvvEPfu1zCs4rcHTU" ], - "x": 1858.5462, - "y": 951.5417, + "x": 1852.7804, + "y": 976.8582, "direction": 4 }, "meta": { @@ -12850,7 +13254,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1824.5003, + "x": 1924.5003, "y": 519.6737, "direction": 2 }, @@ -12859,8 +13263,8 @@ "columnIds": [ "s1Az-lXWK0NlVQqFEEK8o" ], - "x": 2294.4072, - "y": 528.3698333333333, + "x": 2314.4072, + "y": 705.3698333333333, "direction": 1 }, "meta": { @@ -12878,7 +13282,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1824.5003, + "x": 1924.5003, "y": 371.6737, "direction": 2 }, @@ -13102,7 +13506,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1321.5003, + "x": 1419.5003, "y": 482.6737, "direction": 1 }, @@ -13111,8 +13515,8 @@ "columnIds": [ "hrPg0uHAdEjamOj--BVzO" ], - "x": 1265.6798, - "y": 818.2277, + "x": 1140.4758666666667, + "y": 832.1517, "direction": 4 }, "meta": { @@ -13130,7 +13534,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1321.5003, + "x": 1419.5003, "y": 334.6737, "direction": 1 }, @@ -13139,8 +13543,8 @@ "columnIds": [ "10Ii30CtjhJA-dPVnX2Z-" ], - "x": 606.996, - "y": 167.6218, + "x": 565.0848, + "y": 153.6977, "direction": 2 }, "meta": { @@ -13186,7 +13590,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1321.5003, + "x": 1419.5003, "y": 408.6737, "direction": 1 }, @@ -13195,8 +13599,8 @@ "columnIds": [ "J1dtvqmAyJxT6QtuZq7IA" ], - "x": 604.2377, - "y": 529.9543, + "x": 566.1238, + "y": 503.372, "direction": 2 }, "meta": { @@ -14306,8 +14710,8 @@ "columnIds": [ "1ZM86qoxmCcoKnqOpE2oj" ], - "x": 2189.5461999999998, - "y": 1147.5417, + "x": 2180.5461999999998, + "y": 1159.5417, "direction": 2 }, "end": { @@ -14334,8 +14738,8 @@ "columnIds": [ "34psXzS7RLX0sWXZyDGGf" ], - "x": 1328.179, - "y": 1848.520766666667, + "x": 1319.179, + "y": 1868.520766666667, "direction": 2 }, "end": { @@ -14419,7 +14823,7 @@ "34psXzS7RLX0sWXZyDGGf" ], "x": 740.179, - "y": 1633.8541, + "y": 1639.8541, "direction": 1 }, "end": { @@ -14427,8 +14831,8 @@ "columnIds": [ "Li6TetD-ZbH9MNKGAK0im" ], - "x": 608.893, - "y": 1543.8934, + "x": 610.893, + "y": 1555.8934, "direction": 2 }, "meta": { @@ -14503,7 +14907,7 @@ "1ZM86qoxmCcoKnqOpE2oj" ], "x": 1527.5462, - "y": 1245.5417, + "y": 1263.5417, "direction": 1 }, "end": { @@ -14512,7 +14916,7 @@ "3fZMQ9qB1DO8y44eJRKdt" ], "x": 1328.179, - "y": 1603.1874333333335, + "y": 1607.1874333333335, "direction": 2 }, "meta": { @@ -14642,8 +15046,8 @@ "columnIds": [ "34psXzS7RLX0sWXZyDGGf" ], - "x": 1328.179, - "y": 1725.8541000000002, + "x": 1319.179, + "y": 1737.8541000000002, "direction": 2 }, "end": { @@ -14671,7 +15075,7 @@ "n7IyDCZLDqfEo49XRYtYR" ], "x": 1398.9298, - "y": 1112.2277, + "y": 1130.2277, "direction": 2 }, "end": { @@ -14680,7 +15084,7 @@ "0LanT5cVJX_uBb0Foh2NM" ], "x": 1527.5462, - "y": 1049.5417, + "y": 1055.5417, "direction": 1 }, "meta": { @@ -14699,7 +15103,7 @@ "n7IyDCZLDqfEo49XRYtYR" ], "x": 1398.9298, - "y": 916.2277, + "y": 922.2277, "direction": 2 }, "end": { @@ -14754,7 +15158,7 @@ "columnIds": [ "n7IyDCZLDqfEo49XRYtYR" ], - "x": 999.1798, + "x": 954.7631333333333, "y": 818.2277, "direction": 4 }, @@ -14764,7 +15168,7 @@ "7e7kPIVKM4VrUWTZADe-5" ], "x": 606.996, - "y": 339.6218, + "y": 265.6218, "direction": 2 }, "meta": { @@ -14783,7 +15187,7 @@ "n7IyDCZLDqfEo49XRYtYR" ], "x": 865.9298, - "y": 916.2277, + "y": 922.2277, "direction": 1 }, "end": { @@ -14811,7 +15215,7 @@ "34psXzS7RLX0sWXZyDGGf" ], "x": 740.179, - "y": 1817.8541, + "y": 1835.8541, "direction": 1 }, "end": { @@ -14847,7 +15251,7 @@ "columnIds": [ "l2g7xess8DY86_ZOm7Ca1" ], - "x": 2114.6117, + "x": 2110.6117, "y": 1934.3055, "direction": 2 }, @@ -14866,7 +15270,7 @@ "columnIds": [ "mfHtgzc_Aeocr6xkgwYWh" ], - "x": 1321.5003, + "x": 1419.5003, "y": 556.6737, "direction": 1 }, @@ -14875,8 +15279,8 @@ "columnIds": [ "z86v6qGtWsrVhzZfUo_7d" ], - "x": 606.8513, - "y": 841.4195, + "x": 562.4083, + "y": 802.179, "direction": 2 }, "meta": { @@ -14895,7 +15299,7 @@ "n7IyDCZLDqfEo49XRYtYR" ], "x": 865.9298, - "y": 1112.2277, + "y": 1130.2277, "direction": 1 }, "end": { @@ -14923,7 +15327,7 @@ "n7IyDCZLDqfEo49XRYtYR" ], "x": 999.1798, - "y": 1210.2277, + "y": 1234.2277, "direction": 8 }, "end": { @@ -14931,7 +15335,7 @@ "columnIds": [ "hPz83FX0cU7HIyVRRr5sl" ], - "x": 1034.179, + "x": 1030.679, "y": 1541.8541, "direction": 4 }, @@ -14951,7 +15355,7 @@ "n7IyDCZLDqfEo49XRYtYR" ], "x": 1265.6798, - "y": 1210.2277, + "y": 1234.2277, "direction": 8 }, "end": { @@ -14967,6 +15371,398 @@ "updateAt": 1755566111980, "createAt": 1755566111980 } + }, + "zOs903u-VzCEbWJraaxmw": { + "id": "zOs903u-VzCEbWJraaxmw", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 2, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 696.3092, + "y": 1052.1517, + "direction": 1 + }, + "end": { + "tableId": "PdXX5ghGi8ZK89G9OjtnQ", + "columnIds": [ + "wYamirJUg21s94uxd_YhW" + ], + "x": 562.4083, + "y": 938.179, + "direction": 2 + }, + "meta": { + "updateAt": 1755653051161, + "createAt": 1755653051161 + } + }, + "1p3LjLIbD9DdTZWgCMHXw": { + "id": "1p3LjLIbD9DdTZWgCMHXw", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 2, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 962.8091999999999, + "y": 832.1517, + "direction": 4 + }, + "end": { + "tableId": "jO40Ej5EXImXnadoJo9bn", + "columnIds": [ + "7V8vH8k_wZV5zwh_OLNFs" + ], + "x": 566.1238, + "y": 639.3720000000001, + "direction": 2 + }, + "meta": { + "updateAt": 1755653122067, + "createAt": 1755653122067 + } + }, + "NgATxxoCJLbTz8z474ksG": { + "id": "NgATxxoCJLbTz8z474ksG", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 2, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 785.1425333333333, + "y": 832.1517, + "direction": 4 + }, + "end": { + "tableId": "GDEF0_WuOpaYtsZxjn2zM", + "columnIds": [ + "UdKStw4LaMSQ0QxI2PfV_" + ], + "x": 565.0848, + "y": 325.6977, + "direction": 2 + }, + "meta": { + "updateAt": 1755653143745, + "createAt": 1755653143745 + } + }, + "fEy_ujJc8f1yvtvsordhM": { + "id": "fEy_ujJc8f1yvtvsordhM", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 2, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 1229.3092000000001, + "y": 905.4850333333333, + "direction": 2 + }, + "end": { + "tableId": "QCNA57Pi6A9dJDgybxS5v", + "columnIds": [ + "8mPFhDdUY8QLPvc8rNw1B" + ], + "x": 2314.4072, + "y": 828.0364999999999, + "direction": 1 + }, + "meta": { + "updateAt": 1755653280042, + "createAt": 1755653280042 + } + }, + "u_J2wFyhwkNzvwtpuwCLu": { + "id": "u_J2wFyhwkNzvwtpuwCLu", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 2, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 1229.3092000000001, + "y": 1052.1517, + "direction": 2 + }, + "end": { + "tableId": "B8haiEbPc1lRBWTv1g25G", + "columnIds": [ + "N-2m8O_JzS6-sDEcL5zTv" + ], + "x": 1526.2804, + "y": 1080.8582000000001, + "direction": 1 + }, + "meta": { + "updateAt": 1755653363963, + "createAt": 1755653363963 + } + }, + "S-DADUvespt-XHt1mSG1Q": { + "id": "S-DADUvespt-XHt1mSG1Q", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 2, + "start": { + "tableId": "B8haiEbPc1lRBWTv1g25G", + "columnIds": [ + "nNWsAWbHfKWqx8EwxvuM1" + ], + "x": 2179.2804, + "y": 1184.8582000000001, + "direction": 2 + }, + "end": { + "tableId": "QCNA57Pi6A9dJDgybxS5v", + "columnIds": [ + "vxhl-9RMNJ8zU9oqzEWo8" + ], + "x": 2314.4072, + "y": 950.7031666666666, + "direction": 1 + }, + "meta": { + "updateAt": 1755653412891, + "createAt": 1755653412891 + } + }, + "SNezubjRaJG8eo3XKux-v": { + "id": "SNezubjRaJG8eo3XKux-v", + "identification": false, + "relationshipType": 8, + "startRelationshipType": 2, + "start": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "RITMHZcQAJ7KvtxkTtMv-" + ], + "x": 740.179, + "y": 1639.8541, + "direction": 1 + }, + "end": { + "tableId": "IsMoJXzvtuoOFFt93qS0w", + "columnIds": [ + "GGL413h2VpSCaHyrCkWSA" + ], + "x": 587.893, + "y": 1555.8934, + "direction": 2 + }, + "meta": { + "updateAt": 1755653684946, + "createAt": 1755653684946 + } + }, + "6VC4ptgKReRmeDlXuKRN1": { + "id": "6VC4ptgKReRmeDlXuKRN1", + "identification": false, + "relationshipType": 8, + "startRelationshipType": 1, + "start": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "RITMHZcQAJ7KvtxkTtMv-" + ], + "x": 740.179, + "y": 1639.8541, + "direction": 1 + }, + "end": { + "tableId": "IsMoJXzvtuoOFFt93qS0w", + "columnIds": [ + "wi1XbZM3emknh42sOMkYq" + ], + "x": 601.893, + "y": 1555.8934, + "direction": 2 + }, + "meta": { + "updateAt": 1755653724845, + "createAt": 1755653724845 + } + }, + "xTe9A_4sfYrsFREUz7sNc": { + "id": "xTe9A_4sfYrsFREUz7sNc", + "identification": false, + "relationshipType": 8, + "startRelationshipType": 1, + "start": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "RITMHZcQAJ7KvtxkTtMv-" + ], + "x": 740.179, + "y": 1835.8541, + "direction": 1 + }, + "end": { + "tableId": "SEgsi7mbM-56Rsx5-qj8K", + "columnIds": [ + "GtBqjKsmtYWvsd0fckBc0" + ], + "x": 621.9303, + "y": 1884.3252, + "direction": 2 + }, + "meta": { + "updateAt": 1755653779890, + "createAt": 1755653779890 + } + }, + "5R5vlOrsoLSG-j2m2_dj2": { + "id": "5R5vlOrsoLSG-j2m2_dj2", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 1, + "start": { + "tableId": "B8haiEbPc1lRBWTv1g25G", + "columnIds": [ + "nNWsAWbHfKWqx8EwxvuM1" + ], + "x": 1526.2804, + "y": 1288.8582000000001, + "direction": 1 + }, + "end": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "4iRyOhmW3b7kbiZT8lQyY" + ], + "x": 1319.179, + "y": 1607.1874333333335, + "direction": 2 + }, + "meta": { + "updateAt": 1755653818593, + "createAt": 1755653818593 + } + }, + "sWc1LMcA0iFU_8byUhUnv": { + "id": "sWc1LMcA0iFU_8byUhUnv", + "identification": false, + "relationshipType": 8, + "startRelationshipType": 1, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 962.8092, + "y": 1272.1517, + "direction": 8 + }, + "end": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "JRdeV7n53lb1iSmmYnhHX" + ], + "x": 1029.679, + "y": 1541.8541, + "direction": 4 + }, + "meta": { + "updateAt": 1755653851900, + "createAt": 1755653851900 + } + }, + "UoS3Mvohv6zri0971LA1O": { + "id": "UoS3Mvohv6zri0971LA1O", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 1, + "start": { + "tableId": "6ajvOCaGuXU9pzV0Y9jEi", + "columnIds": [ + "V6BuLrtFrGgCWaHSUkSLb" + ], + "x": 1229.3092000000001, + "y": 1198.8183666666666, + "direction": 2 + }, + "end": { + "tableId": "ZLEpY5EjuZV21718zf-Y1", + "columnIds": [ + "60w6M5QqxGAvJa3EEMDbR" + ], + "x": 1514.7956, + "y": 1520.8948, + "direction": 1 + }, + "meta": { + "updateAt": 1755653938445, + "createAt": 1755653938445 + } + }, + "sXGbpO3Qip9Ed7NxK_Bdj": { + "id": "sXGbpO3Qip9Ed7NxK_Bdj", + "identification": false, + "relationshipType": 16, + "startRelationshipType": 1, + "start": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "RITMHZcQAJ7KvtxkTtMv-" + ], + "x": 1319.179, + "y": 1737.8541000000002, + "direction": 2 + }, + "end": { + "tableId": "ZLEpY5EjuZV21718zf-Y1", + "columnIds": [ + "QznZ6PY_T3OGj3YD4GdOX" + ], + "x": 1514.7956, + "y": 1680.8948, + "direction": 1 + }, + "meta": { + "updateAt": 1755653979090, + "createAt": 1755653979090 + } + }, + "-Cg-8t54mL4p_RVJqoVEC": { + "id": "-Cg-8t54mL4p_RVJqoVEC", + "identification": false, + "relationshipType": 8, + "startRelationshipType": 2, + "start": { + "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", + "columnIds": [ + "RITMHZcQAJ7KvtxkTtMv-" + ], + "x": 1319.179, + "y": 1868.520766666667, + "direction": 2 + }, + "end": { + "tableId": "8GYAVBvZGaMFeq3QuXk_B", + "columnIds": [ + "IbWdZlEEF70bGqUDkU5ub" + ], + "x": 1515.6117, + "y": 1934.3055, + "direction": 1 + }, + "meta": { + "updateAt": 1755654048878, + "createAt": 1755654048878 + } } }, "indexEntities": {}, diff --git a/app/Database/dbmsv2_init.sql b/app/Database/dbmsv2_init.sql index 5cfb6eb..879f824 100644 --- a/app/Database/dbmsv2_init.sql +++ b/app/Database/dbmsv2_init.sql @@ -25,7 +25,7 @@ DROP TABLE IF EXISTS `accountinfo`; CREATE TABLE `accountinfo` ( `uid` int(11) NOT NULL AUTO_INCREMENT, `user_uid` int(11) NOT NULL COMMENT '관리자정보', - `clientinfo_code` varchar(20) NOT NULL COMMENT '고객코드', + `clientinfo_uid` int(11) NOT NULL COMMENT '고객정보', `bank` int(11) NOT NULL COMMENT '은행', `title` varchar(255) NOT NULL COMMENT '사유', `alias` varchar(50) NOT NULL COMMENT '입출금자명', @@ -37,8 +37,8 @@ CREATE TABLE `accountinfo` ( `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`uid`), KEY `FK_user_TO_accountinfo` (`user_uid`), - KEY `FK_clientinfo_TO_accountinfo` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_accountinfo` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), + KEY `FK_clientinfo_TO_accountinfo` (`clientinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_accountinfo` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), CONSTRAINT `FK_user_TO_accountinfo` FOREIGN KEY (`user_uid`) REFERENCES `user` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='예치금계좌'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -60,8 +60,10 @@ DROP TABLE IF EXISTS `clientinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `clientinfo` ( - `code` varchar(20) NOT NULL COMMENT '고객코드', + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT '고객정보', `user_uid` int(11) NOT NULL COMMENT '관리자정보', + `code` varchar(20) NOT NULL COMMENT '고객코드', + `site` varchar(20) NOT NULL DEFAULT 'prime' COMMENT 'Site구분', `role` varchar(50) NOT NULL DEFAULT 'user', `name` varchar(100) NOT NULL, `phone` varchar(50) DEFAULT NULL, @@ -74,7 +76,8 @@ CREATE TABLE `clientinfo` ( `updated_at` timestamp NULL DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), `deleted_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`code`), + PRIMARY KEY (`uid`), + UNIQUE KEY `UQ_code` (`code`), UNIQUE KEY `UQ_name` (`name`), KEY `FK_user_TO_clientinfo` (`user_uid`), CONSTRAINT `FK_user_TO_clientinfo` FOREIGN KEY (`user_uid`) REFERENCES `user` (`uid`) @@ -100,7 +103,7 @@ DROP TABLE IF EXISTS `couponinfo`; CREATE TABLE `couponinfo` ( `uid` int(11) NOT NULL AUTO_INCREMENT, `user_uid` int(11) NOT NULL COMMENT '관리자정보', - `clientinfo_code` varchar(20) NOT NULL COMMENT '고객코드', + `clientinfo_uid` int(11) NOT NULL COMMENT '고객정보', `title` varchar(255) NOT NULL, `cnt` int(11) NOT NULL DEFAULT 0 COMMENT '갯수', `status` varchar(20) NOT NULL DEFAULT 'deposit', @@ -109,8 +112,8 @@ CREATE TABLE `couponinfo` ( `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`uid`), KEY `FK_user_TO_couponinfo` (`user_uid`), - KEY `FK_clientinfo_TO_couponinfo` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_couponinfo` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), + KEY `FK_clientinfo_TO_couponinfo` (`clientinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_couponinfo` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), CONSTRAINT `FK_user_TO_couponinfo` FOREIGN KEY (`user_uid`) REFERENCES `user` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='쿠폰정보'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -133,7 +136,7 @@ DROP TABLE IF EXISTS `csinfo`; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `csinfo` ( `uid` int(11) NOT NULL AUTO_INCREMENT, - `serverinfo_code` varchar(20) DEFAULT NULL COMMENT '서버코드', + `serverinfo_uid` int(11) DEFAULT NULL COMMENT '서버정보', `type` varchar(20) NOT NULL COMMENT '구분(KCS,VCS)', `ip` varchar(50) NOT NULL, `accountid` varchar(50) DEFAULT NULL, @@ -145,8 +148,8 @@ CREATE TABLE `csinfo` ( `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`uid`), UNIQUE KEY `UQ_ip` (`ip`), - KEY `FK_serverinfo_TO_csinfo` (`serverinfo_code`), - CONSTRAINT `FK_serverinfo_TO_csinfo` FOREIGN KEY (`serverinfo_code`) REFERENCES `serverinfo` (`code`) + KEY `FK_serverinfo_TO_csinfo` (`serverinfo_uid`), + CONSTRAINT `FK_serverinfo_TO_csinfo` FOREIGN KEY (`serverinfo_uid`) REFERENCES `serverinfo` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='CS정보(한서버 여러개 앞단 등록가능)'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -167,10 +170,10 @@ DROP TABLE IF EXISTS `ipinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `ipinfo` ( - `uid` int(11) NOT NULL AUTO_INCREMENT, + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT 'IP정보', `lineinfo_uid` int(11) NOT NULL COMMENT '회선정보', - `clientinfo_code` varchar(20) DEFAULT NULL COMMENT '고객코드(직전고객)', - `serverinfo_code` varchar(20) DEFAULT NULL COMMENT '서버코드', + `clientinfo_uid` int(11) DEFAULT NULL COMMENT '고객정보', + `serverinfo_uid` int(11) DEFAULT NULL COMMENT '서버정보', `ip` char(16) NOT NULL, `price` int(11) NOT NULL DEFAULT 0 COMMENT '기본금액', `history` text DEFAULT NULL COMMENT 'history', @@ -181,12 +184,12 @@ CREATE TABLE `ipinfo` ( PRIMARY KEY (`uid`), UNIQUE KEY `UQ_ip` (`ip`), KEY `FK_lineinfo_TO_ipinfo` (`lineinfo_uid`), - KEY `FK_serverinfo_TO_ipinfo` (`serverinfo_code`), - KEY `FK_clientinfo_TO_ipinfo` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_ipinfo` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), + KEY `FK_clientinfo_TO_ipinfo` (`clientinfo_uid`), + KEY `FK_serverinfo_TO_ipinfo` (`serverinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_ipinfo` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), CONSTRAINT `FK_lineinfo_TO_ipinfo` FOREIGN KEY (`lineinfo_uid`) REFERENCES `lineinfo` (`uid`), - CONSTRAINT `FK_serverinfo_TO_ipinfo` FOREIGN KEY (`serverinfo_code`) REFERENCES `serverinfo` (`code`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT=' IP 정보'; + CONSTRAINT `FK_serverinfo_TO_ipinfo` FOREIGN KEY (`serverinfo_uid`) REFERENCES `serverinfo` (`uid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT=' IP정보'; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -206,7 +209,7 @@ DROP TABLE IF EXISTS `lineinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `lineinfo` ( - `uid` int(11) NOT NULL AUTO_INCREMENT, + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT '회선정보', `type` varchar(20) NOT NULL COMMENT '회선구분', `title` varchar(100) NOT NULL, `bandwith` varchar(20) NOT NULL COMMENT 'IP 대역', @@ -218,7 +221,7 @@ CREATE TABLE `lineinfo` ( `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`uid`), UNIQUE KEY `UQ_title` (`title`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='회선 정보'; +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='회선정보'; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -238,7 +241,7 @@ DROP TABLE IF EXISTS `partinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `partinfo` ( - `uid` int(11) NOT NULL AUTO_INCREMENT, + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT 'PART정보', `type` enum('CPU','RAM','DISK','SOFTWARE') NOT NULL COMMENT '형식', `title` varchar(50) NOT NULL, `price` int(11) NOT NULL DEFAULT 0 COMMENT '기본금액', @@ -270,8 +273,8 @@ DROP TABLE IF EXISTS `payment`; CREATE TABLE `payment` ( `uid` int(11) NOT NULL AUTO_INCREMENT, `user_uid` int(11) NOT NULL COMMENT '관리자정보', - `clientinfo_code` varchar(20) NOT NULL COMMENT '고객코드', - `serviceinfo_code` varchar(20) NOT NULL COMMENT '서비스코드', + `clientinfo_uid` int(11) NOT NULL COMMENT '고객정보', + `serviceinfo_uid` int(11) NOT NULL COMMENT '서비스정보', `title` varchar(50) NOT NULL COMMENT '청구 내용(제품명)', `amount` int(11) NOT NULL DEFAULT 0 COMMENT '청구금액', `billing_method` varchar(20) NOT NULL COMMENT '청구방법(month,onetime)', @@ -283,10 +286,10 @@ CREATE TABLE `payment` ( `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`uid`), KEY `FK_user_TO_payment` (`user_uid`), - KEY `FK_serviceinfo_TO_payment` (`serviceinfo_code`), - KEY `FK_clientinfo_TO_payment` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_payment` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), - CONSTRAINT `FK_serviceinfo_TO_payment` FOREIGN KEY (`serviceinfo_code`) REFERENCES `serviceinfo` (`code`), + KEY `FK_clientinfo_TO_payment` (`clientinfo_uid`), + KEY `FK_serviceinfo_TO_payment` (`serviceinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_payment` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), + CONSTRAINT `FK_serviceinfo_TO_payment` FOREIGN KEY (`serviceinfo_uid`) REFERENCES `serviceinfo` (`uid`), CONSTRAINT `FK_user_TO_payment` FOREIGN KEY (`user_uid`) REFERENCES `user` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='결제정보'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -310,7 +313,7 @@ DROP TABLE IF EXISTS `pointinfo`; CREATE TABLE `pointinfo` ( `uid` int(11) NOT NULL AUTO_INCREMENT, `user_uid` int(11) NOT NULL COMMENT '관리자정보', - `clientinfo_code` varchar(20) NOT NULL COMMENT '고객코드', + `clientinfo_uid` int(11) NOT NULL COMMENT '고객정보', `title` varchar(255) NOT NULL, `amount` int(11) NOT NULL DEFAULT 0 COMMENT '포인트액', `status` varchar(20) NOT NULL DEFAULT 'deposit', @@ -319,8 +322,8 @@ CREATE TABLE `pointinfo` ( `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`uid`), KEY `FK_user_TO_pointinfo` (`user_uid`), - KEY `FK_clientinfo_TO_pointinfo` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_pointinfo` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), + KEY `FK_clientinfo_TO_pointinfo` (`clientinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_pointinfo` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), CONSTRAINT `FK_user_TO_pointinfo` FOREIGN KEY (`user_uid`) REFERENCES `user` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='포인트정보'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -342,9 +345,10 @@ DROP TABLE IF EXISTS `serverinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `serverinfo` ( + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT '서버정보', + `clientinfo_uid` int(11) DEFAULT NULL COMMENT '고객정보', + `serviceinfo_uid` int(11) DEFAULT NULL COMMENT '서비스정보', `code` varchar(20) NOT NULL COMMENT '서버코드', - `clientinfo_code` varchar(20) DEFAULT NULL COMMENT '고객코드(소유주)', - `serviceinfo_code` varchar(20) DEFAULT NULL COMMENT '서비스코드', `type` varchar(20) NOT NULL COMMENT '구분(밴더등)', `title` varchar(50) NOT NULL, `price` int(11) NOT NULL DEFAULT 0 COMMENT '기본금액', @@ -355,11 +359,12 @@ CREATE TABLE `serverinfo` ( `updated_at` timestamp NULL DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), `deleted_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`code`), - KEY `FK_serviceinfo_TO_serverinfo` (`serviceinfo_code`), - KEY `FK_clientinfo_TO_serverinfo` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_serverinfo` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), - CONSTRAINT `FK_serviceinfo_TO_serverinfo` FOREIGN KEY (`serviceinfo_code`) REFERENCES `serviceinfo` (`code`) + PRIMARY KEY (`uid`), + UNIQUE KEY `UQ_code` (`code`), + KEY `FK_serviceinfo_TO_serverinfo` (`serviceinfo_uid`), + KEY `FK_clientinfo_TO_serverinfo` (`clientinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_serverinfo` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), + CONSTRAINT `FK_serviceinfo_TO_serverinfo` FOREIGN KEY (`serviceinfo_uid`) REFERENCES `serviceinfo` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='서버정보'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -381,18 +386,18 @@ DROP TABLE IF EXISTS `serverinfo_partinfo`; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `serverinfo_partinfo` ( `uid` int(11) NOT NULL AUTO_INCREMENT, - `serverinfo_code` varchar(20) NOT NULL COMMENT '서버코드', - `partinfo_uid` int(11) NOT NULL COMMENT 'part정보', + `serverinfo_uid` int(11) NOT NULL COMMENT '서버정보', + `partinfo_uid` int(11) NOT NULL COMMENT 'PART정보', `billing_method` varchar(20) NOT NULL COMMENT '청구방법(month,onetime)', `cnt` tinyint(4) NOT NULL DEFAULT 1 COMMENT '갯수', `extra` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '추가정보(RAID등)', `updated_at` timestamp NULL DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), PRIMARY KEY (`uid`), - KEY `FK_serverinfo_TO_serverinfo_partinfo` (`serverinfo_code`), KEY `FK_partinfo_TO_serverinfo_partinfo` (`partinfo_uid`), + KEY `FK_serverinfo_TO_serverinfo_partinfo` (`serverinfo_uid`), CONSTRAINT `FK_partinfo_TO_serverinfo_partinfo` FOREIGN KEY (`partinfo_uid`) REFERENCES `partinfo` (`uid`), - CONSTRAINT `FK_serverinfo_TO_serverinfo_partinfo` FOREIGN KEY (`serverinfo_code`) REFERENCES `serverinfo` (`code`) + CONSTRAINT `FK_serverinfo_TO_serverinfo_partinfo` FOREIGN KEY (`serverinfo_uid`) REFERENCES `serverinfo` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='서버정보_part정보(CASECADE)'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -413,9 +418,10 @@ DROP TABLE IF EXISTS `serviceinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `serviceinfo` ( - `code` varchar(20) NOT NULL COMMENT '서비스코드', + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT '서비스정보', `user_uid` int(11) NOT NULL COMMENT '관리자정보', - `clientinfo_code` varchar(20) NOT NULL COMMENT '고객코드', + `clientinfo_uid` int(11) NOT NULL COMMENT '고객정보', + `code` varchar(20) NOT NULL COMMENT '서비스코드', `type` varchar(20) NOT NULL COMMENT '서비스형식((일반, 자사,코로케이션 등)', `location` varchar(20) DEFAULT NULL COMMENT '지역코드(chiba,tokyo,3center등)', `billing_at` date NOT NULL COMMENT '청구일', @@ -427,10 +433,11 @@ CREATE TABLE `serviceinfo` ( `updated_at` timestamp NULL DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), `deleted_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`code`), + PRIMARY KEY (`uid`), + UNIQUE KEY `UQ_code` (`code`), KEY `FK_user_TO_serviceinfo` (`user_uid`), - KEY `FK_clientinfo_TO_serviceinfo` (`clientinfo_code`), - CONSTRAINT `FK_clientinfo_TO_serviceinfo` FOREIGN KEY (`clientinfo_code`) REFERENCES `clientinfo` (`code`), + KEY `FK_clientinfo_TO_serviceinfo` (`clientinfo_uid`), + CONSTRAINT `FK_clientinfo_TO_serviceinfo` FOREIGN KEY (`clientinfo_uid`) REFERENCES `clientinfo` (`uid`), CONSTRAINT `FK_user_TO_serviceinfo` FOREIGN KEY (`user_uid`) REFERENCES `user` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='서비스정보'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -452,15 +459,17 @@ DROP TABLE IF EXISTS `switchinfo`; /*!40101 SET @saved_cs_client = @@character_set_client */; /*!40101 SET character_set_client = utf8 */; CREATE TABLE `switchinfo` ( + `uid` int(11) NOT NULL AUTO_INCREMENT COMMENT '스위치정보', + `serverinfo_uid` int(11) DEFAULT NULL COMMENT '서버정보', `code` varchar(20) NOT NULL COMMENT 'switch코드', - `serverinfo_code` varchar(20) DEFAULT NULL COMMENT '서버코드', `status` varchar(20) NOT NULL DEFAULT 'available', `updated_at` timestamp NULL DEFAULT NULL, `created_at` timestamp NOT NULL DEFAULT current_timestamp(), `deleted_at` timestamp NULL DEFAULT NULL, - PRIMARY KEY (`code`), - KEY `FK_serverinfo_TO_switchinfo` (`serverinfo_code`), - CONSTRAINT `FK_serverinfo_TO_switchinfo` FOREIGN KEY (`serverinfo_code`) REFERENCES `serverinfo` (`code`) + PRIMARY KEY (`uid`), + UNIQUE KEY `UQ_code` (`code`), + KEY `FK_serverinfo_TO_switchinfo` (`serverinfo_uid`), + CONSTRAINT `FK_serverinfo_TO_switchinfo` FOREIGN KEY (`serverinfo_uid`) REFERENCES `serverinfo` (`uid`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='스위치정보'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -548,4 +557,4 @@ UNLOCK TABLES; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; --- Dump completed on 2025-08-19 17:54:30 +-- Dump completed on 2025-08-20 11:06:56 diff --git a/app/Entities/Customer/CustomerEntity.php b/app/Entities/Customer/CustomerEntity.php index 1eed03d..84a998a 100644 --- a/app/Entities/Customer/CustomerEntity.php +++ b/app/Entities/Customer/CustomerEntity.php @@ -13,6 +13,6 @@ abstract class CustomerEntity extends CommonEntity //고객정보객체 final public function getClientUID(): int { - return intval($this->attributes['clientinfo_code']); + return intval($this->attributes['clientinfo_uid']); } } diff --git a/app/Entities/Customer/PaymentEntity.php b/app/Entities/Customer/PaymentEntity.php index 6c72f8f..809c026 100644 --- a/app/Entities/Customer/PaymentEntity.php +++ b/app/Entities/Customer/PaymentEntity.php @@ -19,11 +19,11 @@ class PaymentEntity extends CustomerEntity } final public function getClientCode(): int { - return intval($this->attributes['clientinfo_code']); + return intval($this->attributes['clientinfo_uid']); } final public function getServiceCode(): int { - return intval($this->attributes['serviceinfo_code']); + return intval($this->attributes['serviceinfo_uid']); } //타 객체정의 부분 public function getItemType(): string diff --git a/app/Helpers/CommonHelper.php b/app/Helpers/CommonHelper.php index 86f0c62..d62a5b2 100644 --- a/app/Helpers/CommonHelper.php +++ b/app/Helpers/CommonHelper.php @@ -269,7 +269,7 @@ class CommonHelper $extras['class'] = array_key_exists('class', $extras) ? $extras['class'] . ' tinymce' : 'tinymce'; $form = form_textarea($field, $value ?? "", ['id' => $field, ...$extras]); break; - case 'clientinfo_code': + case 'clientinfo_uid': case 'user_uid': $extras['class'] = array_key_exists('class', $extras) ? $extras['class'] . ' select-field' : 'select-field'; $form = $this->form_dropdown_disabled($field, $value, $viewDatas['control']['filter_optons'][$field], $extras); diff --git a/app/Helpers/Customer/ClientHelper.php b/app/Helpers/Customer/ClientHelper.php index 43c6ffe..8a4ba04 100644 --- a/app/Helpers/Customer/ClientHelper.php +++ b/app/Helpers/Customer/ClientHelper.php @@ -24,7 +24,7 @@ class ClientHelper extends CustomerHelper number_format(intval($value)) . "원", 'index', [ - "data-src" => "/admin/customer/account?clientinfo_code={$viewDatas['entity']->getPK()}&ActionTemplate=popup", + "data-src" => "/admin/customer/account?clientinfo_uid={$viewDatas['entity']->getPK()}&ActionTemplate=popup", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", ...$extras @@ -37,7 +37,7 @@ class ClientHelper extends CustomerHelper number_format(intval($value)) . "개", 'index', [ - "data-src" => "/admin/customer/coupon?clientinfo_code={$viewDatas['entity']->getPK()}&ActionTemplate=popup", + "data-src" => "/admin/customer/coupon?clientinfo_uid={$viewDatas['entity']->getPK()}&ActionTemplate=popup", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", ...$extras @@ -50,7 +50,7 @@ class ClientHelper extends CustomerHelper number_format(intval($value)) . "원", 'index', [ - "data-src" => "/admin/customer/point?clientinfo_code={$viewDatas['entity']->getPK()}&ActionTemplate=popup", + "data-src" => "/admin/customer/point?clientinfo_uid={$viewDatas['entity']->getPK()}&ActionTemplate=popup", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", ...$extras @@ -89,7 +89,7 @@ class ClientHelper extends CustomerHelper ICONS['HISTORY'], $action, [ - "data-src" => "/admin/customer/clienthistory?clientinfo_code={$viewDatas['entity']->getPK()}", + "data-src" => "/admin/customer/clienthistory?clientinfo_uid={$viewDatas['entity']->getPK()}", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", ...$extras diff --git a/app/Helpers/Customer/PaymentHelper.php b/app/Helpers/Customer/PaymentHelper.php index 923e58c..faf950f 100644 --- a/app/Helpers/Customer/PaymentHelper.php +++ b/app/Helpers/Customer/PaymentHelper.php @@ -22,8 +22,8 @@ class PaymentHelper extends CustomerHelper //ItemType에 따라 필터옵션에서 Title을 가져옴 $value = $viewDatas['control']['filter_optons'][$viewDatas['entity']->getItemType()][$value]->getTitle(); break; - case 'serviceinfo_code': - case 'clientinfo_code': + case 'serviceinfo_uid': + case 'clientinfo_uid': case 'billing_method': $value = array_key_exists($value, $viewDatas['control']['filter_optons'][$field]) && $viewDatas['control']['filter_optons'][$field][$value] ? $viewDatas['control']['filter_optons'][$field][$value]->getTitle() : ""; break; diff --git a/app/Helpers/Customer/ServiceHelper.php b/app/Helpers/Customer/ServiceHelper.php index 15b5957..bc31fb5 100644 --- a/app/Helpers/Customer/ServiceHelper.php +++ b/app/Helpers/Customer/ServiceHelper.php @@ -30,7 +30,7 @@ class ServiceHelper extends CustomerHelper ICONS['SETUP'], $field, [ - "data-src" => "/admin/customer/serviceitem?serviceinfo_code={$viewDatas['entity']->getPK()}&item_type={$field}", + "data-src" => "/admin/customer/serviceitem?serviceinfo_uid={$viewDatas['entity']->getPK()}&item_type={$field}", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", ...$extras @@ -59,14 +59,14 @@ class ServiceHelper extends CustomerHelper public function getFieldView(string $field, mixed $value, array $viewDatas, array $extras = []): string|null { switch ($field) { - case 'clientinfo_code': + case 'clientinfo_uid': case 'ownerinfo_uid': $temp = parent::getFieldForm($field, $value, $viewDatas, $extras); $value = $temp . form_label( ICONS['HISTORY'], 'client_history', [ - "data-src" => "/admin/customer/clienthistory?clientinfo_code={$value}", + "data-src" => "/admin/customer/clienthistory?clientinfo_uid={$value}", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", "class" => "btn btn-outline btn-primary btn-circle", @@ -127,7 +127,7 @@ class ServiceHelper extends CustomerHelper $label ? $label : ICONS['HISTORY'], $action, [ - "data-src" => "/admin/customer/servicehistory?serviceinfo_code={$viewDatas['entity']->getPK()}", + "data-src" => "/admin/customer/servicehistory?serviceinfo_uid={$viewDatas['entity']->getPK()}", "data-bs-toggle" => "modal", "data-bs-target" => "#index_action_form", ...$extras diff --git a/app/Helpers/Equipment/PartHelper.php b/app/Helpers/Equipment/PartHelper.php new file mode 100644 index 0000000..aba7294 --- /dev/null +++ b/app/Helpers/Equipment/PartHelper.php @@ -0,0 +1,14 @@ +setTitleField(field: PartModel::TITLE); + } +} diff --git a/app/Language/en/Customer/Account.php b/app/Language/en/Customer/Account.php index cc93ced..c0ce6fa 100644 --- a/app/Language/en/Customer/Account.php +++ b/app/Language/en/Customer/Account.php @@ -2,7 +2,7 @@ return [ 'title' => "고객예치금", 'label' => [ - 'clientinfo_code' => "고객명", + 'clientinfo_uid' => "고객명", 'title' => "제목", 'alias' => "입/출금자명", 'amount' => "금액", diff --git a/app/Language/en/Customer/Coupon.php b/app/Language/en/Customer/Coupon.php index 74a4ed1..603125c 100644 --- a/app/Language/en/Customer/Coupon.php +++ b/app/Language/en/Customer/Coupon.php @@ -2,7 +2,7 @@ return [ 'title' => "고객쿠폰", 'label' => [ - 'clientinfo_code' => "고객명", + 'clientinfo_uid' => "고객명", 'title' => "제목", 'amount' => "갯수", 'status' => "추가/사용", diff --git a/app/Language/en/Customer/Payment.php b/app/Language/en/Customer/Payment.php index 73dfc1a..0e42159 100644 --- a/app/Language/en/Customer/Payment.php +++ b/app/Language/en/Customer/Payment.php @@ -3,8 +3,8 @@ return [ 'title' => "서비스결제정보", 'label' => [ 'user_uid' => "관리자", - 'clientinfo_code' => "고객", - 'serviceinfo_code' => "서비스", + 'clientinfo_uid' => "고객", + 'serviceinfo_uid' => "서비스", 'amount' => "청구금액", 'billing_method' => "청구방법", 'billing_at' => "지급기한일", diff --git a/app/Language/en/Customer/Point.php b/app/Language/en/Customer/Point.php index 7218ccc..15aba39 100644 --- a/app/Language/en/Customer/Point.php +++ b/app/Language/en/Customer/Point.php @@ -2,7 +2,7 @@ return [ 'title' => "고객포인트", 'label' => [ - 'clientinfo_code' => "고객명", + 'clientinfo_uid' => "고객명", 'title' => "제목", 'amount' => "금액", 'status' => "입/출금", diff --git a/app/Language/en/Customer/Service.php b/app/Language/en/Customer/Service.php index 3e6c281..573b466 100644 --- a/app/Language/en/Customer/Service.php +++ b/app/Language/en/Customer/Service.php @@ -3,8 +3,8 @@ return [ 'title' => "서비스정보", 'label' => [ 'user_uid' => "관리자", - 'clientinfo_code' => "고객", - 'serverinfo_code' => "서버", + 'clientinfo_uid' => "고객", + 'serverinfo_uid' => "서버", 'type' => "서비스형식", 'location' => "위치", 'billing_at' => "결제일", diff --git a/app/Language/en/Equipment/Ip.php b/app/Language/en/Equipment/Ip.php index 84fcbd2..12087ef 100644 --- a/app/Language/en/Equipment/Ip.php +++ b/app/Language/en/Equipment/Ip.php @@ -3,8 +3,8 @@ return [ 'title' => "IP정보", 'label' => [ 'lineinfo_uid' => '회선정보', - 'clientinfo_code' => '(이전)고객정보', - 'serverinfo_code' => '서버정보', + 'clientinfo_uid' => '(이전)고객정보', + 'serverinfo_uid' => '서버정보', 'ip' => "IP", 'price' => "소비자금액", 'amount' => "서비스금액", diff --git a/app/Language/en/Equipment/Part.php b/app/Language/en/Equipment/Part.php new file mode 100644 index 0000000..854e2af --- /dev/null +++ b/app/Language/en/Equipment/Part.php @@ -0,0 +1,23 @@ + "부품정보", + 'label' => [ + 'type' => "종류", + 'title' => "모델명", + 'price' => "금액", + 'status' => "상태", + 'updated_at' => "수정일", + 'created_at' => "작성일", + 'deleted_at' => "삭제일", + ], + "TYPE" => [ + "CPU" => "CPU", + "RAM" => "RAM", + "DISK" => "DISK", + "SOFTWARE" => "SOFTWARE", + ], + "STATUS" => [ + 'available' => "사용가능", + 'forbidden' => "사용불가", + ], +]; diff --git a/app/Language/en/Equipment/Server.php b/app/Language/en/Equipment/Server.php index 1de3317..c0d4efd 100644 --- a/app/Language/en/Equipment/Server.php +++ b/app/Language/en/Equipment/Server.php @@ -2,8 +2,8 @@ return [ 'title' => "서버장비정보", 'label' => [ - 'clientinfo_code' => "고객번호", - 'serviceinfo_code' => "서비스번호", + 'clientinfo_uid' => "고객번호", + 'serviceinfo_uid' => "서비스번호", 'code' => "장비번호", 'type' => "장비종류", 'title' => "장비명", diff --git a/app/Models/Customer/AccountModel.php b/app/Models/Customer/AccountModel.php index 7afe255..802be0e 100644 --- a/app/Models/Customer/AccountModel.php +++ b/app/Models/Customer/AccountModel.php @@ -13,7 +13,7 @@ class AccountModel extends CustomerModel protected $primaryKey = self::PK; protected $returnType = AccountEntity::class; protected $allowedFields = [ - "clientinfo_code", + "clientinfo_uid", "status", "alias", "title", @@ -30,7 +30,7 @@ class AccountModel extends CustomerModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case "clientinfo_code": + case "clientinfo_uid": case "amount": $rule = "required|numeric"; break; diff --git a/app/Models/Customer/ClientModel.php b/app/Models/Customer/ClientModel.php index 0cee11c..f4137f4 100644 --- a/app/Models/Customer/ClientModel.php +++ b/app/Models/Customer/ClientModel.php @@ -7,12 +7,14 @@ use App\Entities\Customer\ClientEntity; class ClientModel extends CustomerModel { const TABLE = "clientinfo"; - const PK = "code"; + const PK = "uid"; const TITLE = "name"; protected $table = self::TABLE; + // protected $useAutoIncrement = false; protected $primaryKey = self::PK; protected $returnType = ClientEntity::class; protected $allowedFields = [ + "site", "code", "name", "email", @@ -34,14 +36,15 @@ class ClientModel extends CustomerModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case $this->getPKField(): - $rule = "required|trim|min_length[4]|max_length[20]"; + case "code": + $rule = "required|trim|alpha_numeric|min_length[4]|max_length[20]"; $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; break; case "name": $rule = "required|trim|string"; $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; break; + case "site": case "role": $rule = "required|trim|string"; break; @@ -59,12 +62,12 @@ class ClientModel extends CustomerModel } return $rule; } - + //입력후 코드처리 protected function create_process(array $formDatas): ClientEntity { $entity = parent::create_process($formDatas); // 생성 후, 추가 작업이 필요할 경우 여기에 작성 - $formDatas = ['code' => SITE_PREFIX['Client'] . $entity->getPK()]; + $formDatas = ['code' => SITE_PREFIX[$formDatas['site']] . $entity->getPK()]; return $this->modify($entity, $formDatas); } } diff --git a/app/Models/Customer/CouponModel.php b/app/Models/Customer/CouponModel.php index aa05167..96beb69 100644 --- a/app/Models/Customer/CouponModel.php +++ b/app/Models/Customer/CouponModel.php @@ -13,7 +13,7 @@ class CouponModel extends CustomerModel protected $primaryKey = self::PK; protected $returnType = CouponEntity::class; protected $allowedFields = [ - "clientinfo_code", + "clientinfo_uid", "status", "title", "amount", @@ -29,7 +29,7 @@ class CouponModel extends CustomerModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case "clientinfo_code": + case "clientinfo_uid": case "amount": $rule = "required|numeric"; break; diff --git a/app/Models/Customer/PaymentModel.php b/app/Models/Customer/PaymentModel.php index 3039683..92a35e6 100644 --- a/app/Models/Customer/PaymentModel.php +++ b/app/Models/Customer/PaymentModel.php @@ -15,8 +15,8 @@ class PaymentModel extends CustomerModel protected $returnType = PaymentEntity::class; protected $allowedFields = [ "user_uid", - "clientinfo_code", - "serviceinfo_code", + "clientinfo_uid", + "serviceinfo_uid", "title", "amount", "billing_method", @@ -41,8 +41,8 @@ class PaymentModel extends CustomerModel break; case "title": case "billing_method": - case "clientinfo_code": - case "serviceinfo_code": + case "clientinfo_uid": + case "serviceinfo_uid": $rule = "required|trim|string"; break; case "billing_at": diff --git a/app/Models/Customer/PointModel.php b/app/Models/Customer/PointModel.php index b695005..faa32a2 100644 --- a/app/Models/Customer/PointModel.php +++ b/app/Models/Customer/PointModel.php @@ -13,7 +13,7 @@ class PointModel extends CustomerModel protected $primaryKey = self::PK; protected $returnType = PointEntity::class; protected $allowedFields = [ - "clientinfo_code", + "clientinfo_uid", "status", "title", "amount", @@ -29,7 +29,7 @@ class PointModel extends CustomerModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case "clientinfo_code": + case "clientinfo_uid": case "amount": $rule = "required|numeric"; break; diff --git a/app/Models/Customer/ServiceModel.php b/app/Models/Customer/ServiceModel.php index c9695c7..5813b0a 100644 --- a/app/Models/Customer/ServiceModel.php +++ b/app/Models/Customer/ServiceModel.php @@ -3,19 +3,21 @@ namespace App\Models\Customer; use App\Entities\Customer\ServiceEntity; +use tidy; class ServiceModel extends CustomerModel { const TABLE = "serviceinfo"; - const PK = "uid"; + const PK = "code"; const TITLE = "code"; protected $table = self::TABLE; + // protected $useAutoIncrement = false; protected $primaryKey = self::PK; protected $returnType = ServiceEntity::class; protected $allowedFields = [ "user_uid", - "clientinfo_code", - "serverinfo_code", + "clientinfo_uid", + "code", "type", "location", "billing_at", @@ -23,7 +25,6 @@ class ServiceModel extends CustomerModel "start_at", "end_at", "status", - "updated_at" ]; public function __construct() { @@ -35,12 +36,15 @@ class ServiceModel extends CustomerModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { + case $this->getPKField(): + $rule = "required|trim|alpha_numeric|min_length[4]|max_length[20]"; + $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; + break; case "user_uid": - case "serverinfo_code": case "amount": $rule = "required|numeric"; break; - case "clientinfo_code": + case "clientinfo_uid": case "type": case "location": case "status": @@ -59,12 +63,10 @@ class ServiceModel extends CustomerModel } return $rule; } - //Create용 + //입력전 코드처리 protected function create_process(array $formDatas): ServiceEntity { - $entity = parent::create_process($formDatas); - // 생성 후, 추가 작업이 필요할 경우 여기에 작성 - $formDatas = ['code' => SITE_PREFIX['Service'] . time()]; - return $this->modify($entity, $formDatas); + $formDatas['code'] = "s" . time(); + return parent::create_process($formDatas); } } diff --git a/app/Models/Equipment/CSModel.php b/app/Models/Equipment/CSModel.php index 0012230..714ba05 100644 --- a/app/Models/Equipment/CSModel.php +++ b/app/Models/Equipment/CSModel.php @@ -18,9 +18,7 @@ class CSModel extends EquipmentModel "accountid", "domain", "price", - "amount", "status", - "updated_at" ]; public function __construct() { @@ -32,10 +30,6 @@ class CSModel extends EquipmentModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case "model": - $rule = "required|trim|string"; - $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; - break; case "type": $rule = "required|trim|string"; break; @@ -44,9 +38,11 @@ class CSModel extends EquipmentModel $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; break; case "price": - case "amount": $rule = "required|numeric"; break; + case "domain": + $rule = "if_exist|trim|string"; + break; default: $rule = parent::getFormFieldRule($action, $field); break; diff --git a/app/Models/Equipment/IpModel.php b/app/Models/Equipment/IpModel.php index a33634d..c3fe82d 100644 --- a/app/Models/Equipment/IpModel.php +++ b/app/Models/Equipment/IpModel.php @@ -14,8 +14,8 @@ class IpModel extends EquipmentModel protected $returnType = IpEntity::class; protected $allowedFields = [ "lineinfo_uid", - "clientinfo_code", - "serverinfo_code", + "clientinfo_uid", + "serverinfo_uid", "ip", "price", "amount", @@ -36,8 +36,8 @@ class IpModel extends EquipmentModel case "lineinfo_uid": $rule = "required|numeric"; break; - case "clientinfo_code": - case "serverinfo_code": + case "clientinfo_uid": + case "serverinfo_uid": case "history": $rule = "if_exist|trim|string"; break; diff --git a/app/Models/Equipment/PartModel.php b/app/Models/Equipment/PartModel.php index de037eb..ed6da59 100644 --- a/app/Models/Equipment/PartModel.php +++ b/app/Models/Equipment/PartModel.php @@ -11,7 +11,9 @@ class PartModel extends EquipmentModel const TITLE = "title"; protected $table = self::TABLE; protected $primaryKey = self::PK; + protected $returnType = PartEntity::class; protected $allowedFields = [ + "type", "title", "price", "status", @@ -19,7 +21,6 @@ class PartModel extends EquipmentModel public function __construct() { parent::__construct(); - $this->returnType = PartEntity::class; } final public function getFormFieldRule(string $action, string $field): string { @@ -27,10 +28,14 @@ class PartModel extends EquipmentModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case "model": + case "title": $rule = "required|trim|string"; $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; break; + case "type": + case "status": + $rule = "required|trim|string"; + break; case "price": $rule = "required|numeric"; break; diff --git a/app/Models/Equipment/ServerModel.php b/app/Models/Equipment/ServerModel.php index c98b4f9..a7c122e 100644 --- a/app/Models/Equipment/ServerModel.php +++ b/app/Models/Equipment/ServerModel.php @@ -7,15 +7,22 @@ use App\Entities\Equipment\ServerEntity; class ServerModel extends EquipmentModel { const TABLE = "serverinfo"; - const PK = "code"; + const PK = "uid"; const TITLE = "title"; protected $table = self::TABLE; + // protected $useAutoIncrement = false; protected $primaryKey = self::PK; protected $returnType = ServerEntity::class; protected $allowedFields = [ + "clientinfo_uid", + "serviceinfo_uid", + "code", + "type", "title", + "price", + "manufactur_at", + "format_at", "status", - "updated_at" ]; public function __construct() { @@ -27,10 +34,14 @@ class ServerModel extends EquipmentModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case $this->getPKField(): - $rule = "required|trim|min_length[4]|max_length[20]"; + case "code": + $rule = "required|trim|alpha_numeric|min_length[4]|max_length[20]"; $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; break; + case "type": + case "status": + $rule = "required|trim|string"; + break; case "title": $rule = "required|trim|string"; $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; @@ -38,6 +49,12 @@ class ServerModel extends EquipmentModel case "price": $rule = "required|numeric"; break; + case "manufactur_at": + $rule = "required|valid_date"; + break; + case "format_at": + $rule = "if_exist|valid_date"; + break; default: $rule = parent::getFormFieldRule($action, $field); break; diff --git a/app/Models/Equipment/SwitchModel.php b/app/Models/Equipment/SwitchModel.php index 332a3d9..1770e2a 100644 --- a/app/Models/Equipment/SwitchModel.php +++ b/app/Models/Equipment/SwitchModel.php @@ -7,17 +7,16 @@ use App\Entities\Equipment\SwitchEntity; class SwitchModel extends EquipmentModel { const TABLE = "switchinfo"; - const PK = "code"; + const PK = "uid"; const TITLE = "code"; protected $table = self::TABLE; protected $primaryKey = self::PK; - protected $useAutoIncrement = false; + // protected $useAutoIncrement = false; protected $returnType = SwitchEntity::class; protected $allowedFields = [ "code", - "serverinfo__code", + "serverinfo_uid", "status", - "updated_at" ]; public function __construct() { @@ -29,8 +28,8 @@ class SwitchModel extends EquipmentModel throw new \Exception(__FUNCTION__ . "=> field가 array 입니다.\n" . var_export($field, true)); } switch ($field) { - case $this->getPKField(): - $rule = "required|trim|min_length[4]|max_length[20]"; + case "code": + $rule = "required|trim|alpha_numeric|min_length[4]|max_length[20]"; $rule .= in_array($action, ["create", "create_form"]) ? "|is_unique[{$this->table}.{$field}]" : ""; break; case "status": diff --git a/app/Services/CommonService.php b/app/Services/CommonService.php index a2cd6df..088f712 100644 --- a/app/Services/CommonService.php +++ b/app/Services/CommonService.php @@ -77,7 +77,7 @@ abstract class CommonService throw new \Exception($message); } } - protected function findAllDatas_process(array $columns = ['*']): mixed + protected function findAllDatas_process(array $columns = ['*']): array { $entities = $this->getModel()->select(implode(',', $columns))->findAll(); // dd($entities); diff --git a/app/Services/Customer/AccountService.php b/app/Services/Customer/AccountService.php index 23dc1f5..f99251a 100644 --- a/app/Services/Customer/AccountService.php +++ b/app/Services/Customer/AccountService.php @@ -16,7 +16,7 @@ class AccountService extends CustomerService public function getFormFields(): array { return [ - "clientinfo_code", + "clientinfo_uid", "status", "alias", "title", @@ -25,7 +25,7 @@ class AccountService extends CustomerService } public function getFilterFields(): array { - return ["clientinfo_code", 'status']; + return ["clientinfo_uid", 'status']; } public function getBatchJobFields(): array { @@ -37,9 +37,9 @@ class AccountService extends CustomerService private function setBalance(array $formDatas): void { //account_balance 체크 - $entity = $this->getClientService()->getEntity($formDatas['clientinfo_code']); + $entity = $this->getClientService()->getEntity($formDatas['clientinfo_uid']); if (!$entity) { - throw new \Exception("{$formDatas['clientinfo_code']}에 대한 고객정보를 찾을수 없습니다."); + throw new \Exception("{$formDatas['clientinfo_uid']}에 대한 고객정보를 찾을수 없습니다."); } $amount = intval($formDatas['amount']); // dd($formDatas); diff --git a/app/Services/Customer/CouponService.php b/app/Services/Customer/CouponService.php index 0821cb6..ed25070 100644 --- a/app/Services/Customer/CouponService.php +++ b/app/Services/Customer/CouponService.php @@ -16,7 +16,7 @@ class CouponService extends CustomerService public function getFormFields(): array { return [ - "clientinfo_code", + "clientinfo_uid", "status", "title", "amount", @@ -24,7 +24,7 @@ class CouponService extends CustomerService } public function getFilterFields(): array { - return ["clientinfo_code", 'status']; + return ["clientinfo_uid", 'status']; } public function getBatchJobFields(): array { @@ -36,9 +36,9 @@ class CouponService extends CustomerService private function setBalance(array $formDatas): void { //coupon_balance 체크 - $entity = $this->getClientService()->getEntity($formDatas['clientinfo_code']); + $entity = $this->getClientService()->getEntity($formDatas['clientinfo_uid']); if (!$entity) { - throw new \Exception("{$formDatas['clientinfo_code']}에 대한 고객정보를 찾을수 없습니다."); + throw new \Exception("{$formDatas['clientinfo_uid']}에 대한 고객정보를 찾을수 없습니다."); } $amount = intval($formDatas['amount']); if ($formDatas['status'] === CouponEntity::DEFAULT_STATUS) { //입금, 쿠폰추가 diff --git a/app/Services/Customer/CustomerService.php b/app/Services/Customer/CustomerService.php index 1422bf6..26b3efc 100644 --- a/app/Services/Customer/CustomerService.php +++ b/app/Services/Customer/CustomerService.php @@ -58,13 +58,13 @@ abstract class CustomerService extends CommonService case 'user_uid': $options = $this->getUserService()->getEntities(); break; - case 'clientinfo_code': + case 'clientinfo_uid': $options = $this->getClientService()->getEntities(); break; - case 'serviceinfo_code': + case 'serviceinfo_uid': $options = $this->getServiceService()->getEntities(); break; - case 'serverinfo_code': + case 'serverinfo_uid': $options = $this->getServerService()->getEntities(); break; default: diff --git a/app/Services/Customer/PaymentService.php b/app/Services/Customer/PaymentService.php index 4819bd7..0d45335 100644 --- a/app/Services/Customer/PaymentService.php +++ b/app/Services/Customer/PaymentService.php @@ -25,8 +25,8 @@ class PaymentService extends CustomerService public function getFormFields(): array { return [ - "clientinfo_code", - "serviceinfo_code", + "clientinfo_uid", + "serviceinfo_uid", "title", "amount", "billing_method", @@ -38,15 +38,15 @@ class PaymentService extends CustomerService } public function getFilterFields(): array { - return ['clientinfo_code', 'billing_method', 'pay_method', 'status', 'user_uid']; + return ['clientinfo_uid', 'billing_method', 'pay_method', 'status', 'user_uid']; } public function getBatchJobFields(): array { - return ['clientinfo_code', 'billing_method', 'pay_method', 'status']; + return ['clientinfo_uid', 'billing_method', 'pay_method', 'status']; } public function getIndexFields(): array { - return ['clientinfo_code', 'billing_method', 'amount', 'billing_at', 'pay_method', 'status', 'countdown', 'user_uid']; + return ['clientinfo_uid', 'billing_method', 'amount', 'billing_at', 'pay_method', 'status', 'countdown', 'user_uid']; } public function getBatchJobButtons(): array { @@ -62,10 +62,10 @@ class PaymentService extends CustomerService case 'user_uid': $options = $this->getUserService()->getEntities(); break; - case 'clientinfo_code': + case 'clientinfo_uid': $options = $this->getClientService()->getEntities(); break; - case 'serviceinfo_code': + case 'serviceinfo_uid': $options = $this->getServiceService()->getEntities(); break; default: @@ -77,13 +77,13 @@ class PaymentService extends CustomerService //미납서비스 정보 final public function getUnPaidCount(): array { - $sql = sprintf("SELECT serviceinfo_code,COUNT(*) as CNT + $sql = sprintf("SELECT serviceinfo_uid,COUNT(*) as CNT FROM payment WHERE billing_at < NOW() AND amount > 0 AND status = '%s' - GROUP BY serviceinfo_code", PaymentEntity::DEFAULT_STATUS); + GROUP BY serviceinfo_uid", PaymentEntity::DEFAULT_STATUS); $unpaids = []; foreach ($this->getModel()->query($sql)->getResult() as $row) { - $unpaids[$row->serverinfo_code] = $row->CNT; + $unpaids[$row->serverinfo_uid] = $row->CNT; } return $unpaids; } diff --git a/app/Services/Customer/PointService.php b/app/Services/Customer/PointService.php index b26c399..7722938 100644 --- a/app/Services/Customer/PointService.php +++ b/app/Services/Customer/PointService.php @@ -16,7 +16,7 @@ class PointService extends CustomerService public function getFormFields(): array { return [ - "clientinfo_code", + "clientinfo_uid", "status", "title", "amount" @@ -24,7 +24,7 @@ class PointService extends CustomerService } public function getFilterFields(): array { - return ["clientinfo_code", 'status']; + return ["clientinfo_uid", 'status']; } public function getBatchJobFields(): array { @@ -35,9 +35,9 @@ class PointService extends CustomerService private function setBalance(array $formDatas): void { //point_balance 체크 - $entity = $this->getClientService()->getEntity($formDatas['clientinfo_code']); + $entity = $this->getClientService()->getEntity($formDatas['clientinfo_uid']); if (!$entity) { - throw new \Exception("{$formDatas['clientinfo_code']}에 대한 고객정보를 찾을수 없습니다."); + throw new \Exception("{$formDatas['clientinfo_uid']}에 대한 고객정보를 찾을수 없습니다."); } $amount = intval($formDatas['amount']); if ($formDatas['status'] === PointEntity::DEFAULT_STATUS) { //입금, 쿠폰추가 diff --git a/app/Services/Customer/ServiceService.php b/app/Services/Customer/ServiceService.php index 4067835..1392399 100644 --- a/app/Services/Customer/ServiceService.php +++ b/app/Services/Customer/ServiceService.php @@ -17,8 +17,7 @@ class ServiceService extends CustomerService public function getFormFields(): array { return [ - "clientinfo_code", - "serverinfo_code", + "clientinfo_uid", "type", "location", "billing_at", @@ -30,15 +29,15 @@ class ServiceService extends CustomerService } public function getFilterFields(): array { - return ['clientinfo_code', 'serverinfo_code', 'type', 'location', 'status']; + return ['clientinfo_uid', 'serverinfo_uid', 'type', 'location', 'status']; } public function getBatchJobFields(): array { - return ['clientinfo_code', 'status']; + return ['clientinfo_uid', 'status']; } public function getIndexFields(): array { - return ['clientinfo_code', 'type', 'location', 'serverinfo_code', 'billing_at', 'amount', 'start_at', 'end_at', 'updated_at', 'status', 'user_uid']; + return ['clientinfo_uid', 'type', 'location', 'serverinfo_uid', 'billing_at', 'amount', 'start_at', 'end_at', 'updated_at', 'status', 'user_uid']; } //Entity의 관련객체정의용 public function setSearchIp(string $ip): void @@ -54,7 +53,7 @@ class ServiceService extends CustomerService // $ip = $this->getSearchIp(); // if ($ip) { // $sql = "SELECT serviceinfo.* FROM serviceinfo - // LEFT JOIN serviceinfo_items ON serviceinfo.uid = serviceinfo_items.serviceinfo_code + // LEFT JOIN serviceinfo_items ON serviceinfo.uid = serviceinfo_items.serviceinfo_uid // WHERE serviceinfo_items.item_type = ? // AND serviceinfo_items.item_uid IN (SELECT uid FROM ipinfo WHERE ip = ?)"; // return $this->getModel()->query($sql, ['IP', $ip])->getResult(ServiceEntity::class); diff --git a/app/Services/Equipment/CSService.php b/app/Services/Equipment/CSService.php index 740e3ac..8842174 100644 --- a/app/Services/Equipment/CSService.php +++ b/app/Services/Equipment/CSService.php @@ -20,7 +20,6 @@ class CSService extends EquipmentService "accountid", "domain", "price", - "amount", "status", ]; } @@ -34,7 +33,7 @@ class CSService extends EquipmentService } public function getIndexFields(): array { - return ['type', 'ip', 'accountid', 'domain', 'price', 'amount', 'status']; + return ['type', 'ip', 'accountid', 'domain', 'price', 'status']; } //List 검색용 //OrderBy 처리 diff --git a/app/Services/Equipment/DomainService.php b/app/Services/Equipment/DomainService.php deleted file mode 100644 index 06376e5..0000000 --- a/app/Services/Equipment/DomainService.php +++ /dev/null @@ -1,42 +0,0 @@ -addClassName('Domain'); - } - public function getFormFields(): array - { - return [ - "domain", - "status", - ]; - } - public function getFilterFields(): array - { - return ['status',]; - } - public function getBatchJobFields(): array - { - return ['status']; - } - - public function getIndexFields(): array - { - return ['domain', 'status']; - } - //List 검색용 - //OrderBy 처리 - public function setOrderBy(mixed $field = null, mixed $value = null): void - { - $this->getModel()->orderBy('domain', 'ASC'); - parent::setOrderBy($field, $value); - } -} diff --git a/app/Services/Equipment/EquipmentService.php b/app/Services/Equipment/EquipmentService.php index e995a2e..4dfdc23 100644 --- a/app/Services/Equipment/EquipmentService.php +++ b/app/Services/Equipment/EquipmentService.php @@ -59,13 +59,13 @@ abstract class EquipmentService extends CommonService case 'user_uid': $options = $this->getUserService()->getEntities(); break; - case 'clientinfo_code': + case 'clientinfo_uid': $options = $this->getClientService()->getEntities(); break; - case 'serviceinfo_code': + case 'serviceinfo_uid': $options = $this->getServiceService()->getEntities(); break; - case 'serverinfo_code': + case 'serverinfo_uid': $options = $this->getServerService()->getEntities(); break; default: diff --git a/app/Services/Equipment/IpService.php b/app/Services/Equipment/IpService.php index 8f75406..6af40fb 100644 --- a/app/Services/Equipment/IpService.php +++ b/app/Services/Equipment/IpService.php @@ -20,8 +20,8 @@ class IpService extends EquipmentService { return [ "lineinfo_uid", - "clientinfo_code", - "serverinfo_code", + "clientinfo_uid", + "serverinfo_uid", "ip", "price", "amount", @@ -39,7 +39,7 @@ class IpService extends EquipmentService } public function getIndexFields(): array { - return ['lineinfo_uid', 'clientinfo_code', 'serverinfo_code', 'ip', 'price', 'amount', 'status']; + return ['lineinfo_uid', 'clientinfo_uid', 'serverinfo_uid', 'ip', 'price', 'amount', 'status']; } final public function getLineService(): LineService { @@ -56,10 +56,10 @@ class IpService extends EquipmentService case 'lineinfo_uid': $options = $this->getLineService()->getEntities(); break; - case 'clientinfo_code': + case 'clientinfo_uid': $options = $this->getClientService()->getEntities(); break; - case 'serverinfo_code': + case 'serverinfo_uid': $options = $this->getServerService()->getEntities(); break; default: diff --git a/app/Services/Equipment/PartService.php b/app/Services/Equipment/PartService.php index 56dbc0b..9cfe45f 100644 --- a/app/Services/Equipment/PartService.php +++ b/app/Services/Equipment/PartService.php @@ -3,26 +3,42 @@ namespace App\Services\Equipment; use App\Models\Equipment\PartModel; -use App\Services\Equipment\EquipmentService; -abstract class PartService extends EquipmentService +class PartService extends EquipmentService { - protected function __construct() + public function __construct() { parent::__construct(new PartModel()); $this->addClassName('Part'); } - //FieldForm관련용 - public function getFormFieldOption(string $field, array $options = []): array + public function getFormFields(): array { - switch ($field) { - case 'clientinfo_code': - $options = $this->getClientService()->getEntities(); - break; - default: - $options = parent::getFormFieldOption($field, $options); - break; - } - return $options; + return [ + "type", + "title", + "price", + "status", + ]; + } + public function getFilterFields(): array + { + return ["type", 'status',]; + } + public function getBatchJobFields(): array + { + return ['status']; + } + public function getIndexFields(): array + { + return ['type', 'title', 'price', 'status', 'created_at']; + } + //기본 기능부분 + //FieldForm관련용 + //List 검색용 + //OrderBy 처리 + public function setOrderBy(mixed $field = null, mixed $value = null): void + { + $this->getModel()->orderBy('type ASC, title ASC'); + parent::setOrderBy($field, $value); } } diff --git a/app/Services/Equipment/ServerService.php b/app/Services/Equipment/ServerService.php index fbf2337..e5abcd4 100644 --- a/app/Services/Equipment/ServerService.php +++ b/app/Services/Equipment/ServerService.php @@ -16,8 +16,8 @@ class ServerService extends EquipmentService public function getFormFields(): array { return [ - "clientinfo_code", - "serviceinfo_code", + "clientinfo_uid", + "serviceinfo_uid", "code", "type", "title", @@ -38,7 +38,7 @@ class ServerService extends EquipmentService } public function getIndexFields(): array { - return ['clientinfo_code', 'serviceinfo_code', "type", 'title', 'price', 'total_price', 'manufactur_at', "format_at", 'status']; + return ['clientinfo_uid', 'serviceinfo_uid', "type", 'title', 'price', 'total_price', 'manufactur_at', "format_at", 'status']; } //기본 기능부분 //FieldForm관련용 diff --git a/app/Views/admin/welcome/new.php b/app/Views/admin/welcome/new.php index 352472a..2e88d0b 100644 --- a/app/Views/admin/welcome/new.php +++ b/app/Views/admin/welcome/new.php @@ -26,7 +26,7 @@ getListButton('new_service_view', '', $viewDatas, ['label' => $entity->getTitle()]) ?> - getFieldView('clientinfo_code', $entity->getClientCode(), $viewDatas) ?> + getFieldView('clientinfo_uid', $entity->getClientCode(), $viewDatas) ?> getFieldView('type', $entity->getType(), $viewDatas) ?> getFieldView('switchinfo_uid', $entity->getSwitchCode(), $viewDatas) ?> getFieldView('IP', null, $viewDatas) ?> diff --git a/erp3.vuerd.json b/erp3.vuerd.json index 1856d6f..b03ff54 100644 --- a/erp3.vuerd.json +++ b/erp3.vuerd.json @@ -2963,7 +2963,7 @@ "35XbdvgOzpNdasPnMcbkx": { "id": "35XbdvgOzpNdasPnMcbkx", "tableId": "jO40Ej5EXImXnadoJo9bn", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "고객정보", "dataType": "INT", "default": "", @@ -3003,7 +3003,7 @@ "X1GxGekOLLuoEkqGQDF86": { "id": "X1GxGekOLLuoEkqGQDF86", "tableId": "5AUwJum9FKPCoYRMBhLnF", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -3163,7 +3163,7 @@ "PyXYmokQzpzzT08WTmtsN": { "id": "PyXYmokQzpzzT08WTmtsN", "tableId": "5AUwJum9FKPCoYRMBhLnF", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "고객정보", "dataType": "INT", "default": "", @@ -3863,7 +3863,7 @@ "F6TXYV3uwRzb-aZYCmf5x": { "id": "F6TXYV3uwRzb-aZYCmf5x", "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자", "dataType": "INT", "default": "", @@ -3903,7 +3903,7 @@ "ha72QbBWfvyRymsyFBov8": { "id": "ha72QbBWfvyRymsyFBov8", "tableId": "RMhrLs7bOaopKmKt9YKHQ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자", "dataType": "INT", "default": "", @@ -4023,7 +4023,7 @@ "Ue1gt0C4DyjOQswV8LxkE": { "id": "Ue1gt0C4DyjOQswV8LxkE", "tableId": "doERb3lIVeBW_D0NtNYX8", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자", "dataType": "INT", "default": "", @@ -4063,7 +4063,7 @@ "5KRw8TtT2nLqpYfKFOBwe": { "id": "5KRw8TtT2nLqpYfKFOBwe", "tableId": "doERb3lIVeBW_D0NtNYX8", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자정보", "dataType": "INT", "default": "", @@ -4103,7 +4103,7 @@ "VxbbWBYPZdH63koVtdRuv": { "id": "VxbbWBYPZdH63koVtdRuv", "tableId": "RMhrLs7bOaopKmKt9YKHQ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -4123,7 +4123,7 @@ "kyD7tU9kevxCDow7j2uHI": { "id": "kyD7tU9kevxCDow7j2uHI", "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -4143,7 +4143,7 @@ "SaTapKkBzVUluKTG_fsBy": { "id": "SaTapKkBzVUluKTG_fsBy", "tableId": "ZLEpY5EjuZV21718zf-Y1", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -4163,7 +4163,7 @@ "B5P-XTPII39W_C1xsZEM-": { "id": "B5P-XTPII39W_C1xsZEM-", "tableId": "doERb3lIVeBW_D0NtNYX8", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "고객정보", "dataType": "INT", "default": "", @@ -4443,7 +4443,7 @@ "dluCt7VimWWwGu4Is8V0v": { "id": "dluCt7VimWWwGu4Is8V0v", "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자정보", "dataType": "INT", "default": "", @@ -4923,7 +4923,7 @@ "qzikkq9Ixd8qxTt9ZsXU_": { "id": "qzikkq9Ixd8qxTt9ZsXU_", "tableId": "GRBrbb1hqwKSRMfod3I7U", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -5403,7 +5403,7 @@ "skdAqnMsTEE6ZKbCD14VX": { "id": "skdAqnMsTEE6ZKbCD14VX", "tableId": "GRBrbb1hqwKSRMfod3I7U", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -5463,7 +5463,7 @@ "rK1V9ccYa0gxVE2W98dGH": { "id": "rK1V9ccYa0gxVE2W98dGH", "tableId": "GRBrbb1hqwKSRMfod3I7U", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -5483,7 +5483,7 @@ "Z2KizkUFrIaV_R_Quv4Ho": { "id": "Z2KizkUFrIaV_R_Quv4Ho", "tableId": "doERb3lIVeBW_D0NtNYX8", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자정보", "dataType": "INT", "default": "", @@ -5983,7 +5983,7 @@ "NzxkmndrTbH7xb6fbnGV7": { "id": "NzxkmndrTbH7xb6fbnGV7", "tableId": "B8haiEbPc1lRBWTv1g25G", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "고객정보", "dataType": "INT", "default": "", @@ -6283,7 +6283,7 @@ "TA8YG5vV7QmJxAXVpP8Tc": { "id": "TA8YG5vV7QmJxAXVpP8Tc", "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "소유자정보", "dataType": "INT", "default": "", @@ -6443,7 +6443,7 @@ "U3pGwK2LVZA4wQ1xa6EcF": { "id": "U3pGwK2LVZA4wQ1xa6EcF", "tableId": "GRBrbb1hqwKSRMfod3I7U", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -7863,7 +7863,7 @@ "xM99dcx7-5WMPvULGsgWq": { "id": "xM99dcx7-5WMPvULGsgWq", "tableId": "rlCmi1ybOTx8gPwOXyjTX", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "고객정보", "dataType": "INT", "default": "", @@ -8103,7 +8103,7 @@ "jqmxU5JhvpNsSCdKSoyT7": { "id": "jqmxU5JhvpNsSCdKSoyT7", "tableId": "H5lE3ZX7xEbV8d0OHBR95", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -8143,7 +8143,7 @@ "r0esmH8vUxxZfUM5g2LMo": { "id": "r0esmH8vUxxZfUM5g2LMo", "tableId": "VdcGlLO4HgExVJUAVEriv", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -8183,7 +8183,7 @@ "gutGFwQWK4wXhe8FtDw2o": { "id": "gutGFwQWK4wXhe8FtDw2o", "tableId": "BFhEqfFZ0L56a6Tey1OsK", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -8563,7 +8563,7 @@ "Mc9DanKrdzYxiptkoeq9J": { "id": "Mc9DanKrdzYxiptkoeq9J", "tableId": "1IgC97w7iAToPDVjmA6cP", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "", "dataType": "INT", "default": "", @@ -8583,7 +8583,7 @@ "0ukDN4F_rhKa5sHuLY5FX": { "id": "0ukDN4F_rhKa5sHuLY5FX", "tableId": "RTq5rHQupiXXJPXqpN8K5", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "서버코드", "dataType": "INT", "default": "", @@ -8603,7 +8603,7 @@ "g18PdAF1Il5_QWgnio9Lw": { "id": "g18PdAF1Il5_QWgnio9Lw", "tableId": "GRBrbb1hqwKSRMfod3I7U", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "서버코드", "dataType": "INT", "default": "", @@ -8623,7 +8623,7 @@ "7j-v8422Rzf3ZoLGCDJGo": { "id": "7j-v8422Rzf3ZoLGCDJGo", "tableId": "ZLEpY5EjuZV21718zf-Y1", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "서버코드", "dataType": "INT", "default": "", @@ -8643,7 +8643,7 @@ "UqCsY6KiCJOOFtjCHoMVL": { "id": "UqCsY6KiCJOOFtjCHoMVL", "tableId": "IsMoJXzvtuoOFFt93qS0w", - "name": "serverinfo_code", + "name": "serverinfo_uid", "comment": "서버코드", "dataType": "INT", "default": "", @@ -9023,7 +9023,7 @@ "imjqFzOrKxNF9-aH171pe": { "id": "imjqFzOrKxNF9-aH171pe", "tableId": "B4qGh3KZsXHQ3_4EOgwJZ", - "name": "clientinfo_code", + "name": "clientinfo_uid", "comment": "고객정보", "dataType": "INT", "default": "",