refactor: billing - use Form title, Tabular always present, form submit loadData via script
This commit is contained in:
parent
6d3dcf2db9
commit
8d447b90ea
@ -1,5 +1,3 @@
|
|||||||
{% set start_date = params_kw.get('start_date', '') %}
|
|
||||||
{% set end_date = params_kw.get('end_date', '') %}
|
|
||||||
{
|
{
|
||||||
"widgettype":"VBox",
|
"widgettype":"VBox",
|
||||||
"id":"billing_page",
|
"id":"billing_page",
|
||||||
@ -11,33 +9,19 @@
|
|||||||
},
|
},
|
||||||
"subwidgets":[
|
"subwidgets":[
|
||||||
{
|
{
|
||||||
"widgettype":"Title6",
|
"widgettype":"Form",
|
||||||
"options":{
|
"options":{
|
||||||
"text":"账单查询"
|
"title":"账单查询",
|
||||||
}
|
"fields":[
|
||||||
},
|
|
||||||
{
|
|
||||||
"widgettype":"VBox",
|
|
||||||
"options":{
|
|
||||||
"width":"100%",
|
|
||||||
"height":"60px"
|
|
||||||
},
|
|
||||||
"subwidgets":[
|
|
||||||
{
|
|
||||||
"widgettype":"Form",
|
|
||||||
"options":{
|
|
||||||
"fields":[
|
|
||||||
{
|
{
|
||||||
"name":"start_date",
|
"name":"start_date",
|
||||||
"label":"开始日期",
|
"label":"开始日期",
|
||||||
"uitype":"date",
|
"uitype":"date"
|
||||||
"value":"{{start_date}}"
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name":"end_date",
|
"name":"end_date",
|
||||||
"label":"结束日期",
|
"label":"结束日期",
|
||||||
"uitype":"date",
|
"uitype":"date"
|
||||||
"value":"{{end_date}}"
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"buttons":[
|
"buttons":[
|
||||||
@ -52,29 +36,22 @@
|
|||||||
{
|
{
|
||||||
"wid":"self",
|
"wid":"self",
|
||||||
"event":"submit",
|
"event":"submit",
|
||||||
"actiontype":"urlwidget",
|
"actiontype":"script",
|
||||||
"target":"billing_page",
|
"target":"billing_tabular",
|
||||||
"options":{
|
"options":{
|
||||||
"url":"{{entire_url('/accounting/billing.ui')}}"
|
"script":"this.loadData(params)"
|
||||||
},
|
}
|
||||||
"mode":"replace"
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
},
|
||||||
]
|
{
|
||||||
}
|
|
||||||
{% if start_date and end_date %}
|
|
||||||
,{
|
|
||||||
"widgettype":"Tabular",
|
"widgettype":"Tabular",
|
||||||
|
"id":"billing_tabular",
|
||||||
"options":{
|
"options":{
|
||||||
"width":"100%",
|
"width":"100%",
|
||||||
"height":"100%",
|
"height":"100%",
|
||||||
"css":"filler",
|
"css":"filler",
|
||||||
"data_url":"{{entire_url('/accounting/billing.dspy')}}",
|
"data_url":"{{entire_url('/accounting/billing.dspy')}}",
|
||||||
"data_params":{
|
|
||||||
"start_date":"{{start_date}}",
|
|
||||||
"end_date":"{{end_date}}"
|
|
||||||
},
|
|
||||||
"editable":false,
|
"editable":false,
|
||||||
"page_rows":80,
|
"page_rows":80,
|
||||||
"cache_limit":3,
|
"cache_limit":3,
|
||||||
@ -157,6 +134,5 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
{% endif %}
|
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user