trex-model 1.6.9__tar.gz → 1.6.11__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of trex-model might be problematic. Click here for more details.
- {trex_model-1.6.9 → trex_model-1.6.11}/PKG-INFO +1 -1
- {trex_model-1.6.9 → trex_model-1.6.11}/setup.py +1 -1
- {trex_model-1.6.9 → trex_model-1.6.11}/trex_model.egg-info/PKG-INFO +1 -1
- {trex_model-1.6.9 → trex_model-1.6.11}/trex_model.egg-info/SOURCES.txt +1 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/customer_model_helpers.py +26 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/customer_models.py +6 -1
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/merchant_models.py +13 -1
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/ndb_models.py +9 -3
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/rating_models.py +28 -2
- trex_model-1.6.11/trexmodel/models/datastore/support_models.py +32 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/transaction_models.py +22 -6
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/merchant_helpers.py +10 -6
- {trex_model-1.6.9 → trex_model-1.6.11}/LICENSE +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/MANIFEST.in +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/README.md +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/setup.cfg +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trex_model.egg-info/dependency_links.txt +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trex_model.egg-info/requires.txt +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trex_model.egg-info/top_level.txt +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/conf.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/admin_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/analytic_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/app_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/coporate_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/fb_subsriber_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/helper/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/helper/reward_model_helpers.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/helper/reward_transaction_helper.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/helper/sales_transaction_helpers.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/import_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/inventory_model.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/loyalty_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/lucky_draw_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/marketing_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/membership_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/merchant_promotion_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/message_model_helper.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/message_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/model_decorators.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/partnership_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/pos_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/prepaid_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/product_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/program_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/recruit_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/redeem_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/redemption_catalogue_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/referral_program_model.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/reward_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/spending_base_program_model.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/system_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/task_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/test_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/user_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/voucher_models.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/model_decorator.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/prepaid_helpers.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/pos_conf.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/program_conf.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/utils/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/utils/gcloud/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/utils/gcloud/datastore_util.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/utils/model/__init__.py +0 -0
- {trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/utils/model/model_util.py +0 -0
|
@@ -48,6 +48,7 @@ trexmodel/models/datastore/redemption_catalogue_models.py
|
|
|
48
48
|
trexmodel/models/datastore/referral_program_model.py
|
|
49
49
|
trexmodel/models/datastore/reward_models.py
|
|
50
50
|
trexmodel/models/datastore/spending_base_program_model.py
|
|
51
|
+
trexmodel/models/datastore/support_models.py
|
|
51
52
|
trexmodel/models/datastore/system_models.py
|
|
52
53
|
trexmodel/models/datastore/task_models.py
|
|
53
54
|
trexmodel/models/datastore/test_models.py
|
|
@@ -399,6 +399,32 @@ def update_customer_entiteld_voucher_summary_after_removed_voucher(customer_enti
|
|
|
399
399
|
customer_entitled_voucher_summary[merchant_voucher_key]['amount'] = len(new_redeem_info_list)
|
|
400
400
|
|
|
401
401
|
return customer_entitled_voucher_summary
|
|
402
|
+
|
|
403
|
+
def update_customer_entiteld_voucher_summary_after_removed_voucher_by_redeem_code(customer_entitled_voucher_summary, redeem_code):
|
|
404
|
+
'''
|
|
405
|
+
removed entitled voucher from customer entitled voucher summary
|
|
406
|
+
'''
|
|
407
|
+
logger.debug('redeem_code=%s', redeem_code)
|
|
408
|
+
|
|
409
|
+
new_customer_entitled_voucher_summary = {}
|
|
410
|
+
|
|
411
|
+
if customer_entitled_voucher_summary:
|
|
412
|
+
|
|
413
|
+
for merchant_voucher_key, voucher_summary in customer_entitled_voucher_summary.items():
|
|
414
|
+
new_redeem_info_list = []
|
|
415
|
+
redeem_info_list = voucher_summary.get('redeem_info_list')
|
|
416
|
+
for redeem_info in redeem_info_list:
|
|
417
|
+
if redeem_info.get('redeem_code')!=redeem_code:
|
|
418
|
+
new_redeem_info_list.append(redeem_info)
|
|
419
|
+
|
|
420
|
+
new_customer_entitled_voucher_summary[merchant_voucher_key] = {}
|
|
421
|
+
new_customer_entitled_voucher_summary[merchant_voucher_key]['redeem_info_list'] = new_redeem_info_list
|
|
422
|
+
new_customer_entitled_voucher_summary[merchant_voucher_key]['count'] = len(new_redeem_info_list)
|
|
423
|
+
new_customer_entitled_voucher_summary[merchant_voucher_key]['amount'] = len(new_redeem_info_list)
|
|
424
|
+
|
|
425
|
+
|
|
426
|
+
|
|
427
|
+
return new_customer_entitled_voucher_summary
|
|
402
428
|
|
|
403
429
|
|
|
404
430
|
def update_customer_entiteld_voucher_summary_after_reverted_voucher(entitled_voucher_summary, reverted_customer_voucher):
|
|
@@ -19,7 +19,8 @@ from datetime import datetime, timedelta
|
|
|
19
19
|
from trexmodel.models.datastore.membership_models import MerchantTierMembership,\
|
|
20
20
|
MerchantMembership
|
|
21
21
|
from trexmodel.models.datastore.customer_model_helpers import update_customer_entiteld_voucher_summary_after_removed_voucher,\
|
|
22
|
-
update_customer_entiteld_voucher_summary_with_customer_new_voucher
|
|
22
|
+
update_customer_entiteld_voucher_summary_with_customer_new_voucher,\
|
|
23
|
+
update_customer_entiteld_voucher_summary_after_removed_voucher_by_redeem_code
|
|
23
24
|
|
|
24
25
|
|
|
25
26
|
logger = logging.getLogger('model')
|
|
@@ -758,6 +759,10 @@ class Customer(BaseNModel, DictModel, FullTextSearchable):
|
|
|
758
759
|
update_customer_entiteld_voucher_summary_after_removed_voucher(entitled_voucher_summary, removed_voucher)
|
|
759
760
|
self.put()
|
|
760
761
|
|
|
762
|
+
def update_after_removed_voucher_by_redeem_code(self, redeem_code):
|
|
763
|
+
self.entitled_voucher_summary = update_customer_entiteld_voucher_summary_after_removed_voucher_by_redeem_code(self.entitled_voucher_summary, redeem_code)
|
|
764
|
+
self.put()
|
|
765
|
+
|
|
761
766
|
def update_after_added_voucher(self, added_voucher):
|
|
762
767
|
entitled_voucher_summary = self.entitled_voucher_summary
|
|
763
768
|
update_customer_entiteld_voucher_summary_with_customer_new_voucher(entitled_voucher_summary, added_voucher)
|
|
@@ -171,8 +171,10 @@ class MerchantAcct(MerchantMin):
|
|
|
171
171
|
'currency_code' : self.currency_code,
|
|
172
172
|
'country' : self.country,
|
|
173
173
|
'account_plan' : self.account_plan,
|
|
174
|
+
'gmt_hour' : self.gmt_hour,
|
|
175
|
+
'account_plan' : self.account_plan,
|
|
174
176
|
}
|
|
175
|
-
|
|
177
|
+
|
|
176
178
|
@property
|
|
177
179
|
def product_package(self):
|
|
178
180
|
if self.account_plan:
|
|
@@ -1852,6 +1854,16 @@ class Outlet(BusinessEntity, FullTextSearchable):
|
|
|
1852
1854
|
outlet.is_headquarter = is_headquarter
|
|
1853
1855
|
outlet.put()
|
|
1854
1856
|
|
|
1857
|
+
def to_brief_dict(self):
|
|
1858
|
+
return {
|
|
1859
|
+
'outlet_name' : self.name,
|
|
1860
|
+
'company_name' : self.company_name,
|
|
1861
|
+
'business_reg_no' : self.business_reg_no,
|
|
1862
|
+
'address' : self.address,
|
|
1863
|
+
'email' : self.email,
|
|
1864
|
+
'office_phone' : self.office_phone,
|
|
1865
|
+
}
|
|
1866
|
+
|
|
1855
1867
|
@staticmethod
|
|
1856
1868
|
def list_by_merchant_acct(merchant_acct):
|
|
1857
1869
|
return Outlet.query(ancestor = merchant_acct.create_ndb_key()).fetch(limit=model_conf.MAX_FETCH_RECORD)
|
|
@@ -139,8 +139,13 @@ class DictObject(object):
|
|
|
139
139
|
def properties(self):
|
|
140
140
|
return self.__dict__
|
|
141
141
|
|
|
142
|
-
def to_dict(self, full=True, show_key=True, dict_properties=None,
|
|
143
|
-
|
|
142
|
+
def to_dict(self, full=True, show_key=True, dict_properties=None,
|
|
143
|
+
excluded_dict_properties=None,
|
|
144
|
+
#gmt=lib_conf.DEFAULT_GMT,
|
|
145
|
+
gmt=0,
|
|
146
|
+
datetime_format=lib_conf.DEFAULT_DATETIME_FORMAT,
|
|
147
|
+
date_format=lib_conf.DEFAULT_DATE_FORMAT,
|
|
148
|
+
time_format=lib_conf.DEFAULT_TIME_FORMAT,
|
|
144
149
|
deep_level=99,
|
|
145
150
|
):
|
|
146
151
|
logger.info('calling DictObject.to_dict')
|
|
@@ -183,7 +188,8 @@ class DictModel(ndb.Model):
|
|
|
183
188
|
def __str__(self):
|
|
184
189
|
return '%s' % self.to_dict(deep_level=1)
|
|
185
190
|
|
|
186
|
-
def to_dict(self, full=False, show_key=True, dict_properties=None, excluded_dict_properties=None,
|
|
191
|
+
def to_dict(self, full=False, show_key=True, dict_properties=None, excluded_dict_properties=None,
|
|
192
|
+
gmt=0,
|
|
187
193
|
datetime_format=lib_conf.DEFAULT_DATETIME_FORMAT,
|
|
188
194
|
date_format=lib_conf.DEFAULT_DATE_FORMAT,time_format=lib_conf.DEFAULT_TIME_FORMAT,
|
|
189
195
|
deep_level=99,
|
|
@@ -12,6 +12,7 @@ from datetime import datetime, timedelta
|
|
|
12
12
|
import logging
|
|
13
13
|
from trexmodel.models.datastore.transaction_models import CustomerTransaction
|
|
14
14
|
from trexmodel.models.datastore.model_decorators import model_transactional
|
|
15
|
+
from trexlib.utils.common.date_util import convert_date_to_datetime
|
|
15
16
|
|
|
16
17
|
#logger = logging.getLogger('model')
|
|
17
18
|
logger = logging.getLogger('target_debug')
|
|
@@ -34,13 +35,34 @@ class TransactionRating(RatingBase):
|
|
|
34
35
|
|
|
35
36
|
created_datetime = ndb.DateTimeProperty(required=True, auto_now_add=True)
|
|
36
37
|
|
|
37
|
-
dict_properties = ['transaction_id','rating_result', 'remarks', 'industry', 'score',
|
|
38
|
+
dict_properties = ['transaction_id','rating_result', 'remarks', 'industry', 'score', 'created_datetime',
|
|
38
39
|
]
|
|
39
40
|
|
|
40
41
|
@property
|
|
41
42
|
def merchant_acct_entity(self):
|
|
42
43
|
return self.merchant_acct.get()
|
|
43
44
|
|
|
45
|
+
@property
|
|
46
|
+
def user_acct_key(self):
|
|
47
|
+
return self.user_acct.urlsafe().decode('utf-8')
|
|
48
|
+
|
|
49
|
+
@staticmethod
|
|
50
|
+
def list_transaction_by_date(enquiry_date, outlet=None, offset=0, limit=conf.PAGINATION_SIZE, return_with_cursor=False, start_cursor=None):
|
|
51
|
+
start_datetime = convert_date_to_datetime(enquiry_date)
|
|
52
|
+
end_datetime = start_datetime + timedelta(days=1)
|
|
53
|
+
query = TransactionRating.query(
|
|
54
|
+
ndb.AND(
|
|
55
|
+
TransactionRating.outlet==outlet.create_ndb_key(),
|
|
56
|
+
TransactionRating.created_datetime>=start_datetime,
|
|
57
|
+
TransactionRating.created_datetime<end_datetime,
|
|
58
|
+
))
|
|
59
|
+
if return_with_cursor:
|
|
60
|
+
(result, next_cursor) = TransactionRating.list_all_with_condition_query(query, order_by=TransactionRating.created_datetime, start_cursor=start_cursor, return_with_cursor=True, limit=limit)
|
|
61
|
+
|
|
62
|
+
return (result, next_cursor)
|
|
63
|
+
else:
|
|
64
|
+
return query.order(TransactionRating.created_datetime).fetch(offset=offset, limit=limit)
|
|
65
|
+
|
|
44
66
|
@staticmethod
|
|
45
67
|
@model_transactional(desc="update rating changes")
|
|
46
68
|
def create(user_acct, transaction_id, rating_result={},
|
|
@@ -321,7 +343,11 @@ class OutletRatingResult(RatingResult):
|
|
|
321
343
|
outlet = ndb.KeyProperty(name="outlet", kind=Outlet)
|
|
322
344
|
|
|
323
345
|
|
|
324
|
-
dict_properties = ['total_rating_count', 'rating_result', 'previous_rating_result', 'modified_datetime',]
|
|
346
|
+
dict_properties = ['total_rating_count', 'rating_result', 'previous_rating_result', 'modified_datetime', 'outlet_key']
|
|
347
|
+
|
|
348
|
+
@property
|
|
349
|
+
def outlet_key(self):
|
|
350
|
+
return self.outlet.urlsafe().decode('utf-8')
|
|
325
351
|
|
|
326
352
|
@staticmethod
|
|
327
353
|
def get_by_outlet(outlet):
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
'''
|
|
2
|
+
Created on 28 Jul 2025
|
|
3
|
+
|
|
4
|
+
@author: jacklok
|
|
5
|
+
'''
|
|
6
|
+
|
|
7
|
+
from trexmodel.models.datastore.ndb_models import BaseNModel, DictModel
|
|
8
|
+
from google.cloud import ndb
|
|
9
|
+
import logging
|
|
10
|
+
|
|
11
|
+
#logger = logging.getLogger('model')
|
|
12
|
+
logger = logging.getLogger('target_debug')
|
|
13
|
+
|
|
14
|
+
class SupportReportBase(BaseNModel, DictModel):
|
|
15
|
+
activation_code = ndb.StringProperty(required=False)
|
|
16
|
+
platform = ndb.StringProperty(required=True)
|
|
17
|
+
error_message = ndb.TextProperty(required=False)
|
|
18
|
+
stack_trace = ndb.TextProperty(required=False)
|
|
19
|
+
reported_datetime = ndb.DateTimeProperty(required=True, auto_now=True)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
class ErrorReport(SupportReportBase):
|
|
24
|
+
|
|
25
|
+
@staticmethod
|
|
26
|
+
def create(platform, error_message, activation_code=None, stack_trace=None, ):
|
|
27
|
+
ErrorReport(
|
|
28
|
+
activation_code = activation_code,
|
|
29
|
+
platform = platform,
|
|
30
|
+
error_message = error_message,
|
|
31
|
+
stack_trace = stack_trace,
|
|
32
|
+
).put()
|
|
@@ -188,13 +188,29 @@ class SalesTransaction(BaseNModel, DictModel):
|
|
|
188
188
|
return customer_transaction
|
|
189
189
|
|
|
190
190
|
@classmethod
|
|
191
|
-
def list_outlet_transaction(cls, transact_outlet, offset=0, limit=conf.PAGINATION_SIZE, start_cursor=None, return_with_cursor=False, reverse_order=True):
|
|
192
|
-
if
|
|
193
|
-
|
|
191
|
+
def list_outlet_transaction(cls, transact_outlet, enquiry_date=None, offset=0, limit=conf.PAGINATION_SIZE, start_cursor=None, return_with_cursor=False, reverse_order=True):
|
|
192
|
+
if enquiry_date:
|
|
193
|
+
enquiry_datetime = datetime.combine(enquiry_date, datetime.min.time())
|
|
194
|
+
next_enquiry_datetime = enquiry_datetime + timedelta(days=1)
|
|
195
|
+
query = cls.query(ndb.AND(
|
|
196
|
+
cls.transact_datetime >= enquiry_datetime,
|
|
197
|
+
cls.transact_datetime < next_enquiry_datetime,
|
|
198
|
+
cls.transact_outlet==transact_outlet.create_ndb_key())
|
|
199
|
+
)
|
|
200
|
+
if reverse_order:
|
|
201
|
+
query = query.order(-cls.transact_datetime)
|
|
202
|
+
else:
|
|
203
|
+
query = query.order(cls.transact_datetime)
|
|
204
|
+
|
|
205
|
+
return cls.list_all_with_condition_query(query, offset=offset, limit=limit, start_cursor=start_cursor, return_with_cursor=return_with_cursor)
|
|
194
206
|
else:
|
|
195
|
-
query = cls.query(ndb.AND(cls.transact_outlet==transact_outlet.create_ndb_key())).order(cls.transact_datetime)
|
|
196
|
-
|
|
197
|
-
|
|
207
|
+
query = cls.query(ndb.AND(cls.transact_outlet==transact_outlet.create_ndb_key())).order(-cls.transact_datetime)
|
|
208
|
+
if reverse_order:
|
|
209
|
+
query = query.order(-cls.transact_datetime)
|
|
210
|
+
else:
|
|
211
|
+
query = query.order(cls.transact_datetime)
|
|
212
|
+
|
|
213
|
+
return cls.list_all_with_condition_query(query, offset=offset, limit=limit, start_cursor=start_cursor, return_with_cursor=return_with_cursor)
|
|
198
214
|
|
|
199
215
|
@classmethod
|
|
200
216
|
def count_outlet_transaction(cls, transact_outlet, limit=conf.MAX_FETCH_RECORD):
|
|
@@ -15,6 +15,7 @@ def construct_merchant_acct_info(merchant_acct, referrer_code=None):
|
|
|
15
15
|
'account_code' : merchant_acct.account_code,
|
|
16
16
|
'currency' : merchant_acct.currency_code,
|
|
17
17
|
'locale' : merchant_acct.locale,
|
|
18
|
+
'gmt_hour' : merchant_acct.gmt_hour,
|
|
18
19
|
}
|
|
19
20
|
|
|
20
21
|
outlet_list = Outlet.list_by_merchant_acct(merchant_acct)
|
|
@@ -229,6 +230,7 @@ def construct_setting_by_outlet(outlet, device_setting=None, is_pos_device=False
|
|
|
229
230
|
'account_code' : merchant_acct.account_code,
|
|
230
231
|
'currency' : merchant_acct.currency_code,
|
|
231
232
|
'locale' : merchant_acct.locale,
|
|
233
|
+
'gmt_hour' : merchant_acct.gmt_hour,
|
|
232
234
|
}
|
|
233
235
|
|
|
234
236
|
logger.info('is_pos_device=%s', is_pos_device)
|
|
@@ -287,11 +289,12 @@ def construct_setting_by_outlet(outlet, device_setting=None, is_pos_device=False
|
|
|
287
289
|
'is_rounding_required' : d.is_rounding_required,
|
|
288
290
|
})
|
|
289
291
|
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
292
|
+
if is_pos_device:
|
|
293
|
+
account_settings['assigned_service_charge_setup'] = outlet.service_charge_settings
|
|
294
|
+
account_settings['assigned_tax_setup'] = outlet.assigned_tax_setup
|
|
295
|
+
account_settings['dinning_table_list'] = outlet.assigned_dinning_table_list
|
|
296
|
+
account_settings['show_dinning_table_occupied'] = outlet.show_dinning_table_occupied
|
|
297
|
+
account_settings['payment_methods'] = pos_payment_method_json
|
|
295
298
|
|
|
296
299
|
|
|
297
300
|
outlet_details = {
|
|
@@ -305,7 +308,8 @@ def construct_setting_by_outlet(outlet, device_setting=None, is_pos_device=False
|
|
|
305
308
|
'email' : outlet.email,
|
|
306
309
|
'phone' : outlet.office_phone,
|
|
307
310
|
'website' : merchant_acct.website or '',
|
|
308
|
-
|
|
311
|
+
'industry_type' : merchant_acct.industry,
|
|
312
|
+
'gmt_hour' : merchant_acct.gmt_hour,
|
|
309
313
|
}
|
|
310
314
|
|
|
311
315
|
program_configurations = {
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/helper/reward_model_helpers.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/merchant_promotion_models.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/redemption_catalogue_models.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trex_model-1.6.9 → trex_model-1.6.11}/trexmodel/models/datastore/spending_base_program_model.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|