<?php
/**
 * @copyright (c) Kufer Software GmbH, Loisachstrasse 4, D-84453 Mühldorf
 */




namespace Kufer\KuferTools\Veranstalter\KursUebersicht\Detailsreiter\Honorar\AddDozent;

class NewDozentDialogPresenter extends \Kufer\KuferTools\Basis\Presenter\Presenter
{
  
  
  public function present() {
    $view = $this->getView();
    $ajaxResponse = \JsonOperations::encode4Ajax($this->getAjaxObject($view)); 
    return $ajaxResponse;
  }
  
  
  protected function getAjaxDialogTitle() {
    
    return 'Details zum neuen Dozenten';
  }
  
  
  protected function getJSDeclarations()
  {
    
    
    $result  = 'registerNamespace("KuferTools.NewDozentDialog");'."\n";
    
    return $result;
  }
    
  
  protected function getView()
  {
    return new NewDozentDialogView($this->getViewModel());
  }
  
  protected function getViewModel()
  {
    $viewModel = new NewDozentDialogViewModel();
    $viewModel->dozent = $this->useCaseResponse->dozent;
    $viewModel->kurs = $this->useCaseResponse->kurs;
    $viewModel->columns = $this->useCaseResponse->columns;
    return $viewModel;
  }
}