Skip to content

Commit

Permalink
handle server validations and fix minor issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
suraj-webkul committed Jul 16, 2024
1 parent 6fbb94f commit d7e5189
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ class="cursor-pointer rounded-md p-1.5 ml-1 text-2xl transition-all hover:bg-gra
</div>
<x-admin::form.control-group.error ::name="`${attribute['code']}[${index}][value]`"/>
<x-admin::form.control-group.error ::name="`${attribute['code']}[${index}].value`"/>
</template>
<span
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{{-- TODO: need to look into this --}}
@php
$lookUpEntityData = app('Webkul\Attribute\Repositories\AttributeRepository')->getLookUpEntity($attribute->lookup_type, old($attribute->code) ?: $value);
@endphp
Expand Down Expand Up @@ -67,7 +66,7 @@ class="p-4 text-sm font-semibold text-gray-600 dark:text-gray-300"
app.component('v-lookup-component', {
template: '#v-lookup-component-template',
props: ['validations', 'attribute', 'src', 'value'],
props: ['validations', 'attribute', 'value'],
data() {
return {
Expand All @@ -79,7 +78,7 @@ class="p-4 text-sm font-semibold text-gray-600 dark:text-gray-300"
entityId: null,
searchRoute: this.src ?? `{{ route('admin.settings.attributes.lookup') }}/${this.attribute.lookup_type}`,
searchRoute: `{{ route('admin.settings.attributes.lookup') }}/${this.attribute.lookup_type}`,
};
},
Expand Down Expand Up @@ -113,7 +112,7 @@ class="p-4 text-sm font-semibold text-gray-600 dark:text-gray-300"
search(event) {
const searchTerm = event.target.value;
if (searchTerm <= 1) {
if (searchTerm.length <= 2) {
this.searchedResults = [];
this.isDropdownOpen = false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ class="cursor-pointer rounded-md p-1.5 ml-1 text-2xl transition-all hover:bg-gra
</div>
<x-admin::form.control-group.error ::name="`${attribute['code']}[${index}][value]`"/>
<x-admin::form.control-group.error ::name="`${attribute['code']}[${index}].value`"/>
</template>
<span
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,7 @@ class="flex gap-2.5 p-1.5 items-center cursor-pointer hover:rounded-lg {{ $menuI

@if ($menuItem->haveChildren())
<div class="fixed z-[100] hidden h-[calc(100vh-60px)] min-w-[180px] overflow-hidden rounded-none rounded-b-lg border border-gray-300 bg-white !p-0 pb-2 group-hover/item:!flex group-hover/item:!flex-col group-hover/item:!gap-2 dark:border-gray-800 dark:bg-gray-900 ltr:left-[270px] ltr:rounded-r-lg ltr:pl-10 ltr:shadow-[34px_10px_14px_rgba(0,0,0,0.01),19px_6px_12px_rgba(0,0,0,0.03),9px_3px_9px_rgba(0,0,0,0.04),2px_1px_5px_rgba(0,0,0,0.05),0px_0px_0px_rgba(0,0,0,0.05)] rtl:right-[270px] rtl:rounded-l-lg rtl:pr-10 rtl:shadow-[-34px_10px_14px_rgba(0,0,0,0.01),-19px_6px_12px_rgba(0,0,0,0.03),-9px_3px_9px_rgba(0,0,0,0.04),-2px_1px_5px_rgba(0,0,0,0.05),-0px_0px_0px_rgba(0,0,0,0.05)]">

<div
class="fixed top-14 z-[1000] h-full w-[200px] bg-white pt-4 shadow-[0px_8px_10px_0px_rgba(0,_0,_0,_0.2)] dark:bg-gray-900 max-lg:hidden"
>
<div class="fixed top-14 z-[1000] h-full w-[200px] bg-white pt-4 shadow-[0px_8px_10px_0px_rgba(0,_0,_0,_0.2)] dark:bg-gray-900 max-lg:hidden">
<div class="journal-scroll h-[calc(100vh-100px)] overflow-auto">
<nav class="grid w-full gap-2">
@foreach ($menuItem->getChildren() as $subMenuItem)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
:action="route('admin.contacts.persons.store')"
enctype="multipart/form-data"
>

{!! view_render_event('bagisto.admin.cms.pages.create.create_form_controls.before') !!}

<div class="flex items-center justify-between gap-4 max-sm:flex-wrap">
Expand Down Expand Up @@ -42,13 +41,11 @@ class="primary-button"
<div class="mt-3.5 flex gap-2.5 max-xl:flex-wrap">
<div class="flex flex-1 flex-col gap-2 max-xl:flex-auto">
<div class="box-shadow rounded bg-white p-4 dark:bg-gray-900">

@include('admin::common.custom-attributes.edit', [
'customAttributes' => app('Webkul\Attribute\Repositories\AttributeRepository')->findWhere([
'entity_type' => 'persons',
]),
])

</div>
</div>
</div>
Expand Down

0 comments on commit d7e5189

Please sign in to comment.