SAE AGS955-19
AGS955 Metal Couplings (Steel) Inner Sleeve
Se ha producido un error al procesar la plantilla.
The following has evaluated to null or missing:
==> getProductCategories(channelId, productId) [in template "34352066712900#33336#null" at line 16, column 30]
----
Tip: If the failing expression is known to legally refer to something that's sometimes null or missing, either specify a default value like myOptionalVar!myDefault, or use <#if myOptionalVar??>when-present<#else>when-missing</#if>. (These only cover the last step of the expression; to cover the whole expression, use parenthesis: (myOptionalVar.foo)!myDefault, (myOptionalVar.foo)??
----
----
FTL stack trace ("~" means nesting-related):
- Failed at: #assign categoriesProduct = getProduc... [in template "34352066712900#33336#null" at line 16, column 1]
----
1<#-- Variables -->
2<#assign channelResponse = restClient.get("/headless-commerce-delivery-catalog/v1.0/channels?filter=name eq 'Aenor Tienda'")>
3<#assign channel = channelResponse.items[0]>
4<#assign channelId = channel.id>
5<#assign product = getProduct(channelId, CPDefinition_cProductId.getData()) />
6
7<#-- Product data -->
8<#assign displayDateProduct = CPDefinition_displayDate.getData() />
9<#assign productId = product.productId />
10<#assign cpDefinitionId = product.id />
11<#assign productERC = product.externalReferenceCode />
12
13<#assign categoriesProduct = getProductCategories(channelId, productId) />
14<#assign hasProductCategoriaTipoEntidadLibro = isVocabularyNameIntoCategories(categoriesProduct, 'entity type', 'libro') />
15<#assign hasProductCategoriaTipoEntidadNorma = isVocabularyNameIntoCategories(categoriesProduct, 'entity type', 'norma') />
16<#assign hasProductCategoriaTipoEntidadColeccionTematica = isVocabularyNameIntoCategories(categoriesProduct, 'entity type', 'coleccion tematica') />
17
18
19
20<#-- Functions -->
21<#function getProduct channelId productId>
22 <#return restClient.get("/headless-commerce-delivery-catalog/v1.0/channels/${channelId}/products/${productId}")>
23</#function>
24
25
26<#function getProductCategories channelId productId>
27 <#return restClient.get("/headless-commerce-delivery-catalog/v1.0/channels/${channelId}/products/${productId}/categories?sort=vocabulary").items>
28</#function>
29
30
31<#function isVocabularyNameIntoCategories categories vocabulary name>
32 <#assign found = false />
33
34 <#if categories?has_content && vocabulary?has_content && name?has_content>
35
36 <#assign vocabNorm = normalize(vocabulary) />
37 <#assign nameNorm = normalize(name) />
38
39 <#list categories as category>
40 <#if !found>
41 <#assign catVocabNorm = normalize(category.vocabulary) />
42 <#assign catNameNorm = normalize(category.name) />
43
44 <#if catVocabNorm == vocabNorm && catNameNorm == nameNorm>
45 <#assign found = true />
46 </#if>
47 </#if>
48 </#list>
49
50 </#if>
51
52 <#return found>
53</#function>
54
55
56<#function normalize text onlyAccents = false>
57 <#-- proteger null -->
58 <#if !text?has_content>
59 <#return "">
60 </#if>
61
62 <#assign t = text />
63
64 <#-- quitar acentos -->
65 <#assign t = t
66 ?replace("á","a")?replace("é","e")?replace("í","i")
67 ?replace("ó","o")?replace("ú","u")?replace("ü","u")
68 ?replace("ñ","n")
69 ?replace("Á","A")?replace("É","E")?replace("Í","I")
70 ?replace("Ó","O")?replace("Ú","U")?replace("Ü","U")
71 ?replace("Ñ","N")
72 />
73
74 <#-- si NO es solo acentos, normalización completa -->
75 <#if !onlyAccents>
76 <#assign t = t?lower_case />
77 <#assign t = t?trim />
78 <#assign t = t?replace("\\s+", " ", "r") />
79 </#if>
80
81 <#return t>
82</#function>
83
84
85
86<#-- HTML -->
87<#if hasProductCategoriaTipoEntidadColeccionTematica>
88 <div id="ecom-coleccion_tematica-price" class="container ecom-coleccion_tematica">
89
90 <aside class="purchase-box">
91
92 <div class="price-header">
93 <p class="price">00,00 €</p>
94 <p class="note">${languageUtil.get(locale, "ecom-precio_sin_iva_gastos")}</p>
95 </div>
96
97 <div class="selectors">
98
99 <!-- Cantidad -->
100 <div class="qty">
101 <input type="number" min="1" value="1">
102 </div>
103
104 <!-- Selectores language y format -->
105 <div class="selector">
106 <div data-productid="${productId}" data-erc="${productERC}" class="pb-0 selectors selector-language_format"></div>
107 </div>
108
109 </div>
110
111 <button class="buy-btn btnae-- btnae--secondary animated-button">${languageUtil.get(locale, "ecom-add_cart")}</button>
112
113 </aside>
114 </div>
115</#if>
| * Aviso PDF secure: |
El documento PDF de las normas SAE descargado quedará bloqueado y no podrá traspasarse a otro ordenador, es monopuesto y monousuario. El usuario final debe tener instalado el sistema de seguridad FILE OPEN PLUG-IN. El documento puede imprimirse una vez. |
|---|---|
| Fecha edición: |
1978-11-01
En Vigor
|
| Idiomas disponibles: | Inglés |
| Resumen: | No scope available.
|
| CTN: | |
|
Otras Relaciones |
Crossreference AGS955 |










