支持多个项目

This commit is contained in:
fengbohan 2024-01-29 10:19:56 +08:00
parent 951a0fa586
commit d18d600334
3 changed files with 8 additions and 8 deletions

View File

@ -1,4 +1,4 @@
@REM @echo off @REM @echo off
call .\week_report\Scripts\activate call .\env\Scripts\activate
python gen_word.py python gen_word.py
pause pause

View File

@ -1,4 +1,4 @@
user_name: 冯博涵 user_name: 冯博涵
project_name: nb2337 project_name: [nb2337,nb2353]
project_leader: 罗伟 project_leader: [罗伟,何进]
template_file_name: 2017WWXX周工作报告样本.doc template_file_name: 2017WWXX周工作报告样本.doc

View File

@ -79,10 +79,10 @@ class WEEK_REPORT:
table.Cell(Row=1, Column=4).Range.Text = self.str table.Cell(Row=1, Column=4).Range.Text = self.str
# 所在项目 # 所在项目
table.Cell(Row=2, Column=2).Range.Text = self.project_name table.Cell(Row=2, Column=2).Range.Text = "".join(self.project_name)
# 项目负责人 # 项目负责人
table.Cell(Row=2, Column=4).Range.Text = self.project_leader table.Cell(Row=2, Column=4).Range.Text = "".join(self.project_leader)
# 报告人 # 报告人
table.Cell(Row=3, Column=2).Range.Text = self.user_name table.Cell(Row=3, Column=2).Range.Text = self.user_name
@ -94,10 +94,10 @@ class WEEK_REPORT:
table.Cell(Row=i, Column=3).Range.Text = '' table.Cell(Row=i, Column=3).Range.Text = ''
# 额外工作记录 # 额外工作记录
table.Cell(Row=13, Column=1).Range.Text = '1周一' table.Cell(Row=13, Column=1).Range.Text = ''
# 工作完成情况 # 工作完成情况
table.Cell(Row=15, Column=1).Range.Text = "项目工作:\n{}\n1\n其他(非项目工作)\n\n".format(self.project_name) table.Cell(Row=15, Column=1).Range.Text = "\n".join(["{}%".format(i) for i in self.project_name])
# 困难问题、经验教训及建议 # 困难问题、经验教训及建议
table.Cell(Row=17, Column=1).Range.Text = '' table.Cell(Row=17, Column=1).Range.Text = ''