diff --git a/app/helpers.php b/app/helpers.php index 6894fa1..8fb5c3c 100755 --- a/app/helpers.php +++ b/app/helpers.php @@ -150,7 +150,7 @@ function str_split_ucwords($string) * @param int $bytes File size. * @return string Converted file size with unit. */ -function formatSizeUnits($bytes) +function format_size_units($bytes) { if ($bytes >= 1073741824) { $bytes = number_format($bytes / 1073741824, 2).' GB'; diff --git a/resources/views/backups/index.blade.php b/resources/views/backups/index.blade.php index 8976fdc..d9efab9 100644 --- a/resources/views/backups/index.blade.php +++ b/resources/views/backups/index.blade.php @@ -24,7 +24,7 @@ {{ $key + 1 }} {{ $backup->getFilename() }} - {{ formatSizeUnits($backup->getSize()) }} + {{ format_size_units($backup->getSize()) }} {{ date('Y-m-d H:i:s', $backup->getMTime()) }} name) +@section('title', __('project.files').' | '.$project->name) @section('content') -@include('projects.partials.breadcrumb',['title' => trans('project.files')]) +@include('projects.partials.breadcrumb',['title' => __('project.files')])

- {{ $project->name }} {{ trans('project.files') }} + {{ $project->name }} {{ __('project.files') }}

@include('projects.partials.nav-tabs') @@ -14,16 +14,16 @@
-

{{ trans('project.files') }}

+

{{ __('project.files') }}

- - - - - - + + + + + + @forelse($files as $key => $file) @@ -37,16 +37,16 @@
{{ $file->getDate() }}
{{ $file->getTime() }}
- + @empty - + @endforelse
{{ trans('app.table_no') }}{{ trans('file.file') }}{{ trans('file.updated_at') }}{{ trans('file.size') }}{{ trans('file.download') }}{{ trans('app.action') }}{{ __('app.table_no') }}{{ __('file.file') }}{{ __('file.updated_at') }}{{ __('file.size') }}{{ __('file.download') }}{{ __('app.action') }}
{{ formatSizeUnits($file->getSize()) }}{{ format_size_units($file->getSize()) }} - {!! html_link_to_route('files.download', '', [$file->id], ['icon' => 'file', 'title' => trans('file.download')]) !!} + {!! html_link_to_route('files.download', '', [$file->id], ['icon' => 'file', 'title' => __('file.download')]) !!} - {!! html_link_to_route('projects.files', '', [$project->id, 'action' => 'edit', 'id' => $file->id], ['icon' => 'edit', 'title' => trans('file.edit')]) !!} + {!! html_link_to_route('projects.files', '', [$project->id, 'action' => 'edit', 'id' => $file->id], ['icon' => 'edit', 'title' => __('file.edit')]) !!}
{{ trans('file.empty') }}
{{ __('file.empty') }}
@@ -55,27 +55,27 @@
@if (Request::has('action') == false)
-

{{ trans('file.create') }}

+

{{ __('file.create') }}

{!! Form::open(['route' => ['files.upload', $project->id], 'id' => 'upload-file', 'files' => true]) !!} {{ Form::hidden('fileable_type', get_class($project)) }} - {!! FormField::file('file', ['label' => trans('file.select')]) !!} + {!! FormField::file('file', ['label' => __('file.select')]) !!} {!! FormField::text('title') !!} {!! FormField::textarea('description') !!} - {!! Form::submit(trans('file.upload'), ['class' => 'btn btn-info']) !!} + {!! Form::submit(__('file.upload'), ['class' => 'btn btn-info']) !!} {!! Form::close() !!}
@endif @if (Request::get('action') == 'edit' && $editableFile)
-

{{ trans('file.edit') }} : {{ $editableFile->title }}

+

{{ __('file.edit') }} : {{ $editableFile->title }}

{!! Form::model($editableFile, ['route' => ['files.update', $editableFile->id],'method' => 'patch']) !!} - {!! FormField::text('title', ['label' => trans('file.title'), 'required' => true]) !!} - {!! FormField::textarea('description', ['label' => trans('file.description')]) !!} - {!! Form::submit(trans('file.update'), ['class' => 'btn btn-success']) !!} - {{ link_to_route('projects.files', trans('app.cancel'), [$project->id], ['class' => 'btn btn-default']) }} + {!! FormField::text('title', ['label' => __('file.title'), 'required' => true]) !!} + {!! FormField::textarea('description', ['label' => __('file.description')]) !!} + {!! Form::submit(__('file.update'), ['class' => 'btn btn-success']) !!} + {{ link_to_route('projects.files', __('app.cancel'), [$project->id], ['class' => 'btn btn-default']) }} {!! Form::close() !!}
@@ -84,4 +84,4 @@
-@endsection \ No newline at end of file +@endsection diff --git a/resources/views/reports/log-files.blade.php b/resources/views/reports/log-files.blade.php index a651c9f..16b2c50 100755 --- a/resources/views/reports/log-files.blade.php +++ b/resources/views/reports/log-files.blade.php @@ -1,11 +1,9 @@ @extends('layouts.app') -@section('title','Log Files') +@section('title', 'Log Files') @section('content') - +
@@ -15,35 +13,33 @@ Nama File Ukuran Tanggal Jam - {{ trans('app.action') }} + {{ __('app.action') }} @forelse($logFiles as $key => $logFile) {{ $key + 1 }} {{ $logFile->getFilename() }} - {{ formatSizeUnits($logFile->getSize()) }} + {{ format_size_units($logFile->getSize()) }} {{ date('Y-m-d H:i:s', $logFile->getMTime()) }} - {!! html_link_to_route('log-files.download','',[$logFile->getFilename()],[ + {!! html_link_to_route('log-files.download', '', [$logFile->getFilename()], [ 'class'=>'btn btn-default btn-xs', 'icon' => 'download', - 'id' => 'download-' . $logFile->getFilename(), - 'title' => 'Download file ' . $logFile->getFilename() + 'id' => 'download-'.$logFile->getFilename(), + 'title' => 'Download file '.$logFile->getFilename() ]) !!} - {!! html_link_to_route('log-files.show','',[$logFile->getFilename()],[ + {!! html_link_to_route('log-files.show', '', [$logFile->getFilename()], [ 'class'=>'btn btn-default btn-xs', 'icon' => 'search', - 'id' => 'view-' . $logFile->getFilename(), - 'title' => 'View file ' . $logFile->getFilename(), + 'id' => 'view-'.$logFile->getFilename(), + 'title' => 'View file '.$logFile->getFilename(), 'target' => '_blank', ]) !!} @empty - - Belum ada file logFile - + Belum ada file logFile @endforelse