Beispiel #1
0
 public function getPenetrationNameAttribute()
 {
     $historyRepositories = new HistoryRepository();
     $values = $historyRepositories->penetration_name();
     return $values[$this->attributes['penetration']];
 }
Beispiel #2
0
 public function skillTables(Skill $skill, PaperRepository $paperRepository, HistoryRepository $historyRepository)
 {
     $experiences = $skill->experiences()->get();
     $degrees = $skill->degrees()->get();
     $honors = $skill->honors()->get();
     $histories = $skill->histories()->get();
     $papers = $skill->papers()->get();
     $papers_type = $paperRepository->type_name();
     $history_penetration = $historyRepository->penetration_name();
     $years_list = [];
     for ($i = jDate::forge('now')->format('%Y'); $i >= jDate::forge('now - 40 years')->format('%Y'); $i--) {
         $years_list[$i] = $i;
     }
     return view('profile.newSkill', compact('skill', 'experiences', 'degrees', 'honors', 'histories', 'papers', 'papers_type', 'years_list', 'history_penetration'))->with(['title' => 'ثبت مهارت جدید', 'new_skill' => 0, 'edit_skill' => 1, 'step' => 2, 'hasEdit' => 1]);
 }