52f8a31bf3bdb6763989b48ed9334cae3b3b733a
[Packages/TYPO3.CMS.git] / typo3 / sysext / form / Resources / Public / JavaScript / Wizard / Viewport / Left / Options / Forms / Validation / FileAllowedTypes.js
1 Ext.namespace('TYPO3.Form.Wizard.Viewport.Left.Options.Forms.FileAllowedTypes');
2
3 /**
4 * The allowed file types rule
5 *
6 * @class TYPO3.Form.Wizard.Viewport.Left.Options.Forms.Validation.FileAllowedTypes
7 * @extends TYPO3.Form.Wizard.Viewport.Left.Options.Forms.Validation.Rule
8 */
9 TYPO3.Form.Wizard.Viewport.Left.Options.Forms.Validation.FileAllowedTypes = Ext.extend(TYPO3.Form.Wizard.Viewport.Left.Options.Forms.Validation.Rule, {
10 /**
11 * @cfg {String} rule
12 *
13 * The name of this rule
14 */
15 rule: 'fileallowedtypes',
16
17 /**
18 * Constructor
19 *
20 * Add the configuration object to this component
21 * @param config
22 */
23 constructor: function(config) {
24 Ext.apply(this, {
25 configuration: {
26 breakOnError: 0,
27 showMessage: 1,
28 message: TYPO3.l10n.localize('tx_form_system_validate_fileallowedtypes.message'),
29 error: TYPO3.l10n.localize('tx_form_system_validate_fileallowedtypes.error'),
30 types: ''
31 }
32 });
33 TYPO3.Form.Wizard.Viewport.Left.Options.Forms.Validation.FileAllowedTypes.superclass.constructor.apply(this, arguments);
34 }
35 });
36
37 Ext.reg('typo3-form-wizard-viewport-left-options-forms-validation-fileallowedtypes', TYPO3.Form.Wizard.Viewport.Left.Options.Forms.Validation.FileAllowedTypes);