fixed all eslint errors and warning, compiled as PROD
This commit is contained in:
@@ -23,21 +23,21 @@ export default {
|
||||
canSearch: state => state.User.canSearch
|
||||
}),
|
||||
displayform(){
|
||||
// console.log('computed displayform');
|
||||
// console.log('computed displayform')
|
||||
return this.canSearch && this.form
|
||||
}
|
||||
},
|
||||
beforeMount() {
|
||||
// console.log('SearchBlock beforeMount');
|
||||
// console.log('SearchBlock beforeMount')
|
||||
this.form = this.formhtml
|
||||
},
|
||||
watch: {
|
||||
canSearch(new_value, old_value) {
|
||||
// console.log('canSearch changed, old: '+old_value+", new: "+new_value);
|
||||
if(new_value && !this.form){
|
||||
// console.log('canSearch changed, old: '+old_value+", new: "+new_value)
|
||||
if (new_value && !this.form) {
|
||||
this.getSearchForm()
|
||||
}
|
||||
if(!new_value && this.form){
|
||||
if (!new_value && this.form) {
|
||||
this.form = null
|
||||
}
|
||||
}
|
||||
@@ -46,10 +46,10 @@ export default {
|
||||
getSearchForm(){
|
||||
MA.get(`/materio_sapi/search_form`)
|
||||
.then(({data}) => {
|
||||
// console.log("getSearchForm");
|
||||
// console.log('getSearchForm')
|
||||
this.form = data.rendered
|
||||
})
|
||||
.catch(( error ) => {
|
||||
.catch((error) => {
|
||||
console.warn('Issue with get searchform', error)
|
||||
})
|
||||
}
|
||||
|
Reference in New Issue
Block a user