From 60fac958807b8daabfbcd994f334fb963c9dd79e Mon Sep 17 00:00:00 2001 From: s460930 Date: Mon, 30 Nov 2020 22:42:24 +0100 Subject: [PATCH] SMART-29 created user_profile app, UserProfile class and made migration --- .idea/dataSources.xml | 11 +++++++ rest-app/db.sqlite3 | Bin 143360 -> 155648 bytes .../__pycache__/settings.cpython-38.pyc | Bin 2339 -> 2374 bytes .../user/__pycache__/models.cpython-38.pyc | Bin 2418 -> 2416 bytes .../migrations/0002_auto_20201130_2119.py | 17 ++++++++++ .../0002_auto_20201130_2119.cpython-38.pyc | Bin 0 -> 530 bytes rest-app/smartpicasso/app/user/models.py | 2 +- .../smartpicasso/app/user_profile/__init__.py | 0 .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 184 bytes .../__pycache__/admin.cpython-38.pyc | Bin 0 -> 225 bytes .../__pycache__/models.cpython-38.pyc | Bin 0 -> 1124 bytes .../smartpicasso/app/user_profile/admin.py | 3 ++ .../smartpicasso/app/user_profile/apps.py | 5 +++ .../user_profile/migrations/0001_initial.py | 30 ++++++++++++++++++ .../app/user_profile/migrations/__init__.py | 0 .../__pycache__/0001_initial.cpython-38.pyc | Bin 0 -> 1055 bytes .../__pycache__/__init__.cpython-38.pyc | Bin 0 -> 195 bytes .../smartpicasso/app/user_profile/models.py | 24 ++++++++++++++ .../smartpicasso/app/user_profile/tests.py | 3 ++ .../smartpicasso/app/user_profile/views.py | 3 ++ rest-app/smartpicasso/settings.py | 3 +- 21 files changed, 99 insertions(+), 2 deletions(-) create mode 100644 .idea/dataSources.xml create mode 100644 rest-app/smartpicasso/app/user/migrations/0002_auto_20201130_2119.py create mode 100644 rest-app/smartpicasso/app/user/migrations/__pycache__/0002_auto_20201130_2119.cpython-38.pyc create mode 100644 rest-app/smartpicasso/app/user_profile/__init__.py create mode 100644 rest-app/smartpicasso/app/user_profile/__pycache__/__init__.cpython-38.pyc create mode 100644 rest-app/smartpicasso/app/user_profile/__pycache__/admin.cpython-38.pyc create mode 100644 rest-app/smartpicasso/app/user_profile/__pycache__/models.cpython-38.pyc create mode 100644 rest-app/smartpicasso/app/user_profile/admin.py create mode 100644 rest-app/smartpicasso/app/user_profile/apps.py create mode 100644 rest-app/smartpicasso/app/user_profile/migrations/0001_initial.py create mode 100644 rest-app/smartpicasso/app/user_profile/migrations/__init__.py create mode 100644 rest-app/smartpicasso/app/user_profile/migrations/__pycache__/0001_initial.cpython-38.pyc create mode 100644 rest-app/smartpicasso/app/user_profile/migrations/__pycache__/__init__.cpython-38.pyc create mode 100644 rest-app/smartpicasso/app/user_profile/models.py create mode 100644 rest-app/smartpicasso/app/user_profile/tests.py create mode 100644 rest-app/smartpicasso/app/user_profile/views.py diff --git a/.idea/dataSources.xml b/.idea/dataSources.xml new file mode 100644 index 0000000..16e6268 --- /dev/null +++ b/.idea/dataSources.xml @@ -0,0 +1,11 @@ + + + + + sqlite.xerial + true + org.sqlite.JDBC + jdbc:sqlite:$PROJECT_DIR$/rest-app/db.sqlite3 + + + \ No newline at end of file diff --git a/rest-app/db.sqlite3 b/rest-app/db.sqlite3 index 891a8cc5fd58a8adf0f725f438f54a8985d0d2b9..a5478a487dea049f6c3dce6f5e1191f8b700d583 100644 GIT binary patch delta 1141 zcmZ`%O-vI(6yE6%U0U10*isbR4#lO#QrKy&rL77`R!~S0Y~u;Gg)Y(nZBq(*ps_`x zMlOJg(&sv4U@{X@N4%->KS@fwr_MRm>2aA`J`PL9W? zxWZG*vEEbI@AkA}uNS+#e!Y?~1SAYi(=IkTn@O@R+C^jRrdb!pK5^m1*y*N`3;VIp z?>^nyPGgS;uUYCR^#BzX+j;?6_}Jz+YETP(kuXBQU+@F`3}3@1a1mxPg5F@F)BP-@{k%F}x4wAzRG%KvO-bAgIOzxP|$Fdvc`B7F3sg zr1qWmh4!H~Tg-d3Y^?$~0XY}vuCrxlp*jV?fQ)fdT!t%8Shf;l6Vb%AiiFvq01iM# zW3h6$Y3=Kq2P zlLd?UOEPAm>72?)QQ$VrL`SE%y-IE0|B3D)rYpptP}li>23gBtR%GX6NkF0TczPzo zCZf}v70pG{f*NVNhi*o}fe;FY`}_HqF;F{FzSDxNsflEQV-vH}qg;BIhDDk{5dhLr z@t74!_1v!AdMF&cI2dNo5OaYUVuIbw6=da8J;HF!-p(pxA0ydDS}bk(!d` zjwY`dmGuSk3*~D$dr^hEVO7Q07r)TEH8-Xe1?Vl4E=P_}y z0~Kr9z}4_T)EI)P?fa7%wb+?h_%}9kvluk7TeFLci!(OomLw+Sq=Hp|2}S21SH}=n wg%C$4A6Eq>u$Yp9#&q2jMu+Wb`Hb@tm}R&hO=rKr2z2ox?(L6mGs=Yk0FKdP*#H0l diff --git a/rest-app/smartpicasso/__pycache__/settings.cpython-38.pyc b/rest-app/smartpicasso/__pycache__/settings.cpython-38.pyc index 37ff6a6f9ebf1c8ccd971651349afc89f60c4148..167151aacf6aea37d2c7c2873f9f23977e8f752b 100644 GIT binary patch delta 220 zcmZ21bWDghl$V!_0SLm9j>daUhF-3X~OFCl|Z;DJ5Uy5vsTq;|Nyfj0K!W^bd z#wh+2#S|r=8pRZ4FsTA2RWljWS)v3|)S?7a)T4w_SfYf1SOkbgQ#duE#8Nba88o#v zzEfk8lP%6oEGj9;OinB=&euyUD9|e{PA!TrD9TUE%t_rW%sh>iv10Nn4jEQPrtd7g JlTUI)0RTXGIo1FG delta 185 zcmW-Xy$-=p7>0ZFP@$*Vqw25quQX<(s}Re#FuZco8?d^DMr<}$Aa)yzTahptop_Vy z8J@fkd6r@&M9I*5Z|>`HCL(srW{bVDs014V4k~crLF!UQm2CLR07nf0>S&;;c*@W^ zam7fWO%6gt+X6am1Km?DWmG{Aef{ZS@b~cVQOXo27i01elLV)##@Ey^AuGUiX(Y+z W6X&jT^O$G5!?PHgUv3{>Mfw3#3@#D? diff --git a/rest-app/smartpicasso/app/user/__pycache__/models.cpython-38.pyc b/rest-app/smartpicasso/app/user/__pycache__/models.cpython-38.pyc index a8aa9a7ecc530e6b3b578dbe9c9663e44c291ff8..bc5624af33562f037b0591c32af1430cbd4ca052 100644 GIT binary patch delta 64 zcmew)^g)O>l$V!_0SIm+9*xi6$h(T2wMYoaoxG3TlU)PI@Y58Xe2`savJyuZqsC-A RPVvb{I4l{pCja9o0RSlT5lsL9 delta 56 zcmew$^ht;}l$V!_0SG3=AB`{A$h(T2{T6FZetKr!$Vi+)8m?`@!F zF#e-O$at+5%7k$oCp53}CTE3mNLQ*@DU9E+Ss^CTf$3A~6iQ7%X(@SIxN}J9Q_G5N zCFG(O6&KY!7g`|;GDp`%Bh*-OQQSF{31ls{Zr*@8w0FAgTapJ^3R1I1tsY6sN}@$6 zbfZ$DS2>xMOf|RpoM|nIvib?DYoeW6Z&fEaKV&yAVx6UwwT+}{oW@CV8q+jM&PVl1 zVf%H@F70~gW3={s4i;g`k0*$1j@gVv!h(HF6K#l_t7qb9~6oz01O-8?!3`HPe1o10YKO;XkRlgvy zq^L4mzcevdzc@8FwYa3nNWZu;Q$IL2v8W^Gu19yfY)exT)F4ib;qQ>?HjWFPqQNG3%_*O$=1l9*#2=6T*@r7^>d{5nv e_Mq_!Gl%x1O9jL8rE9zK+F03?YQyQ>o6Nq9T0AxY literal 0 HcmV?d00001 diff --git a/rest-app/smartpicasso/app/user_profile/__pycache__/models.cpython-38.pyc b/rest-app/smartpicasso/app/user_profile/__pycache__/models.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..f37a9a61be95139833d4a0e3155f0639e3f06ba3 GIT binary patch literal 1124 zcmZuwO>fgM7|w^&rfFKXf&d{7xuFQrNP`nXsME#}hYh5ymvFG$`R$r6U$Ya5_ByWn zA^Zof{0Uz%N4U$LL}u`?YEJOjs%`8WF2GK}xq*&YO)2~PPEfg7>G zO>U)TY~tHat;~*XQ^!b3GADLS^(>D95}= zS;f3tT+=uSP1VT?4yi}I1f1q9gWEl99P?hrKG78Ni)x`db)H<+aH|h6B%+Tm;Ug%L z*J-MpS<3Ruf21_AVuDlNL)ey*TQT7_woBGKTkVdIp+;qn=6cKBk5 z`^dF{pC6+|kwH|lN~|uUnq`rM3}hwtBDqSUQ`EWokeo9qiwIAqddA8!k~&&$qB^im zENbuGxLhfsd)2x~eeGS7*y14?C*er!Y6c?>cQxoDf&Yu4deiB+geEU+UEe*}KRwt#e1p}fj_MsOm}o!u=82G1qmb&QY-7fLxhQg=d7aHb zG<^QZ(OM5Q8O>PV1UW>|)JNvX9O5&wnq26%q#t2g_4tzI7sZ&*nkM4M+X{_Qp|K`6 hZk1_yJI#e}mipiR%6-)y=xcq!q>Dg^Yx<^d{{on}C+PqH literal 0 HcmV?d00001 diff --git a/rest-app/smartpicasso/app/user_profile/admin.py b/rest-app/smartpicasso/app/user_profile/admin.py new file mode 100644 index 0000000..8c38f3f --- /dev/null +++ b/rest-app/smartpicasso/app/user_profile/admin.py @@ -0,0 +1,3 @@ +from django.contrib import admin + +# Register your models here. diff --git a/rest-app/smartpicasso/app/user_profile/apps.py b/rest-app/smartpicasso/app/user_profile/apps.py new file mode 100644 index 0000000..91ad550 --- /dev/null +++ b/rest-app/smartpicasso/app/user_profile/apps.py @@ -0,0 +1,5 @@ +from django.apps import AppConfig + + +class UserProfileConfig(AppConfig): + name = 'user_profile' diff --git a/rest-app/smartpicasso/app/user_profile/migrations/0001_initial.py b/rest-app/smartpicasso/app/user_profile/migrations/0001_initial.py new file mode 100644 index 0000000..316b371 --- /dev/null +++ b/rest-app/smartpicasso/app/user_profile/migrations/0001_initial.py @@ -0,0 +1,30 @@ +# Generated by Django 3.1.3 on 2020-11-30 21:41 + +from django.db import migrations, models +import django.db.models.deletion +import uuid + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + ('user', '0002_auto_20201130_2119'), + ] + + operations = [ + migrations.CreateModel( + name='UserProfile', + fields=[ + ('id', models.UUIDField(default=uuid.uuid4, editable=False, primary_key=True, serialize=False)), + ('first_name', models.CharField(max_length=50)), + ('last_name', models.CharField(max_length=50)), + ('phone_number', models.CharField(blank=True, max_length=10, null=True)), + ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, related_name='profile', to='user.user')), + ], + options={ + 'db_table': 'user_profile', + }, + ), + ] diff --git a/rest-app/smartpicasso/app/user_profile/migrations/__init__.py b/rest-app/smartpicasso/app/user_profile/migrations/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/rest-app/smartpicasso/app/user_profile/migrations/__pycache__/0001_initial.cpython-38.pyc b/rest-app/smartpicasso/app/user_profile/migrations/__pycache__/0001_initial.cpython-38.pyc new file mode 100644 index 0000000000000000000000000000000000000000..ea880556af41be5e29f6547ce59510327ff88a26 GIT binary patch literal 1055 zcmY*Y$&S=W5Ot>QvRzAWY#L5n=1_+zR}~0pq!9u&i#V`IO<#OTWpzYVr`sE8TbklJ zoRIoM_yc}`pU5kx{sJU8G?C?EXwu4XzK9G*yom7eXw-LT`K!<3lj}HNEV#Nn0uO1| z_ep>QEOT;}u$(8HSB@Bn+H{14~@sE0%cZr#%}5gEYh_?Sl`DcJJIALHyJX)X%@9ZFP8y`U=^pID9_(Ao%7+8ErWjm5cPZvR+#nV= zP4wbt`frGg*Vd@bt?6_+7qV?iF`v$-v)SFLn9pW^o53-eU+Z$IGBjMl)3Ij)z@==n z#)Jr}kqfd6Dy?#<*WwJ5ur&8dkpxwV>M zby^lEiZ)-MzOdaKyT)H+vN+Sbgp60TS*Cq^45}`ncacqgVg+4}%0f^tut77_n8^lV z6WH*kG$AZRm+H`77uzq8n`e_Vy`{noY7>;zrm-)_2PPC7e<4g?2 zy$A)WPz{kaL%<3Pz~V$_^FLVb#E0I-^zO?Iy{xS z(~n*i_@*S$!5*ZtSe1suf;d=qG zUZ2IS%;Oq!tQ$R#>$QrHs8`Kvbt3D!j5X>1l2sMgR$FbgR&ljb@voteX;@}rOMFtT zwf(z7+VvfK;GWAbJ>O%T-()-V9I)HpdB`1p$-jD+o7>~SL>;pUEH>5Z3iQYS%1QTQ lO@4CLWBRuK(+V5z7uW6-lg@