Table of Contents | ||
---|---|---|
|
Usage
Thai |
---|
การใช้ |
Plugin Properties Options allow a plugin to gather configuration data from a plugin user.
Thai ตัวเลือกคุณสมบัติปลั๊กอินอนุญาตให้ปลั๊กอินรวบรวมข้อมูลการกำหนดค่าจากผู้ใช้ปลั๊กอิน
Plugin Properties Options should be returned in the abstract method "getPropertyOptions" of each plugin.
Thai ตัวเลือกคุณสมบัติปลั๊กอินควรส่งคืนในเมธอด abstract "getPropertyOptions" ของแต่ละปลั๊กอิน
Structure
Thai |
---|
โครงสร้าง |
Plugin Properties Options are in JSON format.
Thai ตัวเลือกคุณสมบัติปลั๊กอินอยู่ในรูปแบบ JSON
Plugin Properties Options is an array of Properties Page object
Thai ตัวเลือกคุณสมบัติปลั๊กอินเป็นอาร์เรย์ของวัตถุหน้าคุณสมบัติ
A Properties Page object has 2 mandatory attributes called "title" and "properties". It also has 2 optional attributes called "validators" and "buttons".
Thai วัตถุหน้าคุณสมบัติมี 2 แอตทริบิวต์บังคับที่เรียกว่า "ชื่อ" และ "คุณสมบัติ" นอกจากนี้ยังมีแอตทริบิวต์ 2 ตัวเลือกที่เรียกว่า "ตัวตรวจสอบความถูกต้อง" และ "ปุ่ม"
Code Block | ||||
---|---|---|---|---|
| ||||
[ { title : 'Page Title', properties : [ { name : 'Property Name', label : 'Property Label', description : 'Property Description', //optional, default is NULL type : 'Property Type', value : 'Property Value', //optional, default is null required : 'Mandatory or Not', //optional, 'true' or 'false', default is 'false' //… more attributes … }, //… more fields … ], validators : [ //optional //… properties custom validators … ], buttons : [ //optional //… custom properties page buttons … ] }, //… more properties page … ] |
Sample Look and Feel
Thai |
---|
ตัวอย่างรูปลักษณ์ |
Field Types
Thai |
---|
ประเภทของฟิลด์ |
Auto Complete
Thai |
---|
ดำเนินการอัตโนมัติ |
type : 'autocomplete'
Thai ประเภท: 'เติมข้อความอัตโนมัติ'
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Regular
Refer to RegularExpress (Regex) Validation Attributes for extra attributes to do validation using regex.
Thai อ้างถึง Regular Express (Regex) Validation Attributes สำหรับแอตทริบิวต์เพิ่มเติมเพื่อทำการตรวจสอบความถูกต้องโดยใช้ regex
Check Box
Thai |
---|
ช่องทำเครื่องหมาย |
type : 'CheckBox'
Thai ประเภท: 'ช่องทำเครื่องหมาย'
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Multi Values Field on how to use the value of this field type in the plugin code.
Thai อ้างถึง Retrieve Properties Value in Plugin - Multi Values Field เกี่ยวกับวิธีใช้ค่าของฟิลด์ชนิดนี้ในรหัสปลั๊กอิน
Code Editor
Thai |
---|
เครื่องมือแก้ไขรหัส |
type : 'CodeEditor'
Thai ประเภท: 'CodeEditor'
mode : Optional, used for specified highlight mode. Default to 'text', available values are 'text', 'java', 'html', 'javascript', 'css', 'json', 'sql' and 'xml'.
Thai โหมด: ตัวเลือกใช้สำหรับโหมดไฮไลต์ที่ระบุ ค่าเริ่มต้นของ 'text', available values are 'text', 'java', 'html', 'javascript', 'css', 'json', 'sql' and 'xml'
Refer to Dependency Field Attributes for
Refer to Dependency Field Attributes forextra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Color
Thai |
---|
สี |
type : 'color'
Thai ประเภท: 'สี'
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Combine Grid
Thai |
---|
รวมกริด |
Combine Grid is used to migrate 2 or more single value property fields from old version plugin (etc Text Field & Select Box) to multi values field in Grid View.
Thai การรวมกริดใช้สำหรับโอนย้ายฟิลด์คุณสมบัติค่าอย่างน้อย 2 ฟิลด์ขึ้นไปจากปลั๊กอินเวอร์ชันเก่า (ฯลฯ Text Field & Select Box) ไปยังฟิลด์ค่าหลายค่าในมุมมองกริด
Combine Grid does not support 'value' attribute.
Thai การรวมกริดไม่สนับสนุนแอตทริบิวต์ 'value'
type : 'GridCombine'
Thai ประเภท: 'GridCombine'
columns : A JSON array of 'column' JSON objects which has 2 mandatory 'key' & 'label' attributes and 2 optional 'required' & 'options' attribute.
attributes andThai คอลัมน์: อาร์เรย์ JSON ของวัตถุ 'คอลัมน์' JSON ซึ่งมีแอตทริบิวต์บังคับ 2 รายการคือ 'key' & 'label'
optionalและแอตทริบิวต์ 2
attribute.ตัวเลือก'required' & 'options'
key : Identifier of this column. This value need to be same with the field 'name' that need to migrate from single value field to multiple value field.
Thai สำคัญ: ตัวระบุของคอลัมน์นี้ ค่านี้ต้องเหมือนกันกับฟิลด์ 'name' ที่ต้องย้ายจากฟิลด์ค่าเดียวไปยังหลายค่า
label : Label of the column header
Thai label: เลเบลของส่วนหัวคอลัมน์
options : Optional, an array of JSON object with 'value' and 'label' attributes. A column with 'options' attribute will display the input field as select box.
Thai ตัวเลือก: ตัวเลือกอาร์เรย์ของวัตถุ JSON ที่มีแอตทริบิวต์ 'value' และ 'label' คอลัมน์ที่มีแอตทริบิวต์ 'options' จะแสดงช่องป้อนข้อมูลเป็นกล่องที่เลือก
required : Optional, 'true' or 'false'. A grid cell with the 'required' attribute of 'row' and 'column' set to 'true' value is a mandatory field.
Thai ต้องการ: ไม่บังคับ, 'true' หรือ 'false' เซลล์กริดที่มีแอตทริบิวต์ 'required' ของ 'row' และ 'column' ตั้งค่าเป็น 'true' เป็นฟิลด์บังคับ
Code Block language js columns : [ {key : 'key', label : 'Columns'}, {key : 'value', label : 'Value', required: 'true'}, {key : 'label', label : 'Label', required: 'true'}, {key : 'width', label : 'Width', options:[ {value : '10%', label : '10%'}, {value : '20%', label : '20%'}, {value : '30%', label : '20%'}, {value : '40%', label : '20%'} ]} ]
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based
on other field value.on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Combine Grid Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Combine Grid Field เกี่ยวกับวิธีใช้ค่าของฟิลด์ชนิดนี้ในโค้ดปลั๊กอิน
Custom Scripting (New)
Thai |
---|
สคริปต์ที่กำหนดเอง (ใหม่) |
Panel | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
This is a new feature in Joget DX.
|
type : 'custom'
Thai ประเภท: 'กำหนดเอง'
script_url : A URL which will return script of the selected element.
Built-in URL isBuilt-in URL is "[CONTEXT_PATH]/web/property/json[APP_PATH]/[CLASS_PATH]" which will return the script of a plugin.
webThai script_url: URL ที่จะส่งคืนสคริปต์ขององค์ประกอบที่เลือก URL ในตัวคือ "[CONTEXT_PATH] /
which will return the script of a plugin.เว็บ / property / json [APP_PATH] / [CLASS_PATH]"
ซึ่งจะส่งคืนสคริปต์ของปลั๊กอิน
Element Select Box
Thai |
---|
องค์ประกอบเลือกกล่อง |
type : 'ElementSelect'
Thai ประเภท: 'ElementSelect'
url : A URL which will return Properties Options JSON object of the selected element. Built-in URL is "[CONTEXT_PATH]/web/property/json[APP_PATH]/getPropertyOptions" which will return the Properties Options JSON object of a plugin.
Thai url: URL ที่จะส่งคืนออบเจกต์ JSON ของตัวเลือกคุณสมบัติขององค์ประกอบที่เลือก URL ในตัวคือ "[CONTEXT_PATH] / web / property / json [APP_PATH] / getPropertyOptions" ซึ่งจะส่งคืนออบเจ็กต์ตัวเลือกคุณสมบัติ JSON ของปลั๊กอิน
keep_value_on_change : Optional, 'true' or 'false'. Used to decide whether to keep the configuration of the properties options of previous selected
element when a new element is selected.element when a new element is selected.
Thai keep_value_on_change: ไม่บังคับ, 'true' หรือ 'false' ใช้เพื่อตัดสินใจว่าจะเก็บคอนฟิกูเรชันของตัวเลือกคุณสมบัติขององค์ประกอบที่เลือกไว้ก่อนหน้านี้หรือไม่เมื่อเลือกองค์ประกอบใหม่
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Usually used for select a plugin and configure the properties of the selected plugin.
Thai มักจะใช้สำหรับเลือกปลั๊กอินและกำหนดค่าคุณสมบัติของปลั๊กอินที่เลือก
Refer to Retrieve Properties Value in Plugin - ElementSelectBox on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - ElementSelectBox เกี่ยวกับวิธีการใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
File
Thai |
---|
ไฟล์ |
type : 'file',
appPath : '[APP_PATH]',
allowInput : Optional, 'true' or 'false'. Set to 'true' to allow custom link.
isPublic : Optional, 'true' or 'false'. Set to 'true' to auto set the permission to access by anonymous.
allowType : Optional, a string of file extension seperated (;). Example: ".jpeg;.jpg;.gif;.png".
maxSize : Optional, integer value in string format. In kB.
Refer to Regular Express (Regex) Validation Attributes for extra attributes to do validation using regex.
Thai อ้างถึง Regular Express (Regex) Validation Attributes สำหรับแอตทริบิวต์เพิ่มเติมเพื่อทำการตรวจสอบความถูกต้องโดยใช้ regex
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field
type in the plugin code.type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Fixed Row Grid
Thai |
---|
แก้ไขกริดแถว |
type : 'GridFixedRow'
columns : A JSON array of 'column' JSON objects which has 2 mandatory 'key' & 'label' attributes and 2 optional 'required' & 'options' attribute.
key : Identifier of this column.
label : Label of the column header
options : Optional, an array of JSON object with 'value' and 'label' attributes. A column with 'options' attribute will display the input field as select box.
required : Optional, 'true' or 'false'. A grid cell with the 'required' attribute of 'row' and 'column' set to 'true' value is a mandatory field.
rows : A JSON array of 'row' JSON Object with 'label' attribute and an optional 'required' attribute. A grid cell with the 'required' attribute of 'row' and 'column' set to 'true' value is a mandatory field.
label : Label of a row. Used to populate in the first column or every row.
required : Optional, 'true' or 'false'. A grid cell with the 'required' attribute of 'row' and 'column' set to 'true' value is a mandatory field.
value : A JSON array of grid row values in JSON Object format with all the 'key' attribute of 'column' object used as attribute.
Code Block | ||
---|---|---|
| ||
columns : [ {key : 'key', label : 'Columns'}, // first column will used to populate row label {key : 'value', label : 'Value', required: 'true'}, {key : 'label', label : 'Label', required: 'true'}, {key : 'width', label : 'Width', options:[ {value : '10%', label : '10%'}, {value : '20%', label : '20%'}, {value : '30%', label : '20%'}, {value : '40%', label : '20%'} ]} ], rows : [ {label : 'Username', required: 'true'}, {label : 'Status'}, {label : 'Message'}, {label : 'Date'} ], value : [ {label : 'Username'}, {label : 'Status'}, {label : 'Message', width : '20%'}, {label : 'Date', value : 'dateCreated'} ] |
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Grid Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Grid Field เกี่ยวกับวิธีใช้ค่าของฟิลด์ชนิดนี้ในรหัสปลั๊กอิน
Grid
Thai |
---|
กริด |
type : 'Grid'
columns : A JSON array of 'column' JSON objects which has 2 mandatory 'key' & 'label' attributes and 2 optional 'required' & 'options' attribute.
key : Identifier of this column.
label : Label of the column header
options : Optional, an array of JSON object with 'value' and 'label' attributes. A column with 'options' attribute will display the input field as select box.
required : Optional, 'true' or 'false'. A grid cell with the 'required' attribute of 'row' and 'column' set to 'true' value is a mandatory field.
value : A JSON array of grid row values in JSON Object format with all the 'key' attribute of 'column' object used as attribute.
Code Block language js columns : [ {key : 'value', label : 'Value', required: 'true'}, {key : 'label', label : 'Label', required: 'true'}, {key : 'width', label : 'Width', options:[ {value : '10%', label : '10%'}, {value : '20%', label : '20%'}, {value : '30%', label : '20%'}, {value : '40%', label : '20%'} ]} ], value : [ {label : 'Username', value : 'username'}, {label : 'Status', value : 'status'}, {label : 'Message', value : 'message', width : '20%'}, {label : 'Date', value : 'dateCreated'} ]
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Grid Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Grid Field เกี่ยวกับวิธีใช้ค่าของฟิลด์ชนิดนี้ในรหัสปลั๊กอิน
Header
Thai |
---|
หัวข้อ |
type : 'Header'
Header does not support 'value' and 'required' attributes.
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
This field type is used for separate the fields into different groups. It is not use for capture data.
Thai ประเภทฟิลด์นี้ใช้สำหรับแยกฟิลด์ออกเป็นกลุ่มต่าง ๆ มันไม่ได้ใช้สำหรับการจับข้อมูล
Hidden Field
Thai |
---|
ซ่อนฟิลด์ |
type : 'Hidden'
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
HTML Editor
Thai |
---|
ตัวแก้ไข HTML |
type : 'HtmlEditor'
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Image
Thai |
---|
ภาพ |
type : 'file',
appPath : '[APP_PATH]',
allowInput : Optional, 'true' or 'false'. Set to 'true' to allow custom link.
isPublic : Optional, 'true' or 'false'. Set to 'true' to auto set the permission to access by anonymous.
allowType : Optional, a string of file extension seperated (;). Example: ".jpeg;.jpg;.gif;.png".
maxSize : Optional, integer value in string format. In kB.
imageSize : Optional, can be integer value in string format or a css expression. Example: '50' or "width:100px;height:70px;".
Refer to Regular Express (Regex) Validation Attributes for extra attributes to do validation using regex.
Thai อ้างถึง Regular Express (Regex) Validation Attributes สำหรับแอตทริบิวต์เพิ่มเติมเพื่อทำการตรวจสอบความถูกต้องโดยใช้ regex
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other
field value.field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Label
Thai |
---|
ป้าย |
type : 'Label'
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Multi Select Box
Thai |
---|
กล่องเลือกหลายตัว |
type : 'MultiSelect'
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Multi Values Field on how to use the value of this field type in the plugin code.
Thai อ้างถึง Retrieve Properties Value in Plugin - Multi Values Field เกี่ยวกับวิธีใช้ค่าของฟิลด์ชนิดนี้ในรหัสปลั๊กอิน
Password Field
Thai |
---|
ฟิลด์รหัสผ่าน |
type : 'Password'
size : Optional, integer value in string format. Default to '50'. Used to control the length of the input field.
maxlength : Optional, integer value in string format. Used to limit the number of characters can be enter in the input field.
Refer to Regular Express (Regex) Validation Attributes for extra attributes to do validation using regex.
Thai อ้างถึง Regular Express (Regex) Validation Attributes สำหรับแอตทริบิวต์เพิ่มเติมเพื่อทำการตรวจสอบความถูกต้องโดยใช้ regex
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Radio Button
Thai |
---|
ปุ่มตัวเลือก |
type : 'Radio'
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Readonly Text Field
Thai |
---|
ช่องข้อความแบบอ่านอย่างเดียว |
type : 'Readonly'
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other
field value.field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Multiselect in Grid Interface (New)
Thai |
---|
เลือกได้หลายแบบในส่วนต่อประสานกริด (ใหม่) |
Panel | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
This is a new feature in Joget DX.
|
type : 'elementmultiselect'
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Number (New)
Thai |
---|
หมายเลข (ใหม่) |
Panel | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
| ||||||||||
This is a new feature in Joget DX.
|
type : 'elementmultiselect'
Select Box
Thai |
---|
เลือกกล่อง |
type : 'SelectBox'
Refer to Option Field Attributes for extra attributes.
Thai อ้างถึง Option Field Attributes สำหรับแอตทริบิวต์เพิ่มเติม
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin
code.code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Text Area
Thai |
---|
พื้นที่ข้อความ |
type : 'TextArea'
rows : Optional, integer value in string format. Default to '5'. Used to control the height of the input field.
cols : Optional, integer value in string format. Default to '50'. Used to control the length of the input field.
Refer to Regular Express (Regex) Validation Attributes for extra attributes to do validation using regex.
Thai อ้างถึง Regular Express (Regex) Validation Attributes สำหรับแอตทริบิวต์เพิ่มเติมเพื่อทำการตรวจสอบความถูกต้องโดยใช้ regex
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Text Field
Thai |
---|
ช่องข้อความ |
type : 'TextField'
size : Optional, integer value in string format. Default to '50'. Used to control the length of the input field.
maxlength : Optional, integer value in string format. Used to limit the number of characters can be enter in the input field.
Refer to Regular Express (Regex) Validation Attributes for extra attributes to do validation using regex.
Thai อ้างถึง Regular Express (Regex) Validation Attributes สำหรับแอตทริบิวต์เพิ่มเติมเพื่อทำการตรวจสอบความถูกต้องโดยใช้ regex
Refer to Dependency Field Attributes for extra attributes to do show/hide this field based on other field value.
Thai อ้างถึง Dependency Field Attributes สำหรับแอททริบิวพิเศษที่ต้องแสดง / ซ่อนฟิลด์นี้ตามค่าฟิลด์อื่น
Refer to Retrieve Properties Value in Plugin - Single Value Field on how to use the value of this field type in the
plugin code.plugin code.
Thai อ้างอิงถึง Retrieve Properties Value in Plugin - Single Value Field เกี่ยวกับวิธีใช้ค่าของฟิลด์นี้พิมพ์ในรหัสปลั๊กอิน
Regular Express (Regex) Validation Attributes
Thai |
---|
แอตทริบิวต์การตรวจสอบความถูกต้องแบบด่วน (Regex) |
The following attributes are designed for Auto Complete, Password Field, Text Area and Text Field.
Thai คุณลักษณะต่อไปนี้ได้รับการออกแบบมาสำหรับ Auto Complete, Password Field, Text Area และ Text Field
regex_validation : Optional, regular express in string format.
validation_message : Optional, error message to display when validation failure.
Code Block | ||
---|---|---|
| ||
{ regex_validation : '^[a-zA-Z0-9_]+$', validation_message : 'Invalid ID!!' } |
Dependency Field Attributes
Thai |
---|
คุณสมบัติของฟิลด์ |
The following attributes are available for all field types.
Thai แอททริบิวต่อไปนี้ใช้ได้กับฟิลด์ทุกประเภท
These attributes are used to show/hide a field based on the value of another field.
Thai แอ็ตทริบิวต์เหล่านี้ใช้เพื่อแสดง / ซ่อนฟิลด์ตามค่าของฟิลด์อื่น
The value of a field hidden by these attributes will be ignore during save.
Thai ค่าของฟิลด์ที่ถูกซ่อนโดยแอตทริบิวต์เหล่านี้จะถูกละเว้นในระหว่างการบันทึก
control_field : Optional, 'name' of another field used to control the show/hide of current field.
control_value : Optional, value or regular expression (regex) in string format. This value need to match the value of the controlling field in order to make the field visible.
control_use_regex : Optional, 'true' or 'false'. Default to 'false'. Set to 'true' to use regular expression (regex) in matching the value.
Code Block | ||
---|---|---|
| ||
{
control_field: 'chartType',
control_value: 'bar|xy|area|bubble|line|candlestick|ohlc',
control_use_regex: 'true',
} |
Options Field Attributes
,
} |
Options Field Attributes
Thai |
---|
คุณสมบัติฟิลด์ตัวเลือก |
The following attributes are designed for options fields like Auto Complete, Check Box, Element Select Box, Multi Select Box, Radio Button and Select Box.
The following attributes are designed for options fields likeThai แอททริบิวต่อไปนี้ได้รับการออกแบบสำหรับฟิลด์ตัวเลือกเช่น
andAuto Complete, Check Box, Element Select Box, Multi Select Box, Radio Button
.และ Select Box
You can choose to use one of the following attributes "options", "options_ajax", "options_callback" or "options_script" to populate the options for the field.
Thai คุณสามารถเลือกใช้หนึ่งในแอตทริบิวต์ "options", "options_ajax", "options_callback" หรือ "options_script" ต่อไปนี้เพื่อเติมข้อมูลตัวเลือกสำหรับฟิลด์
options : Optional, an array of JSON object with 'value' and 'label' attributes.
Code Block | ||
---|---|---|
| ||
options : [ {value: 'value1', label : 'Value 1'}, {value: 'value2', label : 'Value 2'}, {value: 'value3', label : 'Value 3'} ] |
options_ajax : Optional, a URL which will return an array of JSON object with 'value' and 'label' attributes.
Code Block | ||
---|---|---|
| ||
options_ajax : '[CONTEXT_PATH]/web/json/console/app[APP_PATH]/datalist/options' |
options_ajax_on_change : Optional, name of a property field. Used together with 'options_ajax' attribute. The field name and its value will passed as HTTP request parameter to the URL.
Code Block | ||
---|---|---|
| ||
options_ajax_on_change : 'type' options_ajax : '[CONTEXT_PATH]/web/json/app[APP_PATH]/plugin/org.joget.plugin.enterprise.SamplePlugin/service?action=getJson' |
options_callback : Optional, a javascript function name. All attributes in the field will passed as a single JSON object parameter to this function. The function should return an array of JSON object with 'value' and 'label' attributes.
Code Block | ||
---|---|---|
| ||
options_callback: 'DatalistBuilder.getColumnOptions' |
options_script : Optional, a string of javascript which will return an array of JSON object with 'value' and 'label' attributes.
Code Block | ||
---|---|---|
| ||
options_script: 'var tempArray = [{\'label\':\'\',\'value\':\'\'}]; for(ee in DatalistBuilder.availableColumns){ var temp = { \'label\' : UI.escapeHTML(DatalistBuilder.availableColumns[ee].label), \'value\' : DatalistBuilder.availableColumns[ee].id}; tempArray.push(temp);}tempArray;' |
...
DatalistBuilder.getColumnOptions(properties)
Can be used by plugins related to Datalist Builder. It return all available columns based on binder configuration.Thai สามารถใช้โดยปลั๊กอินที่เกี่ยวข้องกับตัวสร้างดาต้าลิสต์ กลับคอลัมน์ทั้งหมดที่มีอยู่ตามการกำหนดค่า binder
Validator Types
Thai |
---|
ประเภทตัวตรวจสอบความถูกต้อง |
Page validator is execute during change page.
Thai ตัวตรวจสอบความถูกต้องของหน้าถูกเรียกใช้งานระหว่างหน้าการเปลี่ยนแปลง
All fields data in the same page will pass to the validator for validation.
Thai ข้อมูลฟิลด์ทั้งหมดในหน้าเดียวกันจะถูกส่งไปยังเครื่องมือตรวจสอบความถูกต้อง
AJAX
Call to a URL for validation.
Thai เรียกไปที่ URL เพื่อตรวจสอบความถูกต้อง
type : 'AJAX'
url : An URL return a JSON Object with status (success or fail) & message (JSONArray of String) attribute
default_error_message : Optional. A string of error message.
Page Button
Thai |
---|
ปุ่มหน้า |
Page button can be added on the bottom of each page to provide extra feature. Such as send an test email to test the email configuration or make a test connection to database.
Thai สามารถเพิ่มปุ่มหน้าได้ที่ด้านล่างของแต่ละหน้าเพื่อให้มีคุณสมบัติพิเศษ เช่นส่งอีเมลทดสอบเพื่อทดสอบการกำหนดค่าอีเมลหรือทำการเชื่อมต่อทดสอบกับฐานข้อมูล
Page button will collect the required fields data from the page and popup dialog and call an AJAX URL.
Thai ปุ่มหน้าจะรวบรวมข้อมูลฟิลด์ที่ต้องการจากหน้าและกล่องโต้ตอบป๊อปอัพและเรียก AJAX URL
name : Identifier of this button.
label : Label of the button.
ajax_url : A URL to execute the button action. The URL should return a JSON Object with message (String) attribute.
fields : An array of fields name in the same page that will be used by this button.
addition_fields : An array of Property Field JSON object that will be shown in a popup dialog to collect extra data.
Example:
Thai ตัวอย่าง:
Code Block language js buttons : [{ name : 'testmail', label : 'Send Test Email', ajax_url : '[CONTEXT_PATH]/web/json/app[APP_PATH]/plugin/org.joget.apps.app.lib.EmailTool/service?action=testmail', fields : ['host', 'port', 'security', 'username', 'password'], addition_fields : [ { name : 'from', label : 'From', type : 'textfield', required : 'True' }, { name : 'toSpecific', label : 'To', type : 'textfield', required : 'True' } ] }]
Variable
Thai |
---|
ตัวแปร |
[CONTEXT_PATH]
This variable will be replaced by Context Path of current URL.
Thai ตัวแปรนี้จะถูกแทนที่ด้วยเส้นทางของ URL ปัจจุบัน
Usually used in property attribute value which is URL
Thai มักใช้ในค่าคุณสมบัติคุณสมบัติซึ่งเป็น URL
Example : '[CONTEXT_PATH]/web/property/json/getElements?classname=org.joget.apps.form.model.FormValidator'
Resulted URL : '/jw/web/property/json/getElements?classname=org.joget.apps.form.model.FormValidator'
[APP_PATH]
This variable will be replaced by Current App Id and App Version of current URL.
Thai ตัวแปรนี้จะถูกแทนที่ด้วยรหัสแอปปัจจุบันและเวอร์ชันแอปของ URL ปัจจุบัน
Usually used in property attribute value which is URL
Thai มักใช้ในค่าคุณสมบัติคุณสมบัติซึ่งเป็น URL
Example : '[CONTEXT_PATH]/web/json/console/app[APP_PATH]/datalist/options'
Resulted URL : '/jw/web/json/console/app/crm/3/datalist/options'
Retrieve Properties Value in Plugin
Thai |
---|
ดึงค่าคุณสมบัติในปลั๊กอิน |
All the plugin must extends the "org.joget.plugin.base.ExtDefaultPlugin" abstract class. We can use the "Object getProperty(String)" and "String getPropertyString(String)" method to retrieve the configured properties.
Thai ปลั๊กอินทั้งหมดจะต้องขยายคลาสนามธรรม "org.joget.plugin.base.ExtDefaultPlugin" เราสามารถใช้วิธี "Object getProperty (String)" และ "String getPropertyString (String)" วิธีการเพื่อดึงคุณสมบัติที่กำหนดค่าไว้
Single Value Field
Thai |
---|
เขตข้อมูลค่าเดียว |
Code Block | ||
---|---|---|
| ||
String value = getPropertyString("property_name"); |
Multi Values Field
Thai |
---|
ฟิลด์ค่าหลายค่า |
Code Block | ||
---|---|---|
| ||
String[] values = getPropertyString("property_name").split(";"); |
Combine Grid Field
Thai |
---|
รวมเขตข้อมูลกริด |
Code Block | ||
---|---|---|
| ||
String[] col1_values = getPropertyString("col1_name").split(";"); String[] col2_values = getPropertyString("col2_name").split(";"); |
Grid Field
Thai |
---|
ฟิลด์กริด |
Code Block | ||
---|---|---|
| ||
Object columns = getProperty("property_name"); if (columns != null) { for (Object colObj : (Object[]) columns) { Map col = (Map) colObj; String col1_value = (String) opt.get("col1_key"); String col2_value = (String) opt.get("col2_key"); } } |
Element Select Box
Thai |
---|
องค์ประกอบเลือกกล่อง |
Code Block | ||
---|---|---|
| ||
import org.joget.plugin.base.PluginManager; import org.joget.apps.app.service.AppUtil; import org.joget.plugin.base.ExtDefaultPlugin; Object element = getProperty("property_name"); if (element != null && element instanceof Map) { Map elementMap = (Map) element; String className = (String) elementMap.get("className"); Map<String, Object> properties = (Map<String, Object>) elementMap.get("properties"); //convert it to plugin PluginManager pm = (PluginManager) AppUtil.getApplicationContext().getBean("pluginManager"); ExtDefaultPlugin plugin = (ExtDefaultPlugin) pm.getPlugin(className); if (plugin != null) { plugin.setProperties(properties); } } |