From 2dbedc1303bb13dd83571646873e414bc843b735 Mon Sep 17 00:00:00 2001 From: Pierre Date: Thu, 19 Apr 2018 09:31:47 +0200 Subject: [PATCH] Created SecuritySettings model --- classes/models/SecuritySettings.php | 72 +++++++++++++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 classes/models/SecuritySettings.php diff --git a/classes/models/SecuritySettings.php b/classes/models/SecuritySettings.php new file mode 100644 index 0000000..44e64f1 --- /dev/null +++ b/classes/models/SecuritySettings.php @@ -0,0 +1,72 @@ +security_question_1 = $security_question_1 == "" ? null : $security_question_1; + } + + public function has_security_question_1() : bool { + return $this->security_question_1 != null; + } + + public function get_security_question_1() : string { + return $this->security_question_1 != null ? $this->security_question_1 : "null"; + } + + + //Set and get first security answer + public function set_security_answer_1(string $security_answer_1){ + $this->security_answer_1 = $security_answer_1 == "" ? null : $security_answer_1; + } + + public function has_security_answer_1() : bool { + return $this->security_answer_1 != null; + } + + public function get_security_answer_1() : string { + return $this->security_answer_1 != null ? $this->security_answer_1 : "null"; + } + + + //Set and get second security question + public function set_security_question_2(string $security_question_2){ + $this->security_question_2 = $security_question_2 == "" ? null : $security_question_2; + } + + public function has_security_question_2() : bool { + return $this->security_question_2 != null; + } + + public function get_security_question_2() : string { + return $this->security_question_2 != null ? $this->security_question_2 : "null"; + } + + + //Set and get second security answer + public function set_security_answer_2(string $security_answer_2){ + $this->security_answer_2 = $security_answer_2 == "" ? null : $security_answer_2; + } + + public function has_security_answer_2() : bool { + return $this->security_answer_2 != null; + } + + public function get_security_answer_2() : string { + return $this->security_answer_2 != null ? $this->security_answer_2 : "null"; + } + +} \ No newline at end of file