diff --git a/src/02/01/01/z2ui5_cl_xml_view.clas.abap b/src/02/01/01/z2ui5_cl_xml_view.clas.abap index 4b918caa..8c6c7cad 100644 --- a/src/02/01/01/z2ui5_cl_xml_view.clas.abap +++ b/src/02/01/01/z2ui5_cl_xml_view.clas.abap @@ -3511,6 +3511,41 @@ methods WIZARD returning value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + methods template_repeat + importing + !list type CLIKE optional + !var type CLIKE optional + returning + value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + + methods template_with + importing + !path type CLIKE optional + !helper type CLIKE optional + !var type CLIKE optional + returning + value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + + methods template_if + importing + !test type CLIKE optional + returning + value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + + methods template_then + returning + value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + + methods template_else + returning + value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + + methods template_elseif + importing + !test type CLIKE optional + returning + value(RESULT) type ref to Z2UI5_CL_XML_VIEW . + PROTECTED SECTION. DATA mv_name TYPE string. DATA mv_ns TYPE string. @@ -7125,6 +7160,71 @@ CLASS Z2UI5_CL_XML_VIEW IMPLEMENTATION. ENDMETHOD. + METHOD template_else. + + result = _generic( name = `else` + ns = `template` + ). + + ENDMETHOD. + + + METHOD template_elseif. + + result = _generic( name = `elseif` + ns = `template` + t_prop = VALUE #( + ( n = `test` v = test ) + ) ). + + ENDMETHOD. + + + METHOD template_if. + + result = _generic( name = `if` + ns = `template` + t_prop = VALUE #( + ( n = `test` v = test ) + ) ). + + ENDMETHOD. + + + METHOD template_repeat. + + result = _generic( name = `repeat` + ns = `template` + t_prop = VALUE #( + ( n = `list` v = list ) + ( n = `var` v = var ) + ) ). + + ENDMETHOD. + + + METHOD template_then. + + result = _generic( name = `then` + ns = `template` + ). + + ENDMETHOD. + + + METHOD template_with. + + result = _generic( name = `with` + ns = `template` + t_prop = VALUE #( + ( n = `path` v = path ) + ( n = `helper` v = helper ) + ( n = `var` v = var ) + ) ). + + ENDMETHOD. + + METHOD text. result = me. _generic( name = `Text` @@ -7877,6 +7977,7 @@ METHOD wizard. * ( n = `core:require` v = `{ MessageToast: 'sap/m/MessageToast' }` ) * ( n = `core:require` v = `{ URLHelper: 'sap/m/library/URLHelper' }` ) ( n = `xmlns:table` v = `sap.ui.table` ) + ( n = `xmlns:template` v = `http://schemas.sap.com/sapui5/extension/sap.ui.core.template/1` ) ( n = `xmlns:f` v = `sap.f` ) ( n = `xmlns:form` v = `sap.ui.layout.form` ) ( n = `xmlns:editor` v = `sap.ui.codeeditor` ) diff --git a/test/abap_transpile.json b/test/abap_transpile.json index 4eac1c1e..f59da9c3 100644 --- a/test/abap_transpile.json +++ b/test/abap_transpile.json @@ -14,7 +14,7 @@ "addFilenames": true, "addCommonJS": true, "unknownTypes": "runtimeError", - "keywords": ["return", "in", "class", "for", "delete", "default"], + "keywords": ["return", "in", "class", "for", "delete", "default", "var"], "extraSetup": "../test/setup.mjs", "skip": [ {"object": "Z2UI5_CL_AJSON", "class": "ltcl_parser_test", "method": "parse_error", "note": "NodeJS 20 does not set position of parsing error"}