如何添加“类别"?除了“应用程序"之外,还可以使用表单和“形式"? [英] How can I add a "category" to forms, in addition to the "app" and "form"?

查看:57
本文介绍了如何添加“类别"?除了“应用程序"之外,还可以使用表单和“形式"?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经更改了 Orbeon Form Builder 的代码以在 dialog-form-settings.xbl 中添加一个新的输入字段:

I have changed the code of Orbeon Form Builder to add a new input field in dialog-form-settings.xbl:

<xf:input ref="category" id="fb-category-input" xxf:autocomplete="off">
     <xf:label>Category</xf:label>
     <xf:hint>input Category</xf:hint>
</xf:input>

<!-- Dispatch event with result -->
<xf:dispatch name="fb-update-metadata" targetid="fb-dialog-form-settings">
    <xf:property name="app"         value="instance()/app"/>
    <xf:property name="form"        value="instance()/form"/>
    <!-- Add By Haibpl -->
    <xf:property name="category"        value="instance()/category"/>
    <!-- End Add -->
    <xf:property name="title"       value="instance()/title"/>
    <xf:property name="description" value="instance()/description"/>
    <xf:property name="logo" value="instance()/logo"/>
    <xf:property name="mode"        value="instance()/mode"/>
</xf:dispatch>

crud.xpl 中,如何获取 app 等类别的值(/request/app)?

In crud.xpl, how can i get value of category like app (/request/app)?

推荐答案

我的建议很可能不是您要寻找的,但无论如何:尽量避免对 Form Builder 和 Form Runner 进行更改.这些更改可能难以移植到 Orbeon Forms 的新版本,也很难升级,然后,如果您坚持使用旧版本,则需要获得对它的支持.

My recommendation most likely won't be what you're looking for, but here it is anyway: try to avoid making changes to Form Builder and Form Runner. Those changes can be hard to port to new versions of Orbeon Forms, make it hard to upgrade, and then, if you are stuck with an older version, to get support for it.

此外,虽然您可以在开发支持订阅下从 Orbeon 获得这些类型的自定义帮助,PE 订阅 不包括定制,您也不会在社区中获得太多帮助,因为这这不是我们想要鼓励的.

Also, while you can get help from Orbeon for these type of customizations under a Dev Support subscription, customization are not covered by PE subscriptions, and you won't get much help in the community either, as this isn't something we'd like to encourage.

那么,您有没有想过使用应用"作为类别"?如果您同时需要应用程序"和类别",您是否考虑过将两者都放在应用程序"字段中,并在两者之间加上一个破折号?例如.hr-applications,而不是一个应用程序 hr 和一个类别 application?

So, have you thought of using the "app" as the "category"? And if you need both an "app" and a "category", have you thought about putting both in the "app" field with say a dash in between? E.g. hr-applications, instead of having an app hr and a category application?

这篇关于如何添加“类别"?除了“应用程序"之外,还可以使用表单和“形式"?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆