ovh: fix fields for use in creation form (#48052)

This commit is contained in:
Valentin Deniaud 2020-10-27 11:36:46 +01:00
parent 4fe1eb5c1d
commit 17dc62ab47
2 changed files with 27 additions and 1 deletions

View File

@ -0,0 +1,25 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.11.18 on 2020-10-27 10:21
from __future__ import unicode_literals
from django.db import migrations, models
class Migration(migrations.Migration):
dependencies = [
('ovh', '0011_auto_20201026_1424'),
]
operations = [
migrations.AlterField(
model_name='ovhsmsgateway',
name='credit_alert_timestamp',
field=models.DateTimeField(editable=False, null=True),
),
migrations.AlterField(
model_name='ovhsmsgateway',
name='username',
field=models.CharField(blank=True, help_text='API user created on the SMS account. This field is obsolete once keys and secret fields above are filled.', max_length=64, verbose_name='Username (deprecated)'),
),
]

View File

@ -61,6 +61,7 @@ class OVHSMSGateway(SMSResource):
username = models.CharField(
verbose_name=_('Username (deprecated)'),
max_length=64,
blank=True,
help_text=_('API user created on the SMS account. This field is obsolete once keys and secret '
'fields above are filled.'),
)
@ -83,7 +84,7 @@ class OVHSMSGateway(SMSResource):
null=True,
verbose_name=_('Email addresses to send credit alerts to'),
)
credit_alert_timestamp = models.DateTimeField(null=True)
credit_alert_timestamp = models.DateTimeField(null=True, editable=False)
TEST_DEFAULTS = {
'create_kwargs': {