Giter VIP home page Giter VIP logo

Comments (5)

Omranic avatar Omranic commented on May 26, 2024

Would you give me a real scenario where you need to modify the core migrations please, since I can see it possible to always migrate the core migrations first, and then alter tables the way you want from within your application migrations..

from laravel-attributes.

psychonetic avatar psychonetic commented on May 26, 2024

I have some additional fields for the attributes table, so the user can create via frontend a new attribute and like Magento, the user can decide how to validate the field, if the field should be unique. This is just an example, but I think there are also other scenarios.

Yes, that would be also a way to go, but in my opinion it's more intuitiv to publish the migrations and edit them after.

But as I said, I just wanted to discuss this solution. I don't know what others may think, but I just know other packages do it in that fashion.

from laravel-attributes.

Omranic avatar Omranic commented on May 26, 2024

I still believe the current package architecture is good, and there's nothing limits you from doing so. Your scenario is actually a real case we had, and we already implemented such interface as a solution for users to create attributes and attach it to other entities, and we can't see any limitation even whenever we need to alter database structure. We like to separate architecture layers which in my own opinion is better for separation of concerns and layer isolation, without losing flexibility. You can check that interface package here: rinvex/cortex-attributes in case you're interested in trying it.. 😉 As always, use the dev-develop branch for all untagged packages! ⚠️

from laravel-attributes.

psychonetic avatar psychonetic commented on May 26, 2024

Okay fine :) Are you interested in a new datatype (decimal)? I would create a pull request in the next days/weeks.

But thank you for your time! I'll take a look at it.

from laravel-attributes.

Omranic avatar Omranic commented on May 26, 2024

Yeah sure, please go ahead and add that new data type. PRs are always welcome 🙏

from laravel-attributes.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.