Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3323

Recommended SAP UI5 F4 SearchHelp JS code organization/structure

$
0
0

Hi experts,

 

I'm struggling with the correction structure Approach for SAP UI5 Input search helps.

my application is an XML view with a filter bar and an Input field in the filter bar.

 

For the input field I have set the Parameter showValueHelp="true". The Icon for the
SH is displayed at end of the field. OK.

 

Then I want to open the search help. Therefore the event handler "valueHelpRequest"

must be coded in the view controller.

 

There are some Blogs in SCN available, showing examples for UI5 F4 search helps.

But these examples always define a basic view, the view controller, ...

 

If I'm implementing 5 search helps on my view the Controller will be completely overloaded !

 

I started to think about fragments, but fragments have no own controller to separate the JS-function
definitions from the main view JS function definitions.

 

I want to have a project structure like the following:

 

ROOT

          --> view

          --> controller

          --> model

 

          --> searchhelps

 

          --> util (e.g. formatter)

 

How can I call the search help relevant functions from my XML view event handler USING MY
PREFERRED FOLDER STRUCTURE ?

 

*** Maybe my approach is not the best and you have better recommendations.

 

 

*** Maybe I MUST CODE THE JS FUNCTIONS FOR THE SH IN THE MAIN VIEW, BECAUSE I'M OPERATING
WITHIN THIS VIEW...

 

There is some experience missing on my side  how to separate the mass of code of the different required search helps

within my UI5 project.

 

One remaining question. If I'm extracting the data for the SH via ODATA: Do I have to code the layout of the

search help columns by myself?

 

Thanks in advance
Klaus Wegener


Viewing all articles
Browse latest Browse all 3323

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>