diff --git a/app/Controllers/Admin/OrderController.php b/app/Controllers/Admin/OrderController.php
index e1b8957..4142fd0 100644
--- a/app/Controllers/Admin/OrderController.php
+++ b/app/Controllers/Admin/OrderController.php
@@ -24,6 +24,8 @@ class OrderController extends AdminController
break;
case "index":
case "excel":
+ return ["user_uid", "name", "cost", "sale", "quantity", "price", "status", "updated_at", "created_at"];
+ break;
case "view":
return ["user_uid", 'product_uid', "name", "cost", "sale", "quantity", "price", "status", "updated_at", "created_at"];
break;
diff --git a/app/Entities/OrderEntity.php b/app/Entities/OrderEntity.php
index ee08638..c181f5c 100644
--- a/app/Entities/OrderEntity.php
+++ b/app/Entities/OrderEntity.php
@@ -15,4 +15,13 @@ class OrderEntity extends BaseEntity
return $this->attributes['name'];
}
//추가기능
+ public function getOrderHint()
+ {
+ $hints = explode("-", $this->getPrimaryKey());
+ return sprintf(
+ "%s-**-%s",
+ str_split($hints[0], 3)[0],
+ str_split($hints[count($hints) - 1], 5)[0]
+ );
+ }
}
diff --git a/app/Helpers/Order_helper.php b/app/Helpers/Order_helper.php
index 354ac36..9ea54b3 100644
--- a/app/Helpers/Order_helper.php
+++ b/app/Helpers/Order_helper.php
@@ -109,10 +109,15 @@ function getFieldIndex_Row_OrderHelper($field, $entity, array $viewDatas): strin
switch ($field) {
case 'title':
case 'name':
- return anchor(
- current_url() . '/view/' . $entity->getPrimaryKey() . '?category=' . $viewDatas['category']->getPrimaryKey(),
- $value,
- ["target" => "_self"]
+ return sprintf(
+ "
%s : %s
%s",
+ lang("{$viewDatas['className']}.label.uid"),
+ $entity->getOrderHint(),
+ anchor(
+ current_url() . '/view/' . $entity->getPrimaryKey() . '?category=' . $viewDatas['category']->getPrimaryKey(),
+ $value,
+ ["target" => "_self"]
+ )
);
break;
default:
@@ -127,23 +132,29 @@ function getFieldIndex_Row_OrderHelper_Admin($field, $entity, array $viewDatas):
switch ($field) {
case 'title':
case 'name':
- return anchor(
- current_url() . '/view/' . $entity->getPrimaryKey(),
- $value,
- ["target" => "_self"]
+ return sprintf(
+ "%s : %s
%s",
+ lang("{$viewDatas['className']}.label.uid"),
+ $entity->getPrimaryKey(),
+ anchor(
+ current_url() . '/view/' . $entity->getPrimaryKey(),
+ $value,
+ ["target" => "_self"]
+ )
);
break;
default:
- if (in_array($field, $viewDatas['fieldFilters'])) {
- $attributes["onChange"] = sprintf(
- 'location.href="%s/toggle/%s/%s?%s="+this.options[this.selectedIndex].value',
- current_url(),
- $entity->getPrimaryKey(),
- $field,
- $field
- );
- return getFieldForm_OrderHelper($field, $entity->$field, $viewDatas, $attributes);
- }
+ //관리자도 수정할수 없게 하기위해
+ // if (in_array($field, $viewDatas['fieldFilters'])) {
+ // $attributes["onChange"] = sprintf(
+ // 'location.href="%s/toggle/%s/%s?%s="+this.options[this.selectedIndex].value',
+ // current_url(),
+ // $entity->getPrimaryKey(),
+ // $field,
+ // $field
+ // );
+ // return getFieldForm_OrderHelper($field, $entity->$field, $viewDatas, $attributes);
+ // }
return getFieldIndex_Row_OrderHelper($field, $entity, $viewDatas);
break;
}
diff --git a/app/Language/ko/Order.php b/app/Language/ko/Order.php
index e0f86c1..589a989 100644
--- a/app/Language/ko/Order.php
+++ b/app/Language/ko/Order.php
@@ -2,7 +2,7 @@
return [
'title' => "주문 정보",
'label' => [
- 'uid' => "번호",
+ 'uid' => "주문ID",
'product_uid' => "상품정보",
'sess_id' => "세션ID",
'user_uid' => "사용자정보",
diff --git a/public/css/style.css b/public/css/style.css
index f4bf0c9..c9dc689 100644
--- a/public/css/style.css
+++ b/public/css/style.css
@@ -14,13 +14,13 @@
font: Arial;
}
-/* user class */
-h1,h2,h3,h4,h5,h6,strong,th,.bold{font-weight:500;}
-
body {
background-color: white;
}
+/* user class */
+h1,h2,h3,h4,h5,h6,strong,th,.bold{font-weight:500;}
+
input[type=text],input[type=password]{
display: inline-block;
border: 1px solid #ccc;
@@ -38,4 +38,6 @@ select,textarea,button {
a:link { text-decoration: none; }
a:visited { text-decoration: none; }
a:hover { text-decoration: underline; }
-a:active { text-decoration: underline; }
\ No newline at end of file
+a:active { text-decoration: underline; }
+
+div.location-left { text-align:left; }
\ No newline at end of file