8
8
use GetCandy \Models \AttributeGroup ;
9
9
use GetCandy \Models \Channel ;
10
10
use GetCandy \Models \Collection ;
11
+ use GetCandy \Models \CollectionGroup ;
11
12
use GetCandy \Models \Country ;
12
13
use GetCandy \Models \Currency ;
13
14
use GetCandy \Models \CustomerGroup ;
@@ -59,8 +60,6 @@ public function handle(): void
59
60
60
61
$ this ->info ('Publishing hub assets ' );
61
62
62
- $ this ->publishResources ();
63
-
64
63
if (! Country::count ()) {
65
64
$ this ->info ('Importing countries ' );
66
65
$ this ->call ('getcandy:import:address-data ' );
@@ -116,6 +115,7 @@ public function handle(): void
116
115
'thousand_point ' => ', ' ,
117
116
'decimal_places ' => 2 ,
118
117
'default ' => true ,
118
+ 'enabled ' => true ,
119
119
]);
120
120
}
121
121
@@ -129,6 +129,15 @@ public function handle(): void
129
129
]);
130
130
}
131
131
132
+ if (!CollectionGroup::count ()) {
133
+ $ this ->info ('Adding an initial collection group ' );
134
+
135
+ CollectionGroup::create ([
136
+ 'name ' => 'Main ' ,
137
+ 'handle ' => 'main ' ,
138
+ ]);
139
+ }
140
+
132
141
if (! TaxClass::count ()) {
133
142
$ this ->info ('Adding a default tax class. ' );
134
143
@@ -301,11 +310,4 @@ private function publishConfiguration($forcePublish = false): void
301
310
302
311
$ this ->call ('vendor:publish ' , $ params );
303
312
}
304
-
305
- private function publishResources ()
306
- {
307
- $ this ->call ('vendor:publish ' , [
308
- '--tag ' => 'getcandy:hub:public ' ,
309
- ]);
310
- }
311
313
}
0 commit comments