jQuery(document).ready(function ($) {
    // When the notice is dismissed
    $(document).on('click', '.medicine-shop-notice .notice-dismiss', function () {
        $.post(ajaxurl, {
            action: 'medicine_shop_dismiss_notice'
        });
    });
});