public Page<WorkitemServicesDetail> Get(WorkItemServicesDetailSearchCriteria criteria)
        {
            var sql = Sql.Builder
                .OrderBy(criteria.OrderBy + " " + criteria.OrderByDirection)
                .Where("workOrderNumber=@0",criteria.WorkOrderNumber);

            return _repository.PagedQuery<WorkitemServicesDetail>(criteria.PageNumber, criteria.ItemsPerPage, sql.SQL, sql.Arguments);
        }
        public JsonResult List(WorkItemServicesDetailSearchCriteria criteria)
        {
            var page = _workItemServicesQueries.Get(criteria);

            return Json(new
            {
                total = page.TotalPages,
                page = page.CurrentPage,
                records = page.TotalItems,
                rows = page.Items.Select(Mapper.Map<WorkitemServicesViewModel>)
            });
        }