Muoland.Reporting 1.0.4

dotnet add package Muoland.Reporting --version 1.0.4
                    
NuGet\Install-Package Muoland.Reporting -Version 1.0.4
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Muoland.Reporting" Version="1.0.4" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Muoland.Reporting" Version="1.0.4" />
                    
Directory.Packages.props
<PackageReference Include="Muoland.Reporting" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Muoland.Reporting --version 1.0.4
                    
#r "nuget: Muoland.Reporting, 1.0.4"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Muoland.Reporting@1.0.4
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Muoland.Reporting&version=1.0.4
                    
Install as a Cake Addin
#tool nuget:?package=Muoland.Reporting&version=1.0.4
                    
Install as a Cake Tool

Muoland.Reporting

The present library enables advanced reporting and data analysis featuring data tensors (data cubes), pivot tables, and interactive comments, slices, and filters.

Features

  • Data Tensor (Data Cube): Multi-dimensional data modeling for complex analytical scenarios.
  • Pivot Tables: Dynamic pivot table generation for summarizing and exploring data.
  • Interactive Comments: Add, edit, and view comments directly within reports for enhanced collaboration.
  • Slices & Filters: Intuitive slicing and filtering capabilities to drill down into data subsets.
  • Extensible & Flexible: Designed for easy integration and customization in your .NET applications.

Installation

Install via NuGet Package Manager:

dotnet add package Muoland.Reporting

Getting Started

Following is an example of Blazor page:

@page "/Playground"
@rendermode InteractiveServer
@inject IJSRuntime JS

@using DataModelMock
@using Enterprise.DataTensor
@using Enterprise.Reporting

<h2 style="font-size:200%"> Playground <p style="font-size:50%"> (in-memory setup for testing purpose) </p> </h2>

@if (PivotTable is null || Table is null || DataWithStringPivotTable is null || DataWithArrayPivotTable is null)
{
    <p><em>Loading...</em></p>
}
else
{
    @Report.GetCSSStyle(this)

    <div style="font-size:11px;">

        <h5> Transactional Data (Pivot Table) </h5>

        <table>
            <tr>
                <td> @PivotTable.GetViewWidgetFragment(this) </td>
                <td> @PivotTable.GetCommentWidgetFragment(this) </td>
                <td> @PivotTable.GetSliceWidgetFragment(this) </td>
                <td> @PivotTable.GetFilterWidgetFragment(this) </td>
            </tr>
        </table>
   
        <br>

        @PivotTable.GetFragment(this)
        @PivotTable.GetDialogsFragment(this)
    </div>
}


@code {
    public PivotTable<TransactionalData>? PivotTable { get; set; }
    public DataTensor<TransactionalData>? TransactionalDataTensor { get; set; }

    protected override async Task OnInitializedAsync()
    {
        await Task.CompletedTask;
    }

    protected override async Task OnAfterRenderAsync(bool firstRender)
    {
        await Task.CompletedTask;

        if (firstRender)
        {
            var data = TemplateData.GetTransactionalData();
            var views = TemplateData.GetViews();
            var comments = TemplateData.GetComments();

            TransactionalDataTensor = DataTensorBuilder.WithData(data)
                .WithDimensionData(TemplateDimensions.GetLineOfBusinesses())
                .WithDimensionData(TemplateDimensions.GetAmountTypes())
                .WithDimensionData(TemplateDimensions.GetScenarios())
                .WithViews(views, async (view) => await Task.CompletedTask)
                .WithComments(comments, async (comment) => await Task.CompletedTask)
                .Create();

            PivotTable = ReportBuilder.FromTensor(TransactionalDataTensor)
                .WithUpdateAction(() => InvokeAsync(StateHasChanged))
                .Create().ToPivotTable()
                .SliceColumnsBy(nameof(LineOfBusiness))
                .SliceRowsBy(nameof(AmountType));

            StateHasChanged();
        }

        await JS.InvokeVoidAsync("eval", Report.JSScripts);
    }
}

Contributing

For info please contact Andrea Muolo on LinkedIn or via email: and.muolo@gmail.com

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Release Note v1.0.2

- Data Tensor and Reporting now can process multiple values
- Data Tensor initial support for custom aggregation
- Roll out Data Tensor builder for consistent and user friendly instantiation
- Reporting of Data Tensor without comments can no open data cells
- Report height and width can now be configured
- columns and row headers are now frozen to enhance horizontal and vertical scrolling
- improved moving dialogs with memory
- Fix dimension parent update for the top-level entry
- various bug fixing and performance improvements

For detailed information regarding the terms and conditions of this package, please refer to the LICENSE.txt file.