import { ChangeDetectionStrategy, Component } from '@angular/core'; import { CommonModule } from '@angular/common'; interface ExampleCall { phone: string; duration: string; status: string; statusKind: 'answered' | 'pending' | 'missed'; date: string; } interface CallFilter { label: string; value: string; hint: string; type: 'text' | 'select'; options?: string[]; } /** * Symbolic demonstration page for retrieving call records from the call * center. The rows are example data and every control is a placeholder. */ @Component({ selector: 'app-call-center-calls', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, templateUrl: './call-center-calls.page.html', styleUrls: ['./call-center-calls.page.css', '../../shared/styles/demo-page.css'], }) export class CallCenterCallsPage { readonly filters: CallFilter[] = [ { label: 'از تاریخ', value: '۱۴۰۴/۰۷/۰۱', hint: 'نمونه — بازه تاریخ قابل انتخاب است.', type: 'text', }, { label: 'تا تاریخ', value: '۱۴۰۴/۰۷/۳۰', hint: 'نمونه — بازه تاریخ قابل انتخاب است.', type: 'text', }, { label: 'وضعیت تماس', value: 'همه وضعیت‌ها', hint: 'فیلتر نمونه.', type: 'select', options: ['همه وضعیت‌ها', 'پاسخ‌داده شده', 'بدون پاسخ', 'در انتظار بازبینی'], }, ]; readonly exampleCalls: ExampleCall[] = [ { phone: '۰۹۱۲۱۲۳۴۵۶۷', duration: '۲:۴۵', status: 'پاسخ‌داده شده', statusKind: 'answered', date: '۱۴ مهر ۱۴۰۴', }, { phone: '۰۹۳۵۱۱۲۲۳۳۴۴', duration: '۰:۳۸', status: 'بدون پاسخ', statusKind: 'missed', date: '۱۴ مهر ۱۴۰۴', }, { phone: '۰۹۱۲۹۸۷۶۵۴۳۲', duration: '۵:۱۲', status: 'پاسخ‌داده شده', statusKind: 'answered', date: '۱۳ مهر ۱۴۰۴', }, { phone: '۰۹۱۵۵۵۱۲۳۴۵', duration: '۱:۰۳', status: 'در انتظار بازبینی', statusKind: 'pending', date: '۱۳ مهر ۱۴۰۴', }, ]; }