feat: remove plugin-charts

This commit is contained in:
chenos 2023-10-31 09:20:46 +08:00
parent f374c2f9b5
commit c3a1538435
2 changed files with 28 additions and 1 deletions

View File

@ -23,7 +23,6 @@ export class PresetNocoBase extends Plugin {
'duplicator',
'iframe-block',
'formula-field',
'charts',
'data-visualization',
'auth',
'sms-auth',
@ -31,6 +30,7 @@ export class PresetNocoBase extends Plugin {
];
localPlugins = [
// ['charts', '0.9.1-alpha.2'],
['audit-logs', '0.7.1-alpha.4'],
['sample-hello', '0.8.0-alpha.4'],
['multi-app-manager', '0.7.0-alpha.1'],

View File

@ -0,0 +1,27 @@
import { Migration } from '@nocobase/server';
export default class extends Migration {
async up() {
const version = await this.app.version.satisfies('<0.14.0-alpha.8');
if (!version) {
return;
}
const repository = this.context.db.getRepository('applicationPlugins');
const model = await repository.findOne({
filter: {
name: 'charts',
},
});
if (!model) {
return;
}
await repository.update({
values: {
builtIn: false,
},
filter: {
name: 'charts',
},
});
}
}