Conditions | 1 |
Paths | 1 |
Total Lines | 18 |
Code Lines | 10 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
38 | public function handle() |
||
39 | { |
||
40 | $this->line('[Counters] Creating the counter...'); |
||
41 | |||
42 | $key = $this->argument('key'); |
||
43 | $name = $this->argument('name'); |
||
44 | $initial_value = $this->argument('initial_value'); |
||
45 | $step = $this->argument('step'); |
||
46 | |||
47 | $value = $initial_value; |
||
48 | |||
49 | Counter::query()->create( |
||
50 | compact('key', 'name', 'initial_value', 'step', 'value') |
||
51 | ); |
||
52 | |||
53 | $this->info("[Counters] Counter $key created Successfully"); |
||
54 | |||
55 | return; |
||
56 | } |
||
58 |