diff --git a/app/Cells/Equipment/ServerCell.php b/app/Cells/Equipment/ServerCell.php
index 9bd81df..6809b66 100644
--- a/app/Cells/Equipment/ServerCell.php
+++ b/app/Cells/Equipment/ServerCell.php
@@ -57,16 +57,6 @@ class ServerCell extends EquipmentCell
]
]);
}
- public function stock(array $params): string
- {
- $template = array_key_exists('template', $params) ? $params['template'] : 'stock';
- return view('cells/server/' . $template, [
- 'partCellDatas' => [
- 'rows' => $this->getService()->getStockCount(),
- ],
- ]);
- }
-
public function detail(array $params): string
{
$this->getService()->action_init_process(__FUNCTION__);
diff --git a/app/Cells/Part/CHASSISCell.php b/app/Cells/Part/CHASSISCell.php
new file mode 100644
index 0000000..75bcbb3
--- /dev/null
+++ b/app/Cells/Part/CHASSISCell.php
@@ -0,0 +1,23 @@
+ [
+ 'entities' => $this->getService()->getEntities(),
+ ],
+ ]);
+ }
+}
diff --git a/app/Views/admin/welcome/stock.php b/app/Views/admin/welcome/stock.php
index d504212..c43d9da 100644
--- a/app/Views/admin/welcome/stock.php
+++ b/app/Views/admin/welcome/stock.php
@@ -15,7 +15,7 @@
저장장치 재고 |
- | = view_cell("\App\Cells\Equipment\ServerCell::stock") ?> |
+ = view_cell("\App\Cells\Part\CHASSISCell::stock") ?> |
= view_cell("\App\Cells\Part\RAMCell::stock") ?> |
= view_cell("\App\Cells\Part\DISKCell::stock") ?> |
diff --git a/app/Views/cells/part/chassis_stock.php b/app/Views/cells/part/chassis_stock.php
new file mode 100644
index 0000000..b067153
--- /dev/null
+++ b/app/Views/cells/part/chassis_stock.php
@@ -0,0 +1,30 @@
+
+
+ | 항목 |
+ 사용 |
+ 가능 |
+ 총재고 |
+
+
+
+
+ |
+ =
+ form_label(
+ $entity->getTitle(),
+ 'disk_modify',
+ [
+ "data-src" => "admin/part/chassis/modify/{$entity->getPK()}",
+ "data-bs-toggle" => "modal",
+ "data-bs-target" => "#modal_action_form",
+ "class" => "text-primary form-label-sm",
+ ]
+ );
+ ?>
+ |
+ = $entity->getUsed() ?> |
+ = $entity->getAvailable() ?> |
+ = $entity->getStock() ?> |
+
+
+
\ No newline at end of file
diff --git a/app/Views/cells/server/stock.php b/app/Views/cells/server/stock.php
deleted file mode 100644
index 025beb5..0000000
--- a/app/Views/cells/server/stock.php
+++ /dev/null
@@ -1,16 +0,0 @@
-
-
- | 항목 |
- 사용 |
- 가능 |
- 총재고 |
-
- $label): ?>
-
- | = $label ?> |
- = array_key_exists($key, $partCellDatas['rows']) ? $partCellDatas['rows'][$key] : 0 ?> |
- = array_key_exists($key, $partCellDatas['rows']) ? SERVER['STOCKS'][$key] - $partCellDatas['rows'][$key] : SERVER['STOCKS'][$key] ?> |
- = SERVER['STOCKS'][$key] ?> |
-
-
-
\ No newline at end of file