- neue Rechte bezüglich Unterschriften hinzugefügt, aber noch unbenutzt
- Vollbildmodalpopup für Reports hinzugefügt, aber noch unbenutzt

Übersetzungen in EnumTranslations.cs (z. 714ff) gegebenenfalls überarbeiten!
This commit is contained in:
2023-08-16 14:18:27 +02:00
parent 09939e0e15
commit 429d4966e4
24 changed files with 327 additions and 38 deletions

View File

@@ -408,6 +408,8 @@
<Content Include="node_modules\%40xmldom\xmldom\lib\entities.js" />
<Content Include="node_modules\%40xmldom\xmldom\lib\index.js" />
<Content Include="node_modules\%40xmldom\xmldom\lib\sax.js" />
<Content Include="node_modules\bootstrap4-fullscreen-modal\dist\bootstrap4-modal-fullscreen.css" />
<Content Include="node_modules\bootstrap4-fullscreen-modal\dist\bootstrap4-modal-fullscreen.min.css" />
<Content Include="node_modules\bootstrap\dist\css\bootstrap-grid.css" />
<Content Include="node_modules\bootstrap\dist\css\bootstrap-grid.min.css" />
<Content Include="node_modules\bootstrap\dist\css\bootstrap-reboot.css" />
@@ -5076,6 +5078,12 @@
<Content Include="node_modules\signature_pad\src\signature_pad.js.map" />
<Content Include="node_modules\signature_pad\src\throttle.js.map" />
</ItemGroup>
<ItemGroup>
<Content Include="node_modules\bootstrap4-fullscreen-modal\dist\bootstrap4-modal-fullscreen.min.css.map" />
<Content Include="node_modules\bootstrap4-fullscreen-modal\package.json" />
<Content Include="node_modules\bootstrap4-fullscreen-modal\README.md" />
<Content Include="node_modules\bootstrap4-fullscreen-modal\src\bootstrap4-modal-fullscreen.scss" />
</ItemGroup>
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>

View File

@@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.Linq;
using System.Web.Mvc;
using BeWo.Report.DefaultReports;
using BeWo.View.Navigation.Filter;
using BeWoPlanerMobil.Models;
using BeWoPlanerMobil.Service;
@@ -276,10 +277,13 @@ namespace BeWoPlanerMobil.Controllers
using (var memoryStream = ReportService.CreateMedikamentenlistenReport(medList.MedikamentenverordnungslistenOid.Value, MobileSessionFacade.Tenant))
{
var report = new XtraReport();
report.PrintingSystem.LoadDocument(memoryStream);
var medikamentenverordnungslistenReport = new MedikamentenverordnungslistenReport();
medikamentenverordnungslistenReport.PrintingSystem.LoadDocument(memoryStream);
Model.Report = report;
var height = medikamentenverordnungslistenReport.PageHeight;
var width = medikamentenverordnungslistenReport.PageWidth;
Model.Report = medikamentenverordnungslistenReport;
}
}

View File

@@ -164,10 +164,10 @@ namespace BeWoPlanerMobil.Controllers
AbstractModel.ShowServiceRecordInsertedOn = !UserSettingsUtils.GetSettingValueAsBool(mandatorSettings, SettingsKeys.HideServiceRecordInsertedByAndInsertedOn);
Model.ShowSignature = UserSettingsUtils.GetSettingValueAsBool(mandatorSettings, SettingsKeys.ShowSignature);
Model.ShowSignature = UserSettingsUtils.GetSettingValueAsBool(mandatorSettings, SettingsKeys.ShowSignature);// && AbstractModel.HasRightToProvideSingleSignature;
#if DEBUG
Model.ShowSignature = true;
//Model.ShowSignature = true;
#endif
Model.GroupsOfPeople = EmployeeService.GetAllGroups(GetUser().Employee.EmployeeOid).OrderBy(gop => gop.Name).ToList();

View File

@@ -187,5 +187,7 @@ namespace BeWoPlanerMobil.Models
}
public static bool HasRightToViewDiagnosen => CheckRight(UserRightType.Customer_ViewDiagnosis);
public static bool HasRightToProvideSingleSignature => CheckRight(UserRightType.Signature_ProvideSingleSignature);
}
}

View File

@@ -70,6 +70,7 @@
function submitReportTypeSelectionForm() {
try {
showSpinner();
var selectedReportType = $("#report-type-select").find(":selected").val();
$("#report-type-input").val(selectedReportType);
@@ -110,7 +111,7 @@
function deleteHistoryMedList(oid, name) {
try {
showMessagePopupWithCallback("Löschen","Sind Sie sicher, dass Sie die " + name + " löschen wollen?", function() {
showMessagePopupWithCallback("Löschen", "Sind Sie sicher, dass Sie die " + name + " löschen wollen?", function () {
showSpinner();
$("#med-list-oid-delete").val(oid);
$("#delete-history-med-list").submit();
@@ -760,12 +761,6 @@
</tbody>
</table>
}
@if(!(Model.Report is null))
{
// ToDo: Ist viel zu hoch auf kleinen Bildschirmen!
@Html.Partial("CustomerReportPartial", Model)
}
</div>
</div>
</div>
@@ -907,6 +902,29 @@
}
</div>
@if(!(Model?.Report is null) && Html.IsInDebugMode())
{
<div class="modal modal-fullscreen" tabindex="-1" role="dialog" id="report-popup">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header" onclick="debugOnclick()">
<h5 class="modal-title">Testpopup für Reports</h5>
<button type="button" class="close" data-dismiss="modal">
<span>&times;</span>
</button>
</div>
<div class="modal-body">
@Html.Partial("CustomerReportPartial", Model)
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary">Sekundärfarbe</button>
<button type="button" class="btn btn-primary" data-dismiss="modal">Schließen</button>
</div>
</div>
</div>
</div>
}
@using(Html.BeginForm("SelectReport", "Customer", FormMethod.Post, new { id = "medverordnungs-form" }))
{
<input type="hidden" name="report-type-input" id="report-type-input" />

View File

@@ -3,27 +3,125 @@
<script type="text/javascript">
function customerReportInitEvent(s, e) {
@if(Model?.Report != null && Html.IsInDebugMode())
{
<text>
$("#report-popup").modal('show');
</text>
}
}
function iterateThroughTree(element) {
var children = element.children();
var nodeName1 = element.prop("nodeName");
if (nodeName1 === "SCRIPT") {
return;
}
var classList1 = element.attr("class");
if (classList1 === undefined) {
classList1 = "";
}
logInfo(`${nodeName1} ${classList1}`);
$.each(children,
function (index, item) {
var nodeName = $(item).prop("nodeName");
if (nodeName === "SCRIPT") {
return;
}
var classList = $(item).attr("class");
if (classList === undefined) {
classList = "";
}
logInfo(`${(index + 1)} of ${children.length}: ${nodeName} ${classList}`);
iterateThroughTree($(item));
});
}
function getReportImageElement() {
var viewer = $("#webDocumentViewer2");
if (viewer.length === 0) {
logError("webDocumentViewer2 nicht gefunden!");
return null;
}
return viewer.find("div.dx-designer")
.find("div.dx-viewport.dx-theme-desktop.dx-theme-desktop-typography")
.find("div.dxrd-designer-wrapper.dx-editors.dxrd-preview.dxrdp-mobile.dx-ltr")
.find("div.dxrd-preview-wrapper.dxrdp-fullscreen")
.find("div.dxrd-mobile-content")
.find("div.dxrd-mobile-gallery.dx-gallery.dx-gallery-loop.dx-widget.dx-visibility-change-handler.dx-swipeable.dx-collection")
.find("div.dx-gallery-wrapper")
.find("div.dx-gallery-container")
.find("div.dx-item.dx-gallery-item.dx-item-selected.dx-gallery-item-selected")
.find("div.dx-template-wrapper.dx-item-content.dx-gallery-item-content")
.find("div.dxrd-scrollView-mobile.dx-scrollable.dx-scrollview.dx-scrollable-both.dx-scrollable-simulated.dx-visibility-change-handler")
.find("div.dx-scrollable-wrapper")
.find("div.dx-scrollable-container")
.find("div.dx-scrollable-content")
.find("div.dx-scrollview-content")
.find("div.dxrd-gallery-blocks")
.find("div.dxrd-gallery-block")
.find("div.dxrd-gallery-block-content")
.find("div.dxrd-mobile-page")
.find("div.dxrdp-content")
.find("img");
}
function getHeight() {
return getReportImageElement().height();
}
function getWidth() {
return getReportImageElement().width();
}
function debugOnclick() {
var viewer = $("#webDocumentViewer2");
var newHeight = parseFloat('@Model.ReportRatio.ToString().Replace(',', '.')') * parseFloat(viewer.width().toString());
var reportImg = getReportImageElement();
logInfo3(viewer.width() + " x " + newHeight);
if (reportImg.length > 0) {
viewer.height(getHeight());
viewer.width(getWidth());
}
$("#webDocumentViewer2").height(newHeight);
logColorfulMessage(`Größe des Report-Img: ${reportImg.height()}x${reportImg.width()}`, '#daf700');
}
function resizeReportImage() {
var reportImage = getReportImageElement();
if (reportImage !== undefined && reportImage !== null) {
var height = reportImage.height();
var width = reportImage.width();
if (height > 0 && width > 0) {
var viewer = $("#webDocumentViewer2");
viewer.height(reportImage.height());
viewer.width(reportImage.width());
}
}
}
</script>
@if(Model?.Report != null && Html.IsInDebugMode())
{
<div id="customer-report-container">
@Html.DevExpress().WebDocumentViewer(settings =>
{
settings.Name = "webDocumentViewer2";
settings.Width = Unit.Percentage(100);
settings.MobileMode = true;
settings.SettingsMobile.ReaderMode = true;
settings.SettingsMobile.AnimationEnabled = false;
settings.ClientSideEvents.Init = "customerReportInitEvent";
}).Bind(Model.Report).GetHtml()
</div>
@Html.DevExpress().WebDocumentViewer(settings =>
{
settings.Name = "webDocumentViewer2";
settings.Width = Unit.Percentage(100);
settings.Height = Unit.Percentage(100);
settings.MobileMode = true;
settings.SettingsMobile.ReaderMode = true;
settings.SettingsMobile.AnimationEnabled = false;
settings.ClientSideEvents.Init = "customerReportInitEvent";
}).Bind(Model.Report).GetHtml()
}

View File

@@ -858,7 +858,7 @@
Gefahrene Kilometer:
</div>
<div class="col">
@string.Format("{0:0.##}", serviceRecord.DistanceInMeterDecimal)
@($"{serviceRecord.DistanceInMeterDecimal:0.##}")
</div>
</div>
}
@@ -894,7 +894,7 @@
Angelegt für:
</div>
<div class="col">
@serviceRecord.Employee.ToString()
@($"{serviceRecord.Employee.FirstName} {serviceRecord.Employee.LastName}")
</div>
</div>

View File

@@ -55,6 +55,8 @@
<script src="@Url.Content("~/Scripts/group-booking.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/view-scripts/main.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/signature.js")" type="text/javascript"></script>
<link rel="stylesheet" href="@Url.Content("~/node_modules/bootstrap4-fullscreen-modal/dist/bootstrap4-modal-fullscreen.min.css")" />
<script src="@Url.Content("~/Scripts/support-concept-statistics.js")" type="text/javascript"></script>
@@ -374,7 +376,6 @@
}
}
@*ToDo: Wie im FaC machen!*@
@if(AbstractModel.HasRightToViewReports && AbstractModel.HasRightToViewMitarbeiterstundenkonto)
{
using(Html.BeginForm("RedirectToReportViewer", "Main", FormMethod.Post))
@@ -416,7 +417,7 @@
</div>
</nav>
}
<div class="modal" role="dialog" tabindex="-1" id="mySpinner">
<div class="modal-dialog modal-dialog-centered text-center" role="document">
<div class="modal-content bg-transparent border-0">

View File

@@ -28,6 +28,11 @@
"popper.js": "^1.16.0"
}
},
"node_modules/bootstrap4-fullscreen-modal": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/bootstrap4-fullscreen-modal/-/bootstrap4-fullscreen-modal-4.5.0.tgz",
"integrity": "sha512-tDnp5XNJxbjjXJPwyPymfbupdndVfS2aECUd1ziS2JFAjKLOmUszNehlMrq8yfcWqbCyFzJGQ6gQ69lHXjB6Lw=="
},
"node_modules/chainsaw": {
"version": "0.0.9",
"resolved": "https://registry.npmjs.org/chainsaw/-/chainsaw-0.0.9.tgz",

View File

@@ -0,0 +1,60 @@
# Bootstrap 4 fullscreen modal
An easy solution to integrate fullscreen bootstrap modals.
## Install
### With npm
```
npm install --save bootstrap4-fullscreen-modal
```
**Then add into your html head**
```
<link href="[YourPath]/bootstrap4-modal-fullscreen/dist/bootstrap4-modal-fullscreen.min.css" rel="stylesheet">
```
## Example
Just add the class _.modal-fullscreen_ to your bootstrap 4 modal.
```
<!-- Button trigger modal -->
<button type="button" class="btn btn-primary" data-toggle="modal" data-target="#exampleModal">
Launch fullscreen modal
</button>
<!-- Modal -->
<div class="modal fade modal-fullscreen" id="exampleModal" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel" aria-hidden="true">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="exampleModalLabel">Modal title</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
This is a fullscreen modal
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
</div>
</div>
</div>
</div>
```
## Dependencies
- [Bootstrap 4 ](https://getbootstrap.com/)
## Authors
- **Basile Bong**
## Version
1.0.5

View File

@@ -0,0 +1,15 @@
.modal.modal-fullscreen .modal-dialog {
width: 100vw;
height: 100vh;
margin: 0;
padding: 0;
max-width: none; }
.modal.modal-fullscreen .modal-content {
height: auto;
height: 100vh;
border-radius: 0;
border: none; }
.modal.modal-fullscreen .modal-body {
overflow-y: auto; }

View File

@@ -0,0 +1,2 @@
.modal.modal-fullscreen .modal-dialog{width:100vw;height:100vh;margin:0;padding:0;max-width:none}.modal.modal-fullscreen .modal-content{height:auto;height:100vh;border-radius:0;border:none}.modal.modal-fullscreen .modal-body{overflow-y:auto}
/*# sourceMappingURL=bootstrap4-modal-fullscreen.min.css.map */

View File

@@ -0,0 +1 @@
{"version":3,"names":[],"mappings":"","sources":["bootstrap4-modal-fullscreen.css"],"sourcesContent":[".modal.modal-fullscreen .modal-dialog{width:100vw;height:100vh;margin:0;padding:0;max-width:none}.modal.modal-fullscreen .modal-content{height:auto;height:100vh;border-radius:0;border:none}.modal.modal-fullscreen .modal-body{overflow-y:auto}"],"file":"bootstrap4-modal-fullscreen.min.css"}

View File

@@ -0,0 +1,27 @@
{
"name": "bootstrap4-fullscreen-modal",
"version": "4.5.0",
"description": "A easy way to create an bootstrap 4 fullscreen modal",
"repository": {
"type": "git",
"url": "git+https://github.com/basilebong/bootstrap4-fullscreen-modal.git"
},
"author": "Basile Bong",
"license": "ISC",
"bugs": {
"url": "https://github.com/basilebong/bootstrap4-fullscreen-modal/issues"
},
"homepage": "https://github.com/basilebong/bootstrap4-fullscreen-modal#readme",
"dependencies": {},
"devDependencies": {
"gulp": "4.0.2",
"gulp-cssmin": "^0.2.0",
"gulp-rename": "^2.0.0",
"gulp-sass": "4.1.0",
"gulp-sourcemaps": "^2.6.5",
"pump": "^3.0.0"
},
"scripts": {
"build": "npx gulp"
}
}

View File

@@ -0,0 +1,25 @@
.modal{
&.modal-fullscreen{
.modal{
&-dialog{
width: 100vw;
height: 100vh;
margin: 0;
padding: 0;
max-width: none;
}
&-content{
height: auto;
height: 100vh;
border-radius: 0;
border: none;
}
&-body{
overflow-y: auto;
}
}
}
}

View File

@@ -10,6 +10,7 @@
"license": "ISC",
"dependencies": {
"bootstrap": "^4.4.1",
"bootstrap4-fullscreen-modal": "^4.5.0",
"cldr": "^7.4.0",
"globalize": "^1.7.0",
"jquery": "^3.6.4",
@@ -43,6 +44,11 @@
"popper.js": "^1.16.0"
}
},
"node_modules/bootstrap4-fullscreen-modal": {
"version": "4.5.0",
"resolved": "https://registry.npmjs.org/bootstrap4-fullscreen-modal/-/bootstrap4-fullscreen-modal-4.5.0.tgz",
"integrity": "sha512-tDnp5XNJxbjjXJPwyPymfbupdndVfS2aECUd1ziS2JFAjKLOmUszNehlMrq8yfcWqbCyFzJGQ6gQ69lHXjB6Lw=="
},
"node_modules/chainsaw": {
"version": "0.0.9",
"resolved": "https://registry.npmjs.org/chainsaw/-/chainsaw-0.0.9.tgz",

View File

@@ -10,6 +10,7 @@
"private": true,
"dependencies": {
"bootstrap": "^4.4.1",
"bootstrap4-fullscreen-modal": "^4.5.0",
"cldr": "^7.4.0",
"globalize": "^1.7.0",
"jquery": "^3.6.4",

View File

@@ -4359,6 +4359,7 @@ namespace BeWo.Data.Access
return result;
}
// ToDo: An neue Rechte anpassen!
// Methode, die herausfindet, ob eine Liste mit ServiceRecordOids zu genau einer Mitarbeiterunterschrift gehört
public ConfirmationReceiptSignature GetConfirmationReceiptSignatureForServiceRecords(List<long> serviceRecordOids, SignatureType signatureType)
{

View File

@@ -21,9 +21,9 @@ namespace BetreuWoReports.Service
return new List<ResourceDC>();
}
public override List<SchedulerAppointmentDC> CheckResourceAvailabilityWithBookingEmployees(DateTime start, DateTime end, List<long> resourceOids, long? selectedAppointmentOid)
public override Dictionary<string, List<string>> CheckResourceAvailabilityWithBookingEmployees(DateTime start, DateTime end, List<long> resourceOids, long? selectedAppointmentOid, Guid? recurrenceId, int occurrenceIndex = 0, bool shouldSkipResourceAvailability = false)
{
return new List<SchedulerAppointmentDC>();
return new Dictionary<string, List<string>>();
}
}
}

View File

@@ -3,7 +3,6 @@ using System.Configuration;
using System.IO;
using System.Linq;
using System.Reflection;
using BeWo.Data;
using BS.Shared.Core;
namespace BeWo.Service.Plugins
@@ -17,7 +16,7 @@ namespace BeWo.Service.Plugins
#if DEBUG
var t = "demo";
t = "irgendwaswasesnichtgibt";
//t = "irgendwaswasesnichtgibt";
//t = "5473568546"; //Interner Chat
//t = "2356097460"; // Lebenshilfe Würzburg
//t = "1234567890"; // Präsentationsdatenbank
@@ -177,7 +176,7 @@ namespace BeWo.Service.Plugins
//t = "5426234256"; // SKM Leverkusen
//t = "4137042939"; // MLG Lebengestalten / Haus Müllestumpe
//t = "5260936181"; // LORI
t = "1931553444"; // HIBA
//t = "1931553444"; // HIBA
//t = "7185338722"; // BeWo Walz & Paiva
//t = "3196643272"; // Betreutes Wohnen Lisa Wöll
//t = "3432911735"; // Caritas Günzburg - Neu Ulm
@@ -338,7 +337,7 @@ namespace BeWo.Service.Plugins
//t = "2986016022"; // Ev Verein für Wohnraumhilfe Frankfurt a.M.
//t = "2181497347"; // BetreuungsserviceFuerAlltagUndWohnen (BAW Aachen)
//t = "5433105975"; // aha e.V.
//t = "7396826106"; // SKF Sozialdienst katholischer Frauen e.V. Leverkusen
t = "7396826106"; // SKF Sozialdienst katholischer Frauen e.V. Leverkusen
//t = "4748304562"; // BeWo Darmstadt
//t = "5315865694"; // Wismarer Werkstätten GmbH
//t = "6971328056"; // SKM Krefeld

View File

@@ -6850,7 +6850,9 @@ namespace BeWo.Service.ServiceImplementations
{
var confirmationReceiptSignatureToDelete = DAOFactory.GenericDAO.LoadByID<ConfirmationReceiptSignature>(confirmationReceiptSignatureOid);
DAOFactory.GenericDAO.Delete(confirmationReceiptSignatureToDelete);
//DAOFactory.GenericDAO.Delete(confirmationReceiptSignatureToDelete);
ServiceLogic.SetActivationType<ConfirmationReceiptSignature>(new Dictionary<long, long> { { confirmationReceiptSignatureOid, confirmationReceiptSignatureToDelete.Version.Value } }, ActivationTypeId.Deleted);
}
catch (Exception exception)
{

View File

@@ -58,6 +58,7 @@ namespace BeWo.Service.ServiceImplementations
try
{
var qs = PluginLoader.FindClass<QueryService>();
return qs.GetAllQueriesOfType(pType);
}
catch (Exception e)

View File

@@ -566,7 +566,11 @@ namespace BS.Shared
ServiceRecord_AllowEditAfterEmployeeSignature = 171724,
ServiceRecord_AllowDeleteAfterEmployeeSignature = 171725,
ConfirmationReceiptSignatures_Delete = 50000
ConfirmationReceiptSignatures_Delete = 50000,
Signature_ProvideSingleSignature = 60000,
Signature_ProvideMonthlySignature = 60001,
Signature_ProvideMonthlySignatureByProxy = 60002
}
public enum PersonType

View File

@@ -709,6 +709,15 @@ namespace BS.Shared.Core
},
{
UserRightType.Auswertungen_HilfeplanuebersichtAnsehen, Translator.Translate("Auswertungen->Hilfeplanübersicht")
},
{
UserRightType.Signature_ProvideSingleSignature, Translator.Translate($"{Translator.Translate("Klienten")}unterschriften leisten (einzeln)")
},
{
UserRightType.Signature_ProvideMonthlySignature, Translator.Translate($"{Translator.Translate("MitarbeiterPlural")}unterschriften für den Quittierungsbeleg leisten (monatlich)")
},
{
UserRightType.Signature_ProvideMonthlySignatureByProxy, Translator.Translate($"{Translator.Translate("MitarbeiterPlural")}unterschriften für den Quittierungsbeleg stellvertretend leisten (monatlich)")
}
};
#endregion