public function register()
 {
     if (Request::isMethod('post')) {
         $this->postRegister();
     }
     $countryModel = new CountryBaseModel();
     $this->data['listCountry'] = $countryModel->getAllForm();
     $this->data['listWebsiteCategory'] = CategoryBaseModel::where('status', 1)->where('parent_id', 0)->where('name', '!=', 'Other')->orderBy('name', 'asc')->get()->toArray();
     $this->data['listLanguage'] = LanguageBaseModel::where('status', 1)->orderBy('name', 'asc')->get()->toArray();
     $this->data['listReason'] = $this->model->reason;
     $this->data['errors'] = $this->errors;
     $this->layout->content = View::make('register', $this->data);
 }
Beispiel #2
0
 public function contactInfo()
 {
     $this->layout = View::make('layout.main');
     $this->layout->slugMenu = '';
     $countryModel = new CountryBaseModel();
     $this->data['listCountry'] = $countryModel->getAllForm();
     $this->data['listWebsiteCategory'] = CategoryBaseModel::where('status', 1)->where('parent_id', 0)->where('name', '!=', 'Other')->orderBy('name', 'asc')->get()->toArray();
     $this->data['listLanguage'] = LanguageBaseModel::where('status', 1)->orderBy('name', 'asc')->get()->toArray();
     //$this->data['listReason']			= $this->model->reason;
     if (Request::isMethod('post')) {
         $this->postContactInfo($this->data);
     }
     $this->layout->slugMenu = '';
     $this->layout->content = View::make('contactInfoPage', $this->data);
 }
 public function getCategoryByIdAttribute()
 {
     $modelCate = new CategoryBaseModel();
     $item = $modelCate->where('id', $this->category)->select('id', 'name')->first();
     if (!empty($item)) {
         return $item->name;
     } else {
         return FALSE;
     }
 }