mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-24 02:12:17 +00:00
Merge branch 'master' into feature-67550/CIS4_Profilupdate_Finetuning
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
class Kontaktverifikation_model extends DB_Model
|
||||
{
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->dbTable = 'public.tbl_kontakt_verifikation';
|
||||
$this->pk = 'kontakt_verifikation_id';
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets contact verification for a person and a verification code
|
||||
* @param person_id
|
||||
* @param kontakttyp
|
||||
* @param verifikation_code
|
||||
* @param expiration_days number of days after which verifikation code expires
|
||||
* @return object success or error
|
||||
*/
|
||||
public function getKontaktVerifikation($person_id, $kontakttyp, $verifikation_code, $expiration_days = 1)
|
||||
{
|
||||
$qry = "
|
||||
SELECT
|
||||
kt.kontakt_id,
|
||||
kv.verifikation_code
|
||||
FROM
|
||||
public.tbl_kontakt_verifikation kv
|
||||
JOIN public.tbl_kontakt kt USING(kontakt_id)
|
||||
WHERE kt.person_id = ?
|
||||
AND kt.kontakttyp = ?
|
||||
AND kv.verifikation_code = ?
|
||||
AND kv.erstelldatum >= NOW() - INTERVAL '".$this->escape($expiration_days)." days'
|
||||
ORDER BY
|
||||
kt.kontakt_id DESC
|
||||
LIMIT 1";
|
||||
|
||||
return $this->execQuery($qry, array($person_id, $kontakttyp, $verifikation_code));
|
||||
}
|
||||
}
|
||||
@@ -76,7 +76,7 @@ class Reservierung_model extends DB_Model
|
||||
*
|
||||
* @return stdClass
|
||||
*/
|
||||
public function getReservierungenMitarbeiter($start_date, $end_date, $ort_kurzbz = null)
|
||||
public function getReservierungenMitarbeiter($start_date, $end_date)
|
||||
{
|
||||
|
||||
$raum_reservierungen_query = "SELECT res.*, beginn, ende,
|
||||
@@ -89,7 +89,6 @@ class Reservierung_model extends DB_Model
|
||||
JOIN lehre.tbl_stunde ON lehre.tbl_stunde.stunde = res.stunde
|
||||
WHERE res.uid = ? AND datum >= ? AND datum <= ?";
|
||||
|
||||
// $subquery = is_null($ort_kurzbz)? $lvplan_reservierungen_query:$raum_reservierungen_query;
|
||||
$subquery = $raum_reservierungen_query;
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user