diff --git a/app/Domains/Virtual/Http/Controllers/PropertyController.php b/app/Domains/Virtual/Http/Controllers/PropertyController.php index 93e94ad7..68e56c83 100644 --- a/app/Domains/Virtual/Http/Controllers/PropertyController.php +++ b/app/Domains/Virtual/Http/Controllers/PropertyController.php @@ -111,7 +111,7 @@ class PropertyController extends Controller ]; foreach ($data as $i => $item) { - $row = $i + 1; + $row = $i + 2; foreach ($item as $v => $value) { if (strpos($v, '*') !== false) { diff --git a/app/Domains/Virtual/Services/PropertyService.php b/app/Domains/Virtual/Services/PropertyService.php index a7a70954..b00ad220 100644 --- a/app/Domains/Virtual/Services/PropertyService.php +++ b/app/Domains/Virtual/Services/PropertyService.php @@ -266,14 +266,14 @@ class PropertyService extends Service $value['created_at'] = date('Y-m-d H:i:s'); $value['updated_at'] = date('Y-m-d H:i:s'); - $data[] = $value; + $data[$value['company_id'] . '_' . $value['package_id']] = $value; } if (empty($data)) { throw new NotAllowedException('数据未修改'); } - $this->propertyRepository->upsert($data, ['company_id', 'package_id']); + $this->propertyRepository->upsert(array_values($data), ['company_id', 'package_id']); $this->propertyRepository->forgetCached(); diff --git a/frontend/src/views/virtual/properties/index.vue b/frontend/src/views/virtual/properties/index.vue index 617285e0..b7a7434e 100644 --- a/frontend/src/views/virtual/properties/index.vue +++ b/frontend/src/views/virtual/properties/index.vue @@ -64,6 +64,13 @@ +
{{message}}
\n选择图标
\n\n{{CONFIG.title}}
\n \n