app/projrev/models.py
changeset 24 7257b66a6766
parent 23 91cf6872d853
child 26 97bd3c28c957
equal deleted inserted replaced
23:91cf6872d853 24:7257b66a6766
   676       }
   676       }
   677 
   677 
   678   # Field containing the Line Item to which the project belongs to.
   678   # Field containing the Line Item to which the project belongs to.
   679   line_item = models.CharField(max_length=256,
   679   line_item = models.CharField(max_length=256,
   680                                choices=sort_dict(LINE_ITEM_CHOICES))
   680                                choices=sort_dict(LINE_ITEM_CHOICES))
   681   line_item.help_text = "Select from one of the Line Items."
   681   line_item.help_text = 'Select from one of the Line Items.'
   682 
   682 
   683   # Field containing the name of the institution working on the
   683   # Field containing the name of the institution working on the
   684   # project.
   684   # project.
   685   institution = models.CharField(max_length=256)
   685   institution = models.CharField(max_length=256)
       
   686   institution.help_text = 'Give the full name of your institution.'
   686 
   687 
   687   # Field containing the state to which the institution belongs to.
   688   # Field containing the state to which the institution belongs to.
   688   state = models.CharField(
   689   state = models.CharField(
   689       max_length=256,
   690       max_length=256,
   690       choices=sorted(STATE_CHOICES.items(), key=lambda (k,v): (v,k)))
   691       choices=sorted(STATE_CHOICES.items(), key=lambda (k,v): (v,k)))
       
   692   state.help_text = 'Select the state in which this project is taken up.'
   691 
   693 
   692   # Field containing the district to which the institution belongs
   694   # Field containing the district to which the institution belongs
   693   # to in the state of India.
   695   # to in the state of India.
   694   district = models.CharField(max_length=256,
   696   district = models.CharField(max_length=256,
   695                               choices=sort_dict(DISTRICT_CHOICES))
   697                               choices=sort_dict(DISTRICT_CHOICES))
       
   698   district.help_text = ('First select the state before selecting the district. '
       
   699       'Select the district of the state where this project is taken up.')
   696 
   700 
   697   mobile_num = models.CharField(max_length=20)
   701   mobile_num = models.CharField(max_length=20)
       
   702   mobile_num.help_text = 'Enter your mobile number.'
   698 
   703 
   699   fax_num = models.CharField(max_length=20, null=True, blank=True)
   704   fax_num = models.CharField(max_length=20, null=True, blank=True)
       
   705   fax_num.help_text = 'Enter your fax number with the code.'
   700 
   706 
   701   # Field containing the autogenerated MICR code for the project.
   707   # Field containing the autogenerated MICR code for the project.
   702   micr_code = models.CharField(max_length=15, unique=True)
   708   micr_code = models.CharField(max_length=15, unique=True)
   703 
   709 
   704   # Field containing the status of the project.
   710   # Field containing the status of the project.
   771   #: Field representing the relation to the corresponding project.
   777   #: Field representing the relation to the corresponding project.
   772   project = models.ForeignKey(Project)
   778   project = models.ForeignKey(Project)
   773  
   779  
   774   #: Field containing the Line Item to which the project belongs to.
   780   #: Field containing the Line Item to which the project belongs to.
   775   document = models.FileField(upload_to='proposals/%Y/%m/%d')
   781   document = models.FileField(upload_to='proposals/%Y/%m/%d')
       
   782   document.help_text = 'Select the document path from your local file system.'
   776 
   783 
   777   #: Field containing the date on which the document was submitted
   784   #: Field containing the date on which the document was submitted
   778   submitted_on = models.DateTimeField(auto_now_add=True)
   785   submitted_on = models.DateTimeField(auto_now_add=True)
   779 
   786 
   780   #: Field containing the reference to the user who submitted the proposal.
   787   #: Field containing the reference to the user who submitted the proposal.