lib/plugins/inheritance.js
function () {
            var q = this._getPrimaryKeyQuery(), changed = this.__changed;
            var modelStatic = this._static,
                ctiColumns = modelStatic.__ctiColumns,
                tables = modelStatic.__ctiTables,
                self = this;
            return new PromiseList(tables.map(function (table) {
                var cols = ctiColumns[table], update = {};
                cols.forEach(function (c) {
                    if (!comb.isUndefined(changed[c])) {
                        update[c] = changed[c];
                    }
                });
                return comb.isEmpty(update) ? new Promise().callback() : self.db.from(table).filter(q).update(update);
            }), true)
                .chain(function () {
                    return self._updateReload();
                })
                .promise();
        }
function () {
            var q = this._getPrimaryKeyQuery(), changed = this.__changed;
            var modelStatic = this._static,
                ctiColumns = modelStatic.__ctiColumns,
                tables = modelStatic.__ctiTables,
                self = this;
            return new PromiseList(tables.map(function (table) {
                var cols = ctiColumns[table], update = {};
                cols.forEach(function (c) {
                    if (!comb.isUndefined(changed[c])) {
                        update[c] = changed[c];
                    }
                });
                return comb.isEmpty(update) ? new Promise().callback() : self.db.from(table).filter(q).update(update);
            }), true)
                .chain(function () {
                    return self._updateReload();
                })
                .promise();
        }
function ( ) { var q = this . _getPrimaryKeyQuery ( ) , changed = this . __changed ; var modelStatic = this . _static , ctiColumns = modelStatic . __ctiColumns , tables = modelStatic . __ctiTables , self = this ; return new PromiseList ( tables . map ( function ( table ) { var cols = ctiColumns [ table ] , update = { } ; cols . forEach ( function ( c ) { if ( ! comb . isUndefined ( changed [ c ] ) ) { update [ c ] = changed [ c ] ; } } ) ; return comb . isEmpty ( update ) ? new Promise ( ) . callback ( ) : self . db . from ( table ) . filter ( q ) . update ( update ) ; } ) , true ) . chain ( function ( ) { return self . _updateReload ( ) ; } ) . promise ( ) ; }
update each column according to the columns in each table
update each column according to the columns in each table