3rd Party Mod Installed

I just installed. Now I want to override the default values in the Admin area form. I found the, which defines the models, and contains the current default text: class CSVImport(models. Mts Zte S1602 Usb Driver Download Fl. Model): '' Logging model for importing files '' model_choice = [] model_name = models. Premium Gerador. CharField(max_length=255, blank=False, default='csvimport.Item', help_text='Please specify the app_label.model_name', choices=get_models()) field_list = models.TextField(blank=True, help_text=''Enter list of fields in order only if you dont have a header row with matching field names, eg. ''Your admin.py'' from csvimport.models import CSVImport from csvimport.admin import CSVImportAdmin class MyCSVImportAdmin(CSVImportAdmin): ''Override some of the form's field properties: clean, creation_counter, default_error_messages, default_validators, disabled, empty_value, empty_values.

3rd Party Mod Installed3rd Party Mod Installed

Antares Clinica Program. Etc '' def get_form(self, request, obj=None, **kwargs): form = super(MyCSVImportAdmin, self).get_form(request, obj, **kwargs) form.base_fields['model_name'].initial = 'What you want' form.base_fields['model_name'].help_text = 'Please customize the fields however you like' return form admin.site.unregister(CSVImport) admin.site.register(CSVImport, MyCSVImportAdmin). Ha, sorry of course I have 'an app', which i think is called a 'project' in django.

Comments are closed.