@extends('admin.layouts.contentLayoutMaster') @section('title','帳號分類') @section('vendor-styles')
@endsection @section('page-styles') @endsection @section('content')
@csrf
名稱
@if ($errors->has('name')) @include('admin.panels.input-invalid-messages', [ 'messages' => $errors->get('name') ]) @endif
類別
@if ($role_categories->isNotEmpty()) @foreach ($role_categories as $role_category_id => $role_category_name) @php $checked_id = old("role_category_id", 1); $checked = $role_category_id == $checked_id ? 'checked' : ''; @endphp
{{ $role_category_name }}
@endforeach @endif
@if ($errors->has('role_category_id')) @include('admin.panels.input-invalid-messages', [ 'messages' => $errors->get('role_category_id') ]) @endif
啟用
利潤
@if ($errors->has('bonus_percent')) @include('admin.panels.input-invalid-messages', [ 'messages' => $errors->get('bonus_percent') ]) @endif
@if (!empty($permissions)) @foreach ($permissions as $main_name => $main) @if (!empty($main)) @foreach ($main as $sub_name => $info) @php if (!isset($row)) { $row = 1; } else { $row++; } @endphp {{-- 檢視 --}} @php $i = 0; @endphp @if(!empty($info[$i]) && $info[$i]['method'] == '檢視') @else @endif {{-- 編輯 --}} @php $i = 1; @endphp @if(!empty($info[$i]) && $info[$i]['method'] == '編輯') @else @endif {{-- 刪除 --}} @php $i = 2; @endphp @if(!empty($info[$i]) && $info[$i]['method'] == '刪除') @else @endif @endforeach @endif @endforeach @endif
權限表
全選
檢視
編輯
刪除
{{ $main_name }}
{{ $sub_name }}
{{-- 全選 --}}
@endsection @section('vendor-scripts') @endsection @section('page-scripts') @endsection