qrpa 1.0.18__tar.gz → 1.0.20__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 qrpa might be problematic. Click here for more details.
- {qrpa-1.0.18 → qrpa-1.0.20}/PKG-INFO +1 -1
- {qrpa-1.0.18 → qrpa-1.0.20}/pyproject.toml +1 -1
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/shein_excel.py +10 -5
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/shein_lib.py +1442 -1405
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa.egg-info/PKG-INFO +1 -1
- {qrpa-1.0.18 → qrpa-1.0.20}/README.md +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/RateLimitedSender.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/__init__.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/db_migrator.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/fun_base.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/fun_excel.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/fun_file.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/fun_web.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/fun_win.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/shein_sqlite.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/shein_ziniao.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/time_utils.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/time_utils_example.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa/wxwork.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa.egg-info/SOURCES.txt +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa.egg-info/dependency_links.txt +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/qrpa.egg-info/top_level.txt +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/setup.cfg +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/setup.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/tests/test_db_migrator.py +0 -0
- {qrpa-1.0.18 → qrpa-1.0.20}/tests/test_wxwork.py +0 -0
|
@@ -2,6 +2,7 @@ from .fun_excel import *
|
|
|
2
2
|
from .fun_base import log
|
|
3
3
|
from .fun_file import read_dict_from_file, read_dict_from_file_ex, write_dict_to_file, write_dict_to_file_ex
|
|
4
4
|
from .time_utils import TimeUtils
|
|
5
|
+
from .wxwork import WxWorkBot
|
|
5
6
|
|
|
6
7
|
class SheinExcel:
|
|
7
8
|
|
|
@@ -30,6 +31,8 @@ class SheinExcel:
|
|
|
30
31
|
InsertImageV2(app, wb, sheet, ['SKC图片', 'SKU图片'])
|
|
31
32
|
wb.save()
|
|
32
33
|
close_excel(app, wb)
|
|
34
|
+
if mode == 4:
|
|
35
|
+
WxWorkBot('b30aaa8d-1a1f-4378-841a-8b0f8295f2d9').send_file(excel_path)
|
|
33
36
|
|
|
34
37
|
def write_bak_advice(self, mode_list):
|
|
35
38
|
excel_path_list = [
|
|
@@ -159,6 +162,7 @@ class SheinExcel:
|
|
|
159
162
|
InsertImageV2(app, wb, sheet, ['SKC图片', 'SKU图片'])
|
|
160
163
|
wb.save()
|
|
161
164
|
close_excel(app, wb)
|
|
165
|
+
WxWorkBot('b30aaa8d-1a1f-4378-841a-8b0f8295f2d9').send_file(excel_path)
|
|
162
166
|
|
|
163
167
|
def write_week_report(self):
|
|
164
168
|
excel_path = create_file_path(self.config.excel_week_sales_report)
|
|
@@ -170,9 +174,9 @@ class SheinExcel:
|
|
|
170
174
|
summary_excel_data = []
|
|
171
175
|
header = []
|
|
172
176
|
for store_name, excel_data in dict.items():
|
|
173
|
-
sheet_name = store_name
|
|
174
|
-
write_data(excel_path, sheet_name, excel_data)
|
|
175
|
-
self.format_week_report(excel_path, sheet_name)
|
|
177
|
+
# sheet_name = store_name
|
|
178
|
+
# write_data(excel_path, sheet_name, excel_data)
|
|
179
|
+
# self.format_week_report(excel_path, sheet_name)
|
|
176
180
|
header = excel_data[0]
|
|
177
181
|
summary_excel_data += excel_data[1:]
|
|
178
182
|
summary_excel_data = [header] + summary_excel_data
|
|
@@ -188,10 +192,11 @@ class SheinExcel:
|
|
|
188
192
|
format_to_percent(sheet, ['支付率', '点击率', '毛利率'])
|
|
189
193
|
self.dealFormula(sheet) # 有空再封装优化
|
|
190
194
|
colorize_by_field(app, wb, sheet, 'SPU')
|
|
191
|
-
autofit_column(sheet, ['店铺名称'])
|
|
195
|
+
autofit_column(sheet, ['商品信息', '店铺名称', 'SKC点击率/SKC转化率', '自主参与活动'])
|
|
196
|
+
column_to_left(sheet, ['店铺名称', 'SKC点击率/SKC转化率', '自主参与活动'])
|
|
192
197
|
specify_column_width(sheet, ['商品标题'], 150 / 6)
|
|
193
198
|
add_borders(sheet)
|
|
194
|
-
InsertImageV2(app, wb, sheet, ['SKC图片', 'SKU图片'], 'shein',
|
|
199
|
+
InsertImageV2(app, wb, sheet, ['SKC图片', 'SKU图片'], 'shein', 120, None, None, True)
|
|
195
200
|
wb.save()
|
|
196
201
|
close_excel(app, wb)
|
|
197
202
|
|