Skip to content

Commit fc549e1

Browse files
committed
Tidy up a bit
1 parent 236163d commit fc549e1

File tree

2 files changed

+1
-49
lines changed

2 files changed

+1
-49
lines changed

src/controllers/BulkEditController.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,14 +81,11 @@ public function actionGetFields(): Response
8181

8282
$service = Plugin::getInstance()->bulkEdit;
8383
$customFields = $service->getFieldWrappersForElementQuery($this->getElementQuery());
84-
// $attributes = $service->getAttributeWrappersForElementQuery($this->getElementQuery());
85-
$attributes = [];
8684

8785
$view = Craft::$app->getView();
8886
$view->setNamespace($namespace);
8987
$modalHtml = $view->renderTemplate('venveo-bulk-edit/elementactions/BulkEdit/_fields', [
9088
'fieldWrappers' => $customFields,
91-
'attributeWrappers' => [],
9289
'bulkedit' => $service,
9390
'selectedTotal' => $this->getElementQuery()->count(),
9491
'selectAllTotal' => $this->getElementQuery()->id(null)->count(),

src/templates/elementactions/BulkEdit/_fields.twig

Lines changed: 1 addition & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<h2>{{ "Select Fields"|t('venveo-bulk-edit') }}</h2>
55
<p>Editing <strong>{{ selectedTotal }}</strong> elements on site
66
<strong>{{ site.name }} ({{ site.language }})</strong></p>
7-
{% if fieldWrappers|length or attributeWrappers|length %}
7+
{% if fieldWrappers|length %}
88

99
<div style="margin-bottom: 10px;">
1010
{{ forms.checkbox({
@@ -84,51 +84,6 @@
8484
{% else %}
8585
<p>These elements have no associated fields.</p>
8686
{% endif %}
87-
88-
{% if attributeWrappers|length %}
89-
<table class="data fullwidth" id="attributes-table">
90-
<thead>
91-
<th scope="col" class="col-header">
92-
<span class="heading-text">
93-
Attribute
94-
</span>
95-
</th>
96-
<th scope="col" class="col-header">
97-
<span class="heading-text">
98-
Edit
99-
</span>
100-
</th>
101-
<th scope="col" class="col-header">
102-
<span class="heading-text">
103-
Strategy
104-
</span>
105-
</th>
106-
</thead>
107-
{# fieldWrapper #}
108-
{% for attributeWrapper in attributeWrappers %}
109-
<tr>
110-
<td>
111-
<span>
112-
{{ attributeWrapper.name|t('site') }}
113-
</span>
114-
</td>
115-
<td>
116-
<span>
117-
{{ forms.lightswitchField({
118-
id: 'attributeEnabled-'~attributeWrapper.handle,
119-
name: 'attributes['~attributeWrapper.handle~'][enabled]',
120-
on: false,
121-
value: true,
122-
}) }}
123-
</span>
124-
</td>
125-
<td>
126-
<span></span>
127-
</td>
128-
</tr>
129-
{% endfor %}
130-
</table>
131-
{% endif %}
13287
<div class="field-edit-modal-bar">
13388
<div class="buttons right">
13489
<div class="btn" id="field-edit-cancel">Cancel</div>

0 commit comments

Comments
 (0)