[midPoint] Mandatory fields

Jason Everling jeverling at bshp.edu
Thu Aug 6 16:49:28 CEST 2015


I had no idea! I have been overriding the displayName for "Extension" in
common-3 then rebuilding and now I can simply add

   <item>
      <c:ref>c:extension</c:ref>
      <displayName>BSHP Extensions</displayName>
   </item>

To our default object template, tested, and it works :)

Thanks for this awesome enhancement!

JASON

On Thu, Aug 6, 2015 at 8:16 AM, Katarina Valalikova <
k.valalikova at evolveum.com> wrote:

> Hi Peter,
>
> which version of midPoint are you using? I'm asking because from the
> version 3.1.1 it is not necessary to modify midpoint's schemas dirrectly.
> You can do it in runtime environment using object template. In my opinion
> this is better way for customization as you can do it without rebuilding
> and redeploying midPoint with every other change. The example configuration
> is bellow:
>
> <objectTemplate xmlns=
> "http://midpoint.evolveum.com/xml/ns/public/common/common-3"
> <http://midpoint.evolveum.com/xml/ns/public/common/common-3>
>                 xmlns:c=
> "http://midpoint.evolveum.com/xml/ns/public/common/common-3"
> <http://midpoint.evolveum.com/xml/ns/public/common/common-3>
>                 oid="10000000-0000-0000-0000-000000000000">
>    <name>User Template</name>
>    <mapping>
>                 <!-- this is a section where you can have your mappings -->
>    </mapping>
>
> <!-- here start the section for 'schema override' -->
>  <item>
>         <ref>c:additionalName</ref>                    <!-- the name of
> the schema attribute you want to modify -->
>         <limitations>
>             *<layer>presentation</layer>                  * <!-- layer
> has to be set to presentation - this will provide checks on the GUI layer
> -->
> *            <ignore>true</ignore>*                             <!--
> completely hides this attribute in GUI -->
>         </limitations>
>    </item>
>
> <item>
>         <ref>c:name</ref>
>         <limitations>
>             *<layer>presentation</layer>*
> *            <minOccurs>1</minOccurs>*               <!-- this makes the
> field mandatory -->
>         </limitations>
>    </item>
>
> <!-- end of the 'schema override' section -->
>
>
> Hope this helps you.
>
> Best Regards,
> Katarina Valalikova
>
>
> Dňa 6. 8. 2015 o 14:43 Petr Gašparík napísal(a):
>
> Hi,
> I customized common-3.xsd - minOccurs="1" in scheme jar to make attributes
> mandatory.
>
> Now, input fields has red asterisk but midPoint is not taking care about
> that and allows empty values.
>
> What I am missing? Thanks!
> Any answer is appreciated, we run PoC right now..
>
> beste regards, Petr G.
> --
> --
> Petr G.
>
>
> _______________________________________________
> midPoint mailing listmidPoint at lists.evolveum.comhttp://lists.evolveum.com/mailman/listinfo/midpoint
>
>
>
> _______________________________________________
> midPoint mailing list
> midPoint at lists.evolveum.com
> http://lists.evolveum.com/mailman/listinfo/midpoint
>
>


-- 
JASON

-- 


CONFIDENTIALITY NOTICE:
This e-mail together with any attachments is proprietary and confidential; 
intended for only the recipient(s) named above and may contain information 
that is privileged. You should not retain, copy or use this e-mail or any 
attachments for any purpose, or disclose all or any part of the contents to 
any person. Any views or opinions expressed in this e-mail are those of the 
author and do not represent those of the Baptist School of Health 
Professions. If you have received this e-mail in error, or are not the 
named recipient(s), you are hereby notified that any review, dissemination, 
distribution or copying of this communication is prohibited by the sender 
and to do so might constitute a violation of the Electronic Communications 
Privacy Act, 18 U.S.C. section 2510-2521. Please immediately notify the 
sender and delete this e-mail and any attachments from your computer. 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20150806/72023041/attachment.htm>


More information about the midPoint mailing list