08 2021 档案

摘要:###使用openpyxl实现 只支持xlsx文件,不支持xls import openpyxl def read_cell(io, sheet, cell='A2'): """ 读取单元格 :param io: Excel文件路径 :param sheet: 读取哪一张表,str, int eg: 阅读全文
posted @ 2021-08-31 11:32 cnblogs用户 阅读(3422) 评论(0) 推荐(0) 编辑
摘要:import datetime def get_date_of_last_week(form='%Y-%m-%d'): """ 获取上周开始结束日期 :param form: 日期格式 :return: str,date tuple """ today = datetime.date.today() 阅读全文
posted @ 2021-08-19 21:00 cnblogs用户 阅读(577) 评论(0) 推荐(0) 编辑
摘要:注:chinese_calander库需要每年手动更新一次 import datetime import chinese_calendar def get_holidays(year=None, include_weekends=True): """ 获取某一年的所有节假日,默认当年 :param 阅读全文
posted @ 2021-08-19 20:53 cnblogs用户 阅读(2473) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示