StatisticRepository
class StatisticRepository extends EntityRepository
Class StatisticRepository is injected as alligator.statistic_repository service. StatisticRepository is used for crud operation for managed entity.
Use this class to work with database.
Constants
| ALIAS |
Alias for statistics |
| USER_ALIAS |
Alias for user |
| PRODUCT_ALIAS |
Alias for product |
| PRODUCT_ATTRIBUTE_VALUES_ALIAS |
Alias for product attribute values |
| ORDER_ALIAS |
Alias for order |
| SHOW_ROUTES |
Array of routes to show |
Methods
Load statistics data for graph representation
Load statistics data for graph representation
Find top products by review, limit by $maxResult
Find most viewed products, limit by $maxResult
Find top rated products, limit by $maxResult
Find financial data for graph representation
Find orders for month and year
Find best seller products, limit by $maxResult
Find last statistics data with pagination
Find order statistics data
Find order statistic rows
No description
Find latest viewed products for specific user
Find most viewed products for specific user
Find all data for OLAP
Details
at line 83
array
loadAllPlatformGraphData()
Load statistics data for graph representation
at line 108
array
loadPlatformPieGraphData()
Load statistics data for graph representation
at line 146
Statistics
saveStatistic(Statistics $statistics)
Persist new statistics
at line 162
array
getTopProductsAdmin(int $maxResult)
Find top products by review, limit by $maxResult
at line 192
array
getMostViewed(int $maxResult)
Find most viewed products, limit by $maxResult
at line 230
array|bool
getTopRated(int $maxResult)
Find top rated products, limit by $maxResult
at line 271
array
getFinancialGraphData(string|DateTime|null $currentDate = null, string|null $currency = null)
Find financial data for graph representation
at line 327
array
getOrderForYearAndMonth(string|DateTime|null $currentDate = null, string|null $currency = null)
Find orders for month and year
at line 361
array
getBestSellers(int $maxResult)
Find best seller products, limit by $maxResult
at line 400
array
getDataForLiveActivityLog(int $page = 1, int $offset = 10, array|null $params = null)
Find last statistics data with pagination
at line 467
array
getDataForOrderActivityLog(int $orderId)
Find order statistics data
at line 496
array
findRowsByOrderId(int $id)
Find order statistic rows
at line 508
EntityManager
getEntityManager()
at line 520
array
getLatestViewedProductsForUser(int|string $userId, int $numberOfProducts)
Find latest viewed products for specific user
at line 572
array
getMostViewedProductsForUser(int|string $userId, int $numberOfProducts)
Find most viewed products for specific user
at line 620
array
getAddedRemovedProductOlapData()
Find all data for OLAP