amezenin / encyclopedia-kn

0 stars 0 forks source link

the first run of your project is not easy because it needs some predefined data and the code is needed to be red to understand the required data. #17

Open vahid-forghani opened 1 year ago

vahid-forghani commented 1 year ago

https://github.com/amezenin/encyclopedia-kn/blob/d8c6159568b556e048a823cd49be0563c1b78f0b/README.md?plain=1#L1

this is just something I wanted to mention which is not important for now. when I ran the project there was no user predefined in database so I used the signup button and created a new user but when I tried to create an article it was not possible because my user didn't have any role so I red your code and I found out. in a real life project there is a framework called liquibase in which you can provide some data for the first time and it is for database change logs (you might have heard about it) later you can use it to provide some roles and users so it would be easier to use the project. you can later provide those users information in readme file. but yeah this is not important for now and I just didn't want to forget to tell you.

amezenin commented 1 year ago

Yes, this is a helpful note. In this project, I used a test class to populate the database. Not the best way, but it was convenient for me to work with him. https://github.com/amezenin/encyclopedia-kn/blob/master/src/test/java/com/knits/product/repository/ModelTest.java