1
0
mirror of https://github.com/devcode-it/openstamanager.git synced 2025-02-19 21:10:49 +01:00
This commit is contained in:
Thomas Zilio 2019-09-07 15:57:33 +02:00
parent 1ad4e04e59
commit 272054090e
2 changed files with 11 additions and 4 deletions

View File

@ -137,6 +137,8 @@ switch (post('op')) {
$new->qta = 0; $new->qta = 0;
$new->save(); $new->save();
$id_record = $new->id;
flash()->info(tr('Articolo duplicato correttamente!')); flash()->info(tr('Articolo duplicato correttamente!'));
break; break;

View File

@ -70,10 +70,7 @@ class Articolo extends Model
return true; return true;
} }
public function articoli() // Attributi Eloquent
{
return $this->hasMany(ArticoloIntervento::class, 'idarticolo');
}
public function getImageAttribute() public function getImageAttribute()
{ {
@ -102,4 +99,12 @@ class Articolo extends Model
{ {
return 'Articoli'; return 'Articoli';
} }
// Relazioni Eloquent
public function articoli()
{
return $this->hasMany(ArticoloIntervento::class, 'idarticolo');
}
} }