lib/routes/index.js
function (req, res, options) {
    if (!options) {
      options = {};
    }
    options.operation = 'STATUS';
    options.res = res;
    exports.status.before(req, res, options);
    vulpejs.models.status({
      model: req.params.model,
      data: req.body,
      callback: {
        success: function (item) {
          exports.status.after(req, res, item);
          if (options && options.callback) {
            vulpejs.utils.execute(options.callback, item);
          } else {
            exports.response.success(options);
          }
        },
        error: function (error) {
          exports.response.error(options, error);
        },
      },
    });
  }
function (req, res, options) {
    if (!options) {
      options = {};
    }
    options.operation = 'STATUS';
    options.res = res;
    exports.status.before(req, res, options);
    vulpejs.models.status({
      model: req.params.model,
      data: req.body,
      callback: {
        success: function (item) {
          exports.status.after(req, res, item);
          if (options && options.callback) {
            vulpejs.utils.execute(options.callback, item);
          } else {
            exports.response.success(options);
          }
        },
        error: function (error) {
          exports.response.error(options, error);
        },
      },
    });
  }
function ( req , res , options ) { if ( ! options ) { options = { } ; } options . operation = 'STATUS' ; options . res = res ; exports . status . before ( req , res , options ) ; vulpejs . models . status ( { model : req . params . model , data : req . body , callback : { success : function ( item ) { exports . status . after ( req , res , item ) ; if ( options && options . callback ) { vulpejs . utils . execute ( options . callback , item ) ; } else { exports . response . success ( options ) ; } } , error : function ( error ) { exports . response . error ( options , error ) ; } , } , } ) ; }
Change status of object in database.
@param {Object} req     Request
@param {Object} res     Response
@param {Object} options {model, callback}
Change status of object in database .