1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-14 07:02:34 +01:00
invoiceninja/app/Http/Controllers/AccountController.php

121 lines
2.5 KiB
PHP
Raw Normal View History

2018-10-24 05:50:15 +02:00
<?php
2019-05-11 05:32:07 +02:00
/**
* Invoice Ninja (https://invoiceninja.com)
*
* @link https://github.com/invoiceninja/invoiceninja source repository
*
* @copyright Copyright (c) 2019. Invoice Ninja LLC (https://invoiceninja.com)
*
* @license https://opensource.org/licenses/AAL
*/
2018-10-24 05:50:15 +02:00
namespace App\Http\Controllers;
use App\Http\Requests\Account\CreateAccountRequest;
use App\Jobs\Account\CreateAccount;
2019-04-18 13:57:22 +02:00
use App\Models\Account;
2019-09-16 23:42:08 +02:00
use App\Models\CompanyUser;
2019-04-18 13:57:22 +02:00
use App\Transformers\AccountTransformer;
2019-09-16 23:42:08 +02:00
use App\Transformers\CompanyUserTransformer;
use Illuminate\Foundation\Bus\DispatchesJobs;
2018-10-24 05:50:15 +02:00
use Illuminate\Http\Request;
2019-03-28 10:05:13 +01:00
use Illuminate\Support\Facades\Log;
2018-10-24 05:50:15 +02:00
2019-03-28 22:34:58 +01:00
class AccountController extends BaseController
2018-10-24 05:50:15 +02:00
{
use DispatchesJobs;
2019-09-16 23:42:08 +02:00
protected $entity_type = CompanyUser::class;
2019-04-18 13:57:22 +02:00
2019-09-16 23:42:08 +02:00
protected $entity_transformer = CompanyUserTransformer::class;
2019-04-18 13:57:22 +02:00
2018-10-24 05:50:15 +02:00
public function __construct()
{
2019-03-28 22:34:58 +01:00
parent::__construct();
2019-04-03 02:09:22 +02:00
//$this->middleware('guest');
2018-10-24 05:50:15 +02:00
}
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public function index()
{
2019-04-03 02:09:22 +02:00
// return view('signup.index');
2018-10-24 05:50:15 +02:00
}
/**
* Show the form for creating a new resource.
*
* @return \Illuminate\Http\Response
*/
public function create()
{
//
}
/**
* Store a newly created resource in storage.
*
* @param \App\Http\Requests\SignupRequest $request
* @return \Illuminate\Http\Response
*/
public function store(CreateAccountRequest $request)
{
2019-04-18 13:57:22 +02:00
$account = CreateAccount::dispatchNow($request->all());
2019-09-16 23:42:08 +02:00
$ct = CompanyUser::whereUserId(auth()->user()->id);
return $this->listResponse($ct);
2018-10-24 05:50:15 +02:00
}
/**
* Display the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function show($id)
{
//
}
/**
* Show the form for editing the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function edit($id)
{
//
}
/**
* Update the specified resource in storage.
*
* @param \Illuminate\Http\Request $request
* @param int $id
* @return \Illuminate\Http\Response
*/
public function update(Request $request, $id)
{
//
}
/**
* Remove the specified resource from storage.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function destroy($id)
{
//
}
}