public function getCountriesAndZones()
 {
     $coutnry_service = new CountryService();
     $countries = $coutnry_service->getAll(['columns' => ['id', 'name'], 'sort_column' => 'name']);
     $zone_service = new ZoneService();
     $zones = $zone_service->getAll(['columns' => ['id', 'name', 'country_id'], 'sort_column' => 'name'])->toArray();
     return Response::json(['countries' => $countries, 'zones' => $zones]);
 }
 public function getEmpty()
 {
     $country_service = new CountryService();
     $country = $country_service->getById(84);
     $zones = $country->zones->toArray();
     $faker = \Faker\Factory::create();
     $data = ['first_name' => $faker->firstName, 'last_name' => $faker->lastName, 'company' => $faker->company, 'address_1' => $faker->address, 'address_2' => $faker->address, 'city' => $faker->city, 'postal_code' => $faker->postcode, 'country_id' => $country->id, 'zone_id' => $zones[rand(0, count($zones) - 1)]['id']];
     return Response::json($data);
 }