Skip to content

Commit

Permalink
Merge pull request #54 from ryanaidilp/feature/dynamic-data
Browse files Browse the repository at this point in the history
feat: implement dynamic table phase 1
  • Loading branch information
ryanaidilp authored Apr 27, 2024
2 parents efe3c57 + 637f5c6 commit ea12315
Show file tree
Hide file tree
Showing 425 changed files with 10,161 additions and 1,544 deletions.
8 changes: 7 additions & 1 deletion .github/cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@
"Exim",
"SIMDASI",
"Glosarium",
"SDDS"
"SDDS",
"datasource",
"getx",
"logging",
"usecase",
"usecases",
"Repobeats"
]
}
5 changes: 5 additions & 0 deletions .github/workflows/coverage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ on:
jobs:
coverage:
runs-on: ubuntu-latest
defaults:
run:
working-directory: packages/stadata_flutter_sdk
steps:
- name: 📚 Git Checkout
uses: actions/checkout@v4
Expand Down Expand Up @@ -47,6 +50,8 @@ jobs:
"**/http_module.dart" \
"**/usecase.dart" \
"**/service_locator.dart" \
"**/injector.dart" \
"**/*_injector.dart" \
"**/register_module.dart" \
"**/env.dart" \
"**/*_log_*.dart" \
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,14 @@ jobs:
spell-check:
uses: VeryGoodOpenSource/very_good_workflows/.github/workflows/spell_check.yml@v1
with:
working_directory: packages/stadata_flutter_sdk
includes: "**/*.md"
modified_files_only: false

build:
uses: VeryGoodOpenSource/very_good_workflows/.github/workflows/flutter_package.yml@v1
with:
working_directory: packages/stadata_flutter_sdk
flutter_channel: stable
min_coverage: 80
coverage_excludes: "**/*.config.dart **/register_module.dart **/http_*.dart **/*_http_module.dart **/*_log_*.dart **/*.g.dart **/*.freezed.dart **/*_serializer.dart **/service_locator.dart **/env.dart **/usecase.dart"
coverage_excludes: "**/*.config.dart **/register_module.dart **/http_*.dart **/*_http_module.dart **/*_log_*.dart **/*.g.dart **/*.freezed.dart **/*_serializer.dart **/service_locator.dart **/env.dart **/usecase.dart **/injector.dart **/*_injector.dart"
41 changes: 5 additions & 36 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,46 +1,15 @@
# Miscellaneous
*.class
*.log
*.pyc
*.swp
.DS_Store
.atom/
.buildlog/
.history
.svn/

# IntelliJ related
*.iml
*.ipr
*.iws
.idea/

# VSCode related
.vscode/

# Flutter/Dart/Pub related
**/doc/api/
**/ios/Flutter/.last_build_id
.dart_tool/
.flutter-plugins
.flutter-plugins-dependencies
.packages
.pub-cache/
.pub/
/build/
pubspec.lock

# Web related
lib/generated_plugin_registrant.dart

# Symbolication related
app.*.symbols

# Obfuscation related
app.*.map.json

# Test related
coverage

# Environment Variable
.env
# IntelliJ related
*.iml
*.ipr
*.iws
.idea/
1 change: 1 addition & 0 deletions .vscode/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
settings.json
15 changes: 15 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "example",
"request": "launch",
"type": "dart",
"program": "app/example/lib/main.dart",
"args": ["--target", "lib/main.dart"]
}
]
}
15 changes: 5 additions & 10 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@ Packages with other changes:
- **REFACTOR**(exception): make stadata exception a normal class. ([f6d61af2](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/f6d61af24098a850e2b76016138ddd55c871dbe7))
- **REFACTOR**(datasource): remove unused param on press release. ([3e8af21c](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/3e8af21c88dd3faaaa74bc71cc0b9fe3afb0befc))
- **REFACTOR**(news): mark categoryId deprecated. ([895b5aab](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/895b5aab36f6cf1399724fa1b2ced61344749819))
- **REFACTOR**(controllers): replace deprectaed member. ([1aadefaa](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/1aadefaa4008f5c6a853e70ba01ff1e10dda0d0f))
- **REFACTOR**(controllers): replace deprecated member. ([1aadefaa](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/1aadefaa4008f5c6a853e70ba01ff1e10dda0d0f))
- **REFACTOR**(list): make some property deprecated. ([e72f2da8](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/e72f2da8104fac1893806cd231b774405a702180))
- **REFACTOR**(env): using new useConstantCase param. ([be72a53d](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/be72a53d05d10202bab7c5ada7ffad8efb746c83))
- **REFACTOR**(env): regenerate env variable. ([de57655e](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/de57655e8a0b6599671768a0df9c8dc36dd781a8))
- **REFACTOR**(config): update melos config. ([855b1eed](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/855b1eed2b54cd2c1fb602adc5c385890700166c))
- **REFACTOR**(params): update all param that has id to ID instead of Id. ([7c1349d9](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/7c1349d9a3d89d0756b494ca4e48ff1af529f6a7))
- **REFACTOR**(domain): change variableID param type to int? ([2cb36f8d](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/2cb36f8d34ad285dbecf272e37e3ad93bf0d8c47))
- **REFACTOR**(domain): add page parameter. ([1a58d429](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/1a58d4295a0ff2b4e10abffed91a7750cb4c5b10))
- **REFACTOR**(domain): update return value type to apiresponse. ([9a6b27a2](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/9a6b27a25c60cb3065c27907b2c2516c0544e31a))
- **REFACTOR**(domain): update return value type to api response. ([9a6b27a2](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/9a6b27a25c60cb3065c27907b2c2516c0544e31a))
- **REFACTOR**(exceptions): update exception class. ([daedbf8f](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/daedbf8fafda1ddbcf37796c5acd871cadb69739))
- **REFACTOR**(repository): remove dead code. ([00d1bb2e](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/00d1bb2e67eadda0e7a8e6133808d77006320668))
- **REFACTOR**(static_table): mark subjectId as deprecated. ([ad17bf37](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/ad17bf37dacb008c95e495525f87548b9565b196))
Expand All @@ -45,7 +45,7 @@ Packages with other changes:
- **REFACTOR**(features): move domains from list to features. ([4f8605fc](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/4f8605fcabc6ed9f93aaf61ae84b255e635810b5))
- **REFACTOR**(static_table): mark subjectId as deprecated. ([2b6817be](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/2b6817bea24ee1079999645406fb8097180fe714))
- **REFACTOR**(endpoint): update infographic endpoint name and add endpoint. ([12d6ff80](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/12d6ff80ac99ecb1e164f4991cba924258b54cd8))
- **REFACTOR**(interceptor): update loggin interceptor. ([29c6de99](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/29c6de9911d47965e17d0ffc90050c3ced414e07))
- **REFACTOR**(interceptor): update logging interceptor. ([29c6de99](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/29c6de9911d47965e17d0ffc90050c3ced414e07))
- **REFACTOR**(datasource): rename endpoint. ([d9251d60](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/d9251d60fd60e6fc91ae7d47ea1abedbeb35572c))
- **REFACTOR**(pagination): move required to first param. ([be078ea9](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/be078ea9ee8fe58045b9f069e3f23c76ea84299e))
- **REFACTOR**(logger): add prefix to log. ([9cf4745d](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/9cf4745db92fe80f9834c41df7945e812cd14079))
Expand Down Expand Up @@ -76,7 +76,7 @@ Packages with other changes:
- **FIX**(example): fix nullable abstract. ([ce895748](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/ce8957480bca921b84787cfb611b6ddf31926a67))
- **FIX**(analysis): fix analysis issue. ([2d267267](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/2d267267d3d9fd03fc4a8188900ef348e1495442))
- **FIX**(test): fix breaking test. ([2c7f836d](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/2c7f836d9d16065ee60a7114cbf07371894b13af))
- **FIX**(model): fix wrong key for periode. ([3eb79002](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/3eb79002171086d809fec2f0c7cfe2ec3b0120da))
- **FIX**(model): fix wrong key for period. ([3eb79002](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/3eb79002171086d809fec2f0c7cfe2ec3b0120da))
- **FIX**(library): fix get it wont run. ([211383cd](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/211383cd9ff26a9c2bf61cbfae286097cfa089bf))
- **FIX**(cspell): add new words to cspell. ([804abbea](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/804abbeafd8d6f0fa59116ad755a3cabafc52e09))
- **FIX**(entity): fix nullable csa subject ID. ([7ef65569](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/7ef65569f8fc06ff1aaed4e0b738be1ed6844ae0))
Expand Down Expand Up @@ -131,7 +131,7 @@ Packages with other changes:
- **FEAT**(library): add infographics to stadata flutter sdk. ([7b8d6757](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/7b8d6757bc9dce1abe36478ac36dfcb1b7dda8ae))
- **FEAT**(example): add infographics page example. ([1b8b4c79](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/1b8b4c79820abc38986164ad85f63d7b30847d47))
- **FEAT**(example): create example page for strategic indicator. ([2b043768](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/2b04376878f5152128f7233bf7eab1886fe9c800))
- **FEAT**(repository): create static table repository contradt. ([9af562a5](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/9af562a5cd6f389b2c9ae1a61290319b6f4fb697))
- **FEAT**(repository): create static table repository contract. ([9af562a5](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/9af562a5cd6f389b2c9ae1a61290319b6f4fb697))
- **FEAT**(news): add news feature to list and view. ([0448b1c6](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/0448b1c66fc747b327732b7c5b187cc2dc9ab55d))
- **DOCS**(changelog): update changelog. ([0488edea](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/0488edeaff0ccf6a87571387c8377145cba322cb))
- **DOCS**(license): add license. ([4efa395d](https://github.com/ryanaidilp/stadata_flutter_sdk/commit/4efa395d307cffdda31c5634c28ce31566b0dc86))
Expand Down Expand Up @@ -434,8 +434,3 @@ All notable changes to this project will be documented in this file. The format
### New Contributors

- @ryanaidilp made their first contribution in [#2](https://github.com/ryanaidilp/stadata_flutter_sdk/pull/2)

[0.3.0]: https://github.com/ryanaidilp/stadata_flutter_sdk/compare/0.2.1...0.3.0
[0.2.1]: https://github.com/ryanaidilp/stadata_flutter_sdk/compare/0.2.0...0.2.1
[0.2.0]: https://github.com/ryanaidilp/stadata_flutter_sdk/compare/0.1.0...0.2.0
[0.1.0]: https://github.com/ryanaidilp/stadata_flutter_sdk/compare/0.1.0...0.1.0
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@ For detailed usage instructions and documentation of this package, please refer
- 🔄 SDGs Data
- 🔄 Strategic Indicator
- 🔄 SDDS
- ✅ Unit
- ✅ Variable
- ✅ Vertical Variable

### View API TODO

Expand All @@ -90,8 +93,11 @@ For detailed usage instructions and documentation of this package, please refer
<img src="https://contrib.rocks/image?repo=ryanaidilp/stadata_flutter_sdk" />
</a>

## Activities

![Alt](https://repobeats.axiom.co/api/embed/a54b7524a1269a5f4e1d39ec68b99713b07317c2.svg "Repobeats analytics image")

[license_badge]: https://img.shields.io/badge/license-MIT-blue.svg
[license_link]: https://github.com/ryanaidilp/stadata_flutter_sdk/blob/main/LICENSE
[very_good_analysis_badge]: https://img.shields.io/badge/style-very_good_analysis-B22C89.svg
[very_good_analysis_link]: https://pub.dev/packages/very_good_analysis
[very_good_cli_link]: https://pub.dev/packages/very_good_cli
11 changes: 0 additions & 11 deletions analysis_options.yaml

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@ linter:

# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options
analyzer:
exclude:
- "**/*.g.dart"
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
86 changes: 86 additions & 0 deletions app/example/assets/locales/en_US.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
{
"stadata_example": "Stadata Example",
"features": {
"domains": "Domains",
"infographics": "Infographics",
"list": "List",
"news": "News",
"news_categories": "News Categories",
"press_releases": "Press Releases",
"publications": "Publications",
"static_tables": "Static Tables",
"strategic_indicators": "Strategic Indicators",
"subject_categories": "Subject Categories",
"subjects": "Subjects",
"units": "Units",
"variables": "Variables",
"vertical_variables": "Vertical Variables"
},
"page": {
"domain": "Domain Page",
"units": "Unit Page",
"variables": "Variable Page",
"vertical_variables": "Vertical Variable Page"
},
"label": {
"empty": "Empty",
"result": "Result",
"custom_param": "Custom Param",
"type": "Type (type) - required",
"province_code": "Province Code (prov) - optional",
"page": "Page (page):",
"area_variable": "showExistingVariable (area): ",
"language": "Language (lang) - required",
"domain": "Domain (domain) - required",
"subject_id": "Subject ID (subject) - optional",
"year": "Year (year) - optional",
"variable_id": "Variable ID (var) - optional",
"pagination": {
"main": "Pagination",
"page": "Page: @page",
"pages": "Pages: @pages",
"per_page": "Per Page: @per_page",
"total": "Total: @total"
}
},
"button": {
"submit": "Submit"
},
"enums": {
"domain": {
"all": "All (all)",
"province": "Province (province)",
"regency": "Regency (regency)",
"regency_by_province": "Regency by Province (regencyByProv)"
}
},
"properties": {
"unit": {
"id": "ID (unit_id): ",
"title": "Title (unit): "
},
"variable": {
"id": "ID (var_id): ",
"subject_id": "Subject ID (sub_id): ",
"subject_name": "Subject Name (sub_name): ",
"title": "Title (title): ",
"vertical": "Vertical Variable ID (vertical): ",
"def": "Definition (def): ",
"type": "Type (jenis): ",
"unit": "Unit (unit): ",
"notes": "Notes (notes): ",
"graph_name": "Graph Name (graph_name): ",
"csa_subject_id": "CSA Subject ID (subcsa_id): ",
"csa_subject_name": "CSA Subject Name (subcsa_name): ",
"derived_period_id": "Derived Period ID (turth): ",
"derived_variable_id": "Derived Variable ID (turvar): "
},
"vertical_variable": {
"id": "ID (kode_ver_id): ",
"title": "Title (vervar): ",
"item_id": "Item ID (item_var_id): ",
"group_id": "Group ID (group_var_id): ",
"group_name": "Group Name (name_group_var_id): "
}
}
}
86 changes: 86 additions & 0 deletions app/example/assets/locales/id_ID.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
{
"stadata_example": "Contoh Stadata",
"features": {
"domains": "Domain",
"infographics": "Infografis",
"list": "Daftar",
"news": "Berita",
"news_categories": "Kategori Berita",
"press_releases": "Press Rilis",
"publications": "Publikasi",
"static_tables": "Tabel Statis",
"strategic_indicators": "Indikator Strategis",
"subject_categories": "Kategori Subjek",
"subjects": "Subjek",
"units": "Satuan",
"variables": "Variabel",
"vertical_variables": "Variabel Vertikal"
},
"page": {
"domain": "Halaman Domain",
"units": "Halaman Satuan",
"variables": "Halaman Variabel",
"vertical_variables": "Halaman Variabel Vertikal"
},
"label": {
"empty": "Kosong",
"result": "Hasil",
"custom_param": "Kustomisasi Parameter",
"type": "Jenis (type) - wajib",
"province_code": "Kode Provinsi (prov) - opsional",
"page": "Halaman (page):",
"area_variable": "showExistingVariable (area): ",
"language": "Bahasa (lang) - wajib",
"domain": "Domain (domain) - wajib",
"subject_id": "ID Subjek (subject) - opsional",
"year": "Tahun (year) - opsional",
"variable_id": "ID Variabel (var) - opsional",
"pagination": {
"main": "Data Halaman",
"page": "Halaman: @page",
"pages": "Jumlah Halaman: @pages",
"per_page": "Per Halaman: @per_page",
"total": "Total: @total"
}
},
"button": {
"submit": "Kirim"
},
"enums": {
"domain": {
"all": "Semua (all)",
"province": "Provinsi (province)",
"regency": "Kabupaten (regency)",
"regency_by_province": "Kabupaten by Provinsi (regencyByProv)"
}
},
"properties": {
"unit": {
"id": "ID (unit_id): ",
"title": "Judul (unit): "
},
"variable": {
"id": "ID (var_id): ",
"subject_id": "ID Subjek (sub_id): ",
"subject_name": "Nama Subjek (sub_name): ",
"title": "Judul (title): ",
"vertical": "ID Variabel Vertikal (vertical): ",
"def": "Definisi (def): ",
"type": "Jenis (jenis): ",
"unit": "Satuan (unit): ",
"notes": "Catatan (notes): ",
"graph_name": "Nama Grafik (graph_name): ",
"csa_subject_id": "ID Subjek CSA (subcsa_id): ",
"csa_subject_name": "Nama Subjek CSA (subcsa_name): ",
"derived_period_id": "ID Periode Turunan (turth): ",
"derived_variable_id": "ID Variabel Turunan (turvar): "
},
"vertical_variable": {
"id": "ID (kode_ver_id): ",
"title": "Judul (vervar): ",
"item_id": "ID Item (item_var_id): ",
"group_id": "ID Grup (group_var_id): ",
"group_name": "Nama Grup (name_group_var_id): "
}
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit ea12315

Please sign in to comment.