|
1 | | -# Generated by Django 4.2.7 on 2024-07-01 13:30 |
| 1 | +# Generated by Django 4.2.7 on 2024-07-05 09:47 |
2 | 2 |
|
3 | 3 | import django.contrib.postgres.fields |
4 | 4 | import django.db.models.deletion |
@@ -44,12 +44,45 @@ class Migration(migrations.Migration): |
44 | 44 | ), |
45 | 45 | ("default_root_folder", models.CharField(blank=True)), |
46 | 46 | ("_api_base_url", models.URLField(blank=True)), |
| 47 | + ( |
| 48 | + "is_oauth1_ready", |
| 49 | + models.BooleanField( |
| 50 | + blank=True, |
| 51 | + null=True, |
| 52 | + verbose_name="addon_service.OAuth2TokenMetadata", |
| 53 | + ), |
| 54 | + ), |
47 | 55 | ], |
48 | 56 | options={ |
49 | 57 | "verbose_name": "Authorized Storage Account", |
50 | 58 | "verbose_name_plural": "Authorized Storage Accounts", |
51 | 59 | }, |
52 | 60 | ), |
| 61 | + migrations.CreateModel( |
| 62 | + name="OAuth1ClientConfig", |
| 63 | + fields=[ |
| 64 | + ( |
| 65 | + "id", |
| 66 | + addon_service.common.str_uuid_field.StrUUIDField( |
| 67 | + default=addon_service.common.str_uuid_field.str_uuid4, |
| 68 | + editable=False, |
| 69 | + primary_key=True, |
| 70 | + serialize=False, |
| 71 | + ), |
| 72 | + ), |
| 73 | + ("created", models.DateTimeField(editable=False)), |
| 74 | + ("modified", models.DateTimeField()), |
| 75 | + ("request_token_url", models.URLField()), |
| 76 | + ("auth_url", models.URLField()), |
| 77 | + ("access_token_url", models.URLField()), |
| 78 | + ("client_key", models.CharField(null=True)), |
| 79 | + ("client_secret", models.CharField(null=True)), |
| 80 | + ], |
| 81 | + options={ |
| 82 | + "verbose_name": "OAuth1 Client Config", |
| 83 | + "verbose_name_plural": "OAuth1 Client Configs", |
| 84 | + }, |
| 85 | + ), |
53 | 86 | migrations.CreateModel( |
54 | 87 | name="OAuth2ClientConfig", |
55 | 88 | fields=[ |
@@ -206,6 +239,16 @@ class Migration(migrations.Migration): |
206 | 239 | ), |
207 | 240 | ("api_base_url", models.URLField(blank=True, default="")), |
208 | 241 | ("wb_key", models.CharField(blank=True, default="")), |
| 242 | + ( |
| 243 | + "oauth1_client_config", |
| 244 | + models.ForeignKey( |
| 245 | + blank=True, |
| 246 | + null=True, |
| 247 | + on_delete=django.db.models.deletion.SET_NULL, |
| 248 | + related_name="external_storage_services", |
| 249 | + to="addon_service.oauth1clientconfig", |
| 250 | + ), |
| 251 | + ), |
209 | 252 | ( |
210 | 253 | "oauth2_client_config", |
211 | 254 | models.ForeignKey( |
|
0 commit comments