Esempio n. 1
0
 /**
  * Получаем справочник с решениями
  * @return array
  */
 protected function getResolutionChoices()
 {
     return TicketResolutionQuery::create()->find()->toKeyValue('Id', 'Title');
 }
Esempio n. 2
0
 /**
  * Получение справочника с решениями
  * @Route("/get_resolutions", name="get_resolutions")
  * @param Request $request
  * @return JsonResponse
  */
 public function getResolutionsAction(Request $request)
 {
     $resolutions = TicketResolutionQuery::create()->find();
     return new JsonResponse(array('success' => true, 'resolutions' => $resolutions->toArray()));
 }