From d77dfcf3138c55ad5944f61faba718aaa89039fc Mon Sep 17 00:00:00 2001 From: Daniel Grams Date: Thu, 4 Nov 2021 16:37:21 +0100 Subject: [PATCH] =?UTF-8?q?Hinweis,=20wenn=20Einladung=20f=C3=BCr=20andere?= =?UTF-8?q?n=20Nutzer=20#328?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- messages.pot | 129 ++++++++--------- .../translations/de/LC_MESSAGES/messages.mo | Bin 33195 -> 33414 bytes .../translations/de/LC_MESSAGES/messages.po | 132 +++++++++--------- .../translations/en/LC_MESSAGES/messages.mo | Bin 3489 -> 3489 bytes .../translations/en/LC_MESSAGES/messages.po | 132 +++++++++--------- project/views/admin_unit_member_invitation.py | 15 +- project/views/user.py | 15 +- project/views/utils.py | 32 ++++- tests/views/test_user.py | 13 ++ 9 files changed, 256 insertions(+), 212 deletions(-) diff --git a/messages.pot b/messages.pot index bf3c95a..987a0aa 100644 --- a/messages.pot +++ b/messages.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2021-10-26 23:29+0200\n" +"POT-Creation-Date: 2021-11-04 16:04+0100\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -189,30 +189,30 @@ msgstr "" msgid "message" msgstr "" -#: project/api/organization/resources.py:348 -#: project/views/admin_unit_member_invitation.py:92 +#: project/api/organization/resources.py:355 +#: project/views/admin_unit_member_invitation.py:85 msgid "You have received an invitation" msgstr "" -#: project/forms/admin.py:10 project/templates/layout.html:308 -#: project/views/root.py:42 +#: project/forms/admin.py:10 project/templates/layout.html:309 +#: project/views/root.py:37 msgid "Terms of service" msgstr "" -#: project/forms/admin.py:11 project/templates/layout.html:312 -#: project/views/root.py:50 +#: project/forms/admin.py:11 project/templates/layout.html:313 +#: project/views/root.py:45 msgid "Legal notice" msgstr "" -#: project/forms/admin.py:12 project/templates/_macros.html:1409 -#: project/templates/layout.html:316 +#: project/forms/admin.py:12 project/templates/_macros.html:1412 +#: project/templates/layout.html:317 #: project/templates/widget/event_suggestion/create.html:204 -#: project/views/admin_unit.py:73 project/views/root.py:58 +#: project/views/admin_unit.py:73 project/views/root.py:53 msgid "Contact" msgstr "" -#: project/forms/admin.py:13 project/templates/layout.html:320 -#: project/views/root.py:66 +#: project/forms/admin.py:13 project/templates/layout.html:321 +#: project/views/root.py:61 msgid "Privacy" msgstr "" @@ -327,7 +327,7 @@ msgstr "" msgid "The short name is used to create a unique identifier for your events" msgstr "" -#: project/forms/admin_unit.py:41 project/templates/_macros.html:1545 +#: project/forms/admin_unit.py:41 project/templates/_macros.html:1548 msgid "Short name must contain only letters numbers or underscore" msgstr "" @@ -341,7 +341,7 @@ msgstr "" #: project/forms/admin_unit_member.py:23 project/forms/admin_unit_member.py:28 #: project/forms/event.py:58 project/forms/event_suggestion.py:38 #: project/forms/organizer.py:27 project/templates/_macros.html:262 -#: project/templates/_macros.html:1505 project/templates/admin/users.html:19 +#: project/templates/_macros.html:1508 project/templates/admin/users.html:19 msgid "Email" msgstr "" @@ -696,11 +696,11 @@ msgid "" " course it works without it." msgstr "" -#: project/forms/event.py:208 project/templates/_macros.html:1266 +#: project/forms/event.py:208 project/templates/_macros.html:1269 msgid "The start must be before the end." msgstr "" -#: project/forms/event.py:214 project/templates/_macros.html:1283 +#: project/forms/event.py:214 project/templates/_macros.html:1286 msgid "An event can last a maximum of 14 days." msgstr "" @@ -869,7 +869,7 @@ msgstr "" msgid "Update event" msgstr "" -#: project/forms/event.py:397 project/templates/_macros.html:1238 +#: project/forms/event.py:397 project/templates/_macros.html:1241 #: project/templates/event/actions.html:47 #: project/templates/event/delete.html:6 msgid "Delete event" @@ -1071,7 +1071,7 @@ msgstr "" msgid "Delete request" msgstr "" -#: project/forms/reference_request.py:28 project/templates/_macros.html:1421 +#: project/forms/reference_request.py:28 project/templates/_macros.html:1424 #: project/templates/event_suggestion/review_status.html:18 #: project/templates/reference_request/review_status.html:12 msgid "Review status" @@ -1134,7 +1134,7 @@ msgid "This field is required." msgstr "" #: project/templates/_macros.html:134 project/templates/_macros.html:418 -#: project/templates/_macros.html:934 +#: project/templates/_macros.html:937 msgid "Date" msgstr "" @@ -1188,12 +1188,12 @@ msgid "Event" msgstr "" #: project/templates/_macros.html:445 project/templates/_macros.html:604 -#: project/templates/_macros.html:1490 project/templates/event/actions.html:32 +#: project/templates/_macros.html:1493 project/templates/event/actions.html:32 msgid "Share" msgstr "" #: project/templates/_macros.html:449 project/templates/_macros.html:608 -#: project/templates/_macros.html:1520 +#: project/templates/_macros.html:1523 msgid "Add to calendar" msgstr "" @@ -1214,27 +1214,27 @@ msgstr "" msgid "The event takes place both offline and online." msgstr "" -#: project/templates/_macros.html:700 project/templates/event_date/list.html:5 +#: project/templates/_macros.html:703 project/templates/event_date/list.html:5 #: project/templates/event_date/list.html:300 #: project/templates/reference_request/review.html:32 msgid "Event Dates" msgstr "" -#: project/templates/_macros.html:792 +#: project/templates/_macros.html:795 msgid "Search location on Google" msgstr "" -#: project/templates/_macros.html:858 +#: project/templates/_macros.html:861 #, python-format msgid "%(count)d event dates" msgstr "" -#: project/templates/_macros.html:874 project/templates/_macros.html:876 +#: project/templates/_macros.html:877 project/templates/_macros.html:879 #: project/templates/event_date/list.html:321 msgid "First" msgstr "" -#: project/templates/_macros.html:879 project/templates/_macros.html:881 +#: project/templates/_macros.html:882 project/templates/_macros.html:884 #: project/templates/event_date/list.html:322 #: project/templates/widget/event_suggestion/create.html:193 #: project/templates/widget/event_suggestion/create.html:218 @@ -1245,12 +1245,12 @@ msgstr "" msgid "Previous" msgstr "" -#: project/templates/_macros.html:883 +#: project/templates/_macros.html:886 #, python-format msgid "Page %(page)d of %(pages)d (%(total)d total)" msgstr "" -#: project/templates/_macros.html:885 project/templates/_macros.html:887 +#: project/templates/_macros.html:888 project/templates/_macros.html:890 #: project/templates/event_date/list.html:324 #: project/templates/widget/event_suggestion/create.html:194 #: project/templates/widget/event_suggestion/create.html:219 @@ -1260,73 +1260,73 @@ msgstr "" msgid "Next" msgstr "" -#: project/templates/_macros.html:890 project/templates/_macros.html:892 +#: project/templates/_macros.html:893 project/templates/_macros.html:895 #: project/templates/event_date/list.html:325 msgid "Last" msgstr "" -#: project/templates/_macros.html:957 +#: project/templates/_macros.html:960 msgid "Radius" msgstr "" -#: project/templates/_macros.html:1167 +#: project/templates/_macros.html:1170 msgid "Edit image" msgstr "" -#: project/templates/_macros.html:1188 +#: project/templates/_macros.html:1191 msgid "Close" msgstr "" -#: project/templates/_macros.html:1189 +#: project/templates/_macros.html:1192 msgid "Okay" msgstr "" -#: project/templates/_macros.html:1201 +#: project/templates/_macros.html:1204 msgid "Choose image file" msgstr "" -#: project/templates/_macros.html:1237 project/templates/event/actions.html:46 +#: project/templates/_macros.html:1240 project/templates/event/actions.html:46 msgid "Edit event" msgstr "" -#: project/templates/_macros.html:1240 project/templates/manage/events.html:45 +#: project/templates/_macros.html:1243 project/templates/manage/events.html:45 msgid "More" msgstr "" -#: project/templates/_macros.html:1287 +#: project/templates/_macros.html:1290 msgid "Please enter a valid time, between 00:00 and 23:59." msgstr "" -#: project/templates/_macros.html:1315 +#: project/templates/_macros.html:1318 #, python-format msgid "Just use %(term)s" msgstr "" -#: project/templates/_macros.html:1381 +#: project/templates/_macros.html:1384 msgid "Event suggestion" msgstr "" -#: project/templates/_macros.html:1499 +#: project/templates/_macros.html:1502 msgid "Link copied" msgstr "" -#: project/templates/_macros.html:1499 +#: project/templates/_macros.html:1502 msgid "Copy link" msgstr "" -#: project/templates/_macros.html:1528 +#: project/templates/_macros.html:1531 msgid "Google calendar" msgstr "" -#: project/templates/_macros.html:1529 +#: project/templates/_macros.html:1532 msgid "Apple calendar" msgstr "" -#: project/templates/_macros.html:1530 +#: project/templates/_macros.html:1533 msgid "Yahoo calendar" msgstr "" -#: project/templates/_macros.html:1531 +#: project/templates/_macros.html:1534 msgid "Other calendar" msgstr "" @@ -1345,24 +1345,21 @@ msgstr "" msgid "Events" msgstr "" -#: project/templates/layout.html:176 -msgid "Planing" -msgstr "" - -#: project/templates/layout.html:177 -msgid "Example" -msgstr "" - #: project/templates/admin/admin.html:19 #: project/templates/admin/admin_units.html:4 #: project/templates/admin/admin_units.html:11 -#: project/templates/layout.html:186 +#: project/templates/layout.html:176 project/templates/layout.html:186 #: project/templates/manage/admin_units.html:3 #: project/templates/manage/admin_units.html:25 +#: project/templates/organization/main.html:4 msgid "Organizations" msgstr "" -#: project/templates/layout.html:187 +#: project/templates/layout.html:177 +msgid "Planing" +msgstr "" + +#: project/templates/layout.html:187 project/templates/layout.html:271 #: project/templates/oauth2_client/list.html:10 #: project/templates/oauth2_client/read.html:10 #: project/templates/oauth2_token/list.html:10 project/templates/profile.html:4 @@ -1465,11 +1462,11 @@ msgstr "" msgid "Widgets" msgstr "" -#: project/templates/layout.html:280 +#: project/templates/layout.html:281 msgid "Switch organization" msgstr "" -#: project/templates/developer/read.html:4 project/templates/layout.html:330 +#: project/templates/developer/read.html:4 project/templates/layout.html:331 #: project/templates/profile.html:29 msgid "Developer" msgstr "" @@ -1963,23 +1960,23 @@ msgstr "" msgid "Member successfully deleted" msgstr "" -#: project/views/admin_unit_member_invitation.py:45 +#: project/views/admin_unit_member_invitation.py:38 msgid "Invitation successfully accepted" msgstr "" -#: project/views/admin_unit_member_invitation.py:52 +#: project/views/admin_unit_member_invitation.py:45 msgid "Invitation successfully declined" msgstr "" -#: project/views/admin_unit_member_invitation.py:97 +#: project/views/admin_unit_member_invitation.py:90 msgid "Invitation successfully sent" msgstr "" -#: project/views/admin_unit_member_invitation.py:120 +#: project/views/admin_unit_member_invitation.py:113 msgid "Entered email does not match invitation email" msgstr "" -#: project/views/admin_unit_member_invitation.py:125 +#: project/views/admin_unit_member_invitation.py:118 msgid "Invitation successfully deleted" msgstr "" @@ -2153,10 +2150,16 @@ msgstr "" msgid "Show" msgstr "" -#: project/views/utils.py:142 +#: project/views/utils.py:143 msgid "You do not have permission for this action" msgstr "" +#: project/views/utils.py:264 +msgid "" +"The invitation was issued to another user. Sign in with the email address" +" the invitation was sent to." +msgstr "" + #: project/views/widget.py:150 msgid "Thank you so much! The event is being verified." msgstr "" diff --git a/project/translations/de/LC_MESSAGES/messages.mo b/project/translations/de/LC_MESSAGES/messages.mo index a51a8b3b1a7f81ba0dcb474f55a9682ec0a2b01b..fe8eb154a2b8a84c1a982e9e86f3ba3e860f119a 100644 GIT binary patch delta 6262 zcmZA5c~sU_9>?*Yh-{*uAP^G#T*4(l5K_UxEyxVT%oQCmmM3_WC3zmg{Rx*wEn6HX zo6633Ds!^bBTi+hHG^jwqqJqpk}}81%CSYGG8>2H{qf#E=FB)!jj%lCfo{r#SF z*P5Vv)&=eTzFQ#0ah$wij?)$AVlb9scdW41V>jx{?ek`wO#L1V!S`(YNsOZYDTd*< zw*4pcQvVO$fK{1}GY_|AI)ST&%QXCohM8H8b0coHeqc=;?l@CvFU4%!jRWxvreY|K zYR}+5IarPgcq{hBZ8!iAU<`hOlkj48z;Oms7|kf{yb}AM7b7r$E^f5$LS^htOv0~F znF?oH%0wU30!f&NnW*PQ*b8T4D0(px7Y8V4;Z?|Hoi(Th{)9^5`>2kmQ2oxM0=r+($53IC>wWw6xYkdY4X{&wShMMSI>j~^b{bP*A z@2p)%nxlzDJ!$DkCnsn2rfp zj2c&E-GCau3s>L)RHjDcnhZ?9WbU6c`D(#&7FjoJadX+@pwrpOp-pj5wzTukRx9E%;O+nqhy)aRmh@F=SP4%8X% zMg{gFD)2Vc&Obl}_!+AIzpUTc=RaehHxI&i_u{ZGYT$5Gq~oj;F^YPzeO_woHJC{I z3e-GXF&Uq=9<_dn+*2ns-yBswD$rT^X^7dmfdE zA5eFp%NR3pPt<&aP?^ica=aaruoaW>G-{n+#*lxVaXk6f&Qno4$w8%TA}SM8Q7N8f z+ZUoz+kiTPC8$fE%>DV7NVGimD z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&G7;z;g3_vzg~!+ zW;-UM21-Q@+zYjr8R&;&PytWD#`r4g`MX#H526Ana~?z8l25S-UUT*8x%NjWCYSsx z)dOhI0FzMHZ5qbnd~AwaP>~-;eGhJ<27H2ASvVVC9h;%9Zyc&U4HalV)FIAw^;fYO z^>;lKG~hYhhL=$t=g+V%MGdeH70_W+$1mOUD%5X=U!KiO1ZqK@P$?dYzPJ>XnG*EE zb*O+mZ&1*l??)Y~v#1wuq4xftsKfF<)IcFK?d^!f!PLiKYux4P7cqc(esO$-orqwG0SEm z1eLkgs9(Jd)Ge8UF}nXtpB2~()V)80ap*PMuB0{ULzC(pirRvySR2=1FmA^fJb+rr zUs1Q}DrzDB!dB>&Zv#ohcFb>jQdoio7?1zO1{gcXM%ooM!FcCP)Jlqx6q@zUZK%E9 zb*kLUav*1j-ugxaEw&h4nc_Fz3M_fSx(E3qX87C!qcyXlBp*=yJV4`O?~ zjT129W&X8<3o#u(#9jCw)C9jRvj10f0+rccu^+ZuWZy4DZH4D31*PPgYxo%zaZIs2 z#qsDzy(22(bks^mxcYQ#Nc|P(R@BPNumS$Xc^8#2uUBlQLor47KaoOx9%N$(7NhRx z2GqodQG0$2b*-*rG~P!YK7Y1QhcXfM{#aB1FXA#Ra_wfZU06+gc2>~Wj39an$%b^G z4#j9p$Em1Oz8f_`1$IQ;)ke?>brwcrUz~{gwC-9`+8`>nuFs^Iv-7e`Q`?LSEv@QZ uUL&w=LQ+ahQv0-|)cCeZr4@t1L;QMX=gys-o1IsBFRNjL(vp{}eE$z6e&fsl diff --git a/project/translations/de/LC_MESSAGES/messages.po b/project/translations/de/LC_MESSAGES/messages.po index 4c53367..2488d5b 100644 --- a/project/translations/de/LC_MESSAGES/messages.po +++ b/project/translations/de/LC_MESSAGES/messages.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2021-10-26 23:29+0200\n" +"POT-Creation-Date: 2021-11-04 16:04+0100\n" "PO-Revision-Date: 2020-06-07 18:51+0200\n" "Last-Translator: FULL NAME \n" "Language: de\n" @@ -190,30 +190,30 @@ msgstr "." msgid "message" msgstr "message" -#: project/api/organization/resources.py:348 -#: project/views/admin_unit_member_invitation.py:92 +#: project/api/organization/resources.py:355 +#: project/views/admin_unit_member_invitation.py:85 msgid "You have received an invitation" msgstr "Du hast eine Einladung erhalten" -#: project/forms/admin.py:10 project/templates/layout.html:308 -#: project/views/root.py:42 +#: project/forms/admin.py:10 project/templates/layout.html:309 +#: project/views/root.py:37 msgid "Terms of service" msgstr "Nutzungsbedingungen" -#: project/forms/admin.py:11 project/templates/layout.html:312 -#: project/views/root.py:50 +#: project/forms/admin.py:11 project/templates/layout.html:313 +#: project/views/root.py:45 msgid "Legal notice" msgstr "Impressum" -#: project/forms/admin.py:12 project/templates/_macros.html:1409 -#: project/templates/layout.html:316 +#: project/forms/admin.py:12 project/templates/_macros.html:1412 +#: project/templates/layout.html:317 #: project/templates/widget/event_suggestion/create.html:204 -#: project/views/admin_unit.py:73 project/views/root.py:58 +#: project/views/admin_unit.py:73 project/views/root.py:53 msgid "Contact" msgstr "Kontakt" -#: project/forms/admin.py:13 project/templates/layout.html:320 -#: project/views/root.py:66 +#: project/forms/admin.py:13 project/templates/layout.html:321 +#: project/views/root.py:61 msgid "Privacy" msgstr "Datenschutz" @@ -339,7 +339,7 @@ msgstr "" "eindeutig zu identifizieren. Der Kurzname darf nur Buchstaben, Nummern " "und Unterstriche enthalten." -#: project/forms/admin_unit.py:41 project/templates/_macros.html:1545 +#: project/forms/admin_unit.py:41 project/templates/_macros.html:1548 msgid "Short name must contain only letters numbers or underscore" msgstr "Der Kurzname darf nur Buchstaben, Nummern und Unterstriche enthalten" @@ -353,7 +353,7 @@ msgstr "Link URL" #: project/forms/admin_unit_member.py:23 project/forms/admin_unit_member.py:28 #: project/forms/event.py:58 project/forms/event_suggestion.py:38 #: project/forms/organizer.py:27 project/templates/_macros.html:262 -#: project/templates/_macros.html:1505 project/templates/admin/users.html:19 +#: project/templates/_macros.html:1508 project/templates/admin/users.html:19 msgid "Email" msgstr "Email" @@ -728,11 +728,11 @@ msgstr "" "Wir empfehlen dir, ein Foto für die Veranstaltung hochzuladen. Es macht " "schon deutlich mehr her, aber es geht natürlich auch ohne." -#: project/forms/event.py:208 project/templates/_macros.html:1266 +#: project/forms/event.py:208 project/templates/_macros.html:1269 msgid "The start must be before the end." msgstr "Der Start muss vor dem Ende sein." -#: project/forms/event.py:214 project/templates/_macros.html:1283 +#: project/forms/event.py:214 project/templates/_macros.html:1286 msgid "An event can last a maximum of 14 days." msgstr "Eine Veranstaltung darf maximal 14 Tage dauern." @@ -911,7 +911,7 @@ msgstr "Wähle den öffentlichen Status der Veranstaltung." msgid "Update event" msgstr "Veranstaltung aktualisieren" -#: project/forms/event.py:397 project/templates/_macros.html:1238 +#: project/forms/event.py:397 project/templates/_macros.html:1241 #: project/templates/event/actions.html:47 #: project/templates/event/delete.html:6 msgid "Delete event" @@ -1117,7 +1117,7 @@ msgstr "Anfrage speichern" msgid "Delete request" msgstr "Anfrage löschen" -#: project/forms/reference_request.py:28 project/templates/_macros.html:1421 +#: project/forms/reference_request.py:28 project/templates/_macros.html:1424 #: project/templates/event_suggestion/review_status.html:18 #: project/templates/reference_request/review_status.html:12 msgid "Review status" @@ -1180,7 +1180,7 @@ msgid "This field is required." msgstr "Dieses Feld ist erforderlich." #: project/templates/_macros.html:134 project/templates/_macros.html:418 -#: project/templates/_macros.html:934 +#: project/templates/_macros.html:937 msgid "Date" msgstr "Datum" @@ -1234,12 +1234,12 @@ msgid "Event" msgstr "Veranstaltung" #: project/templates/_macros.html:445 project/templates/_macros.html:604 -#: project/templates/_macros.html:1490 project/templates/event/actions.html:32 +#: project/templates/_macros.html:1493 project/templates/event/actions.html:32 msgid "Share" msgstr "Teilen" #: project/templates/_macros.html:449 project/templates/_macros.html:608 -#: project/templates/_macros.html:1520 +#: project/templates/_macros.html:1523 msgid "Add to calendar" msgstr "Zum Kalender" @@ -1262,27 +1262,27 @@ msgstr "" "Die Veranstaltung findet sowohl als Präsenzveranstaltung als auch online " "statt." -#: project/templates/_macros.html:700 project/templates/event_date/list.html:5 +#: project/templates/_macros.html:703 project/templates/event_date/list.html:5 #: project/templates/event_date/list.html:300 #: project/templates/reference_request/review.html:32 msgid "Event Dates" msgstr "Termine" -#: project/templates/_macros.html:792 +#: project/templates/_macros.html:795 msgid "Search location on Google" msgstr "Ort bei Google suchen" -#: project/templates/_macros.html:858 +#: project/templates/_macros.html:861 #, python-format msgid "%(count)d event dates" msgstr "%(count)d Termine" -#: project/templates/_macros.html:874 project/templates/_macros.html:876 +#: project/templates/_macros.html:877 project/templates/_macros.html:879 #: project/templates/event_date/list.html:321 msgid "First" msgstr "Letzte" -#: project/templates/_macros.html:879 project/templates/_macros.html:881 +#: project/templates/_macros.html:882 project/templates/_macros.html:884 #: project/templates/event_date/list.html:322 #: project/templates/widget/event_suggestion/create.html:193 #: project/templates/widget/event_suggestion/create.html:218 @@ -1293,12 +1293,12 @@ msgstr "Letzte" msgid "Previous" msgstr "Zurück" -#: project/templates/_macros.html:883 +#: project/templates/_macros.html:886 #, python-format msgid "Page %(page)d of %(pages)d (%(total)d total)" msgstr "Seite %(page)d von %(pages)d (%(total)d insgesamt)" -#: project/templates/_macros.html:885 project/templates/_macros.html:887 +#: project/templates/_macros.html:888 project/templates/_macros.html:890 #: project/templates/event_date/list.html:324 #: project/templates/widget/event_suggestion/create.html:194 #: project/templates/widget/event_suggestion/create.html:219 @@ -1308,73 +1308,73 @@ msgstr "Seite %(page)d von %(pages)d (%(total)d insgesamt)" msgid "Next" msgstr "Weiter" -#: project/templates/_macros.html:890 project/templates/_macros.html:892 +#: project/templates/_macros.html:893 project/templates/_macros.html:895 #: project/templates/event_date/list.html:325 msgid "Last" msgstr "Erste" -#: project/templates/_macros.html:957 +#: project/templates/_macros.html:960 msgid "Radius" msgstr "Umkreis" -#: project/templates/_macros.html:1167 +#: project/templates/_macros.html:1170 msgid "Edit image" msgstr "Bild bearbeiten" -#: project/templates/_macros.html:1188 +#: project/templates/_macros.html:1191 msgid "Close" msgstr "Schließen" -#: project/templates/_macros.html:1189 +#: project/templates/_macros.html:1192 msgid "Okay" msgstr "OK" -#: project/templates/_macros.html:1201 +#: project/templates/_macros.html:1204 msgid "Choose image file" msgstr "Bild-Datei auswählen" -#: project/templates/_macros.html:1237 project/templates/event/actions.html:46 +#: project/templates/_macros.html:1240 project/templates/event/actions.html:46 msgid "Edit event" msgstr "Veranstaltung bearbeiten" -#: project/templates/_macros.html:1240 project/templates/manage/events.html:45 +#: project/templates/_macros.html:1243 project/templates/manage/events.html:45 msgid "More" msgstr "Mehr" -#: project/templates/_macros.html:1287 +#: project/templates/_macros.html:1290 msgid "Please enter a valid time, between 00:00 and 23:59." msgstr "Bitte gib eine gültige Uhrzeit zwischen 00:00 und 23:59 ein." -#: project/templates/_macros.html:1315 +#: project/templates/_macros.html:1318 #, python-format msgid "Just use %(term)s" msgstr "Verwende einfach %(term)s" -#: project/templates/_macros.html:1381 +#: project/templates/_macros.html:1384 msgid "Event suggestion" msgstr "Veranstaltungsvorschlag" -#: project/templates/_macros.html:1499 +#: project/templates/_macros.html:1502 msgid "Link copied" msgstr "Link kopiert" -#: project/templates/_macros.html:1499 +#: project/templates/_macros.html:1502 msgid "Copy link" msgstr "Link kopieren" -#: project/templates/_macros.html:1528 +#: project/templates/_macros.html:1531 msgid "Google calendar" msgstr "Google Kalender" -#: project/templates/_macros.html:1529 +#: project/templates/_macros.html:1532 msgid "Apple calendar" msgstr "Apple Kalender" -#: project/templates/_macros.html:1530 +#: project/templates/_macros.html:1533 msgid "Yahoo calendar" msgstr "Yahoo Kalender" -#: project/templates/_macros.html:1531 +#: project/templates/_macros.html:1534 msgid "Other calendar" msgstr "Anderer Kalender" @@ -1393,24 +1393,21 @@ msgstr "Kostenlos registrieren" msgid "Events" msgstr "Veranstaltungen" -#: project/templates/layout.html:176 -msgid "Planing" -msgstr "Planung" - -#: project/templates/layout.html:177 -msgid "Example" -msgstr "Beispiel" - #: project/templates/admin/admin.html:19 #: project/templates/admin/admin_units.html:4 #: project/templates/admin/admin_units.html:11 -#: project/templates/layout.html:186 +#: project/templates/layout.html:176 project/templates/layout.html:186 #: project/templates/manage/admin_units.html:3 #: project/templates/manage/admin_units.html:25 +#: project/templates/organization/main.html:4 msgid "Organizations" msgstr "Organisationen" -#: project/templates/layout.html:187 +#: project/templates/layout.html:177 +msgid "Planing" +msgstr "Planung" + +#: project/templates/layout.html:187 project/templates/layout.html:271 #: project/templates/oauth2_client/list.html:10 #: project/templates/oauth2_client/read.html:10 #: project/templates/oauth2_token/list.html:10 project/templates/profile.html:4 @@ -1513,11 +1510,11 @@ msgstr "Einstellungen" msgid "Widgets" msgstr "Widgets" -#: project/templates/layout.html:280 +#: project/templates/layout.html:281 msgid "Switch organization" msgstr "Organisation wechseln" -#: project/templates/developer/read.html:4 project/templates/layout.html:330 +#: project/templates/developer/read.html:4 project/templates/layout.html:331 #: project/templates/profile.html:29 msgid "Developer" msgstr "Entwickler" @@ -2020,23 +2017,23 @@ msgstr "Die eingegebene Email passt nicht zur Email des Mitglieds" msgid "Member successfully deleted" msgstr "Mitglied erfolgreich gelöscht" -#: project/views/admin_unit_member_invitation.py:45 +#: project/views/admin_unit_member_invitation.py:38 msgid "Invitation successfully accepted" msgstr "Einladung erfolgreich akzeptiert" -#: project/views/admin_unit_member_invitation.py:52 +#: project/views/admin_unit_member_invitation.py:45 msgid "Invitation successfully declined" msgstr "Einladung erfolgreich abgelehnt" -#: project/views/admin_unit_member_invitation.py:97 +#: project/views/admin_unit_member_invitation.py:90 msgid "Invitation successfully sent" msgstr "Einladung erfolgreich gesendet" -#: project/views/admin_unit_member_invitation.py:120 +#: project/views/admin_unit_member_invitation.py:113 msgid "Entered email does not match invitation email" msgstr "Die eingegebene Email passt nicht zur Email der Einladung" -#: project/views/admin_unit_member_invitation.py:125 +#: project/views/admin_unit_member_invitation.py:118 msgid "Invitation successfully deleted" msgstr "Einladung erfolgreich gelöscht" @@ -2216,10 +2213,16 @@ msgstr "Fehler im Feld %s: %s" msgid "Show" msgstr "Anzeigen" -#: project/views/utils.py:142 +#: project/views/utils.py:143 msgid "You do not have permission for this action" msgstr "Du hast keine Berechtigung für diese Aktion" +#: project/views/utils.py:264 +msgid "" +"The invitation was issued to another user. Sign in with the email address" +" the invitation was sent to." +msgstr "Die Einladung wurde für einen anderen Nutzer ausgestellt. Melde dich mit der Email-Adresse an, an die die Einladung geschickt wurde." + #: project/views/widget.py:150 msgid "Thank you so much! The event is being verified." msgstr "Vielen Dank! Die Veranstaltung wird geprüft." @@ -2270,3 +2273,6 @@ msgstr "Neue Veranstaltung zu prüfen" #~ msgid "URL für Infoscreen" #~ msgstr "URL für Infoscreen" +#~ msgid "Example" +#~ msgstr "Beispiel" + diff --git a/project/translations/en/LC_MESSAGES/messages.mo b/project/translations/en/LC_MESSAGES/messages.mo index 367745dd254aa94b225bfe172108bbaf8aa3c589..ececdf0cea3b15d507923a18aae2b6f97cc0b5b1 100644 GIT binary patch delta 26 hcmZ1|y-<2X5ht&qu7Qbyp_!F|iMD~^=6X&g764)22893s delta 26 hcmZ1|y-<2X5ht&Ku92C7k+GGLrM7|5=6X&g764*9295v# diff --git a/project/translations/en/LC_MESSAGES/messages.po b/project/translations/en/LC_MESSAGES/messages.po index 7099967..151fc8f 100644 --- a/project/translations/en/LC_MESSAGES/messages.po +++ b/project/translations/en/LC_MESSAGES/messages.po @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PROJECT VERSION\n" "Report-Msgid-Bugs-To: EMAIL@ADDRESS\n" -"POT-Creation-Date: 2021-10-26 23:29+0200\n" +"POT-Creation-Date: 2021-11-04 16:04+0100\n" "PO-Revision-Date: 2021-04-30 15:04+0200\n" "Last-Translator: FULL NAME \n" "Language: en\n" @@ -190,30 +190,30 @@ msgstr "" msgid "message" msgstr "" -#: project/api/organization/resources.py:348 -#: project/views/admin_unit_member_invitation.py:92 +#: project/api/organization/resources.py:355 +#: project/views/admin_unit_member_invitation.py:85 msgid "You have received an invitation" msgstr "" -#: project/forms/admin.py:10 project/templates/layout.html:308 -#: project/views/root.py:42 +#: project/forms/admin.py:10 project/templates/layout.html:309 +#: project/views/root.py:37 msgid "Terms of service" msgstr "" -#: project/forms/admin.py:11 project/templates/layout.html:312 -#: project/views/root.py:50 +#: project/forms/admin.py:11 project/templates/layout.html:313 +#: project/views/root.py:45 msgid "Legal notice" msgstr "" -#: project/forms/admin.py:12 project/templates/_macros.html:1409 -#: project/templates/layout.html:316 +#: project/forms/admin.py:12 project/templates/_macros.html:1412 +#: project/templates/layout.html:317 #: project/templates/widget/event_suggestion/create.html:204 -#: project/views/admin_unit.py:73 project/views/root.py:58 +#: project/views/admin_unit.py:73 project/views/root.py:53 msgid "Contact" msgstr "" -#: project/forms/admin.py:13 project/templates/layout.html:320 -#: project/views/root.py:66 +#: project/forms/admin.py:13 project/templates/layout.html:321 +#: project/views/root.py:61 msgid "Privacy" msgstr "" @@ -328,7 +328,7 @@ msgstr "" msgid "The short name is used to create a unique identifier for your events" msgstr "" -#: project/forms/admin_unit.py:41 project/templates/_macros.html:1545 +#: project/forms/admin_unit.py:41 project/templates/_macros.html:1548 msgid "Short name must contain only letters numbers or underscore" msgstr "" @@ -342,7 +342,7 @@ msgstr "" #: project/forms/admin_unit_member.py:23 project/forms/admin_unit_member.py:28 #: project/forms/event.py:58 project/forms/event_suggestion.py:38 #: project/forms/organizer.py:27 project/templates/_macros.html:262 -#: project/templates/_macros.html:1505 project/templates/admin/users.html:19 +#: project/templates/_macros.html:1508 project/templates/admin/users.html:19 msgid "Email" msgstr "" @@ -697,11 +697,11 @@ msgid "" " course it works without it." msgstr "" -#: project/forms/event.py:208 project/templates/_macros.html:1266 +#: project/forms/event.py:208 project/templates/_macros.html:1269 msgid "The start must be before the end." msgstr "" -#: project/forms/event.py:214 project/templates/_macros.html:1283 +#: project/forms/event.py:214 project/templates/_macros.html:1286 msgid "An event can last a maximum of 14 days." msgstr "" @@ -870,7 +870,7 @@ msgstr "" msgid "Update event" msgstr "" -#: project/forms/event.py:397 project/templates/_macros.html:1238 +#: project/forms/event.py:397 project/templates/_macros.html:1241 #: project/templates/event/actions.html:47 #: project/templates/event/delete.html:6 msgid "Delete event" @@ -1072,7 +1072,7 @@ msgstr "" msgid "Delete request" msgstr "" -#: project/forms/reference_request.py:28 project/templates/_macros.html:1421 +#: project/forms/reference_request.py:28 project/templates/_macros.html:1424 #: project/templates/event_suggestion/review_status.html:18 #: project/templates/reference_request/review_status.html:12 msgid "Review status" @@ -1135,7 +1135,7 @@ msgid "This field is required." msgstr "" #: project/templates/_macros.html:134 project/templates/_macros.html:418 -#: project/templates/_macros.html:934 +#: project/templates/_macros.html:937 msgid "Date" msgstr "" @@ -1189,12 +1189,12 @@ msgid "Event" msgstr "" #: project/templates/_macros.html:445 project/templates/_macros.html:604 -#: project/templates/_macros.html:1490 project/templates/event/actions.html:32 +#: project/templates/_macros.html:1493 project/templates/event/actions.html:32 msgid "Share" msgstr "" #: project/templates/_macros.html:449 project/templates/_macros.html:608 -#: project/templates/_macros.html:1520 +#: project/templates/_macros.html:1523 msgid "Add to calendar" msgstr "" @@ -1215,27 +1215,27 @@ msgstr "" msgid "The event takes place both offline and online." msgstr "" -#: project/templates/_macros.html:700 project/templates/event_date/list.html:5 +#: project/templates/_macros.html:703 project/templates/event_date/list.html:5 #: project/templates/event_date/list.html:300 #: project/templates/reference_request/review.html:32 msgid "Event Dates" msgstr "" -#: project/templates/_macros.html:792 +#: project/templates/_macros.html:795 msgid "Search location on Google" msgstr "" -#: project/templates/_macros.html:858 +#: project/templates/_macros.html:861 #, python-format msgid "%(count)d event dates" msgstr "" -#: project/templates/_macros.html:874 project/templates/_macros.html:876 +#: project/templates/_macros.html:877 project/templates/_macros.html:879 #: project/templates/event_date/list.html:321 msgid "First" msgstr "" -#: project/templates/_macros.html:879 project/templates/_macros.html:881 +#: project/templates/_macros.html:882 project/templates/_macros.html:884 #: project/templates/event_date/list.html:322 #: project/templates/widget/event_suggestion/create.html:193 #: project/templates/widget/event_suggestion/create.html:218 @@ -1246,12 +1246,12 @@ msgstr "" msgid "Previous" msgstr "" -#: project/templates/_macros.html:883 +#: project/templates/_macros.html:886 #, python-format msgid "Page %(page)d of %(pages)d (%(total)d total)" msgstr "" -#: project/templates/_macros.html:885 project/templates/_macros.html:887 +#: project/templates/_macros.html:888 project/templates/_macros.html:890 #: project/templates/event_date/list.html:324 #: project/templates/widget/event_suggestion/create.html:194 #: project/templates/widget/event_suggestion/create.html:219 @@ -1261,73 +1261,73 @@ msgstr "" msgid "Next" msgstr "" -#: project/templates/_macros.html:890 project/templates/_macros.html:892 +#: project/templates/_macros.html:893 project/templates/_macros.html:895 #: project/templates/event_date/list.html:325 msgid "Last" msgstr "" -#: project/templates/_macros.html:957 +#: project/templates/_macros.html:960 msgid "Radius" msgstr "" -#: project/templates/_macros.html:1167 +#: project/templates/_macros.html:1170 msgid "Edit image" msgstr "" -#: project/templates/_macros.html:1188 +#: project/templates/_macros.html:1191 msgid "Close" msgstr "" -#: project/templates/_macros.html:1189 +#: project/templates/_macros.html:1192 msgid "Okay" msgstr "" -#: project/templates/_macros.html:1201 +#: project/templates/_macros.html:1204 msgid "Choose image file" msgstr "" -#: project/templates/_macros.html:1237 project/templates/event/actions.html:46 +#: project/templates/_macros.html:1240 project/templates/event/actions.html:46 msgid "Edit event" msgstr "" -#: project/templates/_macros.html:1240 project/templates/manage/events.html:45 +#: project/templates/_macros.html:1243 project/templates/manage/events.html:45 msgid "More" msgstr "" -#: project/templates/_macros.html:1287 +#: project/templates/_macros.html:1290 msgid "Please enter a valid time, between 00:00 and 23:59." msgstr "" -#: project/templates/_macros.html:1315 +#: project/templates/_macros.html:1318 #, python-format msgid "Just use %(term)s" msgstr "" -#: project/templates/_macros.html:1381 +#: project/templates/_macros.html:1384 msgid "Event suggestion" msgstr "" -#: project/templates/_macros.html:1499 +#: project/templates/_macros.html:1502 msgid "Link copied" msgstr "" -#: project/templates/_macros.html:1499 +#: project/templates/_macros.html:1502 msgid "Copy link" msgstr "" -#: project/templates/_macros.html:1528 +#: project/templates/_macros.html:1531 msgid "Google calendar" msgstr "" -#: project/templates/_macros.html:1529 +#: project/templates/_macros.html:1532 msgid "Apple calendar" msgstr "" -#: project/templates/_macros.html:1530 +#: project/templates/_macros.html:1533 msgid "Yahoo calendar" msgstr "" -#: project/templates/_macros.html:1531 +#: project/templates/_macros.html:1534 msgid "Other calendar" msgstr "" @@ -1346,24 +1346,21 @@ msgstr "" msgid "Events" msgstr "" -#: project/templates/layout.html:176 -msgid "Planing" -msgstr "" - -#: project/templates/layout.html:177 -msgid "Example" -msgstr "" - #: project/templates/admin/admin.html:19 #: project/templates/admin/admin_units.html:4 #: project/templates/admin/admin_units.html:11 -#: project/templates/layout.html:186 +#: project/templates/layout.html:176 project/templates/layout.html:186 #: project/templates/manage/admin_units.html:3 #: project/templates/manage/admin_units.html:25 +#: project/templates/organization/main.html:4 msgid "Organizations" msgstr "" -#: project/templates/layout.html:187 +#: project/templates/layout.html:177 +msgid "Planing" +msgstr "" + +#: project/templates/layout.html:187 project/templates/layout.html:271 #: project/templates/oauth2_client/list.html:10 #: project/templates/oauth2_client/read.html:10 #: project/templates/oauth2_token/list.html:10 project/templates/profile.html:4 @@ -1466,11 +1463,11 @@ msgstr "" msgid "Widgets" msgstr "" -#: project/templates/layout.html:280 +#: project/templates/layout.html:281 msgid "Switch organization" msgstr "" -#: project/templates/developer/read.html:4 project/templates/layout.html:330 +#: project/templates/developer/read.html:4 project/templates/layout.html:331 #: project/templates/profile.html:29 msgid "Developer" msgstr "" @@ -1964,23 +1961,23 @@ msgstr "" msgid "Member successfully deleted" msgstr "" -#: project/views/admin_unit_member_invitation.py:45 +#: project/views/admin_unit_member_invitation.py:38 msgid "Invitation successfully accepted" msgstr "" -#: project/views/admin_unit_member_invitation.py:52 +#: project/views/admin_unit_member_invitation.py:45 msgid "Invitation successfully declined" msgstr "" -#: project/views/admin_unit_member_invitation.py:97 +#: project/views/admin_unit_member_invitation.py:90 msgid "Invitation successfully sent" msgstr "" -#: project/views/admin_unit_member_invitation.py:120 +#: project/views/admin_unit_member_invitation.py:113 msgid "Entered email does not match invitation email" msgstr "" -#: project/views/admin_unit_member_invitation.py:125 +#: project/views/admin_unit_member_invitation.py:118 msgid "Invitation successfully deleted" msgstr "" @@ -2154,10 +2151,16 @@ msgstr "" msgid "Show" msgstr "" -#: project/views/utils.py:142 +#: project/views/utils.py:143 msgid "You do not have permission for this action" msgstr "" +#: project/views/utils.py:264 +msgid "" +"The invitation was issued to another user. Sign in with the email address" +" the invitation was sent to." +msgstr "" + #: project/views/widget.py:150 msgid "Thank you so much! The event is being verified." msgstr "" @@ -2201,3 +2204,6 @@ msgstr "" #~ msgid "URL für Infoscreen" #~ msgstr "" +#~ msgid "Example" +#~ msgstr "" + diff --git a/project/views/admin_unit_member_invitation.py b/project/views/admin_unit_member_invitation.py index 357f572..e966029 100644 --- a/project/views/admin_unit_member_invitation.py +++ b/project/views/admin_unit_member_invitation.py @@ -12,10 +12,9 @@ from project.forms.admin_unit_member import ( ) from project.models import AdminUnitMemberInvitation, AdminUnitMemberRole from project.services.admin_unit import add_user_to_admin_unit_with_roles -from project.services.user import find_user_by_email -from project.utils import strings_are_equal_ignoring_case from project.views.utils import ( flash_errors, + get_invitation_access_result, handleSqlError, non_match_for_deletion, permission_missing, @@ -26,16 +25,10 @@ from project.views.utils import ( @app.route("/invitations/", methods=("GET", "POST")) def admin_unit_member_invitation(id): invitation = AdminUnitMemberInvitation.query.get_or_404(id) + result = get_invitation_access_result(invitation.email) - # Wenn Email nicht als Nutzer vorhanden, dann direkt zu Registrierung - if not find_user_by_email(invitation.email): - return redirect(url_for("security.register")) - - if not current_user.is_authenticated: - return app.login_manager.unauthorized() - - if not strings_are_equal_ignoring_case(invitation.email, current_user.email): - return permission_missing(url_for("profile")) + if result: + return result form = NegotiateAdminUnitMemberInvitationForm() diff --git a/project/views/user.py b/project/views/user.py index 06c0995..3ee0b44 100644 --- a/project/views/user.py +++ b/project/views/user.py @@ -1,9 +1,9 @@ -from flask import redirect, render_template, url_for -from flask_security import auth_required, current_user +from flask import render_template +from flask_security import auth_required from project import app from project.models import AdminUnitInvitation -from project.services.user import find_user_by_email +from project.views.utils import get_invitation_access_result @app.route("/profile") @@ -15,13 +15,10 @@ def profile(): @app.route("/user/organization-invitations/") def user_organization_invitation(id): invitation = AdminUnitInvitation.query.get_or_404(id) + result = get_invitation_access_result(invitation.email) - # Wenn Email nicht als Nutzer vorhanden, dann direkt zu Registrierung - if not find_user_by_email(invitation.email): - return redirect(url_for("security.register")) - - if not current_user.is_authenticated: - return app.login_manager.unauthorized() + if result: + return result return render_template("user/organization_invitations.html") diff --git a/project/views/utils.py b/project/views/utils.py index 83f78e6..16b0a13 100644 --- a/project/views/utils.py +++ b/project/views/utils.py @@ -13,7 +13,7 @@ from project import app, db, mail from project.access import get_admin_unit_for_manage, get_admin_units_for_manage from project.dateutils import berlin_tz, round_to_next_day from project.models import Analytics, EventAttendanceMode, EventDate -from project.utils import get_place_str +from project.utils import get_place_str, strings_are_equal_ignoring_case def set_current_admin_unit(admin_unit): @@ -138,8 +138,11 @@ def flash_message(msg, url, link_text=None, category="success"): flash(message, category) -def permission_missing(redirect_location): - flash(gettext("You do not have permission for this action"), "danger") +def permission_missing(redirect_location, message=None): + if not message: + message = gettext("You do not have permission for this action") + + flash(message, "danger") return redirect(redirect_location) @@ -241,3 +244,26 @@ def get_calendar_links(event_date: EventDate) -> dict: calendar_links["ics"] = url_for("event_date_ical", id=event_date.id, _external=True) return calendar_links + + +def get_invitation_access_result(email: str): + from project.services.user import find_user_by_email + + # Wenn Email nicht als Nutzer vorhanden, dann direkt zu Registrierung + if not find_user_by_email(email): + return redirect(url_for("security.register")) + + # Wenn nicht angemeldet, dann zum Login + if not current_user.is_authenticated: + return app.login_manager.unauthorized() + + # Wenn der aktuelle Nutzer nicht der Empfänger der Einladung ist, Meldung ausgeben + if not strings_are_equal_ignoring_case(email, current_user.email): + return permission_missing( + url_for("profile"), + gettext( + "The invitation was issued to another user. Sign in with the email address the invitation was sent to." + ), + ) + + return None diff --git a/tests/views/test_user.py b/tests/views/test_user.py index fa67f9b..7288450 100644 --- a/tests/views/test_user.py +++ b/tests/views/test_user.py @@ -26,6 +26,19 @@ def test_organization_invitation_not_authenticated(client, app, utils, seeder): assert response.headers["Location"].startswith("http://localhost/login") +def test_organization_invitation_currentUserDoesNotMatchInvitationEmail( + client, app, db, utils, seeder +): + _, admin_unit_id = seeder.setup_base() + invitation_id = seeder.create_admin_unit_invitation(admin_unit_id) + + seeder.create_user("invited@test.de") + url = utils.get_url("user_organization_invitation", id=invitation_id) + response = client.get(url) + assert response.status_code == 302 + assert response.headers["Location"] == "http://localhost/profile" + + def test_organization_invitation_list(client, seeder, utils): _, admin_unit_id = seeder.setup_base(log_in=False) _ = seeder.create_admin_unit_invitation(admin_unit_id)