sc-common-interface 2.4.8__tar.gz → 2.4.9__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sc-common-interface
3
- Version: 2.4.8
3
+ Version: 2.4.9
4
4
  Summary: SC贴文销售公用的接口
5
5
  Home-page: UNKNOWN
6
6
  Author: river
@@ -805,7 +805,6 @@ def edit_live_info(data):
805
805
  keywordValidInLive = data["keywordValidInLive"]
806
806
  if "keywordValidAfterLive" in data:
807
807
  keywordValidAfterLive = data["keywordValidAfterLive"]
808
-
809
808
  if "autoNotifyPayEnable" in data:
810
809
  autoNotifyPayEnable = data["autoNotifyPayEnable"]
811
810
  if "autoNotifyPayMessage" in data:
@@ -814,19 +813,16 @@ def edit_live_info(data):
814
813
  autoNotifyPayButton = data["autoNotifyPayButton"]
815
814
  if "autoNotifyPayTime" in data:
816
815
  autoNotifyPayTime = data["autoNotifyPayTime"]
817
-
818
816
  if "stockEnable" in data:
819
817
  stockEnable = data["stockEnable"]
820
818
  if "stockExpireTime" in data:
821
819
  stockExpireTime = data["stockExpireTime"]
822
-
823
820
  if "lowOfQuantityEnable" in data:
824
821
  lowOfQuantityEnable = data["lowOfQuantityEnable"]
825
822
  if "lowOfQuantitySound" in data:
826
823
  lowOfQuantitySound = data["lowOfQuantitySound"]
827
824
  if "lowOfQuantityQuantity" in data:
828
825
  lowOfQuantityQuantity = data["lowOfQuantityQuantity"]
829
-
830
826
  if "has_interaction_message" in data:
831
827
  has_interaction_message = data["has_interaction_message"]
832
828
  if "has_interaction_message_button" in data:
@@ -847,22 +843,18 @@ def edit_live_info(data):
847
843
  has_link = data["has_link"]
848
844
  if "commentIntent" in data:
849
845
  commentIntent = data["commentIntent"]
850
-
851
846
  if "allOutOfStockMessage" in data:
852
847
  allOutOfStockMessage = data["allOutOfStockMessage"]
853
848
  if "allOutOfStockEnable" in data:
854
849
  allOutOfStockEnable = data["allOutOfStockEnable"]
855
-
856
850
  if "welcomeMessage" in data:
857
851
  welcomeMessage = data["welcomeMessage"]
858
852
  if "welcomeMessageEnable" in data:
859
853
  welcomeMessageEnable = data["welcomeMessageEnable"]
860
-
861
854
  if "welcomeComment" in data:
862
855
  welcomeComment = data["welcomeComment"]
863
856
  if "welcomeCommentEnable" in data:
864
857
  welcomeCommentEnable = data["welcomeCommentEnable"]
865
-
866
858
  if "productRecommendMessage" in data:
867
859
  productRecommendMessage = data["productRecommendMessage"]
868
860
  if "productRecommendMessageEnable" in data:
@@ -870,6 +862,7 @@ def edit_live_info(data):
870
862
  platformChannels = []
871
863
  startTime = None
872
864
  endTime = None
865
+ body = {}
873
866
  if type=="progress":
874
867
  #进行中不允许修改基础设置、关键子下单设置、保留库存、
875
868
  res = get_live_info(data)
@@ -893,8 +886,6 @@ def edit_live_info(data):
893
886
  "platform": platform
894
887
  }
895
888
  platformChannels.append(platformChannel)
896
-
897
- body = {}
898
889
  if platform.upper()=="FB_GROUP":
899
890
  body = {
900
891
  "sales": {
@@ -1130,8 +1121,8 @@ def edit_live_info(data):
1130
1121
  }
1131
1122
  }
1132
1123
  }
1133
- response = requests.put(url,headers=headers,json=body).json()
1134
- return response
1124
+ response = requests.put(url, headers=headers, json=body).json()
1125
+ return response
1135
1126
 
1136
1127
 
1137
1128
  def save_global_config(data):
@@ -1448,8 +1439,4 @@ def remove_live_product(data):
1448
1439
 
1449
1440
 
1450
1441
  if __name__=="__main__":
1451
- data = {'env': 'https://front-admin-preview.shoplineapp.com', 'headers': {'Content-Type': 'application/json', 'authorization': 'Bearer eyJhbGciOiJIUzI1NiJ9.eyJqdGkiOiIwNmUxNGU2NzAxMWY0ZDNhMGU0ZDgyNDk3ZDAxYmQwZSIsImRhdGEiOnsibWVyY2hhbnRfaWQiOiI2MWE4N2M5NzYzYjcwYzAwNTEwNmZiZDAiLCJhcHBsaWNhdGlvbl9pZCI6IjVmNTlmMTI4MzcyZWIzMDAwNmRjNDcwMSJ9LCJpc3MiOiJodHRwczovL2RldmVsb3BlcnMtcHJldmlldy5zaG9wbGluZWFwcC5jb20iLCJhdWQiOltdLCJzdWIiOiI2MWE4N2M5NzYzYjcwYzAwNTEwNmZiZDAifQ.gUqa8FJs_vjRJ-kFMhOZx42QtCr7XxcN3gKSK6_4Zvs', 'lang': 'en'}, 'platform': 'FACEBOOK', 'sales_id': 517320}
1452
- data['type'] = "progress"
1453
- res = edit_live_info(data)
1454
-
1455
- print(res)
1442
+ pass
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sc-common-interface
3
- Version: 2.4.8
3
+ Version: 2.4.9
4
4
  Summary: SC贴文销售公用的接口
5
5
  Home-page: UNKNOWN
6
6
  Author: river
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name='sc-common-interface',
5
- version='2.4.8',
5
+ version='2.4.9',
6
6
  description='SC贴文销售公用的接口',
7
7
  author='river',
8
8
  packages=find_packages(),