Skip to Content

Hide Custom Embedded Component based on Standard bo when no data found in C4C PDI

Hi,

currently we have some embedded components within Ticket TI screen.
Some of them are displaying no data.

Is there any option to hide these Components when no data is found ?
I've already tryed to use ui-switches, which allows me to configure the embedded component for different user roles, but empty embedded components are still visible.

Any ideas ?

Add a comment
10|10000 characters needed characters exceeded

Related questions

3 Answers

  • Posted on Jun 15, 2020 at 09:12 PM

    Hi,

    You can make use of "UI Rule" to manage the visibility of empty components assuming that data is shown in those embedded components comes from the same Standard BO. if not then you need to implement some workaround to make sure that you have atleast one identifier at Standard BO root level as root fields can be evaluated in UI Rules.

    Once done then you can:

    1. Using kUT, define a Rule at UI Component where you will evaluate if fields to be shown are empty or not. Pls check https://enable.cx.sap.com/media/t/1_iitw93sw for more details about how to create UI rules.

    2. Associate the Rule created to the corresponding EC visibility conditon.

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Christopher.

      Aah, I got it. Apologies, I overlooked your problem. Now I see that for custom EC even after generating/assigning. all the anchors I can't see the "ADD" button in "Rules and Validations".

      I think you might need to reach out to SAP Support to know if this is even possible with the current system design.

      Sorry!

  • Posted on Jul 20, 2020 at 01:19 PM

    Hi,

    thx for your information.
    Setting an UI Rule wiould be an option, but how to make Use of Ui Rules within custom embedded components.

    Currently i'am only able to enable or disable the embedded component.

    Add a comment
    10|10000 characters needed characters exceeded

    • Hi Christopher.

      Aah, I got it. Apologies, I overlooked your problem. Now I see that for custom EC even after generating/assigning. all the anchors I can't see the "ADD" button in "Rules and Validations".

      I think you might need to reach out to SAP Support to know if this is even possible with the current system design.

      Sorry!

  • Posted on Jul 22, 2020 at 12:07 PM

    Hi Christopher,

    One work around is to define an indicator in the custom BO(if the EC is associated to a custom BO) then set it to false if there is no data (can be done in the afterloading event).

    In the EC Level in the properties, set the binding of the EC to that indicator.

    There is one drawback however that the heading of the EC when you bind it to the screen will be visible (no sure if you can make it empty and use the heading from the EC instead):

    This is how it will look like with the heading

    I hope that helps :)

    Mousa


    Add a comment
    10|10000 characters needed characters exceeded

    • Hi,

      I am not sure if it will work with EC, I have to check. Usually, you will start adaption mode in the front end you will locate the UI element you want to hide and click on the small pencil on top of it and you will have the rules option in the right side menu, when you go there you will find visibility.

      If I have time today I will create one EC in C4C and test it out.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.