batchnz / craft-commerce-untitled

A Craft Commerce plugin for minting variants based on field values
MIT License
0 stars 1 forks source link

Normalize variant values on generation #9

Open moacode opened 3 years ago

moacode commented 3 years ago

We need to ensure the variant generation method matches how Craft Commerce create their variants, namely normalizing the various values such as price, weight, stock etc.

We can use Craft Commerce's normalization methods for this.

moacode commented 3 years ago

Estimate: 30mins to an hour.

moacode commented 3 years ago

@judereid checkout this helper method that uses a localization helper to normalize values