Remove data- elements in resources/ we didnt end on using them

This commit is contained in:
Deon George 2025-02-24 21:55:12 +11:00
parent 03c2eba9e3
commit e0e4b0264d
4 changed files with 3 additions and 8 deletions

View File

@ -4,7 +4,7 @@
<div class="col-12 col-sm-10 col-md-8"> <div class="col-12 col-sm-10 col-md-8">
<div class="row"> <div class="row">
<div class="col-12 bg-light text-dark p-2"> <div class="col-12 bg-light text-dark p-2">
<strong><abbr title="{{ $o->description }}" data-attr-name="{{ $o->name_lc }}" data-attr-required="{{ $o->required_by->intersect($oc)->join('|') }}" data-oc="{{ $oc->count() ? $o->required_by->keys()->intersect($oc)->join('|') : $o->used_in->keys()->join('|') }}">{{ $o->name }}</abbr></strong> <strong><abbr title="{{ $o->description }}">{{ $o->name }}</abbr></strong>
<!-- Attribute Hints --> <!-- Attribute Hints -->
<span class="float-end small"> <span class="float-end small">
@foreach($o->hints as $name => $description) @foreach($o->hints as $name => $description)

View File

@ -76,10 +76,6 @@
if (added_oc.sort().join('|') == newadded.sort().join('|')) if (added_oc.sort().join('|') == newadded.sort().join('|'))
return; return;
var attrs = $('[data-attr-name]').map(function() {
return $(this).data('attrName');
});
// Find out what was selected, and add them // Find out what was selected, and add them
newadded.forEach(function (item) { newadded.forEach(function (item) {
if (added_oc.indexOf(item) !== -1) if (added_oc.indexOf(item) !== -1)
@ -152,7 +148,6 @@
url: '{{ url('api/schema/objectclass/attrs') }}/'+item, url: '{{ url('api/schema/objectclass/attrs') }}/'+item,
cache: false cache: false
}); });
}); });
// Loop through added_oc, and remove anything not in newadded // Loop through added_oc, and remove anything not in newadded

View File

@ -52,7 +52,7 @@
theme: 'bootstrap-5', theme: 'bootstrap-5',
dropdownAutoWidth: true, dropdownAutoWidth: true,
width: 'style', width: 'style',
allowClear: {{ $allowclear ?? 'true' }}, allowClear: {{ $allowclear ?? 'false' }},
placeholder: '{{ $placeholder ?? '' }}', placeholder: '{{ $placeholder ?? '' }}',
@isset($addvalues) @isset($addvalues)
tags: true, tags: true,

View File

@ -31,7 +31,7 @@
<input type="hidden" name="dn" value=""> <input type="hidden" name="dn" value="">
@foreach ($o->getVisibleAttributes() as $ao) @foreach ($o->getVisibleAttributes() as $ao)
<x-attribute-type :edit="true" :o="$ao" :oc="collect($o->objectclass)"/> <x-attribute-type :edit="true" :o="$ao"/>
@endforeach @endforeach
<div id="newattrs"></div> <div id="newattrs"></div>