1. Get rid of all advertisements and get unlimited access to documents by upgrading to Premium Membership. Upgrade to Premium Now and also get a Premium Badge!

How to hide the matadata fields in UCM??

Discussion in 'Oracle Webcenter Suite (formerly Oracle ECM)' started by YogitaM1, Jun 12, 2012.

  1. YogitaM1

    YogitaM1 Active Member

    Messages:
    29
    Likes Received:
    0
    Trophy Points:
    80
    Location:
    Navi Mumbai
    Hi all..
    How to hide matadata fields in UCM depending on particular value of option list field???
    Ex-One option list is there- department having two values 1. HR and 2. Finance.
    If I select HR,Then in the same profile EmpName and EmpNo. should displayed and
    if I select Finance,then OrderId and OrderName should be displayed..means EMPNo and EmpName should hide
    How can I achieve this??
    -Yogita
     
  2. dcell59

    dcell59 Forum Advisor

    Messages:
    103
    Likes Received:
    18
    Trophy Points:
    260
    Are you creating profiles based on this option list field? In profiles, you can hide metadata fields or make them mandatory (that's basically the main reason for profiles).
     
  3. YogitaM1

    YogitaM1 Active Member

    Messages:
    29
    Likes Received:
    0
    Trophy Points:
    80
    Location:
    Navi Mumbai
    Thanks for reply..but I want to achieve this in a single profile only...
    One choice is I can make some matadata fields Hidden,But How to make the custom matadata fields hidden??
    Other choice is How can I prevent to be checked in some matadata fields though the user enters the values..???
    Please Reply..
     
  4. dcell59

    dcell59 Forum Advisor

    Messages:
    103
    Likes Received:
    18
    Trophy Points:
    260
    It sounds like you want to do things dynamically, which I believe will require writing custom javascript to hide and show fields.
     
  5. YogitaM1

    YogitaM1 Active Member

    Messages:
    29
    Likes Received:
    0
    Trophy Points:
    80
    Location:
    Navi Mumbai
    Hi dcell59..
    Thanks for reply..Can you please tell how to write custom javascript in UCM??
    Or tell me how can we prevent one some matadata fields to be checked in ,though the user enter the value

    Thanks & Regards,
    Yogita
     
  6. dcell59

    dcell59 Forum Advisor

    Messages:
    103
    Likes Received:
    18
    Trophy Points:
    260
    For either, you will need to create a custom component.

    To remove metadata fields from the checkin operation, you need to write a filter. How you write the filter will depend on what version of the Content Server you are running and what updates have been applied. I believe it's different between 10g and 11g, as 11g has more filter hooks built in.

    To add custom javascript, you need to first figure out if you can do what you need by reading the page source. You may not be able to hide the fields in a nice way, but you may be able to disable them. Once you know what code to add, you have to figure out where to add it. This involves using the page debugger to figure out where to insert your custom code. I've done this a few times, and it's not easy and sometimes it's not even possible.
     
    YogitaM1 likes this.