<?php

namespace App\Repositories\Shop;

use App\Models\Shop\Package;
use App\Traits\Model\Basic;

class Packages
{
    use Basic;

    public static function init()
    {
        return [
            'families' => ArticleNatures::getOptions(),
        ];
    }

    public static function getOptions()
    {
        return Package::orderBy('value', 'asc')->pluck('value', 'id')->toArray();
    }

    public static function getAll()
    {
        return Package::orderBy('value', 'asc')->get();
    }

    public static function getName($id)
    {
        return self::get($id)->value;
    }

    public static function getModel()
    {
        return Package::query();
    }
}
