AnsweredAssumed Answered

Sets in advanced search forms

Question asked by jordiv on Mar 26, 2012
Latest reply on Apr 11, 2012 by jordiv
Hi,

I've created some new advanced search forms for my custom types as described in the Working with Custom Content Types tutorial by Jeff.

I want to group the metadata in the view, and I've tried using form set, but it doesn't seem to work for the search form. For the edit metadata form is working fine.

Any clue of how to achieve this?

The relevant code of my share-config-custom.xml:

    <config evaluator="string-compare" condition="AdvancedSearch">
        <advanced-search>
            <forms>
                <form labelId="label.my_workContract" descriptionId="label.my_workContract_description">my:workContract</form>
            </forms>
        </advanced-search>
    </config>
    <config evaluator="node-type" condition="my:workContract">
        <property-sheet>
            <show-property name="my:workContractType" display-label-id="label.my_workContractType" />
            <show-property name="my:workContractWorkerId" display-label-id="label.my_workContractWorkerId" />
            <show-property name="my:workContractWorkerName" display-label-id="label.my_workContractWorkerName" />
        </property-sheet>
        <forms>
            <form>
                <field-visiblity>
                    <show id="my:workContractType" label-id="label.my_workContractType" />
                    <show id="my:workContractWorkerId" label-id="label.my_workContractType" />
                    <show id="my:workContractWorkerName" label-id="label.my_workContractType" />
                </field-visiblity>
                <appearance>
                    <set id="workContractSet" appearance="fieldset" label="Work Contract Properties" />
                    <set id="" appearance="fieldset" label="General Properties" />

                    <field id="my:workContractType" set="workContractSet" />
                    <field id="my:workContractWorkerId" set="workContractSet" />
                    <field id="my:workContractWorkerName" set="workContractSet" />
                </appearance>
            </form>
            <form id="search">
                <field-visiblity>
                    <show id="my:workContractType" label-id="label.my_workContractType" />
                    <show id="my:workContractWorkerId" label-id="label.my_workContractType" />
                    <show id="my:workContractWorkerName" label-id="label.my_workContractType" />
                </field-visiblity>
                <appearance>
                    <set id="workContractSet" appearance="fieldset" label="Work Contract Properties" />
                    <set id="" appearance="fieldset" label="General Properties" />

                    <field id="my:workContractType" set="workContractSet" />
                    <field id="my:workContractWorkerId" set="workContractSet" />
                    <field id="my:workContractWorkerName" set="workContractSet" />
                </appearance>
            </form>
        </forms>
    </config>


Thanks,
Jordi

Outcomes