*

Hugo

  • ****
  • 186 posts
Item upload process (category picker)
« on: March 08, 2022, 09:34:27 PM »
Hello,

Is it possible to adjust the code so that the fields after the category dropdown gets visable when you fill it in?

So the field " where is your item located" is appears when you filled in also the second dropdown of the categories.

See attached image

Hugo

*

MB Themes

Re: Item upload process (category picker)
« Reply #1 on: March 09, 2022, 07:38:26 AM »
@Hugo
It should be quite easy to do using jQuery and css, that you hide all the blocks and then link change events to following block (show).
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Hugo

  • ****
  • 186 posts
Re: Item upload process (category picker)
« Reply #2 on: March 12, 2022, 06:03:54 PM »
Hello, can you guys fix that for me or show me how?

Because sometimes people forget to select the sub category and then later on after submitting they receive the error message but sometimes some fields are erased and they need to refill it.

Hugo

*

MB Themes

Re: Item upload process (category picker)
« Reply #3 on: March 13, 2022, 05:25:29 PM »
Sorry but I do not have that code, it must be weitten first.
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

Hugo

  • ****
  • 186 posts
Re: Item upload process (category picker)
« Reply #4 on: March 15, 2022, 09:05:06 AM »
Can you do this or assist me? Or give me a bit more advanced description on how to do this and implement it.

Hugo

*

MB Themes

Re: Item upload process (category picker)
« Reply #5 on: March 16, 2022, 08:15:59 AM »
@Hugo
First you need to hide other blocks via CSS:
Code: [Select]
.post-edit fieldset, .post-edit .buttons-block {display:none;}
Then you need javascript that check if category is filled, best to check hidden catId input.
Code: [Select]
$('body').on('change', 'input[name="catId"]', function() {
  if($(this).val() != '') {
    $('.post-edit fieldset, .post-edit .buttons-block').fadeIn(200);
  } else {
    $('.post-edit fieldset, .post-edit .buttons-block').fadeOut(0);
  }
}

Rest is on you ;)
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots