Skip to content

AltafEmpaxis/jsreport-studio-playground

Repository files navigation

JsReport Studio .NET

A .NET-based reporting application that integrates jsreport for generating, designing, and managing reports through a web-based interface.

Running the Application

Follow these steps to get the application up and running:

  1. Prerequisites

    • Install .NET 9.0 SDK or later
    • Install Node.js (automatically managed by jsreport.Binary)
    • Use a modern web browser (Chrome recommended)
    • Visual Studio 2022 or VS Code (optional)
  2. Clone the Repository

git clone https://github.com/AltafEmpaxis/jsreport-studio-playground.git
cd jsreport-studio-playground
  1. First Time Setup
# Clean any existing builds
dotnet clean

# Remove existing binaries and cache (if any)
rd /s /q bin obj jsreport

# Restore packages
dotnet restore
  1. Build and Run
dotnet build
dotnet run
  1. Access the Application

The application runs on port 5488 by default. You can change this in the jsreport.config.json file if needed.

Package Dependencies

<PackageReference Include="jsreport.Binary" Version="3.8.0" />
<PackageReference Include="jsreport.Local" Version="3.8.2" />
<PackageReference Include="Microsoft.Extensions.Logging.Console" Version="9.0.1" />

Project Structure

jsreport-studio-playground/
├── Program.cs              # Main application entry point
├── JsReportStudio.csproj  # Project file with dependencies
├── jsreport.config.json   # jsreport configuration
└── jsreport/             # Report templates and assets directory (auto-generated)
    └── data/             # Stored templates and data

Configuration

The application uses jsreport.config.json for configuration:

{
  "httpPort": 5488,
  "allowLocalFilesAccess": true,
  "store": {
    "provider": "fs"
  },
  "extensions": {
    "authentication": {
      "enabled": false,
      "admin": {
        "username": "admin",
        "password": "password"
      }
    },
    "sample-template": {
      "createSamples": true
    }
  }
}

Changing the Port

To use a different port:

  1. Update the httpPort in jsreport.config.json:
{
  "httpPort": YOUR_PORT_NUMBER,
  ...
}
  1. Or set it through environment variable:
set JSREPORT_PORT=YOUR_PORT_NUMBER
dotnet run

Features

  • Web-based template designer
  • Multiple output formats (PDF, Excel, Word, HTML)
  • Asset management
  • Sample templates included
  • File-based storage
  • No authentication required (by default)

Development

Requirements

  • Visual Studio 2022 or VS Code
  • .NET 9.0 SDK
  • Git
  • Node.js

Debug Mode

  1. Open the solution in Visual Studio
  2. Set breakpoints in Program.cs
  3. Press F5 to start debugging

VS Code Setup

  1. Install C# extension
  2. Open the folder
  3. Use the .vscode/launch.json for debugging configuration

Troubleshooting

If the application doesn't start:

  1. Check Port
# See if port 5488 is in use
netstat -ano | findstr :5488
  1. Kill Existing Process
# If port is in use, kill the process
taskkill /F /IM jsreport.exe
taskkill /F /IM node.exe
  1. Fresh Start
# Clean everything and start fresh
dotnet clean
rd /s /q bin obj jsreport
dotnet restore
dotnet run
  1. Common Issues
    • Port 5488 already in use
    • Node.js not installed or wrong version
    • Missing .NET SDK
    • Insufficient permissions for file system access

Repository Information

Support

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages