schema-name-adapter.js 310 B

12345678910111213141516
  1. const db = uniCloud.database()
  2. module.exports = async function () {
  3. try {
  4. const count = await db.collection('batch-sms-template').count()
  5. if (count.total > 0) {
  6. this.tableNames = {
  7. template: 'batch-sms-template',
  8. task: 'batch-sms-task',
  9. log: 'batch-sms-result'
  10. }
  11. }
  12. } catch (e) {}
  13. }