0

alfresco shareのフォーム エンジンは、新しいコンテンツ オブジェクトを作成および編集するための非常に強力な方法のようです。リポジトリ オブジェクトに直接対応しないフォームに対しても、この宣言的な構成を使用することは可能ですか?

私が解決しようとしている問題は、いくつかのカスタム プロパティの検索マスクです。検索フィールドの 1 つは、リスト制約のあるアスペクト用であり、オブジェクトのプロパティを編集するときのように、対応する選択要素と検証を alfresco が自動的に作成できれば素晴らしいと思います。

例として、次のコンテンツ モデルを考えてみましょう。

<constraints>
    <constraint name="jh:listconstraint" type="LIST">
        <parameter name="allowedValues">
            <list>
                <value>100</value>
                <value>200</value>
                <value>300</value>
            </list>
        </parameter>
    </constraint>
    <constraint name="jh:regexConstraint" type="REGEX">
        <parameter name="expression">
            <value>[a-z]{4}</value>
        </parameter>
        <parameter name="requiresMatch">
            <value>true</value>
        </parameter>
    </constraint>
</constraint>

<aspects>
    <aspect name="jh:test">
        <properties>
            <property name="jh:property1">
                <title>Property 1</title>
                <type>d:int</type>
                <constraints>
                    <constraint ref="jh:listconstraint"/>
                </constraints>
            </property>
            <property name="jh:property2">
                <title>Property 2</title>
                <type>d:text</type>
                <constraints>
                    <constraint ref="jh:regexConstraint"/>
                </constraints>
            </property>
        </properties>
    </aspect>
</aspects>

この側面を持つドキュメントのプロパティ シートには、リスト制約付きのプロパティの適切なドロップダウン選択と、正規表現制約の自動検証が含まれています。カスタム ダッシュレット内で同じ入力フィールドをレンダリングしたいのですが、バックエンド ロジックは自分で処理します。

ターゲット バージョンは alfresco 4.1.1 です。

4

1 に答える 1

0

タイプまたはアスペクトの定義に基づいて検索 (フォーム) を構築するための合理的な方法があるとは思えませんFormsService

Alfresco Forms を活用したい場合は、http://wiki.alfresco.com/wiki/Custom_Actions の wiki に記載されているアクション ベースのフォームを試してみて ください。値の制約を処理することについてまだ心配する必要があり、同じことを繰り返す必要があるかもしれませんが、それでもまともなスタートを切ることができます.

于 2013-01-09T20:41:15.257 に答える