承接 jansuchanek/naudit 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

jansuchanek/naudit

最新稳定版本:v1.1.0

Composer 安装命令:

composer require jansuchanek/naudit

包简介

Doctrine entity audit log for Nette — automatic change tracking with user context

README 文档

README

Doctrine entity audit log for Nette Framework — automatically tracks changes to entities.

Features

  • 📝 Change Tracking — Records create/update/delete with field diffs
  • 🔌 AuditableInterface — Mark entities for tracking
  • 📊 JSON Storage — Changes stored as JSON in audit_log table
  • ⚙️ DI Extension — Auto-registers Doctrine event subscriber

Installation

composer require jansuchanek/naudit

Configuration

extensions:
    audit: NAudit\DI\NAuditExtension

Usage

Implement AuditableInterface on your entities:

use NAudit\AuditableInterface;

class Product implements AuditableInterface
{
    use AuditableTrait;

    public function getAuditLabel(): string
    {
        return $this->name;
    }
}

Migration

CREATE TABLE audit_log (
    id INT AUTO_INCREMENT PRIMARY KEY,
    entity_class VARCHAR(255) NOT NULL,
    entity_id INT NOT NULL,
    action VARCHAR(16) NOT NULL,
    changes JSON,
    user_id INT,
    created_at DATETIME NOT NULL,
    INDEX idx_entity (entity_class, entity_id)
);

Requirements

  • PHP >= 8.2
  • Doctrine ORM ^3.0
  • Nette DI ^3.2

License

MIT

统计信息

  • 总下载量: 2
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 4
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-03-20

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固