Skip to content

Type Alias: ArgAddProduct ​

ts
type ArgAddProduct = object;

The product of the print job — supplier, product model and variants (ArgPrintJob.addProducts).

Remarks ​

What you fill in depends on EditorArguments.dataMode:

  • Exact — supplierCode (or supplierGuid) and at least one entry in variants.
  • Partial — supplierCode (or supplierGuid) and model.modelCode, variants, or both. The user selects the missing variants in the editor.
  • Own — model and variants describing your own product; the supplier fields are not used. If you leave out addProducts or its model, the editor asks the user to enter the product data.

When you edit an existing print job (openMode: 'Edit'), only variants is used: variants that are not in the print job yet are added (from the print job's supplier), variants that are already there get the quantity and overrides you send updated (values you leave out keep their saved values).

Properties ​

PropertyTypeDescription
model?ArgAddProductModelThe product model. Partial: modelCode selects the TronCloud product model whose variants the user can choose from. Own: describes your own product.
supplierCode?stringCode of the supplier in TronCloud, for example PFC. Use either this or supplierGuid.
supplierGuid?stringGUID of the supplier in TronCloud. Alternative to supplierCode.
variantsArgAddProductVariant[]The product variants. Exact: the variants to design (at least one). Partial: the variants to use or preselect (may be empty when model is set). Own: your own variants.

Czech Republic – The Country for the FutureFunded by the European Union – NextGenerationEUThe project was implemented within the The Country for the Future programme of the Ministry of Industry and Trade and co-financed by the European Union under NextGenerationEU.Support · Examples

Czech Republic – The Country for the FutureFunded by the European Union – NextGenerationEUThe project was implemented within the The Country for the Future programme of the Ministry of Industry and Trade and co-financed by the European Union under NextGenerationEU.Support · Examples