GithubHelp home page GithubHelp logo

marklehm / firegento-adminmonitoring Goto Github PK

View Code? Open in Web Editor NEW

This project forked from firegento/firegento-adminmonitoring

0.0 1.0 0.0 1.17 MB

Monitor all activities in the backend and provide a history about the changes.

License: GNU General Public License v3.0

CSS 4.91% PHP 95.09%

firegento-adminmonitoring's Introduction

FireGento_AdminMonitoring

The admin monitoring allows an shop owner to log almost every activity in the backend.

Facts

Builds

  • Branch: master Build Status
  • Branch: develop Build Status

Description

The admin monitoring allows an shop owner to log almost every activity in the backend. The goal is to monitor all changes in the backend and show them in a nice view so that a shop owner can monitor who changed what, e.g. logged in to the admin account, saved a product, deleted a customer, e.g.

BE CAREFUL

This extension writes a lot of data into the database and we exclude only a few core classes. If you have many writes in the backend, please have a look into this to avoid a full hard disk!

There are currently several ways if you can exclude e.g. specific models, admin routes, field names from logging data to the database:

  • Exclude all changes from a specific object (e.g. Mage_Index_Model_Event)
  • Exclude all changes from a specific admin route (e.g. admin_sales_order_create_loadBlock)
  • Exclude specific objects from specific admin routes (e.g. Mage_CatalogRule_Model_Flag from admin_promo_catalog_save)
  • Exclude specific field names from every object (e.g. created_at, updated_at)

There is a basic adminmonitoring.xml file located in the "etc" folder of this extension with the following default excludes:

<?xml version="1.0"?>
<config>
    <adminmonitoring>
        <excludes>
            <object_types>
                <Mage_Index_Model_Event/>
                <Mage_Admin_Model_User/>
                <Enterprise_Logging_Model_Event_Changes/>
                <Enterprise_Logging_Model_Event/>
                <!-- omit infinite loops -->
                <FireGento_AdminMonitoring_Model_History/>
            </object_types>
            <fields>
                <created_at/>
                <updated_at/>
                <create_time/>
                <update_time/>
                <low_stock_date/>
            </fields>
            <admin_routes>
                <admin_sales_order_create_index/>
                <admin_sales_order_create_loadBlock/>
                <admin_sales_order_create_save/>
                <admin_sales_order_invoice_save/>
                <admin_sales_order_shipment_save/>
                <admin_sales_order_creditmemo_save/>
                <admin_sales_order_create_reorder/>
                <admin_promo_catalog_save>
                    <Mage_CatalogRule_Model_Flag/>
                </admin_promo_catalog_save>
            </admin_routes>
        </excludes>
    </adminmonitoring>
</config>

Third party integration

Events for model_save_after and model_delete_after are observed and changes automatically logged, if not excluded as described above. So even third party models will be logged and can be even better integrated by link to their adminhtml edit form. To do this observe the event firegento_adminmonitoring_rowurl and see Firegento_AdminMonitoring_Model_RowUrl_Product for an catalog_product implementation which can be adapted for your custom models.

If you want to log your own events just dispatch the event firegento_adminmonitoring_log and pass your custom data:

Mage::dispatchEvent(
    'firegento_adminmonitoring_log',
    array(
        'object_id'    => $objectId,
        'object_type'  => $objectType,
        'content'      => $content, // as json
        'content_diff' => $contentDiff, // as json
        'action'       => $action, // see Firegento_AdminMonitoring_Helper_Data for possible ACTION constants
    )
);

If you want to exclude some more fields, admin routes, object types just create a custom adminmonitoring.xml file in your custom module and add the necessary values in the same structure like in the default adminmonitoring.xml file of this extension.

Requirements

  • PHP >= 5.3.0 (or even 5.0 as long as spl is activated)
  • PHP >= 5.5.0: json extension

Compatibility

  • Magento CE >= 1.6
  • Magento EE >= 1.12

Installation Instructions

  1. Install the extension by copying all the extension files into your document root.
  2. Clear the cache, logout from the admin panel and then login again.
  3. You can now configure the extenion via System -> Configuration -> Advanced -> Admin -> Admin Monitoring
  4. You can view all logging entries in System -> Configuration -> Admin Monitoring

Uninstallation

  1. Remove all extension files from your Magento installation
  2. Run the following sql script in your database:
DROP TABLE 'firegento_adminmonitoring_history';
  1. Please remove all integration for the admin monitoring in your custom modules.

Support

If you have any issues with this extension, open an issue on GitHub.

Contribution

Any contribution is highly appreciated. The best way to contribute code is to open a pull request on GitHub.

Developer

FireGento Team

Developers:

License

GNU General Public License, version 3 (GPLv3)

Copyright

(c) 2013-2014 FireGento Team

firegento-adminmonitoring's People

Contributors

therouv avatar schrank avatar mryvlin avatar neoshops avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.