Esempio n. 1
0
 public function updateForm($id_policy)
 {
     $policy = Policy::find($id_policy);
     $clients = Client::orderBy('name')->get();
     $hostnames = Host::orderBy('hostname')->get();
     $databases = Database::orderBy('db_name')->get();
     if (empty($policy)) {
         return 'Backup Policy not found!';
     }
     return View::make('policies.policiesUpdate')->with('policy', $policy)->with('clients', $clients)->with('hostnames', $hostnames)->with('databases', $databases);
 }
Esempio n. 2
0
 public function delete($db_name)
 {
     Database::destroy($db_name);
     return redirect()->action('DatabasesController@read')->withInput(Request::only('db_name'));
 }