📖 Overview
This document provides a comprehensive list of all TypeScript functions available in the Inbound module components and services. The Inbound module handles all inbound telecommunications services including DID (Direct Inward Dialing) number management, call routing, number provisioning, CDR processing, order management, and comprehensive telecommunications infrastructure.
🧩 Components Overview
Primary Components
📞 GetnumbersComponent
File: src/app/inbound/getnumbers/getnumbers.component.ts
Purpose: Number search, provisioning, and selection interface with toll-free and vanity number support
📋 DidComponent
File: src/app/inbound/did/did.component.ts
Purpose: Comprehensive DID number management with bulk operations, filtering, and status management
📊 CalldetailsrecordComponent
File: src/app/inbound/calldetailsrecord/calldetailsrecord.component.ts
Purpose: CDR viewing, analysis, filtering, and export functionality
🛒 AddcartComponent
File: src/app/inbound/addcart/addcart.component.ts
Purpose: Shopping cart functionality for number ordering and bulk purchase operations
📞 TollfreenumbersComponent
File: src/app/inbound/tollfreenumbers/tollfreenumbers.component.ts
Purpose: Toll-free number management with advanced routing and configuration
📂 LoadnumberComponent
File: src/app/inbound/loadnumber/loadnumber.component.ts
Purpose: Number loading and import functionality
📜 OrdersHistoryComponent
File: src/app/inbound/orders-history/orders-history.component.ts
Purpose: Order tracking, history management, and status monitoring
Additional Components
- CompletecallComponent: Completed call analytics and tracking
- UncompletecallComponent: Failed call analysis and troubleshooting
- ManagesitesComponent: Site and location management
- IpaddressComponent: IP address configuration and management
- ShortcodeComponent: Short code management and configuration
- ViewOrderComponent: Detailed order viewing and management
- DidHistoryComponent: DID usage history and analytics
- BulkactionLogComponent: Bulk operation logging and audit
Services & Utilities
⚙️ InboundService
File: src/app/inbound/inbound.service.ts
Purpose: Core inbound operations, API integration, and data management
🔧 DateFilter Pipe
File: src/app/inbound/datefilter.pipe.ts
Purpose: Date formatting and filtering utility
🔧 OrderPipe
File: src/app/inbound/orderPipe.pipe.ts
Purpose: Data sorting and ordering functionality
📞 GetnumbersComponent Functions
🔄 Lifecycle Functions
ngOnInit()
/**
* Component initialization with form setup, data loading, and state management
* Initializes number search component with cart management
* Creates reactive forms for local and toll-free numbers
* Sets up dropdown configuration and state management
* Loads user tariff data
* @returns {void}
*/
ngOnInit(): void
ngOnDestroy()
/**
* Component cleanup and subscription management
* Properly unsubscribes from observables and cleans up component resources
* Prevents memory leaks and improves performance
* @returns {void}
*/
ngOnDestroy(): void
📝 Form Management Functions
setState()
/**
* Handles state selection and rate center loading
* Updates form with selected state
* Loads rate centers for the selected state
* Refreshes UI data based on state selection
* @param {any} event - State selection event containing abbreviation
* @returns {void}
*/
setState(event: any): void
setRateCenter()
/**
* Handles rate center selection for number filtering
* Updates form with selected rate center data
* Applies geographic filtering for number searches
* @param {any} event - Rate center selection event
* @returns {void}
*/
setRateCenter(event: any): void
Form Controls Getter
/**
* Form controls getter for template access
* Provides convenient access to form controls for validation and data binding
* @returns {AbstractControl} Form controls object
*/
get f(): AbstractControl
🔍 Number Search Functions
onSearchDID()
/**
* Executes DID number search with filtering and cart integration
* Validates search form and performs API call for number search
* Processes results with cart status checking
* Manages DataTable initialization and duplicate detection for cart items
* @returns {void}
*/
onSearchDID(): void
onSubmit()
/**
* Submits toll-free and vanity number search requests
* Validates vanity form and executes toll-free number search
* Processes search results with cart integration
* Manages DataTable updates and cart status for returned numbers
* @returns {void}
*/
onSubmit(): void
🛒 Cart Management Functions
onSelectDid()
/**
* Handles individual DID selection for cart management
* Manages individual DID selection/deselection
* Checks for cart duplicates and updates selection counters
* Handles cart state management and validates cart limits
* @param {any} event - Checkbox selection event
* @param {any} did - DID object containing number data
* @param {number} idx - Array index for tracking
* @returns {void}
*/
onSelectDid(event: any, did: any, idx: number): void
onSelectAll()
/**
* Handles bulk selection/deselection of all visible DIDs
* Toggles all DID selections and manages bulk cart operations
* Updates counters and UI state
* Handles validation for bulk selections
* @param {any} event - Select all checkbox event
* @returns {void}
*/
onSelectAll(event: any): void
addToCart()
/**
* Adds selected DIDs to shopping cart
* Validates selected DIDs and adds items to cart through service
* Updates cart state and provides user feedback
* Handles cart limitations and business rules
* @returns {void}
*/
addToCart(): void
🔄 State Management Functions
tabChange()
/**
* Manages tab switching between local, toll-free, and vanity numbers
* Switches between different number search interfaces
* Resets forms and state, updates UI display mode
* Manages tab-specific configurations
* @param {string} tab - Tab identifier ('1', '2', '3')
* @returns {void}
*/
tabChange(tab: string): void
onReset()
/**
* Resets forms and UI state
* Clears form data and resets validation states
* Updates UI elements and checkbox states
* @param {HTMLInputElement} checkBox1 - First checkbox reference
* @param {HTMLInputElement} checkBox2 - Second checkbox reference
* @returns {void}
*/
onReset(checkBox1: HTMLInputElement, checkBox2: HTMLInputElement): void
📋 DidComponent Functions
🔄 Lifecycle Functions
ngOnInit()
/**
* Component initialization with DID data loading and form setup
* Initializes DID management component with user context
* Sets up filtering forms and pagination
* Loads DID numbers and status information
* Configures bulk operation capabilities
* @returns {void}
*/
ngOnInit(): void
📊 Data Management Functions
getDIDNumbers()
/**
* Retrieves DID numbers with filtering and pagination
* Loads DID data from API with applied filters
* Manages pagination and data table updates
* Handles sorting and search functionality
* @returns {void}
*/
getDIDNumbers(): void
applyFilters()
/**
* Applies filtering criteria to DID list
* Processes filter form data and applies search criteria
* Updates data table with filtered results
* Manages filter state and validation
* @returns {void}
*/
applyFilters(): void
⚡ Bulk Operations Functions
bulkRelease()
/**
* Performs bulk release of selected DID numbers
* Validates selection and confirms bulk release operation
* Executes bulk release through API
* Updates UI and provides operation feedback
* @returns {void}
*/
bulkRelease(): void
bulkRouting()
/**
* Applies bulk routing configuration to selected DIDs
* Validates routing parameters and selected DIDs
* Executes bulk routing update through API
* Manages routing configuration and validation
* @returns {void}
*/
bulkRouting(): void
selectAllDIDs()
/**
* Handles select all functionality for DID management
* Toggles selection state for all visible DIDs
* Updates bulk operation availability
* Manages UI state and selection counters
* @param {any} event - Select all checkbox event
* @returns {void}
*/
selectAllDIDs(event: any): void
📞 Individual DID Functions
updateRouting()
/**
* Updates routing configuration for individual DID
* Validates routing parameters and DID ownership
* Submits routing update through API
* Provides feedback and updates DID status
* @param {any} did - DID object to update
* @param {any} routingData - New routing configuration
* @returns {void}
*/
updateRouting(did: any, routingData: any): void
releaseDID()
/**
* Releases individual DID number
* Confirms release operation with user
* Executes DID release through API
* Updates UI and removes DID from list
* @param {any} did - DID object to release
* @returns {void}
*/
releaseDID(did: any): void
📊 CalldetailsrecordComponent Functions
🔄 Lifecycle Functions
ngOnInit()
/**
* Component initialization with CDR data loading and filtering setup
* Initializes call detail record component with date range configuration
* Sets up filtering forms and data table
* Loads initial CDR data with default filters
* Configures export and analysis tools
* @returns {void}
*/
ngOnInit(): void
📊 Data Retrieval Functions
loadCDRData()
/**
* Loads call detail records with filtering and pagination
* Retrieves CDR data from API with applied date range and filters
* Manages data table initialization and updates
* Handles large dataset pagination and performance optimization
* @returns {void}
*/
loadCDRData(): void
applyCDRFilters()
/**
* Applies advanced filtering to CDR data
* Processes filter form with date range, number, and status criteria
* Updates data table with filtered results
* Manages filter validation and state
* @returns {void}
*/
applyCDRFilters(): void
📁 Export Functions
exportCDR()
/**
* Exports CDR data to various formats (CSV, Excel, PDF)
* Validates export parameters and data selection
* Generates export file through API
* Handles download process and user feedback
* @param {string} format - Export format ('csv', 'excel', 'pdf')
* @returns {void}
*/
exportCDR(format: string): void
generateReport()
/**
* Generates detailed call analytics report
* Processes CDR data for statistical analysis
* Creates formatted report with charts and summaries
* Manages report generation and download
* @returns {void}
*/
generateReport(): void
🛒 AddcartComponent Functions
🔄 Lifecycle Functions
ngOnInit()
/**
* Component initialization with cart data loading and form setup
* Initializes shopping cart component with saved cart items
* Sets up billing and shipping forms
* Loads pricing and tariff information
* Configures checkout process
* @returns {void}
*/
ngOnInit(): void
🛒 Cart Management Functions
loadCartItems()
/**
* Loads and displays cart items with pricing
* Retrieves saved cart items from service
* Calculates total pricing and taxes
* Updates cart UI with item details and pricing breakdown
* @returns {void}
*/
loadCartItems(): void
removeFromCart()
/**
* Removes item from shopping cart
* Confirms removal with user and updates cart state
* Recalculates pricing and updates UI
* Manages cart persistence and state
* @param {any} item - Cart item to remove
* @returns {void}
*/
removeFromCart(item: any): void
updateQuantity()
/**
* Updates item quantity in cart
* Validates quantity limits and availability
* Recalculates pricing and updates cart totals
* Manages inventory checking and validation
* @param {any} item - Cart item to update
* @param {number} quantity - New quantity value
* @returns {void}
*/
updateQuantity(item: any, quantity: number): void
💳 Checkout Functions
processCheckout()
/**
* Processes cart checkout and order placement
* Validates cart items and billing information
* Submits order through payment gateway
* Handles order confirmation and receipt generation
* @returns {void}
*/
processCheckout(): void
calculateTotals()
/**
* Calculates cart totals including taxes and fees
* Processes item pricing and applies applicable taxes
* Calculates shipping and handling fees
* Updates total pricing display
* @returns {void}
*/
calculateTotals(): void
validatePayment()
/**
* Validates payment information and processes payment
* Validates credit card information and billing details
* Processes payment through secure gateway
* Handles payment success/failure responses
* @returns {Promise<boolean>} Payment validation result
*/
validatePayment(): Promise<boolean>
⚙️ InboundService Functions
📡 API Integration Functions
searchNumbers()
/**
* Searches for available numbers based on criteria
* Executes number search API with filtering parameters
* Handles different number types (local, toll-free, vanity)
* Returns available numbers with pricing information
* @param {any} searchCriteria - Search parameters and filters
* @returns {Observable<any>} Available numbers response
*/
searchNumbers(searchCriteria: any): Observable<any>
getDIDList()
/**
* Retrieves user's DID number list with filtering
* Fetches DID numbers with status and routing information
* Supports pagination and advanced filtering
* Returns DID data with management capabilities
* @param {any} filters - Filter criteria for DID list
* @returns {Observable<any>} DID list response
*/
getDIDList(filters: any): Observable<any>
getCDRData()
/**
* Retrieves call detail records with filtering and pagination
* Fetches CDR data from API with date range and filters
* Supports large dataset handling and export functionality
* Returns CDR data with analytics information
* @param {any} filters - CDR filter criteria
* @returns {Observable<any>} CDR data response
*/
getCDRData(filters: any): Observable<any>
📞 Number Management Functions
orderNumbers()
/**
* Places order for selected numbers
* Processes number order with payment and billing information
* Handles order validation and inventory checking
* Returns order confirmation and tracking details
* @param {any} orderData - Order details and selected numbers
* @returns {Observable<any>} Order placement response
*/
orderNumbers(orderData: any): Observable<any>
updateDIDRouting()
/**
* Updates DID routing configuration
* Processes routing changes for individual or bulk DIDs
* Validates routing parameters and ownership
* Returns routing update confirmation
* @param {any} routingData - DID routing configuration
* @returns {Observable<any>} Routing update response
*/
updateDIDRouting(routingData: any): Observable<any>
releaseDIDNumbers()
/**
* Releases DID numbers from user account
* Processes individual or bulk DID release operations
* Handles release validation and confirmation
* Returns release operation status
* @param {any} releaseData - DIDs to release and confirmation details
* @returns {Observable<any>} Release operation response
*/
releaseDIDNumbers(releaseData: any): Observable<any>
🛒 Cart Management Functions
addToCart()
/**
* Adds selected numbers to shopping cart
* Validates number availability and pricing
* Manages cart state and persistence
* Returns cart update confirmation
* @param {any} cartItems - Numbers to add to cart
* @returns {Observable<any>} Cart update response
*/
addToCart(cartItems: any): Observable<any>
getCartItems()
/**
* Retrieves current cart items with pricing
* Fetches saved cart data with current pricing
* Validates item availability and pricing updates
* Returns cart contents with totals
* @returns {Observable<any>} Cart items response
*/
getCartItems(): Observable<any>
removeFromCart()
/**
* Removes items from shopping cart
* Processes cart item removal and updates cart state
* Manages cart persistence and validation
* Returns updated cart information
* @param {any} itemIds - Cart item IDs to remove
* @returns {Observable<any>} Cart removal response
*/
removeFromCart(itemIds: any): Observable<any>
📊 Analytics & Reporting Functions
generateCDRReport()
/**
* Generates detailed CDR analytics report
* Processes CDR data for statistical analysis and reporting
* Creates formatted reports with charts and summaries
* Handles various report formats and export options
* @param {any} reportCriteria - Report parameters and filters
* @returns {Observable<Blob>} Generated report file
*/
generateCDRReport(reportCriteria: any): Observable<Blob>
exportData()
/**
* Exports data to various formats
* Processes data export requests for DIDs, CDRs, or orders
* Supports multiple export formats (CSV, Excel, PDF)
* Handles large dataset exports with chunking
* @param {string} dataType - Type of data to export
* @param {string} format - Export format
* @param {any} filters - Data filtering criteria
* @returns {Observable<Blob>} Export file blob
*/
exportData(dataType: string, format: string, filters: any): Observable<Blob>
🔧 Utility Pipes Functions
📅 DateFilter Pipe
transform()
/**
* Transforms and filters data based on date criteria
* Applies date range filtering to arrays of data
* Supports various date formats and comparison operators
* Returns filtered array based on date criteria
* @param {any[]} items - Array of items to filter
* @param {string} field - Date field name to filter on
* @param {Date} startDate - Start date for filtering
* @param {Date} endDate - End date for filtering
* @returns {any[]} Filtered array of items
*/
transform(items: any[], field: string, startDate: Date, endDate: Date): any[]
🔄 OrderPipe
transform()
/**
* Sorts and orders array data based on specified criteria
* Supports ascending and descending sort orders
* Handles multiple data types (string, number, date)
* Returns sorted array based on field and direction
* @param {any[]} array - Array of items to sort
* @param {string} field - Field name to sort by
* @param {string} direction - Sort direction ('asc' or 'desc')
* @returns {any[]} Sorted array of items
*/
transform(array: any[], field: string, direction: string): any[]
🔗 Integration & Workflow
📞 Number Provisioning Workflow
- Search - Search for available numbers by criteria
- Selection - Select desired numbers and add to cart
- Cart Management - Review, modify, and validate cart items
- Checkout - Process payment and place order
- Provisioning - Numbers are provisioned and activated
- Management - Configure routing and manage DIDs
📊 CDR Processing Workflow
- Data Collection - CDR data is collected from network
- Processing - Records are processed and stored
- Filtering - Apply filters for analysis
- Analysis - Generate reports and analytics
- Export - Export data in various formats
🛒 Order Management Workflow
- Order Placement - Customer places number order
- Validation - Order validation and inventory check
- Payment Processing - Secure payment handling
- Fulfillment - Number provisioning and activation
- Tracking - Order status tracking and updates
- Completion - Order completion and receipt
📋 Summary
This comprehensive documentation covers all aspects of inbound telecommunications functionality, from number search and provisioning to CDR analysis and order management within the telecommunications admin panel application.