47 lines
		
	
	
		
			2.9 KiB
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			47 lines
		
	
	
		
			2.9 KiB
		
	
	
	
		
			PHP
		
	
	
	
	
	
@section('meta_title', __('admin-sections.Setting up automatic translation') . '. ' . __('admin-sections.Project') . ': ' . $project->name)
 | 
						|
@section('h1', __('admin-sections.Setting up automatic translation') . '. ' . __('admin-sections.Project') . ': ' . $project->name)
 | 
						|
<x-admin.layout>
 | 
						|
    <div class="row">
 | 
						|
        <div class="col-12 mb-4">
 | 
						|
            <div class="card border-0 shadow components-section">
 | 
						|
                <div class="card-body">
 | 
						|
                    <form method="post" action="{{ route('admin.projects.service-translate.update', ['project' => $project->id]) }}">
 | 
						|
                        @csrf
 | 
						|
                        <div class="table-responsive">
 | 
						|
                            <table class="table table-centered table-nowrap mb-0 rounded">
 | 
						|
                                <thead class="thead-light">
 | 
						|
                                <tr>
 | 
						|
                                    <th class="border-0">{{ __('validation.attributes.lang') }}</th>
 | 
						|
                                    <th class="border-0">{{ __('validation.attributes.code') }}</th>
 | 
						|
                                    <th class="border-0">{{ __('validation.attributes.translate_from_language') }}</th>
 | 
						|
                                    <th class="border-0 rounded-end" style="width: 150px"></th>
 | 
						|
                                </tr>
 | 
						|
                                </thead>
 | 
						|
                                <tbody>
 | 
						|
                                    @foreach($languages as $index => $language)
 | 
						|
                                        <tr>
 | 
						|
                                            <td>{{ $language->title }}</td>
 | 
						|
                                            <td>
 | 
						|
                                                <x-volt.forms.input title="" name="language[{{ $index }}][code]" type="text" :value="$language->serviceTranslate?->code" />
 | 
						|
                                            </td>
 | 
						|
                                            <td>
 | 
						|
                                                <x-volt.forms.select title="" name="language[{{ $index }}][source_language_id]" :value="(string) $language->serviceTranslate?->source_language_id" :list="$languages->pluck('title', 'id')->toArray()">
 | 
						|
                                                    <option value=""></option>
 | 
						|
                                                </x-volt.forms.select>
 | 
						|
                                            </td>
 | 
						|
                                            <td>
 | 
						|
                                                <input type="hidden" value="{{ $language->id }}" name="language[{{ $index }}][id]" />
 | 
						|
                                            </td>
 | 
						|
                                        </tr>
 | 
						|
                                    @endforeach
 | 
						|
                                </tbody>
 | 
						|
                            </table>
 | 
						|
                        </div>
 | 
						|
                        <button class="btn btn-primary" type="submit">{{ __('Save') }}</button>
 | 
						|
                    </form>
 | 
						|
                </div>
 | 
						|
            </div>
 | 
						|
        </div>
 | 
						|
    </div>
 | 
						|
</x-admin.layout>
 |