/**
  * Display Product's caracteristics tab in complete product sheet
  * @param array $args
  * @return string
  */
 function display_product_caracteristics_tab($args)
 {
     $output = '';
     if (!empty($args) && !empty($args['pid'])) {
         $wps_product_mdl = new wps_product_mdl();
         $product_atts_def = $wps_product_mdl->get_product_atts_def($args['pid']);
         if (!empty($product_atts_def)) {
             ob_start();
             require wpshop_tools::get_template_part(WPS_PRODUCT_DIR, WPS_PRODUCT_TEMPLATES_MAIN_DIR, "frontend", "product_caracteristics_tab");
             $output = ob_get_contents();
             ob_end_clean();
         }
     }
     return $output;
 }
 /**
  * AJAX - Refresh product listing in order back-office
  */
 function refresh_product_list()
 {
     $status = false;
     $response = '';
     $letter = !empty($_POST['letter']) ? sanitize_title($_POST['letter']) : '';
     if (!empty($_POST['oid'])) {
         $post = get_post($_POST['oid']);
     }
     if (!empty($letter)) {
         $current_letter = $letter;
         $wps_product_mdl = new wps_product_mdl();
         $products = $wps_product_mdl->get_products_by_letter($letter);
         ob_start();
         require wpshop_tools::get_template_part(WPS_ORDERS_DIR, $this->template_dir, "backend", "product-listing/wps_orders_product_listing_table");
         $response = ob_get_contents();
         ob_end_clean();
         $status = true;
     }
     echo json_encode(array('status' => $status, 'response' => $response));
     wp_die();
 }