<?php
// $Id: indonesia_360_1.cif,v 1.2.2.7 2010/04/14 05:18:19 tr Exp $

function indonesia_install() {
  db_query("INSERT INTO {uc_countries} (country_id, country_name, country_iso_code_2, country_iso_code_3, version) VALUES (360, 'Indonesia', 'ID', 'IDN', 1)");

  // Make the entries in the zones table.
  $zones = array(
    array(360, 'NAD', 'Nanggroe Aceh Darussalam'),
    array(360, 'Sumut', 'Sumatera Utara'),
    array(360, 'Sumbar', 'Sumatera Barat'),
    array(360, 'Riau', 'Riau'),
    array(360, 'Jambi', 'Jambi'),
    array(360, 'Sumsel', 'Sumatera Selatan'),
    array(360, 'Bengkulu', 'Bengkulu'),
    array(360, 'Lampung', 'Lampung'),
    array(360, 'Babel', 'Kepulauan Bangka Belitung'),
    array(360, 'Kepri', 'Kepulauan Riau'),
    array(360, 'DKI', 'DKI Jakarta'),
    array(360, 'Jabar', 'Jawa Barat'),
    array(360, 'Jateng', 'Jawa Tengah'),
    array(360, 'DIY', 'Daista Yogyakarta'),
    array(360, 'Jatim', 'Jawa Timur'),
    array(360, 'Banten', 'Banten'),
    array(360, 'Bali', 'Bali'),
    array(360, 'NTB', 'Nusa Tenggara Barat'),
    array(360, 'NTT', 'Nusa Tenggara Timur'),
    array(360, 'Kalbar', 'Kalimantan Barat'),
    array(360, 'Kalteng', 'Kalimantan Tengah'),
    array(360, 'Kalsel', 'Kalimantan Selatan'),
    array(360, 'Kaltim', 'Kalimantan Timur'),
    array(360, 'Sulut', 'Sulawesi Utara'),
    array(360, 'Sulteng', 'Sulawesi Tengah'),
    array(360, 'Sulsel', 'Sulawesi Selatan'),
    array(360, 'Sultra', 'Sulawesi Tenggara'),
    array(360, 'Gorontalo', 'Gorontalo'),
    array(360, 'Sulbar', 'Sulawesi Barat'),
    array(360, 'Maluku', 'Maluku'),
    array(360, 'Malut', 'Maluku Utara'),
    array(360, 'Papua', 'Papua'),
    array(360, 'Irjabar', 'Irian Jaya Barat'),
  );

  foreach ($zones as $zone) {
    db_query("INSERT INTO {uc_zones} (zone_country_id, zone_code, zone_name) VALUES (%d, '%s', '%s')", $zone);
  }

  variable_set('uc_address_format_360',
               "!company\n!first_name !last_name\n!street1\n!street2\n!city !postal_code \n!country_name_if");
}
