PageSourceSearch

https://clubyacht.net/recordm/localresource/js/cob/_audit.js

js clubyacht.net collected 2026-10-02 19:20:37 UTC 1,473 bytes, 24 lines download raw bytes

1//----------------- $audit  ------------------------
2cob.custom.customize.push(function (core, utils, ui) {
3    core.customizeAllInstances((instance, presenter) => 
4    {
5        let userFPs = presenter.findFieldPs( fp => /[$]audit\.(creator|updater)\.(username|uri|time)/.exec(fp.field.fieldDefinition.description) )
6        userFPs.forEach( fp => {
7            fp.disable()
8            if( presenter.isGroupEdit() ) return; // Don't do nothing in group edit
9            if(/[$]audit\.updater\./.exec(fp.field.fieldDefinition.description) && !instance.isNew()) return //Don't do nothing if $audit.updater.* and it's an update interface (updates will only be changed by the backend)
10            if(fp.isVisible() && /[$]audit\.creator\./.exec(fp.field.fieldDefinition.description) && !instance.isNew()) return //Se campo visível e é um creator não faz nada 
11            
12            if(/[$]audit\.(creator|updater)\.username/.exec(fp.field.fieldDefinition.description)) {
13                fp.setValue(core.getCurrentLoggedInUser())
14            }
15            if(/[$]audit\.(creator|updater)\.uri/.exec(fp.field.fieldDefinition.description)) {
16                fp.setValue(core.getCurrentLoggedInUserUri())
17            }
18            if(/[$]audit\.(creator|updater)\.time/.exec(fp.field.fieldDefinition.description)) {               
19                fp.setValue(Date.now())
20                setInterval(() =>  fp.setValue(Date.now()),15000)
21            }
22        })
23    })
24});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.