当前位置:首页>python>中篇Python(ODOO)篇 第四章 ODOO项目优化(五)教练预约单

中篇Python(ODOO)篇 第四章 ODOO项目优化(五)教练预约单

  • 2026-06-30 07:41:46
中篇Python(ODOO)篇 第四章 ODOO项目优化(五)教练预约单

预约单子模块数据来自预约单,指定教练和预约日,列出该教练当日所有预约信息。关键字是教练编号+年月日,这个子模块,采用按钮生成方式,在窗口放两个按钮。

一个是基于教练生成,即选择教练和日期后,点击按钮,则自动生成该教练和该日所有预约单数据。

一个是基于日期生成,即选择日期后,点击按钮,则自动生成所有教练该日所有预约单数据。

预约情况

学员姓名:

王小二

手机:

1862323

日期:

2020/8/1

预约时间:

7:00:00

9:59:59

排档类:

手动挡

金额:

220

自备车:

上车地点:

上海浦东大道1111号

下车地点:

上海浦东大道22号

教练员

工号:

001

姓名:

顾总

车辆信息

车牌:

A7868

类型:

桑塔纳3000型

实际情况

学员姓名:

王小二

手机:

1862323

日期:

2020/8/1

陪驾时间:

7:00:00

9:59:59

排档类:

手动挡

金额:

220

自备车:

上车地点:

上海浦东大道1111号

下车地点:

上海浦东大道22号

教练员

工号:

001

姓名:

顾总

车辆信息

车牌:

99900A

类型:

桑塔纳3000型

新增数据模型

models目录下新增teacher_appointment.py数据模型文件,代码如下:

from datetime import datetime, timedeltafrom odoo import fields, models, apiclass NebulaTeacherAppointment(models.Model):    _name = "nebula.teacher.appointment"    _description = "教练预约单"    _order = 'name'    active = fields.Boolean('是否有效', default=True)    name = fields.Char('教练预约简情', size=30)    appointment_date = fields.Date('预约日期', default=datetime.now())    teacher_name = fields.Many2one('nebula.teacher', string='教练工号',                                   size=8, required=True,                                   domain=[('active''=', True)])    teacher_full_name = fields.Char('教练姓名', related='teacher_name.full_name',                                    store=True)    teacher_mobile = fields.Char('教练手机', related='teacher_name.mobile')    date_docket = fields.Datetime('单据日期', required=True, readonly=True,                                  index=True, default=fields.Datetime.now)    user_id = fields.Many2one('res.users', string='创建人', index=True,                              readonly=True, default=lambda self: self.env.user)    order_line = fields.One2many('nebula.teacher.appointment.line''order_id',                                 string='预约明细', auto_join=True)    _sql_constraints = [('check_uniq_name''unique(appointment_date, name)''一个教练一个日期预约单')]class TeacherAppointmentLine(models.Model):    _name = 'nebula.teacher.appointment.line'    _description = '预约明细'    @api.model    def _select_car_type(self):        records = self.env['nebula.car.type'].search([('active''=', True)])        return [(r.name, r.name_type) for r in records]    def _select_auto_type(self):        records = self.env['nebula.auto.type'].search([])        return [(r.name, r.name_type) for r in records]    @api.depends('complete_begin_date''complete_hours')    def _calc_complete_end_date(self):        for order in self:            if order.complete_begin_date:                begin_date = order.complete_begin_date                add_hours = order.complete_hours                begin_date += timedelta(hours=add_hours)                begin_date -= timedelta(seconds=1)                order.complete_end_date = begin_date    order_id = fields.Many2one('nebula.teacher.appointment', string='预约明细行',                               required=True,                               ondelete='cascade', index=True, copy=False)    appointment_name = fields.Many2one('nebula.appointment', string='预约单',                                       index=True, size=8)    auto_type_name = fields.Selection(selection='_select_auto_type',                                      string='预约类型', related='appointment_name.auto_type_name')    student_name = fields.Many2one('nebula.student', string='学员姓名',                                   index=True, size=8, related='appointment_name.student_name')student_mobile = fields.Char('学员手机', related='student_name.mobile')appointment_begin_date = fields.Datetime('预约起始时间', related='appointment_name.appointment_begin_date')    appointment_hours = fields.Integer('预约小时数', related='appointment_name.appointment_hours')    appointment_end_date = fields.Datetime('预约结束时间', related='appointment_name.appointment_end_date')    complete_begin_date = fields.Datetime('实际起始时间')    complete_hours = fields.Integer('实际小时数')    complete_end_date = fields.Datetime('实际结束时间', compute='_calc_complete_end_date',                                        store=True)    car_name = fields.Many2one('nebula.car', string='车辆编号',                               size=8, related='appointment_name.car_name',                               domain=[('active''=', True)])    license_plate = fields.Char('车辆牌照', related='car_name.license_plate')    car_type_name = fields.Selection(selection='_select_car_type', string='车型',                                     related='car_name.car_type_name')    car_auto_type_name = fields.Selection(selection='_select_auto_type',                                          string='排挡类',                                          related='car_name.auto_type_name')    work_charge_hour = fields.Integer('每小时收费', related='appointment_name.work_charge_hour')    deposit = fields.Integer('学员缴费')    begin_address = fields.Text('上车地点', related='appointment_name.begin_address')    end_address = fields.Text('下车地点', related='appointment_name.end_address')note = fields.Text('备注', related='appointment_name.note')

teacher_appointment.py添加到 models目录下__init__.py文件中import部分,以逗号分割文件名。

设置访问权限

peijia->security目录下的ir.model.access.csv新增权限的记录。

access_nebula_teacher_appointment,nebula.teacher.appointment,model_nebula_teacher_appointment,group_peijia_manager,1,1,1,1access_nebula_teacher_appointment_line,nebula.teacher.appointment.line,model_nebula_teacher_appointment_line,group_peijia_manager,1,1,1,1

创建视图层

views目录新增teacher_appointment_views.xml文件,暂时以默认方式展示即可,内容如下:

<?xml version="1.0" encoding="utf-8"?><odoo>    <act_windowid="peijia.action_teacher_appointment_views"name="教练预约单"    res_model="nebula.teacher.appointment" view_mode="tree,form" /></odoo>

修改peijia目录下__manifest__.py文件中data段,在views/car_views.xml前新增views/teacher_appointment_views文件名。

views目录下car_views.xml文件,教练管理下添加菜单指向该子模块,代码:

<menuitem id="menu_teacher_appointment_views" name="教练预约单"          parent="menu_peijia_teacher_data" sequence="105"          action="peijia.action_teacher_appointment_views"/>

全部修改完成后,重启odoo服务。

name自动赋值

name设计为教练编号+日期,当教练编号和日期变化后,name自动变化。

我们在数据模型NebulaTeacherAppointment添加以下代码。

@api.onchange('teacher_name''appointment_date')def _onchange_name_date(self):    if self.appointment_date and self.teacher_name:        self.name = _make_name(self.appointment_date, self.teacher_name.name, self.teacher_name.full_name)

公用函数:

def _make_name(appointment_date, teacher_name, teacher_full_name):    # 传入参数,生成默认name    order_date = appointment_date + timedelta(hours=8)    order_text = datetime.strftime(order_date, "%Y-%m-%d")    record_name = '(' + teacher_name + ')'    record_name += teacher_full_name + '^'    record_name += order_text    return record_name

效果见下图,当教练工号和预约日期变化时自动更新教练预约简情字段。

完善视图

teacher_appointment_views.xml文件中act_window段删除,参考费用管理子模块修改,请读者自行完成,如果完成不了,最好从头再学!

另外为子表在views目录下新建视图文件teacher_appointment_lines_views.xml,并将该文件名添加到__manifest__.pydata段里面。该代码也请参考费用管理子模块修改。

子模块完整代码会在本节未贴出。

另外,演示了如何在视图中屏蔽教练、学员、陪驾单号的新建、修改等功能。关键点是添加options参数,如下例:

<fieldname="teacher_name"options="{'no_open': True, 'no_create': True}"/>

生成预约单按钮事件

我们在teacher_appointment_views.xml视图文件中添加按钮。

<form string="表单">    <header>        <button name="button_teacher_time" type="object"                string="指定教练本日预约" class="oe_highlight"/>        <button name="button_all_time" type="object"                string="所有教练本日预约" class="oe_highlight"/>    </header> 

teacher_appointment.py数据模型文件中NebulaTeacherAppointment类最末段添加按钮事件。

def button_teacher_time(self):    """        功能: 生成指定教练本日预约。              从传入的self中得到指定的教练和日期,删除旧子表,再创建新子表        1.调插入子表程序    """    # todo : 应该有时间判断,大于等于今天才能操作,未写    _insert_line_table(selfself.idself.appointment_date, self.teacher_name.id)def button_all_time(self):  # 所有教练本日预约    # todo : 应该有时间判断,大于等于今天才能操作,未写    """        功能: 生成所有教练本日预约。              从传入的self中得到指定的教练和日期,生成所有教练本日预约单。        1. 删除除了传入的教练外所有本日主表,子表会自动删除删除。        2.查找本日预约表中所有教练,循环生成除了本教练外主表,        3.查找教练预约表本日所有记录,遍历生成子表    """    # 1. 删除除了传入的教练外所有本日主表,子表会自动删除删除。    appointment_date = self.appointment_date    domain = [('teacher_name''!='self.teacher_name.id),  # 教练排除              ('active''='True),              ('appointment_date''=', appointment_date)]    self.env['nebula.teacher.appointment'].search(domain).unlink()    # 2. 查找本日预约表中所有教练,生成主表    begin_time = datetime.strftime(appointment_date, "%Y-%m-%d 00:00:00")    end_time = datetime.strftime(appointment_date, "%Y-%m-%d 23:59:59")    domain = [('active''='True),              ('appointment_begin_date''>=', begin_time),              ('appointment_begin_date''<=', end_time),              ('teacher_name''!='self.teacher_name.id),              ('complete_begin_date''='None)]    field_names = ['teacher_name''teacher_full_name']    records = self.env['nebula.appointment'].search_read(domain, field_names, order='teacher_name desc')    old_name = ''    for record in records:        record_name = _make_name(self.appointment_date, record['teacher_name'][1], record['teacher_full_name'])        if old_name != record_name:  # 不是重名            old_name = record_name            new_record = {                'teacher_name': record['teacher_name'][0],                'appointment_date'self.appointment_date,                'name': record_name,            }            self.env['nebula.teacher.appointment'].create(new_record)    # 3.查找教练预约表本日所有记录,遍历生成子表    domain = [('active''='True),              ('appointment_date''=', appointment_date)]    field_names = ['teacher_name']    records = self.env['nebula.teacher.appointment'].search_read(domain, field_names)    for record in records:        order_id = record['id']        teacher_id = record['teacher_name'][0]        _insert_line_table(self, order_id, appointment_date, teacher_id)

公用函数:

def _insert_line_table(self, order_id, appointment_date, teacher_id):    """        功能:传入主表,然后生成子表        1.传入主表        2.删除主表对应的子表        3.查询预约表本教练所有预约情况        4. 逐条插入到子表    """    domain = [('order_id''=', order_id)]    self.env['nebula.teacher.appointment.line'].search(domain).unlink()    begin_time = datetime.strftime(appointment_date, "%Y-%m-%d 00:00:00")    end_time = datetime.strftime(appointment_date, "%Y-%m-%d 23:59:59")    domain = [('active''='True),              ('appointment_begin_date''>=', begin_time),              ('appointment_begin_date''<=', end_time),              ('teacher_name''=', teacher_id),              ('complete_begin_date''='None)]    field_names = ['name']    items = self.env['nebula.appointment'].search_read(domain, field_names)    for item in items:        new_record = {            'order_id': order_id, # 主表ID            'appointment_name': item['id'],  # 子表预约单ID        }        self.env['nebula.teacher.appointment.line'].create(new_record)

界面展示

列表效果:

表单效果:

最新文章

随机文章

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