⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 widget-form.dtd

📁 国外的一套开源CRM
💻 DTD
字号:
<?xml version="1.0" encoding="UTF-8"?>
<!--
  To refer to this DTD in your XML file, use the following declaration:
<!DOCTYPE forms PUBLIC "-//OFBiz//DTD OFBiz Form Widget//EN" "http://www.ofbiz.org/dtds/widget-form.dtd">
-->

<!--
 *  Copyright (c) 2003 The Open For Business Project - www.ofbiz.org
 *
 *  Permission is hereby granted, free of charge, to any person obtaining a
 *  copy of this software and associated documentation files (the "Software"),
 *  to deal in the Software without restriction, including without limitation
 *  the rights to use, copy, modify, merge, publish, distribute, sublicense,
 *  and/or sell copies of the Software, and to permit persons to whom the
 *  Software is furnished to do so, subject to the following conditions:
 *
 *  The above copyright notice and this permission notice shall be included
 *  in all copies or substantial portions of the Software.
 *
 *  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 *  OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 *  MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 *  IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
 *  CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT
 *  OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR
 *  THE USE OR OTHER DEALINGS IN THE SOFTWARE.

 *  $Id: widget-form.dtd,v 1.4 2004/02/21 23:58:04 jonesde Exp $
-->

<!ENTITY % AllFields "display | hyperlink | lookup | text | textarea | date-time | drop-down | check | radio | submit | reset | hidden | ignored | file | text-find | date-find | range-find">

<!ELEMENT forms ( form+ )>

<!--
	map-list-name: for list type and other multiple data/form types this is
		the name of the list in the context to iterate over
	list-entry-name: if specified each list entry will be put in the context
		with this name; otherwise the list entry must be a Map and the entries
		in the Map will be put into the context by name
	type: a single form is a simple single form with values from a single set of values;
		a list form is a list of individual forms in a table (could be called a tabular form), it has a list of sets of values and creates one form for each list element;
		a multi form is like a list/tabular form, but it creates a single form to submit all list item forms at once; the field names in the resulting form have an appendage attached to make them unique according to the pattern used for the multi-service event handler that will call one service for each list element
-->
<!ELEMENT form ( alt-target*, auto-fields-service*, auto-fields-entity*, field*, sort-order? )>
<!ATTLIST form
    name CDATA #REQUIRED
    type ( single | list | multi | upload ) #REQUIRED
    target CDATA #IMPLIED
    paginate-target CDATA #IMPLIED
    title CDATA #IMPLIED
    tooltip CDATA #IMPLIED
    list-name CDATA #IMPLIED
    list-entry-name CDATA #IMPLIED
    default-map-name CDATA #IMPLIED
    default-entity-name CDATA #IMPLIED
    default-service-name CDATA #IMPLIED
    default-title-style CDATA #IMPLIED
    default-widget-style CDATA #IMPLIED
    default-tooltip-style CDATA #IMPLIED
    item-index-separator CDATA "_o_"
    extends CDATA #IMPLIED
    extends-resource CDATA #IMPLIED
>

<!ELEMENT alt-target EMPTY>
<!ATTLIST alt-target
    use-when CDATA #REQUIRED
    target CDATA #IMPLIED
>

<!ELEMENT auto-fields-service EMPTY>
<!ATTLIST auto-fields-service
    service-name CDATA #REQUIRED
    map-name CDATA #IMPLIED
    default-field-type ( edit | find | display | hidden ) "edit"
>

<!ELEMENT auto-fields-entity EMPTY>
<!ATTLIST auto-fields-entity
    entity-name CDATA #REQUIRED
    map-name CDATA #IMPLIED
    default-field-type ( edit | find | display | hidden ) "edit"
>

<!--
	name: a unique name for this field
	map-name: the name (or location) of the map that contains the data for this 
		field in the form context
	entity-name: used along with the field-name to look up the entity field definition
		for any information that might be helpful when rendering the form field
	field-name: see the description of entity-name
	service-name: used along with the attribute-name to look up the service attribute 
		definition for any information that might be helpful when rendering the form field
	attribute-name: see the description of service-name
	entry-name: defaults to the value of the name attribute; is used to 
		specify the name of the entry in the map that contains the value to populate
	parameter-name: defaults to the value of the name attribute; is the name of the 
		parameter to use for this field (the request parameter in a web application)
	title: the name of this field that will be shown to the user; can use the ${} 
		and foo.bar (dot) syntax to insert values from the context for parameterization
		or internationalization
	tooltip: the text to show on mouse over or help for more information; can use the ${} 
		and foo.bar (dot) syntax to insert values from the context for parameterization
		or internationalization
	title-style: the name of a style (like a CSS class) to apply to the title of this field
	widget-style: the name of a style (like a CSS class) to apply to the widget 
		that the user will interact with for this field
	position: for row oriented forms (single type) can specify that the field should be put 
		a column other than the first; for column oriented forms (list type) specifies 
		the row the field should be put in
	red-when: the widget/interaction part will be red if the date value is
		before-now (for thruDate), after-now (for fromDate), or by-name (if the
		field's name or entry-name or fromDate or thruDate the corresponding 
		action will be done); only applicable when the field is a timestamp
	use-when: used to specify a condition that must be true to use this field;
		the condition should be written using the Java syntax and can operate 
		on values in the form context; if this is used the field will only be put
		on the field list, and not in the field map meaning that values for this
		field cannot be overridden
-->
<!ELEMENT field ( (%AllFields;)? )>
<!ATTLIST field
    name CDATA #REQUIRED
    map-name CDATA #IMPLIED
    entity-name CDATA #IMPLIED
    service-name CDATA #IMPLIED
    entry-name CDATA #IMPLIED
    parameter-name CDATA #IMPLIED
    field-name CDATA #IMPLIED
    attribute-name CDATA #IMPLIED
    title CDATA #IMPLIED
    tooltip CDATA #IMPLIED
    title-style CDATA #IMPLIED
    widget-style CDATA #IMPLIED
    tooltip-style CDATA #IMPLIED
    position CDATA "1"
    red-when ( never | before-now | after-now | by-name ) "by-name"
    use-when CDATA #IMPLIED
    id-name CDATA #IMPLIED
>

<!--
	description: specifies the string to display, can use the ${} synrax
		to insert context values; if empty the value of the field will be
		printed for a default
-->
<!ELEMENT display EMPTY>
<!ATTLIST display
    also-hidden ( true | false ) "true"
    description CDATA #IMPLIED
>

<!--
	target: the target location of the hyperlink; can use the ${} syntax to 
		substitute values from the context
	description: specifies the string to display, can use the ${} synrax
		to insert context values; if empty the value of the field will be
		printed for a default
-->
<!ELEMENT hyperlink EMPTY>
<!ATTLIST hyperlink
    also-hidden ( true | false ) "true"
    target-type ( intra-app | inter-app | content | plain ) "intra-app"
    target CDATA #REQUIRED
    description CDATA #IMPLIED
>

<!ELEMENT sub-hyperlink EMPTY>
<!ATTLIST sub-hyperlink
	use-when CDATA #IMPLIED
	link-style CDATA #IMPLIED
    target-type ( intra-app | inter-app | content | plain ) "intra-app"
    target CDATA #REQUIRED
    description CDATA #IMPLIED
>

<!ELEMENT text ( sub-hyperlink? )>
<!ATTLIST text
    size CDATA "25"
    maxlength CDATA #IMPLIED
    default-value CDATA #IMPLIED
>

<!ELEMENT textarea EMPTY>
<!ATTLIST textarea
    cols CDATA "60"
    rows CDATA "3"
    default-value CDATA #IMPLIED
>

<!-- a special entry for date-time fields; may just have a default size text 
	entry box and some sort of widget to make date entry/selection easier
-->
<!ELEMENT date-time EMPTY>
<!ATTLIST date-time
    type ( timestamp | date | time ) "timestamp"
    default-value CDATA #IMPLIED
>

<!-- entity-options will look up options for the field in the given entity
    key-field-name: the value of the key-field-name will be the value passed 
    	to the server
    description: will be presented to the user with field values
    	substituted using the ${} syntax
    key-field-name: the name of the field in the looked up entity that will be used 
    	for the key value; defaults to the entry-name of the field this is in
 -->
<!ELEMENT entity-options ( entity-constraint*, entity-order-by* )>
<!ATTLIST entity-options
    entity-name CDATA #REQUIRED
    key-field-name CDATA #IMPLIED
    description CDATA #REQUIRED
    cache ( true | false ) "true"
    filter-by-date ( true | false | by-name ) "by-name"
>

<!ELEMENT entity-constraint EMPTY>
<!ATTLIST entity-constraint
    name CDATA #REQUIRED
    value CDATA #REQUIRED
>
<!ELEMENT entity-order-by EMPTY>
<!ATTLIST entity-order-by
    field-name CDATA #REQUIRED
>

<!-- list-options will create options based on data in a list
	list-name: the name of the list to iterate through to get values
	list-entry-name: if specified the list entry will be placed in the local 
		context, otherwise each list entry must be a Map that will be expanded 
		into the local context
    key-name: the value of the key-name will be the value passed 
    	to the server; this should be the full name of the location of the
    	key value in the context, given the list-entry-name or expanded
    	list-entry Map as the options you would most likely use
    description: will be presented to the user with field values
    	substituted using the ${} syntax
-->
<!ELEMENT list-options EMPTY>
<!ATTLIST list-options
    list-name CDATA #REQUIRED
    list-entry-name CDATA #IMPLIED
    key-name CDATA #REQUIRED
    description CDATA #IMPLIED
>

<!--
	description: what the user will see in the widget; defaults to the value of the key attribute
-->
<!ELEMENT option EMPTY>
<!ATTLIST option
    key CDATA #REQUIRED
    description CDATA #IMPLIED
>

<!--
	no-current-selected-key: the key to mark as selected when there is no
		current entry value
-->
<!ELEMENT drop-down ( (entity-options | list-options | option)*, sub-hyperlink? )>
<!ATTLIST drop-down
    allow-empty ( true | false ) "false"
    current ( first-in-list | selected ) "first-in-list"
    no-current-selected-key CDATA #IMPLIED
    current-description CDATA #IMPLIED
>

<!ELEMENT radio ( (entity-options | list-options | option)* )>
<!ATTLIST radio
    no-current-selected-key CDATA #IMPLIED
>

<!ELEMENT check EMPTY>

<!ELEMENT submit EMPTY>
<!ATTLIST submit
    button-type ( button | text-link | image ) "button"
    image-location CDATA #IMPLIED
>

<!ELEMENT reset EMPTY>

<!ELEMENT hidden EMPTY>
<!ATTLIST hidden
    value CDATA #IMPLIED
>

<!ELEMENT ignored EMPTY>

<!ELEMENT text-find ( sub-hyperlink? )>
<!ATTLIST text-find
    size CDATA "25"
    maxlength CDATA #IMPLIED
    default-value CDATA #IMPLIED
>

<!ELEMENT range-find ( sub-hyperlink? )>
<!ATTLIST range-find
    size CDATA "25"
    maxlength CDATA #IMPLIED
    default-value CDATA #IMPLIED
>

<!ELEMENT lookup ( sub-hyperlink? )>
<!ATTLIST lookup
    target-form-name CDATA #REQUIRED
    size CDATA "25"
    maxlength CDATA #IMPLIED
    default-value CDATA #IMPLIED
>

<!ELEMENT date-find EMPTY>
<!ATTLIST date-find
    type ( timestamp | date | time ) "timestamp"
    default-value CDATA #IMPLIED
>

<!ELEMENT sort-order ( sort-field* )>
<!ATTLIST sort-order
    type ( explicit ) "explicit"
>
<!ELEMENT sort-field EMPTY>
<!ATTLIST sort-field
    name CDATA #REQUIRED
>

<!ELEMENT file ( sub-hyperlink? )>
<!ATTLIST file
    size CDATA "25"
    maxlength CDATA #IMPLIED
    default-value CDATA #IMPLIED
>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -