index.js 381 B

1234567891011121314151617181920
  1. const {
  2. db,
  3. _
  4. } = require("../../utils/http");
  5. async function LiveService(data) {
  6. const orilist = await db.collection('live').where({
  7. live_type: _.eq('live'),
  8. }).get();
  9. return orilist.data[0] || {}
  10. }
  11. async function LiveServiceList() {
  12. const orilist = await db.collection('live').get();
  13. return orilist.data
  14. }
  15. module.exports = {
  16. LiveService,
  17. LiveServiceList
  18. }