mirror of
https://gitlab.com/TheGamecraft/c-cms.git
synced 2026-04-21 10:49:10 -04:00
filesysteme
This commit is contained in:
@@ -1,114 +0,0 @@
|
||||
<table class="table table-hover table-responsive dt-responsive material-datatables w-100 d-sm-table" id="table">
|
||||
<thead class="thead-dark">
|
||||
<tr>
|
||||
<td class="text-center explorerType"><strong>#</strong></td>
|
||||
<td class="text-left">Nom</td>
|
||||
<td class="text-center">Dernière modification</td>
|
||||
<td class="td-actions text-right">
|
||||
@if($permission['p'])
|
||||
<div class="dropdown">
|
||||
<div id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fas fa-ellipsis-v fa-2x ml-3 text-gray" style="margin-right: .8rem !important;cursor: pointer;margin-top: -10px;margin-bottom: -6px"></i>
|
||||
</div>
|
||||
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
|
||||
<a class="dropdown-item" href="/admin/drive/{{$currentDir}}/permission">
|
||||
<i class="fas fa-lock mr-2"></i></i>Permission
|
||||
</a>
|
||||
<a class="dropdown-item text-danger" onclick="deleteFolder('{{ $currentDir }}')">
|
||||
<i class="fas fa-trash-alt mr-2"></i>Supprimer
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
<i class="fas fa-lock text-danger mr-2" data-toggle="tooltip" data-placement="left" title="Vous n'avez pas les permissions nécessaires pour modifier ce dossier"></i>
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@foreach($directories as $directory)
|
||||
@php
|
||||
$read = \App\GoogleDriveFile::getPermForAuthUser($directory['basename'],'r');
|
||||
$manage = \App\GoogleDriveFile::getPermForAuthUser($directory['basename'],'p');
|
||||
@endphp
|
||||
<tr class="context-menu-one">
|
||||
@if($read)
|
||||
<td onclick="loadFolder('{{$directory['basename']}}')" style="cursor: pointer;" >
|
||||
<i class="fas fa-folder fa-2x"></i>
|
||||
</td>
|
||||
@else
|
||||
<td>
|
||||
<i class="fas fa-folder fa-2x text-muted"></i>
|
||||
</td>
|
||||
@endif
|
||||
<td @if($read) onclick="loadFolder('{{$directory['basename']}}')" style="cursor: pointer;" @else class="text-muted" @endif>{{$directory['name']}}</td>
|
||||
<td @if($read) class="text-center" onclick="loadFolder('{{$directory['basename']}}')" style="cursor: pointer;" @else class="text-center text-muted" @endif ><span data-toggle="tooltip" data-placement="bottom" title="{{date('r',$directory['timestamp'])}}">{{strftime('%e %b %Y',$directory['timestamp'])}}</span></td>
|
||||
<td class="td-actions text-right">
|
||||
@if($manage)
|
||||
<div class="dropdown">
|
||||
<div id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fas fa-ellipsis-v fa-2x ml-3 text-gray" style="margin-right: .8rem !important;cursor: pointer;"></i>
|
||||
</div>
|
||||
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
|
||||
<a class="dropdown-item" href="/admin/drive/{{$directory['basename']}}/permission">
|
||||
<i class="fas fa-lock mr-2"></i>Permission
|
||||
</a>
|
||||
<a class="dropdown-item text-danger" onclick="deleteFolder('{{ $directory['basename'] }}')">
|
||||
<i class="fas fa-trash-alt mr-2"></i>Supprimer
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
@else
|
||||
@if(!$read)
|
||||
<i class="fas fa-lock text-danger mr-2" data-toggle="tooltip" data-placement="left" title="Vous n'avez pas les permissions nécessaires pour modifier ce dossier"></i>
|
||||
@endif
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@foreach($files as $file)
|
||||
<tr onclick="showfile('{{$file['basename']}}')" style="cursor: pointer;">
|
||||
<td><i class="{{ \App\GoogleDriveFile::icon($file['extension']) }} fa-2x"></i></td>
|
||||
<td>{{$file['name']}}</td>
|
||||
<td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="{{date('r',$file['timestamp'])}}">{{strftime('%e %b %Y',$file['timestamp'])}}</span></td>
|
||||
<td class="td-actions text-right">
|
||||
<i id="fa-{{$file['basename']}}" class="fas fa-angle-down fa-2x pr-2 text-gray"></i>
|
||||
</td>
|
||||
</tr>
|
||||
<tr id="{{$file['basename']}}" class="d-none">
|
||||
<td style="border-top: none" colspan="4">
|
||||
<div class="row">
|
||||
<div class="col-md-2">
|
||||
Type : {{$file['type']}} / {{$file['extension']}}
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
Taille : {{GetSizeName($file['size'])}}
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
Permission : rw
|
||||
</div>
|
||||
<div class="col-md-4 text-right">
|
||||
<a href="/file/get?f={{urlencode($file['name'])}}&d={{$file['dirname']}}" rel="tooltip" class="btn btn-info">
|
||||
<i class="material-icons">cloud_download</i>
|
||||
</a>
|
||||
<button onclick="deleteFile('{{$file['name']}}','{{$file['dirname']}}')" rel="tooltip" class="btn btn-danger text-white">
|
||||
<i class="material-icons">delete</i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@if(count($directories) == 0 && count($files) == 0)
|
||||
<tr>
|
||||
<td colspan="4" class="text-center m-2">
|
||||
Le dossier est vide
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
<small class="float-right mr-4">Dernière mise à jour {{date('r')}}</small>
|
||||
<script>
|
||||
updateHeader('{{$permission['p']}}');
|
||||
</script>
|
||||
@@ -1,19 +0,0 @@
|
||||
<div class="modal fade" id="exampleModalCenter" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true">
|
||||
<div class="modal-dialog modal-dialog-centered" role="document">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="exampleModalLongTitle">Modal title</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
...
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
|
||||
<button type="button" class="btn btn-primary">Save changes</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1,149 +0,0 @@
|
||||
@extends('layouts.admin.main')
|
||||
|
||||
@section('content')
|
||||
<div class="card">
|
||||
<div class="progress progress-bar-top">
|
||||
<div id="progress-bar" class="progress-bar progress-bar-striped progress-bar-animated" role="progressbar" aria-valuenow="50" aria-valuemin="0" aria-valuemax="100" style="width: 0%;"></div>
|
||||
</div>
|
||||
<div class="row ml-3 mr-3 mt-3">
|
||||
<div class="col-sm-1 d-inline-flex">
|
||||
<button id="backbtn" type="button" onclick="goBack()" class="btn btn-secondary" style="border-radius: 50% !important; width: 3.5rem;height: 3.5rem;margin-bottom: -10px;margin-top: -2px" disabled><i class="fas fa-arrow-left fa-2x" aria-hidden="true" style="margin-left: -0.6rem;"></i></button>
|
||||
<button id="refreshbtn" type="button" onclick="refreshFolder()" class="border-0 bg-transparent ml-3 hover-spin cursor active-spin no-outline" style="margin-bottom: -10px;margin-top: -2px;font-size: 1.1rem"><i class="fas fa-sync-alt"></i></button>
|
||||
</div>
|
||||
<div class="col-md-4 col-sm d-flex justify-content-end offset-md-7 mt-2 mt-sm-0">
|
||||
<div class="dropdown mr-md-2 d-none" id="createDropdown">
|
||||
<button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fas fa-plus"></i> Nouveau
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
|
||||
<a class="dropdown-item" data-toggle="modal" data-target="#createFolderModal"><i class="fas fa-folder mr-3"></i> Dossier</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="dropdown d-none" id="uploadDropdown">
|
||||
<button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<i class="fas fa-upload"></i> Téléverser
|
||||
</button>
|
||||
<div class="dropdown-menu" aria-labelledby="dropdownMenuButton">
|
||||
<a class="dropdown-item" data-toggle="modal" data-target="#uploadFileModal"><i class="fas fa-file mr-3"></i> Fichier</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="loader" class="w-100 h-100" style="background-color: #0000007a;position: absolute; z-index: 5;display: none;border-radius: 6px">
|
||||
<div class="d-flex h-100" style="justify-content: center; align-items: center;">
|
||||
@loaderDot
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body mt-0">
|
||||
<div class="drive-explorer" style="min-height: 10rem"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal fade bd-example-modal-lg" tabindex="-1" role="dialog" aria-labelledby="createFileModal" id="createFileModal" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Créer un fichier</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<form action="/file/create" method="post">
|
||||
@csrf
|
||||
<input class="d-none currentDir" type="text" name="currentDir">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label for="exampleFormControlInput1">Nom du fichier</label>
|
||||
<input type="text" class="form-control" id="name" name="name" placeholder="fichier.txt">
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" class="btn btn-primary">Créer</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Annuler</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal fade bd-example-modal-lg" tabindex="-1" role="dialog" aria-labelledby="createFolderModal" id="createFolderModal" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Créer un dossier</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<form action="/folder/create" method="post">
|
||||
@csrf
|
||||
<input class="d-none currentDir" type="text" name="currentDir">
|
||||
<div class="modal-body">
|
||||
<div class="form-group">
|
||||
<label for="exampleFormControlInput1">Nom du dossier</label>
|
||||
<input type="text" class="form-control" id="name" name="name">
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" class="btn btn-primary">Créer</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Annuler</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal fade bd-example-modal-lg" tabindex="-1" role="dialog" aria-labelledby="uploadFileModal" id="uploadFileModal" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Téléverser une fichier</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<form action="/file/upload" method="POST" enctype="multipart/form-data">
|
||||
@csrf
|
||||
<input class="d-none currentDir" type="text" name="currentDir">
|
||||
<div class="modal-body">
|
||||
<div class="form-group bmd-form-group is-filled">
|
||||
<label class="label-control bmd-label-static">Fichier à téléverser (Max 50Mo)</label>
|
||||
<div class="fileinput fileinput-new input-group" data-provides="fileinput" style="display: flex !important;">
|
||||
<div class="form-control" data-trigger="fileinput">
|
||||
<span class="fileinput-filename"></span>
|
||||
</div>
|
||||
<span class="input-group-append">
|
||||
<span class="input-group-text fileinput-exists" data-dismiss="fileinput">Supprimer</span>
|
||||
<span class="input-group-text btn-file">
|
||||
<span class="fileinput-new">Parcourir</span>
|
||||
<span class="fileinput-exists">Modifier</span>
|
||||
<input type="file" name="fichier">
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" class="btn btn-primary">Téléverser</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Annuler</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@section('breadcrumb')
|
||||
Fichier / Google Drive
|
||||
@endsection
|
||||
|
||||
@section('custom_scripts')
|
||||
<script src="/js/plugins/jquery.ui.position.min.js"></script>
|
||||
<script src="/js/plugins/jquery.contextMenu.min.js"></script>
|
||||
<script src="/js/plugins/drive-explorer.js"></script>
|
||||
<script>
|
||||
@if(isset($mode))
|
||||
init("{{$folder}}","{{$mode}}");
|
||||
@else
|
||||
init("{{$folder}}");
|
||||
@endif
|
||||
</script>
|
||||
@endsection
|
||||
@@ -1,266 +0,0 @@
|
||||
@extends('layouts.admin.main')
|
||||
|
||||
@section('content')
|
||||
<div class="col-md-12">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h4 class="card-title">Permission du dossier: {{$dir->name}}</h4>
|
||||
<p class="category">/{{$dir->path}}</p>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<h5>Permission des grades</h5>
|
||||
<table class="table table-striped table-responsive w-100">
|
||||
<thead class="table-dark">
|
||||
<tr class="text-center">
|
||||
<td class="text-left" style="width: 25%">Grade</td>
|
||||
<td >Lecture</td>
|
||||
<td>Écriture</td>
|
||||
<td>Gestion</td>
|
||||
<td style="width: 6rem;">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round m-0" onclick="addPermission('{{$dir->id}}','rank')">
|
||||
<i class="material-icons">add</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="text-center">
|
||||
<td class="text-left">
|
||||
Utilisateur non authentifié
|
||||
</td>
|
||||
<td>
|
||||
@if(isset($dir->rank_permission[0]))
|
||||
@if(strpos($dir->rank_permission[0],'r') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(isset($dir->rank_permission[0]))
|
||||
@if(strpos($dir->rank_permission[0],'w') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(isset($dir->rank_permission[0]))
|
||||
@if(strpos($dir->rank_permission[0],'p') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round" onclick="editPermission('{{$dir->id}}','rank','0')">
|
||||
<i class="material-icons">edit</i>
|
||||
</button>
|
||||
<button class="btn btn-danger btn-fab btn-fab-mini btn-round no-cursor" disabled data-toggle="tooltip" data-placement="bottom" title="Vous ne pouvez pas supprimer les permissions des utilisteurs non authentifié">
|
||||
<i class="material-icons">delete</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
@foreach($dir->rank_permission as $key => $rank)
|
||||
@if($key != 0)
|
||||
<tr class="text-center">
|
||||
<td class="text-left">
|
||||
{{\App\Rank::find($key)->name}}
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'r') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'w') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'p') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round" onclick="editPermission('{{$dir->id}}','rank','{{$key}}')">
|
||||
<i class="material-icons">edit</i>
|
||||
</button>
|
||||
<button class="btn btn-danger btn-fab btn-fab-mini btn-round" onclick="deletePermission('{{$dir->id}}','rank','{{$key}}')">
|
||||
<i class="material-icons">delete</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
<h5 class="mt-5">Permission des postes</h5>
|
||||
<table class="table table-striped table-responsive w-100">
|
||||
<thead class="table-dark">
|
||||
<tr class="text-center">
|
||||
<td class="text-left" style="width: 25%">Poste</td>
|
||||
<td >Lecture</td>
|
||||
<td>Écriture</td>
|
||||
<td>Gestion</td>
|
||||
<td style="width: 6rem;">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round m-0" onclick="addPermission('{{$dir->id}}','job')">
|
||||
<i class="material-icons">add</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if(count($dir->job_permission) < 1)
|
||||
<tr>
|
||||
<td colspan="5" class="text-center">
|
||||
Aucune permission de poste
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
@foreach($dir->job_permission as $key => $rank)
|
||||
<tr class="text-center">
|
||||
<td class="text-left">
|
||||
{{\App\Job::find($key)->name}}
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'r') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'w') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'p') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round" onclick="editPermission('{{$dir->id}}','job','{{$key}}')">
|
||||
<i class="material-icons">edit</i>
|
||||
</button>
|
||||
<button class="btn btn-danger btn-fab btn-fab-mini btn-round" onclick="deletePermission('{{$dir->id}}','job','{{$key}}')">
|
||||
<i class="material-icons">delete</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
<h5 class="mt-5">Permission des utilisateurs</h5>
|
||||
<table class="table table-striped table-responsive w-100">
|
||||
<thead class="table-dark">
|
||||
<tr class="text-center">
|
||||
<td class="text-left" style="width: 25%">Utilisateurs</td>
|
||||
<td >Lecture</td>
|
||||
<td>Écriture</td>
|
||||
<td>Gestion</td>
|
||||
<td style="width: 6rem;">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round m-0" onclick="addPermission('{{$dir->id}}','user')">
|
||||
<i class="material-icons">add</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if(count($dir->user_permission) < 1)
|
||||
<tr>
|
||||
<td colspan="5" class="text-center">
|
||||
Aucune permission d'utilisateur
|
||||
</td>
|
||||
</tr>
|
||||
@endif
|
||||
@foreach($dir->user_permission as $key => $rank)
|
||||
<tr class="text-center">
|
||||
<td class="text-left">
|
||||
{{\App\User::find($key)->fullname()}}
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'r') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'w') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if(strpos($rank,'p') !== false)
|
||||
<i class="fas fa-check-circle fa-2x text-success"></i>
|
||||
@else
|
||||
<i class="fas fa-times-circle fa-2x text-danger"></i>
|
||||
@endif
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<button class="btn btn-primary btn-fab btn-fab-mini btn-round" onclick="editPermission('{{$dir->id}}','user','{{$key}}')">
|
||||
<i class="material-icons">edit</i>
|
||||
</button>
|
||||
<button class="btn btn-danger btn-fab btn-fab-mini btn-round" onclick="deletePermission('{{$dir->id}}','user','{{$key}}')">
|
||||
<i class="material-icons">delete</i>
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@csrf
|
||||
<button type="button" class="btn btn-primary" data-toggle="modal" data-target=".bd-example-modal-lg">Large modal</button>
|
||||
|
||||
<div id="permissionModal" class="modal fade bd-example-modal-lg" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog modal-lg">
|
||||
<div class="modal-content" id="permissionModalHtml">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Chargement ...</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
@loaderDot
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-primary" disabled>Sauvegarder</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Annuler</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@section('custom_scripts')
|
||||
<script src="/js/plugins/jquery.ui.position.min.js"></script>
|
||||
<script src="/js/plugins/jquery.contextMenu.min.js"></script>
|
||||
<script src="/js/plugins/drive-explorer.js"></script>
|
||||
@endsection
|
||||
@@ -1,81 +0,0 @@
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Modification des permissions</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<form action="/admin/drive/{{$folder->id}}/addpermission/{{$s}}" method="post">
|
||||
<input id="csrf" type="hidden" name="_token" value="">
|
||||
@method('patch')
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
@if($s == 'rank')
|
||||
<select class="selectpicker" name="id" data-style="btn btn-primary btn-round" title="Grade" required>
|
||||
@foreach($list as $l)
|
||||
<option value="{{$l->id}}">{{$l->name}}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
@elseif($s == 'job')
|
||||
<select class="selectpicker" name="id" data-style="btn btn-primary btn-round" title="Poste" required>
|
||||
@foreach($list as $l)
|
||||
<option value="{{$l->id}}">{{$l->name}}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
@else
|
||||
<select class="selectpicker" name="id" data-style="btn btn-primary btn-round" title="Utilisateur" required>
|
||||
@foreach($list as $l)
|
||||
<option value="{{$l->id}}">{{$l->fullname()}}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
@endif
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="togglebutton row">
|
||||
<div class="col-3">
|
||||
<label>
|
||||
<input name="read" type="checkbox">
|
||||
<span class="toggle"></span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<label>Peux consulter les fichiers a l'intérieur du dossier</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="togglebutton row">
|
||||
<div class="col-3">
|
||||
<label>
|
||||
<input name="write" type="checkbox">
|
||||
<span class="toggle"></span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<label>Peux modifier les fichiers a l'intérieur du dossier</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="togglebutton row">
|
||||
<div class="col-3">
|
||||
<label>
|
||||
<input name="perm" type="checkbox">
|
||||
<span class="toggle"></span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<label>Peux gérer le dossier</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" class="btn btn-primary">Sauvegarder</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Annuler</button>
|
||||
</div>
|
||||
<script>
|
||||
$('select').selectpicker();
|
||||
</script>
|
||||
</form>
|
||||
@@ -1,70 +0,0 @@
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title">Modification des permissions</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<form action="/admin/drive/{{$folder->id}}/permission/{{$s}}/{{$subject->id}}" method="post">
|
||||
<input id="csrf" type="hidden" name="_token" value="">
|
||||
@method('patch')
|
||||
<div class="modal-body">
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
@switch($s)
|
||||
@case('rank')
|
||||
Grade : {{$subject->name}}
|
||||
@break
|
||||
@case('job')
|
||||
Poste : {{$subject->name}}
|
||||
@break
|
||||
@case('user')
|
||||
Utilisateur : {{$subject->fullname()}}
|
||||
@break
|
||||
@endswitch
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="togglebutton row">
|
||||
<div class="col-3">
|
||||
<label>
|
||||
<input name="read" type="checkbox" @if(strpos($perm,'r') !== false) checked @endif>
|
||||
<span class="toggle"></span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<label>Peux consulter les fichiers a l'intérieur du dossier</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="togglebutton row">
|
||||
<div class="col-3">
|
||||
<label>
|
||||
<input name="write" type="checkbox" @if(strpos($perm,'w') !== false) checked @endif>
|
||||
<span class="toggle"></span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<label>Peux modifier les fichiers a l'intérieur du dossier</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3">
|
||||
<div class="togglebutton row">
|
||||
<div class="col-3">
|
||||
<label>
|
||||
<input name="perm" type="checkbox" @if(strpos($perm,'p') !== false) checked @endif>
|
||||
<span class="toggle"></span>
|
||||
</label>
|
||||
</div>
|
||||
<div class="col">
|
||||
<label>Peux gérer le dossier</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="submit" class="btn btn-primary">Sauvegarder</button>
|
||||
<button type="button" class="btn btn-secondary" data-dismiss="modal">Annuler</button>
|
||||
</div>
|
||||
</form>
|
||||
@@ -1,154 +1,17 @@
|
||||
@extends('layouts.admin.main')
|
||||
|
||||
@section('content')
|
||||
<div class="col-md-12">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<strong class="card-title">Fichiers <a href="#"><i class="fa fa-question-circle" aria-hidden="true"></i>
|
||||
</a></strong>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="content">
|
||||
<p>Les fichiers si dessous sont disponible autant dans l'espace administration que dans l'espace cadet cadre.</p>
|
||||
<table class="table table-striped dt-responsive material-datatables" id="table" style="width:100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Nom</th>
|
||||
<th>Catégorie</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Plan de cours Vierge</td>
|
||||
<td>Plan de cours</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1i1a0sjI8I3nzt4mlcLvznjqYF-12JgfQ">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Mini Ordre Operation Projet Soirée Journée Vierge</td>
|
||||
<td>Ordre d'opération</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1sqkeUp-djZDjltitGvjR0efMQgyB_sos">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Mini Ordre Operation Vierge</td>
|
||||
<td>Ordre d'opération</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1RjSSwK9NIVUFbHKlu0hbkK5IeTnAFWq9">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Liste des tenues</td>
|
||||
<td>Tenues</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1JUXaPQhHGJffE7CTnB1BAkqwM8g9t8ef">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Cadet commandant</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1DdI9eOptKarpApsUdO-6gkDFYtD6DHi8">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Cadet commandant adjoint</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1jDuKQzY3Dam0J9mSGDWiv2I1agDYacRm">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Chef entrainement</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=12p8rGhSZloPFurD--RZO9KQVoRmXAEnE">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Instructeur sénior</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=13fNufhR2hYhKgeiHUo0W_V-vF_W8SPkC">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Instructeur</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1Y1gEsNP7mz2SmJPwxi7YUfpxgioJKvR0">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Assistant Instructeur</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1BxKj0J20QZ5hVQ1womwS8GUWvuq-VsJy">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Commandant de section</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1jOmyNFZ2rSOwCFjcoABx6VFcvEMKCf73">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Commandant de la garde</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=18T3rQQ-RN551meOGGPD8Ni2wbpvKNfYz">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Commandant adjoint de section</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1A5NkPhSJ5E-bIPiLRwa7VAOXQrrHIzn6">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Commandant adjoint de garde</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1ncphhTpBm9uhq0isGFNzDs_-TRPrxfKw">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Cadet cadre de la logistique</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1PcmlegtAqmdX2ufGQMubkNxfkrCcSIge">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Cadet cadre de l'administration</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1haEG9jSabp10VtI7EV2OyLctn9-63T8G">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Commandant adjoint de section</td>
|
||||
<td>Énoncé de fonction</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1A5NkPhSJ5E-bIPiLRwa7VAOXQrrHIzn6">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Information NECPC</td>
|
||||
<td>Divers</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1KG0IoPxpqctqqVwCfM0WyKq4y6RDBtUJ">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Évaluation pratique sur la coordination d’un ordre d’opération sur le terrain</td>
|
||||
<td>Divers</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=1AAPB7IdpIw8UGJwIoTNQZ3cg9ODfWrAp">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>RENCONTRE PRÉILIMINAIRE D’INSTRUCTION</td>
|
||||
<td>Divers</td>
|
||||
<td><a class="btn btn-primary btn-block" href="https://drive.google.com/uc?export=download&id=16lT4YzNjGWd2SFmgSbmj1LcPG9cDkkyo">Télécharger</a></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Liste nominal des cadets</td>
|
||||
<td>Divers</td>
|
||||
<td><a class="btn btn-primary btn-block" href="{{\App\Config::getData('cadet_list')}}">Télécharger</a></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div style="height: 600px;">
|
||||
<div id="fm"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@section('breadcrumb')
|
||||
Fichier / Autres
|
||||
Fichier / Explorer
|
||||
@endsection
|
||||
|
||||
@section('custom_scripts')
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
$('#table').DataTable({
|
||||
"lengthMenu": [[25, 50, -1], [25, 50, "All"]],
|
||||
"ordering" : false,
|
||||
"rowGroup": {
|
||||
dataSrc: 1
|
||||
},
|
||||
"columnDefs": [
|
||||
{ "visible": false, "targets": 1 }
|
||||
]
|
||||
});
|
||||
} );
|
||||
</script>
|
||||
<script src="{{ asset('vendor/file-manager/js/file-manager.js') }}"></script>
|
||||
@endsection
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
<link rel="stylesheet" href="/js/plugins/fontawesome-icon-picker/fontawesome-iconpicker.css">
|
||||
<link rel="stylesheet" href="/css/monolith.min.css"/>
|
||||
<link rel="stylesheet" href="/css/contextLoader.min.css">
|
||||
<link rel="stylesheet" href="{{ asset('vendor/file-manager/css/file-manager.css') }}">
|
||||
|
||||
<!-- Custom CSS -->
|
||||
<link rel="stylesheet" href="/css/custom.css">
|
||||
|
||||
Reference in New Issue
Block a user