Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#4 - #6 - #9 - #10 - kebab, sauce and filling crud, kebab data #14

Merged
merged 30 commits into from
Jan 15, 2025

Conversation

AleksandraKozubal
Copy link
Owner

@AleksandraKozubal AleksandraKozubal commented Dec 5, 2024

It should close #6, close #9, close #10.
In this pr I:

  • added admin CRUD for fillings, sauces and kebab places along with observers and enums
  • switched from seeders to one seeder and three factories (for models mentioned in this pr)
  • added KebabPlaceRequest with simple image storing (still needs to be handled properly)
  • updated KebabPlace Model (@Lee0z this is important for mobile retrieving api)
  • added kebab data

and provided some cosmetic changes

image

@AleksandraKozubal AleksandraKozubal changed the title #6 - admin panel kebab crud #6 - #9 - #10 - admin panel kebab crud Dec 5, 2024

This comment was marked as outdated.

@AleksandraKozubal AleksandraKozubal changed the title #6 - #9 - #10 - admin panel kebab crud #6 - #9 - #10 - kebab, sauce and filling crud Dec 5, 2024
@AleksandraKozubal AleksandraKozubal marked this pull request as ready for review January 7, 2025 19:39
@Lee0z
Copy link
Collaborator

Lee0z commented Jan 7, 2025

As far as I see there are changes that need attention on frontend, thus will be addressed in AleksandraKozubal/KULA-Mobile#4

Lee0z
Lee0z previously approved these changes Jan 9, 2025
{
public function execute(int $fillingId): void
{
Kebab::query()->whereJsonContains("fillings", $fillingId)->get()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Kebab? Shouldn't it be KebabPlace?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure, fixed

@AleksandraKozubal AleksandraKozubal changed the title #6 - #9 - #10 - kebab, sauce and filling crud #4 - #6 - #9 - #10 - kebab, sauce and filling crud, kebab data Jan 13, 2025
Copy link
Owner Author

@AleksandraKozubal AleksandraKozubal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I decided to merge branch with kebab data seeders here bc some errors were fixed there and I thought that's better way to do it now

To run real data seeders just run php artisan migrate:fresh --seed

Copy link
Collaborator

@Lee0z Lee0z left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Data is inconsistent:
example for social medias:

Sphinx { "id": 31, "name": "KEBAB Sphinx", "image": "kebab-place/sphinx-kebab.jpg", "address": "Najświętszej Marii Panny", "latitude": "51.209281018102246", "longitude": "16.16491389168841", "google_maps_url": null, "google_maps_rating": null, "phone": "574 179 918", "website": null, "android": null, "ios": null, "email": null, "opened_at_year": null, "closed_at_year": 2020, "opening_hours": [], "fillings": [], "sauces": [], "status": "zamknięte", "is_craft": false, "is_chain_restaurant": true, "location_type": "lokal", "order_options": [], "social_media": { "name": "fb", "url": "https://www.facebook.com/people/Kebab-Sphinx-Legnica/100064028922914/" }, "created_at": "2025-01-13T22:11:57.000000Z", "updated_at": "2025-01-13T22:11:57.000000Z" },

and other:

Empire { "id": 26, "name": "Kebab Empire", "image": "kebab-place/kebab-empire.jpg", "address": "Fabryczna 13", "latitude": "51.20677303064106", "longitude": "16.17869613057113", "google_maps_url": "https://maps.app.goo.gl/X7hFNX8eWv5KnMn1A", "google_maps_rating": null, "phone": "573 683 905", "website": null, "android": null, "ios": null, "email": "[email protected]", "opened_at_year": null, "closed_at_year": null, "opening_hours": [], "fillings": [ 3, 4, 5, 6 ], "sauces": [ 3, 5, 6, 7 ], "status": "zamknięte", "is_craft": false, "is_chain_restaurant": false, "location_type": "lokal", "order_options": [], "social_media": [ { "name": "fb", "url": "https://www.facebook.com/p/Kebab-Empire-Legnica-100086383969163/" } ], "created_at": "2025-01-13T22:11:57.000000Z", "updated_at": "2025-01-13T22:11:57.000000Z" },

other example:

Rulo { "id": 22, "name": "Rulo Kebab", "image": "kebab-place/rulo-kebab.jpg", "address": "Nowy Świat", "latitude": "51.205128470632545", "longitude": "16.1545378995454", "google_maps_url": "https://maps.app.goo.gl/QHozQGXuoWRrd7US7", "google_maps_rating": null, "phone": "669 721 401", "website": null, "android": null, "ios": null, "email": null, "opened_at_year": null, "closed_at_year": null, "opening_hours": [], "fillings": [], "sauces": [], "status": "zamknięte", "is_craft": false, "is_chain_restaurant": false, "location_type": "buda", "order_options": [], "social_media": [ { "fb": "https://www.facebook.com/RuloKebab/?locale=pl_PL" } ], "created_at": "2025-01-13T22:11:57.000000Z", "updated_at": "2025-01-13T22:11:57.000000Z" },

As far as I know we went for Map type of data:

            {
                "name": "fb",
                "url": "https://www.facebook.com/p/Kebab-Empire-Legnica-100086383969163/"
            }

Copy link
Collaborator

@zmigrOO zmigrOO left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also I think we should have Dodatki instead of Mięsa. It will look better with vegetarian fillings.

@AleksandraKozubal
Copy link
Owner Author

AleksandraKozubal commented Jan 14, 2025

As far as I know we went for Map type of data:

            {
                "name": "fb",
                "url": "https://www.facebook.com/p/Kebab-Empire-Legnica-100086383969163/"
            }

In this case we want to have json array, not single json, fixed sphinx

@AleksandraKozubal
Copy link
Owner Author

Also I think we should have Dodatki instead of Mięsa. It will look better with vegetarian fillings.

There is no right word for this category, imo Dodatki means all other ingredients. Switched to "Główne składniki" as a compromise word

@Lee0z
Copy link
Collaborator

Lee0z commented Jan 15, 2025

Also I think we should have Dodatki instead of Mięsa. It will look better with vegetarian fillings.

There is no right word for this category, imo Dodatki means all other ingredients. Switched to "Główne składniki" as a compromise word

"Główne składniki" is okayish, but in mobile app we have "Nadzienia" that could also fit our scenario. We could unify that.

Copy link
Collaborator

@Lee0z Lee0z left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Data is OK now, I may be worried about many null data occuring, but for mobile app it's fine.

@AleksandraKozubal AleksandraKozubal merged commit 572a18d into main Jan 15, 2025
2 checks passed
@AleksandraKozubal AleksandraKozubal deleted the #6-Admin-Panel-kebab-CRUD branch January 15, 2025 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Admin panel sauces CRUD Admin panel fillings CRUD Admin Panel kebab CRUD
3 participants