350 lines
22 KiB
PHP
Executable File
350 lines
22 KiB
PHP
Executable File
<?php $attributes ??= new \Illuminate\View\ComponentAttributeBag; ?>
|
|
<?php foreach($attributes->onlyProps([
|
|
'entity' => null,
|
|
'entityControlName' => null,
|
|
]) as $__key => $__value) {
|
|
$$__key = $$__key ?? $__value;
|
|
} ?>
|
|
<?php $attributes = $attributes->exceptProps([
|
|
'entity' => null,
|
|
'entityControlName' => null,
|
|
]); ?>
|
|
<?php foreach (array_filter(([
|
|
'entity' => null,
|
|
'entityControlName' => null,
|
|
]), 'is_string', ARRAY_FILTER_USE_KEY) as $__key => $__value) {
|
|
$$__key = $$__key ?? $__value;
|
|
} ?>
|
|
<?php $__defined_vars = get_defined_vars(); ?>
|
|
<?php foreach ($attributes as $__key => $__value) {
|
|
if (array_key_exists($__key, $__defined_vars)) unset($$__key);
|
|
} ?>
|
|
<?php unset($__defined_vars); ?>
|
|
|
|
<!-- Note Button -->
|
|
<div>
|
|
<?php echo view_render_event('admin.components.activities.actions.note.create_btn.before'); ?>
|
|
|
|
|
|
<button
|
|
class="flex h-[74px] w-[84px] flex-col items-center justify-center gap-1 rounded-lg border border-transparent bg-orange-200 font-medium text-orange-800 transition-all hover:border-orange-400"
|
|
@click="$refs.noteActionComponent.openModal('mail')"
|
|
>
|
|
<span class="icon-note text-2xl dark:!text-orange-800"></span>
|
|
|
|
<?php echo app('translator')->get('admin::app.components.activities.actions.note.btn'); ?>
|
|
</button>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.create_btn.after'); ?>
|
|
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.before'); ?>
|
|
|
|
|
|
<!-- Note Action Vue Component -->
|
|
<v-note-activity
|
|
ref="noteActionComponent"
|
|
:entity="<?php echo e(json_encode($entity)); ?>"
|
|
entity-control-name="<?php echo e($entityControlName); ?>"
|
|
></v-note-activity>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.after'); ?>
|
|
|
|
</div>
|
|
|
|
<?php if (! $__env->hasRenderedOnce('d3f79bf3-ae06-4ca8-91dc-5b9b17753d2b')): $__env->markAsRenderedOnce('d3f79bf3-ae06-4ca8-91dc-5b9b17753d2b');
|
|
$__env->startPush('scripts'); ?>
|
|
<script type="text/x-template" id="v-note-activity-template">
|
|
<Teleport to="body">
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.before'); ?>
|
|
|
|
|
|
<?php if (isset($component)) { $__componentOriginal81b4d293d9113446bb908fc8aef5c8f6 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal81b4d293d9113446bb908fc8aef5c8f6 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.index','data' => ['vSlot' => '{ meta, errors, handleSubmit }','as' => 'div','ref' => 'modalForm']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['v-slot' => '{ meta, errors, handleSubmit }','as' => 'div','ref' => 'modalForm']); ?>
|
|
<form @submit="handleSubmit($event, save)">
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.before'); ?>
|
|
|
|
|
|
<?php if (isset($component)) { $__componentOriginal09768308838b828c7799162f44758281 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal09768308838b828c7799162f44758281 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.modal.index','data' => ['ref' => 'noteActivityModal','position' => 'bottom-right']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::modal'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['ref' => 'noteActivityModal','position' => 'bottom-right']); ?>
|
|
<?php $__env->slot('header', null, []); ?>
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.header.title.before'); ?>
|
|
|
|
|
|
<h3 class="text-base font-semibold dark:text-white">
|
|
<?php echo app('translator')->get('admin::app.components.activities.actions.note.title'); ?>
|
|
</h3>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.header.title.after'); ?>
|
|
|
|
<?php $__env->endSlot(); ?>
|
|
|
|
<?php $__env->slot('content', null, []); ?>
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.header.content.controls.before'); ?>
|
|
|
|
|
|
<!-- Activity Type -->
|
|
<?php if (isset($component)) { $__componentOriginal53af403f6b2179a3039d488b8ab2a267 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal53af403f6b2179a3039d488b8ab2a267 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.control-group.control','data' => ['type' => 'hidden','name' => 'type','value' => 'note']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form.control-group.control'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['type' => 'hidden','name' => 'type','value' => 'note']); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal53af403f6b2179a3039d488b8ab2a267)): ?>
|
|
<?php $attributes = $__attributesOriginal53af403f6b2179a3039d488b8ab2a267; ?>
|
|
<?php unset($__attributesOriginal53af403f6b2179a3039d488b8ab2a267); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal53af403f6b2179a3039d488b8ab2a267)): ?>
|
|
<?php $component = $__componentOriginal53af403f6b2179a3039d488b8ab2a267; ?>
|
|
<?php unset($__componentOriginal53af403f6b2179a3039d488b8ab2a267); ?>
|
|
<?php endif; ?>
|
|
|
|
<!-- Id -->
|
|
<?php if (isset($component)) { $__componentOriginal53af403f6b2179a3039d488b8ab2a267 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal53af403f6b2179a3039d488b8ab2a267 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.control-group.control','data' => ['type' => 'hidden',':name' => 'entityControlName',':value' => 'entity.id']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form.control-group.control'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['type' => 'hidden',':name' => 'entityControlName',':value' => 'entity.id']); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal53af403f6b2179a3039d488b8ab2a267)): ?>
|
|
<?php $attributes = $__attributesOriginal53af403f6b2179a3039d488b8ab2a267; ?>
|
|
<?php unset($__attributesOriginal53af403f6b2179a3039d488b8ab2a267); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal53af403f6b2179a3039d488b8ab2a267)): ?>
|
|
<?php $component = $__componentOriginal53af403f6b2179a3039d488b8ab2a267; ?>
|
|
<?php unset($__componentOriginal53af403f6b2179a3039d488b8ab2a267); ?>
|
|
<?php endif; ?>
|
|
|
|
<!-- Comment -->
|
|
<?php if (isset($component)) { $__componentOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.control-group.index','data' => ['class' => '!mb-0']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form.control-group'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['class' => '!mb-0']); ?>
|
|
<?php if (isset($component)) { $__componentOriginal8378211f70f8c39b16d47cecdac9c7c8 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal8378211f70f8c39b16d47cecdac9c7c8 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.control-group.label','data' => ['class' => 'required']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form.control-group.label'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['class' => 'required']); ?>
|
|
<?php echo app('translator')->get('admin::app.components.activities.actions.note.comment'); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal8378211f70f8c39b16d47cecdac9c7c8)): ?>
|
|
<?php $attributes = $__attributesOriginal8378211f70f8c39b16d47cecdac9c7c8; ?>
|
|
<?php unset($__attributesOriginal8378211f70f8c39b16d47cecdac9c7c8); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal8378211f70f8c39b16d47cecdac9c7c8)): ?>
|
|
<?php $component = $__componentOriginal8378211f70f8c39b16d47cecdac9c7c8; ?>
|
|
<?php unset($__componentOriginal8378211f70f8c39b16d47cecdac9c7c8); ?>
|
|
<?php endif; ?>
|
|
|
|
<?php if (isset($component)) { $__componentOriginal53af403f6b2179a3039d488b8ab2a267 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal53af403f6b2179a3039d488b8ab2a267 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.control-group.control','data' => ['type' => 'textarea','name' => 'comment','rules' => 'required','label' => trans('admin::app.components.activities.actions.note.comment')]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form.control-group.control'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['type' => 'textarea','name' => 'comment','rules' => 'required','label' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(trans('admin::app.components.activities.actions.note.comment'))]); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal53af403f6b2179a3039d488b8ab2a267)): ?>
|
|
<?php $attributes = $__attributesOriginal53af403f6b2179a3039d488b8ab2a267; ?>
|
|
<?php unset($__attributesOriginal53af403f6b2179a3039d488b8ab2a267); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal53af403f6b2179a3039d488b8ab2a267)): ?>
|
|
<?php $component = $__componentOriginal53af403f6b2179a3039d488b8ab2a267; ?>
|
|
<?php unset($__componentOriginal53af403f6b2179a3039d488b8ab2a267); ?>
|
|
<?php endif; ?>
|
|
|
|
<?php if (isset($component)) { $__componentOriginal8da25fb6534e2ef288914e35c32417f8 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal8da25fb6534e2ef288914e35c32417f8 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.form.control-group.error','data' => ['controlName' => 'comment']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::form.control-group.error'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['control-name' => 'comment']); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal8da25fb6534e2ef288914e35c32417f8)): ?>
|
|
<?php $attributes = $__attributesOriginal8da25fb6534e2ef288914e35c32417f8; ?>
|
|
<?php unset($__attributesOriginal8da25fb6534e2ef288914e35c32417f8); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal8da25fb6534e2ef288914e35c32417f8)): ?>
|
|
<?php $component = $__componentOriginal8da25fb6534e2ef288914e35c32417f8; ?>
|
|
<?php unset($__componentOriginal8da25fb6534e2ef288914e35c32417f8); ?>
|
|
<?php endif; ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3)): ?>
|
|
<?php $attributes = $__attributesOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3; ?>
|
|
<?php unset($__attributesOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3)): ?>
|
|
<?php $component = $__componentOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3; ?>
|
|
<?php unset($__componentOriginal7b1bc76a00ab5e7f1bf2c6429dae85a3); ?>
|
|
<?php endif; ?>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.header.content.controls.after'); ?>
|
|
|
|
<?php $__env->endSlot(); ?>
|
|
|
|
<?php $__env->slot('footer', null, []); ?>
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.header.footer.save_button.before'); ?>
|
|
|
|
|
|
<?php if (isset($component)) { $__componentOriginal989f82b74d189698d771eef298c02d90 = $component; } ?>
|
|
<?php if (isset($attributes)) { $__attributesOriginal989f82b74d189698d771eef298c02d90 = $attributes; } ?>
|
|
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'admin::components.button.index','data' => ['class' => 'primary-button','title' => trans('admin::app.components.activities.actions.note.save-btn'),':loading' => 'isStoring',':disabled' => 'isStoring']] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? (array) $attributes->getIterator() : [])); ?>
|
|
<?php $component->withName('admin::button'); ?>
|
|
<?php if ($component->shouldRender()): ?>
|
|
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
|
|
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag && $constructor = (new ReflectionClass(Illuminate\View\AnonymousComponent::class))->getConstructor()): ?>
|
|
<?php $attributes = $attributes->except(collect($constructor->getParameters())->map->getName()->all()); ?>
|
|
<?php endif; ?>
|
|
<?php $component->withAttributes(['class' => 'primary-button','title' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(trans('admin::app.components.activities.actions.note.save-btn')),':loading' => 'isStoring',':disabled' => 'isStoring']); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal989f82b74d189698d771eef298c02d90)): ?>
|
|
<?php $attributes = $__attributesOriginal989f82b74d189698d771eef298c02d90; ?>
|
|
<?php unset($__attributesOriginal989f82b74d189698d771eef298c02d90); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal989f82b74d189698d771eef298c02d90)): ?>
|
|
<?php $component = $__componentOriginal989f82b74d189698d771eef298c02d90; ?>
|
|
<?php unset($__componentOriginal989f82b74d189698d771eef298c02d90); ?>
|
|
<?php endif; ?>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.header.footer.save_button.after'); ?>
|
|
|
|
<?php $__env->endSlot(); ?>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal09768308838b828c7799162f44758281)): ?>
|
|
<?php $attributes = $__attributesOriginal09768308838b828c7799162f44758281; ?>
|
|
<?php unset($__attributesOriginal09768308838b828c7799162f44758281); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal09768308838b828c7799162f44758281)): ?>
|
|
<?php $component = $__componentOriginal09768308838b828c7799162f44758281; ?>
|
|
<?php unset($__componentOriginal09768308838b828c7799162f44758281); ?>
|
|
<?php endif; ?>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.modal.after'); ?>
|
|
|
|
</form>
|
|
<?php echo $__env->renderComponent(); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__attributesOriginal81b4d293d9113446bb908fc8aef5c8f6)): ?>
|
|
<?php $attributes = $__attributesOriginal81b4d293d9113446bb908fc8aef5c8f6; ?>
|
|
<?php unset($__attributesOriginal81b4d293d9113446bb908fc8aef5c8f6); ?>
|
|
<?php endif; ?>
|
|
<?php if (isset($__componentOriginal81b4d293d9113446bb908fc8aef5c8f6)): ?>
|
|
<?php $component = $__componentOriginal81b4d293d9113446bb908fc8aef5c8f6; ?>
|
|
<?php unset($__componentOriginal81b4d293d9113446bb908fc8aef5c8f6); ?>
|
|
<?php endif; ?>
|
|
|
|
<?php echo view_render_event('admin.components.activities.actions.note.form_controls.after'); ?>
|
|
|
|
</Teleport>
|
|
</script>
|
|
|
|
<script type="module">
|
|
app.component('v-note-activity', {
|
|
template: '#v-note-activity-template',
|
|
|
|
props: {
|
|
entity: {
|
|
type: Object,
|
|
required: true,
|
|
default: () => {}
|
|
},
|
|
|
|
entityControlName: {
|
|
type: String,
|
|
required: true,
|
|
default: ''
|
|
}
|
|
},
|
|
|
|
data: function () {
|
|
return {
|
|
isStoring: false,
|
|
}
|
|
},
|
|
|
|
methods: {
|
|
openModal(type) {
|
|
this.$refs.noteActivityModal.open();
|
|
},
|
|
|
|
save(params) {
|
|
this.isStoring = true;
|
|
|
|
this.$axios.post("<?php echo e(route('admin.activities.store')); ?>", params)
|
|
.then (response => {
|
|
this.isStoring = false;
|
|
|
|
this.$emitter.emit('add-flash', { type: 'success', message: response.data.message });
|
|
|
|
this.$emitter.emit('on-activity-added', response.data.data);
|
|
|
|
this.$refs.noteActivityModal.close();
|
|
})
|
|
.catch (error => {
|
|
this.isStoring = false;
|
|
|
|
if (error.response.status == 422) {
|
|
setErrors(error.response.data.errors);
|
|
} else {
|
|
this.$emitter.emit('add-flash', { type: 'error', message: error.response.data.message });
|
|
|
|
this.$refs.noteActivityModal.close();
|
|
}
|
|
});
|
|
},
|
|
},
|
|
});
|
|
</script>
|
|
<?php $__env->stopPush(); endif; ?><?php /**PATH /var/www/html/packages/Webkul/Admin/src/Resources/views/components/activities/actions/note.blade.php ENDPATH**/ ?>
|