This commit is contained in:
yumoqing 2024-04-12 14:05:13 +08:00
parent 127882d669
commit 16c8ed4c70
3 changed files with 26 additions and 22 deletions

View File

@ -94,7 +94,8 @@ bricks.TabPanel = class extends bricks.Layout {
this.cur_tab_name = name; this.cur_tab_name = name;
return; return;
} }
w = await bricks.widgetBuild(items[i].content); try {
w = await bricks.widgetBuild(items[i].content, this, {});
if (! w){ if (! w){
bricks.debug('TabPanel():create content error', items[i].content); bricks.debug('TabPanel():create content error', items[i].content);
return; return;
@ -105,6 +106,10 @@ bricks.TabPanel = class extends bricks.Layout {
this.cur_tab_name = tdesc.name; this.cur_tab_name = tdesc.name;
return; return;
} }
catch (e) {
console.log('except ', e)
}
}
} }
bricks.debug('TabPanel(): click event handled but noting to do', tdesc) bricks.debug('TabPanel(): click event handled but noting to do', tdesc)
} }

View File

@ -64,20 +64,19 @@
"uitype":"email", "uitype":"email",
"name":"email", "name":"email",
"label":"Email", "label":"Email",
'required':true "required":true
}, },
{ {
"uitype":"tel", "uitype":"tel",
"name":"tel", "name":"tel",
"pattern":"{\d}3-{\d}4-{\d}4",
"label":"Tel", "label":"Tel",
'required':true "required":true
}, },
{ {
"uitype":"file", "uitype":"file",
"name":"file", "name":"file",
"label":"File", "label":"File",
'required':true "required":true
}, },
{ {
"uitype":"str", "uitype":"str",
@ -86,7 +85,7 @@
"value":"tlegre", "value":"tlegre",
"name":"name", "name":"name",
"label":"Name", "label":"Name",
'required':true "required":true
}, },
{ {
"uitype":"int", "uitype":"int",
@ -95,7 +94,7 @@
"value":12432, "value":12432,
"name":"integer", "name":"integer",
"label":"Integer", "label":"Integer",
'required':true "required":true
}, },
{ {
"uitype":"float", "uitype":"float",
@ -108,7 +107,7 @@
"uitype":"date", "uitype":"date",
"name":"date", "name":"date",
"label":"Date", "label":"Date",
'required':true "required":true
}, },
{ {
"uitype":"password", "uitype":"password",
@ -116,7 +115,7 @@
"length":30, "length":30,
"name":"password", "name":"password",
"label":"Password", "label":"Password",
'required':true "required":true
}, },
{ {
"uitype":"checkbox", "uitype":"checkbox",
@ -125,7 +124,7 @@
"label":"CheckBox", "label":"CheckBox",
"value":2, "value":2,
"dataurl":"test_code.json", "dataurl":"test_code.json",
'required':true "required":true
}, },
{ {
"uitype":"code", "uitype":"code",
@ -133,14 +132,14 @@
"label":"Code", "label":"Code",
"value":2, "value":2,
"dataurl":"test_code.json", "dataurl":"test_code.json",
'required':true "required":true
}, },
{ {
"uitype":"text", "uitype":"text",
"name":"text", "name":"text",
"value":"This is a test", "value":"This is a test",
"label":"Text", "label":"Text",
'required':true "required":true
}, },
{ {
"uitype":"audiotext", "uitype":"audiotext",
@ -148,7 +147,7 @@
"name":"atext", "name":"atext",
"value":"This is a test", "value":"This is a test",
"label":"Text", "label":"Text",
'required':true "required":true
} }
] ]
} }

View File

@ -47,9 +47,9 @@
"name":"python", "name":"python",
"label":"Python", "label":"Python",
"content":{ "content":{
"widgettype":"Text", "widgettype":"urlwidget",
"options":{ "options":{
"text":"This is Python language documents" "url":"{{entire_url('form.ui')}}"
} }
}, },
"icon":null "icon":null