Open MSnoeren opened 5 years ago
Hi @msnoeren,
We're essentially discussing two features here:
metadata
: I like the idea of having metadata, because it can also be accessed by the preprocessors.
features
: would be essentially another feature, and very application specific. I don't think this should be a first class citizen as of yet. But if we go with the metadata
, you could nest the features there. (metadata => features => ...
)
@MSnoeren what do you think?
Looks fine to me. That way features can be added as well, but simply by adding them to the metadata.
FYI: Not sure yet I'll be including this in the v1 release. Not a must-have at this point.
Hi @sandervanhooft, big thanks for this package! When do you think the V1 will be available?
I can't wait to use this package in production.
@Jimmylet Please stay on topic; the answer you're looking for is here: https://github.com/laravel/cashier-mollie/issues/32.
It would also be nice to have metadata for each subscription and not connected to a predefined plan. So you could save a variable as "domainname" for example. Currently I am using the name of the subscription as foreign key to add more information to a subscription.
@pascallieverse Can you open a separate issue for this?
I've noticed there currently is no way to add settings or metadata to plans. For example, a plan allows for 5 users and 20 emails. Currently, I have to use an array-map to retrieve how many users the team can create. It would be easier to add this to the plan itself and get it from the plan object afterwards.
Consider the following:
Think of the metadata as specifying the pricing table. The metadata should then be able to be retrieved using the
Plan
object.. I know this can also be archieved by usingconfig('cashier_plans.plan')[<name of plan>]['metadata']
, but its a bit nicer this way. Thoughts?Edit: after thinking about it some more, features would be a better name for this as plans have features, not settings or metadata.