arshtech commited on
Commit
7472f96
·
verified ·
1 Parent(s): 8f8da43

Update templates/index.html

Browse files
Files changed (1) hide show
  1. templates/index.html +5 -105
templates/index.html CHANGED
@@ -4,8 +4,8 @@
4
  <!-- Hero Section -->
5
  <section class="bg-gradient-to-r from-blue-500 to-purple-600 text-white py-20 mb-12 rounded-lg">
6
  <div class="container mx-auto text-center">
7
- <h1 class="text-5xl font-bold mb-4">Find Your Dream Car in India</h1>
8
- <p class="text-xl mb-8">Browse through our extensive collection of quality vehicles at the best prices</p>
9
  {% if session.get('user_id') and session.get('role') == 'buyer' %}
10
  <a href="#cars" class="bg-white text-blue-600 px-8 py-3 rounded-full font-semibold hover:bg-gray-100 transition duration-300">
11
  Browse Cars
@@ -29,16 +29,16 @@
29
  <div class="p-6">
30
  <h3 class="text-xl font-bold mb-2">{{ car.name }}</h3>
31
  <p class="text-gray-600 mb-2">Year: {{ car.year }}</p>
32
- <p class="text-2xl font-bold text-green-600 mb-4">{{ car.price|format_price }}</p>
33
  <p class="text-gray-700 mb-4">{{ car.description }}</p>
34
 
35
  {% if session.get('user_id') and session.get('role') == 'buyer' %}
36
  <a href="{{ url_for('book_appointment', car_id=car._id) }}"
37
  class="bg-blue-600 text-white px-6 py-2 rounded-full hover:bg-blue-700 transition duration-300 block text-center">
38
- Book Test Drive
39
  </a>
40
  {% elif not session.get('user_id') %}
41
- <p class="text-red-500 text-center">Please login as buyer to book test drive</p>
42
  {% endif %}
43
  </div>
44
  </div>
@@ -50,104 +50,4 @@
50
  </div>
51
  {% endif %}
52
  </section>
53
-
54
- <!-- Features Section -->
55
- <section class="bg-white py-12 rounded-lg shadow-lg">
56
- <div class="container mx-auto text-center">
57
- <h2 class="text-3xl font-bold mb-8">Why Choose Carwala?</h2>
58
- <div class="grid grid-cols-1 md:grid-cols-3 gap-8">
59
- <div class="p-6">
60
- <i class="fas fa-shield-alt text-4xl text-blue-600 mb-4"></i>
61
- <h3 class="text-xl font-bold mb-2">Verified Sellers</h3>
62
- <p class="text-gray-600">All our sellers are verified and trusted</p>
63
- </div>
64
- <div class="p-6">
65
- <i class="fas fa-rupee-sign text-4xl text-green-600 mb-4"></i>
66
- <h3 class="text-xl font-bold mb-2">Best Prices</h3>
67
- <p class="text-gray-600">Get the best deals on quality cars</p>
68
- </div>
69
- <div class="p-6">
70
- <i class="fas fa-headset text-4xl text-purple-600 mb-4"></i>
71
- <h3 class="text-xl font-bold mb-2">24/7 Support</h3>
72
- <p class="text-gray-600">We're here to help you anytime</p>
73
- </div>
74
- </div>
75
- </div>
76
- </section>
77
- {% endblock %}{% extends "base.html" %}
78
-
79
- {% block content %}
80
- <!-- Hero Section -->
81
- <section class="bg-gradient-to-r from-blue-500 to-purple-600 text-white py-20 mb-12 rounded-lg">
82
- <div class="container mx-auto text-center">
83
- <h1 class="text-5xl font-bold mb-4">Find Your Dream Car in India</h1>
84
- <p class="text-xl mb-8">Browse through our extensive collection of quality vehicles at the best prices</p>
85
- {% if session.get('user_id') and session.get('role') == 'buyer' %}
86
- <a href="#cars" class="bg-white text-blue-600 px-8 py-3 rounded-full font-semibold hover:bg-gray-100 transition duration-300">
87
- Browse Cars
88
- </a>
89
- {% else %}
90
- <a href="{{ url_for('register') }}" class="bg-white text-blue-600 px-8 py-3 rounded-full font-semibold hover:bg-gray-100 transition duration-300">
91
- Get Started
92
- </a>
93
- {% endif %}
94
- </div>
95
- </section>
96
-
97
- <!-- Cars Section -->
98
- <section id="cars" class="mb-12">
99
- <h2 class="text-3xl font-bold text-center mb-8">Available Cars</h2>
100
-
101
- {% if cars %}
102
- <div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
103
- {% for car in cars %}
104
- <div class="bg-white rounded-lg shadow-lg overflow-hidden hover:shadow-xl transition duration-300">
105
- <div class="p-6">
106
- <h3 class="text-xl font-bold mb-2">{{ car.name }}</h3>
107
- <p class="text-gray-600 mb-2">Year: {{ car.year }}</p>
108
- <p class="text-2xl font-bold text-green-600 mb-4">{{ car.price|format_price }}</p>
109
- <p class="text-gray-700 mb-4">{{ car.description }}</p>
110
-
111
- {% if session.get('user_id') and session.get('role') == 'buyer' %}
112
- <a href="{{ url_for('book_appointment', car_id=car._id) }}"
113
- class="bg-blue-600 text-white px-6 py-2 rounded-full hover:bg-blue-700 transition duration-300 block text-center">
114
- Book Test Drive
115
- </a>
116
- {% elif not session.get('user_id') %}
117
- <p class="text-red-500 text-center">Please login as buyer to book test drive</p>
118
- {% endif %}
119
- </div>
120
- </div>
121
- {% endfor %}
122
- </div>
123
- {% else %}
124
- <div class="text-center py-12">
125
- <p class="text-xl text-gray-600">No cars available at the moment. Check back later!</p>
126
- </div>
127
- {% endif %}
128
- </section>
129
-
130
- <!-- Features Section -->
131
- <section class="bg-white py-12 rounded-lg shadow-lg">
132
- <div class="container mx-auto text-center">
133
- <h2 class="text-3xl font-bold mb-8">Why Choose Carwala?</h2>
134
- <div class="grid grid-cols-1 md:grid-cols-3 gap-8">
135
- <div class="p-6">
136
- <i class="fas fa-shield-alt text-4xl text-blue-600 mb-4"></i>
137
- <h3 class="text-xl font-bold mb-2">Verified Sellers</h3>
138
- <p class="text-gray-600">All our sellers are verified and trusted</p>
139
- </div>
140
- <div class="p-6">
141
- <i class="fas fa-rupee-sign text-4xl text-green-600 mb-4"></i>
142
- <h3 class="text-xl font-bold mb-2">Best Prices</h3>
143
- <p class="text-gray-600">Get the best deals on quality cars</p>
144
- </div>
145
- <div class="p-6">
146
- <i class="fas fa-headset text-4xl text-purple-600 mb-4"></i>
147
- <h3 class="text-xl font-bold mb-2">24/7 Support</h3>
148
- <p class="text-gray-600">We're here to help you anytime</p>
149
- </div>
150
- </div>
151
- </div>
152
- </section>
153
  {% endblock %}
 
4
  <!-- Hero Section -->
5
  <section class="bg-gradient-to-r from-blue-500 to-purple-600 text-white py-20 mb-12 rounded-lg">
6
  <div class="container mx-auto text-center">
7
+ <h1 class="text-5xl font-bold mb-4">Find Your Dream Car</h1>
8
+ <p class="text-xl mb-8">Browse through our extensive collection of quality vehicles</p>
9
  {% if session.get('user_id') and session.get('role') == 'buyer' %}
10
  <a href="#cars" class="bg-white text-blue-600 px-8 py-3 rounded-full font-semibold hover:bg-gray-100 transition duration-300">
11
  Browse Cars
 
29
  <div class="p-6">
30
  <h3 class="text-xl font-bold mb-2">{{ car.name }}</h3>
31
  <p class="text-gray-600 mb-2">Year: {{ car.year }}</p>
32
+ <p class="text-2xl font-bold text-blue-600 mb-4">${{ car.price }}</p>
33
  <p class="text-gray-700 mb-4">{{ car.description }}</p>
34
 
35
  {% if session.get('user_id') and session.get('role') == 'buyer' %}
36
  <a href="{{ url_for('book_appointment', car_id=car._id) }}"
37
  class="bg-blue-600 text-white px-6 py-2 rounded-full hover:bg-blue-700 transition duration-300 block text-center">
38
+ Book Appointment
39
  </a>
40
  {% elif not session.get('user_id') %}
41
+ <p class="text-red-500 text-center">Please login as buyer to book appointment</p>
42
  {% endif %}
43
  </div>
44
  </div>
 
50
  </div>
51
  {% endif %}
52
  </section>
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
53
  {% endblock %}