Migrate to @orbito/api-lib 2.0.0 for single-company container model.
Remove companyId from handlers, models, cron jobs, and cross-module calls to match the v2 one-module-one-company architecture. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -3,8 +3,6 @@ const { customAlphabet } = require('nanoid');
|
||||
const alphabet = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ';
|
||||
|
||||
const schema = new DB.Schema('shop_config', {
|
||||
companyId: { type: 'ObjectId' },
|
||||
|
||||
apiUrl: { type: 'string', optional: true },
|
||||
apiKey: { type: 'string', optional: true },
|
||||
shopName: { type: 'string', optional: true },
|
||||
@@ -50,6 +48,5 @@ schema.post('create', function(data) {
|
||||
// Hook for post-create actions (e.g., emit events, notifications)
|
||||
});
|
||||
|
||||
DB.createIndex('shop_config', { companyId: 1 });
|
||||
|
||||
module.exports = schema;
|
||||
Reference in New Issue
Block a user