@extends('admin.layouts.index') @include('admin.layouts.components.asset_validasi') @include('admin.layouts.components.asset_colorpicker') @section('title')

Pengaturan Tema Ubah Data

@endsection @section('breadcrumb')
  • Ubah Data
  • @endsection @section('content') @include('admin.layouts.components.notifikasi')
    Kembali ke Tema
    @php $daftarPengaturan = collect($tema->config); $pengaturanUnggah = $daftarPengaturan ->filter(function ($item) { return $item['type'] == 'unggah'; }) ->all(); $viewUnggah = count($pengaturanUnggah) > 0; $pengaturanInput = $daftarPengaturan ->filter(function ($item) { return $item['type'] != 'unggah'; }) ->all(); @endphp @if (count($pengaturanInput) > 0) {!! form_open_multipart($form_action, 'id="validasi"') !!} @php $col = 9 @endphp @if ($viewUnggah) @foreach ($pengaturanUnggah as $key => $value)
    @include("admin.theme.components.form.{$value['type']}", [ 'value' => [ 'judul' => $value['judul'], 'key' => $value['key'], 'default' => $tema->opsi[$value['key']] ?? $value['value'], 'readonly' => $value['readonly'], ], ])
    @endforeach @else @php $col = 12 @endphp @endif
    @foreach ($pengaturanInput as $key => $value) @if (view()->exists("admin.theme.components.form.{$value['type']}"))
    @php $value['default'] = $tema->opsi[$value['key']] ?? $value['value']; $value['readonly'] = $value['readonly'] == true ? 'readonly' : ''; $value['class'] = $value['attributes']['class']; unset($value['attributes']['class'], $value['attributes']['readonly']); if (!empty($value['attributes'])) { $value['attributes'] = implode( ' ', array_map( function ($key, $value) { return "$key=\"$value\""; }, array_keys($value['attributes']), $value['attributes'], ), ); } @endphp @include("admin.theme.components.form.{$value['type']}", [ 'value' => $value, ])
    @endif @endforeach
    @else

    Info

    Pengaturan untuk tema ini belum tersedia. @if (!$tema->sistem) Salin Config @endif
    @endif
    @endsection