More webapp changes+fixes
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { Component, inject, signal, OnInit } from '@angular/core';
|
||||
import { CommonModule, DatePipe } from '@angular/common';
|
||||
import { Router } from '@angular/router';
|
||||
import { Router, RouterLink } from '@angular/router';
|
||||
import { FormsModule } from '@angular/forms';
|
||||
import { NzTableModule } from 'ng-zorro-antd/table';
|
||||
import { NzButtonModule } from 'ng-zorro-antd/button';
|
||||
@@ -43,6 +43,7 @@ const TAB_CONFIGS: Record<SubscriptionTab, TabConfig> = {
|
||||
CommonModule,
|
||||
DatePipe,
|
||||
FormsModule,
|
||||
RouterLink,
|
||||
NzTableModule,
|
||||
NzButtonModule,
|
||||
NzIconModule,
|
||||
@@ -231,13 +232,20 @@ export class SubscriptionListComponent implements OnInit {
|
||||
});
|
||||
}
|
||||
|
||||
getStatusInfo(sub: Subscription): { label: string; color: string } {
|
||||
getConfirmationInfo(sub: Subscription): { label: string; color: string } {
|
||||
if (sub.confirmed) {
|
||||
return { label: 'Confirmed', color: 'green' };
|
||||
}
|
||||
return { label: 'Pending', color: 'orange' };
|
||||
}
|
||||
|
||||
getActiveInfo(sub: Subscription): { label: string; color: string } {
|
||||
if (sub.active) {
|
||||
return { label: 'Active', color: 'green' };
|
||||
}
|
||||
return { label: 'Inactive', color: 'default' };
|
||||
}
|
||||
|
||||
getTypeLabel(sub: Subscription): { label: string; color: string } {
|
||||
const userId = this.authService.getUserId();
|
||||
if (sub.subscriber_user_id === sub.channel_owner_user_id) {
|
||||
|
||||
Reference in New Issue
Block a user