ok
Direktori : /home2/selectio/www/fms-worksuite/storage/framework/views/ |
Current File : /home2/selectio/www/fms-worksuite/storage/framework/views/bb9e8099d01ef3e9676d715c7d384ef0.php |
<?php $addExpenseCategoryPermission = user()->permission('manage_expense_category'); ?> <div class="row"> <div class="col-sm-12"> <?php if (isset($component)) { $__componentOriginal18ad2e0d264f9740dc73fff715357c28 = $component; } ?> <?php $component = App\View\Components\Form::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('form'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Form::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['id' => 'save-expense-data-form']); ?> <div class="add-client bg-white rounded"> <h4 class="mb-0 p-20 f-21 font-weight-normal text-capitalize border-bottom-grey"> <?php echo app('translator')->get('app.expense'); ?> <?php echo app('translator')->get('app.details'); ?></h4> <div class="row p-20"> <div class="col-md-6 col-lg-3"> <?php if (isset($component)) { $__componentOriginal4e45e801405ab67097982370a6a83cba = $component; } ?> <?php $component = App\View\Components\Forms\Text::resolve(['fieldLabel' => __('modules.expenses.itemName'),'fieldName' => 'item_name','fieldRequired' => 'true','fieldId' => 'item_name','fieldPlaceholder' => __('placeholders.expense.item')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.text'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Text::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['class' => 'mr-0 mr-lg-2 mr-md-2']); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal4e45e801405ab67097982370a6a83cba)): ?> <?php $component = $__componentOriginal4e45e801405ab67097982370a6a83cba; ?> <?php unset($__componentOriginal4e45e801405ab67097982370a6a83cba); ?> <?php endif; ?> </div> <div class="col-md-6 col-lg-3"> <input type="hidden" id="currency_id" name="currency_id" value="<?php echo e(company()->currency_id); ?>"> <?php if (isset($component)) { $__componentOriginal67cd5dc9866c6185ad92d933c387fa86 = $component; } ?> <?php $component = App\View\Components\Forms\Select::resolve(['fieldLabel' => __('modules.invoices.currency'),'fieldName' => 'currency','fieldRequired' => 'true','fieldId' => 'currency'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.select'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Select::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php $__currentLoopData = $currencies; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $currency): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <option <?php if($currency->id == company()->currency_id): ?> selected <?php endif; ?> value="<?php echo e($currency->id); ?>" data-currency-name="<?php echo e($currency->currency_name); ?>"> <?php echo e($currency->currency_name); ?> - (<?php echo e($currency->currency_symbol); ?>) </option> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal67cd5dc9866c6185ad92d933c387fa86)): ?> <?php $component = $__componentOriginal67cd5dc9866c6185ad92d933c387fa86; ?> <?php unset($__componentOriginal67cd5dc9866c6185ad92d933c387fa86); ?> <?php endif; ?> </div> <div class="col-md-6 col-lg-3"> <?php if (isset($component)) { $__componentOriginal1fded940a0a5d34bf1b88a1f45916593 = $component; } ?> <?php $component = App\View\Components\Forms\Number::resolve(['fieldId' => 'exchange_rate','fieldLabel' => __('modules.currencySettings.exchangeRate'),'fieldName' => 'exchange_rate','fieldRequired' => 'true','fieldValue' => $companyCurrency->exchange_rate,'fieldReadOnly' => 'true','fieldHelp' => '( '.company()->currency->currency_name.' '.__('app.to').' '.company()->currency->currency_name.' )'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.number'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Number::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal1fded940a0a5d34bf1b88a1f45916593)): ?> <?php $component = $__componentOriginal1fded940a0a5d34bf1b88a1f45916593; ?> <?php unset($__componentOriginal1fded940a0a5d34bf1b88a1f45916593); ?> <?php endif; ?> </div> <div class="col-md-6 col-lg-3"> <?php if (isset($component)) { $__componentOriginal1fded940a0a5d34bf1b88a1f45916593 = $component; } ?> <?php $component = App\View\Components\Forms\Number::resolve(['fieldLabel' => __('app.price'),'fieldName' => 'price','fieldRequired' => 'true','fieldId' => 'price','fieldPlaceholder' => __('placeholders.price')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.number'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Number::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['class' => 'mr-0 mr-lg-2 mr-md-2']); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal1fded940a0a5d34bf1b88a1f45916593)): ?> <?php $component = $__componentOriginal1fded940a0a5d34bf1b88a1f45916593; ?> <?php unset($__componentOriginal1fded940a0a5d34bf1b88a1f45916593); ?> <?php endif; ?> </div> <div class="col-md-6 col-lg-4"> <?php if (isset($component)) { $__componentOriginalf704f069031d81dfb7cf95f6709a6a66 = $component; } ?> <?php $component = App\View\Components\Forms\Datepicker::resolve(['fieldId' => 'purchase_date','fieldRequired' => 'true','fieldLabel' => __('modules.expenses.purchaseDate'),'fieldName' => 'purchase_date','fieldPlaceholder' => __('placeholders.date'),'fieldValue' => \Carbon\Carbon::today()->format(company()->date_format)] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.datepicker'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Datepicker::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalf704f069031d81dfb7cf95f6709a6a66)): ?> <?php $component = $__componentOriginalf704f069031d81dfb7cf95f6709a6a66; ?> <?php unset($__componentOriginalf704f069031d81dfb7cf95f6709a6a66); ?> <?php endif; ?> </div> <?php if(user()->permission('add_expenses') == 'all'): ?> <div class="col-md-6 col-lg-4"> <?php if (isset($component)) { $__componentOriginal89b295b0763c93abe0143426334eb5d6 = $component; } ?> <?php $component = App\View\Components\Forms\Label::resolve(['fieldId' => 'user_id','fieldLabel' => __('app.employee'),'fieldRequired' => 'true'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.label'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Label::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['class' => 'mt-3']); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal89b295b0763c93abe0143426334eb5d6)): ?> <?php $component = $__componentOriginal89b295b0763c93abe0143426334eb5d6; ?> <?php unset($__componentOriginal89b295b0763c93abe0143426334eb5d6); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7 = $component; } ?> <?php $component = App\View\Components\Forms\InputGroup::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.input-group'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\InputGroup::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <select class="form-control select-picker" name="user_id" id="user_id" data-live-search="true" data-size="8"> <option value="">--</option> <?php $__currentLoopData = $employees; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <?php if (isset($component)) { $__componentOriginal6c7097547485b98631a37d273a171e9f = $component; } ?> <?php $component = App\View\Components\UserOption::resolve(['user' => $item] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('user-option'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\UserOption::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal6c7097547485b98631a37d273a171e9f)): ?> <?php $component = $__componentOriginal6c7097547485b98631a37d273a171e9f; ?> <?php unset($__componentOriginal6c7097547485b98631a37d273a171e9f); ?> <?php endif; ?> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> </select> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7)): ?> <?php $component = $__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7; ?> <?php unset($__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7); ?> <?php endif; ?> </div> <?php else: ?> <input type="hidden" name="user_id" value="<?php echo e(user()->id); ?>"> <?php endif; ?> <div class="col-md-6 col-lg-4"> <?php if(isset($projectName)): ?> <input type="hidden" name="project_id" id="project_id" value="<?php echo e($projectId); ?>"> <?php if (isset($component)) { $__componentOriginal4e45e801405ab67097982370a6a83cba = $component; } ?> <?php $component = App\View\Components\Forms\Text::resolve(['fieldLabel' => __('app.project'),'fieldName' => 'projectName','fieldId' => 'projectName','fieldValue' => $projectName,'fieldReadOnly' => 'true'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.text'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Text::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal4e45e801405ab67097982370a6a83cba)): ?> <?php $component = $__componentOriginal4e45e801405ab67097982370a6a83cba; ?> <?php unset($__componentOriginal4e45e801405ab67097982370a6a83cba); ?> <?php endif; ?> <?php else: ?> <?php if (isset($component)) { $__componentOriginal67cd5dc9866c6185ad92d933c387fa86 = $component; } ?> <?php $component = App\View\Components\Forms\Select::resolve(['fieldId' => 'project_id','fieldName' => 'project_id','fieldLabel' => __('app.project'),'search' => 'true'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.select'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Select::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <option value="">--</option> <?php $__currentLoopData = $projects; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $project): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <option data-currency-id="<?php echo e($project->currency_id); ?>" <?php if($projectId == $project->id): ?> selected <?php endif; ?> value="<?php echo e($project->id); ?>"> <?php echo e(mb_ucwords($project->project_name)); ?> </option> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal67cd5dc9866c6185ad92d933c387fa86)): ?> <?php $component = $__componentOriginal67cd5dc9866c6185ad92d933c387fa86; ?> <?php unset($__componentOriginal67cd5dc9866c6185ad92d933c387fa86); ?> <?php endif; ?> <?php endif; ?> </div> <div class="col-md-4"> <?php if (isset($component)) { $__componentOriginal89b295b0763c93abe0143426334eb5d6 = $component; } ?> <?php $component = App\View\Components\Forms\Label::resolve(['fieldId' => 'category_id','fieldLabel' => __('modules.expenses.expenseCategory')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.label'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Label::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['class' => 'mt-3']); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal89b295b0763c93abe0143426334eb5d6)): ?> <?php $component = $__componentOriginal89b295b0763c93abe0143426334eb5d6; ?> <?php unset($__componentOriginal89b295b0763c93abe0143426334eb5d6); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7 = $component; } ?> <?php $component = App\View\Components\Forms\InputGroup::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.input-group'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\InputGroup::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <select class="form-control select-picker" name="category_id" id="expense_category_id" data-live-search="true"> <option value="">--</option> <?php $__currentLoopData = $categories; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $category): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <option value="<?php echo e($category->id); ?>"><?php echo e(mb_ucwords($category->category_name)); ?> </option> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> </select> <?php if($addExpenseCategoryPermission == 'all' || $addExpenseCategoryPermission == 'added'): ?> <?php $__env->slot('append', null, []); ?> <button id="addExpenseCategory" type="button" class="btn btn-outline-secondary border-grey" data-toggle="tooltip" data-original-title="<?php echo e(__('modules.expenseCategory.addExpenseCategory')); ?>"><?php echo app('translator')->get('app.add'); ?></button> <?php $__env->endSlot(); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7)): ?> <?php $component = $__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7; ?> <?php unset($__componentOriginalcbf9105fd4879d5d6ef9e1f6fe271af7); ?> <?php endif; ?> </div> <div class="col-md-4"> <?php if (isset($component)) { $__componentOriginal4e45e801405ab67097982370a6a83cba = $component; } ?> <?php $component = App\View\Components\Forms\Text::resolve(['fieldLabel' => __('modules.expenses.purchaseFrom'),'fieldName' => 'purchase_from','fieldId' => 'purchase_from','fieldPlaceholder' => __('placeholders.expense.vendor')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.text'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Text::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal4e45e801405ab67097982370a6a83cba)): ?> <?php $component = $__componentOriginal4e45e801405ab67097982370a6a83cba; ?> <?php unset($__componentOriginal4e45e801405ab67097982370a6a83cba); ?> <?php endif; ?> </div> <?php if($linkExpensePermission == 'all'): ?> <div class="col-md-4"> <?php if (isset($component)) { $__componentOriginal67cd5dc9866c6185ad92d933c387fa86 = $component; } ?> <?php $component = App\View\Components\Forms\Select::resolve(['fieldId' => 'bank_account_id','fieldLabel' => __('app.menu.bankaccount'),'fieldName' => 'bank_account_id','search' => 'true'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.select'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Select::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <option value="">--</option> <?php if($viewBankAccountPermission != 'none'): ?> <?php $__currentLoopData = $bankDetails; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $bankDetail): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?> <option value="<?php echo e($bankDetail->id); ?>"><?php if($bankDetail->type == 'bank'): ?> <?php echo e($bankDetail->bank_name); ?> | <?php endif; ?> <?php echo e(mb_ucwords($bankDetail->account_name)); ?> </option> <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal67cd5dc9866c6185ad92d933c387fa86)): ?> <?php $component = $__componentOriginal67cd5dc9866c6185ad92d933c387fa86; ?> <?php unset($__componentOriginal67cd5dc9866c6185ad92d933c387fa86); ?> <?php endif; ?> </div> <?php endif; ?> <input type = "hidden" name = "mention_user_ids" id = "mentionUserId" class ="mention_user_ids"> <div class="col-md-12"> <div class="form-group my-3"> <?php if (isset($component)) { $__componentOriginal89b295b0763c93abe0143426334eb5d6 = $component; } ?> <?php $component = App\View\Components\Forms\Label::resolve(['fieldId' => 'description','fieldLabel' => __('app.description')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.label'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\Label::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal89b295b0763c93abe0143426334eb5d6)): ?> <?php $component = $__componentOriginal89b295b0763c93abe0143426334eb5d6; ?> <?php unset($__componentOriginal89b295b0763c93abe0143426334eb5d6); ?> <?php endif; ?> <div id="description"></div> <textarea name="description" id="description-text" class="d-none"></textarea> </div> </div> <div class="col-lg-12"> <?php if (isset($component)) { $__componentOriginal71f75760ce80416d6aa938be1ae7e8b2 = $component; } ?> <?php $component = App\View\Components\Forms\File::resolve(['fieldLabel' => __('app.bill'),'fieldName' => 'bill','fieldId' => 'bill','allowedFileExtensions' => 'txt pdf doc xls xlsx docx rtf png jpg jpeg svg','popover' => __('messages.fileFormat.multipleImageFile')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.file'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\File::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal71f75760ce80416d6aa938be1ae7e8b2)): ?> <?php $component = $__componentOriginal71f75760ce80416d6aa938be1ae7e8b2; ?> <?php unset($__componentOriginal71f75760ce80416d6aa938be1ae7e8b2); ?> <?php endif; ?> </div> </div> <?php if (isset($component)) { $__componentOriginalfa1d9407bf58c9650823154ec52dea3e = $component; } ?> <?php $component = App\View\Components\Forms\CustomField::resolve(['fields' => $fields] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.custom-field'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\CustomField::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalfa1d9407bf58c9650823154ec52dea3e)): ?> <?php $component = $__componentOriginalfa1d9407bf58c9650823154ec52dea3e; ?> <?php unset($__componentOriginalfa1d9407bf58c9650823154ec52dea3e); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginalb19caa501eea72410c04d1917a586963 = $component; } ?> <?php $component = App\View\Components\FormActions::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('form-actions'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\FormActions::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes([]); ?> <?php if (isset($component)) { $__componentOriginalcf8d12533ff890e0d6573daf32b7618d = $component; } ?> <?php $component = App\View\Components\Forms\ButtonPrimary::resolve(['icon' => 'check'] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.button-primary'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\ButtonPrimary::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['id' => 'save-expense-form','class' => 'mr-3']); ?><?php echo app('translator')->get('app.save'); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalcf8d12533ff890e0d6573daf32b7618d)): ?> <?php $component = $__componentOriginalcf8d12533ff890e0d6573daf32b7618d; ?> <?php unset($__componentOriginalcf8d12533ff890e0d6573daf32b7618d); ?> <?php endif; ?> <?php if (isset($component)) { $__componentOriginalc35c79ed7e812580313ad04118477974 = $component; } ?> <?php $component = App\View\Components\Forms\ButtonCancel::resolve(['link' => route('expenses.index')] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?> <?php $component->withName('forms.button-cancel'); ?> <?php if ($component->shouldRender()): ?> <?php $__env->startComponent($component->resolveView(), $component->data()); ?> <?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(App\View\Components\Forms\ButtonCancel::class))->getConstructor()): ?> <?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?> <?php endif; ?> <?php $component->withAttributes(['class' => 'border-0']); ?><?php echo app('translator')->get('app.cancel'); ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalc35c79ed7e812580313ad04118477974)): ?> <?php $component = $__componentOriginalc35c79ed7e812580313ad04118477974; ?> <?php unset($__componentOriginalc35c79ed7e812580313ad04118477974); ?> <?php endif; ?> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginalb19caa501eea72410c04d1917a586963)): ?> <?php $component = $__componentOriginalb19caa501eea72410c04d1917a586963; ?> <?php unset($__componentOriginalb19caa501eea72410c04d1917a586963); ?> <?php endif; ?> </div> <?php echo $__env->renderComponent(); ?> <?php endif; ?> <?php if (isset($__componentOriginal18ad2e0d264f9740dc73fff715357c28)): ?> <?php $component = $__componentOriginal18ad2e0d264f9740dc73fff715357c28; ?> <?php unset($__componentOriginal18ad2e0d264f9740dc73fff715357c28); ?> <?php endif; ?> </div> </div> <script> $(document).ready(function() { quillMention(null, '#description'); $('.custom-date-picker').each(function(ind, el) { datepicker(el, { position: 'bl', ...datepickerConfig }); }); const dp1 = datepicker('#purchase_date', { position: 'bl', ...datepickerConfig }); $('#save-expense-form').click(function() { let note = document.getElementById('description').children[0].innerHTML; document.getElementById('description-text').value = note; var mention_user_id = $('#description span[data-id]').map(function(){ return $(this).attr('data-id') }).get(); $('#mentionUserId').val(mention_user_id.join(',')); const url = "<?php echo e(route('expenses.store')); ?>"; var data = $('#save-expense-data-form').serialize(); $.easyAjax({ url: url, container: '#save-expense-data-form', type: "POST", disableButton: true, blockUI: true, buttonSelector: "#save-expense-form", data: data, file: true, success: function(response) { window.location.href = response.redirectUrl; } }); }); $('#addExpenseCategory').click(function() { let userId = $('#user_id').val(); const url = "<?php echo e(route('expenseCategory.create')); ?>?user_id="+userId; $(MODAL_LG + ' ' + MODAL_HEADING).html('...'); $.ajaxModal(MODAL_LG, url); }); $('body').on('change', '#user_id', function(){ let userId = $(this).val(); let categoryId = $('#expense_category_id').val(); const url = "<?php echo e(route('expenses.get_employee_projects')); ?>"; let data = $('#save-expense-data-form').serialize(); $.easyAjax({ url: url, type: "GET", data: {'userId' : userId, 'categoryId' : categoryId}, success: function(response) { $('#project_id').html('<option value="">--</option>'+response.data); $('#project_id').selectpicker('refresh') $('#expense_category_id').html('<option value="">--</option>'+response.category); $('#expense_category_id').selectpicker('refresh') } }); }); $('body').on('change', '#expense_category_id', function(){ let categoryId = $(this).val(); let userId = $('#user_id').val(); const url = "<?php echo e(route('expenses.get_category_employees')); ?>"; let data = $('#save-expense-data-form').serialize(); $.easyAjax({ url: url, type: "GET", data: {'categoryId' : categoryId, 'userId' : userId}, success: function(response) { $('#user_id').html('<option value="">--</option>'+response.employees); $('#user_id').selectpicker('refresh') } }); }); init(RIGHT_MODAL); }); function checkboxChange(parentClass, id){ var checkedData = ''; $('.'+parentClass).find("input[type= 'checkbox']:checked").each(function () { checkedData = (checkedData !== '') ? checkedData+', '+$(this).val() : $(this).val(); }); $('#'+id).val(checkedData); } $('body').on("change", '#currency, #project_id', function() { if ($('#project_id').val() != '') { var curId = $('#project_id option:selected').attr('data-currency-id'); $('#currency').removeAttr('disabled'); $('#currency').selectpicker('refresh'); // $('#currency_id').val(curId); $('#currency').val(curId); $('#currency').prop('disabled', true); $('#currency').selectpicker('refresh'); } else { $('#currency').prop('disabled', false); $('#currency').selectpicker('refresh'); } var id = $('#currency').val(); $('#currency_id').val(id); var currencyId = $('#currency_id').val(); var companyCurrencyName = "<?php echo e($companyCurrency->currency_name); ?>"; var currentCurrencyName = $('#currency option:selected').attr('data-currency-name'); var companyCurrency = '<?php echo e($companyCurrency->id); ?>'; if(currencyId == companyCurrency){ $('#exchange_rate').prop('readonly', true); } else{ $('#exchange_rate').prop('readonly', false); } var token = "<?php echo e(csrf_token()); ?>"; $.easyAjax({ url: "<?php echo e(route('payments.account_list')); ?>", type: "GET", blockUI: true, data: { 'curId' : currencyId , _token: token}, success: function(response) { if (response.status == 'success') { $('#bank_account_id').html(response.data); $('#bank_account_id').selectpicker('refresh'); $('#exchange_rate').val(response.exchangeRate); $('#exchange_rateHelp').html('( '+companyCurrencyName+' <?php echo app('translator')->get('app.to'); ?> '+currentCurrencyName+' )'); } } }); }); </script> <?php /**PATH /home2/selectio/public_html/fms-worksuite/resources/views/expenses/ajax/create.blade.php ENDPATH**/ ?>