From 1ffeadc768fa26836c1f2d9a5779a7cfd228eb6c Mon Sep 17 00:00:00 2001 From: Holger Trampe Date: Wed, 11 Dec 2019 23:22:08 +0100 Subject: [PATCH] =?UTF-8?q?Userprofile=20mit=20Parent=20hinzugef=C3=BCgt?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- areas/migrations/0001_initial.py | 27 +++ areas/migrations/0002_auto_20191211_2158.py | 34 ++++ areas/migrations/__init__.py | 0 .../__pycache__/0001_initial.cpython-38.pyc | Bin 0 -> 1027 bytes .../0002_auto_20191211_2158.cpython-38.pyc | Bin 0 -> 987 bytes .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 165 bytes media/userprofilepics/Seinwill_Steffen.jpg | Bin 24676 -> 24678 bytes news/migrations/0001_initial.py | 28 +++ news/migrations/0002_auto_20191211_2158.py | 34 ++++ news/migrations/0003_auto_20191211_2159.py | 34 ++++ news/migrations/0004_auto_20191211_2200.py | 34 ++++ news/migrations/0005_auto_20191211_2222.py | 34 ++++ news/migrations/__init__.py | 0 .../__pycache__/0001_initial.cpython-38.pyc | Bin 0 -> 1098 bytes .../0002_auto_20191211_2158.cpython-38.pyc | Bin 0 -> 993 bytes .../0003_auto_20191211_2159.cpython-38.pyc | Bin 0 -> 890 bytes .../0004_auto_20191211_2200.cpython-38.pyc | Bin 0 -> 890 bytes .../0005_auto_20191211_2222.cpython-38.pyc | Bin 0 -> 880 bytes .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 164 bytes orga/templates/orga/orga_main.html | 162 ++++++++--------- orga/templates/orga/orga_main_OLD.html | 167 ++++++++++++++++++ standards/migrations/0001_initial.py | 28 +++ .../migrations/0002_auto_20191211_2158.py | 51 ++++++ .../migrations/0003_auto_20191211_2159.py | 29 +++ .../migrations/0004_auto_20191211_2200.py | 29 +++ .../migrations/0005_auto_20191211_2222.py | 29 +++ standards/migrations/__init__.py | 0 .../__pycache__/0001_initial.cpython-38.pyc | Bin 0 -> 1111 bytes .../0002_auto_20191211_2158.cpython-38.pyc | Bin 0 -> 1288 bytes .../0003_auto_20191211_2159.cpython-38.pyc | Bin 0 -> 842 bytes .../0004_auto_20191211_2200.cpython-38.pyc | Bin 0 -> 842 bytes .../0005_auto_20191211_2222.cpython-38.pyc | Bin 0 -> 832 bytes .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 169 bytes tasks/migrations/0001_initial.py | 25 +++ tasks/migrations/0002_auto_20191211_2158.py | 40 +++++ tasks/migrations/__init__.py | 0 .../__pycache__/0001_initial.cpython-38.pyc | Bin 0 -> 870 bytes .../0002_auto_20191211_2158.cpython-38.pyc | Bin 0 -> 1095 bytes .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 165 bytes users/__pycache__/models.cpython-38.pyc | Bin 3108 -> 3170 bytes users/__pycache__/signals.cpython-38.pyc | Bin 1091 -> 1164 bytes users/__pycache__/urls.cpython-38.pyc | Bin 1743 -> 1792 bytes users/__pycache__/usersforms.cpython-38.pyc | Bin 4737 -> 4737 bytes users/__pycache__/views.cpython-38.pyc | Bin 13627 -> 14410 bytes users/migrations/0001_initial.py | 56 ++++++ users/migrations/0002_profile_parent.py | 21 +++ users/migrations/0003_auto_20191211_2200.py | 20 +++ users/migrations/0004_auto_20191211_2222.py | 20 +++ users/migrations/__init__.py | 0 .../__pycache__/0001_initial.cpython-38.pyc | Bin 0 -> 2164 bytes .../0002_profile_parent.cpython-38.pyc | Bin 0 -> 820 bytes .../0003_auto_20191211_2200.cpython-38.pyc | Bin 0 -> 788 bytes .../0004_auto_20191211_2222.cpython-38.pyc | Bin 0 -> 800 bytes .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 165 bytes users/models.py | 5 +- users/signals.py | 11 +- users/templates/users/base.html | 16 +- users/templates/users/profile.html | 5 +- users/templates/users/profile_update.html | 79 ++++++++- .../users/profile_update_DONTKNOW.html | 61 +++++++ users/urls.py | 10 +- users/usersforms.py | 9 + users/views.py | 83 ++++++++- 63 files changed, 1068 insertions(+), 113 deletions(-) create mode 100644 areas/migrations/0001_initial.py create mode 100644 areas/migrations/0002_auto_20191211_2158.py create mode 100644 areas/migrations/__init__.py create mode 100644 areas/migrations/__pycache__/0001_initial.cpython-38.pyc create mode 100644 areas/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc create mode 100644 areas/migrations/__pycache__/__init__.cpython-38.pyc create mode 100644 news/migrations/0001_initial.py create mode 100644 news/migrations/0002_auto_20191211_2158.py create mode 100644 news/migrations/0003_auto_20191211_2159.py create mode 100644 news/migrations/0004_auto_20191211_2200.py create mode 100644 news/migrations/0005_auto_20191211_2222.py create mode 100644 news/migrations/__init__.py create mode 100644 news/migrations/__pycache__/0001_initial.cpython-38.pyc create mode 100644 news/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc create mode 100644 news/migrations/__pycache__/0003_auto_20191211_2159.cpython-38.pyc create mode 100644 news/migrations/__pycache__/0004_auto_20191211_2200.cpython-38.pyc create mode 100644 news/migrations/__pycache__/0005_auto_20191211_2222.cpython-38.pyc create mode 100644 news/migrations/__pycache__/__init__.cpython-38.pyc create mode 100644 orga/templates/orga/orga_main_OLD.html create mode 100644 standards/migrations/0001_initial.py create mode 100644 standards/migrations/0002_auto_20191211_2158.py create mode 100644 standards/migrations/0003_auto_20191211_2159.py create mode 100644 standards/migrations/0004_auto_20191211_2200.py create mode 100644 standards/migrations/0005_auto_20191211_2222.py create mode 100644 standards/migrations/__init__.py create mode 100644 standards/migrations/__pycache__/0001_initial.cpython-38.pyc create mode 100644 standards/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc create mode 100644 standards/migrations/__pycache__/0003_auto_20191211_2159.cpython-38.pyc create mode 100644 standards/migrations/__pycache__/0004_auto_20191211_2200.cpython-38.pyc create mode 100644 standards/migrations/__pycache__/0005_auto_20191211_2222.cpython-38.pyc create mode 100644 standards/migrations/__pycache__/__init__.cpython-38.pyc create mode 100644 tasks/migrations/0001_initial.py create mode 100644 tasks/migrations/0002_auto_20191211_2158.py create mode 100644 tasks/migrations/__init__.py create mode 100644 tasks/migrations/__pycache__/0001_initial.cpython-38.pyc create mode 100644 tasks/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc create mode 100644 tasks/migrations/__pycache__/__init__.cpython-38.pyc create mode 100644 users/migrations/0001_initial.py create mode 100644 users/migrations/0002_profile_parent.py create mode 100644 users/migrations/0003_auto_20191211_2200.py create mode 100644 users/migrations/0004_auto_20191211_2222.py create mode 100644 users/migrations/__init__.py create mode 100644 users/migrations/__pycache__/0001_initial.cpython-38.pyc create mode 100644 users/migrations/__pycache__/0002_profile_parent.cpython-38.pyc create mode 100644 users/migrations/__pycache__/0003_auto_20191211_2200.cpython-38.pyc create mode 100644 users/migrations/__pycache__/0004_auto_20191211_2222.cpython-38.pyc create mode 100644 users/migrations/__pycache__/__init__.cpython-38.pyc create mode 100644 users/templates/users/profile_update_DONTKNOW.html diff --git a/areas/migrations/0001_initial.py b/areas/migrations/0001_initial.py new file mode 100644 index 0000000..b36a9e2 --- /dev/null +++ b/areas/migrations/0001_initial.py @@ -0,0 +1,27 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +import colorful.fields +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Areas', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(max_length=200)), + ('color', colorful.fields.RGBColorField(blank=True, colors=['#FFB900', '#E74856', '#0078D7', '#0099BC', '#7A7574'], default='#0099BC')), + ('desc', models.TextField(blank=True, max_length=3000)), + ('created_area_date', models.DateField(blank=True, default=datetime.date.today)), + ('visible', models.BooleanField(default=True)), + ], + ), + ] diff --git a/areas/migrations/0002_auto_20191211_2158.py b/areas/migrations/0002_auto_20191211_2158.py new file mode 100644 index 0000000..952384b --- /dev/null +++ b/areas/migrations/0002_auto_20191211_2158.py @@ -0,0 +1,34 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('users', '0001_initial'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('areas', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='areas', + name='agency', + field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='users.Agency'), + ), + migrations.AddField( + model_name='areas', + name='created_area_by', + field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL), + ), + migrations.AddField( + model_name='areas', + name='usersfield', + field=models.ManyToManyField(blank=True, related_name='users_in_area', to=settings.AUTH_USER_MODEL), + ), + ] diff --git a/areas/migrations/__init__.py b/areas/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/areas/migrations/__pycache__/0001_initial.cpython-38.pyc b/areas/migrations/__pycache__/0001_initial.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..460ee67dfc3526c8ad94c15a9acb945398775935 GIT binary patch literal 1027 zcmYjQ&2G~`5caOu&VQQzP@o4maKV=Y+VAE1@XJaxxp&u49K?r)qkI zYp%Ql;stmFo?)+?dgR&zFzcjh*V@_n+nxEoU7uAdMFU6p@z19preXZn#>2tT*vBb% zP=Em>GP)#NX_w+kBXh*MY-DvUVjLP^0{dzJ<1Dnlm|Yvl2g9*$aIbOVP*ofSzVOl@ ziKVhf3Ghe`bnM|Mqp^=uenY{tYFLSMP2cD;ZiO~bFnKP_1Hq4h1@?>$Ddf;sfIJjt z1g#=3hNZBK86_w~1*)**TPSNY6Qj$RTfx{0tj;LfYiL)2@TIU8F2keDw~oFQ%z3QO z^KE!Cqdw`b!c#=Fp$f-$NKTb?Ah;(L4WOgwQQKjv>`l_d9iThqph{yAj65-QFZfgy zBo~1f1=n1aFS+O^lDn}t;)-c`^9w;c1c~yl+=$11dakTN5+&j~_oCBj?$zt4ylZUj zZttK{uQztvjZE3wYqn5n95l8YTaKx$e&od$%FZ@Rl>&kWV;%#K2LYFY>Z3}njICq+C)sh&n(Up$*kaUcCxgj|$EoZc9-a0e@PpLDV|;W?L{IZ4d-w0WSFhJ! zxeMT%&{-FPz4CR k*iSa0pHY~xmTkN5ey%w>JO5^WD{nQq(ngUdc~Ud~15Illg#Z8m literal 0 HcmV?d00001 diff --git a/areas/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc b/areas/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..4d06fe97e22f4c06ad3b3aaa027095c2bf950906 GIT binary patch literal 987 zcmZ8gOK;Oa5cYcgisLi^RY)8-!6h7`BvK`)5Ng#I2->1Hk-#!qIoYjc1J-uaENDCXz4S~?a(|%cH4^yS-F?Td>P>5X=Y>HA0i35L1&`Uv1`O?l(knftd;rMTGplxbuUcnUEr0!@vmPY{1@RvM28~U)V|;XtK0Cx9ohmeYqD{8 zmG}r~*o%^hQU?8ge?U^6R%x6ob1Ya~3K!BA9ti2g3FFh{=Rn8zw)F`D8wDr8omEVl zRnf&z7gYMU@d=SWA@JTJXP^g!d|br2iiDH9A|tR$f4%$^&*$+30x6p_P8AtpDpz}Z zJbFRKr+X*l@OXFcwG6H!QdUZDo6>znK&Ww&{(d1?n($X_DIJ={JSn6}C(_eJfN7BK zo0H?w-p)w24`aR@6-sIV=@)ah8kz5gcnEM>{CT&t8I4sNqA`csH(=)%@Txqof!)qg_osv6>f dVyUvY;ah8uz$U$Cb@!gDCY26|0CkXu{{jSK6vqGn literal 0 HcmV?d00001 diff --git a/areas/migrations/__pycache__/__init__.cpython-38.pyc b/areas/migrations/__pycache__/__init__.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..ed6c0ec65582496e3a4561a5547c6e0ab3b5b21b GIT binary patch literal 165 zcmWIL<>g`kg0|3)u^{>}h(HF6K#l_t7qb9~6oz01O-8?!3`HPe1o6wu*(xTqIJKxa zCN!@oH8Cf~B|o_|H#M)MIL6&GBqk*@J+mY+Cp9r0C{$V$lL%B(9Fv=wUX)mpnV(l2 g6Ca2KczG$)edCGXCP((0QLtez5oCK literal 0 HcmV?d00001 diff --git a/media/userprofilepics/Seinwill_Steffen.jpg b/media/userprofilepics/Seinwill_Steffen.jpg index 391af70bf5675de395ade324ed332c7ddfbb51a1..54dd2cf0cbedf53180e945cdb7b70e3f42f39562 100644 GIT binary patch delta 3343 zcmV+q4e;{hzyapK0kD%q1im2El(Uya?GAqiPb~bn!RCqpwdqNW9@Ou~nt1i3F+u)x zoMM53X>sj92sx$vC{gQ4OarI285!wI>61YMfd^rcO=82iCrn@SeIn zMd6D*M3Lu}^5+Azi^G0>e;WCn4i8H7zl2)hwAQE5rhnYtuK0oNDv#>9{DnBNGux2y zN@eH({1z0!sPLsWPx5p z-FWBHy)WYI{&$Nb=tA2m!S^|@HQaxin$9)hxaoiO-N=yr?}ND6o!xvK*sE4UI3 zL2uvY0Fl5Vr@`Z)&svj3u@iCMka^7{GfQQ470eH^Xk0ol?7-w7&ZJ;Ala7D93W7}V zN{*D#5=Yej9oHc7CV^?Hz%VCIojp>akwJGFd@}}n>jUWciF}+CX!Kah|0N18x9Y?YHPy>@4=wZ$|6p4^Q0 zxN$%T4>fYe@@os&FKvI@ZNp&k=={l4;uAOVBTc6zBM6$28 zM355c+r0D)Jkbx>C0CTGD?s^87ec} z)^BsFKMEfXRPlmx8`A=$DgY~v2kT6YG6L)z{o*^ClQ;nK1~Jcn^TkPPVULCx#z;BE zLf{O6$2qCWlacGesKWfY$sMq0C5xxuPo(O$x`nYKYgtxA&vFiN`1Jg1>e~z0bxk(f z`rnvtB3V=D!#IDhlH>$&jFH8ASHa&C$91E=gEW9#S(5OAd3cG>AMTQW0xL)}8KW!W z-L~CAIkDA8Kc#uF`x0S!!(CHe}y~zX*%M7BAn$19qNA&c*c5E*Bl@?<27HL&;!1d zbUwMJ41kfQsG*W(aPzA$`=7WrT(qs|Rot%mW0N~M{Pc(o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U~1SbJOtmpb3|e zlS;#k;+Ur$_&&7e>F-De1Id5r zI#!V;M}>S)jHimr13JSqD6(bqh1d8A>HgV!8T z1#&)M4m}UOS8jg~PMvDYV+R8r$8Kt~oRf}w4AU}XT^k>TYg}D@r%%%NefxBKbMy_l ze?}wltdq-ByU1lz(a3MQb|7a0P)ker8Ix_rw*TnX{>T65ZuvB%@hH9 zJkuYs9<=OYn%{DO6daGO8Ky@01M;VH*AxH`tvyJ|sE@TdN!%y`e%(zcY6m#$K49V15R;{-&$xMze7OBhRE;l zPY1W9M4fh@#-(1oiU39&W3?iX4hg5XJXB zu{q>^4WIkySBxRZt?vhGXT#nrvc6-Bc5f!*{<(j*1pXW!!kTts-5qbn7>D+Sth;hS z{)W8Gy0FO^?_RI*g4#&pv!5A=w$Q_-fBjYD=Z^h4(JjrXd?Ie$gSc`q0pm2hjC9HC zLEVG*N$M%QbMl-Xb5dwH9D0mW@G>c&@;M-p(wsBE{3rsvm;=)X0;;}q&u*1!UWcAY z=Bjx=UV2k9klu$rl(Gyep6bBTf_-U|(9)0Qk2M?hKU#IU%s`4s zI+H;FIZAr_iemlFo$13IiUvqH6dt{4F+u*c0R`4~3a`#;#lXn|prAsJUqhNk9Y#H= XSFa+1JAM=a7BWxxQA$Ql6aoL)Z2xN) diff --git a/news/migrations/0001_initial.py b/news/migrations/0001_initial.py new file mode 100644 index 0000000..94d9d0c --- /dev/null +++ b/news/migrations/0001_initial.py @@ -0,0 +1,28 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +import ckeditor_uploader.fields +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='News', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(default='', max_length=200)), + ('content', ckeditor_uploader.fields.RichTextUploadingField(blank=True, verbose_name='Inhalt')), + ('created_date', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 144449))), + ('go_online_on', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 144449))), + ('go_offline_on', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 144449))), + ('last_modified_on', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 144449))), + ], + ), + ] diff --git a/news/migrations/0002_auto_20191211_2158.py b/news/migrations/0002_auto_20191211_2158.py new file mode 100644 index 0000000..f992dbd --- /dev/null +++ b/news/migrations/0002_auto_20191211_2158.py @@ -0,0 +1,34 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('users', '0001_initial'), + ('news', '0001_initial'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.AddField( + model_name='news', + name='agency', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='users.Agency'), + ), + migrations.AddField( + model_name='news', + name='created_by', + field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL), + ), + migrations.AddField( + model_name='news', + name='last_modified_by', + field=models.ForeignKey(default=None, on_delete=django.db.models.deletion.PROTECT, related_name='news_mod_by', to=settings.AUTH_USER_MODEL), + ), + ] diff --git a/news/migrations/0003_auto_20191211_2159.py b/news/migrations/0003_auto_20191211_2159.py new file mode 100644 index 0000000..e6ca1f8 --- /dev/null +++ b/news/migrations/0003_auto_20191211_2159.py @@ -0,0 +1,34 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:59 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('news', '0002_auto_20191211_2158'), + ] + + operations = [ + migrations.AlterField( + model_name='news', + name='created_date', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 816176)), + ), + migrations.AlterField( + model_name='news', + name='go_offline_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 816176)), + ), + migrations.AlterField( + model_name='news', + name='go_online_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 816176)), + ), + migrations.AlterField( + model_name='news', + name='last_modified_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 816176)), + ), + ] diff --git a/news/migrations/0004_auto_20191211_2200.py b/news/migrations/0004_auto_20191211_2200.py new file mode 100644 index 0000000..054e858 --- /dev/null +++ b/news/migrations/0004_auto_20191211_2200.py @@ -0,0 +1,34 @@ +# Generated by Django 2.2.7 on 2019-12-11 21:00 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('news', '0003_auto_20191211_2159'), + ] + + operations = [ + migrations.AlterField( + model_name='news', + name='created_date', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 106830)), + ), + migrations.AlterField( + model_name='news', + name='go_offline_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 106830)), + ), + migrations.AlterField( + model_name='news', + name='go_online_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 106830)), + ), + migrations.AlterField( + model_name='news', + name='last_modified_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 106830)), + ), + ] diff --git a/news/migrations/0005_auto_20191211_2222.py b/news/migrations/0005_auto_20191211_2222.py new file mode 100644 index 0000000..24a7920 --- /dev/null +++ b/news/migrations/0005_auto_20191211_2222.py @@ -0,0 +1,34 @@ +# Generated by Django 2.2.7 on 2019-12-11 21:22 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('news', '0004_auto_20191211_2200'), + ] + + operations = [ + migrations.AlterField( + model_name='news', + name='created_date', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 194586)), + ), + migrations.AlterField( + model_name='news', + name='go_offline_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 194586)), + ), + migrations.AlterField( + model_name='news', + name='go_online_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 194586)), + ), + migrations.AlterField( + model_name='news', + name='last_modified_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 194586)), + ), + ] diff --git a/news/migrations/__init__.py b/news/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/news/migrations/__pycache__/0001_initial.cpython-38.pyc b/news/migrations/__pycache__/0001_initial.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..659cdfbe70d5ba1730914b8235fd2b586c475ec4 GIT binary patch literal 1098 zcmah|&2AGh5cWDwc9U${^q2B?;eZr@sv;o{6+*3Awd$cgKqH~mqLrI*HcofF!MlN$ zD_r{yaO4Ge2A;u3ddiU_9DwnrRV#6*Eq|Vw{p|64_I6vX2EjIb{qxN?M##B!t~ZR4 z4IKG11R&rfByh@^1{7zSR8khOv>H?$vP+->>=OYd*s%7o64bzXMLN|9t|bQ@Y8t7G zH7{hQa#Kq)5J}#%->$bsbT)A0KM+Kj4Kq1GB_;tA)nN@NRD?V9z`@R-3bixVr{H3& z4j$B@aYoT^ipH=x^pWF3tBlMbqXmwb`8)%&(1tmfhXq)Kr7tclmyBCCGFEP6+`fqs zyKv`>#!fH`cTt^troMlv%AsKg;(czYgdIcowmZ!Dd|YHvPYYfMFwK#cDc7gbu{bsL zTxiJ?`9T=}ozO>FE+WNKVOWV|@*NdK)m;#MK28dhpPxjDP;oIZZZA`XP=%@OsR2(4 z0Atx~Uj`@(d^M(Ud=RSV@r{-MmSb!`t9gRmx#zAO( z-?Eoq%HH5moD|(MELA+^x3*D@Lz#-H>sfIMbWI~0iHnE*mFP#fM+v|8x7NchUQ-@+ z6&@)Gx3k_jMcMOkckeI+8Owqvg2xyd>rmn4hgbhdxVE4P^rAHSK|`OO zo@p~Z)OFI0%$S*>IkQ5mvdzp6ojr|P-2SX_8_d-GWQHy`kF}Qb6Z5r}t~?24ndDR1 zGL%0{rXntrBA3dU6&x~oFd^LSQ%7SPul#}nv{2_-XmC9=xxr1azS`iV?l*mEh8|dH zjk<%M)*(n6sh_T;>)he)xxu}2L|5_JKk+8z|A+7i!Eb6bc~GGm=N8q$UUzsMr&?3B z{i_j%IFP-NAfyU5H#a*h$&)gPGjv-yoJry0{|gU=a^flEljX;tg138>g}7RgGb8~@ zP)1p_OeBa%VR<|QEJD&gO(5gSp9qLc;B359%`BEBLu7(6@*Jo-H6#~WElar^PUA&Z z3fi>_1Y}h%6%<5o>#p)x)rB$TGfG@!fO^2#heezb5H0s|B4JXQ4S5#N=kXYU9OjU7 z8c7%wTJMd9uh{5#aK!cxcLr}&aE(YnDzC@+E{!4Rbt!+h5RgpsH?UL=Pvd-AD1(oc zS5bkFL%IFlalf}SQ0}{CP}TKF~ejSI_OY4@(R2N%}wDzD|K`f9NDq{vTKB-JiGd|dIl;^O|bvt6xT jwy#JK4{1pHi<@y*+GF%7@5O3qFKIW@K@sRp-826J1@IHH literal 0 HcmV?d00001 diff --git a/news/migrations/__pycache__/0003_auto_20191211_2159.cpython-38.pyc b/news/migrations/__pycache__/0003_auto_20191211_2159.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..04cf3c8129f546a349010c7b9a42eb88329cc9f4 GIT binary patch literal 890 zcma)4zi-n(6h8lo9oK;r2{9nLXNi&^Bnk)>QBg6_g+{6@qm!HWVmUpZ!`T*MhJ~U3 z1B}e<{2{k?$_6VEf_Dy4D>1ZZ`SZQ^zWecge$!qrWHi1V|9tbwW$fGpmj~t89=+9& z02o+;#pY`ZtFU9caAL<|2Mio=KQeI9Ubr8e*ahn~8+a>P!wv_w4vRcfX`Pp{(w(9N z6xGbsE{|;r_UNs?6CjH%V6hEWX2lM=3lD5?u(R;#jNo$s9(2Hm0J;#u))yb5GaGtm z8|IB`GjCp-*}s~Zxp5b^N%<|^eYH_c@?DAVDt%`(8clfG)Fq#c#=GOmc+4l`2M?7; zf^{@gnAQj!2#@k}pRrX$h1HgU+XfyR*dfSAb;M|2??j~XRQrJQv=Q~dA)}4CT&4xm zsRq4yjskQqD|tDei(DcvrH)J}H&I`tRn2K>PGq3M;ULrjZ@1xGhuqW}fi#aef7_(O zY;7XIB}za!%dt{6T}_A2M2+f&IaE0&(c5nY71-uSM;X=iFW`33qo~+$_YV4@Y J9RjQG`~~&U=o|n5 literal 0 HcmV?d00001 diff --git a/news/migrations/__pycache__/0004_auto_20191211_2200.cpython-38.pyc b/news/migrations/__pycache__/0004_auto_20191211_2200.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..a74f8b636a1c007995b0a11371584e4eb2716cbd GIT binary patch literal 890 zcma)4%Wl&^6dk`3$4ww*0TKfC*+fo&MXL%GQBkoV8ycyyj7DzmjpcMa4r5!0HL&bI z&?P^?hs?ICERbM}gy4=t)QU|z)*Rp0JkFUr?ezjik))Gf@&Ztl zGn2bIw#nJ2S$-ox7Foa|8?4ld9CQ~R*x+Dm(WW!}FFttCf;RZjfdID7+t59;p?9{a zymjNs+c&Q4UtgKJQ3tk(`5oPPy2d$2_U4f{(+|&S*Ru@$u;Cj`E1G z?#>h@6#@ssqwJ#1*s4p3)s}&~1j;hjLxOB_ZZX=|I}wRI)os9eQj2QfkkCe4E|VPT zRD<3;Ljk&%7QC3xMJACKQg@9jH(p;PWyNV}M#Vsh$so`^Z?@rF2i)Xpfn;|%e^)2M zY;8QiB}za!%dk{7T}=niMTP36IaE0&&^u@d<=DiuZ}?Ri-7F}U_^&CxGWCFJ8~Ann zVmF?asLFUMNfQwt6tg-$#Rq-=p8xSU;Mz15e#Ilsd3TWLga2q~YA~Yzi(}tS$3c+TUBN_sqyq KnmhPb-}wvN0_V^G literal 0 HcmV?d00001 diff --git a/news/migrations/__pycache__/0005_auto_20191211_2222.cpython-38.pyc b/news/migrations/__pycache__/0005_auto_20191211_2222.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..c124ef2f18828bf7cea2095d5e23932e858e6bef GIT binary patch literal 880 zcma)4J&)5s5M8hB*zqMtXh3|3K279UP=F9R#EBCH*Km=LWmx$#6U$+}4*n3LhKAz) z1C;y;e#o|0rGpM3A((ZD?j(x4UHN%u=IzIOn%Qs|FdDnBf4utSFm`H!^Mi71kG^_B z01Pb2V)N(HDtOEbJGL!$z`zFQBLfHd()nP=4p=YP*j>{eb~xrbDDtdIo4i!D?iD4V ztmme7eq5zskG}dF0kYTv7IUyNE4I;Dy1>E4-qNEx{LenP&;t+rZuY-;5S(z>IoUD? zmu3zx&D_11nK^MEu8{JP?myouCi#xSceTDAhT&b2woNIbaC(0lO{XG?!mx5lupZ1S zOdA9Ngh%&+-dG~c7!t(o7HW@_8)HCdt~gW%^Q4cWd8+k C9_4BP literal 0 HcmV?d00001 diff --git a/news/migrations/__pycache__/__init__.cpython-38.pyc b/news/migrations/__pycache__/__init__.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..22b20a89fca21489ce6d6a849d20f71662f97d06 GIT binary patch literal 164 zcmWIL<>g`kf=QttV?p#|5P=LBfgA@QE@lA|DGb33nv8xc8Hzx{2;!HgvsFxJacWU< zOlV$FYGO`|OMY@`Zfaghag4iXNK8s*dS*#tPHJL0P^h#hCNH(TI3_nUy(qCHGe565 gCO$qhFS8^*Uaz3?7Kcr4eoARhsvXFR&p^xo0MnZ)dH?_b literal 0 HcmV?d00001 diff --git a/orga/templates/orga/orga_main.html b/orga/templates/orga/orga_main.html index 0e47ba1..13077dd 100644 --- a/orga/templates/orga/orga_main.html +++ b/orga/templates/orga/orga_main.html @@ -1,89 +1,89 @@ {% extends "users/base.html" %} {% block content %} + +

{{request.user.profile.agency.name}}


Organigramm

- - - - - - - - - {%if external|length > 0%} - - {%endif%} - {%if indoor|length > 0%} - - {%endif%} - {%if trainee|length > 0%} - - {%endif%} - - - {% if external|length > 0 %} - - {%endif%} - - {%if indoor|length > 0%} - - {% endif %} - {%if trainee|length > 0%} - - {% endif %} - - -
- {% if leader != None %} - - {% endif %} - -
- -
-
{{ leader.first_name }} {{ leader.last_name }}
- {{ leader.profile.get_func_display }} -
-

Außendienst

Innendienst

Auszubildende

- {% for us in external %} - -
-
- -
-
{{ us.first_name }} {{ us.last_name }}
- {{ us.profile.get_func_display }} -
-
- {% endfor %} -
- {% for us in indoor %} - -
-
- -
-
{{ us.first_name }} {{ us.last_name }}
- {{ us.profile.get_func_display }} -
-
- {% endfor %} -
- {% for us in trainee %} - -
-
- -
-
{{ us.first_name }} {{ us.last_name }}
- {{ us.profile.get_func_display }} -
-
- {% endfor %} -
- - +
+ + + + + + + + + + + + + + {% endblock content %} \ No newline at end of file diff --git a/orga/templates/orga/orga_main_OLD.html b/orga/templates/orga/orga_main_OLD.html new file mode 100644 index 0000000..c89d436 --- /dev/null +++ b/orga/templates/orga/orga_main_OLD.html @@ -0,0 +1,167 @@ +{% extends "users/base.html" %} +{% block content %} + + +
+

{{request.user.profile.agency.name}}

+
+

Organigramm

+ + + + + + + + + {%if external|length > 0%} + + {%endif%} + {%if indoor|length > 0%} + + {%endif%} + {%if trainee|length > 0%} + + {%endif%} + + + {% if external|length > 0 %} + + {%endif%} + + {%if indoor|length > 0%} + + {% endif %} + {%if trainee|length > 0%} + + {% endif %} + + +
+ {% if leader != None %} + + {% endif %} + +
+ +
+
{{ leader.first_name }} {{ leader.last_name }}
+ {{ leader.profile.get_func_display }} +
+

Außendienst

Innendienst

Auszubildende

+ {% for us in external %} + +
+
+ +
+
{{ us.first_name }} {{ us.last_name }}
+ {{ us.profile.get_func_display }} +
+
+ {% endfor %} +
+ {% for us in indoor %} + +
+
+ +
+
{{ us.first_name }} {{ us.last_name }}
+ {{ us.profile.get_func_display }} +
+
+ {% endfor %} +
+ {% for us in trainee %} + +
+
+ +
+
{{ us.first_name }} {{ us.last_name }}
+ {{ us.profile.get_func_display }} +
+
+ {% endfor %} +
+
+
+ + + + + + + + + + + + + +{% endblock content %} \ No newline at end of file diff --git a/standards/migrations/0001_initial.py b/standards/migrations/0001_initial.py new file mode 100644 index 0000000..18128d1 --- /dev/null +++ b/standards/migrations/0001_initial.py @@ -0,0 +1,28 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +import ckeditor_uploader.fields +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Standards', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(default='', max_length=200)), + ('content', ckeditor_uploader.fields.RichTextUploadingField(blank=True, verbose_name='Inhalt')), + ('created_standard_date', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 142447))), + ('published_on', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 142447))), + ('last_modified_on', models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 58, 18, 142447))), + ('public', models.BooleanField(default=False)), + ], + ), + ] diff --git a/standards/migrations/0002_auto_20191211_2158.py b/standards/migrations/0002_auto_20191211_2158.py new file mode 100644 index 0000000..7f48d58 --- /dev/null +++ b/standards/migrations/0002_auto_20191211_2158.py @@ -0,0 +1,51 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('areas', '0002_auto_20191211_2158'), + ('users', '0001_initial'), + ('tasks', '0001_initial'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('standards', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='standards', + name='agency', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='users.Agency'), + ), + migrations.AddField( + model_name='standards', + name='area', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='areas.Areas'), + ), + migrations.AddField( + model_name='standards', + name='created_standard_by', + field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL), + ), + migrations.AddField( + model_name='standards', + name='last_modified_by', + field=models.ForeignKey(default=None, on_delete=django.db.models.deletion.PROTECT, related_name='user_modified_standard', to=settings.AUTH_USER_MODEL), + ), + migrations.AddField( + model_name='standards', + name='published_by', + field=models.ForeignKey(default=None, on_delete=django.db.models.deletion.PROTECT, related_name='user_published_standard', to=settings.AUTH_USER_MODEL), + ), + migrations.AddField( + model_name='standards', + name='task', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='tasks.Tasks'), + ), + ] diff --git a/standards/migrations/0003_auto_20191211_2159.py b/standards/migrations/0003_auto_20191211_2159.py new file mode 100644 index 0000000..c98190a --- /dev/null +++ b/standards/migrations/0003_auto_20191211_2159.py @@ -0,0 +1,29 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:59 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('standards', '0002_auto_20191211_2158'), + ] + + operations = [ + migrations.AlterField( + model_name='standards', + name='created_standard_date', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 814174)), + ), + migrations.AlterField( + model_name='standards', + name='last_modified_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 814174)), + ), + migrations.AlterField( + model_name='standards', + name='published_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 21, 59, 30, 814174)), + ), + ] diff --git a/standards/migrations/0004_auto_20191211_2200.py b/standards/migrations/0004_auto_20191211_2200.py new file mode 100644 index 0000000..1f4ef94 --- /dev/null +++ b/standards/migrations/0004_auto_20191211_2200.py @@ -0,0 +1,29 @@ +# Generated by Django 2.2.7 on 2019-12-11 21:00 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('standards', '0003_auto_20191211_2159'), + ] + + operations = [ + migrations.AlterField( + model_name='standards', + name='created_standard_date', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 104828)), + ), + migrations.AlterField( + model_name='standards', + name='last_modified_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 104828)), + ), + migrations.AlterField( + model_name='standards', + name='published_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 0, 29, 104828)), + ), + ] diff --git a/standards/migrations/0005_auto_20191211_2222.py b/standards/migrations/0005_auto_20191211_2222.py new file mode 100644 index 0000000..220a9ce --- /dev/null +++ b/standards/migrations/0005_auto_20191211_2222.py @@ -0,0 +1,29 @@ +# Generated by Django 2.2.7 on 2019-12-11 21:22 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('standards', '0004_auto_20191211_2200'), + ] + + operations = [ + migrations.AlterField( + model_name='standards', + name='created_standard_date', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 193586)), + ), + migrations.AlterField( + model_name='standards', + name='last_modified_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 193586)), + ), + migrations.AlterField( + model_name='standards', + name='published_on', + field=models.DateTimeField(blank=True, default=datetime.datetime(2019, 12, 11, 22, 22, 22, 193586)), + ), + ] diff --git a/standards/migrations/__init__.py b/standards/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/standards/migrations/__pycache__/0001_initial.cpython-38.pyc b/standards/migrations/__pycache__/0001_initial.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..ead38f3b08e8d7850b0ba10a87f2830c43d07fc1 GIT binary patch literal 1111 zcmah|zi-n(6t*vp9Vbqj{-i)z7?2{Bsw@l@LWNeXIJ zHU9&Q{3lHO0k?L_$Or@Q?vkpN7<$%yzW45X_uhTaZdI#g3&-Hi&$k~P%evCW?SVdP z7pHuV02bJZ)wa!>vDy%KfYF=sr<8?ra%QqMK~NNaYWRgWG9Wvz@w5H!tGL+c^)}!MjN4@Dql(00;`^xKP zY0lDIxkqWACOPtoorI?6qJmLsb)GSj^P(ca0{E3@S2CvQ*U*D)R{Y%zJ$1am{|WVH-Mz>Z6s5+X={%#-b`k=0;JZ%8`y7 zCk)p?6uleMMBfrEkEc9G9aI2p#8O~smoq7dKB}^3gge&XmMCbC{|fay&1J7AHqj1+TL#VKklj z%h`y{Kk#ps*u)bJ{65{=30v4b8Maa^FbVgw?s$mZkm2D`GXx&Mty2c{B?tu(% zewc83d;3{5zxvkbQs`f^gi~(l1#yVuI5r_GcHLgGADgH4i~Mo^8fL>&>;K((t7n84 sPjsOT1m(kkrg63f9iyj_(8S+dX102&*`*h=7QNI;OBbPJm+X4s9|MOy4*&oF literal 0 HcmV?d00001 diff --git a/standards/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc b/standards/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e657aa39f01f127663778a3cbe0de85fcffc728d GIT binary patch literal 1288 zcmZ`(TWb?R6yE!8Hc69SY|&?5q7agRphcu1O{>_8vJJ`D#Do#bctIfQC``gE#IX!#n7w8+C&Uz9j%7FjOkozGc@gFg9+G4*Ju9dR z)u!?!I8Bh~5y=QQvb17~{>h%91dj-})M}rGBnEED)1Bqj8LLfo($#_Z%Lt%3BkE6i zImRqQqDm|nxiWgcY&PZNt{vnM(_e9v8pF|>5>YKC;d2NuT&+zp$c7w z=9Rc56*$W)9jYCvMrDP2NIeEZ+((jq5))w;5PCDgv7`{5d!ZsVCEFT%i^pT!7eF9m zl7Q5V8ZuRCb~{f|_qct8_7At)d%UnfgoJUg39ut|qVjfee-Rf{Z9g~Zj^I4aaGJZWwAy0Y)RZX)!Kd)w(? zG9pRFdb`g$JqU+khGQZdoK0wNt_ka1-o)O2Ua9JMN^L>piOKe)VOXZ2%b%|szpR|4 z?6u#PebZWB#P0mV5<9-C$`z02XU|_9q{-<_%iKi-`bzehWVaW=>g=;ooohw!N-g9$ bFIAaY_eG3*k7vDoB3sBDu@v;O?wNl8m0xLo literal 0 HcmV?d00001 diff --git a/standards/migrations/__pycache__/0003_auto_20191211_2159.cpython-38.pyc b/standards/migrations/__pycache__/0003_auto_20191211_2159.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..710fcc573d0136344ba5464e4a147107b80ced7c GIT binary patch literal 842 zcma)4F>ljA6h8ax#Bmb{LxqH(6HAsT2|}V2p&}|O2D;El$Z|Pd@~-B>*-r25ff?3r z`~Vo4`3?MuTRUZBU_nCg&LwIkkl?KQeDCgie)oNT(_SwoI6lAldh~@7a^`}|Bfwx6 zrx_vu0Z);{y?y27e&Xjep&r>MKp}WXAQ1i{cuSK2yys*Pt}urj4162sGSj@0WnpY9 zFF`0XcW0MJAA?<-<~@QSi3cR{!OOgaieM3f4^*@kZLAS}h#-U(v>}2H#IW(P4c${8 zdZ%mVmH%d5{WmkCNeB9<=bG(2TkAkk9aHfFxCUddk4B>j<8@WC$!NSio{YzAGQN9H zhp5GF&b8o`0JctGfZ?G$YZJ2SB4f4TVAH{lgDnL4QgsPd31^BIuWcK|F|SoMplGHu zkQF=^HfS(BmO_E;D{d-=rxIgeWnsI^dZwg#)kFt_*hZ|$W6Z|PF>57o-DT{g=E{A` zMIe@<08z}PFxtnv*!YpEgnr_xXzUVVdwY$7Tr_(&a)K&}7mCZJ`2D9p5q%T64SYX( zd_SEUp-nn1&<&ODmGe3mMP<_cr-v!XOjcY8p5a!l)3sA3z37}2O}_J|$=k!_8|~T@ z-6ZBVLPY(aK^S;GK3hNjy86~+3_^Va`L+WKUS#DEW{uoNVnetPaK5_b*wKS?;~qLE KjH?`ZefkSdZQlt1 literal 0 HcmV?d00001 diff --git a/standards/migrations/__pycache__/0004_auto_20191211_2200.cpython-38.pyc b/standards/migrations/__pycache__/0004_auto_20191211_2200.cpython-38.pyc new file mode 100644 index 0000000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yxIwy=fIrK*C7cdXo A$p8QV literal 0 HcmV?d00001 diff --git a/standards/migrations/__pycache__/__init__.cpython-38.pyc b/standards/migrations/__pycache__/__init__.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e82ea6cfff57ace37e3e0b88722b7d2d2b5b7d17 GIT binary patch literal 169 zcmWIL<>g`kf|;QoV?p#|5P=LBfgA@QE@lA|DGb33nv8xc8Hzx{2;!HYvsFxJacWU< zOlV$FYGO`|OMY@`Zfaghag4iXNK8s*dS*#tPHJL0P^h#hrnn?AFD0=kr8p)xGrcIW lBr`v+I3_+mGcU6wK3=b&@)n0pZhlH>PO2Tqp3gwc006@uER6sF literal 0 HcmV?d00001 diff --git a/tasks/migrations/0001_initial.py b/tasks/migrations/0001_initial.py new file mode 100644 index 0000000..75e9148 --- /dev/null +++ b/tasks/migrations/0001_initial.py @@ -0,0 +1,25 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +import datetime +from django.db import migrations, models + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ] + + operations = [ + migrations.CreateModel( + name='Tasks', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(default='', max_length=200)), + ('desc', models.TextField(blank=True, max_length=3000)), + ('created_area_date', models.DateField(blank=True, default=datetime.date.today)), + ('visible', models.BooleanField(default=True)), + ], + ), + ] diff --git a/tasks/migrations/0002_auto_20191211_2158.py b/tasks/migrations/0002_auto_20191211_2158.py new file mode 100644 index 0000000..83f0ed1 --- /dev/null +++ b/tasks/migrations/0002_auto_20191211_2158.py @@ -0,0 +1,40 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('areas', '0002_auto_20191211_2158'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('users', '0001_initial'), + ('tasks', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='tasks', + name='agency', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='users.Agency'), + ), + migrations.AddField( + model_name='tasks', + name='area', + field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='areas.Areas'), + ), + migrations.AddField( + model_name='tasks', + name='created_area_by', + field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to=settings.AUTH_USER_MODEL), + ), + migrations.AddField( + model_name='tasks', + name='usersfield', + field=models.ManyToManyField(blank=True, related_name='users_in_task', to=settings.AUTH_USER_MODEL), + ), + ] diff --git a/tasks/migrations/__init__.py b/tasks/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/tasks/migrations/__pycache__/0001_initial.cpython-38.pyc b/tasks/migrations/__pycache__/0001_initial.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..bcaadac67c7d4a4240803c79e27dc21732ab52ec GIT binary patch literal 870 zcmYjPPjAyO6t^9xP1Gz3`1#TI2>IcH$Ae>Vh|BDw0Rprn ziTkpW&RD``UgA-5O27mDg#eeV;GeyO1AR|o{~rG#7csNFnaZ_jR9zX{nbjamGjX-Y z!|^!8W$w^Ol29NC1Dbd_Nx1Zj4lwX!w+MjZH z@fOB?pfV~3#TIP0xgqAZ5wo+RQ<&Bf<9PTFr!BX4i6QLnE~krMiRJyGZ+AAmGJ!oaz_u~dyI9fNuH3y*MvY4u(>BIh zk*zhfCaN-)+@aRhDjXRRJ&Bi@Onrk<3j2q=taGv#>8pP5@@9MggqFRG` z^;~Wq$XBADV~^JSx;T23UZScdy{wQ#nI6}Z#Y|R>Nl(v4DX3gE0=LOAwa{tfE-QU_ zZ0W(l!OLuOwEg)~yXV}+WuBr57-yVw%Ge$q;@qQKzu6!Dw?)OieufwuLLsWW-iL83 cMtlAi@W68Iy>RH@^;+LIPA22J1$5~B1HXmyN&o-= literal 0 HcmV?d00001 diff --git a/tasks/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc b/tasks/migrations/__pycache__/0002_auto_20191211_2158.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..0f75c5427dfc5259c380b9a0cb6aeb979a0f38c3 GIT binary patch literal 1095 zcmZ`&&2Q5%6wil~rfEt$m_XdPK`+%>2?P^DtGaF=*oL-Nf+)yxYp+U{CdE#Lx+`4w zKfncvf5}%)+~A6s#IxIdPzg(Zc^^MNzu$Y#pj!0}Sjn4T@0yNbd{@Txg}~T?EjB?= zgPN%^F+(nmWiQTxbfxIf^$(J-YaSW(2; zSTro@PvS8rMVx0sx|5u;RP2uw?)s{Lu?1Uv1;LEaq(*2_GqkD2&}WCaN$HD8ZHmSy z^cYIY)S)i(lL`xxYT_q1k{T^h@64j*GkY2LSK^hGc<@iWuI^YtQ~|L@O?pGeYG<~} z4i(&_bzr+D%X=5p`asknoDm`KY;0__F_{%PZf~@nwA!r}ZnqvjR*0EkT*v?rEgWZY z5tCH83nESgF9UV11|?lGX4zXCzffuu4mQ+*XX%#RoE-k|6*oo3e~5e%w-_T4&IIjt57* zL%ese-Fqd2OGM0s^g5L8C{A3xQt9vHoWAt`tlcjFwsN31@ z$(>aIV&hTK1M@q4fZJEAlnbsfVA@w!a&ylmL z-M;kI&(Tkvqv6TQf_8J1XUB^cmX{tn)ZJcm>h7hpx%lgv7cJuVpaz}oiu*!)00HSe RU5xaZnw)S!1ZLgz?7w%(GClwR literal 0 HcmV?d00001 diff --git a/tasks/migrations/__pycache__/__init__.cpython-38.pyc b/tasks/migrations/__pycache__/__init__.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e20bbac2d9b27fc0bb270a6c33b2736519f08d54 GIT binary patch literal 165 zcmWIL<>g`kg1Mm|V?p#|5P=LBfgA@QE@lA|DGb33nv8xc8Hzx{2;!HQvsFxJacWU< zOlV$FYGO`|OMY@`Zfaghag4iXNK8s*dS*#tPHJL0P^h#hrX;aAyErB{GrcIWBr`v+ hI3_+mGcU6wK3=b&@)n0pZhlH>PO2Tqj?X~M000QiD(?UQ literal 0 HcmV?d00001 diff --git a/users/__pycache__/models.cpython-38.pyc b/users/__pycache__/models.cpython-38.pyc index 0ec8d15c72149e8fce7504e1838d7e5df3da8d31..73aaa6376de2c584752abfa39ae9bd49cdd677b9 100644 GIT binary patch delta 438 zcmY*U%}T>S5YDDankG$}{-=d{(2JoLq3B8MLDYkST3f+@meSc4MPu34L%nz~(1Y}} zzJb0#=^OYIQV_(O7s0EDIzcJ8!+!J4H#0l4_x6iz)C@xt@Obt2!{*4ilgI-fNyRIw zQ0XKL3WSFtS3|CY3K7tTq8t4e89_utphFZ4tTi!?&={fxGFHctCBTFjc3YTF2KCdo zQV@rPFSuz)LJECmAhZaip^))aH@hJ~7HnSt`&xAEfglNPZclJ>ye0RRT)op^)a%tR zx|BI0E8;IEQAST2JqmTNaYkR4QL17phMrjgMERS1Lu&j|@yWsXTd5Gag!<8VUwtAo z9i&|oK@~+ZwGUQC$;tCwt!ytKooMUlj2^eWP1>I*zgzHIZLYxdARFGPY**J-tFF>$ zQ?J=)^Qf{#{;b(bFpQP?msThR%dva_4#EoF?ks{T{SE$--#WcB#`vw5dX-SL# diff --git a/users/__pycache__/signals.cpython-38.pyc b/users/__pycache__/signals.cpython-38.pyc index 8eaf08aacbe4a8e5f06e2a86c7157c4585d29dab..509f19d353b94c63b96c4a6e7c6b48f8d15ccdaa 100644 GIT binary patch delta 441 zcmYk2!AiqG5QcX)yGdG`s67;{Ev7|;2)+0O3e}6!ibWBjl+dKoSZdv*g0i7Py=g(n z(Mx;wYL#*HtA*px> zi4Q)NAi-C#mK}}ECz;j$XA16=(BmRP>sg1;SuRrh-)*BDI@h-gpD}JTtr2-B`D1(BUhaBj@ zkZG3%QH>3yJV_sf#Dyv5!RcU5|6XiVL>=3 zNAL+ec=GIRAHkb%;6#cB^5dK2`e^3l((I5{U5EeNuWH*7 G-~0g?j8a$t diff --git a/users/__pycache__/urls.cpython-38.pyc b/users/__pycache__/urls.cpython-38.pyc index 0daf14bc6d22553f7a616a1fb53f955c397ed217..25c1847d5627b0a96a06ead7486828ffa8ce4614 100644 GIT binary patch delta 465 zcmY+Aze~eF6vyu+CN@oSZCYESwkT}}3-*V9fQ#U&qE;cGP(cMkZRcFQjzzf{azT>#}{eJGfd)%8jrlpo?CJB%4?%(CBM#xtz<|B7s+P?#W zGD@D_lO37o1QpNdnU2|`4h6yhRVKSBT*kyy=1OBrZrZgliTV`K5U$B6(g`q?lT=J5 zfN8-j!4%Fif@K9;VSBQh!JLqJ{!|uMg|bCqa%Mdc-f&I$>%vdWtf&q}jp8PMTI1>r zu53PIjknprdVIZOIR$K-l4>)0fdZ(}2OK=_O25+fhz2Yi2FxF{ebx^fqiigK+Jbvn zEkLn>nmTPkywKni;bM=vvw$C=8KC730Y!j;0^%b3Cg73EFkPvL83 zOl1Sg@PlNU8B+wHa)MAfR-l{^R8ANyH}O83t8j`aRGk=99mfKpg$zLb;!tr3s5m!N zToNiS1r_I9AT(KlQI?ZGMIPt^E+Eg1F^(%;AWAw#H<&?FZ}J{S8AkTWHyK^ILJLw7 zOH#u!Q_DAtGW}p;_S2M^Y|0wW#tjUaBEHGJtSW3gASUnR?X0?!zq6)^a+en66eO0E xq!#5BuVg4v0?8^(Ze;V<(*iPi7lpK0D{ShA7cvzHuC*pXEd42&EddkwAqJ4o|(~qat?PXzY9=BF$<93 zU}WJcGMdcD@37f`CxnSHYH}-IK4awOuY4*@jD?e>1icvZH>V1UGO~*c2?>b`i2(qd C$rdaC delta 101 zcmZovZB*q8<>lpK0D^OZA7c0NZ{+*K&Zs?^o5O)obF&YJJTs%)PY4rZ;N(`me8zyyU-?v+7&9hI33@T6ZB7*wWn||Q5)u*>5(5CC C9TpG( diff --git a/users/__pycache__/views.cpython-38.pyc b/users/__pycache__/views.cpython-38.pyc index 3e4f56785938e17a5d107bb9e6f60e06576a8f24..b96a4dfe9773a398e49bc40dbfe307e0bfb4c3e7 100644 GIT binary patch delta 3240 zcmZWrYit}>6`nhwaEfS>hNj>+4N2P->1ORac6WBY-rO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*AA&_}@TuVRQ8^^VD1?UrzsZqE~ZOkkJE6=GKjZW7$W7G1&G l;c;_INr}wT^Zn`m3V)72jNIk-YeCJU$(pLo&|KQ$zW|A|`7Qte diff --git a/users/migrations/0001_initial.py b/users/migrations/0001_initial.py new file mode 100644 index 0000000..daa3101 --- /dev/null +++ b/users/migrations/0001_initial.py @@ -0,0 +1,56 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:58 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('tasks', '0001_initial'), + ] + + operations = [ + migrations.CreateModel( + name='Agency', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('name', models.CharField(default='', max_length=200)), + ('inhaber', models.CharField(blank=True, default='', max_length=200)), + ('street', models.CharField(blank=True, default='', max_length=200)), + ('city', models.CharField(blank=True, default='', max_length=200)), + ('email', models.EmailField(blank=True, default='', max_length=254)), + ('phone', models.CharField(blank=True, default='', max_length=20)), + ('agencypic', models.ImageField(blank=True, default='default.jpg', upload_to='agencymain')), + ], + ), + migrations.CreateModel( + name='Profile', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('phoneland', models.CharField(blank=True, max_length=60)), + ('phonemobile', models.CharField(blank=True, max_length=60)), + ('func', models.CharField(choices=[('lead', 'Agenturleitung'), ('external', 'Außendienst'), ('indoor', 'Innendienst'), ('trainee', 'Azubi')], default='', max_length=50)), + ('image', models.ImageField(blank=True, default='default.jpg', upload_to='userprofilepics')), + ('compfunc', models.CharField(blank=True, max_length=60)), + ('agency', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='users.Agency')), + ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), + ], + options={ + 'permissions': [('agency_change', 'Agenturinformationen verändern'), ('users_usermanagement', 'Benutzer bearbeiten'), ('areas_management', 'Bereiche bearbeiten'), ('tasks_management', 'Aufgabenbereiche bearbeiten'), ('standard_management', 'Standards bearbeiten und freischalten'), ('news_management', 'News bearbeiten und veröffentlichen')], + }, + ), + migrations.CreateModel( + name='Prio', + fields=[ + ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('prio', models.IntegerField(default=0)), + ('task', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='tasks.Tasks')), + ('user', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), + ], + ), + ] diff --git a/users/migrations/0002_profile_parent.py b/users/migrations/0002_profile_parent.py new file mode 100644 index 0000000..0151958 --- /dev/null +++ b/users/migrations/0002_profile_parent.py @@ -0,0 +1,21 @@ +# Generated by Django 2.2.7 on 2019-12-11 20:59 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('users', '0001_initial'), + ] + + operations = [ + migrations.AddField( + model_name='profile', + name='parent', + field=models.ForeignKey(blank=True, default=None, on_delete=django.db.models.deletion.CASCADE, related_name='parent_user', to=settings.AUTH_USER_MODEL), + ), + ] diff --git a/users/migrations/0003_auto_20191211_2200.py b/users/migrations/0003_auto_20191211_2200.py new file mode 100644 index 0000000..0820634 --- /dev/null +++ b/users/migrations/0003_auto_20191211_2200.py @@ -0,0 +1,20 @@ +# Generated by Django 2.2.7 on 2019-12-11 21:00 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + dependencies = [ + ('users', '0002_profile_parent'), + ] + + operations = [ + migrations.AlterField( + model_name='profile', + name='parent', + field=models.ForeignKey(blank=True, on_delete=django.db.models.deletion.CASCADE, related_name='parent_user', to=settings.AUTH_USER_MODEL), + ), + ] diff --git a/users/migrations/0004_auto_20191211_2222.py b/users/migrations/0004_auto_20191211_2222.py new file mode 100644 index 0000000..e6f8149 --- /dev/null +++ b/users/migrations/0004_auto_20191211_2222.py @@ -0,0 +1,20 @@ +# Generated by Django 2.2.7 on 2019-12-11 21:22 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion + + +class Migration(migrations.Migration): + + dependencies = [ + ('users', '0003_auto_20191211_2200'), + ] + + operations = [ + migrations.AlterField( + model_name='profile', + name='parent', + field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='parent_user', to=settings.AUTH_USER_MODEL), + ), + ] diff --git a/users/migrations/__init__.py b/users/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/users/migrations/__pycache__/0001_initial.cpython-38.pyc b/users/migrations/__pycache__/0001_initial.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..8708d32633484c4ca60e4df6245a856b480d27e4 GIT binary patch literal 2164 zcmZuyTW{P%6!vYs_hg$(uRsH|z;apAaxWF?l1qsoN!4r+S}n4?K4-nNwa3fYrcGYq zHNOFnc;OH52l~Qqm?s2Jc|_u&La1=Y-Xzl&bU zO|*V2pgk)7q=Vrb-4a@(GMHdtWmE;7-U8TAJg^1^lt@>DGE|^?V31tPWIfZ=4@}a` zJf)d^O4A@so#K|^4CG#O$2Rj5%>rp=$Yv4F!Z{V$FTwc(Bg1y#nb2I$%4lvh4^4PI%kc*37moFd zs*3pvp?wqHf)>0D%Ww^@`!>_zodc>h)%M+I;(w1~orU+|g9DxF_~8>77vZC+j3-E@ zGg_)XzS%toH;5-6%kt(CDLO=vLgL2vVp&^WUcTlq&JyMZ(r)|6y*+6#SeM4eYSWT6 zH%%hP6X+%gvN{$lbj6-?5BFp_MnPU|A7$-Z6#Xbhhr1z4D;u@L--un5st7o6(;y*Q zx(}QHxt|PWk@2D1N6|E8p&z*Xo|q$RF;9cE<3u1P((+icCkq(5EI53uRtn=`#PM)J z&C6~EcFer}>Lf#JH1=gB*OL=(nqpB!RiR}$9S4yMP7*Z@p~x@o0mA@dS-c~n0Si!; zv+#rl4sVhH*=6n-sA{$rMtx;y4N~sW)~ofFm+(P?g1bRVy|1;? zhd&?(hCEJa(PkW?NXY62=TqupA_y{~EVTF2K0Caw5SX&)4I}1ZJXN0poq>;XHl+g? z=g_GNu`GE}I9AA{o!4N$rcC0N!sqQ#>T<*#x(zTvX(W-f)G{3^ijc*zx-Q73p8Go9 z(B(d+m(>RH{V_g>M3~(x$d~BIAO6gNwnkNEO+i{}g$e?4wxfqbvGU z9#qB+m*^BbPZ|nj-Vje2W+a_9ywpwyKJkVVb)MlcA18Epu7GKut2+~AJQaN@<*+oM z7%}ZL$Z^ebygv;qy+V86BHd{}we?>I1KMJsKr5apLJ3tXS&YW{&1>BejA~3R6A8Lv z>5|TgXsKQ8SF^pfI;st~n&)N7$(qM;WW{ml&Q1fQdChUYN!>s-6iL)HS)&S5C0dB@ zyW_FjCquw7F-aY=Fx1j)d$;qMv%9l)*V)`&UHd}Tjx89*vbvJ>^QQVU2=ynDrLhxigc6tdPJ4;`R8;C*f1iVMACr1EM?px9#Ko(-R`WdbYy*- zV<(~^_bjfocUIb~YqGY%6ZG*YQA8Zfe^|e0VwVtQ!#`UqH+s8@!o6Kikb~Z8rLNot?`~HP~;MQ@f|fWEVH5;k1gBM4P!xX=yNCU zBhuH8^bP$Ytu*xW`o%{^)zD`CGyb+3`Ra_){!7+>WYL=?S-m96|2-8!nC*i;2jSWilk&%Pv`EZxlM@rhzVY|~I9Y$fx5mkN`0 literal 0 HcmV?d00001 diff --git a/users/migrations/__pycache__/0002_profile_parent.cpython-38.pyc b/users/migrations/__pycache__/0002_profile_parent.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..edc86d41abb641485d1f9f4ee4c13c5231e0d36a GIT binary patch literal 820 zcmYjPJ8#rL5VpO3opT`(qCrqV>E;wD5kfiTi6B8DISE-ttG(Mf%Vzyx?Gs9e1a1BU zl+^s2X{jh_k$BA7d5yKBnQvz`^L^vl`g&xMeSh=o?MKJ5ewgH@xs+_vX`hgjmb8^s z+KFwO*ilZ&5>~p2+viMqiGN^8S9+f<=>aQ(Pb>)}JF#N_C%v~~8^ad5F0ZmSb}%aQ zOp7kBs}}vTmY~|>g{iw~X1;AY?IAg^5?fk{1MG_nUg3YWrJXrRK)pigNCu-KGW}t# z7#E{ry|^WPQzwISPlo3#vy%s4B5ulK552h()jJF%EX7K7II1g7ET97%Yfz#C$tzI;I$a$z;%hh#h}+}d zG6yB&O$>PtbB+<`RJKw;@tE`XE1^s&=bDiKc&Gg!nnuj&UP1$vglci7X>}HEOlPNu ze0H+;njgK|-Fu1StBM?245w1=n|9hP6{G!HL!MPH;0%3Ph$^emk#h`t0<;qhcBUsg z)7?Fc>IN?M^v%)_=ymUY&vu@qGb3C&t279e?$(P{NlLZp!SmBp=2_ke1tKG8rPE&H z^m^whsr{H=h|C9NC(W7ms6j}ly=?*(+0I|rcWsBh`+wYj{e2wb+A#EFQCG`BfYAja t=e|g)@ literal 0 HcmV?d00001 diff --git a/users/migrations/__pycache__/0003_auto_20191211_2200.cpython-38.pyc b/users/migrations/__pycache__/0003_auto_20191211_2200.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..a1d2d3ab80d0a84d1a9ab050047050eed874e869 GIT binary patch literal 788 zcmYjPO>fgc5M6t1$8i!`i3@OmvoBE+4v4BkjheI|Xpv|mfn~IEvQx{hKf>BM^bFVj z5dP9!IdR~?6$zDDJEa|KM>Ef}o_TM)7z{i{_Uq&C&o4~Ie(2=BS(F^msrJZ8CXI~c zMqn5^HZwEl0ne?#YI2_0fpg5HCGBra+Q8G!R~~dEKV!c0lkPL$K(~UrPKvnlP4x04 zR#BalMTJgYO313ym9D#QT}lqL1?)IhvRpGG^;@!>8~ig9Q2M#1xZ}Ig)4Mq8WnMgrd*=i z%thK_=Wu#b&eT(?Y22SrhkM~dOB5~& z1yL5x%GD+(b*k|A&3P!3IH{uyqL`qK3L7=UyN!mV>vIup>QYQbfgc5M6t1$8nRkH&h7;uD(P`;6jC}M*RXoi$t0OmSN>&Czj269oF`tXSnu< z@R#<=i6d7eRA%j#R${Cj%{lA%_R(>|EkOz^ zvMdwZ!Y*h;3ny~goC-Jc&Iot7`;BlHXx{ruqaLSo5_&)JJ_#-DS5ViPOsmk=L6M~@ zsk2g6+AB&9qPkd_x`$@wJH%5RpaT+FoJ2OaQY)h1XJ>zlNXceWWuJ?@mTjZs$6FR zw6{qV$of)mbpbOMLsz>?k;u>5k&O_#UrL4)pawlqAd(t5lSu*EuFH@jSwpZxoECT2 z83=w6?r5L2IAc0s4C@*J7!Mfx(j>yvnvBB+BnP?5pi&gY(7{a9pia$Klv$JxPD=$@ zD&N4B_IRGiwA40VYQLQeb=JM3+5BjBe4=pKMDNTNm#^4je)683zdJs8tAla_w;TCR z)Dx^}-R}=a`|-kv6)&WMM8wDCswq&CDn5IC8S^a7>O?@2BGjn3)iu7~Zj1^)|4-rR zbhNorE;jM;RJ$gi_Ko8@mW|KjKh912HuUvYM`pAt<+>Zae~a*Ct3}6u?;kkoey7nL fakXc-m|pj+y67ol+JD)peqeO1JahwV*YfFKrig`kf~BD!V?p#|5P=LBfgA@QE@lA|DGb33nv8xc8Hzx{2;!HQvsFxJacWU< zOlV$FYGO`|OMY@`Zfaghag4iXNK8s*dS*#tPHJL0P^h#hrWC9+H#5B`u_QA;uQ(TZlX-=vg$d1oI%m4rn-zx(E literal 0 HcmV?d00001 diff --git a/users/models.py b/users/models.py index e90880a..449fc25 100644 --- a/users/models.py +++ b/users/models.py @@ -71,13 +71,16 @@ class Profile(models.Model): # Wenn der User gelöscht wird, wird auch das Profil gelöscht user = models.OneToOneField(User, on_delete=models.CASCADE) + parent = models.ForeignKey(User, on_delete=models.CASCADE, related_name='parent_user') phoneland = models.CharField(max_length=60, blank=True) phonemobile = models.CharField(max_length=60, blank=True) - func = models.CharField(choices=agency_task, default="lead", max_length=50) + func = models.CharField(choices=agency_task, default="", max_length=50) # Wenn dieses Profil gelöscht wird, wird NICHT die Agency geslöscht agency = models.ForeignKey(Agency, on_delete=models.PROTECT) image = models.ImageField(default='default.jpg', upload_to='userprofilepics', blank=True) compfunc = models.CharField(max_length=60, blank=True) + + def __str__(self): return f'{self.user.last_name}' diff --git a/users/signals.py b/users/signals.py index 4e26c1e..a7c37ac 100644 --- a/users/signals.py +++ b/users/signals.py @@ -8,7 +8,7 @@ from django.contrib.auth.models import Permission @receiver(post_save, sender=User) def create_profile(sender, instance, created, **kwargs): if created: - Profile.objects.create(user=instance, agency=instance.agency) + Profile.objects.create(user=instance, agency=instance.agency, parent=instance.parent) ''' Wenn ein neuer Nutzer angelegt wird und dies der erste der Agentur ist, @@ -20,10 +20,11 @@ def create_profile(sender, instance, created, **kwargs): temprof = Profile for ele in temprof._meta.permissions: tempperm = Permission.objects.get(codename=ele[0]) - tempuser.user_permissions.add(tempperm) + tempuser.user_permissions.add(tempperm) + tempuser.profile.func = 'lead' tempuser.save() - @receiver(post_save, sender=User) -def save_profile(sender, instance, **kwargs): - instance.profile.save() +def save_profile(sender, instance, **kwargs): + print("PROF SAVED") + instance.profile.save() \ No newline at end of file diff --git a/users/templates/users/base.html b/users/templates/users/base.html index e9a02d3..72f2ef6 100644 --- a/users/templates/users/base.html +++ b/users/templates/users/base.html @@ -28,6 +28,8 @@ + + @@ -316,7 +318,6 @@ - @@ -333,14 +334,15 @@ searchstring: searchstring }, success: function( data ) - { + { $("#searchres").empty(); - for (var i = 0; i < data['res'].length; i++) + for (var i = 0; i < data['standards'].length; i++) { - id = data['res'][i]['id']; - name = data['res'][i]['name'] + " | " + data['res'][i]['content']; - $("#searchres").append(''); - } + id = data['standards'][i]['id']; + name = data['standards'][i]['name'] + " | " + data['standards'][i]['content']; + console.log(name); + $("#searchres").append(''); + } } }); } diff --git a/users/templates/users/profile.html b/users/templates/users/profile.html index f20d890..8ce322d 100644 --- a/users/templates/users/profile.html +++ b/users/templates/users/profile.html @@ -48,12 +48,13 @@ Profil bearbeiten - {{ u_form|crispy }} + {{ u_form|crispy }} + Agenturrelevante Daten werden in der Benutzerverwaltung verändert.
  - Abbrechen + Abbrechen
diff --git a/users/templates/users/profile_update.html b/users/templates/users/profile_update.html index 4c778a7..c950b10 100644 --- a/users/templates/users/profile_update.html +++ b/users/templates/users/profile_update.html @@ -3,37 +3,37 @@ {% block content %}
- +
- +
Name

- {{ object.user.first_name}} {{ object.user.last_name }} + {{ prof_user.first_name}} {{ prof_user.last_name }}

E-Mail

- {{ object.user.email }} + {{ prof_user.email }}

Agenturfunktion

- {{ object.get_func_display }} + {{ prof_user.profile.get_func_display }}

Tätigkeit

- {{ object.compfunc }} + {{ prof_user.profile.compfunc }}

Fesetznetz

- {{ object.phoneland }} + {{ prof_user.profile.phoneland }}

Mobil

- {{ object.phonemobile }} + {{ prof_user.profile.phonemobile }}

@@ -48,8 +48,22 @@ Profil bearbeiten - {{ form|crispy }} + {{ profileform_form|crispy }} + Übergeordneter Mitarbeiter: {{prof_user.profile.parent.first_name}} {{prof_user.profile.parent.last_name}} +
+ +
+ + +
+ + {% for us in possible_users %} + + {% endfor %} + + +

  @@ -58,4 +72,51 @@
+ {% endblock content %} \ No newline at end of file diff --git a/users/templates/users/profile_update_DONTKNOW.html b/users/templates/users/profile_update_DONTKNOW.html new file mode 100644 index 0000000..4489168 --- /dev/null +++ b/users/templates/users/profile_update_DONTKNOW.html @@ -0,0 +1,61 @@ +{% extends "users/base.html" %} +{% load crispy_forms_tags %} +{% block content %} +
+
+ +
+ +
+
+
+
Name
+

+ {{ user.first_name}} {{ user.last_name }} +

+
E-Mail
+

+ {{ user.email }} +

+
Agenturfunktion
+

+ {{ get_func_display }} +

+
+
+
Tätigkeit
+

+ {{ compfunc }} +

+
Fesetznetz
+

+ {{ phoneland }} +

+
Mobil
+

+ {{ phonemobile }} +

+
+
+
+
+ +
+
+ {% csrf_token %} +
+ + Profil bearbeiten + + + {{ profileform_form|crispy }} +
+
+
+   + Abbrechen +
+
+
+
+{% endblock content %} \ No newline at end of file diff --git a/users/urls.py b/users/urls.py index d12acf5..ef38cc3 100644 --- a/users/urls.py +++ b/users/urls.py @@ -1,6 +1,7 @@ from django.urls import path from django.contrib.auth import views as auth_views -from .views import UsersCreateUser, UsersManagement, UserManagementUpdateForm, ProfileUpdateView, ProfileDeleteView, AgencyUpdateView, UsersPermUpdateView +#from .views import UsersCreateUser, UsersManagement, UserManagementUpdateForm, ProfileUpdateView, ProfileDeleteView, AgencyUpdateView, UsersPermUpdateView +from .views import UsersCreateUser, UsersManagement, UserManagementUpdateForm, ProfileDeleteView, AgencyUpdateView, UsersPermUpdateView from . import views from django.contrib.auth.decorators import login_required, permission_required @@ -18,7 +19,8 @@ urlpatterns = [ path('usersman/', permission_required('users.users_usermanagement')(UsersManagement.as_view(template_name="users/users_management.html")), name='users-management'), path('usersman/adduser/', permission_required('users.users_usermanagement')(UsersCreateUser.as_view(template_name="users/users_adduser.html")), name='users-adduser'), path('usersman/profile/', views.profile, name='users-profile'), - path('usersman//', permission_required('users.users_usermanagement')(ProfileUpdateView.as_view()), name='users-update'), + path('usersman//', views.ProfileUpdateView, name='users-update'), + #path('usersman//', permission_required('users.users_usermanagement')(ProfileUpdateView.as_view()), name='users-update'), path('usersman//perms', permission_required('users.users_usermanagement')(UsersPermUpdateView.as_view()), name='users-perm-update'), path('usersman//delete', permission_required('users.users_usermanagement')(ProfileDeleteView.as_view()), name='users-delete'), path('agencyinfo/', views.agency, name='agencyinfo'), @@ -28,7 +30,9 @@ urlpatterns = [ path('areataskupdate//', views.UsersAreaTaskUpdate, name="users-areataskupdate"), path('globalsearch/', views.GlobalSearch, name="globalsearch"), path('standardrout/', views.searchStandardRouter, name="standardrouter"), - path('support/', views.support, name="supportda") + path('support/', views.support, name="supportda"), + path('setuserparent/', views.setuserparent, name="users-setuserparent") + ] diff --git a/users/usersforms.py b/users/usersforms.py index 2929092..49afb06 100644 --- a/users/usersforms.py +++ b/users/usersforms.py @@ -37,6 +37,15 @@ class UsersAddProfileForm(forms.ModelForm): } fields = ['phoneland','phonemobile','func', 'compfunc', 'image'] +#class UsersAddProfileFormParents(forms.ModelForm): + + +# def __init__(self, user, *args, **kwargs): +# super().__init__(*args, **kwargs) +# possibleUsers = Profile + + + # Formular zum hinzufügen neuer Agentur-Mitglieder class AgencyUpdateForm(forms.ModelForm): diff --git a/users/views.py b/users/views.py index ac29b46..9313115 100644 --- a/users/views.py +++ b/users/views.py @@ -114,6 +114,7 @@ class UsersCreateUser(LoginRequiredMixin, CreateView): messages.success(self.request, f'Benutzer angelegt!') # SAVE OBJECTS TO SIGNALE! form.instance.agency = self.request.user.profile.agency + form.instance.parent = self.request.user newuser_name = form.cleaned_data.get('first_name') + " " + form.cleaned_data.get('last_name') msg_html = render_to_string('users/newusers_email.html', {'username': newuser_name}) # E-Mail für Passwort-Setzung! @@ -205,6 +206,7 @@ class UsersPermUpdateView(LoginRequiredMixin, View): # Benutzerprofil wird aktualisiert +''' class ProfileUpdateView(LoginRequiredMixin, UpdateView): model = Profile form_class = UsersAddProfileForm @@ -216,6 +218,72 @@ class ProfileUpdateView(LoginRequiredMixin, UpdateView): context['active_link'] = 'usersmanagement' return context +''' +@login_required +def ProfileUpdateView(request, pk): + prof_user = User.objects.get(profile__pk=pk) + + if request.method == 'POST': + profileform_form = UsersAddProfileForm(request.POST, instance=prof_user.profile) + #profileform_parents = UsersAddProfileFormParents(request.POST, instance=request.user) + + if profileform_form.is_valid(): + + print(profileform_form) + + profileform_form.save() + #prename = request.user.first_name + #name = request.user.last_name + #messages.success(request, f'Daten für {prename} {name} aktualisiert!') + # Daten neu laden und nicht die "Mächten sie die Daten speichern...?" + return redirect('users-management') + + else: + # Form in Klammern sind die aktuellen Daten :) + profileform_form = UsersAddProfileForm(instance=prof_user.profile) + possible_users = User.objects.filter(profile__agency__pk=prof_user.profile.agency.pk) + + + context = { + 'prof_user' : prof_user, + 'profileform_form' : profileform_form, + 'active_link' : 'usersmanagement', + 'possible_users' : possible_users + } + + + return render(request, 'users/profile_update.html', context) + +''' + + Set users Parent by AJAX + +''' +@login_required +def setuserparent(request): + if request.method == 'GET': + + if request.GET['action'] == 'adduserp': + + userid = request.GET['objectid'] + toadd = request.GET['userid'] + toadd_user = User.objects.get(pk=toadd) + workinguser = User.objects.get(pk=userid) + username_clean = toadd_user.first_name + " " + toadd_user.last_name + workinguser.profile.parent = toadd_user + workinguser.save() + # Getting Remaining-Users + possible_users = User.objects.filter(profile__agency__pk=request.user.profile.agency.pk) + possible_users_js = list(possible_users.values()) + # Cleaned out, that only data is neede will send to the side (first/last-name and id) + final_possible_users = {} + for ele in possible_users_js: + final_possible_users.update({'first_name':ele['first_name'],'last_name':ele['last_name'],'id':ele['id']}) + # Counter for remaining users to show/hide "Keine Mitarbeiter"-Div + return JsonResponse({'userid' : userid, 'username_clean' : username_clean, 'remaining_users':possible_users_js}) + else: + return HttpResponse("Request method is not a GET") + ''' # DELETE A USER @@ -342,10 +410,10 @@ def GlobalSearch(request): ag = request.user.profile.agency.pk results = Standards.objects.filter(agency__pk=ag, public=True).filter(name__icontains=searchfor) | Standards.objects.filter(agency__pk=ag, public=True).filter(content__contains=searchfor) | Standards.objects.filter(agency__pk=ag, public=True).filter(area__name__icontains=searchfor) | Standards.objects.filter(agency__pk=ag, public=True).filter(task__name__icontains=searchfor) | Standards.objects.filter(agency__pk=ag, public=True).filter(created_standard_by__last_name__icontains=searchfor)|Standards.objects.filter(agency__pk=ag, public=True).filter(created_standard_by__first_name__icontains=searchfor) - results = list(results) - final_results = [] + results_st = list(results) + final_results_st = [] i = 0 - for ele in results: + for ele in results_st: tempele = {} tempele['id'] = ele.pk tempele['name'] = ele.name @@ -357,9 +425,14 @@ def GlobalSearch(request): tempele['last_name_mod'] = ele.last_modified_by.last_name tempele['created'] = formats.date_format(ele.created_standard_date, "d.m.Y") tempele['last_modified_on'] = formats.date_format(ele.last_modified_on, "d.m.Y") - final_results.append(tempele) + final_results_st.append(tempele) i += 1 - return JsonResponse({'res' : final_results}) + + + + + + return JsonResponse({'standards' : final_results_st}) else: return HttpResponse("Request method is not a GET")