mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-26 09:04:28 +00:00
Codesniffer compliant: if, for and while
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Ampel extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Ampel extends APIv1_Controller
|
||||
{
|
||||
$ampelID = $this->get('ampel_id');
|
||||
|
||||
if(isset($ampelID))
|
||||
if (isset($ampelID))
|
||||
{
|
||||
$result = $this->AmpelModel->load($ampelID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Ampel extends APIv1_Controller
|
||||
*/
|
||||
public function postAmpel()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['ampel_id']))
|
||||
if (isset($this->post()['ampel_id']))
|
||||
{
|
||||
$result = $this->AmpelModel->update($this->post()['ampel_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Content extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Content extends APIv1_Controller
|
||||
{
|
||||
$contentID = $this->get('content_id');
|
||||
|
||||
if(isset($contentID))
|
||||
if (isset($contentID))
|
||||
{
|
||||
$result = $this->ContentModel->load($contentID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Content extends APIv1_Controller
|
||||
*/
|
||||
public function postContent()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['content_id']))
|
||||
if (isset($this->post()['content_id']))
|
||||
{
|
||||
$result = $this->ContentModel->update($this->post()['content_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Contentchild extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Contentchild extends APIv1_Controller
|
||||
{
|
||||
$contentchildID = $this->get('contentchild_id');
|
||||
|
||||
if(isset($contentchildID))
|
||||
if (isset($contentchildID))
|
||||
{
|
||||
$result = $this->ContentchildModel->load($contentchildID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Contentchild extends APIv1_Controller
|
||||
*/
|
||||
public function postContentchild()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['contentchild_id']))
|
||||
if (isset($this->post()['contentchild_id']))
|
||||
{
|
||||
$result = $this->ContentchildModel->update($this->post()['contentchild_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Contentgruppe extends APIv1_Controller
|
||||
{
|
||||
@@ -36,7 +36,7 @@ class Contentgruppe extends APIv1_Controller
|
||||
$gruppe_kurzbz = $this->get('gruppe_kurzbz');
|
||||
$content_id = $this->get('content_id');
|
||||
|
||||
if(isset($gruppe_kurzbz) && isset($content_id))
|
||||
if (isset($gruppe_kurzbz) && isset($content_id))
|
||||
{
|
||||
$result = $this->ContentgruppeModel->load(array($gruppe_kurzbz, $content_id));
|
||||
|
||||
@@ -53,9 +53,9 @@ class Contentgruppe extends APIv1_Controller
|
||||
*/
|
||||
public function postContentgruppe()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['gruppe_kurzbz']) && isset($this->post()['content_id']))
|
||||
if (isset($this->post()['gruppe_kurzbz']) && isset($this->post()['content_id']))
|
||||
{
|
||||
$result = $this->ContentgruppeModel->update(array($this->post()['gruppe_kurzbz'], $this->post()['content_id']), $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Contentlog extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Contentlog extends APIv1_Controller
|
||||
{
|
||||
$contentlogID = $this->get('contentlog_id');
|
||||
|
||||
if(isset($contentlogID))
|
||||
if (isset($contentlogID))
|
||||
{
|
||||
$result = $this->ContentlogModel->load($contentlogID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Contentlog extends APIv1_Controller
|
||||
*/
|
||||
public function postContentlog()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['contentlog_id']))
|
||||
if (isset($this->post()['contentlog_id']))
|
||||
{
|
||||
$result = $this->ContentlogModel->update($this->post()['contentlog_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Contentsprache extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Contentsprache extends APIv1_Controller
|
||||
{
|
||||
$contentspracheID = $this->get('contentsprache_id');
|
||||
|
||||
if(isset($contentspracheID))
|
||||
if (isset($contentspracheID))
|
||||
{
|
||||
$result = $this->ContentspracheModel->load($contentspracheID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Contentsprache extends APIv1_Controller
|
||||
*/
|
||||
public function postContentsprache()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['contentsprache_id']))
|
||||
if (isset($this->post()['contentsprache_id']))
|
||||
{
|
||||
$result = $this->ContentspracheModel->update($this->post()['contentsprache_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Dms extends APIv1_Controller
|
||||
{
|
||||
@@ -36,18 +36,18 @@ class Dms extends APIv1_Controller
|
||||
$dms_id = $this->get('dms_id');
|
||||
$version = $this->get('version');
|
||||
|
||||
if(isset($dms_id))
|
||||
if (isset($dms_id))
|
||||
{
|
||||
$result = $this->DmsModel->addJoin('campus.tbl_dms_version', 'dms_id');
|
||||
if($result->error == EXIT_SUCCESS)
|
||||
if ($result->error == EXIT_SUCCESS)
|
||||
{
|
||||
$result = $this->DmsModel->addOrder('version', 'DESC');
|
||||
if($result->error == EXIT_SUCCESS)
|
||||
if ($result->error == EXIT_SUCCESS)
|
||||
{
|
||||
$result = $this->DmsModel->addLimit(1);
|
||||
if($result->error == EXIT_SUCCESS)
|
||||
if ($result->error == EXIT_SUCCESS)
|
||||
{
|
||||
if(!isset($version))
|
||||
if (!isset($version))
|
||||
{
|
||||
$result = $this->DmsModel->loadWhere(array('dms_id' => $dms_id));
|
||||
}
|
||||
@@ -72,9 +72,9 @@ class Dms extends APIv1_Controller
|
||||
*/
|
||||
public function postDms()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['contentsprache_id']))
|
||||
if (isset($this->post()['contentsprache_id']))
|
||||
{
|
||||
$result = $this->ContentspracheModel->update($this->post()['contentsprache_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Infoscreen extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Infoscreen extends APIv1_Controller
|
||||
{
|
||||
$infoscreenID = $this->get('infoscreen_id');
|
||||
|
||||
if(isset($infoscreenID))
|
||||
if (isset($infoscreenID))
|
||||
{
|
||||
$result = $this->InfoscreenModel->load($infoscreenID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Infoscreen extends APIv1_Controller
|
||||
*/
|
||||
public function postInfoscreen()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['infoscreen_id']))
|
||||
if (isset($this->post()['infoscreen_id']))
|
||||
{
|
||||
$result = $this->InfoscreenModel->update($this->post()['infoscreen_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class News extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class News extends APIv1_Controller
|
||||
{
|
||||
$newsID = $this->get('news_id');
|
||||
|
||||
if(isset($newsID))
|
||||
if (isset($newsID))
|
||||
{
|
||||
$result = $this->NewsModel->load($newsID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class News extends APIv1_Controller
|
||||
*/
|
||||
public function postNews()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['news_id']))
|
||||
if (isset($this->post()['news_id']))
|
||||
{
|
||||
$result = $this->NewsModel->update($this->post()['news_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Template extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Template extends APIv1_Controller
|
||||
{
|
||||
$template_kurzbz = $this->get('template_kurzbz');
|
||||
|
||||
if(isset($template_kurzbz))
|
||||
if (isset($template_kurzbz))
|
||||
{
|
||||
$result = $this->TemplateModel->load($template_kurzbz);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Template extends APIv1_Controller
|
||||
*/
|
||||
public function postTemplate()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['template_kurzbz']))
|
||||
if (isset($this->post()['template_kurzbz']))
|
||||
{
|
||||
$result = $this->TemplateModel->update($this->post()['template_kurzbz'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Veranstaltung extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Veranstaltung extends APIv1_Controller
|
||||
{
|
||||
$veranstaltungID = $this->get('veranstaltung_id');
|
||||
|
||||
if(isset($veranstaltungID))
|
||||
if (isset($veranstaltungID))
|
||||
{
|
||||
$result = $this->VeranstaltungModel->load($veranstaltungID);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Veranstaltung extends APIv1_Controller
|
||||
*/
|
||||
public function postVeranstaltung()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['veranstaltung_id']))
|
||||
if (isset($this->post()['veranstaltung_id']))
|
||||
{
|
||||
$result = $this->VeranstaltungModel->update($this->post()['veranstaltung_id'], $this->post());
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
*/
|
||||
// ------------------------------------------------------------------------
|
||||
|
||||
if(!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
if (!defined('BASEPATH')) exit('No direct script access allowed');
|
||||
|
||||
class Veranstaltungskategorie extends APIv1_Controller
|
||||
{
|
||||
@@ -35,7 +35,7 @@ class Veranstaltungskategorie extends APIv1_Controller
|
||||
{
|
||||
$veranstaltungskategorie_kurzbz = $this->get('veranstaltungskategorie_kurzbz');
|
||||
|
||||
if(isset($veranstaltungskategorie_kurzbz))
|
||||
if (isset($veranstaltungskategorie_kurzbz))
|
||||
{
|
||||
$result = $this->VeranstaltungskategorieModel->load($veranstaltungskategorie_kurzbz);
|
||||
|
||||
@@ -52,9 +52,9 @@ class Veranstaltungskategorie extends APIv1_Controller
|
||||
*/
|
||||
public function postVeranstaltungskategorie()
|
||||
{
|
||||
if($this->_validate($this->post()))
|
||||
if ($this->_validate($this->post()))
|
||||
{
|
||||
if(isset($this->post()['veranstaltungskategorie_kurzbz']))
|
||||
if (isset($this->post()['veranstaltungskategorie_kurzbz']))
|
||||
{
|
||||
$result = $this->VeranstaltungskategorieModel->update($this->post()['veranstaltungskategorie_kurzbz'], $this->post());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user