<commit_before>@extends('layouts.app')

@section('content')
    <header>
        <h1>{{ __('Leads') }}
    </header>
    <form method="POST" action="/lead/save" class="form">
        {{ csrf_field() }}
        <div class="row">
            <div class="col">
                <label>{{ __('Name') }} <span class="text-danger">*</span></label>
                <input type="text" name="name" value="{{ $lead->name }}" required="required" class="form-control form-control-lg">
            </div>
            <div class="col">
                <label>{{ __('Business name') }}</label>
                <input type="text" name="business_name" value="{{ $lead->business_name }}" class="form-control form-control-lg">
            </div>
        </div>
        <div class="row">
            <div class="col">
                <label>{{ __('Phone') }}</label>
                <input type="tel" name="phone" id="phone" value="{{ $lead->phone }}" maxlength="15" class="form-control form-control-lg">
            </div>
            <div class="col">
                <label>{{ __('Mobile') }}</label>
                <input type="tel" name="mobile" id="mobile" value="{{ $lead->mobile }}" maxlength="15" class="form-control form-control-lg">
            </div>
        </div>
        <div class="row">
            <div class="col">
                <label>E-mail</label>
                <input type="email" name="email" id="email" value="{{ $lead->email }}" maxlength="254" class="form-control form-control-lg">
            </div>
            <div class="col">
                <label>Website</label>
                <input type="url" name="website" id="website" value="{{ $lead->website }}" placeholder="https://www.website.com" class="form-control form-control-lg">
            </div>
        </div>
        <div class="row">
            <div class="col">
                <label>{{ __('Notes') }}</label>
                <textarea name="notes" id="notes" rows="10" class="form-control form-control-lg">{{ $lead->notes }}</textarea>
            </div>
        </div>

        <div class="card mt-2">
            <div class="card-header">{{ __('Address') }}</div>
            <div class="card-body">
                <div class="row">
                    <div class="col">
                        <label>{{ __('Country') }} <span class="text-danger">*</span></label>
                        <select name="country_id" id="country_id" required class="form-control form-control-lg">
                            <option value=""></option>
                            @foreach ($countries as $country)
                                <option value="{{ $country->code_2 }}" @if($lead->country_id == $country->code_2) selected="selected" @endif>{{ $country->name }} {{ $country->flag }}</option>
                            @endforeach
                        </select>
                    </div>
                    <div class="col">
                        <label class="" for="city">{{ __('City') }}</label>
                        <input type="text" name="city" id="city" value="{{ $lead->city }}" class="form-control form-control-lg">
                    </div>
                </div><!--./row-->
                <div class="row">
                    <div class="col">
                        <label class="">{{ __('Street') }}</label>
                        <input type="text" name="street" id="street" value="{{ $lead->street }}" class="form-control form-control-lg" maxlength="80">
                    </div>
                    <div class="col">
                        <label class="">{{ __('Zipcode') }}</label>
                        <input type="text" name="zipcode" id="zipcode" value="{{ $lead->zipcode }}" class="form-control form-control-lg" maxlength="10">
                    </div>
                </div><!--./row-->
            </div><!--./card-body-->
        </div><!--./card-->

        <div class="card mt-2">
            <div class="card-header">{{ __('Social networks') }}</div>
            <div class="card-body">
            <div class="row">
                <div class="col">
                    <label>Linkedin</label>
                    <input type="url" name="linkedin" value="{{ $lead->linkedin }}" class="form-control form-control-lg">
                </div>
                <div class="col">
                    <label>Facebook</label>
                    <input type="url" name="facebook" value="{{ $lead->facebook }}" class="form-control form-control-lg">
                </div>
            </div>
            <div class="row">
                <div class="col">
                    <label>Instagram</label>
                    <input type="url" name="instagram" value="{{ $lead->instagram }}" class="form-control form-control-lg">
                </div>
                <div class="col">
                    <label>Twitter</label>
                    <input type="url" name="twitter" value="{{ $lead->twitter }}" class="form-control form-control-lg">
                </div>
            </div>
            <div class="row">
                <div class="col">
                    <label>YouTube</label>
                    <input type="url" name="youtube" value="{{ $lead->youtube }}" class="form-control form-control-lg">
                </div>
                <div class="col">
                    <label>TikTok</label>
                    <input type="url" name="tiktok" value="{{ $lead->tiktok }}" class="form-control form-control-lg">
                </div>
            </div>
            </div><!--./card-body-->
        </div><!--./card-->

        <div class="card mt-2">
            <div class="card-header">{{ __('Details') }}</div>
            <div class="card-body">
                <div class="row">
                    <div class="col">
                        <label>{{ __('Industry') }}</label>
                        <select name="industry_id" id="industry_id" class="form-control form-control-lg">
                            <option value=""></option>
                            <option value=""></option>
                        </select>
                    </div><!--./col-->
                    <div class="col">
                        <label>{{ __('Status') }}</label>
                        <select name="status" id="status" class="form-control form-control-lg">
                            <option value="">{{ __('Choose') }}</option>
                            <option value="open">{{ __('Open') }}</option>
                            <option value="assigned">{{ __('Assigned') }}</option>
                            <option value="customer">{{ __('Customer') }}</option>
                            <option value="dead">{{ __('Dead') }}</option>
                        </select>
                    </div>
                    <div class="col">
                        <label>{{ __('Remember contact') }}</label>
                        <input type="datetime-local" name="schedule_contact" value="" class="form-control form-control-lg">
                    </div>
                </div><!--./row-->
            </div><!--./card-body-->
        </div><!--./card-->

        <div class="row">
            <div class="col mt-2">
                <a href="/lead" class="btn btn-lg btn-outline-secondary">{{ __('Cancel') }}</a>
                <button type="submit" class="btn btn-lg btn-primary">{{ __('Save') }}</button>
            </div>
        </div>
        <input type="hidden" name="id" value="{{ (!empty($lead)) ? $lead->id : '' }}">
    </form>

    @if($lead->id)
    <div class="mt-2">
        <h2>{{ __('Contacts') }}</h2>
    </div>
    <form method="post" action="/contact/save">
        <input type="hidden" name="lead_id" value="{{ $lead->id }}">
        <div class="row"><commit_msg>WIP: Improve lead schedule contact min date to schedule today<commit_after>@extends('layouts.app')

@section('content')
    <header>
        <h1>{{ __('Leads') }}
    </header>
    <form method="POST" action="/lead/save" class="form">
        {{ csrf_field() }}
        <div class="row">
            <div class="col">
                <label>{{ __('Name') }} <span class="text-danger">*</span></label>
                <input type="text" name="name" value="{{ $lead->name }}" required="required" class="form-control form-control-lg">
            </div>
            <div class="col">
                <label>{{ __('Business name') }}</label>
                <input type="text" name="business_name" value="{{ $lead->business_name }}" class="form-control form-control-lg">
            </div>
        </div>
        <div class="row">
            <div class="col">
                <label>{{ __('Phone') }}</label>
                <input type="tel" name="phone" id="phone" value="{{ $lead->phone }}" maxlength="15" class="form-control form-control-lg">
            </div>
            <div class="col">
                <label>{{ __('Mobile') }}</label>
                <input type="tel" name="mobile" id="mobile" value="{{ $lead->mobile }}" maxlength="15" class="form-control form-control-lg">
            </div>
        </div>
        <div class="row">
            <div class="col">
                <label>E-mail</label>
                <input type="email" name="email" id="email" value="{{ $lead->email }}" maxlength="254" class="form-control form-control-lg">
            </div>
            <div class="col">
                <label>Website</label>
                <input type="url" name="website" id="website" value="{{ $lead->website }}" placeholder="https://www.website.com" class="form-control form-control-lg">
            </div>
        </div>
        <div class="row">
            <div class="col">
                <label>{{ __('Notes') }}</label>
                <textarea name="notes" id="notes" rows="10" class="form-control form-control-lg">{{ $lead->notes }}</textarea>
            </div>
        </div>

        <div class="card mt-2">
            <div class="card-header">{{ __('Address') }}</div>
            <div class="card-body">
                <div class="row">
                    <div class="col">
                        <label>{{ __('Country') }} <span class="text-danger">*</span></label>
                        <select name="country_id" id="country_id" required class="form-control form-control-lg">
                            <option value=""></option>
                            @foreach ($countries as $country)
                                <option value="{{ $country->code_2 }}" @if($lead->country_id == $country->code_2) selected="selected" @endif>{{ $country->name }} {{ $country->flag }}</option>
                            @endforeach
                        </select>
                    </div>
                    <div class="col">
                        <label class="" for="city">{{ __('City') }}</label>
                        <input type="text" name="city" id="city" value="{{ $lead->city }}" class="form-control form-control-lg">
                    </div>
                </div><!--./row-->
                <div class="row">
                    <div class="col">
                        <label class="">{{ __('Street') }}</label>
                        <input type="text" name="street" id="street" value="{{ $lead->street }}" class="form-control form-control-lg" maxlength="80">
                    </div>
                    <div class="col">
                        <label class="">{{ __('Zipcode') }}</label>
                        <input type="text" name="zipcode" id="zipcode" value="{{ $lead->zipcode }}" class="form-control form-control-lg" maxlength="10">
                    </div>
                </div><!--./row-->
            </div><!--./card-body-->
        </div><!--./card-->

        <div class="card mt-2">
            <div class="card-header">{{ __('Social networks') }}</div>
            <div class="card-body">
            <div class="row">
                <div class="col">
                    <label>Linkedin</label>
                    <input type="url" name="linkedin" value="{{ $lead->linkedin }}" class="form-control form-control-lg">
                </div>
                <div class="col">
                    <label>Facebook</label>
                    <input type="url" name="facebook" value="{{ $lead->facebook }}" class="form-control form-control-lg">
                </div>
            </div>
            <div class="row">
                <div class="col">
                    <label>Instagram</label>
                    <input type="url" name="instagram" value="{{ $lead->instagram }}" class="form-control form-control-lg">
                </div>
                <div class="col">
                    <label>Twitter</label>
                    <input type="url" name="twitter" value="{{ $lead->twitter }}" class="form-control form-control-lg">
                </div>
            </div>
            <div class="row">
                <div class="col">
                    <label>YouTube</label>
                    <input type="url" name="youtube" value="{{ $lead->youtube }}" class="form-control form-control-lg">
                </div>
                <div class="col">
                    <label>TikTok</label>
                    <input type="url" name="tiktok" value="{{ $lead->tiktok }}" class="form-control form-control-lg">
                </div>
            </div>
            </div><!--./card-body-->
        </div><!--./card-->

        <div class="card mt-2">
            <div class="card-header">{{ __('Details') }}</div>
            <div class="card-body">
                <div class="row">
                    <div class="col">
                        <label>{{ __('Industry') }}</label>
                        <select name="industry_id" id="industry_id" class="form-control form-control-lg">
                            <option value=""></option>
                            <option value=""></option>
                        </select>
                    </div><!--./col-->
                    <div class="col">
                        <label>{{ __('Status') }}</label>
                        <select name="status" id="status" class="form-control form-control-lg">
                            <option value="">{{ __('Choose') }}</option>
                            <option value="open">{{ __('Open') }}</option>
                            <option value="assigned">{{ __('Assigned') }}</option>
                            <option value="customer">{{ __('Customer') }}</option>
                            <option value="dead">{{ __('Dead') }}</option>
                        </select>
                    </div>
                    <div class="col">
                        <label>{{ __('Remember contact') }}</label>
                        <input type="datetime-local" name="schedule_contact" value="" min="{{ date('Y-m-d H:i') }}" class="form-control form-control-lg">
                    </div>
                </div><!--./row-->
            </div><!--./card-body-->
        </div><!--./card-->

        <div class="row">
            <div class="col mt-2">
                <a href="/lead" class="btn btn-lg btn-outline-secondary">{{ __('Cancel') }}</a>
                <button type="submit" class="btn btn-lg btn-primary">{{ __('Save') }}</button>
            </div>
        </div>
        <input type="hidden" name="id" value="{{ (!empty($lead)) ? $lead->id : '' }}">
    </form>

    @if($lead->id)
    <div class="mt-2">
        <h2>{{ __('Contacts') }}</h2>
    </div>
    <form method="post" action="/contact/save">
        <input type="hidden" name="lead_id" value="{{ $lead->id }}">
        <div class="row">
{'fraction_non_alphanumeric': 0.19697943444730076, 'fraction_numerical': 0.0029562982005141387, 'mean_word_length': 1.5179611650485436, 'pattern_counts': {'":': 0, '<': 393, '<?xml version=': 0, '>': 441, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1768156', 'n_tokens_mistral': 4391, 'n_tokens_neox': 4085, 'n_words': 861}