Merge pull request #3632 from shubhwebkul/patch-5

Issue #3622 resolved
This commit is contained in:
Jitendra Singh 2020-08-06 12:46:20 +05:30 committed by GitHub
commit bd423e9b06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 8 deletions

View File

@ -21,8 +21,8 @@
</option>
@foreach ($results['extraFilters']['channels'] as $channelModel)
<option
value="{{ $channelModel->code }}"
{{ (isset($channel) && ($channelModel->code) == $channel) ? 'selected' : '' }}>
value="{{ $channelModel->id }}"
{{ (isset($channel) && ($channelModel->id) == $channel) ? 'selected' : '' }}>
{{ $channelModel->name }}
</option>
@endforeach
@ -662,7 +662,6 @@
} else {
newParams = newParams + '&' + this.filters[i].column + condition + '=' + this.filters[i].val;
}
console.log('newParams', newParams);
}
var uri = window.location.href.toString();
@ -705,7 +704,7 @@
case "channel":
obj.label = "Channel";
if ('channels' in this.extraFilters) {
obj.prettyValue = this.extraFilters['channels'].find(channel => channel.code === obj.val).name
obj.prettyValue = this.extraFilters['channels'].find(channel => channel.id == obj.val).name
}
break;
case "locale":
@ -734,7 +733,6 @@
obj.label = this.columns[colIndex].label;
if (this.columns[colIndex].type === 'boolean') {
console.log('obj.val', obj.val);
if (obj.val === '1') {
obj.val = '{{ __('ui::app.datagrid.true') }}';
} else {
@ -748,7 +746,6 @@
if (obj.column !== undefined && obj.val !== undefined) {
this.filters.push(obj);
console.log('pushed');
}
obj = {};
@ -757,7 +754,7 @@
removeFilter: function (filter) {
for (let i in this.filters) {
if (this.filters[i].col === filter.col
if (this.filters[i].column === filter.column
&& this.filters[i].cond === filter.cond
&& this.filters[i].val === filter.val) {
this.filters.splice(i, 1);
@ -841,7 +838,6 @@
captureColumn: function (id) {
element = document.getElementById(id);
console.log(element.innerHTML);
},
removeMassActions: function () {