If you encounter problems during use, it is recommended to seek help in the following order:
Go to the official documentation page, click the search box, enter the problem keyword, and press Enter
We have prepared several applications of typical scenarios, you can refer to the source code of these applications.
Application | Type | Warehouse Address |
---|---|---|
YAO WMS | Business System | https://github.com/yaoapp/yao-wms |
LMS DEMO | Business System | https://github.com/yaoapp/demo-lms |
CRM DEMO | Business System | https://github.com/YaoApp/demo-crm |
AMS DEMO | Business System | https://github.com/YaoApp/demo-asset |
Widget DEMO | Low-Code Platform | https://github.com/YaoApp/demo-widget |
Component example:
https://github.com/YaoApp/xiang-app/blob/main/tables/service.json
We try our best to improve the relevant documents, but there are inevitably omissions and mistakes in the documents, and some newly added function documents will also be omitted.
You can check the corresponding usage by reading the source code of Yao or Gou.
For example, to query the parameters of the process xiang.helper.PasswordValidate
, you can view the parameter list and return value by reading the unit test source code.
func TestProcessPassword(t *testing.T) {pwd := "U123456p+"hash := "$2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2"args := []interface{}{pwd, hash}process := gou.NewProcess("xiang.helper.PasswordValidate", args...)res := process.Run()assert.True(t, res.(bool))args = []interface{}{pwd, "123456"}process = gou.NewProcess("xiang.helper.PasswordValidate", args...)assert.Panics(t, func() {process.Run()})}
By testing the code, we can see that the process xiang.helper.PasswordValidate
Parameters Table:
parameter | type | example |
---|---|---|
args[0] | string | U123456p+ |
args[1] | string | $2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2 |
return value:
bool
returns true
for correct password, false
for incorrect password
Create a test data flow flows/validate.flow.json
{"label": "Validate Test","version": "1.0.0","description": "Test","nodes": [{"name": "test","process": "xiang.helper.PasswordValidate","args": ["{{$in.0}}","$2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2"]}],"output": "{{$res.test}}"}
test:
yao run flows.validate "U123456p+"
Create a test script scripts/test.js
function Validate(password) {let hash = "$2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2";return Process("xiang.helper.PasswordValidate", password, hash);}
test:
yao run scripts.test.Validate "U123456p+"
Enter the YAO project repository Issues, enter the issue keyword in the search box, and press Enter
Enter the YAO project repository Issues, click the New issue button, and ask a question
Enter the subject and content of the question.
In order to get a better reply faster, it is recommended to state in the problem description:
Join the YAO development exchange group and ask questions in the WeChat group.
Add 17192175099
as a friend on WeChat, note (YAO development exchange)
If you encounter problems during use, it is recommended to seek help in the following order:
Go to the official documentation page, click the search box, enter the problem keyword, and press Enter
We have prepared several applications of typical scenarios, you can refer to the source code of these applications.
Application | Type | Warehouse Address |
---|---|---|
YAO WMS | Business System | https://github.com/yaoapp/yao-wms |
LMS DEMO | Business System | https://github.com/yaoapp/demo-lms |
CRM DEMO | Business System | https://github.com/YaoApp/demo-crm |
AMS DEMO | Business System | https://github.com/YaoApp/demo-asset |
Widget DEMO | Low-Code Platform | https://github.com/YaoApp/demo-widget |
Component example:
https://github.com/YaoApp/xiang-app/blob/main/tables/service.json
We try our best to improve the relevant documents, but there are inevitably omissions and mistakes in the documents, and some newly added function documents will also be omitted.
You can check the corresponding usage by reading the source code of Yao or Gou.
For example, to query the parameters of the process xiang.helper.PasswordValidate
, you can view the parameter list and return value by reading the unit test source code.
func TestProcessPassword(t *testing.T) {pwd := "U123456p+"hash := "$2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2"args := []interface{}{pwd, hash}process := gou.NewProcess("xiang.helper.PasswordValidate", args...)res := process.Run()assert.True(t, res.(bool))args = []interface{}{pwd, "123456"}process = gou.NewProcess("xiang.helper.PasswordValidate", args...)assert.Panics(t, func() {process.Run()})}
By testing the code, we can see that the process xiang.helper.PasswordValidate
Parameters Table:
parameter | type | example |
---|---|---|
args[0] | string | U123456p+ |
args[1] | string | $2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2 |
return value:
bool
returns true
for correct password, false
for incorrect password
Create a test data flow flows/validate.flow.json
{"label": "Validate Test","version": "1.0.0","description": "Test","nodes": [{"name": "test","process": "xiang.helper.PasswordValidate","args": ["{{$in.0}}","$2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2"]}],"output": "{{$res.test}}"}
test:
yao run flows.validate "U123456p+"
Create a test script scripts/test.js
function Validate(password) {let hash = "$2a$04$TS/rWBs66jADjQl8fa.w..ivkNAjH8d4sI1OPGvEB9Leed6EpzIF2";return Process("xiang.helper.PasswordValidate", password, hash);}
test:
yao run scripts.test.Validate "U123456p+"
Enter the YAO project repository Issues, enter the issue keyword in the search box, and press Enter
Enter the YAO project repository Issues, click the New issue button, and ask a question
Enter the subject and content of the question.
In order to get a better reply faster, it is recommended to state in the problem description:
Join the YAO development exchange group and ask questions in the WeChat group.
Add 17192175099
as a friend on WeChat, note (YAO development exchange)