コード例 #1
0
ファイル: utilities.php プロジェクト: wyrover/aeroeco
function generateWorkTickets($pID)
{
    $ticks = ProjectPart::where('in_project', 1)->where('project_id', $pID)->get();
    foreach ($ticks as $tick) {
        Workticket::create(['project_id' => $pID, 'part_id' => $tick->part_listing_id, 'scopestatus_id' => 1]);
    }
    // end foreach
    return $pID;
}
コード例 #2
0
 public function listOne($id)
 {
     //show single
     $ticket = Workticket::with($this->related)->findOrFail($id);
     return view('tickets.single', compact('ticket'));
 }