| Line 7... |
Line 7... |
| 7 |
from shop2020.model.v1.order.impl.DataAccessors import create_transaction,\
|
7 |
from shop2020.model.v1.order.impl.DataAccessors import create_transaction,\
|
| 8 |
get_transaction, get_all_transactions, get_transactions_for_shipment_status,\
|
8 |
get_transaction, get_all_transactions, get_transactions_for_shipment_status,\
|
| 9 |
get_transactions_for_customer, get_transactions_for_customer_shipment,\
|
9 |
get_transactions_for_customer, get_transactions_for_customer_shipment,\
|
| 10 |
get_transaction_status, change_transaction_status, set_shipping_tracker_info,\
|
10 |
get_transaction_status, change_transaction_status, set_shipping_tracker_info,\
|
| 11 |
change_shipping_status, set_shipping_date, set_delivery_date, get_line_items,\
|
11 |
change_shipping_status, set_shipping_date, set_delivery_date, get_line_items,\
|
| 12 |
get_shipments, get_billings, set_billing
|
12 |
get_shipments, get_billings, set_billing,\
|
| - |
|
13 |
get_transactions_for_shopping_cart_id
|
| 13 |
from shop2020.model.v1.order.impl.Convertors import to_t_transaction,\
|
14 |
from shop2020.model.v1.order.impl.Convertors import to_t_transaction,\
|
| 14 |
to_t_lineitem, to_t_shipment, to_t_billing
|
15 |
to_t_lineitem, to_t_shipment, to_t_billing
|
| 15 |
from shop2020.thriftpy.model.v1.order.ttypes import Transaction, OrderInfo,\
|
16 |
from shop2020.thriftpy.model.v1.order.ttypes import Transaction, OrderInfo,\
|
| 16 |
LineItem, ShipmentInfo, BillingInfo
|
17 |
LineItem, ShipmentInfo, BillingInfo
|
| 17 |
from shop2020.utils import OrderStatus
|
18 |
from shop2020.utils import OrderStatus
|
| Line 106... |
Line 107... |
| 106 |
t_transaction = []
|
107 |
t_transaction = []
|
| 107 |
for transaction in transactions:
|
108 |
for transaction in transactions:
|
| 108 |
t_transaction.append(to_t_transaction(transaction))
|
109 |
t_transaction.append(to_t_transaction(transaction))
|
| 109 |
return t_transaction
|
110 |
return t_transaction
|
| 110 |
|
111 |
|
| - |
|
112 |
def getTransactionsForShoppingCartId(self, shoppingCartId):
|
| - |
|
113 |
"""
|
| - |
|
114 |
Parameters:
|
| - |
|
115 |
- shoppingCartId
|
| - |
|
116 |
"""
|
| - |
|
117 |
transactions = get_transactions_for_shopping_cart_id(shoppingCartId)
|
| - |
|
118 |
t_transaction = []
|
| - |
|
119 |
for transaction in transactions:
|
| - |
|
120 |
t_transaction.append(to_t_transaction(transaction))
|
| - |
|
121 |
return t_transaction
|
| - |
|
122 |
pass
|
| - |
|
123 |
|
| - |
|
124 |
|
| 111 |
def getTransactionStatus(self, transactionId):
|
125 |
def getTransactionStatus(self, transactionId):
|
| 112 |
"""
|
126 |
"""
|
| 113 |
Parameters:
|
127 |
Parameters:
|
| 114 |
- transactionId
|
128 |
- transactionId
|
| 115 |
"""
|
129 |
"""
|