{% set start_date = params_kw.get('start_date', '') %} {% set end_date = params_kw.get('end_date', '') %} { "widgettype":"VBox", "options":{ "width":"100%", "css":"card", "cwidth":30, "gap":"8px" }, "subwidgets":[ { "widgettype":"Title6", "options":{ "text":"账单查询" } }, { "widgettype":"Form", "options":{ "fields":[ { "name":"start_date", "label":"开始日期", "uitype":"date", "value":"{{start_date}}" }, { "name":"end_date", "label":"结束日期", "uitype":"date", "value":"{{end_date}}" } ], "buttons":[ { "name":"query", "label":"查询", "bgcolor":"#1890ff" } ] }, "binds":[ { "wid":"self", "event":"submit", "actiontype":"urlwidget", "target":"self", "options":{ "url":"{{entire_url('/accounting/billing.ui')}}" } } ] } {% if start_date and end_date %} ,{ "widgettype":"DataViewer", "options":{ "data_url":"{{entire_url('/accounting/billing.dspy')}}", "data_params":{ "start_date":"{{start_date}}", "end_date":"{{end_date}}" }, "editable":false, "page_size":30 } } {% endif %} ] }