diff --git a/FHC-vendor/jquery-tablesorter/package.json b/FHC-vendor/jquery-tablesorter/package.json
index b16fcb45e..110042959 100644
--- a/FHC-vendor/jquery-tablesorter/package.json
+++ b/FHC-vendor/jquery-tablesorter/package.json
@@ -56,7 +56,7 @@
]
},
"devDependencies": {
- "grunt": "^0.4.5",
+ "grunt": "^1.3.0",
"grunt-cli": "~0.1.13",
"grunt-contrib-clean": "^0.7.0",
"grunt-contrib-concat": "^0.5.1",
diff --git a/application/controllers/jobs/LehrauftragJob.php b/application/controllers/jobs/LehrauftragJob.php
index 4ba327a2f..7f5754595 100644
--- a/application/controllers/jobs/LehrauftragJob.php
+++ b/application/controllers/jobs/LehrauftragJob.php
@@ -383,8 +383,8 @@ class LehrauftragJob extends JOB_Controller
} // Else if UID exists
else
{
- // Search if studiensemester exists
- $ss_index = array_search($data['studiensemester_kurzbz'], array_column($mail_data_arr, 'studiensemester_kurzbz'));
+ // Search if studiensemester exists inside the existing UID array
+ $ss_index = array_search($data['studiensemester_kurzbz'], array_column($mail_data_arr[$uid_index], 'studiensemester_kurzbz'));
// If studiensemester is new, add studiensemester to existing UID
if ($ss_index === false)
@@ -394,13 +394,6 @@ class LehrauftragJob extends JOB_Controller
$data[$i]
);
}
- // Else if studiensemester exists
- else
- {
- // Add corresponding data to existing studiensemester of UID
- $mail_data_arr[$uid_index]['studiensemester_kurbz'][] = $data[$i];
- }
-
}
}
}
diff --git a/application/controllers/lehre/lehrauftrag/Lehrauftrag.php b/application/controllers/lehre/lehrauftrag/Lehrauftrag.php
index 8a096338e..0fe70a302 100644
--- a/application/controllers/lehre/lehrauftrag/Lehrauftrag.php
+++ b/application/controllers/lehre/lehrauftrag/Lehrauftrag.php
@@ -270,7 +270,6 @@ class Lehrauftrag extends Auth_Controller
private function _sendMail($lehrvertrag_data_arr)
{
// Cluster data of new lehrvertraege as needed to send mail
- $lehrvertrag_data_arr = $this->_cluster_newVertragData($lehrvertrag_data_arr);
foreach ($lehrvertrag_data_arr as $lehrvertrag_data)
{
diff --git a/application/controllers/system/infocenter/InfoCenter.php b/application/controllers/system/infocenter/InfoCenter.php
index 12d9a9c4d..44a1cf327 100644
--- a/application/controllers/system/infocenter/InfoCenter.php
+++ b/application/controllers/system/infocenter/InfoCenter.php
@@ -93,6 +93,7 @@ class InfoCenter extends Auth_Controller
const INTERESSENTSTATUS = 'Interessent';
const ABGEWIESENERSTATUS = 'Abgewiesener';
const BEWERBERSTATUS = 'Bewerber';
+ const WARTENDER = 'Wartender';
// Statusgruende for which no Studiengangsfreigabemessage should be sent
private $_statusgruendeNoStgFreigabeMessage = array('FIT Programm', 'FIT program', 'FIT programme');
@@ -137,7 +138,9 @@ class InfoCenter extends Auth_Controller
'setOnHold' => 'infocenter:rw',
'removeOnHold' => 'infocenter:rw',
'getStudienjahrEnd' => 'infocenter:r',
- 'setNavigationMenuArrayJson' => 'infocenter:r'
+ 'setNavigationMenuArrayJson' => 'infocenter:r',
+ 'getAbsageData' => 'infocenter:r',
+ 'saveAbsageForAll' => 'infocenter:rw'
)
);
@@ -715,11 +718,14 @@ class InfoCenter extends Auth_Controller
* Saves Absage for Prestudent including the reason for the Absage (statusgrund).
* inserts Studiensemester and Ausbildungssemester for the new Absage of (chronologically) last status.
*/
- public function saveAbsage()
+ public function saveAbsage($prestudent_id = null, $statusgrund = null)
{
$json = null;
- $prestudent_id = $this->input->post('prestudent_id');
- $statusgrund = $this->input->post('statusgrund');
+ if (is_null($prestudent_id))
+ $prestudent_id = $this->input->post('prestudent_id');
+
+ if (is_null($statusgrund))
+ $statusgrund = $this->input->post('statusgrund');
$lastStatus = $this->PrestudentstatusModel->getLastStatus($prestudent_id);
@@ -728,8 +734,10 @@ class InfoCenter extends Auth_Controller
if (hasData($lastStatus) && hasData($statusgrresult))
{
- //check if still Interessent and not freigegeben yet
- if ($lastStatus->retval[0]->status_kurzbz === self::INTERESSENTSTATUS && !isset($lastStatus->retval[0]->bestaetigtam))
+ //check if still Interessent
+ if ($lastStatus->retval[0]->status_kurzbz === self::INTERESSENTSTATUS
+ || $lastStatus->retval[0]->status_kurzbz === self::BEWERBERSTATUS
+ || $lastStatus->retval[0]->status_kurzbz === self::WARTENDER)
{
$result = $this->PrestudentstatusModel->insert(
array(
@@ -1760,6 +1768,8 @@ class InfoCenter extends Auth_Controller
|| isset($zgvpruefung->prestudentstatus->bestaetigtam)
|| $zgvpruefung->prestudentstatus->status_kurzbz != self::INTERESSENTSTATUS;
+ $zgvpruefung->abgewiesener = $zgvpruefung->prestudentstatus->status_kurzbz === self::ABGEWIESENERSTATUS;
+
//wether prestudent was freigegeben for RT/Stg
$zgvpruefung->isRtFreigegeben = false;
$zgvpruefung->isStgFreigegeben = false;
@@ -1841,8 +1851,8 @@ class InfoCenter extends Auth_Controller
$this->_sortPrestudents($zgvpruefungen);
- $abwstatusgruende = $this->StatusgrundModel->loadWhere(array('status_kurzbz' => self::ABGEWIESENERSTATUS))->retval;
- $intstatusgruende = $this->StatusgrundModel->loadWhere(array('status_kurzbz' => self::INTERESSENTSTATUS))->retval;
+ $abwstatusgruende = $this->StatusgrundModel->getStatus(self::ABGEWIESENERSTATUS, true)->retval;
+ $intstatusgruende = $this->StatusgrundModel->getStatus(self::INTERESSENTSTATUS)->retval;
$data = array (
'zgvpruefungen' => $zgvpruefungen,
@@ -2103,4 +2113,45 @@ class InfoCenter extends Auth_Controller
$this->loglib->logError('Studiengang has no mail for sending Freigabe mail');
}
}
+
+ public function getAbsageData()
+ {
+ $this->load->model('organisation/Studiengang_model', 'StudiengangModel');
+
+ $statusgruende = $this->StatusgrundModel->getStatus(self::ABGEWIESENERSTATUS, true)->retval;
+ $studienSemester = $this->variablelib->getVar('infocenter_studiensemester');
+ $studiengaenge = $this->StudiengangModel->getStudiengaengeWithOrgForm(['b', 'm'], $studienSemester);
+
+ $data = array (
+ 'statusgruende' => $statusgruende,
+ 'studiengaenge' => $studiengaenge->retval
+ );
+
+ $this->outputJsonSuccess($data);
+ }
+
+ public function saveAbsageForAll()
+ {
+ $statusgrund = $this->input->post('statusgrund');
+ $studiengang = $this->input->post('studiengang');
+ $personen = $this->input->post('personen');
+ $studienSemester = $this->variablelib->getVar('infocenter_studiensemester');
+
+ if ($statusgrund === 'null' || $studiengang === 'null' || empty($personen))
+ $this->terminateWithJsonError("Bitte Statusgrund, Studiengang und Personen auswählen.");
+
+ foreach($personen as $person)
+ {
+ $prestudent = $this->PrestudentModel->getPrestudentByStudiengangAndPerson($studiengang, $person, $studienSemester);
+
+ if(!hasData($prestudent))
+ continue;
+
+ $prestudentData = getData($prestudent);
+
+ $this->saveAbsage($prestudentData[0]->prestudent_id, $statusgrund);
+ }
+
+ $this->outputJsonSuccess("Success");
+ }
}
diff --git a/application/libraries/LDAPLib.php b/application/libraries/LDAPLib.php
index a119af51e..195dddc88 100644
--- a/application/libraries/LDAPLib.php
+++ b/application/libraries/LDAPLib.php
@@ -220,7 +220,9 @@ class LDAPLib
}
else // Connection error
{
- return error(ldap_error($ldapConnection));
+ return error(
+ 'An error occurred while connecting to the LDAP server: '.$ldapConfigs[self::SERVER].':'.$ldapConfigs[self::PORT]
+ );
}
}
}
diff --git a/application/models/CL/Messages_model.php b/application/models/CL/Messages_model.php
index 9ffd12cf6..4975af382 100644
--- a/application/models/CL/Messages_model.php
+++ b/application/models/CL/Messages_model.php
@@ -612,9 +612,9 @@ class Messages_model extends CI_Model
if (!isEmptyString($vorlage_kurzbz))
{
$this->load->model('system/Vorlagestudiengang_model', 'VorlagestudiengangModel');
- $this->VorlagestudiengangModel->addOrder('version','DESC');
+ $this->VorlagestudiengangModel->addOrder('version', 'DESC');
- $getVorlage = $this->VorlagestudiengangModel->loadWhere(array('vorlage_kurzbz' => $vorlage_kurzbz));
+ $getVorlage = $this->VorlagestudiengangModel->loadWhere(array('vorlage_kurzbz' => $vorlage_kurzbz, 'aktiv' => true));
}
return $getVorlage;
diff --git a/application/models/crm/Prestudent_model.php b/application/models/crm/Prestudent_model.php
index 2e014800c..52ba4d9f3 100644
--- a/application/models/crm/Prestudent_model.php
+++ b/application/models/crm/Prestudent_model.php
@@ -581,4 +581,19 @@ class Prestudent_model extends DB_Model
return $this->execQuery($query, array($person_id));
}
+
+ public function getPrestudentByStudiengangAndPerson($studiengang, $person, $studienSemester)
+ {
+ $query = "SELECT ps.prestudent_id
+ FROM public.tbl_prestudentstatus pss
+ JOIN public.tbl_prestudent ps USING(prestudent_id)
+ JOIN public.tbl_studiengang sg USING(studiengang_kz)
+ JOIN lehre.tbl_studienplan sp USING(studienplan_id)
+ WHERE ps.person_id = ?
+ AND UPPER((sg.typ || sg.kurzbz) || ':' || sp.orgform_kurzbz) = ?
+ AND pss.studiensemester_kurzbz = ?
+ ";
+
+ return $this->execQuery($query, array($person, $studiengang, $studienSemester));
+ }
}
diff --git a/application/models/crm/Statusgrund_model.php b/application/models/crm/Statusgrund_model.php
index 4717a7571..7ab17a45b 100644
--- a/application/models/crm/Statusgrund_model.php
+++ b/application/models/crm/Statusgrund_model.php
@@ -11,4 +11,18 @@ class Statusgrund_model extends DB_Model
$this->dbTable = "public.tbl_status_grund";
$this->pk = "statusgrund_id";
}
+
+ public function getStatus($status_kurzbz = null, $aktiv = null)
+ {
+ $this->addOrder('bezeichnung_mehrsprachig');
+ $where = array();
+ if (!is_null($status_kurzbz))
+ $where['status_kurzbz'] = $status_kurzbz;
+ if (!is_null($aktiv))
+ $where['aktiv'] = $aktiv;
+
+ $status = $this->loadWhere($where);
+
+ return success($status->retval);
+ }
}
diff --git a/application/models/organisation/Studiengang_model.php b/application/models/organisation/Studiengang_model.php
index 8b8be0366..41bdabd11 100644
--- a/application/models/organisation/Studiengang_model.php
+++ b/application/models/organisation/Studiengang_model.php
@@ -481,4 +481,18 @@ class Studiengang_model extends DB_Model
return $this->loadWhere($condition);
}
+
+ public function getStudiengaengeWithOrgForm($typ, $semester)
+ {
+ $query = "SELECT DISTINCT (UPPER(sg.typ || sg.kurzbz || ':' || sp.orgform_kurzbz)) AS Studiengang
+ FROM public.tbl_studiengang sg
+ JOIN lehre.tbl_studienordnung USING (studiengang_kz)
+ JOIN lehre.tbl_studienplan sp USING (studienordnung_id)
+ JOIN lehre.tbl_studienplan_semester spsem USING (studienplan_id)
+ WHERE sp.aktiv = TRUE AND sg.aktiv = TRUE AND sg.typ IN ?
+ AND spsem.studiensemester_kurzbz = ?
+ ORDER BY Studiengang";
+
+ return $this->execQuery($query, array($typ, $semester));
+ }
}
diff --git a/application/views/lehre/lehrauftrag/acceptLehrauftrag.php b/application/views/lehre/lehrauftrag/acceptLehrauftrag.php
index e87f0945c..521883452 100644
--- a/application/views/lehre/lehrauftrag/acceptLehrauftrag.php
+++ b/application/views/lehre/lehrauftrag/acceptLehrauftrag.php
@@ -189,7 +189,7 @@ $this->load->view(
-
+
diff --git a/application/views/lehre/lehrauftrag/acceptLehrauftragData.php b/application/views/lehre/lehrauftrag/acceptLehrauftragData.php
index f09eb62a0..92c896ce7 100644
--- a/application/views/lehre/lehrauftrag/acceptLehrauftragData.php
+++ b/application/views/lehre/lehrauftrag/acceptLehrauftragData.php
@@ -32,7 +32,7 @@ SELECT
erteilt,
akzeptiert,
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -48,7 +48,7 @@ SELECT
)
) AS "bestellt_von",
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -64,7 +64,7 @@ SELECT
)
) AS "erteilt_von",
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -241,7 +241,7 @@ FROM
\'Betreuung\' AS "typ",
(betreuerart_kurzbz || \' \' ||
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
PUBLIC.tbl_person
JOIN PUBLIC.tbl_benutzer USING (person_id)
diff --git a/application/views/lehre/lehrauftrag/approveLehrauftragData.php b/application/views/lehre/lehrauftrag/approveLehrauftragData.php
index 88b3eabd0..7c9669ae3 100644
--- a/application/views/lehre/lehrauftrag/approveLehrauftragData.php
+++ b/application/views/lehre/lehrauftrag/approveLehrauftragData.php
@@ -34,7 +34,7 @@ SELECT
erteilt,
akzeptiert,
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -50,7 +50,7 @@ SELECT
)
) AS "bestellt_von",
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -66,7 +66,7 @@ SELECT
)
) AS "erteilt_von",
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -128,7 +128,7 @@ FROM
(
SELECT
/* lehrauftraege also planned with dummies, therefore personalnummer is needed */
- ma.personalnummer,
+ (ma.personalnummer::text),
lema.lehreinheit_id,
lv.lehrveranstaltung_id,
lv.bezeichnung AS "lv_bezeichnung",
@@ -240,7 +240,7 @@ FROM
pa.lehreinheit_id,
lv.lehrveranstaltung_id,
lv.bezeichnung AS "lv_bezeichnung",
- pa.projektarbeit_id AS "projektarbeit_id",
+ (pa.projektarbeit_id::text) AS "projektarbeit_id",
le.studiensemester_kurzbz,
stg.studiengang_kz,
upper(stg.typ || stg.kurzbz) AS "stg_typ_kurzbz",
@@ -249,7 +249,7 @@ FROM
\'Betreuung\' AS "typ",
(betreuerart_kurzbz || \' \' ||
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
PUBLIC.tbl_person
JOIN PUBLIC.tbl_benutzer USING (person_id)
@@ -268,7 +268,7 @@ FROM
ELSE (oe.organisationseinheittyp_kurzbz ||
\' \' || oe.bezeichnung)
END AS "lv_oe_kurzbz",
- (nachname || \' \' || vorname) AS "lektor",
+ (vorname || \' \' || nachname) AS "lektor",
TRUNC(pb.stunden, 1) AS "stunden",
TRUNC((pb.stunden * pb.stundensatz), 2) AS "betrag",
vertrag_id,
diff --git a/application/views/lehre/lehrauftrag/cancelledLehrauftragData.php b/application/views/lehre/lehrauftrag/cancelledLehrauftragData.php
index 54948fb26..a3efb66b3 100644
--- a/application/views/lehre/lehrauftrag/cancelledLehrauftragData.php
+++ b/application/views/lehre/lehrauftrag/cancelledLehrauftragData.php
@@ -14,7 +14,7 @@ $query = '
datum AS "storniert",
(
SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
diff --git a/application/views/lehre/lehrauftrag/orderLehrauftragData.php b/application/views/lehre/lehrauftrag/orderLehrauftragData.php
index aea7d5181..1ccfc55a4 100644
--- a/application/views/lehre/lehrauftrag/orderLehrauftragData.php
+++ b/application/views/lehre/lehrauftrag/orderLehrauftragData.php
@@ -65,7 +65,7 @@ SELECT
erteilt,
akzeptiert,
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -81,7 +81,7 @@ SELECT
)
) AS "bestellt_von",
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -97,7 +97,7 @@ SELECT
)
) AS "erteilt_von",
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
public.tbl_person
JOIN public.tbl_benutzer benutzer USING (person_id)
@@ -281,7 +281,7 @@ FROM
\'Betreuung\' AS "typ",
(betreuerart_kurzbz || \' \' ||
(SELECT
- vorname || \' \' || nachname
+ nachname || \' \' || vorname
FROM
PUBLIC.tbl_person
JOIN PUBLIC.tbl_benutzer USING (person_id)
diff --git a/application/views/lehre/pruefungsprotokollUebersicht.php b/application/views/lehre/pruefungsprotokollUebersicht.php
index 35bea7963..c7de8fcd0 100644
--- a/application/views/lehre/pruefungsprotokollUebersicht.php
+++ b/application/views/lehre/pruefungsprotokollUebersicht.php
@@ -48,6 +48,8 @@
name="period" value="today">p->t('ui','heute'); ?>
+
diff --git a/application/views/lehre/pruefungsprotokollUebersichtData.php b/application/views/lehre/pruefungsprotokollUebersichtData.php
index dd247c2eb..ff2caa774 100644
--- a/application/views/lehre/pruefungsprotokollUebersichtData.php
+++ b/application/views/lehre/pruefungsprotokollUebersichtData.php
@@ -19,9 +19,10 @@ FROM
WHERE
vorsitz='".$UID."'
AND (
- '". $PERIOD. "' = 'today' AND datum = NOW()::date OR
- '". $PERIOD. "' = 'lastWeek' AND datum = (NOW() - interval '1 week')::date OR
- '". $PERIOD. "' = 'all' AND datum >= '2020-05-27'
+ ('". $PERIOD. "' = 'today' AND datum = NOW()::date) OR
+ ('". $PERIOD. "' = 'lastWeek' AND datum >= (NOW() - interval '1 week')::date AND datum < NOW()::date) OR
+ ('". $PERIOD. "' = 'upcoming' AND datum > NOW()::date) OR
+ ('". $PERIOD. "' = 'all' AND datum >= '2020-05-27')
)
ORDER BY datum, nachname, vorname
";
diff --git a/application/views/system/infocenter/absageModal.php b/application/views/system/infocenter/absageModal.php
new file mode 100644
index 000000000..00298945e
--- /dev/null
+++ b/application/views/system/infocenter/absageModal.php
@@ -0,0 +1,35 @@
+
+
+
+
+
+
p->t('infocenter', 'absageBestaetigen') ?>
+
+
+ p->t('infocenter', 'absageBestaetigenTxt') ?>
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/application/views/system/infocenter/infocenter.php b/application/views/system/infocenter/infocenter.php
index 4005518a1..38e644846 100644
--- a/application/views/system/infocenter/infocenter.php
+++ b/application/views/system/infocenter/infocenter.php
@@ -13,6 +13,7 @@
'ajaxlib' => true,
'filterwidget' => true,
'navigationwidget' => true,
+ 'dialoglib' => true,
'phrases' => array(
'person' => array('vorname', 'nachname'),
'global' => array('mailAnXversandt'),
@@ -40,6 +41,7 @@
diff --git a/cis/private/lehre/benotungstool/lvgesamtnoteverwalten.php b/cis/private/lehre/benotungstool/lvgesamtnoteverwalten.php
index 713b93dc5..407502178 100644
--- a/cis/private/lehre/benotungstool/lvgesamtnoteverwalten.php
+++ b/cis/private/lehre/benotungstool/lvgesamtnoteverwalten.php
@@ -12,10 +12,13 @@
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
- * Authors: Christian Paminger ,
+ *
+ * Authors:
+ * Christian Paminger ,
* Andreas Oesterreicher and
* Rudolf Hangl < rudolf.hangl@technikum-wien.at >
* Gerald Simane-Sequens < gerald.simane-sequens@technikum-wien.at >
+ * Manuela Thamer
*/
require_once ('../../../../config/cis.config.inc.php');
require_once ('../../../../config/global.config.inc.php');
@@ -306,6 +309,8 @@ foreach ($noten_obj->result as $row)
{
if(typeof(typ)=='undefined')
typ = 'Termin2';
+ var nn = document.getElementById(uid+"_nn").innerHTML;
+ var vn = document.getElementById(uid+"_vn").innerHTML;
var str = "