Пример #1
0
	def __str__(self):
		return "%s %s %s" % (
			str(self.id),
			operations.decrypt_value(
				self.salt,
				self.first_name_enc,
			),
			operations.decrypt_value(self.salt, self.last_name_enc))
Пример #2
0
	def decrypt(self):
		self.email_enc = operations.decrypt_value(
			self.personal_data.salt, self.email_enc
		)
		self.email_password_enc = operations.decrypt_value(
			self.personal_data.salt,
			self.email_password_enc
		)
		return self
Пример #3
0
	def decrypt(self):
		self.first_name_enc = operations.decrypt_value(
			self.salt, self.first_name_enc
		)
		self.last_name_enc = operations.decrypt_value(
			self.salt, self.last_name_enc
		)
		self.address_enc = operations.decrypt_value(
			self.salt, self.address_enc
		)
		return self
Пример #4
0
	def __init__(self, *args, **kwargs):
		if kwargs.get('instance', None):
			if not kwargs.get('initial'):
				kwargs['initial'] = {}
			kwargs['initial'].update({
				'email_enc': operations.decrypt_value(
					kwargs['instance'].personal_data.salt,
					kwargs['instance'].email_enc
				),
			})
		super(EmailForm, self).__init__(*args, **kwargs)
Пример #5
0
	def __str__(self):
		return operations.decrypt_value(self.personal_data.salt, self.email_enc)