Ejemplo n.º 1
0
 public function postAcademicYear(Request $request)
 {
     $name = $request['academic_year_name'];
     $description = $request['academic_year_description'];
     $status = true;
     $country = new Academic_year();
     $country->name = $name;
     $country->description = $description;
     $country->status = $status;
     $country->save();
     return redirect()->route('academic-year')->with(['message' => 'Successfully Saved!']);
 }
Ejemplo n.º 2
0
 public function populateDropdowns()
 {
     $populatecountry = Country::orderBy('created_at', 'asc')->paginate(100);
     $populatemunicipality = Municipality::orderBy('created_at', 'asc')->paginate(100);
     $populateregion = Region::orderBy('created_at', 'asc')->paginate(100);
     $populateschool_level = School_level::orderBy('created_at', 'asc')->paginate(100);
     $populateschool_type = School_type::orderBy('created_at', 'asc')->paginate(100);
     $populateacademic_year = Academic_year::orderBy('created_at', 'asc')->paginate(100);
     $populatetemplate = Template::orderBy('created_at', 'asc')->paginate(100);
     $site_code = Settings::first()->site_code;
     $site_title = Settings::first()->site_title;
     $owner = Settings::first()->owner;
     $street = Settings::first()->street;
     $barangay = Settings::first()->barangay;
     $zip_code = Settings::first()->zip_code;
     $contact = Settings::first()->contact;
     $fax = Settings::first()->fax;
     $tin = Settings::first()->tin;
     //$posts=Post::orderBy('created_at','desc')->paginate(15);
     //return view('general-settings',['populatecountry' => $populatecountry]);
     return view('general-settings')->with('populatecountry', $populatecountry)->with('populatemunicipality', $populatemunicipality)->with('populateregion', $populateregion)->with('populateschool_level', $populateschool_level)->with('populateschool_type', $populateschool_type)->with('populateacademic_year', $populateacademic_year)->with('populatetemplate', $populatetemplate)->with('site_code', $site_code)->with('site_title', $site_title)->with('owner', $owner)->with('street', $street)->with('barangay', $barangay)->with('zip_code', $zip_code)->with('contact', $contact)->with('fax', $fax)->with('tin', $tin);
 }