Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: Added csv file download function and updated package
- Added dcc.Download component and callback process for downloading CSV files. - Updated package and pyproject.toml(version 0.1.0 -> 0.2.0). - Added static analysis tool for development.
- Loading branch information
1 parent
15864f9
commit 0182d8a
Showing
7 changed files
with
748 additions
and
394 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# dev | ||
.DS_Store | ||
.venv | ||
|
||
# python cache | ||
*.pyc | ||
__pycache__/ | ||
|
||
# static code analysis | ||
.mypy_cache/ | ||
.pytest_cache/ | ||
.coverage | ||
htmlcov/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,35 @@ | ||
from typing import List | ||
import pandas as pd | ||
|
||
|
||
class DfManage: | ||
def __init__(self): | ||
self.__data = [] | ||
self.__df_data = pd.DataFrame(self.__data) | ||
data_list: List[List[int | float | str | None]] = [] | ||
""" | ||
data_list = [] # type: List[List[int | float | str | None]] | ||
data_list = [] # type: List[Union[int,float,str,None]] | ||
data_list: List[Union[int, float, str, None]] = [] | ||
""" | ||
columns_list: List[str] = [] | ||
self.__df_data = pd.DataFrame(data=data_list, columns=columns_list) | ||
# print(self.__df_data) | ||
# print(f'values: {self.__df_data.values}') | ||
self.__df_page_num = 0 | ||
|
||
# Accessor for processing DataFrame objects obtained with the Subscan API | ||
def get_df(self): | ||
return self.__df_data | ||
def set_df(self,df_data): | ||
|
||
def set_df(self, df_data): | ||
self.__df_data = df_data | ||
|
||
df_data = property(get_df, set_df) | ||
|
||
# Accessor that handles page_current properties of dash_table.DataTable | ||
def get_df_page_num(self): | ||
return self.__df_page_num | ||
def set_df_page_num(self,df_page_num): | ||
|
||
def set_df_page_num(self, df_page_num): | ||
self.__df_page_num = df_page_num | ||
|
||
df_page_num = property(get_df_page_num, set_df_page_num) | ||
df_page_num = property(get_df_page_num, set_df_page_num) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.