1,844
การแก้ไข
| บรรทัดที่ 239: | บรรทัดที่ 239: | ||
These attributes below dictate the form's behaviours regarding data request: | These attributes below dictate the form's behaviours regarding data request: | ||
* '''populate_route''' ''(url_for_string)'': Route to which a data fetch request is to be sent. | * '''populate_route''' ''(url_for_string: defaults to {{code|lang=python|False}})'': Route to which a data fetch request is to be sent. | ||
* '''populate_suppress''' ''([str,])'': The list of data fetch modes to suppress. (Refer to Note #1 for available fetch mode.) A most common reason to prevent any single CuneiForm to send a fetch request is so that a page-wide fetch request can be used in its stead. A page-wide request fetch the data for several components on the same page and populate them at once (See [[Multi-component Page]]). | * '''populate_suppress''' ''([str,])'': The list of data fetch modes to suppress. (Refer to Note #1 for available fetch mode.) A most common reason to prevent any single CuneiForm to send a fetch request is so that a page-wide fetch request can be used in its stead. A page-wide request fetch the data for several components on the same page and populate them at once (See [[Multi-component Page]]). | ||
* '''populate_id''' ''([str,] | * '''populate_id''' ''([str,]: defaults to {{code|lang=python|False}})'': The list of fields whose data are to be parts of a data fetch request. For example, if a fetch request needs to know the {{code|id}} of the fetch target, then the content of the {{code|id}} field needs to be a part of the fetch request. Members of this list may take the formats listed below, and refer to Note #2 for additional information: | ||
** '''{{code|lang=python|<field_name>}}''' (like {{code|lang=python|'id'}}) refers to a field of the same CuneiForm | ** '''{{code|lang=python|<field_name>}}''' (like {{code|lang=python|'id'}}) refers to a field of the same CuneiForm | ||
** '''{{code|lang=python|master.<field_name>}}''' (like {{code|lang=python|'master.id'}}) refers to a field of the Master CuneiForm or CuneiTable. (Usually the header form of a [[Multi-component Page]], see the article to learn how to declare a master.) | ** '''{{code|lang=python|master.<field_name>}}''' (like {{code|lang=python|'master.id'}}) refers to a field of the Master CuneiForm or CuneiTable. (Usually the header form of a [[Multi-component Page]], see the article to learn how to declare a master.) | ||