Enhance worship import functionality: Add neighbor invitation and self-information fields in worshipController.js and WorshipManagement.vue. Implement logic to automatically set self-information based on neighbor invitation status, improving user experience and data handling during worship imports.
All checks were successful
Deploy miriamgemeinde / deploy (push) Successful in 6s
All checks were successful
Deploy miriamgemeinde / deploy (push) Successful in 6s
This commit is contained in:
@@ -1829,6 +1829,9 @@ exports.saveImportedWorships = async (req, res) => {
|
||||
// Freigabe-Status aus Import-Dialog übernehmen (Checkbox in der UI).
|
||||
// Fallback: wenn kein Wert gesetzt ist, bleibt es false.
|
||||
worshipData.approved = !!worshipData.approved;
|
||||
worshipData.neighborInvitation = !!worshipData.neighborInvitation;
|
||||
// Regel: Nachbarschaftsraum => automatisch Selbstinformation.
|
||||
worshipData.selfInformation = !!worshipData.selfInformation || worshipData.neighborInvitation;
|
||||
worshipData.title = normalizeText(worshipData.title) || 'Gottesdienst';
|
||||
|
||||
const replaceExistingIds = Array.isArray(worshipData._replaceExistingIds)
|
||||
@@ -1844,6 +1847,8 @@ exports.saveImportedWorships = async (req, res) => {
|
||||
sacristanService: worshipData.sacristanService || '',
|
||||
organPlaying: worshipData.organPlaying || '',
|
||||
approved: worshipData.approved,
|
||||
neighborInvitation: worshipData.neighborInvitation,
|
||||
selfInformation: worshipData.selfInformation,
|
||||
eventPlaceId: worshipData.eventPlaceId,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user