PaymentController.php 809 B

123456789101112131415161718192021222324252627282930
  1. <?php
  2. // Copyright 2019 Hackware SpA <human@hackware.cl>
  3. // This file is part of "Hackware Web Services Payment" and licensed under
  4. // the terms of the GNU Affero General Public License version 3, or (at your
  5. // option) a later version. You should have received a copy of this license
  6. // along with the software. If not, see <https://www.gnu.org/licenses/>.
  7. namespace Hawese\Payment\Http\Controllers;
  8. use Hawese\Payment\Payment;
  9. use Hawese\Core\Http\Controllers\Controller;
  10. use Illuminate\Http\Request;
  11. class PaymentController extends Controller
  12. {
  13. public function __construct()
  14. {
  15. $this->middleware('auth');
  16. }
  17. public function show(Request $request, $uuid)
  18. {
  19. $payment = Payment::find($uuid);
  20. $this->authorize('read', $payment);
  21. return $payment;
  22. }
  23. }