PATH:
home
/
lab2454c
/
sothebry.softkinesis.com
/
backups
/
core
/
app
/
Http
/
Controllers
/
Admin
<?php namespace App\Http\Controllers\Admin; use App\Http\Controllers\Controller; use App\Models\FashionNft; use App\Models\NftOrder; use Illuminate\Http\Request; use Illuminate\Support\Facades\Auth; class FashionNftController extends Controller { public function __construct() { $this->activeTemplate = activeTemplate(); } /** * Display a listing of the resource. * * @return \Illuminate\Http\Response */ public function index() { $data['pageTitle'] = 'Fashion NFT Lists'; $data['emptyMessage'] = 'No NFT(s) Added Yet'; $data['nfts'] = FashionNft::orderBy('created_at', 'DESC')->paginate(15); return view('admin.fashionNft.index', $data); } // public function detail($id) // { // $pageTitle = "NFT Details"; // $nft = FashionNft::where('id',$id)->with('fashionNftImages')->firstOrFail(); // return view('admin.fashionNft.detail', compact('pageTitle', 'nft')); // } public function approve(Request $request) { $request->validate([ 'id' => 'required|exists:fashion_nfts,id' ]); $fashionNFT = FashionNft::findOrFail($request->id); $fashionNFT->status = 1; $fashionNFT->save(); $notify[] = ['success', 'NFT has been approved']; return back()->withNotify($notify); } public function cancel(Request $request) { $request->validate([ 'id' => 'required|exists:fashion_nfts,id' ]); $fashionNFT = FashionNft::findOrFail($request->id); $fashionNFT->status = 2; $fashionNFT->save(); $notify[] = ['success', 'Product has been cancel']; return back()->withNotify($notify); } public function nftOrderList() { $data['pageTitle'] = "NFT Order List"; $data['orders'] = NftOrder::with('user', 'fashionNft')->orderBy('created_at', 'DESC')->paginate(15); return view('admin.fashionNft.orderList', $data); } public function fashionNftBids(FashionNft $fashionNft) { //dd($fashionNft); $data['pageTitle'] = "Bid List for " .$fashionNft->name; $data['bids'] = $fashionNft->bids->load('user', 'fashionNft')->sortByDesc('created_at'); return view('admin.fashionNft.bids', $data); } }
[-] SubcategoryController.php
[edit]
[-] CategoryController.php
[edit]
[-] FrontendController.php
[edit]
[-] PageBuilderController.php
[edit]
[-] WithdrawalController.php
[edit]
[-] SupportTicketController.php
[edit]
[-] SpecificationController.php
[edit]
[-] AdvertisementController.php
[edit]
[+]
..
[-] HomeImageController.php
[edit]
[-] DepositController.php
[edit]
[-] ProductContentController.php
[edit]
[-] ExtensionController.php
[edit]
[-] MomentContentController.php
[edit]
[-] DynamicPageController.php
[edit]
[-] ManageUsersController.php
[edit]
[-] ReportController.php
[edit]
[-] GatewayController.php
[edit]
[-] EmailTemplateController.php
[edit]
[-] FaqContentController.php
[edit]
[-] OrderController.php
[edit]
[-] BrandController.php
[edit]
[-] ManualGatewayController.php
[edit]
[-] AdminController.php
[edit]
[+]
Auth
[-] LanguageController.php
[edit]
[-] WithdrawMethodController.php
[edit]
[-] FashionNftController.php
[edit]
[-] GeneralSettingController.php
[edit]
[-] ProductController.php
[edit]
[-] SmsTemplateController.php
[edit]