• Publicity: Public Only All

lang-audit-procs.tcl

Auditing of lang_messages

Location:
packages/acs-lang/tcl/lang-audit-procs.tcl
Created:
3 December 2002
Author:
Peter Marklund <peter@collaboraid.biz>
CVS Identification:
$Id: lang-audit-procs.tcl,v 1.6 2017/08/07 23:47:56 gustafn Exp $

Procedures in this file

Detailed information

lang::audit::changed_message (public)

 lang::audit::changed_message old_message package_key message_key \
    locale comment deleted_p sync_time conflict_p upgrade_status

Save a message that is overwritten.

Parameters:
old_message (required)
package_key (required)
message_key (required)
locale (required)
comment (required)
deleted_p (required)
sync_time (required)
conflict_p (required)
upgrade_status (required)
Author:
Peter Marklund

Partial Call Graph (max 5 caller/called nodes):
%3 test_test_catalog_import_export test_catalog_import_export (test acs-lang) lang::audit::changed_message lang::audit::changed_message test_test_catalog_import_export->lang::audit::changed_message ad_conn ad_conn (public) lang::audit::changed_message->ad_conn db_dml db_dml (public) lang::audit::changed_message->db_dml lang::message::edit lang::message::edit (private) lang::message::edit->lang::audit::changed_message lang::message::register lang::message::register (public) lang::message::register->lang::audit::changed_message

Testcases:
test_catalog_import_export
[ hide source ] | [ make this the default ]

Content File Source

#/packages/acs-lang/tcl/lang-message-procs.tcl
ad_library {

    Auditing of lang_messages

    @creation-date 3 December 2002
    @author Peter Marklund (peter@collaboraid.biz)
    @cvs-id $Id: lang-audit-procs.tcl,v 1.6 2017/08/07 23:47:56 gustafn Exp $
}

namespace eval lang::audit {

    d_proc -public changed_message { 
        old_message
        package_key
        message_key
        locale
        comment
        deleted_p
        sync_time
        conflict_p
        upgrade_status
    } {
      Save a message that is overwritten.
      @author Peter Marklund
    } {
        # Save the old message in the audit table
        set overwrite_user [ad_conn user_id]

        db_dml lang_message_audit {} -clobs [list $old_message $comment]
    }    
}

# Local variables:
#    mode: tcl
#    tcl-indent-level: 4
#    indent-tabs-mode: nil
# End: