refactor(profile): added social link in profile and in organization
This commit is contained in:
@@ -157,12 +157,14 @@ class ProfileSerializer(serializers.ModelSerializer):
|
|||||||
"player_id",
|
"player_id",
|
||||||
"first_name",
|
"first_name",
|
||||||
"last_name",
|
"last_name",
|
||||||
|
'business_name',
|
||||||
"phone_no",
|
"phone_no",
|
||||||
"email",
|
"email",
|
||||||
"linkedin_profile",
|
"linkedin_profile",
|
||||||
"youtube_profile",
|
"youtube_profile",
|
||||||
"facebook_profile",
|
"facebook_profile",
|
||||||
"instagram_profile",
|
"instagram_profile",
|
||||||
|
"twitter_profile",
|
||||||
"website",
|
"website",
|
||||||
"is_active",
|
"is_active",
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -55,6 +55,13 @@ class OrganizationSerializer(serializers.ModelSerializer):
|
|||||||
"subscription_agreement",
|
"subscription_agreement",
|
||||||
"license_agreement_user",
|
"license_agreement_user",
|
||||||
"license_agreement_merchant",
|
"license_agreement_merchant",
|
||||||
|
"contact_us_email",
|
||||||
|
"instagram_handle",
|
||||||
|
"facebook_handle",
|
||||||
|
"linkedin_handle",
|
||||||
|
"website_url",
|
||||||
|
"address",
|
||||||
|
"contact_us_phone",
|
||||||
]
|
]
|
||||||
|
|
||||||
class EducationVideoSerializer(serializers.ModelSerializer):
|
class EducationVideoSerializer(serializers.ModelSerializer):
|
||||||
|
|||||||
@@ -22,26 +22,31 @@ class OrganizationForm(forms.ModelForm):
|
|||||||
fields = [
|
fields = [
|
||||||
"title",
|
"title",
|
||||||
"contact_us_email",
|
"contact_us_email",
|
||||||
|
"contact_us_phone",
|
||||||
|
"address",
|
||||||
|
"website_url",
|
||||||
"instagram_handle",
|
"instagram_handle",
|
||||||
"facebook_handle",
|
"facebook_handle",
|
||||||
"linkedin_handle",
|
"linkedin_handle",
|
||||||
|
"twitter_handle",
|
||||||
"logo_image",
|
"logo_image",
|
||||||
"favicon_image",
|
"favicon_image",
|
||||||
"website_url",
|
|
||||||
]
|
]
|
||||||
|
|
||||||
labels = {
|
labels = {
|
||||||
"title": "Organization Title",
|
"title": "Organization Title",
|
||||||
"contact_us_email": "Contact Email",
|
"contact_us_email": "Contact Email",
|
||||||
|
"contact_us_phone": "Contact Phone No",
|
||||||
|
"Address": "Contact Address",
|
||||||
|
"website_url": "Website URL",
|
||||||
"instagram_handle": "Instagram URL",
|
"instagram_handle": "Instagram URL",
|
||||||
"facebook_handle": "Facebook URL",
|
"facebook_handle": "Facebook URL",
|
||||||
"linkedin_handle": "LinkedIn URL",
|
"linkedin_handle": "LinkedIn URL",
|
||||||
|
"Twitter_handle": "Twitter URL",
|
||||||
"logo_image": "Organization Logo",
|
"logo_image": "Organization Logo",
|
||||||
"favicon_image": "Favicon",
|
"favicon_image": "Favicon",
|
||||||
"website_url": "Website URL",
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
class NewsAndArticleCategoryForm(forms.ModelForm):
|
class NewsAndArticleCategoryForm(forms.ModelForm):
|
||||||
class Meta:
|
class Meta:
|
||||||
model = NewsAndArticlesCategory
|
model = NewsAndArticlesCategory
|
||||||
|
|||||||
@@ -0,0 +1,25 @@
|
|||||||
|
# Generated by Django 5.0.2 on 2024-08-16 08:29
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('manage_cms', '0001_initial'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='organization',
|
||||||
|
name='address',
|
||||||
|
field=models.TextField(default='this is address'),
|
||||||
|
preserve_default=False,
|
||||||
|
),
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='organization',
|
||||||
|
name='contact_us_phone',
|
||||||
|
field=models.CharField(default='+911212121212', max_length=16),
|
||||||
|
preserve_default=False,
|
||||||
|
),
|
||||||
|
]
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
# Generated by Django 5.0.2 on 2024-08-16 09:29
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('manage_cms', '0002_organization_address_organization_contact_us_phone'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='organization',
|
||||||
|
name='twitter_handle',
|
||||||
|
field=models.URLField(blank=True, null=True),
|
||||||
|
),
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='organization',
|
||||||
|
name='address',
|
||||||
|
field=models.TextField(blank=True, null=True),
|
||||||
|
),
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='organization',
|
||||||
|
name='contact_us_phone',
|
||||||
|
field=models.CharField(blank=True, max_length=16, null=True),
|
||||||
|
),
|
||||||
|
]
|
||||||
@@ -89,6 +89,7 @@ class Organization(BaseModel):
|
|||||||
instagram_handle = models.URLField(blank=True, null=True)
|
instagram_handle = models.URLField(blank=True, null=True)
|
||||||
facebook_handle = models.URLField(blank=True, null=True)
|
facebook_handle = models.URLField(blank=True, null=True)
|
||||||
linkedin_handle = models.URLField(blank=True, null=True)
|
linkedin_handle = models.URLField(blank=True, null=True)
|
||||||
|
twitter_handle = models.URLField(blank=True, null=True)
|
||||||
logo_image = models.ImageField(blank=True, null=True, upload_to="organization/logo")
|
logo_image = models.ImageField(blank=True, null=True, upload_to="organization/logo")
|
||||||
favicon_image = models.ImageField(
|
favicon_image = models.ImageField(
|
||||||
blank=True, null=True, upload_to="organization/favicon"
|
blank=True, null=True, upload_to="organization/favicon"
|
||||||
@@ -104,6 +105,8 @@ class Organization(BaseModel):
|
|||||||
subscription_agreement = QuillField()
|
subscription_agreement = QuillField()
|
||||||
license_agreement_user = QuillField()
|
license_agreement_user = QuillField()
|
||||||
license_agreement_merchant = QuillField()
|
license_agreement_merchant = QuillField()
|
||||||
|
address = models.TextField(blank=True, null=True)
|
||||||
|
contact_us_phone = models.CharField(max_length=16, blank=True, null=True)
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
db_table = "organization"
|
db_table = "organization"
|
||||||
|
|||||||
@@ -50,6 +50,36 @@
|
|||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-3">
|
||||||
|
<p class="mb-0">Contact Phone</p>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-9">
|
||||||
|
<p class="text-muted mb-0">{{organization_obj.contact_us_phone}}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-3">
|
||||||
|
<p class="mb-0">Address</p>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-9">
|
||||||
|
<p class="text-muted mb-0">{{organization_obj.address}}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<hr>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-3">
|
||||||
|
<p class="mb-0">Websiter Url</p>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-9">
|
||||||
|
<p class="text-muted mb-0">{{organization_obj.website_url}}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<hr>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-sm-3">
|
<div class="col-sm-3">
|
||||||
<p class="mb-0">Instagram Url</p>
|
<p class="mb-0">Instagram Url</p>
|
||||||
@@ -59,6 +89,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-sm-3">
|
<div class="col-sm-3">
|
||||||
<p class="mb-0">Facebook Url</p>
|
<p class="mb-0">Facebook Url</p>
|
||||||
@@ -69,6 +100,15 @@
|
|||||||
</div>
|
</div>
|
||||||
<hr>
|
<hr>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-3">
|
||||||
|
<p class="mb-0">Twitter Url</p>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-9">
|
||||||
|
<p class="text-muted mb-0">{{organization_obj.Twitter_handle}}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<hr>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-sm-3">
|
<div class="col-sm-3">
|
||||||
|
|||||||
Reference in New Issue
Block a user