mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-15 22:12:16 +00:00
absagen nun möglich auch bei studenten die den reihungstest absolviert haben
This commit is contained in:
@@ -70,6 +70,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');
|
||||
@@ -452,7 +453,9 @@ class InfoCenter extends Auth_Controller
|
||||
if (hasData($lastStatus) && hasData($statusgrresult))
|
||||
{
|
||||
//check if still Interessent
|
||||
if ($lastStatus->retval[0]->status_kurzbz === self::INTERESSENTSTATUS)
|
||||
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(
|
||||
@@ -1700,7 +1703,8 @@ class InfoCenter extends Auth_Controller
|
||||
$this->load->model('organisation/Studiengang_model', 'StudiengangModel');
|
||||
|
||||
$statusgruende = $this->StatusgrundModel->getStatus(self::ABGEWIESENERSTATUS, true)->retval;
|
||||
$studiengaenge = $this->StudiengangModel->getStudiengaengeWithOrgForm(['b', 'm']);
|
||||
$studienSemester = $this->variablelib->getVar('infocenter_studiensemester');
|
||||
$studiengaenge = $this->StudiengangModel->getStudiengaengeWithOrgForm(['b', 'm'], $studienSemester);
|
||||
|
||||
$data = array (
|
||||
'statusgruende' => $statusgruende,
|
||||
|
||||
@@ -482,16 +482,17 @@ class Studiengang_model extends DB_Model
|
||||
return $this->loadWhere($condition);
|
||||
}
|
||||
|
||||
public function getStudiengaengeWithOrgForm($typ)
|
||||
public function getStudiengaengeWithOrgForm($typ, $semester)
|
||||
{
|
||||
$query = "SELECT DISTINCT (UPPER(sg.typ || sg.kurzbz || ':' || sp.orgform_kurzbz)) AS Studiengang
|
||||
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 sg.typ IN ?
|
||||
ORDER BY 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));
|
||||
return $this->execQuery($query, array($typ, $semester));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -114,6 +114,12 @@
|
||||
sg.studiengang_kz in('.$ADDITIONAL_STG.')
|
||||
)
|
||||
AND pss.studiensemester_kurzbz = '.$STUDIENSEMESTER.'
|
||||
AND NOT EXISTS (
|
||||
SELECT 1
|
||||
FROM tbl_prestudentstatus spss
|
||||
WHERE spss.prestudent_id = ps.prestudent_id
|
||||
AND spss.status_kurzbz = '.$REJECTED_STATUS.'
|
||||
)
|
||||
LIMIT 1
|
||||
) AS "StgAbgeschickt",
|
||||
(
|
||||
|
||||
@@ -83,10 +83,11 @@
|
||||
LIMIT 1
|
||||
) AS "AnzahlAbgeschickt",
|
||||
(
|
||||
SELECT ARRAY_TO_STRING(ARRAY_AGG(DISTINCT UPPER(sg.typ || sg.kurzbz || \':\' || sg.orgform_kurzbz)), \', \')
|
||||
SELECT ARRAY_TO_STRING(ARRAY_AGG(DISTINCT UPPER(sg.typ || sg.kurzbz || \':\' || sp.orgform_kurzbz)), \', \')
|
||||
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 pss.status_kurzbz = '.$INTERESSENT_STATUS.'
|
||||
AND pss.bewerbung_abgeschicktamum IS NOT NULL
|
||||
AND ps.person_id = p.person_id
|
||||
|
||||
@@ -344,7 +344,7 @@
|
||||
|
||||
<?php
|
||||
//Prestudenten cannot be abgewiesen or freigegeben if already done
|
||||
if (!$infoonly) :
|
||||
if (!$infoonly || (isset($zgvpruefung->prestudentstatus->status_kurzbz) && in_array($zgvpruefung->prestudentstatus->status_kurzbz, ['Bewerber', 'Wartender']))) :
|
||||
?>
|
||||
<div class="panel-footer solidtop">
|
||||
<div class="row">
|
||||
@@ -368,130 +368,97 @@
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<div class="modal fade absageModal" id="absageModal_<?php echo $zgvpruefung->prestudent_id ?>"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="absageModalLabel"
|
||||
aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-hidden="true">
|
||||
×
|
||||
</button>
|
||||
<h4 class="modal-title"
|
||||
id="absageModalLabel"><?php echo $this->p->t('infocenter', 'absageBestaetigen') ?></h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<?php echo $this->p->t('infocenter', 'absageBestaetigenTxt') ?>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal">
|
||||
<?php echo $this->p->t('ui', 'abbrechen') ?>
|
||||
</button>
|
||||
<button class="btn btn-primary saveAbsage" id="saveAbsage_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentAbweisen') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.modal-content -->
|
||||
</div>
|
||||
<!-- /.modal-dialog -->
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.column-absage -->
|
||||
<?php
|
||||
$disabled = $disabledStg = $disabledTxt = $disabledStgTxt = '';
|
||||
if (isEmptyString($zgvpruefung->prestudentstatus->bewerbung_abgeschicktamum))
|
||||
{
|
||||
$disabled = $disabledStg = 'disabled';
|
||||
$disabledTxt = $disabledStgTxt = $this->p->t('infocenter', 'bewerbungMussAbgeschickt');
|
||||
}
|
||||
<?php
|
||||
$disabled = $disabledStg = $disabledTxt = $disabledStgTxt = '';
|
||||
if (isEmptyString($zgvpruefung->prestudentstatus->bewerbung_abgeschicktamum))
|
||||
{
|
||||
$disabled = $disabledStg = 'disabled';
|
||||
$disabledTxt = $disabledStgTxt = $this->p->t('infocenter', 'bewerbungMussAbgeschickt');
|
||||
}
|
||||
|
||||
if ($studiengangtyp !== 'b')
|
||||
{
|
||||
$disabled = 'disabled';
|
||||
$disabledTxt = $this->p->t('infocenter', 'nurBachelorFreigeben');
|
||||
if ($studiengangtyp !== 'b')
|
||||
{
|
||||
$disabled = 'disabled';
|
||||
$disabledTxt = $this->p->t('infocenter', 'nurBachelorFreigeben');
|
||||
|
||||
// FIT-Lehrgänge: exceptions, can be freigegeben in Infocenter
|
||||
if (!in_array($studiengang_kz, $fit_programme_studiengaenge))
|
||||
{
|
||||
$disabledStg = 'disabled';
|
||||
$disabledStgTxt = $this->p->t('infocenter', 'nurBachelorFreigeben');
|
||||
}
|
||||
// FIT-Lehrgänge: exceptions, can be freigegeben in Infocenter
|
||||
if (!in_array($studiengang_kz, $fit_programme_studiengaenge))
|
||||
{
|
||||
$disabledStg = 'disabled';
|
||||
$disabledStgTxt = $this->p->t('infocenter', 'nurBachelorFreigeben');
|
||||
}
|
||||
?>
|
||||
<div class="col-lg-8 text-right">
|
||||
<div class="form-inline">
|
||||
<div class="input-group frgstatusgrselect" id="frgstatusgrselect_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<select name="frgstatusgrund"
|
||||
class="d-inline float-right"
|
||||
<?php echo $disabledStg ?>
|
||||
required>
|
||||
<option value="null"
|
||||
selected="selected"><?php echo ucfirst($this->p->t('ui', 'freigabeart')) . '...' ?>
|
||||
</option>
|
||||
<?php foreach ($intstatusgruende as $statusgrund): ?>
|
||||
<option value="<?php echo $statusgrund->statusgrund_id ?>"><?php echo $statusgrund->bezeichnung_mehrsprachig[0] ?></option>
|
||||
<?php endforeach ?>
|
||||
</select>
|
||||
<span class="input-group-btn">
|
||||
<button class="btn btn-default freigabebtnstg" <?php echo $disabledStg ?> id="freigabebtnstg_<?php echo $zgvpruefung->prestudent_id ?>"
|
||||
data-toggle="tooltip" title="<?php echo $disabledStgTxt ?>">
|
||||
<?php echo $this->p->t('ui', 'freigabeAnStudiengang') ?>
|
||||
}
|
||||
if (!$infoonly) :
|
||||
?>
|
||||
<div class="col-lg-8 text-right">
|
||||
<div class="form-inline">
|
||||
<div class="input-group frgstatusgrselect" id="frgstatusgrselect_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<select name="frgstatusgrund"
|
||||
class="d-inline float-right"
|
||||
<?php echo $disabledStg ?>
|
||||
required>
|
||||
<option value="null"
|
||||
selected="selected"><?php echo ucfirst($this->p->t('ui', 'freigabeart')) . '...' ?>
|
||||
</option>
|
||||
<?php foreach ($intstatusgruende as $statusgrund): ?>
|
||||
<option value="<?php echo $statusgrund->statusgrund_id ?>"><?php echo $statusgrund->bezeichnung_mehrsprachig[0] ?></option>
|
||||
<?php endforeach ?>
|
||||
</select>
|
||||
<span class="input-group-btn">
|
||||
<button class="btn btn-default freigabebtnstg" <?php echo $disabledStg ?> id="freigabebtnstg_<?php echo $zgvpruefung->prestudent_id ?>"
|
||||
data-toggle="tooltip" title="<?php echo $disabledStgTxt ?>">
|
||||
<?php echo $this->p->t('ui', 'freigabeAnStudiengang') ?>
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<div class="input-group" id="igrfrgbtn">
|
||||
<button type="button" id="freigabebtn_<?php echo $zgvpruefung->prestudent_id ?>" class="btn btn-default freigabebtn" <?php echo $disabled ?>
|
||||
data-toggle="tooltip" title="<?php echo $disabledTxt ?>">
|
||||
<?php echo $this->p->t('ui', 'freigabeZumReihungstest') ?>
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<div class="input-group" id="igrfrgbtn">
|
||||
<button type="button" id="freigabebtn_<?php echo $zgvpruefung->prestudent_id ?>" class="btn btn-default freigabebtn" <?php echo $disabled ?>
|
||||
data-toggle="tooltip" title="<?php echo $disabledTxt ?>">
|
||||
<?php echo $this->p->t('ui', 'freigabeZumReihungstest') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal fade freigabeModal" id="freigabeModal_<?php echo $zgvpruefung->prestudent_id ?>" tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="freigabeModalLabel"
|
||||
aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close"
|
||||
data-dismiss="modal"
|
||||
aria-hidden="true">×
|
||||
</button>
|
||||
<h4 class="modal-title"
|
||||
id="freigabeModalLabel">
|
||||
<?php echo $this->p->t('infocenter', 'freigabeBestaetigen') ?>
|
||||
<span id="freigabeModalStgr_<?php echo $zgvpruefung->prestudent_id ?>"></span>
|
||||
</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<?php echo $this->p->t('infocenter', 'interessentFreigebenTxt') ?>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal"><?php echo $this->p->t('ui', 'abbrechen') ?>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="btn btn-primary saveFreigabe" id="saveFreigabe_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentFreigeben') ?>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="btn btn-primary saveStgFreigabe" id="saveStgFreigabe_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentFreigeben') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div><!-- /.modal-content -->
|
||||
</div><!-- /.modal-dialog -->
|
||||
</div><!-- /.modal-fade -->
|
||||
<div class="modal fade freigabeModal" id="freigabeModal_<?php echo $zgvpruefung->prestudent_id ?>" tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="freigabeModalLabel"
|
||||
aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close"
|
||||
data-dismiss="modal"
|
||||
aria-hidden="true">×
|
||||
</button>
|
||||
<h4 class="modal-title"
|
||||
id="freigabeModalLabel">
|
||||
<?php echo $this->p->t('infocenter', 'freigabeBestaetigen') ?>
|
||||
<span id="freigabeModalStgr_<?php echo $zgvpruefung->prestudent_id ?>"></span>
|
||||
</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<?php echo $this->p->t('infocenter', 'interessentFreigebenTxt') ?>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal"><?php echo $this->p->t('ui', 'abbrechen') ?>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="btn btn-primary saveFreigabe" id="saveFreigabe_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentFreigeben') ?>
|
||||
</button>
|
||||
<button type="button"
|
||||
class="btn btn-primary saveStgFreigabe" id="saveStgFreigabe_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentFreigeben') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div><!-- /.modal-content -->
|
||||
</div><!-- /.modal-dialog -->
|
||||
</div><!-- /.modal-fade -->
|
||||
<?php endif; ?>
|
||||
</div><!-- /.row -->
|
||||
</div><!-- /.panel-footer -->
|
||||
<?php elseif (isset($zgvpruefung->prestudentstatus->status_kurzbz) && $zgvpruefung->prestudentstatus->status_kurzbz === 'Interessent'): ?>
|
||||
@@ -528,46 +495,49 @@
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<div class="modal fade absageModal" id="absageModal_<?php echo $zgvpruefung->prestudent_id ?>"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="absageModalLabel"
|
||||
aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-hidden="true">
|
||||
×
|
||||
</button>
|
||||
<h4 class="modal-title"
|
||||
id="absageModalLabel"><?php echo $this->p->t('infocenter', 'absageBestaetigen') ?></h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<?php echo $this->p->t('infocenter', 'absageBestaetigenTxt') ?>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal">
|
||||
<?php echo $this->p->t('ui', 'abbrechen') ?>
|
||||
</button>
|
||||
<button class="btn btn-primary saveAbsage" id="saveAbsage_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentAbweisen') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.modal-content -->
|
||||
</div>
|
||||
<!-- /.modal-dialog -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div><!-- /.panel-footer -->
|
||||
<?php endif; //end if infoonly
|
||||
?>
|
||||
|
||||
<?php
|
||||
endif;
|
||||
?>
|
||||
|
||||
<div class="modal fade absageModal" id="absageModal_<?php echo $zgvpruefung->prestudent_id ?>"
|
||||
tabindex="-1"
|
||||
role="dialog"
|
||||
aria-labelledby="absageModalLabel"
|
||||
aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button"
|
||||
class="close"
|
||||
data-dismiss="modal"
|
||||
aria-hidden="true">
|
||||
×
|
||||
</button>
|
||||
<h4 class="modal-title"
|
||||
id="absageModalLabel"><?php echo $this->p->t('infocenter', 'absageBestaetigen') ?></h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<?php echo $this->p->t('infocenter', 'absageBestaetigenTxt') ?>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button"
|
||||
class="btn btn-default"
|
||||
data-dismiss="modal">
|
||||
<?php echo $this->p->t('ui', 'abbrechen') ?>
|
||||
</button>
|
||||
<button class="btn btn-primary saveAbsage" id="saveAbsage_<?php echo $zgvpruefung->prestudent_id ?>">
|
||||
<?php echo $this->p->t('infocenter', 'interessentAbweisen') ?>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<!-- /.modal-content -->
|
||||
</div>
|
||||
<!-- /.modal-dialog -->
|
||||
</div>
|
||||
</div><!-- /.div collapse -->
|
||||
</div><!-- /.panel -->
|
||||
<?php
|
||||
|
||||
Reference in New Issue
Block a user