public function setValue(Application $app, Request $request, $name) { $config = ConfigQuery::create()->findOneByName($name); if ($config === null) { $config = new Config(); $config->setName($name); } $config->setValue($request->get('value')); $config->save(); return new SuccessResponse(); }
/** * Exclude object from result * * @param ChildConfig $config Object to remove from the list of results * * @return $this|ChildConfigQuery The current query, for fluid interface */ public function prune($config = null) { if ($config) { $this->addUsingAlias(ConfigTableMap::COL_IDCONFIG, $config->getIdConfig(), Criteria::NOT_EQUAL); } return $this; }