@@ -150,16 +150,16 @@ discard block |
||
150 | 150 | $faker = Factory::create(); |
151 | 151 | $this->configuration['dni'] = $this->getDNI(); |
152 | 152 | $this->configuration['birthdate'] = |
153 | - $faker->numberBetween(1, 28) . '/' . |
|
154 | - $faker->numberBetween(1, 12). '/1975' |
|
153 | + $faker->numberBetween(1, 28).'/'. |
|
154 | + $faker->numberBetween(1, 12).'/1975' |
|
155 | 155 | ; |
156 | 156 | $this->configuration['firstname'] = $faker->firstName; |
157 | - $this->configuration['lastname'] = $faker->lastName . ' ' . $faker->lastName; |
|
157 | + $this->configuration['lastname'] = $faker->lastName.' '.$faker->lastName; |
|
158 | 158 | $this->configuration['company'] = $faker->company; |
159 | 159 | $this->configuration['zip'] = '28'.$faker->randomNumber(3, true); |
160 | 160 | $this->configuration['street'] = $faker->streetAddress; |
161 | - $this->configuration['phone'] = '6' . $faker->randomNumber(8); |
|
162 | - $this->configuration['email'] = date('ymd') . '@pagantis.com'; |
|
161 | + $this->configuration['phone'] = '6'.$faker->randomNumber(8); |
|
162 | + $this->configuration['email'] = date('ymd').'@pagantis.com'; |
|
163 | 163 | |
164 | 164 | if (!isset($_SERVER['argv']) || |
165 | 165 | !isset($_SERVER['argv'][4]) || |
@@ -183,12 +183,12 @@ discard block |
||
183 | 183 | */ |
184 | 184 | protected function getDNI() |
185 | 185 | { |
186 | - $dni = '0000' . rand(pow(10, 4-1), pow(10, 4)-1); |
|
186 | + $dni = '0000'.rand(pow(10, 4 - 1), pow(10, 4) - 1); |
|
187 | 187 | $value = (int) ($dni / 23); |
188 | 188 | $value *= 23; |
189 | - $value= $dni - $value; |
|
190 | - $letter= "TRWAGMYFPDXBNJZSQVHLCKEO"; |
|
191 | - $dniLetter= substr($letter, $value, 1); |
|
189 | + $value = $dni - $value; |
|
190 | + $letter = "TRWAGMYFPDXBNJZSQVHLCKEO"; |
|
191 | + $dniLetter = substr($letter, $value, 1); |
|
192 | 192 | return $dni.$dniLetter; |
193 | 193 | } |
194 | 194 |