<commit_before>var _ = require('underscore'),
	schedule = require("./lib/schedule");

var city = {
  cityName: "Воронеж",
  vehicleViews: {
    "1": {
      id: 1,
      fareDetailsUrl: null,
      allowFareEstimate: true,
      mapImages: [
        {
          url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/map70px/map-uberx.png",
          width: 70,
          height: 70
        }
      ],
      monoImages: [
        {
          url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/mono/mono-uberx.png",
          width: 100,
          height: 37
        }
      ],
      description: "INSTACAB",
      // pickupButtonString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
      // confirmPickupButtonString: "Подтвердить заказ",
      requestPickupButtonString: "ЗАКАЗАТЬ {string}",
      setPickupLocationString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
      pickupEtaString: "Время прибытия машины примерно {string}",
      noneAvailableString: schedule.getNoneAvailableString(),
    },

    "2": {
    	id: 2,
    	fareDetailsUrl: null,
    	allowFareEstimate: true,
    	mapImages: [
    	  {
    	    url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/map70px/map-taxi.png",
    	    width: 70,
    	    height: 70
    	  }
    	],
    	monoImages: [
    	  {
    	    url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/mono/mono-taxi.png",
    	    width: 100,
    	    height: 37
    	  }
    	],
    	description: "ТАКСИ",
    	// pickupButtonString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
    	// confirmPickupButtonString: "Подтвердить заказ",
    	requestPickupButtonString: "ЗАКАЗАТЬ {string}",
    	setPickupLocationString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
    	pickupEtaString: "Время прибытия машины примерно {string}",
    	noneAvailableString: "НЕТ СВОБОДНЫХ ТАКСИ",
    }
  },
  vehicleViewsOrder: [ 2, 1 ],
  defaultVehicleViewId: 1
};

function tripForClientToJSON(trip) {
	var vehicle = trip.driver.vehicle;

	vehicle.vehicleViewId = city.defaultVehicleViewId;
	vehicle.uuid = vehicle.id;

	// Web Mobile Client
	vehicle.vehicleType = {
		make: vehicle.make,
		model: vehicle.model<commit_msg>Make city schedule dynamic, not one time reading at server start<commit_after>var _ = require('underscore'),
	schedule = require("./lib/schedule");

var city = {
  cityName: "Воронеж",
  vehicleViews: {
    "1": {
      id: 1,
      fareDetailsUrl: null,
      allowFareEstimate: true,
      mapImages: [
        {
          url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/map70px/map-uberx.png",
          width: 70,
          height: 70
        }
      ],
      monoImages: [
        {
          url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/mono/mono-uberx.png",
          width: 100,
          height: 37
        }
      ],
      description: "INSTACAB",
      // pickupButtonString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
      // confirmPickupButtonString: "Подтвердить заказ",
      requestPickupButtonString: "ЗАКАЗАТЬ {string}",
      setPickupLocationString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
      pickupEtaString: "Время прибытия машины примерно {string}",
      noneAvailableString: "НЕТ СВОБОДНЫХ АВТОМОБИЛЕЙ",
    },

    "2": {
    	id: 2,
    	fareDetailsUrl: null,
    	allowFareEstimate: true,
    	mapImages: [
    	  {
    	    url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/map70px/map-taxi.png",
    	    width: 70,
    	    height: 70
    	  }
    	],
    	monoImages: [
    	  {
    	    url: "https://s3-eu-west-1.amazonaws.com/instacab-assets/car-types/mono/mono-taxi.png",
    	    width: 100,
    	    height: 37
    	  }
    	],
    	description: "ТАКСИ",
    	// pickupButtonString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
    	// confirmPickupButtonString: "Подтвердить заказ",
    	requestPickupButtonString: "ЗАКАЗАТЬ {string}",
    	setPickupLocationString: "ВЫБРАТЬ МЕСТО ПОСАДКИ",
    	pickupEtaString: "Время прибытия машины примерно {string}",
    	noneAvailableString: "НЕТ СВОБОДНЫХ ТАКСИ",
    }
  },
  vehicleViewsOrder: [ 2, 1 ],
  defaultVehicleViewId: 1
};

function getCity {
	city.vehicleViews["1"].noneAvailableString = schedule.getNoneAvailableString();
	return city;
}

function tripForClientToJSON(trip) {
	var vehicle = trip.driver.vehicle;

	vehicle.vehicleViewId = city.defaultVehicleViewId;
	vehicle.uuid = vehicle.id;

	// Web Mobile Client
	vehicle.vehicleType = {
		make: vehicle.make,
		model: vehicle.model
{'fraction_non_alphanumeric': 0.12681159420289856, 'fraction_numerical': 0.016983695652173912, 'mean_word_length': 2.5139220365950674, 'pattern_counts': {'":': 4, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 8, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4847129', 'n_tokens_mistral': 1796, 'n_tokens_neox': 1764, 'n_words': 263}