Added customer_number and serice pin
This commit is contained in:
@@ -51,6 +51,20 @@ class Address extends mfBaseModel {
|
||||
|
||||
}
|
||||
|
||||
public function generateServicePin() {
|
||||
if(!$this->customer_number) {
|
||||
return false;
|
||||
}
|
||||
$num1 = rand(65, 90);
|
||||
$num2 = rand(65, 90);
|
||||
|
||||
$c1 = chr($num1);
|
||||
$c2 = chr($num2);
|
||||
|
||||
$spin = $c1.$c2.$this->customer_number;
|
||||
return $spin;
|
||||
}
|
||||
|
||||
public function getProperty($name) {
|
||||
if($this->$name == null) {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user