diff --git a/app/Models/User.php b/app/Models/User.php index ec1ae58..fc56f24 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -8,24 +8,14 @@ use Illuminate\Notifications\Notifiable; use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Hash; use Laravel\Sanctum\HasApiTokens; -<<<<<<< HEAD use Spatie\Permission\Traits\HasRoles; use Illuminate\Foundation\Auth\Access\Authorizable; -======= - //use LdapRecord\Laravel\Auth\Authenticatable; - -use Junges\ACL\Concerns\HasGroups; ->>>>>>> 3ebca7bb4a04430aecf781bee6ba7b1a1ec56a41 class User extends Authenticatable { -<<<<<<< HEAD use HasApiTokens, HasFactory, Notifiable, HasRoles,Authorizable; -======= - use HasApiTokens, HasFactory, Notifiable, HasGroups, SoftDeletes; ->>>>>>> 3ebca7bb4a04430aecf781bee6ba7b1a1ec56a41 /** * The attributes that are mass assignable. @@ -57,7 +47,7 @@ class User extends Authenticatable protected $casts = [ 'email_verified_at' => 'datetime', ]; - + protected $guard_name = 'web'; public function getLdapDomainColumn() @@ -80,13 +70,12 @@ class User extends Authenticatable { return DB::table('users')->where('id','=',$id)->get(); } - + public static function getUsers() { return DB::table('users')->orderBy('name')->get(); } -<<<<<<< HEAD - + // Aggiunge un utente e assegna un ruolo public static function addUser($params) { @@ -95,14 +84,10 @@ class User extends Authenticatable 'email'=>$params['email'], 'password'=>Hash::make($params['password']), ])->assignRole($params['role']); - + } - - -======= ->>>>>>> 3ebca7bb4a04430aecf781bee6ba7b1a1ec56a41 } diff --git a/public/js/app/altrocontatto.js b/public/js/app/altrocontatto.js index f53a64b..ccf9ab9 100644 --- a/public/js/app/altrocontatto.js +++ b/public/js/app/altrocontatto.js @@ -1,10 +1,21 @@ $(document).ready(function() { $('#automobili').DataTable({ responsive: true + fields: [ + { + label:"Data", + type: "datetime" + } + ] }); -}); -$(document).ready(function() { + $('#contatti').DataTable({ responsive: true + fields: [ + { + label:"Data", + type: "datetime" + } + ] }); -}); \ No newline at end of file +}); diff --git a/public/js/app/auto.js b/public/js/app/auto.js index 1b2af60..417142f 100644 --- a/public/js/app/auto.js +++ b/public/js/app/auto.js @@ -1,6 +1,12 @@ $(document).ready(function() { $('#automobili').DataTable({ responsive: true + fields: [ + { + label:"Data", + type: "datetime" + } + ] }); }); @@ -26,7 +32,7 @@ $(document).on('click', '.open_modal_modify', function() { $.getJSON(url + '/' + riga_id, function(data) { $('.modal-title').text('Modifica Automobile'); - // $('#id').val(data.mov_data); + // $('#id').val(data.mov_data); $('#targa').val(data.targa); $('#marca').val(data.marca); $('#modello').val(data.modello); @@ -85,4 +91,4 @@ $(document).on('click', '.open_modal_nuovo', function() { $('#myModal_nuovo').modal('show'); // $('.modal-title').append(' entrata'); $('#form').attr('action', 'movimentie'); -}); \ No newline at end of file +}); diff --git a/public/js/app/conti_categorie.js b/public/js/app/conti_categorie.js index 870e28d..a07ac71 100644 --- a/public/js/app/conti_categorie.js +++ b/public/js/app/conti_categorie.js @@ -1,33 +1,42 @@ $(document).ready(function() { $('#listrapportoS').DataTable({ - responsive: true + responsive: true, + fields: [ + { + label:"Data", + type: "datetime" + } + ] }); -}); -$(document).ready(function() { + $('#listrapportoE').DataTable({ - responsive: true + responsive: true, + fields: [ + { + label:"Data", + type: "datetime" + } + ] }); + + $('#categorie').DataTable({ + responsive: true + }); + }); +$(document).on('click','.open_modal',function(){ + var url = "/admin/categorie/modify"; + var riga_id= $(this).val(); + $.getJSON(url + '/' + riga_id, function (data) { + //success data + console.log(data[0]); + console.log(data[0].cat_name); + $('#H_cat_cat_name').val(data[0].cat_name); + $('#H_cat_id').val(data[0].id); + $('#myModal').modal('show'); + }); +}); +$(document).on('click','.open_modal_new',function(){ + $('#myModal_new').modal('show'); + }); - $(document).ready(function() { - $('#categorie').DataTable({ - responsive: true - }); - - $(document).on('click','.open_modal',function(){ - var url = "/admin/categorie/modify"; - var riga_id= $(this).val(); - $.getJSON(url + '/' + riga_id, function (data) { - //success data - console.log(data[0]); - console.log(data[0].cat_name); - $('#H_cat_cat_name').val(data[0].cat_name); - $('#H_cat_id').val(data[0].id); - $('#myModal').modal('show'); - }); - }); - $(document).on('click','.open_modal_new',function(){ - $('#myModal_new').modal('show'); - - }); - });