<?php $id = $id ?? null; ?>
<?php if(isset($id)): ?>
    <?php echo e(Form::model($data, ['route' => ['clientreview.update', $id], 'method' => 'patch','enctype' => 'multipart/form-data'])); ?>

<?php else: ?>
    <?php echo e(Form::open(['route' => ['clientreview.store'], 'method' => 'post','enctype' => 'multipart/form-data'])); ?>

<?php endif; ?>
<?php echo Form::hidden('type', 'client_review'); ?>

<div class="modal-dialog modal-dialog-centered modal-xl" role="document">
    <div class="modal-content">
        <div class="modal-header">
            <h5 class="modal-title" id="exampleModalLabel"><?php echo e(__($pageTitle)); ?></h5>
            <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                <span aria-hidden="true">&times;</span>
            </button>
        </div>
        <div class="modal-body">
            <div class="form-group col-md-12">
                <?php echo e(Form::label('title', __('message.name') . ' <span class="text-danger">*</span>', ['class' => 'form-control-label'], false)); ?>

                <?php echo e(Form::text('title', old('title'), ['placeholder' => __('message.name'), 'class' => 'form-control', 'required'])); ?>

                <span class="text-danger" id = "ajax_form_validation_title"></span>
            </div>
            <div class="form-group col-md-12">
                <?php echo e(Form::label('subtitle', __('message.email') . ' <span class="text-danger">*</span>', ['class' => 'form-control-label'], false)); ?>

                <?php echo e(Form::text('subtitle', old('subtitle'), ['placeholder' => __('message.email'), 'class' => 'form-control', 'required'])); ?>

                <span class="text-danger" id = "ajax_form_validation_subtitle"></span>
            </div>
            <div class="form-group col-md-12">
                <?php echo e(Form::label('description', __('message.review'). ' <span class="text-danger">*</span>',['class' => 'form-control-label'],false)); ?>

                <?php echo e(Form::textarea('description',old('description'), ['class' => 'form-control textaraea', 'rows' => 2, 'placeholder' => __('message.review')])); ?>

                <span class="text-danger" id = "ajax_form_validation_description"></span>
            </div>
            <div class="row ml-1">
                <div class="form-group col-md-4">
                    <?php echo e(Form::label('frontend_data_image', __('message.image'), ['class' => 'form-control-label'])); ?>

                    <div class="custom-file">
                        <?php echo e(Form::file('frontend_data_image', ['class' => 'custom-file-input', 'id' => 'frontend_data_image', 'lang' => 'en', 'accept' => 'image/*'])); ?>

                        <label class="custom-file-label"
                            for="frontend_data_image"><?php echo e(__('message.choose_file', ['file' => __('message.image')])); ?></label>
                    </div>
                </div>
                <div class="col-md-2 mb-2">
                    <?php if(isset($id) && getMediaFileExit($data, 'frontend_data_image')): ?>
                        <img src="<?php echo e(getSingleMedia($data, 'frontend_data_image' ?? 'images/default.png')); ?>"
                            alt="image" class="attachment-image mt-1">
                    <?php endif; ?>
                </div>
            </div>
        </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-md btn-secondary" data-dismiss="modal"><?php echo e(__('message.close')); ?></button>
                <button type="submit" class="btn btn-md btn-primary" id="btn_submit" data-form="ajax-submite-jquery-validation"><?php echo e(isset($id) ? __('message.update') : __('message.save')); ?></button>
            </div>
    </div>
</div>
<?php echo e(Form::close()); ?>


<?php /**PATH /www/wwwroot/mxunzo.atharvatek.com/resources/views/clientreview/model.blade.php ENDPATH**/ ?>