示例#1
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function edit($id)
 {
     $instruments = Instrument::lists('name', 'id');
     $control = Control::find($id);
     $measureTypes = MeasureType::all();
     $instrument = $control->instrument_id;
     return view('control.edit')->with('control', $control)->with('instruments', $instruments)->with('measureTypes', $measureTypes)->with('instrument', $instrument);
 }
示例#2
0
 /**
  * Show the form for editing the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function edit($id)
 {
     //Get the testtype
     $testtype = TestType::find($id);
     $measures = Measure::all();
     $measuretype = MeasureType::all()->sortBy('id');
     $specimentypes = SpecimenType::orderBy('name')->get();
     $testcategory = $testtype->testCategory->id;
     $testcategories = TestCategory::lists('name', 'id');
     $organisms = Organism::orderBy('name')->get();
     //Open the Edit View and pass to it the $testtype
     return view('testtype.edit', compact('testtype', 'testcategories', 'testcategory', 'measures', 'measuretype', 'specimentypes', 'organisms'));
 }