First Commit
This commit is contained in:
Executable
+84
@@ -0,0 +1,84 @@
|
||||
{% extends "layouts/dashboard.twig" %}
|
||||
|
||||
{% block title %}{{ title }} - {{ platformName }}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="container-fluid px-4">
|
||||
<h1 class="mt-4">{{ title }}</h1>
|
||||
<ol class="breadcrumb mb-4">
|
||||
<li class="breadcrumb-item"><a href="{{ url('admin/dashboard') }}">{{ __('dashboard.dashboard') }}</a></li>
|
||||
<li class="breadcrumb-item"><a href="{{ url('admin/erp') }}">ERP</a></li>
|
||||
<li class="breadcrumb-item active">{{ __('company.title') }}</li>
|
||||
</ol>
|
||||
|
||||
<div class="mb-4 d-flex justify-content-between">
|
||||
<a href="/admin/erp" class="btn btn-outline-secondary">
|
||||
<i class="bi bi-arrow-left"></i> {{ __('erp.admin.back_to_erp') }}
|
||||
</a>
|
||||
{% if can_create_company %}
|
||||
<a href="{{ url('admin/companies/create') }}" class="btn btn-primary">
|
||||
<i class="bi bi-plus me-1"></i> {{ __('company.new_company') }}
|
||||
</a>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<div class="card mb-4">
|
||||
<div class="card-header">
|
||||
<i class="bi bi-building me-1"></i>
|
||||
{{ __('company.list_title') }}
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered" id="dataTable" width="100%" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{ __('company.name') }}</th>
|
||||
<th>{{ __('company.email') }}</th>
|
||||
<th>{{ __('company.type') }}</th>
|
||||
<th>{{ __('company.status') }}</th>
|
||||
<th>{{ __('company.created_at') }}</th>
|
||||
<th>{{ __('company.actions') }}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for company in companies %}
|
||||
<tr>
|
||||
<td>{{ company.bus_name }}</td>
|
||||
<td>{{ company.bus_email }}</td>
|
||||
<td>{{ __('company.' ~ company.bus_type) }}</td>
|
||||
<td>
|
||||
<span class="badge bg-{{ company.bus_status == 'active' ? 'success' : 'secondary' }}">
|
||||
{{ __('company.' ~ company.bus_status) }}
|
||||
</span>
|
||||
</td>
|
||||
<td>{{ company.created_at|date("d/m/Y H:i") }}</td>
|
||||
<td>
|
||||
<a href="{{ url('admin/companies/' ~ company.bus_id) }}" class="btn btn-info btn-sm" title="{{ __('company.view') }}">
|
||||
<i class="bi bi-eye"></i>
|
||||
</a>
|
||||
<a href="{{ url('admin/companies/' ~ company.bus_id ~ '/edit') }}" class="btn btn-warning btn-sm" title="{{ __('company.edit') }}">
|
||||
<i class="bi bi-pencil"></i>
|
||||
</a>
|
||||
{% if user.isSuperAdmin() %}
|
||||
<form action="{{ url('admin/companies/' ~ company.bus_id) }}" method="POST" class="d-inline" onsubmit="return confirm('{{ __('company.confirm_delete') }}');">
|
||||
<input type="hidden" name="_method" value="DELETE">
|
||||
{{ csrf_field()|raw }}
|
||||
<button type="submit" class="btn btn-danger btn-sm" title="{{ __('company.delete') }}">
|
||||
<i class="bi bi-trash"></i>
|
||||
</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
</td>
|
||||
</tr>
|
||||
{% else %}
|
||||
<tr>
|
||||
<td colspan="6" class="text-center">{{ __('company.no_companies') }}</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user