Forum Stats

  • 3,767,858 Users
  • 2,252,726 Discussions
  • 7,874,366 Comments

Discussions

How to apply LOV and input text on single VO Column.ADF

M Yaa Ser
M Yaa Ser Member Posts: 60 Red Ribbon
edited Nov 20, 2019 6:24AM in JDeveloper and ADF

Hello everyone,

I need a urgent query related rendering multiple conditions on single column.

For e.g I have a Table region like below

columnA, columnB

B=1               LOV

B=2               LOV

B=3               InputText

B=4               InputDate

both columnA,B are varchar2

I applied multiple LOVs on single columns like in

http://www.awasthiashish.com/2015/02/adf-basics-set-multiple-lovs-on-attribute-and-conditionally-switch-using-lov-switch…

thats work find,

how to apply InputText and InputDate on same columnB where I already defined multiple LOVs in VO.

Note: I have Table region.

It is possible?

Tagged:

Best Answer

  • M Yaa Ser
    M Yaa Ser Member Posts: 60 Red Ribbon
    edited Nov 19, 2019 5:28AM Accepted Answer

    I achieved the result:

    Solution, from VO I added attribute again same column from EO and changed its name and AliasName.

    ======

    ======

    <ViewAttribute

        Name="CriteriaValueFrom"

        PrecisionRule="true"

        EntityAttrName="CriteriaValueFrom"

        EntityUsage="CrmCampaignCriteriaLine"

        AliasName="CRITERIA_VALUE_FROM"

        LOVName="LOV_CriteriaValueFrom"

        LOVFinder="lovSwitcher">

        <Properties>

          <SchemaBasedProperties>

            <LABEL

              ResId="pqt.dss.crm.model.vo.CrmCampaignCriteriaLineView.CriteriaValueFrom_LABEL"/>

            <TOOLTIP

              ResId="pqt.dss.crm.model.vo.CrmCampaignCriteriaLineView.CriteriaValueFrom_TOOLTIP"/>

            <CONTROLTYPE

              Value="input_text_lov"/>

          </SchemaBasedProperties>

        </Properties>

      </ViewAttribute>

    <ViewAttribute

        Name="InputCriteriaValueFrom"

        PrecisionRule="true"

        EntityAttrName="CriteriaValueFrom"

        EntityUsage="CrmCampaignCriteriaLine"

        AliasName="INPUT_CRITERIA_VALUE_FROM"/>

Answers

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 37,655 Red Diamond
    edited Nov 19, 2019 3:40AM

    I'm not sure i understand your case. A table organize the days in columns. One column has one type. You want to use different types in the fame column. This can only work if you use stings for all data. You would need to convert the date to string for this.

    Why are you using this kind of ui?

    Timo

  • M Yaa Ser
    M Yaa Ser Member Posts: 60 Red Ribbon
    edited Nov 19, 2019 4:08AM

    I dont want to change Data Type of any column,

    Column have String DT and I just want to insert data manually or from LOV that I already applied on same column.

    Below picture can elaborate more my query.

    Capture.PNG

    User will create SQL WHERE CLAUSE at run time as you can see in picture,

    Just I want to render InputText when in 'Criteria_Column' have DUE_DATE or other Number  except

    AGENT_NAME, BRANCH_NAME, CHANNEL_NAME,REGION_NAME because I applied LOVs wrt columns

    Capture2.PNG

    I droped into FROM_VALUE column from Data Control as InputText and insert any value that does not exist in Agent LOV

    so it validate me to insert valid value.

  • M Yaa Ser
    M Yaa Ser Member Posts: 60 Red Ribbon
    edited Nov 19, 2019 4:13AM

    In Short, i want to insert Data through, InputText, &  LOV  using one column

  • Cvele_new_account
    Cvele_new_account Member Posts: 4,810 Bronze Crown
    edited Nov 19, 2019 4:57AM

    I saw this question on LinkedIn, but you still haven't changed the wording of the question.
    You can have af:inputText and af:inputTextLisfofvalue int he same af:column, and you can manipulate the Visible property for them, depending of the other column values..

    Is that what you want to achieve?

  • Timo Hahn
    Timo Hahn Senior Principal Technical Consultant - Oracle ACE Director Member, Moderator Posts: 37,655 Red Diamond
    edited Nov 19, 2019 5:00AM

    If you use an lov on a field, the value entered must be in the list of items of the lov. If you don't want this behavior you can use an af:switcher component to such to a normal input text.

    Timo

  • Cvele_new_account
    Cvele_new_account Member Posts: 4,810 Bronze Crown
    edited Nov 19, 2019 5:11AM

    Timo,
    af:inputText  still will be validated against LOV enries, if attribute it presents have attached LOV

  • M Yaa Ser
    M Yaa Ser Member Posts: 60 Red Ribbon
    edited Nov 19, 2019 5:28AM Accepted Answer

    I achieved the result:

    Solution, from VO I added attribute again same column from EO and changed its name and AliasName.

    ======

    ======

    <ViewAttribute

        Name="CriteriaValueFrom"

        PrecisionRule="true"

        EntityAttrName="CriteriaValueFrom"

        EntityUsage="CrmCampaignCriteriaLine"

        AliasName="CRITERIA_VALUE_FROM"

        LOVName="LOV_CriteriaValueFrom"

        LOVFinder="lovSwitcher">

        <Properties>

          <SchemaBasedProperties>

            <LABEL

              ResId="pqt.dss.crm.model.vo.CrmCampaignCriteriaLineView.CriteriaValueFrom_LABEL"/>

            <TOOLTIP

              ResId="pqt.dss.crm.model.vo.CrmCampaignCriteriaLineView.CriteriaValueFrom_TOOLTIP"/>

            <CONTROLTYPE

              Value="input_text_lov"/>

          </SchemaBasedProperties>

        </Properties>

      </ViewAttribute>

    <ViewAttribute

        Name="InputCriteriaValueFrom"

        PrecisionRule="true"

        EntityAttrName="CriteriaValueFrom"

        EntityUsage="CrmCampaignCriteriaLine"

        AliasName="INPUT_CRITERIA_VALUE_FROM"/>

  • M Yaa Ser
    M Yaa Ser Member Posts: 60 Red Ribbon
    edited Nov 19, 2019 5:38AM

    So we can insert Data using List of Values, InputDate and InputText on one column at a time in table region.

    Thanks @Timo Hahn @Cvele_new_account for consideration.

  • M Yaa Ser
    M Yaa Ser Member Posts: 60 Red Ribbon
    edited Nov 20, 2019 6:24AM