• Resolved yashtiwari

    (@yashtiwari)


    We have encountered an issue with the date picker functionality in the WP Job Manager plugin. When editing a job listing with a “Listing Expiry Date” that has already passed, the date picker automatically sets the input field to the current date instead of retaining the actual past closing date.

    Current Behavior:

    • When editing a job listing with a past Listing Expiry Date, the date picker resets the input field to the current date.
    • The user is unable to see the original past Listing Expiry Date, leading to confusion.

    Expected Behavior:

    • The date picker should not overwrite a past Listing Expiry Date with the current date.
    • The date picker should prevent users from selecting past dates, but if a past date is already set, it should remain visible.
Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter yashtiwari

    (@yashtiwari)

    Hello Team,

    Could you please provide a solution here?

    Plugin Support Jay

    (@bluejay77)

    Hi @yashtiwari,

    Thanks for your report.

    Would you share the WP Job Manager plugin version you currently have? We’ve pushed a fix for this in the past, so we want to make sure you’re up-to-date.

    Also, which PHP version is your site on?

    Lastly, have you done any initial troubleshooting yet? If not, please rule out a theme issue or a plugin conflict. I recommend testing things on a staging site rather than on your production (live) site. Many hosts provide a staging service, where you can do testing without affecting the live site. You can ask your host about this. If they don’t give you a staging site, you could try WP Staging or Duplicator:

    https://www.ads-software.com/plugins/wp-staging/
    https://www.ads-software.com/plugins/duplicator/

    First, temporarily switch to Twenty Seventeen, which is one of the default WordPress themes. You can do this by installing a plugin that only switches the theme for the current user, linked below:

    https://www.ads-software.com/plugins/theme-switcha/

    See if date picker issue resolves, you’ll need to contact your theme’s developer to see if they can help you troubleshoot.

    If things still don’t work properly with Twenty Seventeen, please try checking for conflicting plugins.

    To do so, temporarily disable all plugins but WP Job Manager (and related addons), and see if the issue resolves. If it does, try activating your plugins one-by-one and try to reproduce the problem. If it comes back when you activate a particular plugin, you’ve found the culprit.

    A side-note; before you deactivate your plugins, we recommend that you make a full backup of your site.

    Let us know what you find!

    Thread Starter yashtiwari

    (@yashtiwari)

    Hi @bluejay77

    Thank you for your response. We are currently using the latest version of the WP Job Manager plugin (Version 2.4.0).

    We have already conducted initial troubleshooting, but the issue persists. Additionally, we set up a fresh WordPress installation with the default theme, and the problem still occurs.

    Issue: When editing a job listing with a ‘Listing Expiry Date’ that has already passed, the date picker automatically sets the field to the current date instead of retaining the original past expiry date.

    Plugin Support lastsplash (a11n)

    (@lastsplash)

    Hi @yashtiwari

    I have confirmed the issue that you are seeing. In the backend, I see the expiration date of October 1:

    Annotation on 2024 10 11 at 08 32 27

    But once I open the listing, the date picker is moving the date to the current date:

    Screenshot on 2024 10 11 at 08 26 43

    I’d recommend filing a bug report for this via GitHub. While there isn’t a timeline for when this will be fixed, it will get the issue in front of our development team. We recommend that you file the report as our team may have questions about your use case. You can report it at:

    https://github.com/Automattic/WP-Job-Manager/issues/new?template=Bug_report.md

    Since this can’t be adjusted within the plugin, I am going to mark this thread as resolved.

    Thread Starter yashtiwari

    (@yashtiwari)

    @lastsplash – We have reported this bug on GitHub. You can check: https://github.com/Automattic/WP-Job-Manager/issues/2855.

    Plugin Support lastsplash (a11n)

    (@lastsplash)

    Hi @yashtiwari

    Thanks for reporting. You can follow the issue for any updates.

    Hello. Just found same in my version.

    I did for myself simple temporary solution (just remove mindate setting from datepicker):

    /wp-content/plugins/wp-job-manager/assets/dist/js/datepicker.js

    find and remove this (for jobs):

    ,minDate:new Date

    find and remove this (for resume):

    /wp-content/plugins/wp-job-manager-resumes/assets/dist/js/admin.js

    ,minDate:0

    /wp-content/plugins/wp-job-manager-resumes/assets/js/admin.js

    ,
    minDate: 0,

    Thread Starter yashtiwari

    (@yashtiwari)

    @www15to

    Thank you for the solution. However, if we remove the minDate validation, it will allow users to select past dates, which is not the expected behavior.

    Expected Behavior:
    The date picker should prevent users from selecting past dates, but if a past date is already set, it should remain visible.

    Does this clarification make sense?

Viewing 8 replies - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.