Browse Source

云存提示新方案

chenshibin 4 years ago
parent
commit
966a2b166f
1 changed files with 15 additions and 10 deletions
  1. 15 10
      Controller/CloudStorage.py

+ 15 - 10
Controller/CloudStorage.py

@@ -786,7 +786,7 @@ class CloudStorageView(View):
 
 
                     order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                     order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
-                    sys_msg_text_list = ['温馨提示:尊敬的客户,您的'+UID+'设备在'+datetime+'已成功购买云存套餐', 'Warm tips: Dear customers, your '+UID+' device has successfully purchased the cloud storage package in '+datetime]
+                    sys_msg_text_list = ['温馨提示:尊敬的客户,您的'+UID+'设备在'+datetime+'已成功购买云存套餐', 'Dear customer,you already subscribed the cloud storage package successfully for device ' + UID + ' on '+ time.strftime("%b %dth,%Y", time.localtime())]
                     self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_219738485')
                     self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_219738485')
                     red_url = "{SERVER_DOMAIN_SSL}web/paid2/success.html".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL)
                     red_url = "{SERVER_DOMAIN_SSL}web/paid2/success.html".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL)
                     if lang != 'cn':
                     if lang != 'cn':
@@ -894,7 +894,8 @@ class CloudStorageView(View):
                 order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                 order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                 datetime = time.strftime("%Y-%m-%d", time.localtime())
                 datetime = time.strftime("%Y-%m-%d", time.localtime())
                 sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + UID + '设备在' + datetime + '已成功购买云存套餐',
                 sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + UID + '设备在' + datetime + '已成功购买云存套餐',
-                                     'Warm tips: Dear customers, your '+UID+' device has successfully purchased the cloud storage package in '+datetime]
+                                     'Dear customer,you already subscribed the cloud storage package successfully for device ' + UID + ' on ' + time.strftime(
+                                         "%b %dth,%Y", time.localtime())]
 
 
                 self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_219738485')
                 self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_219738485')
 
 
@@ -997,7 +998,9 @@ class CloudStorageView(View):
                     order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                     order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + UID + '设备在' + datetime + '已成功购买云存套餐',
                     sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + UID + '设备在' + datetime + '已成功购买云存套餐',
-                                         'Warm tips: Dear customers, your '+UID+' device has successfully purchased the cloud storage package in '+datetime]
+                                         'Dear customer,you already subscribed the cloud storage package successfully for device ' + UID + ' on ' + time.strftime(
+                                             "%b %dth,%Y", time.localtime())]
+
                     self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_219738485')
                     self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_219738485')
                     return HttpResponse(pay.xml_to_dict({'return_code': 'SUCCESS', 'return_msg': 'OK'}))
                     return HttpResponse(pay.xml_to_dict({'return_code': 'SUCCESS', 'return_msg': 'OK'}))
             else:
             else:
@@ -1278,7 +1281,9 @@ class CloudStorageView(View):
                 sms = 'SMS_219738485'
                 sms = 'SMS_219738485'
                 datetime = time.strftime("%Y-%m-%d", time.localtime())
                 datetime = time.strftime("%Y-%m-%d", time.localtime())
                 sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + uid + '设备在' + datetime + '已成功购买云存套餐',
                 sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + uid + '设备在' + datetime + '已成功购买云存套餐',
-                                     'Warm tips: Dear customers, your '+uid+' device has successfully purchased the cloud storage package in '+datetime]
+                                     'Dear customer,you already subscribed the cloud storage package successfully for device ' + uid + ' on ' + time.strftime(
+                                         "%b %dth,%Y", time.localtime())]
+
                 # return response.json(0)
                 # return response.json(0)
                 returnurl = "{SERVER_DOMAIN_SSL}cloudstorage/payOK?lang={lang}".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL,lang=lang)
                 returnurl = "{SERVER_DOMAIN_SSL}cloudstorage/payOK?lang={lang}".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL,lang=lang)
                 if pay_type == 10:
                 if pay_type == 10:
@@ -1289,9 +1294,9 @@ class CloudStorageView(View):
                     )
                     )
                     returnurl = "{SERVER_DOMAIN_SSL}cloudstorage/payOK?paytype=10&lang={lang}".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL,lang=lang)
                     returnurl = "{SERVER_DOMAIN_SSL}cloudstorage/payOK?paytype=10&lang={lang}".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL,lang=lang)
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
-                    sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + uid + '设备在' + datetime + '已成功体验云存',
-                                         'Warm tips: respected customers, your '+uid+' device has successfully experienced cloud storage in '+datetime]
-                    sms = 'SMS_219743364'
+                    sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + uid + '设备在' + datetime + '已成功开通云存体验套餐',
+                                         'Dear customer,you already subscribed the free trial cloud storage service successfully for device ' + uid + ' on '+ time.strftime("%b %dth,%Y", time.localtime())]
+                    sms = 'SMS_222870823'
                 if pay_type == 11:
                 if pay_type == 11:
                     update_dict = {}
                     update_dict = {}
                     update_dict['is_activate'] = 1
                     update_dict['is_activate'] = 1
@@ -1301,7 +1306,7 @@ class CloudStorageView(View):
 
 
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + uid + '设备在' + datetime + '已成功兑换云存',
                     sys_msg_text_list = ['温馨提示:尊敬的客户,您的' + uid + '设备在' + datetime + '已成功兑换云存',
-                                         'Warm tips: Dear customers, your '+uid+' device has been successfully converted to cloud deposit at '+datetime]
+                                         'Dear customer, you already redeemed for the cloud storage package successfully for device ' +uid +' on '+time.strftime("%b %dth,%Y", time.localtime())]
                     sms = 'SMS_219748439'
                     sms = 'SMS_219748439'
 
 
                 self.do_vod_msg_Notice(uid, channel, userID, lang, sys_msg_text_list, sms)
                 self.do_vod_msg_Notice(uid, channel, userID, lang, sys_msg_text_list, sms)
@@ -1521,7 +1526,7 @@ class CloudStorageView(View):
                     if ub['bucket__area'] == 'cn':
                     if ub['bucket__area'] == 'cn':
                         sys_msg_text = "温馨提示:尊敬的客户,您" + ub['uid'] + "设备的云存套餐将在" + time.strftime("%Y-%m-%d", time.localtime(ub['endTime'])) + "到期"
                         sys_msg_text = "温馨提示:尊敬的客户,您" + ub['uid'] + "设备的云存套餐将在" + time.strftime("%Y-%m-%d", time.localtime(ub['endTime'])) + "到期"
                     else:
                     else:
-                        sys_msg_text = "Warm tips: Dear customers, the cloud storage package of your " + ub['uid'] + " device will expire at " + time.strftime("%Y-%m-%d", time.localtime(ub['endTime']))
+                        sys_msg_text = 'Dear customer,the cloud storage package for your device '+ub['uid']+' will expire on '+time.strftime('%m-%d-%y',time.localtme(ub['endTime']))
                     uq_list.append(SysMsgModel(
                     uq_list.append(SysMsgModel(
                         userID_id=oo['userID_id'],
                         userID_id=oo['userID_id'],
                         addTime=now_time,
                         addTime=now_time,
@@ -1668,7 +1673,7 @@ class CloudStorageView(View):
 
 
     def sendMessage(self, phone , params, temp_msg):
     def sendMessage(self, phone , params, temp_msg):
             # 购买成功
             # 购买成功
-            sign_ms = 'Ansjer'
+            sign_ms = '周视'
             # 发送手机验证码
             # 发送手机验证码
             aliSms = AliSmsObject()
             aliSms = AliSmsObject()
             res = aliSms.send_code_sms_cloud(phone=phone, params = params, sign_name=sign_ms,
             res = aliSms.send_code_sms_cloud(phone=phone, params = params, sign_name=sign_ms,