/**
  * Preview before printing a record.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function preview($id)
 {
     $record = Burial::find($id);
     $data = array('title' => 'Burial', 'parish_name' => $record->parish->parish_name, 'parish_address' => $record->parish->parish_address, 'parish_priest' => $record->parish->parish_priest, 'parish_secretary' => $record->parish->parish_secretary, 'id' => $id, 'date_of_burial' => $record->date_of_burial, 'name_of_deceased' => $record->name_of_deceased, 'date_of_death' => $record->date_of_death, 'age' => $record->age, 'status' => $record->status, 'parents_or_spouse' => $record->parents_or_spouse, 'residence' => $record->residence, 'sacraments' => $record->sacraments, 'cause_of_death' => $record->cause_of_death, 'place_of_burial' => $record->place_of_burial, 'minister' => $record->minister, 'remarks' => $record->remarks, 'book_no' => $record->book_no, 'page_no' => $record->page_no, 'line_no' => $record->line_no);
     return view('burial.preview')->with($data);
 }
 /**
  * Display a listing of the resource.
  *
  * @return \Illuminate\Http\Response
  */
 public function index()
 {
     $data = array('title' => 'Dashboard', 'baptism_count' => Baptism::all()->count(), 'confirmation_count' => Confirmation::all()->count(), 'marriage_count' => Marriage::all()->count(), 'burial_count' => Burial::all()->count());
     return view('dashboard')->with($data);
 }