From 8c32ffd2e28afc430aca3ce24287e5e460e1b8a9 Mon Sep 17 00:00:00 2001 From: ptibogxiv Date: Sun, 16 Sep 2018 22:36:58 +0200 Subject: [PATCH 1/2] fix html --- htdocs/stripe/charge.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/stripe/charge.php b/htdocs/stripe/charge.php index b9b654e6553..310ad813ebe 100644 --- a/htdocs/stripe/charge.php +++ b/htdocs/stripe/charge.php @@ -158,7 +158,7 @@ if (!$rowid) { $url='https://dashboard.stripe.com/'.$connect.'payments/'.$charge->id; } - print "".img_picto($langs->trans('ShowInStripe'), 'object_globe')." ".$charge->id."\n"; + print "".img_picto($langs->trans('ShowInStripe'), 'object_globe')." ".$charge->id."\n"; // Stripe customer print ""; @@ -168,7 +168,7 @@ if (!$rowid) { $url='https://dashboard.stripe.com/'.$connect.'customers/'.$charge->customer; } - print ' '.img_picto($langs->trans('ShowInStripe'), 'object_globe').' '.$charge->customer.''; + print ''.img_picto($langs->trans('ShowInStripe'), 'object_globe').' '.$charge->customer.''; print "\n"; // Link From 38b23d2be480c254320b13e159b4406bae799331 Mon Sep 17 00:00:00 2001 From: ptibogxiv Date: Sun, 16 Sep 2018 22:55:50 +0200 Subject: [PATCH 2/2] Update charge.php --- htdocs/stripe/charge.php | 62 ++++++++++++++++++++-------------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/htdocs/stripe/charge.php b/htdocs/stripe/charge.php index 310ad813ebe..d39cac84eca 100644 --- a/htdocs/stripe/charge.php +++ b/htdocs/stripe/charge.php @@ -79,24 +79,24 @@ $stripeacc = $stripe->getStripeAccount($service); if (!$rowid) { - print '
'; - if ($optioncss != '') print ''; - print ''; - print ''; - print ''; - print ''; - print ''; - print ''; + print ''; + if ($optioncss != '') print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; $title=$langs->trans("StripeChargeList"); $title.=($stripeacc?' (Stripe connection with Stripe OAuth Connect account '.$stripeacc.')':' (Stripe connection with keys from Stripe module setup)'); print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder,'',$num, $totalnboflines, 'title_accountancy.png', 0, '', '', $limit); - print '
'; - print ''."\n"; + print '
'; + print '
'."\n"; - print ''; + print ''; print_liste_field_titre("Ref",$_SERVER["PHP_SELF"],"","","","",$sortfield,$sortorder); print_liste_field_titre("StripeCustomerId",$_SERVER["PHP_SELF"],"","","","",$sortfield,$sortorder); print_liste_field_titre("Customer",$_SERVER["PHP_SELF"],"","","","",$sortfield,$sortorder); @@ -105,9 +105,9 @@ if (!$rowid) print_liste_field_titre("Type",$_SERVER["PHP_SELF"],"","","",'align="left"',$sortfield,$sortorder); print_liste_field_titre("Paid",$_SERVER["PHP_SELF"],"","","",'align="right"',$sortfield,$sortorder); print_liste_field_titre("Status",$_SERVER["PHP_SELF"],"","","",'align="right"'); - print "\n"; + print "\n"; - print "\n"; + print "\n"; if ($stripeacc) { @@ -148,7 +148,7 @@ if (!$rowid) $memberstatic->id = 0; } - print ''; + print ''; if (! empty($conf->stripe->enabled) && !empty($stripeacc)) $connect=$stripeacc.'/'; @@ -158,9 +158,9 @@ if (!$rowid) { $url='https://dashboard.stripe.com/'.$connect.'payments/'.$charge->id; } - print "\n"; + print "\n"; // Stripe customer - print "\n"; + print "\n"; // Link - print "\n"; + print "\n"; // Origine - print "\n"; + print "\n"; // Date payment - print '\n"; + print '\n"; // Type - print ''; + print ''; // Amount - print ""; + print ""; // Status - print '\n"; + print "\n"; - print "\n"; + print "\n"; } } else {
".img_picto($langs->trans('ShowInStripe'), 'object_globe')." ".$charge->id."".img_picto($langs->trans('ShowInStripe'), 'object_globe')." ".$charge->id.""; + print ""; if (! empty($conf->stripe->enabled) && !empty($stripeacc)) $connect=$stripeacc.'/'; $url='https://dashboard.stripe.com/'.$connect.'test/customers/'.$charge->customer; @@ -168,11 +168,11 @@ if (!$rowid) { $url='https://dashboard.stripe.com/'.$connect.'customers/'.$charge->customer; } - print ''.img_picto($langs->trans('ShowInStripe'), 'object_globe').' '.$charge->customer.''; + print ''.img_picto($langs->trans('ShowInStripe'), 'object_globe').' '.$charge->customer.''; - print ""; + print ""; if ($societestatic->id > 0) { print $societestatic->getNomUrl(1); @@ -181,27 +181,27 @@ if (!$rowid) { print $memberstatic->getNomUrl(1); } - print ""; + print ""; if ($charge->metadata->dol_type=="order"){ $object = new Commande($db); $object->fetch($charge->metadata->dol_id); if ($object->id > 0) { - print "".img_picto('', 'object_order')." ".$object->ref.""; + print "".img_picto('', 'object_order')." ".$object->ref.""; } else print $FULLTAG; } elseif ($charge->metadata->dol_type=="invoice"){ $object = new Facture($db); $object->fetch($charge->metadata->dol_id); if ($object->id > 0) { - print "".img_picto('', 'object_invoice')." ".$object->ref.""; + print "".img_picto('', 'object_invoice')." ".$object->ref.""; } else print $FULLTAG; } else print $FULLTAG; - print "'.dol_print_date($charge->created,'%d/%m/%Y %H:%M')."'.dol_print_date($charge->created,'%d/%m/%Y %H:%M')."'; + print ''; if ($charge->source->object=='card') { print $langs->trans("card"); @@ -211,11 +211,11 @@ if (!$rowid) } elseif ($charge->source->type=='three_d_secure'){ print $langs->trans("card3DS"); } - print '".price(($charge->amount-$charge->amount_refunded)/100, 0, '', 1, - 1, - 1, strtoupper($charge->currency))."".price(($charge->amount-$charge->amount_refunded)/100, 0, '', 1, - 1, - 1, strtoupper($charge->currency))."'; + print ''; if ($charge->refunded=='1'){ print img_picto($langs->trans("refunded"),'statut6'); } elseif ($charge->paid=='1'){ @@ -228,9 +228,9 @@ if (!$rowid) $label.="Statut: ".$langs->trans("".$charge->outcome->seller_message.""); print $form->textwithpicto(img_picto($langs->trans("".$charge->status.""),'statut8'),$label,1); } - print "