218 : void
219 {
220 $mt = $this->gui->ui()->mainTemplate();
222 $ctrl = $this->gui->ctrl();
223 $lng = $this->domain->lng();
224
225 $old_settings = $this->domain->blogSettings()->getByObjId($this->obj_id);
226
227 if ($form->isValid()) {
228 $form->saveStdTitleAndDescription(
229 $this->obj_id,
230 "blog"
231 );
232 $form->saveStdTile(
233 $this->obj_id,
234 "blog"
235 );
236 $form->saveOnline(
237 $this->obj_id,
238 "blog"
239 );
240
241 $this->notes->activateComments($this->obj_id, (bool) $form->getData("notes"));
242
243 $this->reading_time_gui->saveSettingFromFormAdapter($form);
244
245 $settings = $this->data->settings(
246 $this->obj_id,
247 (bool) $form->getData("ppic"),
248 "",
249 "",
250 $this->global_settings->get('enable_global_profiles')
251 ? (bool) $form->getData("ppic")
252 : false,
253 $this->in_repository
254 ? (bool) $form->getData("approval")
255 : false,
256 (bool) $form->getData("abss"),
257 (bool) $form->getData("abss")
258 ? (int) $form->getData("abssl")
259 : 0,
260 (bool) $form->getData("absi"),
261 (bool) $form->getData("absi")
262 ? (int) $form->getData("absiw")
263 : 0,
264 (bool) $form->getData("absi")
265 ? (int) $form->getData("absih")
266 : 0,
267 (bool) $form->getData("keywords"),
268 $this->in_repository
269 ? (bool) $form->getData("nav_authors")
270 : false,
271 (int) $form->getData("nav_mode"),
273 ? (int) $form->getData("nav_list_mon_with_post")
274 : 0,
276 ? (int) $form->getData("nav_list_mon")
277 : 0,
278 (int) $form->getData("ov_list_post_num"),
279 $old_settings->getOrder()
280 );
281
282 $this->domain->blogSettings()->update($settings);
283
284 $mt->setOnScreenMessage(
"success",
$lng->txt(
"msg_obj_modified"),
true);
285 $ctrl->redirectByClass(self::class, "edit");
286 } else {
287 $mt = $this->gui->ui()->mainTemplate();
288 $mt->setContent($form->render());
289 }
290 }