I am dragging various sources to create a person's profile once I do this, I want to have the flexibility to look at different ways. I do not have much expenditures in the DJG so I would like a criticism of my model. Of course, as I coded it, I am thinking about finely, but I would like to know what others think. FWIW - This data was not designed to be pulled - so maybe I should not keep all this but leaving data seems bad ..
Especially I want to know if that is appropriate for the use of ManyToMany Or you just have to kiss and leave every entry because it is without any many businesses. Long time I think that kissing will make it simple (an original for loop), but to inquire a person In Is a means of being able (Sthan_vivrn or by job function). Anyway I appreciate some input
class person (models.Model): "" "Other names = models.ManyToManyField (alias)" This simply makes a note user " Hmm this list .. have = models.CharField (MAX_LENGTH = 255, blank = true) cell_phone = models.CharField (max_lenth = 16, empty = true) city = models.ManyToManyField (city) country = models.ManyToManyField (county) department = models.ManyToManyField (department) departmeht_number = model .ManyToManyField (Department_Number) division_code = models.ManyToManyField (Division_Code) email = models.EmailField (MAX_LENGTH = 50) functional_area = models.ManyToManyField (Functional_Area) # jpeg = model. Job_classification = models.ManyToManyField (Job_Classification) job_classification_code = ModalToManyField (Job_Classification_Code) last_name = models.CharField (max_length = 255) location_description = models.ManyToManyField (Location_Description) location_path = Model. ManyToManyField (Location_Path) mail_address = models.CharField (max_length = 255, blank = true) MAIL_DOMAIN = models.ManyToManyField (MAIL_DOMAIN) mail_file = models.CharField (MAX_LENGTH = 255, blank = true) MAIL_SERVER = models.ManyToManyField (MAIL_SERVER) match_pct = models.CharField (max_lenth = 6) name = model. CharField (MAX_LENGTH = 255) name_reverse = models.CharField (MAX_LENGTH = 255) nickname = models.CharField (MAX_LENGTH = 32) notes_url = models.URLField () # object_class = model. office_phone = models.CharField (MAX_LENGTH = 255, blank = True) other_phone = models.CharField (MAX_LENGTH = 255, empty = true) position = models.ManyToManyField (status) section = models.ManyToManyField (stream) section_code = models.ManyToManyField ((code) = shift model. many Tom Mainifild (shift) state = model. many Tommanfidl (state) supervisor = model. many Maifild (supervisor) supervisor reverse = model. many Menifild (Suprwaijr_rewars) UID = Modlkkrifild (Max_long = 128) def __unicode __ (self): return str (self.name)
>
Here are some ideas.
I think that you
department
andjob_classification
for example.class section (models.Model): name = Models.CharField (MAX_LENGTH = 100) Number = Models.IntegerField
And then there is a lot of organization for the department otherwise, if you have
department = ['hr', 'finance']
and If someone is a person withdepartment_number = [12, 5]
, then I do not think there is any Defense Department does not show that represents what type of number is.If the fields I find are easy models to read alphabetically instead of being classified based on what they describe. EG I think that
names
,alias
,last_name
should be defined together.Finally, maybe aka should be a different model with
foreign
toperson
, because only one person has a special nickname needed.
No comments:
Post a Comment