Participate in our anonymous Starting Web App Research 2025 & Get 25 Credits🔥 It only takes 3 minutes!🚀

Unable to set up the code

We are unable to set up the code login is not working Something went wrong RepositoryNotFoundError: No repository for "Users" was found. Looks like this entity is not registered in current "default" connection? this error comes

Hi, could you please clarify which steps you made for setup? Please take a look at readme.md we have instructions on how to set up project locally, follow each step carefully. Also attach to your next reply versions of your Node.js and Yarn (do you use yarn or npm? we suggest yarn)

for backened :

psql --u postgres

if you see error please create new user with command -> createuser postgres -s (s flag stands for super)

3) now you are logged in under postgres super user, run create database bookkeeper_seed; 4) run this command npm run migrate:run Please add all required variables to your .env file, here is an example below
npm install npm start

https://drive.google.com/file/d/1ys-c75VQAcGuopxF6_GS_Izd0RJ5bhkd/view?usp=sharing when try to login via web portal

still your migration file not working https://tinyurl.com/yzubq7xx bookkeeperpublic_migrations.sql I am using the sql file

It looks like you are not able to perform migration, please try to use this command "\i 'fullpath/to/migration/file'" run this command from bookkeeperseed db, \c bookkeeperseed. This should help

can you please share it with example

https://drive.google.com/file/d/1jK_sK2rPAtoLgoKVpsaRxmvK7FA-Rblr/view?usp=sharing

enter the psql command line \c bookkeeper_seed; \i 'path/to/your/migration/file';

https://drive.google.com/file/d/1uVgANLBB3vNs2GT4xuTFnWXQ_zViD0um/view?usp=sharing https://drive.google.com/file/d/1QmRIbb9VmHvTV_IX8rUPKhBks1QPgMPV/view?usp=sharing

I have used your cammand but causing issues see the above screenshot psql:/home/mss/Downloads/bookkeeper-backend-/flatlogic-bookkeeper-backend-3af9345fc746b9dfc0dec86478984c44d79ac6d0/bookkeeperpublicmigrations.sql:38: ERROR: relation "companies" does not exist psql:/home/mss/Downloads/bookkeeper-backend-/flatlogic-bookkeeper-backend-3af9345fc746b9dfc0dec86478984c44d79ac6d0/bookkeeperpublicmigrations.sql:41: ERROR: relation "accounts" does not exist psql:/home/mss/Downloads/bookkeeper-backend-/flatlogic-bookkeeper-backend-3af9345fc746b9dfc0dec86478984c44d79ac6d0/bookkeeper_publicmigrations.sql:43: ERROR: relation "public.accounts" does not exist LINE 1: INSERT INTO public.accounts (id, code, status, fiscal_year, ...

can you quickly please check via anydesk or skype

I would suggest creating all table by hand and then import again. make sure you entered correct db

only tables not feilds

How I come to know the foreign keys if possible please share the correct db this manual work takes time of mine

don't create fields, create only table it should be 10-12 tables, and after that run import

ok

https://drive.google.com/file/d/164UXKxCMuOh-iUMf0k7x18j3BMZ1TVBN/view?usp=sharing still same issue I have followed your procedure not works https://drive.google.com/file/d/11YnR0YLZf_nSZQcq4b_-40xfCocq7zcj/view?usp=sharing

Something went wrong RepositoryNotFoundError: No repository for "Users" was found. Looks like this entity is not registered in current "default" connection? when hitting login api

Our client is waiting for your response its very urgent please help us

You don't need _migrations table, delete it

ok

Something went wrong RepositoryNotFoundError: No repository for "Users" was found. Looks like this entity is not registered in current "default" connection? what about this error

I haven't encountered such error previously, please make sure that you setted up .env file correctly (you can attach its content here) and also ormconfig.js

ok

let options;

if (process.env.NODEENV === 'production') { options = { "type": "postgres", "url": process.env.DATABASEURL, "synchronize": true, "logging": true, "migrationsTableName": "migrations", "entities": [ "src/entities//*.ts" ], "ssl": true, "extra": { "ssl": { "rejectUnauthorized": false } }, "migrations": [ "src/migrations//.ts" ], "subscribers": [ "src/subscriber//.ts" ], "cli": { "migrationsDir": "src/migrations" } } } else { options = { "type": "postgres", "host": "", "port": 5432, "username": "", "password": "", "database": "fifthlabour", "synchronize": true, "logging": true, "migrationsTableName": "_migrations", "entities": [ "src/entities//*.ts" ], "migrations": [ "src/migrations//.ts" ], "subscribers": [ "src/subscriber//.ts" ], "cli": { "migrationsDir": "src/migrations" } } }

module.exports = options;

NODEENV=development SERVERPORT=8083 PORT=3001

Postgres configuration

PGHOST= PGUSER= PGDATABASE=fifth_labour PGPASSWORD= PGPORT=5432

SECRET=asd2f3rgfa2r2514421 UIBASEURL=http://localhost:3000 UISETPASSWORD_URL=/user/set

i have just emptied the password and host

Are you setting up project locally or on the server? I would highly recommend you to initially set up project with default values for the postgres

PGHOST=localhost PGUSER=postgres PGDATABASE= bookkeeper_seed PGPORT=5432

ok

Could you please answer this question -> Are you setting up project locally or on the server?

parveensachdeva

its local

parveensachdeva

Please get it solved asap. we cannot spend one more day just to setup it. your responses are not prompt. Its just basic things. Its seems your script is buggy or readme doesnt coniats correct commands or flow.

parveensachdeva

with manul inporting db created correct now however while trying to login its crashing as mentioned above

Hi what error you get right now? You receive error from backend or frontend? please attach screenshot or text, thanks

Add this variable to the frontend folder > .env file REACTAPPAPI_ENDPOINT=http://localhost:8083/api

Every word should be separated by underscore REACT_APP_API_ENDPOINT=http://localhost:8083/api

parveensachdeva

Its not fontend issue we have already set this path the issue is with nbackend in ormconfigjs you have mentioned the entity path but it doesnot exists

"entities": [ "src/entities/*/.ts" ],

parveensachdeva

vladyslav, please get us touch with more technical person. We cannot spend one more day for this. Our work is suffering.

parveensachdeva

https://drive.google.com/file/d/1uW7vAf3tcNlUOOJ7IofFdhUNcAgusp5T/view?usp=sharing I am unbale to use users model

What version of node do you use? Are you sure you setted up db correctly?

parveensachdeva

yes node version :v14.15.3

Please try node v12.9.1

parveensachdeva

Why your team doest connect luve with us. Its waisitng a lot of time of us. I have 30 mins more otherwise I need it refund.

parveensachdeva

Is there any postgres version ?

postgres (PostgreSQL) 13.2

parveensachdeva

https://drive.google.com/file/d/1lBHfwZ03V7Bmvr4xpPXbRGuBFHZzAIc3/view?usp=sharing

Why you trying to use migration revert? You already have database setted up correctly as you have mentioned earlier

parveensachdeva

I am not using it I have just run: npm run dev then that issue comes

what about the default connection issue

I see in the error logs that previous command was migration revert that's why i'm curious. Haven't encountered default connection issue error, please research it

parveensachdeva

https://drive.google.com/file/d/1bPN6OEJ7oCw2QOeeidp0znLIY6CcgjvH/view?usp=sharing

dont have access

Hi, could you please clarify your status? Did you manage to get bookkeeper template working on your machine?

Solved