/** * Update an existing item * * @return boolean */ public function update(array $input) { // add checkboxes data $input['has_categories'] = Input::get('has_categories', 0); $input['parent_id'] = Input::get('parent_id') ?: null; return parent::update($input); }
/** * Update an existing item * * @param array $input * @return boolean */ public function update(array $input) { // add checkboxes data $input['rss_enabled'] = Input::get('rss_enabled', 0); $input['comments_enabled'] = Input::get('comments_enabled', 0); $input['is_home'] = Input::get('is_home', 0); $input['parent_id'] = Input::get('parent_id') ?: null; $input['redirect'] = Input::get('redirect') ?: null; // add relations data (default to empty array) $input['galleries'] = Input::get('galleries', []); return parent::update($input); }
public function update(array $input) { $this->validator->setRule('name', 'required|unique:menus,name,' . $input['id']); return parent::update($input); }
/** * Update an existing item * * @param array $input * @return boolean */ public function update(array $input) { // add relations data (default to empty array) $input['galleries'] = Input::get('galleries', []); return parent::update($input); }