dbmsv2_init...1
This commit is contained in:
parent
d84c355c59
commit
0b46189461
@ -4,8 +4,8 @@
|
|||||||
"settings": {
|
"settings": {
|
||||||
"width": 3000,
|
"width": 3000,
|
||||||
"height": 3000,
|
"height": 3000,
|
||||||
"scrollTop": -1581.7873,
|
"scrollTop": -538.7873,
|
||||||
"scrollLeft": -576.9398,
|
"scrollLeft": -1597,
|
||||||
"zoomLevel": 0.79,
|
"zoomLevel": 0.79,
|
||||||
"show": 511,
|
"show": 511,
|
||||||
"database": 4,
|
"database": 4,
|
||||||
@ -615,6 +615,7 @@
|
|||||||
"vxhl-9RMNJ8zU9oqzEWo8",
|
"vxhl-9RMNJ8zU9oqzEWo8",
|
||||||
"d4HxTQuDbI7SN2qBS84s2",
|
"d4HxTQuDbI7SN2qBS84s2",
|
||||||
"vbPIGWHquXROtCfId6RVF",
|
"vbPIGWHquXROtCfId6RVF",
|
||||||
|
"4YV8pFzwxVMlQJfHF6NyI",
|
||||||
"FhnUrn_dOrdhaBe_P3ty-",
|
"FhnUrn_dOrdhaBe_P3ty-",
|
||||||
"SA3xJ9nRW8EWDCFoMjnj3",
|
"SA3xJ9nRW8EWDCFoMjnj3",
|
||||||
"T8UART66GUy4LWDk0yUxl",
|
"T8UART66GUy4LWDk0yUxl",
|
||||||
@ -643,6 +644,7 @@
|
|||||||
"vxhl-9RMNJ8zU9oqzEWo8",
|
"vxhl-9RMNJ8zU9oqzEWo8",
|
||||||
"d4HxTQuDbI7SN2qBS84s2",
|
"d4HxTQuDbI7SN2qBS84s2",
|
||||||
"vbPIGWHquXROtCfId6RVF",
|
"vbPIGWHquXROtCfId6RVF",
|
||||||
|
"4YV8pFzwxVMlQJfHF6NyI",
|
||||||
"FhnUrn_dOrdhaBe_P3ty-",
|
"FhnUrn_dOrdhaBe_P3ty-",
|
||||||
"SA3xJ9nRW8EWDCFoMjnj3",
|
"SA3xJ9nRW8EWDCFoMjnj3",
|
||||||
"T8UART66GUy4LWDk0yUxl",
|
"T8UART66GUy4LWDk0yUxl",
|
||||||
@ -662,7 +664,7 @@
|
|||||||
"color": ""
|
"color": ""
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
"updateAt": 1758175481304,
|
"updateAt": 1759211433149,
|
||||||
"createAt": 1748484896313
|
"createAt": 1748484896313
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -683,6 +685,7 @@
|
|||||||
"MPV_aB_fuEXdco5eTWdEP",
|
"MPV_aB_fuEXdco5eTWdEP",
|
||||||
"SrCfFg0KgEamhUOVqGiPE",
|
"SrCfFg0KgEamhUOVqGiPE",
|
||||||
"hQ5EOPiUpDbVpWQwawtw4",
|
"hQ5EOPiUpDbVpWQwawtw4",
|
||||||
|
"zMpap7_wfBGVf2ZtONK0r",
|
||||||
"hK2hK1Xs1GrDW5nUTroIR",
|
"hK2hK1Xs1GrDW5nUTroIR",
|
||||||
"9o7wfPp7WK2nZoxkDZ9Y1",
|
"9o7wfPp7WK2nZoxkDZ9Y1",
|
||||||
"ualEjhI_OuUVdgH7dSzma",
|
"ualEjhI_OuUVdgH7dSzma",
|
||||||
@ -738,6 +741,7 @@
|
|||||||
"RpyPtXKwtu3XFr5BM61TA",
|
"RpyPtXKwtu3XFr5BM61TA",
|
||||||
"FJtEzmrQUsMMbrWbzr8IR",
|
"FJtEzmrQUsMMbrWbzr8IR",
|
||||||
"hQ5EOPiUpDbVpWQwawtw4",
|
"hQ5EOPiUpDbVpWQwawtw4",
|
||||||
|
"zMpap7_wfBGVf2ZtONK0r",
|
||||||
"hK2hK1Xs1GrDW5nUTroIR",
|
"hK2hK1Xs1GrDW5nUTroIR",
|
||||||
"9o7wfPp7WK2nZoxkDZ9Y1",
|
"9o7wfPp7WK2nZoxkDZ9Y1",
|
||||||
"ualEjhI_OuUVdgH7dSzma",
|
"ualEjhI_OuUVdgH7dSzma",
|
||||||
@ -759,7 +763,7 @@
|
|||||||
"color": ""
|
"color": ""
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
"updateAt": 1758513287204,
|
"updateAt": 1759209589117,
|
||||||
"createAt": 1748485662214
|
"createAt": 1748485662214
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -9479,6 +9483,46 @@
|
|||||||
"updateAt": 1758871910233,
|
"updateAt": 1758871910233,
|
||||||
"createAt": 1758871910232
|
"createAt": 1758871910232
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"zMpap7_wfBGVf2ZtONK0r": {
|
||||||
|
"id": "zMpap7_wfBGVf2ZtONK0r",
|
||||||
|
"tableId": "B8haiEbPc1lRBWTv1g25G",
|
||||||
|
"name": "sale",
|
||||||
|
"comment": "할인액",
|
||||||
|
"dataType": "INT",
|
||||||
|
"default": "0",
|
||||||
|
"options": 8,
|
||||||
|
"ui": {
|
||||||
|
"keys": 0,
|
||||||
|
"widthName": 60,
|
||||||
|
"widthComment": 60,
|
||||||
|
"widthDataType": 60,
|
||||||
|
"widthDefault": 60
|
||||||
|
},
|
||||||
|
"meta": {
|
||||||
|
"updateAt": 1759209609427,
|
||||||
|
"createAt": 1759209583630
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"4YV8pFzwxVMlQJfHF6NyI": {
|
||||||
|
"id": "4YV8pFzwxVMlQJfHF6NyI",
|
||||||
|
"tableId": "QCNA57Pi6A9dJDgybxS5v",
|
||||||
|
"name": "content",
|
||||||
|
"comment": "내용",
|
||||||
|
"dataType": "TEXT",
|
||||||
|
"default": "",
|
||||||
|
"options": 0,
|
||||||
|
"ui": {
|
||||||
|
"keys": 0,
|
||||||
|
"widthName": 60,
|
||||||
|
"widthComment": 60,
|
||||||
|
"widthDataType": 60,
|
||||||
|
"widthDefault": 60
|
||||||
|
},
|
||||||
|
"meta": {
|
||||||
|
"updateAt": 1759211445971,
|
||||||
|
"createAt": 1759211431057
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"relationshipEntities": {
|
"relationshipEntities": {
|
||||||
@ -9558,7 +9602,7 @@
|
|||||||
"s1Az-lXWK0NlVQqFEEK8o"
|
"s1Az-lXWK0NlVQqFEEK8o"
|
||||||
],
|
],
|
||||||
"x": 2338.5336,
|
"x": 2338.5336,
|
||||||
"y": 575.633,
|
"y": 578.633,
|
||||||
"direction": 1
|
"direction": 1
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
@ -9810,7 +9854,7 @@
|
|||||||
"8mPFhDdUY8QLPvc8rNw1B"
|
"8mPFhDdUY8QLPvc8rNw1B"
|
||||||
],
|
],
|
||||||
"x": 2338.5336,
|
"x": 2338.5336,
|
||||||
"y": 869.633,
|
"y": 890.633,
|
||||||
"direction": 1
|
"direction": 1
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
@ -9838,7 +9882,7 @@
|
|||||||
"N-2m8O_JzS6-sDEcL5zTv"
|
"N-2m8O_JzS6-sDEcL5zTv"
|
||||||
],
|
],
|
||||||
"x": 1807.3602,
|
"x": 1807.3602,
|
||||||
"y": 1250.9431,
|
"y": 1256.9431,
|
||||||
"direction": 1
|
"direction": 1
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
@ -9866,7 +9910,7 @@
|
|||||||
"vxhl-9RMNJ8zU9oqzEWo8"
|
"vxhl-9RMNJ8zU9oqzEWo8"
|
||||||
],
|
],
|
||||||
"x": 2338.5336,
|
"x": 2338.5336,
|
||||||
"y": 673.633,
|
"y": 682.633,
|
||||||
"direction": 1
|
"direction": 1
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
@ -9941,7 +9985,7 @@
|
|||||||
"nNWsAWbHfKWqx8EwxvuM1"
|
"nNWsAWbHfKWqx8EwxvuM1"
|
||||||
],
|
],
|
||||||
"x": 1889.3602,
|
"x": 1889.3602,
|
||||||
"y": 1652.9431,
|
"y": 1676.9431,
|
||||||
"direction": 8
|
"direction": 8
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
@ -10081,7 +10125,7 @@
|
|||||||
"nNWsAWbHfKWqx8EwxvuM1"
|
"nNWsAWbHfKWqx8EwxvuM1"
|
||||||
],
|
],
|
||||||
"x": 1807.3602,
|
"x": 1807.3602,
|
||||||
"y": 1518.9431,
|
"y": 1536.9431,
|
||||||
"direction": 1
|
"direction": 1
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
@ -10137,7 +10181,7 @@
|
|||||||
"nNWsAWbHfKWqx8EwxvuM1"
|
"nNWsAWbHfKWqx8EwxvuM1"
|
||||||
],
|
],
|
||||||
"x": 2217.3602,
|
"x": 2217.3602,
|
||||||
"y": 1652.9431,
|
"y": 1676.9431,
|
||||||
"direction": 8
|
"direction": 8
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
@ -10165,7 +10209,7 @@
|
|||||||
"nNWsAWbHfKWqx8EwxvuM1"
|
"nNWsAWbHfKWqx8EwxvuM1"
|
||||||
],
|
],
|
||||||
"x": 2381.3602,
|
"x": 2381.3602,
|
||||||
"y": 1652.9431,
|
"y": 1676.9431,
|
||||||
"direction": 8
|
"direction": 8
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
@ -10305,7 +10349,7 @@
|
|||||||
"GMPyqxaroK2OjQZnoCRwn"
|
"GMPyqxaroK2OjQZnoCRwn"
|
||||||
],
|
],
|
||||||
"x": 2338.5336,
|
"x": 2338.5336,
|
||||||
"y": 771.633,
|
"y": 786.633,
|
||||||
"direction": 1
|
"direction": 1
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
@ -10333,7 +10377,7 @@
|
|||||||
"GMPyqxaroK2OjQZnoCRwn"
|
"GMPyqxaroK2OjQZnoCRwn"
|
||||||
],
|
],
|
||||||
"x": 2657.5336,
|
"x": 2657.5336,
|
||||||
"y": 918.633,
|
"y": 942.633,
|
||||||
"direction": 8
|
"direction": 8
|
||||||
},
|
},
|
||||||
"end": {
|
"end": {
|
||||||
@ -10370,7 +10414,7 @@
|
|||||||
"y6WzFGCw3VEqa06ops3EC"
|
"y6WzFGCw3VEqa06ops3EC"
|
||||||
],
|
],
|
||||||
"x": 2053.3602,
|
"x": 2053.3602,
|
||||||
"y": 1652.9431,
|
"y": 1676.9431,
|
||||||
"direction": 8
|
"direction": 8
|
||||||
},
|
},
|
||||||
"meta": {
|
"meta": {
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@ -60,7 +60,11 @@ class ServiceEntity extends CustomerEntity
|
|||||||
{
|
{
|
||||||
return $this->attributes['billing_at'] ?? "";
|
return $this->attributes['billing_at'] ?? "";
|
||||||
}
|
}
|
||||||
//청구금액->기본:상면비+회선비+서버금액(price)+서버파트연결(월비용)
|
//청구금액->기본:상면비+회선비+서버금액(price)+서버파트연결(월비용)-할인액
|
||||||
|
final public function getSale(): int
|
||||||
|
{
|
||||||
|
return $this->attributes['sale'] ?? 0;
|
||||||
|
}
|
||||||
final public function getAmount(): int
|
final public function getAmount(): int
|
||||||
{
|
{
|
||||||
return $this->attributes['amount'] ?? 0;
|
return $this->attributes['amount'] ?? 0;
|
||||||
@ -75,6 +79,10 @@ class ServiceEntity extends CustomerEntity
|
|||||||
{
|
{
|
||||||
return $this->attributes['line'] ?? 0;
|
return $this->attributes['line'] ?? 0;
|
||||||
}
|
}
|
||||||
|
final public function getStartAt(): string
|
||||||
|
{
|
||||||
|
return $this->attributes['start_at'] ?? "";
|
||||||
|
}
|
||||||
public function getHistory(): string
|
public function getHistory(): string
|
||||||
{
|
{
|
||||||
return $this->attributes['history'] ?? "";
|
return $this->attributes['history'] ?? "";
|
||||||
|
|||||||
@ -75,6 +75,7 @@ class ServiceHelper extends CustomerHelper
|
|||||||
{
|
{
|
||||||
switch ($field) {
|
switch ($field) {
|
||||||
case 'amount':
|
case 'amount':
|
||||||
|
case 'sale':
|
||||||
$value = number_format($value) . "원";
|
$value = number_format($value) . "원";
|
||||||
break;
|
break;
|
||||||
case 'billing_at':
|
case 'billing_at':
|
||||||
|
|||||||
@ -11,6 +11,7 @@ return [
|
|||||||
'rack' => "상면비",
|
'rack' => "상면비",
|
||||||
'line' => "회선비",
|
'line' => "회선비",
|
||||||
'billing_at' => "결제일",
|
'billing_at' => "결제일",
|
||||||
|
'sale' => "할인액",
|
||||||
'amount' => "월청구액",
|
'amount' => "월청구액",
|
||||||
'start_at' => "시작일",
|
'start_at' => "시작일",
|
||||||
'end_at' => "해지일",
|
'end_at' => "해지일",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class AccountModel extends CustomerModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = AccountEntity::class;
|
protected $returnType = AccountEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"bank",
|
"bank",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class ClientModel extends CustomerModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = ClientEntity::class;
|
protected $returnType = ClientEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"code",
|
"code",
|
||||||
"site",
|
"site",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class CouponModel extends CustomerModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = CouponEntity::class;
|
protected $returnType = CouponEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"title",
|
"title",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class PointModel extends CustomerModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = PointEntity::class;
|
protected $returnType = PointEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"title",
|
"title",
|
||||||
|
|||||||
@ -15,6 +15,7 @@ class ServiceModel extends CustomerModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = ServiceEntity::class;
|
protected $returnType = ServiceEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"serverinfo_uid",
|
"serverinfo_uid",
|
||||||
@ -25,6 +26,7 @@ class ServiceModel extends CustomerModel
|
|||||||
"rack",
|
"rack",
|
||||||
"line",
|
"line",
|
||||||
"billing_at",
|
"billing_at",
|
||||||
|
"sale",
|
||||||
"amount",
|
"amount",
|
||||||
"start_at",
|
"start_at",
|
||||||
"end_at",
|
"end_at",
|
||||||
@ -50,6 +52,7 @@ class ServiceModel extends CustomerModel
|
|||||||
case "line":
|
case "line":
|
||||||
$rule = "required|numeric";
|
$rule = "required|numeric";
|
||||||
break;
|
break;
|
||||||
|
case "sale":
|
||||||
case "payment_uid":
|
case "payment_uid":
|
||||||
$rule = "permit_empty|numeric";
|
$rule = "permit_empty|numeric";
|
||||||
break;
|
break;
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class LineModel extends EquipmentModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = LineEntity::class;
|
protected $returnType = LineEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"type",
|
"type",
|
||||||
"title",
|
"title",
|
||||||
"bandwith",
|
"bandwith",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class ServerModel extends EquipmentModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = ServerEntity::class;
|
protected $returnType = ServerEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"serviceinfo_uid",
|
"serviceinfo_uid",
|
||||||
"code",
|
"code",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class ServerPartModel extends EquipmentModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = ServerPartEntity::class;
|
protected $returnType = ServerPartEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"part_uid",
|
"part_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"serverinfo_uid",
|
"serverinfo_uid",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class MyLogModel extends CommonModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = MyLogEntity::class;
|
protected $returnType = MyLogEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"title",
|
"title",
|
||||||
"content",
|
"content",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class CPUModel extends PartModel
|
|||||||
// protected $useAutoIncrement = false;
|
// protected $useAutoIncrement = false;
|
||||||
protected $returnType = CPUEntity::class;
|
protected $returnType = CPUEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"title",
|
"title",
|
||||||
"price",
|
"price",
|
||||||
"stock",
|
"stock",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class CSModel extends PartModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = CSEntity::class;
|
protected $returnType = CSEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"serviceinfo_uid",
|
"serviceinfo_uid",
|
||||||
"serverinfo_uid",
|
"serverinfo_uid",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class DISKModel extends PartModel
|
|||||||
// protected $useAutoIncrement = false;
|
// protected $useAutoIncrement = false;
|
||||||
protected $returnType = DISKEntity::class;
|
protected $returnType = DISKEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"title",
|
"title",
|
||||||
"price",
|
"price",
|
||||||
"stock",
|
"stock",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class IPModel extends PartModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = IPEntity::class;
|
protected $returnType = IPEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"lineinfo_uid",
|
"lineinfo_uid",
|
||||||
"old_clientinfo_uid",
|
"old_clientinfo_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class OSModel extends PartModel
|
|||||||
// protected $useAutoIncrement = false;
|
// protected $useAutoIncrement = false;
|
||||||
protected $returnType = OSEntity::class;
|
protected $returnType = OSEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"title",
|
"title",
|
||||||
"price",
|
"price",
|
||||||
"stock",
|
"stock",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class RAMModel extends PartModel
|
|||||||
// protected $useAutoIncrement = false;
|
// protected $useAutoIncrement = false;
|
||||||
protected $returnType = RAMEntity::class;
|
protected $returnType = RAMEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"title",
|
"title",
|
||||||
"price",
|
"price",
|
||||||
"stock",
|
"stock",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class SOFTWAREModel extends PartModel
|
|||||||
// protected $useAutoIncrement = false;
|
// protected $useAutoIncrement = false;
|
||||||
protected $returnType = SOFTWAREEntity::class;
|
protected $returnType = SOFTWAREEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"title",
|
"title",
|
||||||
"price",
|
"price",
|
||||||
"stock",
|
"stock",
|
||||||
|
|||||||
@ -14,6 +14,7 @@ class SWITCHModel extends PartModel
|
|||||||
// protected $useAutoIncrement = false;
|
// protected $useAutoIncrement = false;
|
||||||
protected $returnType = SWITCHEntity::class;
|
protected $returnType = SWITCHEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"serviceinfo_uid",
|
"serviceinfo_uid",
|
||||||
"serverinfo_uid",
|
"serverinfo_uid",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class PaymentModel extends CommonModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = PaymentEntity::class;
|
protected $returnType = PaymentEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"clientinfo_uid",
|
"clientinfo_uid",
|
||||||
"serviceinfo_uid",
|
"serviceinfo_uid",
|
||||||
|
|||||||
@ -13,6 +13,7 @@ class UserModel extends CommonModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = UserEntity::class;
|
protected $returnType = UserEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"id",
|
"id",
|
||||||
"passwd",
|
"passwd",
|
||||||
"name",
|
"name",
|
||||||
|
|||||||
@ -15,6 +15,7 @@ class UserSNSModel extends CommonModel
|
|||||||
protected $primaryKey = self::PK;
|
protected $primaryKey = self::PK;
|
||||||
protected $returnType = UserSNSEntity::class;
|
protected $returnType = UserSNSEntity::class;
|
||||||
protected $allowedFields = [
|
protected $allowedFields = [
|
||||||
|
"uid",
|
||||||
"site",
|
"site",
|
||||||
"user_uid",
|
"user_uid",
|
||||||
"id",
|
"id",
|
||||||
|
|||||||
@ -36,6 +36,7 @@ class ServiceService extends CustomerService implements ServerInterface, ServerP
|
|||||||
"start_at",
|
"start_at",
|
||||||
"billing_at",
|
"billing_at",
|
||||||
"status",
|
"status",
|
||||||
|
'sale',
|
||||||
'amount',
|
'amount',
|
||||||
"history",
|
"history",
|
||||||
];
|
];
|
||||||
@ -59,6 +60,7 @@ class ServiceService extends CustomerService implements ServerInterface, ServerP
|
|||||||
'location',
|
'location',
|
||||||
'clientinfo_uid',
|
'clientinfo_uid',
|
||||||
'serverinfo_uid',
|
'serverinfo_uid',
|
||||||
|
'sale',
|
||||||
'amount',
|
'amount',
|
||||||
'billing_at',
|
'billing_at',
|
||||||
'status',
|
'status',
|
||||||
@ -167,14 +169,15 @@ class ServiceService extends CustomerService implements ServerInterface, ServerP
|
|||||||
final public function getCaculatedAmount(ServiceEntity $entity): int
|
final public function getCaculatedAmount(ServiceEntity $entity): int
|
||||||
{
|
{
|
||||||
//총서비스금액 계산
|
//총서비스금액 계산
|
||||||
$caculatedAmount = $entity->getRack() + $entity->getLine() + $entity->getServerEntity()->getPrice(); //기본:상면비+회선비+서버금액(price)+서버파트연결(월비용)
|
//기본:상면비+회선비+서버금액(price)+서버파트연결(월비용)-할인액
|
||||||
|
$caculatedAmount = $entity->getRack() + $entity->getLine() + $entity->getServerEntity()->getPrice();
|
||||||
//해당 서비스(서버) 관련 결제방식(Billing)이 Month인 ServerPart 전체를 다시 검사하여 월청구액을 합산한다.
|
//해당 서비스(서버) 관련 결제방식(Billing)이 Month인 ServerPart 전체를 다시 검사하여 월청구액을 합산한다.
|
||||||
foreach ($this->getServerPartService()->getEntities(['serverinfo_uid' => $entity->getServerEntity()->getPK()]) as $serverPartEntity) {
|
foreach ($this->getServerPartService()->getEntities(['serverinfo_uid' => $entity->getServerEntity()->getPK()]) as $serverPartEntity) {
|
||||||
if ($serverPartEntity->getBilling() === PAYMENT['BILLING']['MONTH']) { //월비용일때만 적용
|
if ($serverPartEntity->getBilling() === PAYMENT['BILLING']['MONTH']) { //월비용일때만 적용
|
||||||
$caculatedAmount += $serverPartEntity->getTotalAmount(); //단가*Cnt
|
$caculatedAmount += $serverPartEntity->getTotalAmount(); //단가*Cnt
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $caculatedAmount;
|
return $caculatedAmount - $entity->getSale();
|
||||||
}
|
}
|
||||||
final public function setAmount(ServiceEntity $entity): ServiceEntity
|
final public function setAmount(ServiceEntity $entity): ServiceEntity
|
||||||
{
|
{
|
||||||
@ -199,13 +202,19 @@ class ServiceService extends CustomerService implements ServerInterface, ServerP
|
|||||||
//대체 서버를 메인서버로 설정
|
//대체 서버를 메인서버로 설정
|
||||||
final public function changeAlternativeServer(ServiceEntity $entity, array $formDatas): ServiceEntity
|
final public function changeAlternativeServer(ServiceEntity $entity, array $formDatas): ServiceEntity
|
||||||
{
|
{
|
||||||
|
// //기존메인서버 정보
|
||||||
|
// $oldServerEntity = $entity->getServerEntity();
|
||||||
|
// //메인서버로 선정된 대체서버정보
|
||||||
$serverEntity = $this->getServerService()->getEntity($formDatas['serverinfo_uid']);
|
$serverEntity = $this->getServerService()->getEntity($formDatas['serverinfo_uid']);
|
||||||
if (!$serverEntity instanceof ServerEntity) {
|
if (!$serverEntity instanceof ServerEntity) {
|
||||||
throw new \Exception("{$formDatas['serverinfo_uid']}에 대한 서버정보를 찾을수 없습니다.");
|
throw new \Exception("{$formDatas['serverinfo_uid']}에 대한 서버정보를 찾을수 없습니다.");
|
||||||
}
|
}
|
||||||
//수정전 정보
|
// //메인서버로 선정된 서버의 형식을 기존메인서버의 형식으로 바꿈
|
||||||
|
// $serverEntity = $this->getServerService()->modify($serverEntity, ['type' => $oldServerEntity->getType()]);
|
||||||
|
|
||||||
|
//수정전 서비스정보
|
||||||
$oldEntity = $entity;
|
$oldEntity = $entity;
|
||||||
//메인서버 변경
|
//메인서버 변경(메인서버를 선정된 대체서버로 바꾼다.)
|
||||||
$entity = parent::modify($entity, ['serverinfo_uid' => $serverEntity->getPK()]);
|
$entity = parent::modify($entity, ['serverinfo_uid' => $serverEntity->getPK()]);
|
||||||
//전체 서비스금액 설정
|
//전체 서비스금액 설정
|
||||||
$entity = $this->setAmount($entity);
|
$entity = $this->setAmount($entity);
|
||||||
|
|||||||
@ -188,7 +188,8 @@ class PaymentService extends CommonService implements ServiceInterface, ServerPa
|
|||||||
$formDatas['billing'] = PAYMENT['BILLING']['MONTH'];
|
$formDatas['billing'] = PAYMENT['BILLING']['MONTH'];
|
||||||
$formDatas['billing_at'] = $serviceEntity->getBillingAt();
|
$formDatas['billing_at'] = $serviceEntity->getBillingAt();
|
||||||
//필수정보처리 후 결제정보수정 후 서비스정보 Entity에 결제정보 설정
|
//필수정보처리 후 결제정보수정 후 서비스정보 Entity에 결제정보 설정
|
||||||
return $serviceEntity->setPaymentEntity($this->getModel()->modify($entity, $formDatas));
|
$entity = $this->getModel()->modify($entity, $formDatas);
|
||||||
|
return $serviceEntity->setPaymentEntity($entity);
|
||||||
}
|
}
|
||||||
public function unsetService(ServiceEntity $serviceEntity, array $serviceDatas): ServiceEntity
|
public function unsetService(ServiceEntity $serviceEntity, array $serviceDatas): ServiceEntity
|
||||||
{
|
{
|
||||||
|
|||||||
@ -44,6 +44,9 @@
|
|||||||
<th class="index_head_short_column" style="width:650px;">
|
<th class="index_head_short_column" style="width:650px;">
|
||||||
<span class="float-start rounded border border-primary" style="cursor:pointer;" onclick="copyServerPartsToClipboard()">ALL 📋</span>서버정보
|
<span class="float-start rounded border border-primary" style="cursor:pointer;" onclick="copyServerPartsToClipboard()">ALL 📋</span>서버정보
|
||||||
</th>
|
</th>
|
||||||
|
<th class="index_head_short_column">
|
||||||
|
<?= $viewDatas['service']->getHelper()->getListLabel('amount', lang("{$viewDatas['class_path']}.label.sale"), $viewDatas) ?>
|
||||||
|
</th>
|
||||||
<th class="index_head_short_column">
|
<th class="index_head_short_column">
|
||||||
<?= $viewDatas['service']->getHelper()->getListLabel('amount', lang("{$viewDatas['class_path']}.label.amount"), $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getListLabel('amount', lang("{$viewDatas['class_path']}.label.amount"), $viewDatas) ?>
|
||||||
</th>
|
</th>
|
||||||
@ -67,22 +70,25 @@
|
|||||||
<td nowrap><?= $viewDatas['service']->getHelper()->getListButton('modify', $num, $viewDatas) ?></td>
|
<td nowrap><?= $viewDatas['service']->getHelper()->getListButton('modify', $num, $viewDatas) ?></td>
|
||||||
<td nowrap>
|
<td nowrap>
|
||||||
<?= $viewDatas['service']->getHelper()->getFieldView('site', $entity->site, $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getFieldView('site', $entity->site, $viewDatas) ?>
|
||||||
/ <?= $viewDatas['service']->getHelper()->getFieldView('location', $entity->location, $viewDatas) ?>
|
/ <?= $viewDatas['service']->getHelper()->getFieldView('location', $entity->getLocation(), $viewDatas) ?>
|
||||||
</td>
|
</td>
|
||||||
<td nowrap>
|
<td nowrap>
|
||||||
<?= $viewDatas['service']->getHelper()->getFieldView('clientinfo_uid', $entity->clientinfo_uid, $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getFieldView('clientinfo_uid', $entity->getClientInfoUID(), $viewDatas) ?>
|
||||||
</td>
|
</td>
|
||||||
<td nowrap><?= implode("", $viewDatas['childServers'][$entity->getPK()]) ?></td>
|
<td nowrap><?= implode("", $viewDatas['childServers'][$entity->getPK()]) ?></td>
|
||||||
<td nowrap>
|
<td nowrap class="text-end">
|
||||||
<?= $viewDatas['service']->getHelper()->getFieldView('amount', $entity->amount, $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getFieldView('sale', $entity->getSale(), $viewDatas) ?>
|
||||||
|
</td>
|
||||||
|
<td nowrap class="text-end">
|
||||||
|
<?= $viewDatas['service']->getHelper()->getFieldView('amount', $entity->getAmount(), $viewDatas) ?>
|
||||||
</td>
|
</td>
|
||||||
<td nowrap>
|
<td nowrap>
|
||||||
<?= $viewDatas['service']->getHelper()->getFieldView('billing_at', $entity->billing_at, $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getFieldView('billing_at', $entity->getBillingAt(), $viewDatas) ?>
|
||||||
</td>
|
</td>
|
||||||
<td nowrap>
|
<td nowrap>
|
||||||
<?= $viewDatas['service']->getHelper()->getFieldView('status', $entity->status, $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getFieldView('status', $entity->getStatus(), $viewDatas) ?>
|
||||||
</td>
|
</td>
|
||||||
<td nowrap><?= $viewDatas['service']->getHelper()->getFieldView('start_at', $entity->start_at, $viewDatas) ?></td>
|
<td nowrap><?= $viewDatas['service']->getHelper()->getFieldView('start_at', $entity->getStartAt(), $viewDatas) ?></td>
|
||||||
<td nowrap>
|
<td nowrap>
|
||||||
<?= $viewDatas['service']->getHelper()->getListButton('alternative', '', $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getListButton('alternative', '', $viewDatas) ?>
|
||||||
<?= $viewDatas['service']->getHelper()->getListButton('onetime', '', $viewDatas) ?>
|
<?= $viewDatas['service']->getHelper()->getListButton('onetime', '', $viewDatas) ?>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user