wbreport 2.2.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of wbreport might be problematic. Click here for more details.

Files changed (70) hide show
  1. wbreport-2.2.1/.gitignore +2 -0
  2. wbreport-2.2.1/LICENSE +4 -0
  3. wbreport-2.2.1/PKG-INFO +6 -0
  4. wbreport-2.2.1/pyproject.toml +32 -0
  5. wbreport-2.2.1/wbreport/__init__.py +1 -0
  6. wbreport-2.2.1/wbreport/admin.py +87 -0
  7. wbreport-2.2.1/wbreport/apps.py +6 -0
  8. wbreport-2.2.1/wbreport/defaults/__init__.py +0 -0
  9. wbreport-2.2.1/wbreport/defaults/factsheets/__init__.py +0 -0
  10. wbreport-2.2.1/wbreport/defaults/factsheets/base.py +990 -0
  11. wbreport-2.2.1/wbreport/defaults/factsheets/menu.py +93 -0
  12. wbreport-2.2.1/wbreport/defaults/factsheets/mixins.py +35 -0
  13. wbreport-2.2.1/wbreport/defaults/factsheets/multitheme.py +947 -0
  14. wbreport-2.2.1/wbreport/dynamic_preferences_registry.py +15 -0
  15. wbreport-2.2.1/wbreport/factories/__init__.py +8 -0
  16. wbreport-2.2.1/wbreport/factories/data_classes.py +48 -0
  17. wbreport-2.2.1/wbreport/factories/reports.py +79 -0
  18. wbreport-2.2.1/wbreport/filters.py +37 -0
  19. wbreport-2.2.1/wbreport/fixtures/wbreport.yaml +1 -0
  20. wbreport-2.2.1/wbreport/migrations/0001_initial_squashed_squashed_0007_report_key.py +238 -0
  21. wbreport-2.2.1/wbreport/migrations/0008_alter_report_file_content_type.py +25 -0
  22. wbreport-2.2.1/wbreport/migrations/0009_alter_report_color_palette.py +27 -0
  23. wbreport-2.2.1/wbreport/migrations/0010_auto_20240103_0947.py +43 -0
  24. wbreport-2.2.1/wbreport/migrations/0011_auto_20240207_1629.py +35 -0
  25. wbreport-2.2.1/wbreport/migrations/0012_reportversion_lock.py +17 -0
  26. wbreport-2.2.1/wbreport/migrations/0013_alter_reportversion_context.py +18 -0
  27. wbreport-2.2.1/wbreport/migrations/0014_alter_reportcategory_options_and_more.py +25 -0
  28. wbreport-2.2.1/wbreport/migrations/__init__.py +0 -0
  29. wbreport-2.2.1/wbreport/mixins.py +183 -0
  30. wbreport-2.2.1/wbreport/models.py +781 -0
  31. wbreport-2.2.1/wbreport/pdf/__init__.py +0 -0
  32. wbreport-2.2.1/wbreport/pdf/charts/__init__.py +0 -0
  33. wbreport-2.2.1/wbreport/pdf/charts/legend.py +15 -0
  34. wbreport-2.2.1/wbreport/pdf/charts/pie.py +169 -0
  35. wbreport-2.2.1/wbreport/pdf/charts/timeseries.py +77 -0
  36. wbreport-2.2.1/wbreport/pdf/flowables/risk.py +88 -0
  37. wbreport-2.2.1/wbreport/pdf/flowables/textboxes.py +143 -0
  38. wbreport-2.2.1/wbreport/pdf/flowables/themes.py +179 -0
  39. wbreport-2.2.1/wbreport/pdf/sandbox/__init__.py +0 -0
  40. wbreport-2.2.1/wbreport/pdf/sandbox/run.py +17 -0
  41. wbreport-2.2.1/wbreport/pdf/sandbox/templates/__init__.py +0 -0
  42. wbreport-2.2.1/wbreport/pdf/sandbox/templates/basic_factsheet.py +908 -0
  43. wbreport-2.2.1/wbreport/pdf/sandbox/templates/fund_factsheet.py +864 -0
  44. wbreport-2.2.1/wbreport/pdf/sandbox/templates/long_industry_exposure_factsheet.py +898 -0
  45. wbreport-2.2.1/wbreport/pdf/sandbox/templates/multistrat_factsheet.py +872 -0
  46. wbreport-2.2.1/wbreport/pdf/sandbox/templates/testfile.pdf +434 -0
  47. wbreport-2.2.1/wbreport/pdf/tables/__init__.py +0 -0
  48. wbreport-2.2.1/wbreport/pdf/tables/aggregated_tables.py +156 -0
  49. wbreport-2.2.1/wbreport/pdf/tables/data_tables.py +75 -0
  50. wbreport-2.2.1/wbreport/serializers.py +191 -0
  51. wbreport-2.2.1/wbreport/tasks.py +60 -0
  52. wbreport-2.2.1/wbreport/templates/__init__.py +0 -0
  53. wbreport-2.2.1/wbreport/templatetags/__init__.py +0 -0
  54. wbreport-2.2.1/wbreport/templatetags/portfolio_tags.py +35 -0
  55. wbreport-2.2.1/wbreport/tests/__init__.py +0 -0
  56. wbreport-2.2.1/wbreport/tests/conftest.py +24 -0
  57. wbreport-2.2.1/wbreport/tests/test_models.py +253 -0
  58. wbreport-2.2.1/wbreport/tests/test_tasks.py +17 -0
  59. wbreport-2.2.1/wbreport/tests/test_viewsets.py +0 -0
  60. wbreport-2.2.1/wbreport/tests/tests.py +12 -0
  61. wbreport-2.2.1/wbreport/urls.py +29 -0
  62. wbreport-2.2.1/wbreport/urls_public.py +10 -0
  63. wbreport-2.2.1/wbreport/viewsets/__init__.py +10 -0
  64. wbreport-2.2.1/wbreport/viewsets/configs/__init__.py +18 -0
  65. wbreport-2.2.1/wbreport/viewsets/configs/buttons.py +193 -0
  66. wbreport-2.2.1/wbreport/viewsets/configs/displays.py +116 -0
  67. wbreport-2.2.1/wbreport/viewsets/configs/endpoints.py +23 -0
  68. wbreport-2.2.1/wbreport/viewsets/configs/menus.py +8 -0
  69. wbreport-2.2.1/wbreport/viewsets/configs/titles.py +30 -0
  70. wbreport-2.2.1/wbreport/viewsets/viewsets.py +330 -0
@@ -0,0 +1,2 @@
1
+ report/*
2
+ report
wbreport-2.2.1/LICENSE ADDED
@@ -0,0 +1,4 @@
1
+ This repository is not allowed to be used without written consent from either:
2
+
3
+ - Stainly SarL (Geneva, Switzerland)
4
+ - Intellineers GmbH & Co.KG (Hamburg, Germany)
@@ -0,0 +1,6 @@
1
+ Metadata-Version: 2.3
2
+ Name: wbreport
3
+ Version: 2.2.1
4
+ Author-email: Christopher Wittlinger <c.wittlinger@stainly.com>
5
+ Requires-Dist: wbcore
6
+ Requires-Dist: wbmailing
@@ -0,0 +1,32 @@
1
+ [project]
2
+ name = "wbreport"
3
+ description = ""
4
+ authors = [{ name = "Christopher Wittlinger", email = "c.wittlinger@stainly.com"}]
5
+ dynamic = ["version"]
6
+
7
+ dependencies = [
8
+ "wbcore",
9
+ "wbmailing",
10
+ ]
11
+
12
+ [tool.uv.sources]
13
+ wbcore = { workspace = true }
14
+ wbmailing = { workspace = true }
15
+
16
+
17
+ [tool.uv]
18
+ package = true
19
+
20
+ [tool.hatch.version]
21
+ path = "../../pyproject.toml"
22
+
23
+ [tool.hatch.build.targets.sdist]
24
+ include = ["wbreport/*"]
25
+
26
+ [tool.hatch.build.targets.wheel]
27
+ packages = ["wbreport"]
28
+ only-packages = true
29
+
30
+ [build-system]
31
+ requires = ["hatchling"]
32
+ build-backend = "hatchling.build"
@@ -0,0 +1 @@
1
+ __version__ = "1.0.0"
@@ -0,0 +1,87 @@
1
+ from django.contrib import admin
2
+ from guardian.admin import GuardedModelAdmin
3
+
4
+ from .models import Report, ReportAsset, ReportCategory, ReportClass, ReportVersion
5
+
6
+
7
+ @admin.register(ReportAsset)
8
+ class ReportAssetModelAdmin(admin.ModelAdmin):
9
+ list_display = ["key", "asset", "text"]
10
+
11
+
12
+ @admin.register(ReportCategory)
13
+ class ReportCategoryModelAdmin(admin.ModelAdmin):
14
+ list_display = ["title"]
15
+ search_fields = ("title",)
16
+
17
+
18
+ @admin.register(ReportClass)
19
+ class ReportClassModelAdmin(admin.ModelAdmin):
20
+ list_display = ["title"]
21
+ search_fields = ("title",)
22
+
23
+
24
+ @admin.register(ReportVersion)
25
+ class ReportVersionModelAdmin(admin.ModelAdmin):
26
+ list_display = ["title", "uuid", "disabled", "is_primary", "creation_date", "update_date"]
27
+ search_fields = ("title",)
28
+
29
+
30
+ class ReportVersionTabularInline(admin.TabularInline):
31
+ model = ReportVersion
32
+ fields = ["title", "disabled", "is_primary", "parameters"]
33
+ readonly_fields = ("creation_date", "update_date", "uuid")
34
+ extra = 0
35
+
36
+
37
+ class ReportTabularInline(admin.TabularInline):
38
+ model = Report
39
+ fields = ["title", "is_active", "permission_type"]
40
+ extra = 0
41
+
42
+
43
+ @admin.register(Report)
44
+ class ReportModelAdmin(GuardedModelAdmin):
45
+ list_display = ["title", "key", "category", "is_active", "permission_type"]
46
+ search_fields = (
47
+ "title",
48
+ "key",
49
+ "category__title",
50
+ )
51
+
52
+ fieldsets = (
53
+ (
54
+ "Main Information",
55
+ {
56
+ "fields": (
57
+ ("title", "namespace", "category", "logo_file"),
58
+ ("is_active", "permission_type", "mailing_list"),
59
+ ("key", "base_color", "color_palette"),
60
+ (
61
+ "report_class",
62
+ "parent_report",
63
+ ),
64
+ (
65
+ "file_content_type",
66
+ "file_disabled",
67
+ ),
68
+ ("parameters",),
69
+ )
70
+ },
71
+ ),
72
+ (
73
+ "Generic Content Type",
74
+ {
75
+ "fields": (
76
+ "content_type",
77
+ "object_id",
78
+ )
79
+ },
80
+ ),
81
+ )
82
+ inlines = [ReportVersionTabularInline]
83
+ autocomplete_fields = [
84
+ "content_type",
85
+ "report_class",
86
+ "category",
87
+ ]
@@ -0,0 +1,6 @@
1
+ from django.apps import AppConfig
2
+
3
+
4
+ class WbreportConfig(AppConfig):
5
+ default_auto_field = "django.db.models.BigAutoField"
6
+ name = "wbreport"
File without changes