Merge branch 'description'
This commit is contained in:
commit
7ddb89069d
4 changed files with 32 additions and 2 deletions
|
|
@ -202,7 +202,8 @@ class ImportProfession implements ShouldQueue
|
|||
$recipe = $profession->recipes()->create([
|
||||
'item_id' => $crafted ? $crafted->id : null,
|
||||
'spell_id' => $spell->id,
|
||||
'category_id' => $category->id
|
||||
'category_id' => $category->id,
|
||||
'description' => isset($data->description) ? $data->description : null
|
||||
]);
|
||||
}
|
||||
// Existing record.
|
||||
|
|
@ -216,6 +217,10 @@ class ImportProfession implements ShouldQueue
|
|||
if (!$recipe->spell) {
|
||||
$recipe->spell()->associate($spell);
|
||||
}
|
||||
|
||||
if ($recipe->description === NULL && isset($data->description)) {
|
||||
$recipe->description = $data->description;
|
||||
}
|
||||
}
|
||||
|
||||
// Insert/Update Reagents
|
||||
|
|
|
|||
|
|
@ -34,7 +34,8 @@ class Recipe extends Model
|
|||
'profession_id',
|
||||
'category_id',
|
||||
'item_id',
|
||||
'spell_id'
|
||||
'spell_id',
|
||||
'description'
|
||||
];
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue