Se cambio del modulo de producto-inventario el $ por Bs.
This commit is contained in:
@@ -9,9 +9,9 @@ export const columns: ColumnDef<InventoryTable>[] = [
|
||||
accessorKey: 'urlImg',
|
||||
header: 'img',
|
||||
cell: ({ row }) => {
|
||||
return (
|
||||
<img src={`/uploads/inventory/${row.original.userId}/${row.original.id}/${row.original.urlImg}`} alt="" width={64} height={64} className="rounded"/>
|
||||
)
|
||||
return (
|
||||
<img src={`/uploads/inventory/${row.original.userId}/${row.original.id}/${row.original.urlImg}`} alt="" width={64} height={64} className="rounded" />
|
||||
)
|
||||
},
|
||||
},
|
||||
{
|
||||
@@ -27,7 +27,7 @@ export const columns: ColumnDef<InventoryTable>[] = [
|
||||
{
|
||||
accessorKey: 'price',
|
||||
header: 'Precio',
|
||||
cell: ({ row }) => `${row.original.price}$`
|
||||
cell: ({ row }) => `${row.original.price} Bs.`
|
||||
},
|
||||
{
|
||||
accessorKey: 'stock',
|
||||
|
||||
@@ -32,7 +32,7 @@ export function ProductCard({ product, onClick }: cardProps) {
|
||||
{product.status === 'AGOTADO' ? (
|
||||
<p className="font-semibold text-lg text-red-900">AGOTADO</p>
|
||||
) : ('')}
|
||||
<p className="font-semibold text-lg">$ {product.price}</p>
|
||||
<p className="font-semibold text-lg">{product.price} Bs.</p>
|
||||
</CardFooter>
|
||||
</Card>
|
||||
)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
'use client';
|
||||
import { useState } from "react";
|
||||
import { allProducts } from "../../schemas/inventory";
|
||||
import { allProducts } from "../../schemas/inventory";
|
||||
import {
|
||||
Card,
|
||||
CardContent,
|
||||
@@ -9,11 +9,11 @@ import {
|
||||
CardTitle,
|
||||
} from '@repo/shadcn/card';
|
||||
|
||||
export function ProductList({product}: {product: allProducts}) {
|
||||
export function ProductList({ product }: { product: allProducts }) {
|
||||
const [selectedImg, setSelectedImg] = useState(`/uploads/inventory/${product.userId}/${product.id}/${product.urlImg}`)
|
||||
console.log(product);
|
||||
|
||||
return (
|
||||
return (
|
||||
// <PageContainer>
|
||||
<main className='px-4 lg:px-6 flex flex-col md:flex-row gap-3 lg:gap-4 md:relative'>
|
||||
<div className='w-full flex justify-between flex-col'>
|
||||
@@ -31,15 +31,15 @@ return (
|
||||
</span>
|
||||
</span> */}
|
||||
{product.gallery?.map((img, index) => (
|
||||
<img
|
||||
key={index}
|
||||
className="cursor-pointer border-2 object-cover w-[64px] h-[64px] md:w-[96px] md:h-[96px] aspect-square rounded-2xl"
|
||||
src={`/uploads/inventory/${product.userId}/${product.id}/${img}`}
|
||||
alt=""
|
||||
onClick={() => setSelectedImg(`/uploads/inventory/${product.userId}/${product.id}/${img}`)}
|
||||
/>
|
||||
))}
|
||||
{/* <div className="sticky right-0 flex items-center">
|
||||
<img
|
||||
key={index}
|
||||
className="cursor-pointer border-2 object-cover w-[64px] h-[64px] md:w-[96px] md:h-[96px] aspect-square rounded-2xl"
|
||||
src={`/uploads/inventory/${product.userId}/${product.id}/${img}`}
|
||||
alt=""
|
||||
onClick={() => setSelectedImg(`/uploads/inventory/${product.userId}/${product.id}/${img}`)}
|
||||
/>
|
||||
))}
|
||||
{/* <div className="sticky right-0 flex items-center">
|
||||
<span className="text-xl p-3 cursor-pointer bg-neutral-800/50 rounded-full text-white">
|
||||
{">"}
|
||||
</span>
|
||||
@@ -53,7 +53,7 @@ return (
|
||||
<CardTitle className="font-bold text-2xl text-primary">
|
||||
{product.title.charAt(0).toUpperCase() + product.title.slice(1)}
|
||||
</CardTitle>
|
||||
<p className='font-semibold'>{product.price}$
|
||||
<p className='font-semibold'>{product.price} Bs.
|
||||
{product.status === 'AGOTADO' ? (
|
||||
<span className="font-semibold text-lg text-red-900"> AGOTADO</span>
|
||||
) : ('')}
|
||||
|
||||
Reference in New Issue
Block a user