internalization the names of the filters
This commit is contained in:
parent
032c42a7df
commit
de7e874489
|
@ -481,9 +481,9 @@ export default {
|
||||||
// Removes element from filters list
|
// Removes element from filters list
|
||||||
this.activeFilterList.splice(this.newFilterIndex, 1);
|
this.activeFilterList.splice(this.newFilterIndex, 1);
|
||||||
},
|
},
|
||||||
handleChangeOnMetadata($event) {
|
handleChangeOnMetadata($event) {
|
||||||
if ($event.removed) {
|
if ($event.removed) {
|
||||||
this.oldMetadatumIndex = $event.removed.oldIndex;
|
this.oldMetadatumIndex = $event.removed.oldIndex;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
updateFiltersOrder() {
|
updateFiltersOrder() {
|
||||||
|
@ -527,7 +527,7 @@ export default {
|
||||||
collectionId: this.collectionId,
|
collectionId: this.collectionId,
|
||||||
metadatumId: this.choosenMetadatum.id,
|
metadatumId: this.choosenMetadatum.id,
|
||||||
name: this.choosenMetadatum.name,
|
name: this.choosenMetadatum.name,
|
||||||
filterType: this.selectedFilterType.name,
|
filterType: this.selectedFilterType.filter_type,
|
||||||
status: 'auto-draft',
|
status: 'auto-draft',
|
||||||
isRepositoryLevel: this.isRepositoryLevel,
|
isRepositoryLevel: this.isRepositoryLevel,
|
||||||
newIndex: this.newFilterIndex
|
newIndex: this.newFilterIndex
|
||||||
|
|
|
@ -59,7 +59,6 @@ class REST_Filter_Types_Controller extends REST_Controller {
|
||||||
$filter_type = new $name();
|
$filter_type = new $name();
|
||||||
|
|
||||||
$filter_arr = $filter_type->_toArray();
|
$filter_arr = $filter_type->_toArray();
|
||||||
$filter_arr['name'] = $item;
|
|
||||||
|
|
||||||
return $filter_arr;
|
return $filter_arr;
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,7 +9,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Autocomplete extends Filter_Type {
|
class Autocomplete extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Autocomplete');
|
$this->set_name( __('Autocomplete', 'tainacan') );
|
||||||
$this->set_supported_types(['string','long_string','item']);
|
$this->set_supported_types(['string','long_string','item']);
|
||||||
$this->set_component('tainacan-filter-autocomplete');
|
$this->set_component('tainacan-filter-autocomplete');
|
||||||
$this->set_use_max_options(false);
|
$this->set_use_max_options(false);
|
||||||
|
|
|
@ -9,7 +9,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Checkbox extends Filter_Type {
|
class Checkbox extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Checkbox List');
|
$this->set_name( __('Checkbox List', 'tainacan') );
|
||||||
$this->set_supported_types(['string','long_string','item']);
|
$this->set_supported_types(['string','long_string','item']);
|
||||||
$this->set_component('tainacan-filter-checkbox');
|
$this->set_component('tainacan-filter-checkbox');
|
||||||
$this->set_preview_template('
|
$this->set_preview_template('
|
||||||
|
|
|
@ -10,7 +10,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Custom_Interval extends Filter_Type {
|
class Custom_Interval extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Custom Interval');
|
$this->set_name( __('Custom Interval', 'tainacan'));
|
||||||
$this->set_supported_types(['float','date']);
|
$this->set_supported_types(['float','date']);
|
||||||
$this->set_component('tainacan-filter-custom-interval');
|
$this->set_component('tainacan-filter-custom-interval');
|
||||||
$this->set_use_max_options(false);
|
$this->set_use_max_options(false);
|
||||||
|
|
|
@ -10,7 +10,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Date_Interval extends Filter_Type {
|
class Date_Interval extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Date Interval');
|
$this->set_name( __('Date Interval', 'tainacan') );
|
||||||
$this->set_supported_types(['date']);
|
$this->set_supported_types(['date']);
|
||||||
$this->set_component('tainacan-filter-date-interval');
|
$this->set_component('tainacan-filter-date-interval');
|
||||||
$this->set_use_max_options(false);
|
$this->set_use_max_options(false);
|
||||||
|
|
|
@ -10,7 +10,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Date extends Filter_Type {
|
class Date extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Date');
|
$this->set_name( __('Date', 'tainacan') );
|
||||||
$this->set_supported_types(['date']);
|
$this->set_supported_types(['date']);
|
||||||
$this->set_component('tainacan-filter-date');
|
$this->set_component('tainacan-filter-date');
|
||||||
// $this->set_form_component('tainacan-filter-form-date');
|
// $this->set_form_component('tainacan-filter-form-date');
|
||||||
|
|
|
@ -10,7 +10,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Numeric_Interval extends Filter_Type {
|
class Numeric_Interval extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Numeric Interval');
|
$this->set_name( __('Numeric Interval', 'tainacan') );
|
||||||
$this->set_supported_types(['float']);
|
$this->set_supported_types(['float']);
|
||||||
$this->set_component('tainacan-filter-numeric-interval');
|
$this->set_component('tainacan-filter-numeric-interval');
|
||||||
$this->set_form_component('tainacan-filter-form-numeric-interval');
|
$this->set_form_component('tainacan-filter-form-numeric-interval');
|
||||||
|
|
|
@ -10,7 +10,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Numeric_List_Interval extends Filter_Type {
|
class Numeric_List_Interval extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Numeric Interval List');
|
$this->set_name( __('Numeric Interval List', 'tainacan') );
|
||||||
$this->set_supported_types(['float']);
|
$this->set_supported_types(['float']);
|
||||||
$this->set_component('tainacan-filter-numeric-list-interval');
|
$this->set_component('tainacan-filter-numeric-list-interval');
|
||||||
$this->set_form_component('tainacan-filter-form-numeric-list-interval');
|
$this->set_form_component('tainacan-filter-form-numeric-list-interval');
|
||||||
|
|
|
@ -10,7 +10,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Numeric extends Filter_Type {
|
class Numeric extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Numeric');
|
$this->set_name( __('Numeric', 'tainacan') );
|
||||||
$this->set_supported_types(['float']);
|
$this->set_supported_types(['float']);
|
||||||
$this->set_component('tainacan-filter-numeric');
|
$this->set_component('tainacan-filter-numeric');
|
||||||
$this->set_form_component('tainacan-filter-form-numeric');
|
$this->set_form_component('tainacan-filter-form-numeric');
|
||||||
|
|
|
@ -9,7 +9,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Selectbox extends Filter_Type {
|
class Selectbox extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Select Box');
|
$this->set_name( __('Select Box', 'tainacan') );
|
||||||
$this->set_supported_types(['string', 'long_string']);
|
$this->set_supported_types(['string', 'long_string']);
|
||||||
$this->set_component('tainacan-filter-selectbox');
|
$this->set_component('tainacan-filter-selectbox');
|
||||||
$this->set_use_max_options(false);
|
$this->set_use_max_options(false);
|
||||||
|
|
|
@ -9,7 +9,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class Taginput extends Filter_Type {
|
class Taginput extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Tag Input');
|
$this->set_name( __('Tag Input', 'tainacan') );
|
||||||
$this->set_supported_types(['string','long_string','item']);
|
$this->set_supported_types(['string','long_string','item']);
|
||||||
$this->set_component('tainacan-filter-taginput');
|
$this->set_component('tainacan-filter-taginput');
|
||||||
$this->set_use_max_options(false);
|
$this->set_use_max_options(false);
|
||||||
|
|
|
@ -9,7 +9,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class TaxonomyCheckbox extends Filter_Type {
|
class TaxonomyCheckbox extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Taxonomy Checkbox List');
|
$this->set_name( __('Taxonomy Checkbox List', 'tainacan') );
|
||||||
$this->set_supported_types(['term']);
|
$this->set_supported_types(['term']);
|
||||||
$this->set_component('tainacan-filter-taxonomy-checkbox');
|
$this->set_component('tainacan-filter-taxonomy-checkbox');
|
||||||
$this->set_preview_template('
|
$this->set_preview_template('
|
||||||
|
|
|
@ -9,7 +9,7 @@ defined( 'ABSPATH' ) or die( 'No script kiddies please!' );
|
||||||
class TaxonomyTaginput extends Filter_Type {
|
class TaxonomyTaginput extends Filter_Type {
|
||||||
|
|
||||||
function __construct(){
|
function __construct(){
|
||||||
$this->set_name('Taxonomy Tag Input');
|
$this->set_name( __('Taxonomy Tag Input', 'tainacan') );
|
||||||
$this->set_supported_types(['term']);
|
$this->set_supported_types(['term']);
|
||||||
$this->set_component('tainacan-filter-taxonomy-taginput');
|
$this->set_component('tainacan-filter-taxonomy-taginput');
|
||||||
$this->set_use_max_options(false);
|
$this->set_use_max_options(false);
|
||||||
|
|
Loading…
Reference in New Issue