6 Specific interface for specified field type (limit specified field type available)

1 extension browse button number interface parameter value

Limit condition: only applicable to non-date browse button type

Scenario: control browse button optional data range, limit range, dependent form field filter data range, etc.; for Lenovo input range and pop-up window selection range;

Implementation: interface expansion parameters will be submitted to the server interface through url parameters, need to modify the browse button interface class to take effect

appendBrowserDataUrlParam:function (field Mark, jsonParam)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field

jsonParam

JSON

Yes

url

 WfForm.appendBrowserDataUrlParam("field395",{"customerid ":"2"});
 // Add url parameter customerid to browse button 395 when requesting background data

2 Gets the display valye for browser buttom

Limit condition: Only for Non-date browse button only

Get multiple browse button value, split string with splitChar

getBrowserShowName:function(fieldMark, splitChar)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

splitChar

String

No

delimiter, separated by comma by default

 WfForm.getBrowserShowName("field110");
 // Gets a comma-separated browse button field display value

3 Remove the option value from slection box

Limit condition: Only for selection box

removeSelectOption:function only (fieldMark, optionkeys)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

optionKeys

String

Yes

Option options key values to be removed, multiple separated by commas

 WfForm.removeSelectOption("field112","3,4");
 // Removes the option in id selection box with a value of 3/4ja

4 Control selection box field option

Limit condition: Only for selection box

controlSelectOption:function only (fieldMark, optionkeys)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

optionKeys

String

Yes

Fully control the range of options in the selection box

WfForm.controlSelectOption("field112","1,2,4");
// The control selection box shows only 1/2/4 options
WfForm.controlSelectOption("field112","");
// Clear all options in the box

5 Gets the display value of the selection box

Limit condition: Only for selection box

Get multiple selection box value, split string with splitChar

getSelectShowName:function(fieldMark, splitChar)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

splitChar

String

No

Separator, separated by comma by default (used only with multiple checkboxes)

 WfForm.getSelectShowName("field110_3");
 // Gets the value displayed in the field of the selection box

6 When text field is editable, if empty value display default gray prompt, mouse click input prompt disappear

Limit condition: only for single line text, integer, floating, multi-line text field (non-html) field type; support main field and detail field

setTextFieldEmptyShowContent:function (fieldMark, showContent)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

showContent

String

Yes

Hint information displayed when null, gray

jQuery(document).ready(function(){
 WfForm.setTextFieldEmptyShowContent("field 27555"," single text default prompt information 1");
 WfForm.setTextFieldEmptyShowContent("field 27566"," Multi-text default prompt 2");
 WfForm.setTextFieldEmptyShowContent("field222_0"," detail field prompt information ");
 // need to be used in conjunction with additional row events in interface 5.9
});

7 The props override browse button component

Supports only the browse button type, please use carefully, will completely overrides the browse button props

only passes props, the specific passed properties implement what requirements are controlled by internal function

overrideBrowserProp: function(fieldMark,jsonParam)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

jsonParam

JSON

Yes

Extending or copying props parameters

Example WfForm.overrideBrowserProp("field111"){
 onBeforeFocusCheck:function (success, failure){/***/}
});// Copy the props of the Browse button field 111

8 Control Date Browse button date range

Minimum version: KB900190501

Only support date type, control manual selection of date range

controlDateRange:function (fieldMark, start, end)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

field designation, format field${ field ID}_field${ line number}

start

String

Yes

Support for two formats, the first standard date format, such as 2019-05-28, the second integer, how many days before / after the current date

end

String No

Format and start parameters consistent

Example WfForm.controlDateRange("field111",-5,10);
// Limit the optional range of dates, five days forward and 10 days later
WfForm.controlDateRange("field111",0,'2019-12-31');
// Limit today to this year
WfForm.controlDateRange("field222_0",'2019-05-01','2019-05-31');
// detail field, limiting the month

9 Control whether radio button printing only shows select text

Minimum version: KB900190501

only supports single line text box in the selection box, the printing scnario, whether only the selected text is displayed, and the display empty if no selected

controlRadioPrintText: function(fieldid)

Parameter Description

ParametertypeRequiredRemarks

fieldMark

String

Yes

fields id, format ${fields ID}, support detail fields

Example

WfForm.controlRadioPrintText("12580");
// radio field 12580 print text

Last updated