Rewire Application Provider handlers to use ServiceProvider traits #12

Closed
opened 2026-02-09 21:04:04 +00:00 by mik-tf · 1 comment
Owner

Problem

8 Application Provider handlers bypass ServiceProvider and show 0 deployments, 0 customer base, and empty revenue charts when running with hero_osis backend.

Affected Handlers

Template-Rendering Handlers

  • app_provider_section — Main AP dashboard with app grid
  • app_provider_detail — Individual app detail view
  • app_provider_deployments — Deployment management
  • app_provider_customers — Customer base view
  • app_provider_revenue — Revenue analytics
  • app_provider_settings — AP settings

API Handlers

  • app_provider_data_api Already partially working (returns 6 apps)
  • app_provider_deployments_api — Returns deployment data
  • app_provider_customers_api — Returns customer metrics

Current State

The JSON API endpoints partially work (returning app counts), but template-rendering handlers still use:

let service = AppProviderService::builder().build();

This means the HTML pages show empty data even though the API returns correct counts.

Solution

Replace all AppProviderService::builder().build() and similar patterns with services.app_provider.* trait method calls.

Acceptance Criteria

  • AP dashboard shows real apps with deployment counts
  • Deployment management page lists active deployments
  • Customer base shows actual user metrics
  • Revenue page displays earning data
  • Zero AppProviderService::builder() calls remain
  • Code compiles and tests pass

Dependencies

  • Depends on: #9 (split dashboard.rs)
  • Can be done in parallel with: #10, #11, #13
## Problem 8 Application Provider handlers bypass ServiceProvider and show 0 deployments, 0 customer base, and empty revenue charts when running with hero_osis backend. ## Affected Handlers ### Template-Rendering Handlers - `app_provider_section` — Main AP dashboard with app grid - `app_provider_detail` — Individual app detail view - `app_provider_deployments` — Deployment management - `app_provider_customers` — Customer base view - `app_provider_revenue` — Revenue analytics - `app_provider_settings` — AP settings ### API Handlers - `app_provider_data_api` — ✅ Already partially working (returns 6 apps) - `app_provider_deployments_api` — Returns deployment data - `app_provider_customers_api` — Returns customer metrics ## Current State The JSON API endpoints partially work (returning app counts), but template-rendering handlers still use: ```rust let service = AppProviderService::builder().build(); ``` This means the HTML pages show empty data even though the API returns correct counts. ## Solution Replace all `AppProviderService::builder().build()` and similar patterns with `services.app_provider.*` trait method calls. ## Acceptance Criteria - [ ] AP dashboard shows real apps with deployment counts - [ ] Deployment management page lists active deployments - [ ] Customer base shows actual user metrics - [ ] Revenue page displays earning data - [ ] Zero `AppProviderService::builder()` calls remain - [ ] Code compiles and tests pass ## Dependencies - Depends on: #9 (split dashboard.rs) - Can be done in parallel with: #10, #11, #13
Author
Owner

Already fully rewired. Verified — only dead code UserPersistence call remains (commit 9e669d7).

Already fully rewired. Verified — only dead code UserPersistence call remains (commit 9e669d7).
Commenting is not possible because the repository is archived.
No description provided.