Closed captain-awesome closed 8 years ago
sorry but there is validations on this already. It's not letting me create empty ones?
@versastylist if this is still an issue feel free to re-open but not an issue for me, it throws all sorts of errors when you try to create invalid service products
This issue still persists.
To reproduce:
it's understood the service technically hasn't been added but this type of behavior should be prevent.
there is no easy way to make a validation for this because you can't validate the presence of service products in order to create a service since a service needs to be created first before a service product is created. It's a chicken and the egg scenario... we could give up the service product validations in exchange for just validating that the user is trying to add at least 1 service product but that seems like a less than ideal solution because there would be no point in a user ever creating a service without a service product...
Feel free to create a form object that does all the validation you want but I imagine its going to be very difficult with using cocoon and nested attributes.
stylist should not be able to create empty services with no product added