Show:
Module: store
Parent Module: services

store

Methods

createRecord
(
  • type
  • init
)
Promise

create the record according to modelName

Parameters:

Returns:

deleteRecord
(
  • type
  • model
  • data
)
Promise

delete the record according to modelName

Parameters:

Returns:

emptyAttrs
(
  • type
  • model
  • filterKeys
  • unfilterKeys
)
Array

filter model empty attrs

Parameters:

  • type Object

    modelName

  • model Object

    object need to be filterd

  • filterKeys Object

    default is model keys

  • unfilterKeys Object

    not need to be filterd

Returns:

Array:

all keys attribute value is empty

find
(
  • type
  • params
)
Promise

find the record according to modelName

Parameters:

Returns:

findOne
(
  • type
  • _id
  • data
)
Promise

findOne the record according to modelName

Parameters:

Returns:

save
(
  • type
  • model
)
Promise

save the record according to modelName

Parameters:

Returns: