from dash import dcc, html import feffery_antd_components as fac import callbacks.dasset_c.nfddict_data_c from api.fddict import get_fddict_list_api from api.ndstand import get_all_ndstand_api def render(button_perms): # # 获取fddict_col_no=cd00005的数据 # print(777,button_perms) # data1 = get_all_ndstand_api({}) # #print(777,data1) # query_params = dict( # fddict_col_no='cd00005', # page_num=1, # page_size=10 # ) table_data=[] # table_info = get_fddict_list_api(query_params) #table_data = table_info['data']['rows'] return [ dcc.Store(id='nfddict_data-button-perms-container', data=button_perms), fac.AntdRow( [ fac.AntdCol( [ # fac.AntdRow( # [ # fac.AntdCol( # html.Div( # [ # fac.AntdForm( # [ # fac.AntdFormItem( # fac.AntdInput( # id='nfddict_data-fddict_col_cn-input', # placeholder='代码中文名称', # #options=[], # allowClear=False, # style={ # 'width': 240 # } # ), # label='代码中文名称', # style={'paddingBottom': '10px'}, # ), # fac.AntdFormItem( # fac.AntdInput( # id='nfddict_data-fddict_col_no-input', # placeholder='代码编号', # allowClear=False, # style={ # 'width': 240 # } # ), # label='代码编号', # style={'paddingBottom': '10px'}, # ), # fac.AntdFormItem( # fac.AntdButton( # '搜索', # id='nfddict_data-search', # type='primary', # icon=fac.AntdIcon( # icon='antd-search' # ) # ), # style={'paddingBottom': '10px'}, # ), # fac.AntdFormItem( # fac.AntdButton( # '重置', # id='nfddict_data-reset', # icon=fac.AntdIcon( # icon='antd-sync' # ) # ), # style={'paddingBottom': '10px'}, # ) # ], # layout='inline', # ) # ], # id='nfddict_data-search-form-container', # hidden=False # ), # ) # ] # ), fac.AntdRow( [ fac.AntdCol( fac.AntdSpin( fac.AntdTable( id='nfddict_data-list-table', data=table_data, columns=[ { 'dataIndex': 'fddict_col_no', 'title': '代码编号', 'renderOptions': { 'renderType': 'ellipsis' }, }, { 'dataIndex': 'fddict_col_cn', 'title': '代码中文名称', 'renderOptions': { 'renderType': 'ellipsis' }, }, { 'dataIndex': 'fddict_code', 'title': '代码码值', 'renderOptions': { 'renderType': 'ellipsis' }, }, { 'dataIndex': 'fddict_name', 'title': '码值说明', 'renderOptions': { 'renderType': 'ellipsis' }, }, { 'dataIndex': 'fddict_col_en', 'title': '代码别名', 'renderOptions': { 'renderType': 'ellipsis' }, }, { 'dataIndex': 'fddict_sort', 'title': '码值排序', 'renderOptions': { 'renderType': 'ellipsis' }, }, { 'dataIndex': 'remark', 'title': '业务描述', 'width': 280, 'renderOptions': { 'renderType': 'ellipsis' }, } ], #rowSelectionType='checkbox', rowSelectionWidth=50, bordered=True, maxWidth=1000, pagination={ 'pageSize': 10, 'current': 1, 'showSizeChanger': True, 'pageSizeOptions': [30,80,150], 'showQuickJumper': True, 'total': 0 }, mode='server-side', style={ 'width': '100%', 'padding-right': '10px' } ), text='数据加载中' ), ) ] ), ], span=24 ) ], gutter=5 ), ]