public function show($anx) { $anexo = Anexo22::where('id', $anx)->first(); $validaciones = $anexo->validations()->where('anexo22_id', $anx)->get(); return $validaciones; }
public function show($anx) { $anexo = Anexo22::where('id', $anx)->first(); $validaciones = $anexo->validations()->join('aud_attributes', 'attribute_id', '=', 'aud_attributes.id')->select('val_data', 'attribute_id', 'name', 'aud_validations.id as id')->where('anexo22_id', $anx)->get(); return $validaciones; }