From a6552f1692c5a5a493187723a5e3590682fd3b00 Mon Sep 17 00:00:00 2001 From: Flatlogic Bot Date: Fri, 13 Mar 2026 00:43:16 +0000 Subject: [PATCH] version 1 --- core/__pycache__/models.cpython-311.pyc | Bin 1112 -> 2142 bytes core/migrations/0002_seller_product_seller.py | 32 ++++++++++++ ...0002_seller_product_seller.cpython-311.pyc | Bin 0 -> 1992 bytes core/models.py | 12 +++++ core/templates/base.html | 46 ++++++++++++------ core/templates/core/index.html | 43 +++++++++------- static/css/custom.css | 41 ++++++++++------ 7 files changed, 126 insertions(+), 48 deletions(-) create mode 100644 core/migrations/0002_seller_product_seller.py create mode 100644 core/migrations/__pycache__/0002_seller_product_seller.cpython-311.pyc diff --git a/core/__pycache__/models.cpython-311.pyc b/core/__pycache__/models.cpython-311.pyc index 1e2f5b2c662b46de2feb2b9befd792a42f94a75e..c474e7a6384562450471eee24b06d6a643e4fcb6 100644 GIT binary patch literal 2142 zcma)7PfXip6t@%SuN|me#@aE+%Ait&l#B^YXqpBclxam{lVCkWl`P}$0}PIxeRf(v zlNL=qAdLezcI=5!fhMH&(Bq_Cs+}Ckhsf8RxKY8Wr@dzxE zM2ChLYDldE5Z-aBLn9Yz^t{#(j?*0)y(IIPD_+%)u;0=!#Y|UC@!Vnro|;{Ycda(O<^`25^qAGYSht z)m-)tn0(5ye)wU12v}typfAoIK>hWnDdu-R@x}ZT;UxL2#}lU-;*>8=)n}XXt-XF< zzIC|h$>R-q+?U7e_nOM^-fdqQKJ4?9VnZqVO0hoQR7P=e^pJYWL_?YIl?hmsNAdXR z$%H3QHsncPo~++H6Zk~_jO&KTS@iP?ky5aLjJ%5~F7L(y{yk!K#@i!xCoLHdqGW6pQ&3yGkJz5tJCKhU)}9gz82` zGu5gI{BX82ZR4dvJjm3lrmYbbI8;DOq0Jo3-kz}x0|d?r=o(W%h^QJBBv$BlZ!54i z`LJH!Am5gkz7dwiLg6}l7xvfOSM_t%`dm{SK)MY)aXfLXA&&Xt7*MUns)jP+DX#( zAr)lEx@N7~MY0@a^}Uv?+m_3WixiRnR_e@Ch&?CBG=l<@4m$-g$x!ITDA-rzbS=lvT;`+tE IY=#N=2iLUr?EnA( delta 615 zcmca7aD#(yIWI340}ycfZO&|BoX98PX946*XGmd4Va#F3WsG8EWME=&XGmdcVMt+4 zWz1p%sRn^%%nS^xffxd!m{VAS88lg6g1DNDx7c#?Q&Mw^lP3y_G9H-B%OYK$!nlTM z86!{+5JNx|D-%O1a~2znzYNG&4dXCGv4dqfU;-&X8`iKc1KPhD?uIB%uo|!rKGRx?S0L51_6o~?{j^|x4kK~V!SLF!&dT4KUhDb5iY!RDlwph${A-e41U#`U49GqvQt$ SOrj&LC+8zb{0kOIu*m@3Cw<2N diff --git a/core/migrations/0002_seller_product_seller.py b/core/migrations/0002_seller_product_seller.py new file mode 100644 index 0000000..225a4a7 --- /dev/null +++ b/core/migrations/0002_seller_product_seller.py @@ -0,0 +1,32 @@ +# Generated by Django 5.2.7 on 2026-03-13 00:39 + +import django.db.models.deletion +from django.conf import settings +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('core', '0001_initial'), + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ] + + operations = [ + migrations.CreateModel( + name='Seller', + fields=[ + ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')), + ('store_name', models.CharField(max_length=200)), + ('description', models.TextField(blank=True)), + ('is_verified', models.BooleanField(default=False)), + ('created_at', models.DateTimeField(auto_now_add=True)), + ('user', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to=settings.AUTH_USER_MODEL)), + ], + ), + migrations.AddField( + model_name='product', + name='seller', + field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, related_name='products', to='core.seller'), + ), + ] diff --git a/core/migrations/__pycache__/0002_seller_product_seller.cpython-311.pyc b/core/migrations/__pycache__/0002_seller_product_seller.cpython-311.pyc new file mode 100644 index 0000000000000000000000000000000000000000..141cb1718a8bf7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2B)gW``C7alP$1L~iU#L?Wg#Z8m literal 0 HcmV?d00001 diff --git a/core/models.py b/core/models.py index c05de36..704a588 100644 --- a/core/models.py +++ b/core/models.py @@ -1,6 +1,18 @@ from django.db import models +from django.contrib.auth.models import User + +class Seller(models.Model): + user = models.OneToOneField(User, on_delete=models.CASCADE) + store_name = models.CharField(max_length=200) + description = models.TextField(blank=True) + is_verified = models.BooleanField(default=False) + created_at = models.DateTimeField(auto_now_add=True) + + def __str__(self): + return self.store_name class Product(models.Model): + seller = models.ForeignKey(Seller, on_delete=models.CASCADE, related_name='products', null=True, blank=True) name = models.CharField(max_length=200) description = models.TextField() price = models.DecimalField(max_digits=10, decimal_places=2) diff --git a/core/templates/base.html b/core/templates/base.html index 1e7e5fb..c11a550 100644 --- a/core/templates/base.html +++ b/core/templates/base.html @@ -1,25 +1,41 @@ - - {% block title %}Knowledge Base{% endblock %} - {% if project_description %} - - - - {% endif %} - {% if project_image_url %} - - - {% endif %} + + {% block title %}Ethio-Gebeya{% endblock %} {% load static %} + {% block head %}{% endblock %} + - - {% block content %}{% endblock %} + + +
+ {% block content %}{% endblock %} +
+ +
+
+

© 2026 Ethio-Gebeya. Professional Market Solutions.

+
+
+ + - - + \ No newline at end of file diff --git a/core/templates/core/index.html b/core/templates/core/index.html index a4cc4c1..aa0e20e 100644 --- a/core/templates/core/index.html +++ b/core/templates/core/index.html @@ -3,24 +3,31 @@ {% block title %}Ethio-Gebeya | Modern Marketplace{% endblock %} {% block content %} -
-

Welcome to Ethio-Gebeya

-

Your premium destination for quality goods.

-
- +
+
+

Welcome to Ethio-Gebeya

+

Discover the best quality goods in one place.

+ Start Shopping
-
- {% for product in products %} -
-

{{ product.name }}

-

{{ product.description|truncatewords:15 }}

-

ETB {{ product.price }}

- View Details → -
- {% empty %} -

No products available yet.

- {% endfor %} -
-{% endblock %} \ No newline at end of file +
+

Featured Products

+
+ {% for product in products %} +
+
+
+
{{ product.name }}
+

{{ product.description|truncatewords:15 }}

+

ETB {{ product.price }}

+ View Details +
+
+
+ {% empty %} +

No products available yet.

+ {% endfor %} +
+
+{% endblock %} diff --git a/static/css/custom.css b/static/css/custom.css index 020d029..5915260 100644 --- a/static/css/custom.css +++ b/static/css/custom.css @@ -16,33 +16,44 @@ body { margin: 0; } -h1, h2, h3, .brand { +h1, h2, h3, .navbar-brand { font-family: 'Manrope', sans-serif; + font-weight: 800; } .hero { background: linear-gradient(135deg, var(--secondary), var(--primary)); color: white; - padding: 80px 20px; + padding: 100px 20px; text-align: center; -} - -.product-grid { - display: grid; - grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); - gap: 2rem; - padding: 40px 20px; + border-bottom-left-radius: 40px; + border-bottom-right-radius: 40px; } .product-card { background: white; - border-radius: 12px; + border-radius: 16px; padding: 1.5rem; - box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1); - transition: transform 0.2s, box-shadow 0.2s; + box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05); + transition: transform 0.3s ease, box-shadow 0.3s ease; + border: none; } .product-card:hover { - transform: translateY(-5px); - box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1); -} \ No newline at end of file + transform: translateY(-8px); + box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1); +} + +.card-title { + font-family: 'Manrope', sans-serif; + font-size: 1.25rem; + color: var(--secondary); +} + +.btn-primary { + background-color: var(--accent); + border: none; + border-radius: 8px; + padding: 0.6rem 1.5rem; + font-weight: 600; +}