-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Showing
12 changed files
with
281 additions
and
184 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,40 +1,106 @@ | ||
<h1>Cart</h1> | ||
<div class="flex flex-col w-full py-8 px-4 md:py-16 md:px-8 text-gray-800 md:w-full md:ml-64"> | ||
<h1 class="text-2xl lg:text-4xl font-bold">Buy Stock</h1> | ||
<div> | ||
<table class="w-full text-sm lg:text-base border-4 " cellspacing="0"> | ||
<thead> | ||
<tr class="h-12 uppercase"> | ||
<th class="text-left">Product</th> | ||
<th class="lg:text-right text-left pl-5 lg:pl-0"> | ||
<span class="lg:hidden" title="Quantity">Qtd</span> | ||
<span class="hidden lg:inline">Quantity</span> | ||
</th> | ||
<th class="hidden text-right md:table-cell">Unit price</th> | ||
<th class="text-right">Total price</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
<tr class="bg-gray-600 border-b-2 text-white"> | ||
<td> | ||
<a href="#"> | ||
<p class="mb-2 md:ml-4">Earphone</p> | ||
<form action="" method="POST"> | ||
<button type="submit" class="md:ml-4"> | ||
<small>(Remove item)</small> | ||
</button> | ||
</form> | ||
</a> | ||
</td> | ||
<td class="justify-center md:justify-end md:flex mt-2"> | ||
<div class="w-20 h-10"> | ||
<div class="relative flex flex-row w-full h-8"> | ||
<input type="number" value="1" | ||
class="w-full font-semibold text-center text-gray-700 bg-gray-200 outline-none focus:outline-none hover:text-black focus:text-black" /> | ||
</div> | ||
</div> | ||
</td> | ||
<td class="hidden text-right md:table-cell"> | ||
<span class="text-sm lg:text-base font-medium"> | ||
10.00€ | ||
</span> | ||
</td> | ||
<td class="text-right"> | ||
<span class="text-sm lg:text-base font-medium pr-1"> | ||
20.00€ | ||
</span> | ||
</td> | ||
</tr> | ||
<tr class="bg-gray-600 border-b-2 text-white"> | ||
<td> | ||
<p class="mb-2 md:ml-4">Tesla Model 3</p> | ||
<form action="" method="POST"> | ||
<button type="submit" class="700 md:ml-4"> | ||
<small>(Remove item)</small> | ||
</button> | ||
</form> | ||
</td> | ||
<td class="justify-center md:justify-end md:flex md:mt-4"> | ||
<div class="w-20 h-10"> | ||
<div class="relative flex flex-row w-full h-8"> | ||
<input type="number" value="1" | ||
class="w-full font-semibold text-center text-gray-700 bg-gray-200 outline-none focus:outline-none hover:text-black focus:text-black" /> | ||
</div> | ||
</div> | ||
</td> | ||
<td class="hidden text-right md:table-cell"> | ||
<span class="text-sm lg:text-base font-medium"> | ||
49,600.01€ | ||
</span> | ||
</td> | ||
<td class="text-right"> | ||
<span class="text-sm lg:text-base font-medium pr-1"> | ||
148,800.03€ | ||
</span> | ||
</td> | ||
</tr> | ||
<tr class="bg-gray-600 border-b-2 text-white"> | ||
<td> | ||
<p class="mb-2 md:ml-4">Bic 4 colour pen</p> | ||
<form action="" method="POST"> | ||
<button type="submit" class="md:ml-4"> | ||
<small>(Remove item)</small> | ||
</button> | ||
</form> | ||
</td> | ||
<td class="justify-center md:justify-end md:flex md:mt-4"> | ||
<div class="w-20 h-10"> | ||
<div class="relative flex flex-row w-full h-8"> | ||
<input type="number" value="1" | ||
class="w-full font-semibold text-center text-gray-700 bg-gray-200 outline-none focus:outline-none hover:text-black focus:text-black" /> | ||
</div> | ||
</div> | ||
|
||
<table> | ||
<thead> | ||
<tr> | ||
<th>Company Symbol</th> | ||
<th>Price</th> | ||
<th>No of Stock</th> | ||
<th>Buy</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
<form action="/cart/buy" method="POST"> | ||
<tr> | ||
<td> | ||
<input | ||
readonly | ||
type="text" | ||
name="companySymbol" | ||
id="companySymbol" | ||
value="<%= symbol %>" | ||
/> | ||
</td> | ||
<td> | ||
<input | ||
readonly | ||
type="Number" | ||
name="stockPrice" | ||
id="stockPrice" | ||
value="<%= price %>" | ||
/> | ||
</td> | ||
<td> | ||
<input type="Number" name="noOfStock" id="noOfStock" value="1" /> | ||
</td> | ||
<td><input type="submit" value="BUY" /></td> | ||
</tr> | ||
</form> | ||
</tbody> | ||
</table> | ||
</td> | ||
<td class="hidden text-right md:table-cell"> | ||
<span class="text-sm lg:text-base font-medium"> | ||
1.50€ | ||
</span> | ||
</td> | ||
<td class="text-right"> | ||
<span class="text-sm lg:text-base font-medium pr-1"> | ||
7.50€ | ||
</span> | ||
</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
<script src="https://cdn.jsdelivr.net/gh/alpinejs/[email protected]/dist/alpine.min.js" defer></script> | ||
<div @click.away="open = false" | ||
class="flex flex-col w-full md:w-64 text-gray-700 bg-white flex-shrink-0 md:h-screen md:z-50 md:fixed md:left-0 md:top-0" | ||
class="flex flex-col w-full md:w-56 lg:w-64 text-gray-700 bg-white flex-shrink-0 md:h-screen md:z-50 md:fixed md:left-0 md:top-0" | ||
x-data="{ open: false }"> | ||
<div class="flex-shrink-0 px-6 py-4 flex flex-row items-center justify-between"> | ||
<h1 class="font-bold uppercase border-b border-gray-100 w-full text-center"> | ||
<a href="/" class="hover:text-gray-900 tracking-widest text-2xl md:text-3xl pb-2 pt-32">Tradebyte</a> | ||
<a href="/" class="hover:text-gray-900 tracking-widest text-2xl md:text-2xl lg:text-3xl pb-2 pt-32">Tradebyte</a> | ||
</h1> | ||
<button class="rounded-lg md:hidden rounded-lg focus:outline-none focus:shadow-outline" @click="open = !open"> | ||
<svg fill="currentColor" viewBox="0 0 20 20" class="w-6 h-6"> | ||
|
@@ -19,10 +19,10 @@ | |
</div> | ||
<nav :class="{'block': open, 'hidden': !open}" class="flex-grow md:block px-4 pb-4 md:pb-0"> | ||
<div class="flex justify-center align-center rounded-full"> | ||
<img class="mx-20 h-20 w-20 border-8 border-blue-600 box-1 rounded-full" src="images/profile.jpg" alt=" " /> | ||
<img class="h-20 w-20 border-8 border-blue-600 box-1 rounded-full" src="<%= avatar %>" alt="" /> | ||
</div> | ||
<a class="block w-2/4 max-w-xs md:w-3/5 p-2 mt-4 mb-8 mx-auto text-xs font-bold text-gray-900 focus:shadow-outline flex justify-center bg-green-200 rounded-full text-green-900 font-bold" | ||
href="#"><svg class="w-5 mr-1" fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" | ||
<a class="block w-2/5 md:w-4/5 max-w-xs lg:w-3/5 p-2 mt-4 mb-8 mx-auto text-xs font-bold text-gray-900 focus:shadow-outline flex justify-center bg-green-200 rounded-full text-green-900 font-bold" | ||
href="#"><svg class="w-5 mr-1 " fill="none" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" | ||
viewBox="0 0 24 24" stroke="currentColor"> | ||
<path d="M5 13l4 4L19 7"></path> | ||
</svg>Trading Active</a> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.