Index: /changelog
===================================================================
--- /changelog	(revision 7627)
+++ /changelog	(revision 7628)
@@ -309,4 +309,5 @@
  
 #4.1.9
-- Bugfix: Exportprofile (MwSt Wert)
-- Bugfix: LinkÃŒberprÃŒfung in Abonverwaltung 
+- Bugfix: Exportprofile (MwSt Wert) / Task #705
+- Bugfix: Export von verwendeten Gutscheinnummern / Task #705
+- Bugfix: LinkÃŒberprÃŒfung in Abonverwaltung / Task #707
Index: /mods/wpsg_mod_export.class.php
===================================================================
--- /mods/wpsg_mod_export.class.php	(revision 7627)
+++ /mods/wpsg_mod_export.class.php	(revision 7628)
@@ -2003,7 +2003,24 @@
 				case 'order_weight': $return = $order['weight']; break;
 				case 'order_gutschein': 
-					
-					if ($order['gs_id'] > 0)
+										
+					if (wpsg_isSizedInt($order['gs_id'])) {
+					
+						// AbwÃ€rtskompatibilitÃ€t fÃŒr alte Bestellungen						
 						$return = $this->db->fetchOne("SELECT `code` FROM `".WPSG_TBL_GUTSCHEIN."` WHERE `id` = '".wpsg_q($order['gs_id'])."'");
+						
+					} else {
+						
+						$return = $this->db->fetchOne("
+							SELECT
+								GROUP_CONCAT(`code`)
+							FROM
+								`".WPSG_TBL_ORDER_VOUCHER."`
+							WHERE
+								`order_id` = '".wpsg_q($order['id'])."'
+							GROUP BY
+								`order_id`
+						");
+							
+					}
 						
 					break;
