ServiceRecords werden wie im FaC validiert, d.h. dass Arbeitszeiten und Pausenzeiten keine Überschneidungswarnung bekommen.
59 lines
2.0 KiB
Plaintext
59 lines
2.0 KiB
Plaintext
@using BeWoPlanerMobil.Models
|
|
@using BeWoPlanerMobil.Util
|
|
@model BeWoPlanerMobil.Models.MainModel
|
|
|
|
@{
|
|
if(TempData[TempDataConstants.DoLogoutKey] is bool doLogout && doLogout)
|
|
{
|
|
<text>
|
|
<script type="text/javascript">
|
|
$("#second-logout-form").submit();
|
|
</script>
|
|
</text>
|
|
}
|
|
}
|
|
|
|
<script type="text/javascript">
|
|
function rateGoal(ratingTypeOid) {
|
|
try {
|
|
var goalOid = $("#goal-to-rate-oid").val();
|
|
|
|
$.get("@Url.Action("RateSelectedGoal")", { ratingTypeOid: ratingTypeOid, goalOid: goalOid }).done(
|
|
function (result) {
|
|
if(false === checkJson(result)) {
|
|
logWarning("rateGoal: Der zurückgegebene Wert ist kein gültiges JSON!");
|
|
hideSpinner();
|
|
return;
|
|
}
|
|
|
|
var obj = parseJason(result);
|
|
|
|
$(`#goal-rating-${goalOid}`).text(obj.RatingName);
|
|
$(`#${goalOid}`).prop("checked", true);
|
|
hideGoalRatingPopup();
|
|
$("#goal-to-rate-oid").val("");
|
|
}
|
|
);
|
|
} catch(error) {
|
|
showErrorPopup(error);
|
|
}
|
|
}
|
|
</script>
|
|
|
|
@if(AbstractModel.HasRightToRateGoals)
|
|
{
|
|
<ul class="list-group">
|
|
@foreach(var ratingType in Model.GoalRatingTypes)
|
|
{
|
|
<li class="list-group-item" style="cursor: pointer;">
|
|
<div class="form-check" style="cursor: pointer;">
|
|
<input style="cursor: pointer;" class="form-check-input" type="radio" name="goal-rating-radios" id="grt-radio-@ratingType.RatingTypeOid" onclick="rateGoal(@ratingType.RatingTypeOid)"/>
|
|
<label style="cursor: pointer;" class="form-check-label" for="grt-radio-@ratingType.RatingTypeOid">
|
|
@ratingType.DisplayName
|
|
</label>
|
|
</div>
|
|
</li>
|
|
}
|
|
</ul>
|
|
}
|