From 74a9229ffac91827b961a352344b96ccdde34047 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Dere=C5=BEi=C4=8D?= Date: Sat, 14 Dec 2024 09:01:09 +0100 Subject: [PATCH 1/6] link ikona zamijenjena sa share ikonom --- app/ui/LocationCard.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/ui/LocationCard.tsx b/app/ui/LocationCard.tsx index 62647db..6b388f1 100644 --- a/app/ui/LocationCard.tsx +++ b/app/ui/LocationCard.tsx @@ -1,6 +1,6 @@ 'use client'; -import { Cog8ToothIcon, PlusCircleIcon, LinkIcon } from "@heroicons/react/24/outline"; +import { Cog8ToothIcon, PlusCircleIcon, ShareIcon } from "@heroicons/react/24/outline"; import { FC } from "react"; import { BillBadge } from "./BillBadge"; import { BillingLocation } from "../lib/db-types"; @@ -54,7 +54,7 @@ export const LocationCard:FC = ({location: { _id, name, yearM : null } - + ); }; \ No newline at end of file From 40e421a32af8761c1ddf61f4c67331926557d2d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Dere=C5=BEi=C4=8D?= Date: Sat, 14 Dec 2024 09:04:15 +0100 Subject: [PATCH 2/6] =?UTF-8?q?pode=C5=A1en=20styling=20ikone?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/ui/LocationCard.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/ui/LocationCard.tsx b/app/ui/LocationCard.tsx index 6b388f1..98a32d9 100644 --- a/app/ui/LocationCard.tsx +++ b/app/ui/LocationCard.tsx @@ -54,7 +54,7 @@ export const LocationCard:FC = ({location: { _id, name, yearM : null } - + ); }; \ No newline at end of file From 9c9ddc28c1bd60eedf1e047295ea79ab5a088639 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Dere=C5=BEi=C4=8D?= Date: Sat, 14 Dec 2024 09:12:03 +0100 Subject: [PATCH 3/6] =?UTF-8?q?pove=C4=87avanje=20UI=20elemenata=20na=20vi?= =?UTF-8?q?ew=20ekranu?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/ui/ViewBillBadge.tsx | 2 +- app/ui/ViewLocationCard.tsx | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/ui/ViewBillBadge.tsx b/app/ui/ViewBillBadge.tsx index d0ae494..672a96b 100644 --- a/app/ui/ViewBillBadge.tsx +++ b/app/ui/ViewBillBadge.tsx @@ -14,7 +14,7 @@ export const ViewBillBadge: FC = ({ locationId, bill: { _id: const currentLocale = useLocale(); return ( - + {name} ); diff --git a/app/ui/ViewLocationCard.tsx b/app/ui/ViewLocationCard.tsx index d6e9135..292b533 100644 --- a/app/ui/ViewLocationCard.tsx +++ b/app/ui/ViewLocationCard.tsx @@ -21,7 +21,7 @@ export const ViewLocationCard:FC = ({location: { _id, nam return(
-

{formatYearMonth(yearMonth)} {name}

+

{formatYearMonth(yearMonth)} {name}

{ bills.map(bill => ) @@ -29,7 +29,7 @@ export const ViewLocationCard:FC = ({location: { _id, nam
{ monthlyExpense > 0 ? -

+

{ t("payed-total-label") } ${formatCurrency(monthlyExpense)}

: null From 37ab7a15cbd1e675816ad93a016213ddc8e3c4cd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Dere=C5=BEi=C4=8D?= Date: Sat, 14 Dec 2024 09:55:26 +0100 Subject: [PATCH 4/6] =?UTF-8?q?monogo=20verzija=20u=20dev=20okru=C5=BEenju?= =?UTF-8?q?=20uskla=C4=91ena=20sa=20prod=20env?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docker-compose-debug.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker-compose-debug.yml b/docker-compose-debug.yml index 7da0a5c..8d981ee 100644 --- a/docker-compose-debug.yml +++ b/docker-compose-debug.yml @@ -3,7 +3,7 @@ version: "3.7" services: mongo: - image: mongo:6.0.12 + image: mongo:4.4.27 restart: always ports: - 27017:27017 From 4a7f8991038b4052c3ccc1c22dec13a98dedb264 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Dere=C5=BEi=C4=8D?= Date: Sat, 14 Dec 2024 09:56:14 +0100 Subject: [PATCH 5/6] =?UTF-8?q?za=20potrebe=20testiranja=20pode=C5=A1en=20?= =?UTF-8?q?konkretan=20userID?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/lib/auth.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/lib/auth.ts b/app/lib/auth.ts index 57657a7..55a1f39 100644 --- a/app/lib/auth.ts +++ b/app/lib/auth.ts @@ -8,16 +8,16 @@ import { defaultLocale } from '../i18n'; export const myAuth = () => { // Ovo koristim u developmentu - // + // const session:Session = { // user: { - // id: "123", - // name: "Test User", + // id: "109754742613069927799", + // name: "Nikola Derežić", // }, // expires: "123", // }; - // - // return(Promise.resolve(session)); + + return(Promise.resolve(session)); return(auth()); } From 86b6c777c4471e3dc696830009e6898a503fba8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Dere=C5=BEi=C4=8D?= Date: Sat, 14 Dec 2024 09:56:50 +0100 Subject: [PATCH 6/6] =?UTF-8?q?opzimizacija:=20stranica=20za=20prikaz=20go?= =?UTF-8?q?dine=20je=20dohva=C4=87ala=20i=20QR=20kodove=20=3D=20slow?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/lib/actions/locationActions.ts | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/app/lib/actions/locationActions.ts b/app/lib/actions/locationActions.ts index fcf9439..86b5799 100644 --- a/app/lib/actions/locationActions.ts +++ b/app/lib/actions/locationActions.ts @@ -117,8 +117,22 @@ export const fetchAllLocations = withUser(async (user:AuthenticatedUser, year:nu }, { projection: { - // don't include the attachment binary data in the response - "bills.attachment.fileContentsBase64": 0 + "_id": 1, + // "userId": 0, + // "userEmail": 0, + "name": 1, + // "notes": 0, + // "yearMonth": 1, + "yearMonth.year": 1, + "yearMonth.month": 1, + // "bills": 1, + "bills._id": 1, + "bills.name": 1, + "bills.paid": 1, + "bills.payedAmount": 1, + // "bills.attachment": 0, + // "bills.notes": 0, + // "bills.barcodeImage": 1, }, } )