<?php if($company): ?>
	<div class="box" id="address-residence-form">
		<div class="box-header">
			<h5 class="box-title"><?php echo e(__('forms.BusinessAddress')); ?></h5>
		</div>
		<div class="box-body pb-2">
			
			<form action="<?php echo e(route('crm.companies.addresses.updateResidence', [$company, $company->lastActiveResidence->id])); ?>"
				method="POST">
				<?php echo csrf_field(); ?>
				<?php echo method_field('put'); ?>

				<input type="hidden" name="type" value="Residence">

				
				<div class="grid grid-cols-1 gap-x-6 mb-6">
					<div>
						<label for="residence_line_1" class="ti-form-label <?php $__errorArgs = ['residence.line_1'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> error <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>">
							<?php $__errorArgs = ['residence.line_1'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
								<?php echo e($message); ?>

							<?php else: ?>
								<?php echo e(__('forms.Address')); ?>

							<?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>
						</label>
						<input id="residence_line_1" type="text" name="residence[line_1]"
							value="<?php echo e(old('residence.line_1') ?? $company->lastActiveResidence?->line_1); ?>"
							class="ti-form-input shadow-sm <?php $__errorArgs = ['residence.line_1'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> border-red-500 <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>"
							placeholder="<?php echo e(__('forms.Address')); ?>" <?php echo e($readonly ? 'disabled' : ''); ?>>
					</div>
				</div>

				
				<div class="mb-6">
					<label for="residence_city_id_update" class="ti-form-label <?php $__errorArgs = ['residence.city_id'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> error <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>">
						<?php $__errorArgs = ['residence.city_id'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?>
							<?php echo e($message); ?>

						<?php else: ?>
							<?php echo e(__('forms.Town')); ?>

						<?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>
					</label>
					<select id="residence_city_id_update"
						class="ti-form-select py-1 <?php $__errorArgs = ['residence.city_id'];
$__bag = $errors->getBag($__errorArgs[1] ?? 'default');
if ($__bag->has($__errorArgs[0])) :
if (isset($message)) { $__messageOriginal = $message; }
$message = $__bag->first($__errorArgs[0]); ?> border-red-500 <?php unset($message);
if (isset($__messageOriginal)) { $message = $__messageOriginal; }
endif;
unset($__errorArgs, $__bag); ?>" name="residence[city_id]"
						<?php echo e($readonly ? 'disabled' : ''); ?>>
						<!-- City options -->
					</select>
				</div>

				<?php if(!$readonly): ?>
					<div class="flex justify-between">
						<div></div>
						<button type="submit" class="ti-btn ti-btn-outline-success py-1 px-3 mr-0">
							<span><?php echo e(__('forms.Update')); ?></span>
						</button>
					</div>
				<?php endif; ?>
			</form>

		</div>
	</div>
<?php endif; ?>
<?php /**PATH C:\laragon\www\policypilot\resources\views/backend/crm/companies/forms/address-residence-form-edit.blade.php ENDPATH**/ ?>