חשבוניות SLK

Easy Digital Downloads

מסמך לכל רכישה שהושלמה ב-EDD, וחשבונית זיכוי לכל החזר

WordPressתוסףהחזר ← זיכוי

מה צריך

אימות
מפתח ה-API של החשבון (X-Api-Key)
החזרים
החזר מפיק חשבונית זיכוי אוטומטית
בעמוד הזה

מסמך לכל רכישה שהושלמה ב-EDD (גרסאות 2.x ו-3.x), וחשבונית זיכוי לכל החזר.

התקנה (5 דקות)#

  1. התקינו את התוסף לפי ההוראות הכלליות והדביקו את מפתח ה-API בלשונית חיבור.
  2. פתחו את הלשונית Easy Digital Downloads.
  3. סמנו הפעלת האינטגרציה, בחרו סוג מסמך (ברירת מחדל: חשבונית מס קבלה) ושמרו.
  4. אם החנות לא מחשבת מס, בחרו ב-מע"מ כשהמקור לא מדווח מס אם המחיר כולל מע"מ או פטור.
  5. בצעו רכישת בדיקה. המסמך מופק בסיום הרכישה, ובשורות שלו פריטי העגלה, העמלות וההנחות.

החזר ב-EDD (מלא או חלקי) מפיק חשבונית זיכוי שמפנה למסמך המקורי. אם המסמך המקורי לא הופק, הזיכוי מדולג ונרשם ביומן.

Developer reference#

ItemValue
Plugin classincludes/integrations/class-slk-integration-edd.php
Host guardclass_exists('Easy_Digital_Downloads') || function_exists('EDD')
Issue hookedd_complete_purchase( $order_id, $payment, $customer ) — https://github.com/awesomemotive/easy-digital-downloads/blob/main/includes/payments/actions.php
Refund hooksedd_refund_order( $order_id, $refund_id, $all_refunded ) (https://easydigitaldownloads.com/development/2021/05/20/edd-3-0-beta2/) and edd_post_refund_order (same arguments; a re-fire is harmless)
Data (3.x)edd_get_order(), order items and fee adjustments (https://easydigitaldownloads.com/docs/database-table-structures/); 2.x: EDD_Payment::cart_details and fees
apiIdentifieredd-<host>-<payment id>; credit note edd-<host>-<payment id>-refund-<refund id>
Idempotencyoption slk_invoices_issued_edd, keyed by payment id (and <id>|refund:<refund id>)

Mapping: each order item becomes a line (quantityMilli, net unit price = (subtotal − discount) / quantity, per-line vatBp from the item's tax when the store charges tax); each fee becomes a line. The payment row is the computed document total, payment type from the EDD gateway id (paypal* 10, stripe 1, manual cash, default card). When EDD reports no tax the tab's VAT mode decides: included (taxIncluded: true, default rate) or exempt (vatBp: 0).

Credit note: docType: 4, referenceDocIds: [<original document id>], one line "זיכוי" for the refund amount, following the original document's VAT mode.

Troubleshooting#

  • אין מסמך אחרי רכישה: ודאו שהאינטגרציה מסומנת, ושהרכישה הגיעה לסטטוס Complete (לא Pending).
  • ביומן "סכום הרכישה אפס": רכישה חינמית לא מפיקה מסמך.
  • ביומן "לא נמצא מסמך מקור": החזר על רכישה שהופקה לפני שהאינטגרציה הופעלה לא מזוכה אוטומטית. הפיקו זיכוי ידני ב-SLK Invoices.
  • כשל 401/403: ראו פתרון תקלות כלליות.

פותחים חשבון בדקה, ואז מדביקים את הכתובת.

חברו את Easy Digital Downloads
חיבור Easy Digital Downloads לחשבוניות SLK — הוראות התקנה | פורטל המפתחים