This commit is contained in:
dream2023 2024-01-13 17:44:08 +08:00
parent da365210e4
commit 300302c118

View File

@ -1,58 +1,58 @@
import { CollectionTemplate, getConfigurableProperties } from '@nocobase/client'; import { CollectionTemplate, ICollectionTemplate, getConfigurableProperties } from '@nocobase/client';
import { generateNTemplate } from '../../locale'; import { generateNTemplate } from '../../locale';
// export const calendar: ICollectionTemplate = { export const calendar: ICollectionTemplate = {
// name: 'calendar', name: 'calendar',
// title: generateNTemplate('Calendar collection'), title: generateNTemplate('Calendar collection'),
// order: 2, order: 2,
// color: 'orange', color: 'orange',
// default: { default: {
// createdBy: true, createdBy: true,
// updatedBy: true, updatedBy: true,
// createdAt: true, createdAt: true,
// updatedAt: true, updatedAt: true,
// sortable: true, sortable: true,
// fields: [ fields: [
// { {
// name: 'cron', name: 'cron',
// type: 'string', type: 'string',
// uiSchema: { uiSchema: {
// type: 'string', type: 'string',
// title: generateNTemplate('Repeats'), title: generateNTemplate('Repeats'),
// 'x-component': 'CronSet', 'x-component': 'CronSet',
// 'x-component-props': 'allowClear', 'x-component-props': 'allowClear',
// enum: [ enum: [
// { {
// label: generateNTemplate('Daily'), label: generateNTemplate('Daily'),
// value: '0 0 0 * * ?', value: '0 0 0 * * ?',
// }, },
// { {
// label: generateNTemplate('Weekly'), label: generateNTemplate('Weekly'),
// value: 'every_week', value: 'every_week',
// }, },
// { {
// label: generateNTemplate('Monthly'), label: generateNTemplate('Monthly'),
// value: 'every_month', value: 'every_month',
// }, },
// { {
// label: generateNTemplate('Yearly'), label: generateNTemplate('Yearly'),
// value: 'every_year', value: 'every_year',
// }, },
// ], ],
// }, },
// interface: 'select', interface: 'select',
// }, },
// { {
// name: 'exclude', name: 'exclude',
// type: 'json', type: 'json',
// }, },
// ], ],
// }, },
// availableFieldInterfaces: { availableFieldInterfaces: {
// include: [], include: [],
// }, },
// configurableProperties: getConfigurableProperties('title', 'name', 'inherits', 'category', 'description'), configurableProperties: getConfigurableProperties('title', 'name', 'inherits', 'category', 'description'),
// }; };
export class CalendarCollectionTemplate extends CollectionTemplate { export class CalendarCollectionTemplate extends CollectionTemplate {
name = 'calendar'; name = 'calendar';