<?php $__env->startSection('content'); ?>
	<div class="row">
    	<div class="col-lg-12">
    		<h1 class="page-header"><?php echo e($property_ticket->name); ?></h1>
    	</div>
    </div>
    <div class="row">
        <div class="col-lg-12">
            <?php if(session('status')): ?>
			<div class="alert alert-success">
				<?php echo e(session('status')); ?>

			</div>
			<?php endif; ?>
			<?php if(count($errors) > 0): ?>
				<div class="alert alert-danger">
					<strong>Whoops!</strong> There were some problems with your input.<br><br>
					<ul>
						<?php foreach($errors->all() as $error): ?>
							<li><?php echo e($error); ?></li>
						<?php endforeach; ?>
					</ul>
				</div>
			<?php endif; ?>
				<?php if($property_ticket->assigned_user): ?>
				<div class="col-lg-2 section">
					<label>Assigned To</label>
					<p><?php echo e(App\User::find($property_ticket->assigned_user)['name']); ?></p>	
				</div>
				<?php endif; ?>
				<?php if($property_ticket->due_date): ?>
				<div class="col-lg-2 section">
					<label>Due Date</label>
					<p><?php echo e(date_create($property_ticket->due_date)->format('Y-m-d')); ?></p>	
				</div>
				<?php endif; ?>
				<?php if($property_ticket->priority): ?>
				<div class="col-lg-2 section">
					<label>Priority</label>
					<p><?php echo e(ucfirst($property_ticket->priority)); ?></p>	
				</div>
				<?php endif; ?>
				<div class="col-lg-2 section">
					<label>Property</label>
					<p><a target="_blank" href="<?php echo e(url('uadmin/properties/view/'.$property_ticket->property)); ?>"><?php echo e(App\Property::find($property_ticket->property)->select('name')->first()['name']); ?></a></p>
				</div>
				<div class="col-lg-12 section">
					<label>Instructions</label>
					<p><?php echo e($property_ticket->description); ?></p>	
				</div>
				<form id="theForm" class="form-horizontal" style="margin-bottom: 0px;" role="form" method="POST" enctype="multipart/form-data" action="<?php echo e(url('admin/properties/ticket/completed')); ?>">
					<div class="col-sm-12 col-md-4 section">
						<label>Attachments</label>
						<input type="file" class="form-control" id="attachments" name="attachments[]" value="<?php echo e(old('attachments')); ?>"  title="Attachments" multiple>
					</div>
					<div class="col-sm-12 col-md-8 section">
						<label class="label-control col-sm-12 col-md-12">Notes</label>
						<div class="col-sm-12 col-md-12 morePadding morePadding2" onclick="inputFocus('notes')">
							<textarea class="form-control" style="max-width: 100%;" id="notes" name="notes" title="Notes" placeholder="Notes"><?php echo e(old('notes')); ?></textarea>
						</div>
					</div>
					<div class="col-lg-12 section">
						<input type="hidden" name="_token" value="<?php echo e(csrf_token()); ?>">
						<input type="hidden" name="ticketID" value="<?php echo e($property_ticket->id); ?>">
						<button type="submit" class="btn btn-primary" style="">
							Mark as Completed
						</button>
					</div>
				</form>
		</div>
	</div>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('extras'); ?>
	<style>
		.section{
			margin-bottom: 20px;
		}
	</style>
<?php $__env->stopSection(); ?>

<?php $__env->startSection('bottom'); ?>

<?php $__env->stopSection(); ?>

<?php echo $__env->make('residential.templates.uadmin', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>