Bläddra i källkod

修改短信提示内容2

chenshibin 4 år sedan
förälder
incheckning
a1c30c62df
1 ändrade filer med 9 tillägg och 9 borttagningar
  1. 9 9
      Controller/CloudStorage.py

+ 9 - 9
Controller/CloudStorage.py

@@ -791,7 +791,7 @@ class CloudStorageView(View):
                     order_qs.update(status=1, updTime=nowTime, uid_bucket_id=uid_bucket_id)
                     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]
-                    self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list)
+                    self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_217407207')
                     red_url = "{SERVER_DOMAIN_SSL}web/paid2/success.html".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL)
                     if lang != 'cn':
                         red_url = "{SERVER_DOMAIN_SSL}web/paid2/en_success.html".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL)
@@ -899,7 +899,7 @@ class CloudStorageView(View):
                 sys_msg_text_list = ['温馨提示:尊重的客户,您的' + UID + '设备在' + datetime + '已成功购买云存套餐',
                                      'Warm tips: Dear customers, your '+UID+' device has successfully purchased the cloud storage package in '+datetime]
 
-                self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list)
+                self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_217407207')
 
                 # return response.json(0)
                 red_url = "{SERVER_DOMAIN_SSL}web/paid2/success.html".format(SERVER_DOMAIN_SSL=SERVER_DOMAIN_SSL)
@@ -1001,7 +1001,7 @@ class CloudStorageView(View):
                     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]
-                    self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list)
+                    self.do_vod_msg_Notice(UID, channel, userid, lang, sys_msg_text_list, 'SMS_217407207')
                     return HttpResponse(pay.xml_to_dict({'return_code': 'SUCCESS', 'return_msg': 'OK'}))
             else:
                 order_qs.update(status=10)
@@ -1278,7 +1278,7 @@ class CloudStorageView(View):
                 #         'user_id': userID
                 #     }
                 #     UIDMainUser.objects.create(**uid_main_dict)
-
+                sms = 'SMS_217407207'
                 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]
@@ -1294,7 +1294,7 @@ class CloudStorageView(View):
                     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_217407311'
                 if pay_type == 11:
                     update_dict = {}
                     update_dict['is_activate'] = 1
@@ -1305,9 +1305,9 @@ class CloudStorageView(View):
                     datetime = time.strftime("%Y-%m-%d", time.localtime())
                     sys_msg_text_list = ['温馨提示:尊重的客户,您的' + uid + '设备在' + datetime + '已成功兑换云存',
                                          'Warm tips: Dear customers, your '+uid+' device has been successfully converted to cloud deposit at '+datetime]
+                    sms = 'SMS_217417315'
 
-
-                self.do_vod_msg_Notice(uid, channel, userID, lang, sys_msg_text_list)
+                self.do_vod_msg_Notice(uid, channel, userID, lang, sys_msg_text_list, sms)
                 result = returnurl
                 return response.json(0, result)
         except Exception:
@@ -1434,7 +1434,7 @@ class CloudStorageView(View):
         return response.json(444)
 
     # 云存操作系统消息
-    def do_vod_msg_Notice(self, uid, channel, userID, lang, sys_msg_text_list):
+    def do_vod_msg_Notice(self, uid, channel, userID, lang, sys_msg_text_list, sms):
         try:
             logger = logging.getLogger('log')
             logger.info('进来了')
@@ -1458,7 +1458,7 @@ class CloudStorageView(View):
                     S3Email().faEmail(sys_msg_text, username)
                 elif data_valid.mobile_validate(username):
                     params = u'{"devname":"' + uid + '","submittime":"' + time.strftime("%Y-%m-%d",time.localtime()) + '"}'
-                    self.sendMessage(username, params, 'SMS_217407207')
+                    self.sendMessage(username, params, sms)
 
                 self.pushApp(nowTime, uid, channel, sys_msg_text)