edms/resources/views/admin/languages/view.blade.php

72 lines
2.3 KiB
PHP

@extends('admin.layouts.master')
@section('pageTitle', 'View Language')
@section('content')
<div class="page-header">
<h1 class="page-title">Manage Languages</h1>
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="{{ route('dashboard') }}">Dashboard</a></li>
<li class="breadcrumb-item active">View Language</li>
</ol>
<div class="page-header-actions">
<a class="btn btn-dark" href="{{ route('languages') }}">
<i class="icon wb-arrow-left" aria-hidden="true"></i>
<span class="hidden-sm-down">Back To Listing</span>
</a>
</div>
</div>
<div class="page-content container-fluid">
<div class="row">
<div class="col-md-12">
<div class="language-background card card-shadow">
<div class="card-header card-header-transparent p-20">
<h4 class="card-title mb-0">{{ $language->name }}</h4>
</div>
<div class="card-block">
<form class="form-horizontal" action="{{ route('languages.key_value_store') }}" method="POST">
@csrf
<input type="hidden" name="id" value="{{ $language->id }}">
<div class="panel-body">
<table class="table table-hover dataTable table-striped w-full" data-plugin="dataTable" cellspacing="0" width="100%">
<thead>
<tr>
<th>{{__('Key')}}</th>
<th width="45%">{{__('Value')}}</th>
</tr>
</thead>
<tbody>
@php
$i = 1;
@endphp
@foreach (openJSONFile('en') as $key => $value)
<tr>
<td>{{ $key }}</td>
<td>
<div class="col-lg-12">
<input type="text" class="form-control" style="width:100%" name="key[{{ $key }}]" @isset(openJSONFile($language->short_name)[$key])
value="{{ openJSONFile($language->short_name)[$key] }}"
@endisset>
</div>
</td>
</tr>
@php
$i++;
@endphp
@endforeach
</tbody>
</table>
</div>
<div class="panel-footer">
<button type="submit" class="btn btn-success"><i class="icon wb-check" aria-hidden="true"></i> {{ __('Save') }}</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
@endsection