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

More than one customizable product on a page causes issues. #11

Open
masonjeffreys opened this issue Apr 6, 2018 · 5 comments
Open

Comments

@masonjeffreys
Copy link
Contributor

Showing more than one customizable product at a time causes issues like:

  • Scrolling over one variant changes all pictures
  • Price calculations for one product affect all products

The javascript involved on the frontend of the gem should be reworked to be scoped to a single product, rather than the entire dom.

Happy to work on this. Perhaps some direction could be provided.
Thanks,
Jeff

@masonjeffreys
Copy link
Contributor Author

masonjeffreys commented May 14, 2018

@acreilly @dhonig If you're okay with this direction, I will take a first pass at it. I'll try hard to keep it backwards compatible. This would be for customizable options only at this point.

@acreilly
Copy link
Contributor

That would be great. Ping me when you have a PR. Thanks!

@masonjeffreys
Copy link
Contributor Author

@acreilly Took the first steps and issued a PR. This doesn't get us all the way to allowing multiple products on one page, but it starts us off.

I'd also like to move the front end calculator JS into the asset pipeline, but that's a bigger departure from current status quo. What do you think?

@masonjeffreys
Copy link
Contributor Author

Sorry to overload the comments. But maybe it would be helpful to list the areas I'd like to help in, and see if they align with your vision:

  • Frontend JS for calculators moved asset pipeline
  • Validation of data types at the database level (According to some migrations, it looks like this may have been tried before?)
  • More robust convention for naming customization groups, field ids, etc (i.e. jquery should find user inputs based on customization_type name and customizable_option name instead)

@masonjeffreys
Copy link
Contributor Author

@acreilly @dhonig Any thoughts on my last PR or the bullet points in the comment above? Happy to do more work, just want to make sure it aligns with your vision. Thanks!

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

No branches or pull requests

2 participants