Merge remote-tracking branch 'origin/feature-33250/messages_von_reihungstestverwaltungsseite_aus_schicken' into infocenter_2023_12_04

This commit is contained in:
ma0048
2023-12-04 12:29:43 +01:00
+47 -7
View File
@@ -1010,6 +1010,7 @@ if(isset($_GET['excel']))
headers: {0: { sorter: false}},
widgetOptions: {filter_cssFilter: [
"filter_clm_null",
"filter_clm_prestudent_id",
"filter_clm_person_id",
"filter_clm_null",
"filter_clm_vorname",
@@ -1027,18 +1028,30 @@ if(isset($_GET['excel']))
$("#"+v.id).checkboxes('toggle');
e.preventDefault();
if ($("input.chkbox:checked").size() > 0)
{
$("#mailSendButton").html('Mail an markierte Personen senden');
$("#msgSendButton").html('Message an markierte Personen senden');
}
else
{
$("#mailSendButton").html('Mail an alle senden');
$("#msgSendButton").html('Message an alle senden');
}
});
$("#uncheck_"+v.id).on('click', function(e) {
$("#"+v.id).checkboxes('uncheck');
e.preventDefault();
if ($("input.chkbox:checked").size() > 0)
{
$("#mailSendButton").html('Mail an markierte Personen senden');
$("#msgSendButton").html('Message an markierte Personen senden');
}
else
{
$("#mailSendButton").html('Mail an alle senden');
$("#msgSendButton").html('Message an alle senden');
}
});
$("#"+v.id).checkboxes('range', true);
@@ -1049,6 +1062,7 @@ if(isset($_GET['excel']))
if (typeof(Storage) !== 'undefined')
{
var arr = ['clm_null',
'clm_prestudent_id',
'clm_person_id',
'clm_null',
'clm_vorname',
@@ -1114,9 +1128,15 @@ if(isset($_GET['excel']))
$('.chkbox').change(function()
{
if ($("input.chkbox:checked").size() > 0)
{
$("#mailSendButton").html('Mail an markierte Personen senden');
$("#msgSendButton").html('Message an markierte Personen senden');
}
else
{
$("#mailSendButton").html('Mail an alle senden');
$("#msgSendButton").html('Message an alle senden');
}
});
$('#toggle_bearbeitenForm').click(function()
@@ -1227,6 +1247,23 @@ if(isset($_GET['excel']))
});
window.location.href = "mailto:?bcc="+mailadressen;
}
function SendMessage()
{
// Wenn Checkboxen markiert sind, an diese senden, sonst an alle
if ($("input.chkbox:checked").size() > 0)
var elements = $("input.chkbox:checked");
else
var elements = $("input.chkbox");
var form = $("#sendMsgForm");
form.find("input[type=hidden]").remove();
$.each(elements, function(index, item)
{
var prestudent_id = $(this).closest('tr').find('td.clm_prestudent_id').text();
form.append("<input type='hidden' name='prestudent_id[]' value='" + prestudent_id + "'>");
});
form.submit();
}
</script>
<style type="text/css">
.active
@@ -2264,7 +2301,7 @@ $studienplaene_list = implode(',', array_keys($studienplaene_arr));
echo '<option value="2" '.($reihungstest->stufe == 2 ? 'selected' : '').'>2 (Interview)</option>';
echo '<option value="3" '.($reihungstest->stufe == 3 ? 'selected' : '').'>3</option>';
}
else
else
{
echo '<option value="1" '.($reihungstest->stufe == 1 ? 'selected' : '').'>1</option>';
echo '<option value="2" '.($reihungstest->stufe == 2 ? 'selected' : '').'>2</option>';
@@ -2583,6 +2620,9 @@ if($reihungstest_id!='')
echo '<a class="buttongreen" href="'.$_SERVER['PHP_SELF'].'?reihungstest_id='.$reihungstest_id.'&excel=true">Excel Export</a>';
//echo '<a class="buttongreen" href="'.$_SERVER['PHP_SELF'].'?reihungstest_id='.$reihungstest_id.'&type=saveallrtpunkte">Punkte ins FAS &uuml;bertragen</a>';
echo '<a class="buttongreen" href="#" onclick="SendMail()" id="mailSendButton">Mail an alle BewerberInnen senden</a>';
echo '<form id="sendMsgForm" method="post" action="'. APP_ROOT .'index.ci.php/system/messages/FASMessages/writeTemplate" target="_blank" style="display:inline-block">
<a class="buttongreen" href="javascript:void(0)" onclick="SendMessage()" id="msgSendButton">Message an alle BewerberInnen senden</a>
</form>';
}
if (defined('CAMPUS_NAME') && CAMPUS_NAME == 'FH Technikum Wien')
{
@@ -2607,7 +2647,7 @@ if($reihungstest_id!='')
$qry = "
SELECT DISTINCT rt_person_id,
rt_id,
'0' AS prestudent_id,
prestudent_id,
tbl_rt_person.person_id,
vorname,
nachname,
@@ -2725,7 +2765,7 @@ if($reihungstest_id!='')
echo '<br><span style="color: red"><b>Achtung!</b> Anzahl Arbeitsplätze überschritten</span>';
echo '</td></tr>';
echo '<tr><td>';
//echo '<div id="clm_prestudent_id" class="active" onclick="hideColumn(\'clm_prestudent_id\')">Prestudent ID</div>';
echo '<div id="clm_prestudent_id" class="active" onclick="hideColumn(\'clm_prestudent_id\')">Prestudent ID</div>';
echo '<div id="clm_person_id" class="active" onclick="hideColumn(\'clm_person_id\')">Person ID</div>';
echo '<div id="clm_vorname" class="active" onclick="hideColumn(\'clm_vorname\')">Vorname</div>';
echo '<div id="clm_geschlecht" class="active" onclick="hideColumn(\'clm_geschlecht\')">Geschlecht</div>';
@@ -2765,7 +2805,7 @@ if($reihungstest_id!='')
<a href="#" data-toggle="checkboxes" data-action="uncheck" id="uncheck_t'.$cnt.'"><img src="../../skin/images/checkbox_uncheck.png" name="toggle"></a>
</nobr>
</th>
<!--<th style="display: table-cell" class="clm_prestudent_id" title="PrestudentID">Prestudent ID</th>-->
<th style="display: table-cell" class="clm_prestudent_id" title="PrestudentID">Prestudent ID</th>
<th style="display: table-cell" class="clm_person_id" title="PersonID">Person ID</th>
<th>Nachname</th>
<th style="display: table-cell" class="clm_vorname">Vorname</th>
@@ -2884,7 +2924,7 @@ if($reihungstest_id!='')
echo '
<tr>
<td style="text-align: center"><input type="checkbox" class="chkbox" id="checkbox_'.$row->person_id.'" name="checkbox['.$row->person_id.']"></td>
<!--<td style="display: table-cell" class="clm_prestudent_id">'.$db->convert_html_chars($row->prestudent_id).'</td>-->
<td style="display: table-cell" class="clm_prestudent_id">'.$db->convert_html_chars($row->prestudent_id).'</td>
<td style="display: table-cell" class="clm_person_id">'.$db->convert_html_chars($row->person_id).'</td>
<td>'.$db->convert_html_chars($row->nachname).'</td>
<td style="display: table-cell" class="clm_vorname">'.$db->convert_html_chars($row->vorname).'</td>
@@ -2947,7 +2987,7 @@ if($reihungstest_id!='')
<a href="#" data-toggle="checkboxes" data-action="uncheck" id="uncheck_t'.$cnt.'"><img src="../../skin/images/checkbox_uncheck.png" name="toggle"></a>
</nobr>
</th>
<!--<th style="display: table-cell" class="clm_prestudent_id" title="PrestudentID">Prestudent ID</th>-->
<th style="display: table-cell" class="clm_prestudent_id" title="PrestudentID">Prestudent ID</th>
<th style="display: table-cell" class="clm_person_id" title="PersonID">Person ID</th>
<th>Nachname</th>
<th style="display: table-cell" class="clm_vorname">Vorname</th>
@@ -3066,7 +3106,7 @@ if($reihungstest_id!='')
echo '
<tr>
<td style="text-align: center"><input class="chkbox" type="checkbox" id="checkbox_'.$row->person_id.'" name="checkbox['.$row->person_id.']"></td>
<!--<td style="display: table-cell" class="clm_prestudent_id">'.$db->convert_html_chars($row->prestudent_id).'</td>-->
<td style="display: table-cell" class="clm_prestudent_id">'.$db->convert_html_chars($row->prestudent_id).'</td>
<td style="display: table-cell" class="clm_person_id">'.$db->convert_html_chars($row->person_id).'</td>
<td>'.$db->convert_html_chars($row->nachname).'</td>
<td style="display: table-cell" class="clm_vorname">'.$db->convert_html_chars($row->vorname).'</td>