vendor categories fx9
This commit is contained in:
parent
e77e509b14
commit
170ae64c85
|
|
@ -62,12 +62,16 @@ class CategoryRepository extends WCategoryRepository
|
||||||
$category->vendors()->sync($data['vendors']);
|
$category->vendors()->sync($data['vendors']);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return $category;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function update(array $data, $id, $attribute = 'id'){
|
public function update(array $data, $id, $attribute = 'id'){
|
||||||
$category = parent::update($data,$id,$attribute );
|
$category = parent::update($data,$id,$attribute );
|
||||||
|
|
||||||
if (isset($data['vendors'])) {
|
if (isset($data['vendors'])) {
|
||||||
$category->vendors()->sync($data['vendors']);
|
$category->vendors()->sync($data['vendors']);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return $category;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue