refining fields
This commit is contained in:
parent
ccccbf238e
commit
902e08eb8d
|
|
@ -17,11 +17,13 @@ if (class_exists('GF_Field')) {
|
|||
'post_type' => 'brochures',
|
||||
'posts_per_page' => -1,
|
||||
'post_status' => 'publish',
|
||||
'order' => 'DESC',
|
||||
'orderby' => 'date',
|
||||
'order' => 'ASC',
|
||||
'orderby' => 'title',
|
||||
'meta_key' => 'brochure_pdf',
|
||||
'meta_value' => false,
|
||||
'meta_compare' => '!=',
|
||||
'post__not_in' => [4431, 4436, 7222, 5825, 6505]
|
||||
|
||||
));
|
||||
$choices = [];
|
||||
|
||||
|
|
|
|||
|
|
@ -5,17 +5,10 @@ if (class_exists('GF_Field')) {
|
|||
{
|
||||
public $type = 'order_documents_list';
|
||||
|
||||
|
||||
|
||||
private function buildChoicesArray()
|
||||
{
|
||||
|
||||
$posts_array = [
|
||||
[
|
||||
'text' => 'La synthèse des primes',
|
||||
'ID_fr' => 7153,
|
||||
'ID_nl' => 7157,
|
||||
],
|
||||
[
|
||||
'text' => 'Flyer Général',
|
||||
'ID_fr' => 7425,
|
||||
|
|
@ -29,7 +22,7 @@ if (class_exists('GF_Field')) {
|
|||
[
|
||||
'text' => 'Jeu memo Sherif',
|
||||
'ID_fr' => 7419,
|
||||
'ID_nl' => 7419,
|
||||
'ID_nl' => 7464,
|
||||
],
|
||||
];
|
||||
|
||||
|
|
@ -41,6 +34,7 @@ if (class_exists('GF_Field')) {
|
|||
|
||||
$choices[] = [
|
||||
'title' => get_the_title($id),
|
||||
'text' => get_the_title($id),
|
||||
'ID' => $id,
|
||||
];
|
||||
}
|
||||
|
|
@ -129,12 +123,10 @@ if (class_exists('GF_Field')) {
|
|||
private function PrettyListDocumentOrder($value)
|
||||
{
|
||||
$documentOrderPreviewHtml = '<ul>';
|
||||
|
||||
foreach ($value as $brochure => $quantities) {
|
||||
|
||||
$documentOrderAmountHtml = null;
|
||||
|
||||
|
||||
if ($quantities["quantity_fr"]) {
|
||||
$documentOrderAmountHtml .= '<li>' . __("Quantité FR: ", "homegrade-theme__texte-fonctionnel") . '<span class="brochure_quantity">' . $quantities["quantity_fr"] . '</span></li>';
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user