diff --git a/src/Assets/AssetContainer.php b/src/Assets/AssetContainer.php index afa01415..70c5515f 100644 --- a/src/Assets/AssetContainer.php +++ b/src/Assets/AssetContainer.php @@ -53,6 +53,8 @@ public function fillFromModel(Model $model) ->sourcePreset($model->settings['source_preset'] ?? null) ->warmPresets($model->settings['warm_presets'] ?? null) ->validationRules($model->settings['validation_rules'] ?? null) + ->sortField($model->settings['sort_by'] ?? null) + ->sortDirection($model->settings['sort_dir'] ?? null) ->model($model); return $this; @@ -81,6 +83,8 @@ public static function makeModelFromContract(AssetContainerContract $source) 'source_preset' => $source->sourcePreset, 'warm_presets' => $source->warmPresets, 'validation_rules' => $source->validationRules(), + 'sort_by' => $source->sortField(), + 'sort_dir' => $source->sortDirection(), ]); // Set initial timestamps.