Skip to content

Extension points

phil/commerce-product-template

The library is plain PHP: it declares no service and no port. What an application chooses goes through arguments.

PointHow
The axesAny axes, up to 8: a size and a colour, a format and a paper, a version
The SKUAny pattern of literals and placeholders, {design} among them
The pricesA base, a price per value of one axis, supplements on any axis
The channelsThe channels each value is sold through, as the application's catalogue names them
The imagesPaths relative to the application's store of images: photos, swatches, artworks
The limit of a plannew VariantPlanner($maxVariants), at most VariantPlanner::MAX_VARIANTS
StorageTemplateArray and DesignArray, or the application's own mapping of the public members

What a plan becomes — products of a catalogue, mockups, options of a line — is the application's, or the bundle's.