argon/model.js
function destroy(callback) {
            var model = this;
            var request = {
                action : 'remove',
                model : model.constructor,
                data : this
            };
            this.dispatch('beforeDestroy');

            this.constructor.storage.remove(request, function destroyCallback() {
                model.setProperty('id', null);
                model.dispatch('afterDestroy');
                if (callback) {
                    callback(model);
                }
            });
        }
function destroy(callback) {
            var model = this;
            var request = {
                action : 'remove',
                model : model.constructor,
                data : this
            };
            this.dispatch('beforeDestroy');

            this.constructor.storage.remove(request, function destroyCallback() {
                model.setProperty('id', null);
                model.dispatch('afterDestroy');
                if (callback) {
                    callback(model);
                }
            });
        }
function destroy ( callback ) { var model = this ; var request = { action : 'remove' , model : model . constructor , data : this } ; this . dispatch ( 'beforeDestroy' ) ; this . constructor . storage . remove ( request , function destroyCallback ( ) { model . setProperty ( 'id' , null ) ; model . dispatch ( 'afterDestroy' ) ; if ( callback ) { callback ( model ) ; } } ) ; }
Removes a record from storage.
@method destroy <public>
@argument callback [Function] function to manage response.
@return Noting.
Removes a record from storage .