Esempio n. 1
0
 /**
  * Display the specified resource.
  *
  * @param  int  $id
  * @return \Illuminate\Http\Response
  */
 public function show($id)
 {
     $thisAuction = Auction::findOrFail($id);
     $auctions = [];
     array_push($auctions, $thisAuction);
     $thisAuction->clicks = $thisAuction->clicks + 1;
     $thisAuction->save();
     $timeArray = timecalc::calculate($auctions);
     return view('art.artwork', ['auction' => $auctions[0], 'timediff' => $timeArray[0]]);
 }
Esempio n. 2
0
 public function auctions()
 {
     $auctions = Auth::user()->auctionsowner;
     $timeArray = timecalc::calculate($auctions);
     return view('user/myauctions', ['auctions' => $auctions, 'timediff' => $timeArray]);
 }