Daten fuer die Betriebsmittel und zutrittskarten_ausgegebenam gesammelt

This commit is contained in:
Simon Gschnell
2023-11-20 17:30:58 +01:00
parent 4fead18c06
commit 16b61d0560
5 changed files with 51 additions and 45 deletions
+22
View File
@@ -13,6 +13,28 @@ class Student_model extends DB_Model
$this->hasSequence = false;
}
/**
* Checks if the user is a Student.
* @param string $uid
* @return array
*/
public function isStudent($uid)
{
$this->addSelect('1');
$result = $this->loadWhere(array('student_uid' => $uid));
if(hasData($result))
{
return success(true);
}
else
{
return success(false);
}
}
// ****
// * Generiert die Matrikelnummer
// * FORMAT: 0710254001
@@ -1,41 +0,0 @@
<?php
class Student_model extends DB_Model
{
/**
* Constructor
*/
public function __construct()
{
parent::__construct();
$this->dbTable = 'public.tbl_student';
$this->pk = 'student_uid';
}
/**
* Checks if the user is a Student.
* @param string $uid
* @return array
*/
public function isStudent($uid)
{
$this->addSelect('1');
$result = $this->loadWhere(array('student_uid' => $uid));
if(hasData($result))
{
return success(true);
}
else
{
return success(false);
}
}
//! THIS FILE WAS CREATED USING THE Mitarbeiter_model.php FILE
}