乐于分享
好东西不私藏

Excel处理——OpenPyXL图表生成

Excel处理——OpenPyXL图表生成

一、图表概述

OpenPyXL支持在Excel文件中创建多种类型的图表,包括柱状图、折线图、饼图、散点图等。

from openpyxl import Workbookfrom openpyxl.chart import BarChart, Referencewb = Workbook()ws = wb.active# 添加数据data = [    ['月份''销售额'],    ['1月'100],    ['2月'120],    ['3月'140],    ['4月'160],]for row in data:    ws.append(row)# 创建柱状图chart = BarChart()chart.title = '月度销售趋势'chart.x_axis.title = '月份'chart.y_axis.title = '销售额'# 数据范围data_ref = Reference(ws, min_col=2, min_row=1, max_row=5)categories = Reference(ws, min_col=1, min_row=2, max_row=5)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)ws.add_chart(chart, 'E2')wb.save('chart_basic.xlsx')

二、柱状图

2.1 基本柱状图

from openpyxl import Workbookfrom openpyxl.chart import BarChart, Referencefrom openpyxl.chart.series import Serieswb = Workbook()ws = wb.active# 准备数据data = [    ['产品''Q1''Q2''Q3''Q4'],    ['产品A'100120110130],    ['产品B'8090100110],    ['产品C'120110130140],]for row in data:    ws.append(row)# 创建柱状图chart = BarChart()chart.title = '季度销售对比'chart.x_axis.title = '产品'chart.y_axis.title = '销售额'chart.style = 13# 样式# 数据范围(从第2列开始)data_ref = Reference(ws, min_col=2, min_row=1, max_col=5, max_row=4)categories = Reference(ws, min_col=1, min_row=2, max_row=4)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)# 添加到工作表ws.add_chart(chart, 'F2')wb.save('bar_chart.xlsx')

2.2 堆叠柱状图

from openpyxl import Workbookfrom openpyxl.chart import BarChart, Referencewb = Workbook()ws = wb.active# 准备数据data = [    ['产品''线上''线下'],    ['产品A'6040],    ['产品B'7030],    ['产品C'5050],    ['产品D'8020],]for row in data:    ws.append(row)# 创建堆叠柱状图chart = BarChart()chart.title = '销售渠道分布'chart.x_axis.title = '产品'chart.y_axis.title = '占比 (%)'chart.type = 'col'# 柱状图chart.grouping = 'stacked'# 堆叠chart.overlap = 100# 数据范围data_ref = Reference(ws, min_col=2, min_row=1, max_col=3, max_row=5)categories = Reference(ws, min_col=1, min_row=2, max_row=5)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)ws.add_chart(chart, 'E2')wb.save('stacked_bar.xlsx')

2.3 百分比堆叠柱状图

from openpyxl import Workbookfrom openpyxl.chart import BarChart, Referencewb = Workbook()ws = wb.active# 准备数据(百分比)data = [    ['产品''渠道A''渠道B''渠道C'],    ['产品A'403525],    ['产品B'304030],    ['产品C'503020],]for row in data:    ws.append(row)# 创建百分比堆叠柱状图chart = BarChart()chart.title = '销售渠道占比'chart.x_axis.title = '产品'chart.y_axis.title = '占比 (%)'chart.type = 'col'chart.grouping = 'percentStacked'chart.overlap = 100data_ref = Reference(ws, min_col=2, min_row=1, max_col=4, max_row=4)categories = Reference(ws, min_col=1, min_row=2, max_row=4)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)ws.add_chart(chart, 'F2')wb.save('percent_stacked_bar.xlsx')

三、折线图

3.1 基本折线图

from openpyxl import Workbookfrom openpyxl.chart import LineChart, Referencewb = Workbook()ws = wb.active# 准备数据data = [    ['月份''产品A''产品B''产品C'],    ['1月'10080120],    ['2月'11090130],    ['3月'120100140],    ['4月'130110150],    ['5月'140120160],]for row in data:    ws.append(row)# 创建折线图chart = LineChart()chart.title = '月度销售趋势'chart.x_axis.title = '月份'chart.y_axis.title = '销售额'chart.style = 12# 数据范围data_ref = Reference(ws, min_col=2, min_row=1, max_col=4, max_row=6)categories = Reference(ws, min_col=1, min_row=2, max_row=6)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)# 添加数据标签for series in chart.series:    series.marker.symbol = 'circle'    series.marker.size = 5ws.add_chart(chart, 'H2')wb.save('line_chart.xlsx')

3.2 带数据标记的折线图

from openpyxl import Workbookfrom openpyxl.chart import LineChart, Referencefrom openpyxl.chart.marker import Markerwb = Workbook()ws = wb.activedata = [    ['月份''实际''预测'],    ['1月'10095],    ['2月'120115],    ['3月'140135],    ['4月'160155],    ['5月'180175],]for row in data:    ws.append(row)chart = LineChart()chart.title = '实际vs预测'chart.x_axis.title = '月份'chart.y_axis.title = '销售额'data_ref = Reference(ws, min_col=2, min_row=1, max_col=3, max_row=6)categories = Reference(ws, min_col=1, min_row=2, max_row=6)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)# 设置系列样式for idx, series inenumerate(chart.series):    series.marker.symbol = 'circle'if idx == 0else'diamond'    series.marker.size = 6    series.graphicalProperties.solidFill = 'FF0000'if idx == 0else'0000FF'    series.graphicalProperties.line.width = 20000# 2ptws.add_chart(chart, 'F2')wb.save('marked_line_chart.xlsx')

四、饼图

4.1 基本饼图

from openpyxl import Workbookfrom openpyxl.chart import PieChart, Referencewb = Workbook()ws = wb.active# 准备数据data = [    ['产品''销售额'],    ['产品A'100],    ['产品B'80],    ['产品C'60],    ['产品D'40],    ['产品E'20],]for row in data:    ws.append(row)# 创建饼图chart = PieChart()chart.title = '产品销售分布'# 数据范围data_ref = Reference(ws, min_col=2, min_row=1, max_row=6)labels = Reference(ws, min_col=1, min_row=2, max_row=6)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(labels)chart.dataLabels.showVal = True# 显示数值chart.dataLabels.showCatName = True# 显示类别名ws.add_chart(chart, 'D2')wb.save('pie_chart.xlsx')

4.2 圆环图

from openpyxl import Workbookfrom openpyxl.chart import PieChart, Referencefrom openpyxl.chart.piechart import PieChart3Dwb = Workbook()ws = wb.activedata = [    ['季度''销售额'],    ['Q1'100],    ['Q2'120],    ['Q3'110],    ['Q4'130],]for row in data:    ws.append(row)# 创建圆环图chart = PieChart()chart.title = '季度销售分布'chart.holeSize = 50# 圆环大小百分比data_ref = Reference(ws, min_col=2, min_row=1, max_row=5)labels = Reference(ws, min_col=1, min_row=2, max_row=5)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(labels)ws.add_chart(chart, 'E2')wb.save('donut_chart.xlsx')

五、散点图

5.1 基本散点图

from openpyxl import Workbookfrom openpyxl.chart import ScatterChart, Referencefrom openpyxl.chart.series import Serieswb = Workbook()ws = wb.active# 准备数据data = [    ['X''Y1''Y2'],    [123],    [245],    [367],    [489],    [51011],]for row in data:    ws.append(row)# 创建散点图chart = ScatterChart()chart.title = '散点图示例'chart.x_axis.title = 'X轴'chart.y_axis.title = 'Y轴'chart.style = 13# 添加系列1xvalues = Reference(ws, min_col=1, min_row=2, max_row=6)yvalues = Reference(ws, min_col=2, min_row=2, max_row=6)series1 = Series(yvalues, xvalues, title="系列1")chart.series.append(series1)# 添加系列2yvalues2 = Reference(ws, min_col=3, min_row=2, max_row=6)series2 = Series(yvalues2, xvalues, title="系列2")chart.series.append(series2)ws.add_chart(chart, 'E2')wb.save('scatter_chart.xlsx')

5.2 带趋势线的散点图

from openpyxl import Workbookfrom openpyxl.chart import ScatterChart, Referencefrom openpyxl.chart.series import Seriesfrom openpyxl.chart.trendline import Trendlinewb = Workbook()ws = wb.activedata = [    ['X''Y'],    [12],    [23.5],    [35],    [47],    [59],]for row in data:    ws.append(row)chart = ScatterChart()chart.title = '带趋势线的散点图'xvalues = Reference(ws, min_col=1, min_row=2, max_row=6)yvalues = Reference(ws, min_col=2, min_row=2, max_row=6)series = Series(yvalues, xvalues, title="数据点")series.marker.symbol = 'circle'series.marker.size = 6# 添加趋势线trendline = Trendline()trendline.name = '趋势线'series.trendline = trendlinechart.series.append(series)ws.add_chart(chart, 'E2')wb.save('trendline_scatter.xlsx')

请在微信客户端打开

六、图表样式自定义

6.1 颜色和样式

from openpyxl import Workbookfrom openpyxl.chart import BarChart, Referencefrom openpyxl.chart.colors import Colorfrom openpyxl.chart.graphical import ShapePropertieswb = Workbook()ws = wb.activedata = [    ['类别''值1''值2'],    ['A'1020],    ['B'1525],    ['C'2030],    ['D'2535],]for row in data:    ws.append(row)chart = BarChart()chart.title = '自定义样式'chart.x_axis.title = '类别'chart.y_axis.title = '值'chart.style = 10# 设置颜色colors = ['FF0000''00FF00''0000FF''FF9900']for idx, series inenumerate(chart.series):    series.graphicalProperties.solidFill = colors[idx % len(colors)]data_ref = Reference(ws, min_col=2, min_row=1, max_col=3, max_row=5)categories = Reference(ws, min_col=1, min_row=2, max_row=5)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)ws.add_chart(chart, 'F2')wb.save('styled_chart.xlsx')

6.2 图表尺寸和位置

from openpyxl import Workbookfrom openpyxl.chart import BarChart, Referencefrom openpyxl.utils.units import points_to_pixelswb = Workbook()ws = wb.activedata = [    ['月份''销售额'],    ['1月'100],    ['2月'120],    ['3月'140],]for row in data:    ws.append(row)chart = BarChart()chart.title = '调整尺寸'data_ref = Reference(ws, min_col=2, min_row=1, max_row=4)categories = Reference(ws, min_col=1, min_row=2, max_row=4)chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)# 设置尺寸(像素)chart.width = 15# 15cmchart.height = 10# 10cm# 设置位置chart.anchor = 'E2'ws.add_chart(chart)wb.save('sized_chart.xlsx')

七、实战案例

7.1 综合报表图表

from openpyxl import Workbookfrom openpyxl.chart import BarChart, LineChart, PieChart, Referencefrom openpyxl.chart.series import SeriesclassReportCharts:"""报表图表生成器"""def__init__(self, filename):self.wb = Workbook()self.ws = self.wb.activeself.filename = filenameself._prepare_data()def_prepare_data(self):"""准备数据"""self.data = {'headers': ['月份''销售额''成本''利润''增长率'],'rows': [                ['1月'1007030'5%'],                ['2月'1208040'8%'],                ['3月'1409050'10%'],                ['4月'16010060'12%'],                ['5月'18011070'15%'],                ['6月'20012080'18%'],            ]        }# 写入数据self.ws.append(self.data['headers'])for row inself.data['rows']:self.ws.append(row)defadd_bar_chart(self, position='G2'):"""添加柱状图"""        chart = BarChart()        chart.title = '月度销售趋势'        chart.x_axis.title = '月份'        chart.y_axis.title = '金额'        chart.style = 10        data_ref = Reference(self.ws, min_col=2, min_row=1, max_col=4, max_row=7)        categories = Reference(self.ws, min_col=1, min_row=2, max_row=7)        chart.add_data(data_ref, titles_from_data=True)        chart.set_categories(categories)self.ws.add_chart(chart, position)defadd_line_chart(self, position='G18'):"""添加折线图"""        chart = LineChart()        chart.title = '利润增长趋势'        chart.x_axis.title = '月份'        chart.y_axis.title = '利润'        chart.style = 12        data_ref = Reference(self.ws, min_col=4, min_row=1, max_col=4, max_row=7)        categories = Reference(self.ws, min_col=1, min_row=2, max_row=7)        chart.add_data(data_ref, titles_from_data=True)        chart.set_categories(categories)# 设置标记for series in chart.series:            series.marker.symbol = 'circle'            series.marker.size = 6self.ws.add_chart(chart, position)defadd_pie_chart(self, position='A15'):"""添加饼图"""        chart = PieChart()        chart.title = '成本构成'        data_ref = Reference(self.ws, min_col=4, min_row=1, max_row=7)        labels = Reference(self.ws, min_col=1, min_row=2, max_row=7)        chart.add_data(data_ref, titles_from_data=True)        chart.set_categories(labels)self.ws.add_chart(chart, position)defsave(self):"""保存文件"""self.wb.save(self.filename)# 使用report = ReportCharts('report_charts.xlsx')report.add_bar_chart()report.add_line_chart()report.add_pie_chart()report.save()

7.2 销售仪表板

from openpyxl import Workbookfrom openpyxl.chart import BarChart, LineChart, PieChart, Referencefrom openpyxl.styles import Font, PatternFill, AlignmentclassSalesDashboard:"""销售仪表板"""def__init__(self):self.wb = Workbook()self.ws = self.wb.activeself.ws.title = '销售仪表板'self._setup_style()def_setup_style(self):"""设置样式"""# 标题样式self.title_style = Font(bold=True, size=16, color='FFFFFF')self.title_fill = PatternFill(start_color='1E90FF', fill_type='solid')# 表头样式self.header_style = Font(bold=True, size=11, color='FFFFFF')self.header_fill = PatternFill(start_color='4472C4', fill_type='solid')self.header_align = Alignment(horizontal='center', vertical='center')defcreate_dashboard(self):"""创建仪表板"""# 标题self.ws.merge_cells('A1:H1')        cell = self.ws['A1']        cell.value = '2024年度销售仪表板'        cell.font = self.title_style        cell.fill = self.title_fill        cell.alignment = Alignment(horizontal='center', vertical='center')self.ws.row_dimensions[1].height = 30# 数据区域        data = [            ['月份''销售额''订单数''客单价''增长率'],            ['1月'100502000'5%'],            ['2月'120552182'8%'],            ['3月'140602333'10%'],            ['4月'160652462'12%'],            ['5月'180702571'15%'],            ['6月'200752667'18%'],        ]# 写入表头for col, header inenumerate(data[0], start=1):            cell = self.ws.cell(row=3, column=col)            cell.value = header            cell.font = self.header_style            cell.fill = self.header_fill            cell.alignment = self.header_align# 写入数据for row_idx, row_data inenumerate(data[1:], start=4):for col_idx, value inenumerate(row_data, start=1):self.ws.cell(row=row_idx, column=col_idx, value=value)# 调整列宽for col inrange(16):self.ws.column_dimensions[chr(64+col)].width = 15# 添加图表self._add_charts()def_add_charts(self):"""添加图表"""# 柱状图        chart1 = BarChart()        chart1.title = '月度销售趋势'        chart1.x_axis.title = '月份'        chart1.y_axis.title = '销售额'        data_ref = Reference(self.ws, min_col=2, min_row=3, max_col=2, max_row=9)        categories = Reference(self.ws, min_col=1, min_row=4, max_row=9)        chart1.add_data(data_ref, titles_from_data=True)        chart1.set_categories(categories)self.ws.add_chart(chart1, 'G3')# 折线图        chart2 = LineChart()        chart2.title = '订单量趋势'        chart2.x_axis.title = '月份'        chart2.y_axis.title = '订单数'        data_ref = Reference(self.ws, min_col=3, min_row=3, max_col=3, max_row=9)        categories = Reference(self.ws, min_col=1, min_row=4, max_row=9)        chart2.add_data(data_ref, titles_from_data=True)        chart2.set_categories(categories)self.ws.add_chart(chart2, 'G18')# 饼图        chart3 = PieChart()        chart3.title = '客单价分布'        data_ref = Reference(self.ws, min_col=4, min_row=3, max_row=9)        labels = Reference(self.ws, min_col=1, min_row=4, max_row=9)        chart3.add_data(data_ref, titles_from_data=True)        chart3.set_categories(labels)self.ws.add_chart(chart3, 'A12')defsave(self, filename):"""保存文件"""self.wb.save(filename)# 使用dashboard = SalesDashboard()dashboard.create_dashboard()dashboard.save('sales_dashboard.xlsx')

八、总结

# 快速参考# 1. 柱状图chart = BarChart()chart.title = '标题'chart.x_axis.title = 'X轴'chart.y_axis.title = 'Y轴'chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)# 2. 折线图chart = LineChart()chart.title = '标题'chart.add_data(data_ref, titles_from_data=True)chart.set_categories(categories)# 3. 饼图chart = PieChart()chart.title = '标题'chart.add_data(data_ref, titles_from_data=True)chart.set_categories(labels)# 4. 散点图chart = ScatterChart()chart.title = '标题'series = Series(yvalues, xvalues, title="系列名")chart.series.append(series)# 5. 图表样式chart.style = 10# 预设样式series.graphicalProperties.solidFill = 'FF0000'series.marker.symbol = 'circle'# 6. 添加图表ws.add_chart(chart, 'E2')

OpenPyXL提供了完整的图表生成功能,支持多种图表类型和样式定制。通过组合不同的图表类型,可以创建丰富的数据报表和仪表板。掌握图表生成技术可以让Excel报表更加直观和专业。

基本 文件 流程 错误 SQL 调试
  1. 请求信息 : 2026-07-03 13:28:50 HTTP/1.1 GET : https://www.yeyulingfeng.com/a/829719.html
  2. 运行时间 : 0.151962s [ 吞吐率:6.58req/s ] 内存消耗:4,818.72kb 文件加载:145
  3. 缓存信息 : 0 reads,0 writes
  4. 会话信息 : SESSION_ID=599f3d9eac7945c8413919025012ca9f
  1. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/public/index.php ( 0.79 KB )
  2. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/autoload.php ( 0.17 KB )
  3. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/composer/autoload_real.php ( 2.49 KB )
  4. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/composer/platform_check.php ( 0.90 KB )
  5. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/composer/ClassLoader.php ( 14.03 KB )
  6. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/composer/autoload_static.php ( 6.05 KB )
  7. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-helper/src/helper.php ( 8.34 KB )
  8. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-validate/src/helper.php ( 2.19 KB )
  9. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/ralouphie/getallheaders/src/getallheaders.php ( 1.60 KB )
  10. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/helper.php ( 1.47 KB )
  11. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/stubs/load_stubs.php ( 0.16 KB )
  12. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Exception.php ( 1.69 KB )
  13. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-container/src/Facade.php ( 2.71 KB )
  14. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/symfony/deprecation-contracts/function.php ( 0.99 KB )
  15. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/symfony/polyfill-mbstring/bootstrap.php ( 8.26 KB )
  16. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/symfony/polyfill-mbstring/bootstrap80.php ( 9.78 KB )
  17. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/symfony/var-dumper/Resources/functions/dump.php ( 1.49 KB )
  18. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-dumper/src/helper.php ( 0.18 KB )
  19. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/symfony/var-dumper/VarDumper.php ( 4.30 KB )
  20. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/guzzlehttp/guzzle/src/functions_include.php ( 0.16 KB )
  21. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/guzzlehttp/guzzle/src/functions.php ( 5.54 KB )
  22. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/App.php ( 15.30 KB )
  23. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-container/src/Container.php ( 15.76 KB )
  24. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/psr/container/src/ContainerInterface.php ( 1.02 KB )
  25. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/provider.php ( 0.19 KB )
  26. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Http.php ( 6.04 KB )
  27. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-helper/src/helper/Str.php ( 7.29 KB )
  28. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Env.php ( 4.68 KB )
  29. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/common.php ( 0.03 KB )
  30. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/helper.php ( 18.78 KB )
  31. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Config.php ( 5.54 KB )
  32. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/alipay.php ( 3.59 KB )
  33. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/facade/Env.php ( 1.67 KB )
  34. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/app.php ( 0.95 KB )
  35. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/cache.php ( 0.78 KB )
  36. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/console.php ( 0.23 KB )
  37. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/cookie.php ( 0.56 KB )
  38. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/database.php ( 2.48 KB )
  39. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/filesystem.php ( 0.61 KB )
  40. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/lang.php ( 0.91 KB )
  41. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/log.php ( 1.35 KB )
  42. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/middleware.php ( 0.19 KB )
  43. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/route.php ( 1.89 KB )
  44. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/session.php ( 0.57 KB )
  45. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/trace.php ( 0.34 KB )
  46. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/config/view.php ( 0.82 KB )
  47. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/event.php ( 0.25 KB )
  48. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Event.php ( 7.67 KB )
  49. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/service.php ( 0.13 KB )
  50. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/AppService.php ( 0.26 KB )
  51. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Service.php ( 1.64 KB )
  52. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Lang.php ( 7.35 KB )
  53. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/lang/zh-cn.php ( 13.70 KB )
  54. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/initializer/Error.php ( 3.31 KB )
  55. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/initializer/RegisterService.php ( 1.33 KB )
  56. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/services.php ( 0.14 KB )
  57. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/service/PaginatorService.php ( 1.52 KB )
  58. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/service/ValidateService.php ( 0.99 KB )
  59. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/service/ModelService.php ( 2.04 KB )
  60. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-trace/src/Service.php ( 0.77 KB )
  61. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Middleware.php ( 6.72 KB )
  62. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/initializer/BootService.php ( 0.77 KB )
  63. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/Paginator.php ( 11.86 KB )
  64. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-validate/src/Validate.php ( 63.20 KB )
  65. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/Model.php ( 23.55 KB )
  66. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/concern/Attribute.php ( 21.05 KB )
  67. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/concern/AutoWriteData.php ( 4.21 KB )
  68. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/concern/Conversion.php ( 6.44 KB )
  69. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/concern/DbConnect.php ( 5.16 KB )
  70. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/concern/ModelEvent.php ( 2.33 KB )
  71. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/concern/RelationShip.php ( 28.29 KB )
  72. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-helper/src/contract/Arrayable.php ( 0.09 KB )
  73. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-helper/src/contract/Jsonable.php ( 0.13 KB )
  74. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/model/contract/Modelable.php ( 0.09 KB )
  75. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Db.php ( 2.88 KB )
  76. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/DbManager.php ( 8.52 KB )
  77. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Log.php ( 6.28 KB )
  78. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Manager.php ( 3.92 KB )
  79. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/psr/log/src/LoggerTrait.php ( 2.69 KB )
  80. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/psr/log/src/LoggerInterface.php ( 2.71 KB )
  81. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Cache.php ( 4.92 KB )
  82. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/psr/simple-cache/src/CacheInterface.php ( 4.71 KB )
  83. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-helper/src/helper/Arr.php ( 16.63 KB )
  84. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/cache/driver/File.php ( 7.84 KB )
  85. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/cache/Driver.php ( 9.03 KB )
  86. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/contract/CacheHandlerInterface.php ( 1.99 KB )
  87. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/Request.php ( 0.09 KB )
  88. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Request.php ( 55.78 KB )
  89. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/middleware.php ( 0.25 KB )
  90. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Pipeline.php ( 2.61 KB )
  91. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-trace/src/TraceDebug.php ( 3.40 KB )
  92. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/middleware/SessionInit.php ( 1.94 KB )
  93. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Session.php ( 1.80 KB )
  94. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/session/driver/File.php ( 6.27 KB )
  95. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/contract/SessionHandlerInterface.php ( 0.87 KB )
  96. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/session/Store.php ( 7.12 KB )
  97. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Route.php ( 23.73 KB )
  98. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/RuleName.php ( 5.75 KB )
  99. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/Domain.php ( 2.53 KB )
  100. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/RuleGroup.php ( 22.43 KB )
  101. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/Rule.php ( 26.95 KB )
  102. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/RuleItem.php ( 9.78 KB )
  103. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/route/app.php ( 3.94 KB )
  104. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/facade/Route.php ( 4.70 KB )
  105. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/dispatch/Controller.php ( 4.74 KB )
  106. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/route/Dispatch.php ( 10.44 KB )
  107. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/controller/Index.php ( 9.87 KB )
  108. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/BaseController.php ( 2.05 KB )
  109. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/facade/Db.php ( 0.93 KB )
  110. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/connector/Mysql.php ( 5.44 KB )
  111. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/PDOConnection.php ( 52.47 KB )
  112. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/Connection.php ( 8.39 KB )
  113. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/ConnectionInterface.php ( 4.57 KB )
  114. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/builder/Mysql.php ( 16.58 KB )
  115. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/Builder.php ( 24.06 KB )
  116. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/BaseBuilder.php ( 27.50 KB )
  117. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/Query.php ( 15.71 KB )
  118. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/BaseQuery.php ( 45.13 KB )
  119. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/TimeFieldQuery.php ( 7.43 KB )
  120. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/AggregateQuery.php ( 3.26 KB )
  121. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/ModelRelationQuery.php ( 20.07 KB )
  122. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/ParamsBind.php ( 3.66 KB )
  123. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/ResultOperation.php ( 7.01 KB )
  124. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/WhereQuery.php ( 19.37 KB )
  125. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/JoinAndViewQuery.php ( 7.11 KB )
  126. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/TableFieldInfo.php ( 2.63 KB )
  127. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-orm/src/db/concern/Transaction.php ( 2.77 KB )
  128. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/log/driver/File.php ( 5.96 KB )
  129. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/contract/LogHandlerInterface.php ( 0.86 KB )
  130. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/log/Channel.php ( 3.89 KB )
  131. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/event/LogRecord.php ( 1.02 KB )
  132. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-helper/src/Collection.php ( 16.47 KB )
  133. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/facade/View.php ( 1.70 KB )
  134. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/View.php ( 4.39 KB )
  135. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/app/controller/Es.php ( 3.30 KB )
  136. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Response.php ( 8.81 KB )
  137. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/response/View.php ( 3.29 KB )
  138. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/Cookie.php ( 6.06 KB )
  139. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-view/src/Think.php ( 8.38 KB )
  140. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/framework/src/think/contract/TemplateHandlerInterface.php ( 1.60 KB )
  141. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-template/src/Template.php ( 46.61 KB )
  142. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-template/src/template/driver/File.php ( 2.41 KB )
  143. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-template/src/template/contract/DriverInterface.php ( 0.86 KB )
  144. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/runtime/temp/c935550e3e8a3a4c27dd94e439343fdf.php ( 31.50 KB )
  145. /yingpanguazai/ssd/ssd1/www/wwww.yeyulingfeng.com/vendor/topthink/think-trace/src/Html.php ( 4.42 KB )
  1. CONNECT:[ UseTime:0.000608s ] mysql:host=127.0.0.1;port=3306;dbname=wenku;charset=utf8mb4
  2. SHOW FULL COLUMNS FROM `fenlei` [ RunTime:0.000829s ]
  3. SELECT * FROM `fenlei` WHERE `fid` = 0 [ RunTime:0.000321s ]
  4. SELECT * FROM `fenlei` WHERE `fid` = 63 [ RunTime:0.000298s ]
  5. SHOW FULL COLUMNS FROM `set` [ RunTime:0.000504s ]
  6. SELECT * FROM `set` [ RunTime:0.000197s ]
  7. SHOW FULL COLUMNS FROM `article` [ RunTime:0.000598s ]
  8. SELECT * FROM `article` WHERE `id` = 829719 LIMIT 1 [ RunTime:0.000516s ]
  9. UPDATE `article` SET `lasttime` = 1783056530 WHERE `id` = 829719 [ RunTime:0.008475s ]
  10. SELECT * FROM `fenlei` WHERE `id` = 64 LIMIT 1 [ RunTime:0.000413s ]
  11. SELECT * FROM `article` WHERE `id` < 829719 ORDER BY `id` DESC LIMIT 1 [ RunTime:0.000726s ]
  12. SELECT * FROM `article` WHERE `id` > 829719 ORDER BY `id` ASC LIMIT 1 [ RunTime:0.000527s ]
  13. SELECT * FROM `article` WHERE `id` < 829719 ORDER BY `id` DESC LIMIT 10 [ RunTime:0.013614s ]
  14. SELECT * FROM `article` WHERE `id` < 829719 ORDER BY `id` DESC LIMIT 10,10 [ RunTime:0.043063s ]
  15. SELECT * FROM `article` WHERE `id` < 829719 ORDER BY `id` DESC LIMIT 20,10 [ RunTime:0.001338s ]
0.153612s