sapui5

Code coverage in sapui5 OPA5 tests

左心房为你撑大大i 提交于 2020-01-03 05:53:07
问题 i can see that in SAPUI5 Qunit tests there is option for checkbox for check the code coverage (by checkbox or with an URL parameter ?coverage) But in OPA5 tests in sapui5 there isn't checkbox for code coverage and if i add the URL parameter ?coverage, the test run regular without code coverage. OPA5 test in sapui5 doesn't support code coverage? Thanks! 回答1: Recently Opa5 introduced component based testing, guessing from 1.34 onwards, the code for calling a component based test looks like

Accessing Core Model from Controller Not Working [duplicate]

人盡茶涼 提交于 2020-01-03 05:43:10
问题 This question already has answers here : Global Model Not Accesible (4 answers) Closed 9 months ago . I have added a named model in Component.js. I can access model with its name from any view but I want to access this model from one of the controllers which is not working for me. sap.ui.core.getModel("modelName") is not working and sap.ui.getCore().getModel("modelName") is also not working. How to refer its containing Component and a named model from a controller? 回答1: If the model was

Reusing SAPUI5 custom control library in Web IDE

假装没事ソ 提交于 2020-01-03 04:48:09
问题 It is more or less clear how to implement a SAPUI5 control library and deploy it to SAP ABAP repository, however I am completely lost at attempting to reuse it in Web-IDE. Web-IDE just does not see the library deployed to SAP ABAP repository. Certainly I can always clone the library files into all the projects, but it is not a right methodology. Tried different variants of dependency path to no avail. Does anyone have a clue? Thank you. 回答1: Finally, the problem's been solved. And this is how

Master menu is not visible on mobile devices but is visible on tablet

筅森魡賤 提交于 2020-01-02 13:34:33
问题 I have created a split app using the sap.m.SplitApp control. Mobile Device: iPad: 回答1: I believe this is the intended behaviour. See this github issue: https://github.com/SAP/openui5/issues/30 One of the devs says The SplitApp is designed to behave like e.g. the "Settings" app on iPhone, where a master-detail structure on tablet is mapped to a linear set of pages on phone. As such it is correct not to display a "Show Master" button. However, they suggest the following On phones there is no

Master menu is not visible on mobile devices but is visible on tablet

孤街浪徒 提交于 2020-01-02 13:34:05
问题 I have created a split app using the sap.m.SplitApp control. Mobile Device: iPad: 回答1: I believe this is the intended behaviour. See this github issue: https://github.com/SAP/openui5/issues/30 One of the devs says The SplitApp is designed to behave like e.g. the "Settings" app on iPhone, where a master-detail structure on tablet is mapped to a linear set of pages on phone. As such it is correct not to display a "Show Master" button. However, they suggest the following On phones there is no

What's the best way to add add 'All' value to <Select> Control?

孤者浪人 提交于 2020-01-02 09:11:48
问题 //Update: I use this <select> control in Filter Bar In control of UI5,if I select one item, I can't go back to non-selected state, so I want to add 'All' value in items: This works: <Select> <core:Item key="" text="All" /> <core:Item key="another value" text="another value"/> </Select> But "All" disapear in this example: <Select items="{ path: '/PRODUCTS' }"> <core:Item key="" text="All" /> <core:Item key="{ID}" text="{Route_Name}" /> </Select> What should I do? 回答1: A FacetFilter control

SAP Gateway OData service with LCHR long string

我是研究僧i 提交于 2020-01-01 19:47:20
问题 I am developing a SAPUI5 application consuming oData services with SAP Gateway, where I have implemented a search functionality which is producing a SQL where condition. One part of the condition looks like follows: ... OR DESCRIPTION LIKE '%searchString%'... . In my database table I have a field DESCRIPTION which is of type LCHR length 32000 . The only problem is that the field DESCRIPTION cannot be in WHERE clause. What would be a correct approach of searching long strings in database table

loading third party modules into ui5 without access to a global instance name

China☆狼群 提交于 2020-01-01 19:36:14
问题 I'm struggling of finding a way to include third party libraries into my sapui5 controllers. While blog posts like this one https://blogs.sap.com/2017/04/30/how-to-include-third-party-libraries-modules-in-sapui5/ describe ways to include libaries like moment or underscore , such a solution does not apply to modules that do not export a global name. How can I load browserifed modules (e.g. https://github.com/jameswyse/forecast) in my SAPUI5 application? 来源: https://stackoverflow.com/questions

How to group SAPUI5 OData before bind to control at client side?

雨燕双飞 提交于 2020-01-01 19:03:13
问题 I have an odata list for example in JSON notation: var data = [ {"category" : "A", "value" : 1, "group" : "x"}, {"category" : "B", "value" : 2, "group" : "y"}, {"category" : "C", "value" : 3, "group" : "x"}, {"category" : "A", "value" : 4, "group" : "y"}, {"category" : "A", "value" : 5, "group" : "x"} ]; First of all I filter against group == x; Values left are: var data = [ {"category" : "A", "value" : 1, "group" : "x"}, {"category" : "C", "value" : 3, "group" : "x"}, {"category" : "A",

How to group SAPUI5 OData before bind to control at client side?

[亡魂溺海] 提交于 2020-01-01 19:02:25
问题 I have an odata list for example in JSON notation: var data = [ {"category" : "A", "value" : 1, "group" : "x"}, {"category" : "B", "value" : 2, "group" : "y"}, {"category" : "C", "value" : 3, "group" : "x"}, {"category" : "A", "value" : 4, "group" : "y"}, {"category" : "A", "value" : 5, "group" : "x"} ]; First of all I filter against group == x; Values left are: var data = [ {"category" : "A", "value" : 1, "group" : "x"}, {"category" : "C", "value" : 3, "group" : "x"}, {"category" : "A",