Laravel 11, Vuexy Admin 10.3, by admin@koneko.mx
This commit is contained in:
39
modules/Admin/App/Models/Sat/Pais.php
Normal file
39
modules/Admin/App/Models/Sat/Pais.php
Normal file
@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Admin\App\Models\Sat;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Pais extends Model
|
||||
{
|
||||
/**
|
||||
* The table associated with the model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $table = 'sat_pais';
|
||||
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*
|
||||
* @var string[]
|
||||
*/
|
||||
protected $fillable = [
|
||||
'c_pais',
|
||||
'descripcion',
|
||||
'formato_de_codigo_postal',
|
||||
'formato_de_registro_de_identidad_tributaria',
|
||||
'validacion_del_registro_de_identidad_tributaria',
|
||||
'agrupaciones',
|
||||
];
|
||||
|
||||
public static function selectList()
|
||||
{
|
||||
return self::select('c_pais', 'descripcion')
|
||||
->get()
|
||||
->mapWithKeys(function ($item) {
|
||||
return [$item->c_pais => $item->c_pais . ' - ' . $item->descripcion];
|
||||
});
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user