Changeset 22619


Ignore:
Timestamp:
2013/03/09 15:15:18 (7 years ago)
Author:
AMUAMU
Message:

税ルールテーブル(仮)とヘルパー(仮)

Location:
branches/camp/camp-2_13-tax
Files:
2 added
5 edited

Legend:

Unmodified
Added
Removed
  • branches/camp/camp-2_13-tax/html/install/index.php

    r22567 r22619  
    11191119        array('dtb_api_config', 'api_config_id'), 
    11201120        array('dtb_api_account', 'api_account_id'), 
     1121        array('dtb_tax_rule', 'tax_rule_id'), 
    11211122    ); 
    11221123} 
  • branches/camp/camp-2_13-tax/html/install/sql/create_table_mysql.sql

    r22218 r22619  
    12041204); 
    12051205 
     1206CREATE TABLE dtb_tax_rule ( 
     1207    tax_rule_id int NOT NULL, 
     1208    country_id int NOT NULL DEFAULT 0, 
     1209    pref_id int NOT NULL DEFAULT 0, 
     1210    product_id int NOT NULL DEFAULT 0, 
     1211    product_class_id int NOT NULL DEFAULT 0, 
     1212    calc_rule smallint NOT NULL DEFAULT 1, 
     1213    tax_rate numeric NOT NULL DEFAULT 5, 
     1214    tax_adjust numeric NOT NULL DEFAULT 0, 
     1215    apply_date timestamp, 
     1216    del_flg smallint NOT NULL DEFAULT 0, 
     1217    create_date timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, 
     1218    update_date timestamp NOT NULL, 
     1219    PRIMARY KEY (tax_rule_id) 
     1220); 
     1221 
    12061222 
    12071223CREATE INDEX dtb_customer_mobile_phone_id_key ON dtb_customer (mobile_phone_id(255)); 
  • branches/camp/camp-2_13-tax/html/install/sql/create_table_pgsql.sql

    r22218 r22619  
    12041204); 
    12051205 
     1206CREATE TABLE dtb_tax_rule ( 
     1207    tax_rule_id int NOT NULL, 
     1208    country_id int NOT NULL DEFAULT 0, 
     1209    pref_id int NOT NULL DEFAULT 0, 
     1210    product_id int NOT NULL DEFAULT 0, 
     1211    product_class_id int NOT NULL DEFAULT 0, 
     1212    calc_rule smallint NOT NULL DEFAULT 1, 
     1213    tax_rate numeric NOT NULL DEFAULT 5, 
     1214    tax_adjust numeric NOT NULL DEFAULT 0, 
     1215    apply_date timestamp, 
     1216    del_flg smallint NOT NULL DEFAULT 0, 
     1217    create_date timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP, 
     1218    update_date timestamp NOT NULL, 
     1219    PRIMARY KEY (tax_rule_id) 
     1220); 
     1221 
    12061222 
    12071223CREATE INDEX dtb_customer_mobile_phone_id_key ON dtb_customer (mobile_phone_id); 
  • branches/camp/camp-2_13-tax/html/install/sql/drop_table.sql

    r21942 r22619  
    9696DROP TABLE dtb_api_config; 
    9797DROP TABLE dtb_api_account; 
     98DROP TABLE dtb_tax_rule; 
  • branches/camp/camp-2_13-tax/html/install/sql/insert_data.sql

    r22551 r22619  
    12791279INSERT INTO dtb_index_list (table_name, column_name, recommend_flg, recommend_comment) VALUES ('dtb_product_categories', 'category_id', 2, 'カテゴリが多いときに試してみてください。'); 
    12801280INSERT INTO dtb_index_list (table_name, column_name, recommend_flg, recommend_comment) VALUES ('mtb_zip', 'zipcode', 2, '郵便番号検索が遅いときに試してみてください。郵便番号データの更新時には無効にしていることをおすすめします。'); 
     1281INSERT INTO dtb_tax_rule (tax_rule_id, country_id, pref_id, product_id, product_class_id, calc_rule, tax_rate, tax_adjust, apply_date, del_flg, create_date,update_date) VALUES (0, 0, 0, 0, 0, 1, 5, 0, NULL, 0, CURRENT_TIMESTAMP,CURRENT_TIMESTAMP); 
Note: See TracChangeset for help on using the changeset viewer.