增加companyinfo
This commit is contained in:
parent
7555d6f8e9
commit
1919e93124
|
|
@ -21,5 +21,7 @@ class CompanyInfoForm(forms.Form):
|
||||||
legalperson_phone = forms.CharField(max_length=24, label='法人电话', widget=forms.TextInput(attrs={'size': '50'}))
|
legalperson_phone = forms.CharField(max_length=24, label='法人电话', widget=forms.TextInput(attrs={'size': '50'}))
|
||||||
liaison = forms.CharField(max_length=24, label='联系人', widget=forms.TextInput(attrs={'size': '50'}))
|
liaison = forms.CharField(max_length=24, label='联系人', widget=forms.TextInput(attrs={'size': '50'}))
|
||||||
liaison_phone = forms.CharField(max_length=24, label='联系人电话', widget=forms.TextInput(attrs={'size': '50'}))
|
liaison_phone = forms.CharField(max_length=24, label='联系人电话', widget=forms.TextInput(attrs={'size': '50'}))
|
||||||
|
enp_number = forms.CharField(max_length=24, label='环评批复文号', widget=forms.TextInput(attrs={'size': '50'}), required=False)
|
||||||
|
waste_number = forms.CharField(max_length=24, label='排污许可证编号', widget=forms.TextInput(attrs={'size': '50'}), required=False)
|
||||||
introduce = forms.CharField(label='公司概况', widget=forms.Textarea)
|
introduce = forms.CharField(label='公司概况', widget=forms.Textarea)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,23 @@
|
||||||
|
# Generated by Django 2.2.8 on 2021-10-06 18:19
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('safesite', '0389_auto_20210905_1612'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='companyinfo',
|
||||||
|
name='enp_number',
|
||||||
|
field=models.CharField(blank=True, max_length=50, null=True, verbose_name='环评批复文号'),
|
||||||
|
),
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='companyinfo',
|
||||||
|
name='waste_number',
|
||||||
|
field=models.CharField(blank=True, max_length=50, null=True, verbose_name='排污许可证编号'),
|
||||||
|
),
|
||||||
|
]
|
||||||
|
|
@ -1233,6 +1233,8 @@ class CompanyInfo(models.Model):
|
||||||
liaison = models.CharField(max_length=24, verbose_name='联系人')
|
liaison = models.CharField(max_length=24, verbose_name='联系人')
|
||||||
liaison_phone = models.CharField(max_length=24, verbose_name='联系人电话')
|
liaison_phone = models.CharField(max_length=24, verbose_name='联系人电话')
|
||||||
introduce = models.TextField(null=True, blank=True, verbose_name='公司概况')
|
introduce = models.TextField(null=True, blank=True, verbose_name='公司概况')
|
||||||
|
enp_number = models.CharField(max_length=50, verbose_name='环评批复文号', null=True, blank=True)
|
||||||
|
waste_number = models.CharField(max_length=50, verbose_name='排污许可证编号', null=True, blank=True)
|
||||||
createtime = models.DateTimeField(auto_now_add=True)
|
createtime = models.DateTimeField(auto_now_add=True)
|
||||||
modifytime = models.DateTimeField(auto_now=True)
|
modifytime = models.DateTimeField(auto_now=True)
|
||||||
# 法律法规分类表
|
# 法律法规分类表
|
||||||
|
|
|
||||||
|
|
@ -8312,6 +8312,8 @@ def companyinfo(req):
|
||||||
companyinfo.peoplenum = companyinfo_form.cleaned_data.get(
|
companyinfo.peoplenum = companyinfo_form.cleaned_data.get(
|
||||||
'peoplenum')
|
'peoplenum')
|
||||||
companyinfo.website = companyinfo_form.cleaned_data.get('website')
|
companyinfo.website = companyinfo_form.cleaned_data.get('website')
|
||||||
|
companyinfo.enp_number = companyinfo_form.cleaned_data.get('enp_number', None)
|
||||||
|
companyinfo.waste_number = companyinfo_form.cleaned_data.get('waste_number', None)
|
||||||
companyinfo.save()
|
companyinfo.save()
|
||||||
#html = 'companyinfo.html'
|
#html = 'companyinfo.html'
|
||||||
# return redirect('/withmenu/', html="companyinfo.html")
|
# return redirect('/withmenu/', html="companyinfo.html")
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue