Skip to content

Commit 5eb73ba

Browse files
committed
Removed duplicate formatter
1 parent a97c453 commit 5eb73ba

File tree

3 files changed

+3
-12
lines changed

3 files changed

+3
-12
lines changed

app/Presenters/StatusLabelPresenter.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public static function dataTableLayout()
5151
'switchable' => true,
5252
'title' => trans('admin/statuslabels/table.color'),
5353
'visible' => true,
54-
'formatter' => 'colorSqFormatter',
54+
'formatter' => 'colorTagFormatter',
5555
], [
5656
'field' => 'show_in_nav',
5757
'searchable' => false,

resources/views/partials/bootstrap-table.blade.php

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -999,12 +999,7 @@ function genericColumnObjLinkFormatter(destination) {
999999
}
10001000
};
10011001
}
1002-
1003-
function colorSqFormatter(value, row) {
1004-
if (value) {
1005-
return '<span class="label" style="background-color: ' + value + ';">&nbsp;</span> ' + value;
1006-
}
1007-
}
1002+
10081003
10091004
function colorTagFormatter(value, row) {
10101005
if (value) {

resources/views/statuslabels/index.blade.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,7 @@ class="table table-striped snipe-table"
7777
@include ('partials.bootstrap-table')
7878

7979
<script nonce="{{ csrf_token() }}">
80-
function colorSqFormatter(value, row) {
81-
if (value) {
82-
return '<i class="fa-solid fa-square" style="color: ' + value + ';" aria-hidden="true"></i> ' + value;
83-
}
84-
}
80+
8581
8682
function statuslabelsAssetLinkFormatter(value, row) {
8783
if ((row) && (row.name)) {

0 commit comments

Comments
 (0)