@extends('header') @section('head') @parent @stop @section('content')
{!! Former::open('projects/bulk')->autocomplete('off')->addClass('mainForm') !!}
{!! Former::text('action') !!} {!! Former::text('public_id')->value($project->public_id) !!}
@if ( ! $project->is_deleted) @can('edit', $project) {!! DropdownButton::normal(trans('texts.edit_project')) ->withAttributes(['class'=>'normalDropDown']) ->withContents([ ($project->trashed() ? false : ['label' => trans('texts.archive_project'), 'url' => "javascript:onArchiveClick()"]), ['label' => trans('texts.delete_project'), 'url' => "javascript:onDeleteClick()"], ] )->split() !!} @endcan @endif @if ($project->trashed()) @can('edit', $project) {!! Button::primary(trans('texts.restore_project')) ->appendIcon(Icon::create('cloud-download')) ->withAttributes(['onclick' => 'onRestoreClick()']) !!} @endcan @endif {!! Former::close() !!}
{{ trans('texts.details') }}

@if($project->client) Client Name: {!! $project->client->present()->link !!}
@endif

@if($project->type) Survey Type: @if(is_array(json_decode($project->type))) @php $type = DB::table('products')->whereIn('id', json_decode($project->type))->select('id', 'product_key')->get(); @endphp @php $i = 1; @endphp @foreach ($type as $types) {{ $types->product_key }} @if($i < count($type)) , @endif @php $i++; @endphp @endforeach @else {{ $project->type }} @endif
@endif

@if($project->name) DWG Name: {!! $project->name !!}
@endif

@if($project->status) Status: {!! $project->status !!}
@endif

@if($project->is_rush_job == 1) Rush Job
@endif

{{trans('texts.due_date')}}
calendar

@if ($project->due_date) {{ Utils::fromSqlDate($project->due_date) }} @else   @endif
{{trans('texts.application_date') .' & '. trans('texts.time')}}
calendar
@if ($project->application_date) {{ Utils::fromSqlDate($project->application_date) }}
@else
  @endif @if ($project->application_time) {{ Utils::fromSqlDate($project->application_time) }} @else   @endif
{{ trans('texts.notes') }}
{!! $project->office_comment !!}
{{ trans('texts.file_name_number') }}
{!! $project->file_name_number !!}
@php $width = 0; if($project->researchCount != 0){ $width = $width + 9.1; } if($project->field_workCount != 0){ $width = $width + 9.1; } if($project->computationCount != 0){ $width = $width + 9.1; } if($project->draftingCount != 0){ $width = $width + 9.1; } if($project->first_checkCount != 0){ $width = $width + 9.1; } if($project->correctionCount != 0){ $width = $width + 9.1; } if($project->final_checkCount != 0){ $width = $width + 9.1; } if($project->final_correctionCount != 0){ $width = $width + 9.1; } if($project->completedCount != 0){ $width = $width + 9.1; } if($project->deliveredCount != 0){ $width = $width + 9.1; } if($project->gradeCount === 'A' || $project->gradeCount === 'B' || $project->gradeCount === 'C' || $project->gradeCount === 'a' || $project->gradeCount === 'b' || $project->gradeCount === 'c'){ $width = $width + 9.1; } @endphp

Project Check List

@if($project->researchCount == 1) @endif  
@if($project->field_workCount == 1) @endif  
@if($project->computationCount == 1) @endif  
@if($project->draftingCount == 1) @endif  
@if($project->first_checkCount == 1) @endif  
@if($project->correctionCount == 1) @endif  
@if($project->final_checkCount == 1) @endif  
@if($project->final_correctionCount == 1) @endif  
@if($project->completedCount == 1) @endif  
@if($project->deliveredCount == 1) @endif  

Google Maps |  NYC A.C.R.I.S. BBL Search |  F.E.M.A. Flood Map Service Center |  ZoLa Map |  @php $curlSession = curl_init(); $address = str_replace(' ', '+', $project['address'].' '.$project['city_town'].' '.$project['proj_state'].' '.$project['zip']); curl_setopt($curlSession, CURLOPT_URL, 'https://maps.googleapis.com/maps/api/geocode/json?address='.$address.'&key=AIzaSyAz3xXQV9bKvr5YsL4rsMoaODs04QIPAY8'); curl_setopt($curlSession, CURLOPT_BINARYTRANSFER, true); curl_setopt($curlSession, CURLOPT_RETURNTRANSFER, true); $latlong = json_decode(curl_exec($curlSession)); curl_close($curlSession); $lat = (count($latlong->results) > 0) ? $latlong->results[0]->geometry->location->lat : 0; $lng = (count($latlong->results) > 0) ? $latlong->results[0]->geometry->location->lng : 0; @endphp Streets Planning |  @if(strlen($project['block']) < 6 && !preg_match('/[\'^£$%&*()}{@#~?><>,|=_+¬-]/', $project['block'])) @php $a = 0; $b = ''; $block = $project['block']; for($i = 1; $i <= 5 - strlen($project['block']); $i++){ $b = $a.$b; } $block = $b.$block; @endphp @else @php $block = 0; @endphp @endif @if(strlen($project['lot']) < 5 && !preg_match('/[\'^£$%&*()}{@#~?><>,|=_+¬-]/', $project['lot'])) @php $a = 0; $b = ''; $lot = $project['lot']; for($i = 1; $i <= 4 - strlen($project['lot']); $i++){ $b = $a.$b; } $lot = $b.$lot; @endphp @else @php $lot = 0; @endphp @endif Oasis NYC Map

Client Information
@if($project->client) @if ($project['client']->showMap())
{{$project['client']->address1}}
{{$project['client']->city}}, {{$project['client']->state}} {{$project['client']->postal_code}}
@foreach ($project['client']->contacts as $contact) @if ($contact->phone) {{ $contact->phone }}
@endif @if ($contact->email) {!! HTML::mailto($contact->email, $contact->email) !!}
@endif @endforeach
@endif @endif
Property Information
{{$project['address']}}
{{$project['city_town']}}, {{$project['proj_state']}} {{$project['zip']}}
County: {{$project['country']}}
District: {{$project['district']}}   Section: {{$project['section']}}   Block: {{$project['block']}}   Lot: {{$project['lot']}}   Borough: {{$project['borough']}}  

@if ($chartData->duration)
@endif

Employee Notes

{!! Former::open($url1) ->addClass('col-lg-12 warn-on-exit main-form') ->autocomplete('off') ->method($method) !!}
{!! Former::close() !!} @if(count($employees) > 0) @foreach($employees as $employee)
{{$employee->getPostedByName->first_name}} {{$employee->getPostedByName->last_name}}, {{$employee->created_at->format('m/d/y h:i a')}}
{!! $employee->notes !!}
@endforeach @else
No Notes
@endif

Customer Notes

{!! Former::open($url2) ->addClass('col-lg-12 warn-on-exit main-form') ->autocomplete('off') ->method($method) !!}
{!! Former::close() !!} @if(count($customers) > 0) @foreach($customers as $customer)
{{$customer->getPostedByName->first_name}} {{$customer->getPostedByName->last_name}}, {{$customer->created_at->format('m/d/y h:i a')}}
{!! $customer->notes !!}
@endforeach @else
No Notes
@endif

Drafter Notes

{!! Former::open($url11) ->addClass('col-lg-12 warn-on-exit main-form') ->autocomplete('off') ->method($method) !!}
{!! Former::close() !!}

Manager Notes

{!! Former::open($url22) ->addClass('col-lg-12 warn-on-exit main-form') ->autocomplete('off') ->method($method) !!}
{!! Former::close() !!}

@include('list', [ 'entityType' => ENTITY_TASK, 'datatable' => new \App\Ninja\Datatables\ProjectTaskDatatable(true, true), 'projectId' => $project->public_id, 'clientId' => $project->client ? $project->client->public_id : 0, 'url' => $project->client ? url('api/tasks/' . $project->client->public_id . '/' . $project->public_id) : "#", ])
@stop