I have this query
$orderStates = OrderState::listsTranslations( 'states' )->pluck( 'states', 'id' )->toArray();
which will output something like
array:3 [▼
1 => "waiting"
2 => "agreed"
3 => "canceled"
]
I need to skip the first one to be something like
array:3 [▼
2 => "agreed"
3 => "canceled"
]
How this can be done please?
First thanks for Namoshek guide but skip(1)
didn't work with this but slice(1)
did
Here is the last query
$orderStates = OrderState::listsTranslations( 'states' )
->pluck( 'states', 'id' )
->slice( 1 )
->toArray();
Worked fine.