

<?php $__env->startSection('content'); ?>
<div class="container">
    <div class="container-header">
        <h1><?php echo e($pageTitle); ?></h1>
    </div>
    <div class="card">
        <div class="card-body">
            <form action="<?php echo e(isset($service) ? route('backend.service.update', $service->id) : route('backend.service.store')); ?>" method="post">
                <?php echo csrf_field(); ?>
                <?php if(isset($service)): ?> <?php echo method_field('PUT'); ?> <?php endif; ?>
                <div class="form-group mb-25">
                    <label class="form-label">Server <span class="required">*</span></label>
                    <select name="otp_server_id" class="form-control" required>
                        <?php $__currentLoopData = $servers; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $s): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <option value="<?php echo e($s->id); ?>" <?php echo e(old('otp_server_id', $service->otp_server_id ?? '') == $s->id ? 'selected' : ''); ?>><?php echo e($s->server_name); ?></option>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                    </select>
                </div>
                <div class="form-group mb-25">
                    <label class="form-label">Service Name <span class="required">*</span></label>
                    <input type="text" class="form-control" name="service_name" value="<?php echo e(old('service_name', $service->service_name ?? '')); ?>" required>
                </div>
                <div class="form-group mb-25">
                    <label class="form-label">Service Code (external ID) <span class="required">*</span></label>
                    <input type="text" class="form-control" name="service_code" value="<?php echo e(old('service_code', $service->service_code ?? '')); ?>" required>
                </div>
                <div class="form-group mb-25">
                    <label class="form-label">Price <span class="required">*</span></label>
                    <input type="number" step="0.01" class="form-control" name="service_price" value="<?php echo e(old('service_price', $service->service_price ?? '')); ?>" required>
                </div>
                <div class="form-group mb-25">
                    <label class="form-label">Status</label>
                    <select name="status" class="form-control">
                        <option value="1" <?php echo e(old('status', $service->status ?? 1) == 1 ? 'selected' : ''); ?>>Active</option>
                        <option value="0" <?php echo e(old('status', $service->status ?? 0) == 0 ? 'selected' : ''); ?>>Inactive</option>
                    </select>
                </div>
                <button type="submit" class="btn btn-primary">Save</button>
            </form>
        </div>
    </div>
</div>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('backend.layout.app', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH C:\Users\HP\Desktop\nbverify\mine\resources\views/backend/services/form.blade.php ENDPATH**/ ?>