• Resolved AngeloLazzari

    (@angelolazzari)


    Hi, we are using your plugin since a few years but, probably after the last update we noticed that a field that we have enabled is not visible as custom field into the order custom field list.

    Is that normal? thank you very much

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Support Dina S.

    (@themehighsupport)

    Hi,

    Your issue needs a detailed check. Could you please raise a ticket through our website? We hope our technical team will be able to help.

    Thank you!

    Thread Starter AngeloLazzari

    (@angelolazzari)

    ok done!thanks!

    Plugin Support Dina S.

    (@themehighsupport)

    Please note that you can display only the keys of custom fields added using our plugin in the select dropdown by adding the following code in your child theme’s functions.php file.

    add_filter('postmeta_form_keys', 'th_postmeta_form_keys', 11, 2);
    function th_postmeta_form_keys($keys, $pos){
    $billing = THWCFD_Utils::get_fields('billing');
    $shipping = THWCFD_Utils::get_fields('shipping');
    $additional = THWCFD_Utils::get_fields('additional');
    $custom_fields = array_merge($billing,$shipping,$additional);
    $custom_field_keys = array();
    if(is_array($custom_fields)){
    foreach($custom_fields as $key => $field){
    if($field['custom']){
    $custom_field_keys[] = $key;
    }
    }
    if(!empty($custom_field_keys)){
    return $custom_field_keys;
    }

    }
    return $keys;
    }

    Otherwise, you will need to add it as the input fields.

    Thank you!

    Thread Starter AngeloLazzari

    (@angelolazzari)

    Thank you very much!

    Angelo

    Plugin Support Dina S.

    (@themehighsupport)

    Hi Angelo,

    Have a great day!

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