Changeset 883

Show
Ignore:
Timestamp:
07/11/08 04:15:31 (2 months ago)
Author:
areski
Message:

add description + little change on agi-conf for card group

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/admin/Public/form_data/FG_var_card_group.inc

    r858 r883  
    22 
    33 
    4 getpost_ifset(array('id', 'name', 'id_agi_conf')); 
     4getpost_ifset(array('id', 'name', 'id_agi_conf', 'description')); 
    55 
    66 
     
    2424 
    2525 
    26  
     26$DBHandle  = DbConnect(); 
     27$conf_table = new Table("cc_config_group", "group_title"); 
     28$clause_conf_agi = "cc_config_group.group_title LIKE 'agi_conf_%'"; 
     29$result_config= $conf_table -> Get_list ($DBHandle, $clause_conf_agi, null, null, null, null, null, null); 
     30$agi_list = array(); 
     31$agi_list[-1] = array( gettext("NOT DEFINED"), "-1"); 
     32foreach ($result_config as $value){ 
     33        $agi_list[substr($value["group_title"],8)] = array($value["group_title"], substr($value["group_title"],8));      
     34
    2735 
    2836$HD_Form -> AddViewElement(gettext("NAME"), "name", "25%", "center", "sort"); 
    29 $HD_Form -> AddViewElement(gettext("AGI CONF"), "id_agi_conf", "25%", "center", "sort"); 
    30 $HD_Form -> FieldViewElement ( 'name, id_agi_conf'); 
     37$HD_Form -> AddViewElement(gettext("AGI CONF"), "id_agi_conf", "20%", "center", "sort", "30", "list", $agi_list); 
     38$HD_Form -> AddViewElement(gettext("DESCRIPTION"), "description", "25%", "center", "SORT", "40"); 
     39$HD_Form -> FieldViewElement ( 'name, id_agi_conf, description'); 
    3140 
    3241 
     
    3847 
    3948 
    40 $DBHandle  = DbConnect(); 
    41 $conf_table = new Table("cc_config_group", "group_title"); 
    42 $clause_conf_agi = "cc_config_group.group_title LIKE 'agi_conf_%'"; 
    43 $result_config= $conf_table -> Get_list ($DBHandle, $clause_conf_agi, null, null, null, null, null, null); 
    44 $agi_list = array(); 
    45 $i=1; 
    46 $agi_list["0"] = array( gettext("NOT DEFINED"), "-1"); 
    47 foreach ($result_config as $value){ 
    48 $agi_list[i] = array($value["group_title"], substr($value["group_title"],8));    
    49 $i++; 
    50 } 
    51  
    5249 
    5350$HD_Form -> FG_EDITION = true; 
     
    5653 
    5754$HD_Form -> AddEditElement ( gettext("NAME"),    
    58                 "name", '$value',        
    59                 "INPUT", 
    60                 "size= maxlength=40", 
    61                 "0", 
    62                 gettext("Insert the provider name"),  
    63                 "" , "", "",    "", "", "", "", "" ); 
     55        "name", '$value',        
     56        "INPUT", 
     57        "size= maxlength=40", 
     58        "0", 
     59        gettext("Insert the provider name"),  
     60        "" , "", "",    "", "", "", "", "" ); 
     61 
    6462$HD_Form -> AddEditElement (gettext("AGI CONF"), 
    6563        "id_agi_conf", 
     
    7169        "list" , "", "", "", $agi_list, "%1", "", ""); 
    7270 
    73 $HD_Form -> FieldEditElement ('name, id_agi_conf'); 
     71$HD_Form -> AddEditElement (gettext("DESCRIPTION"), 
     72        "description", 
     73        '', 
     74        "TEXTAREA", 
     75        "cols=50 rows=4", 
     76        "", 
     77        gettext("Insert the description"), 
     78        "" , "", "", "", "" , "", "", ""); 
     79 
     80$HD_Form -> FieldEditElement ('name, id_agi_conf, description'); 
    7481 
    7582 
     
    94101$HD_Form -> FG_GO_LINK_AFTER_ACTION_EDIT = $_SERVER['PHP_SELF']."?atmenu=document&stitle=Document&wh=AC&id="; 
    95102$HD_Form -> FG_GO_LINK_AFTER_ACTION_DELETE = $_SERVER['PHP_SELF']."?atmenu=document&stitle=Document&wh=AC&id="; 
    96 ?> 
     103 
     104 
  • trunk/admin/Public/form_data/FG_var_charge.inc

    r792 r883  
    1313 
    1414$HD_Form_c -> FG_DEBUG = 0; 
    15 // FAQ 
    1615if ($wantinclude==1) $HD_Form_c -> FG_TABLE_DEFAULT_ORDER = $order; 
    1716else $HD_Form_c -> FG_TABLE_DEFAULT_ORDER = "id_cc_card"; 
     
    3130 
    3231 
    33 $currency_list=Constants::getCurrenciesList(); 
     32$currency_list = Constants::getCurrenciesList(); 
    3433$currency_list_r = Constants::getCurrenciesRateList(); 
    3534$currency_list_key = Constants::getCurrenciesKeyList() ; 
  • trunk/admin/Public/form_data/FG_var_log_viewer.inc

    r1 r883  
    11<?php 
     2 
    23getpost_ifset(array('id', 'loglevel', 'enteradmin', 'Period', 'frommonth', 'fromstatsmonth', 'tomonth', 'tostatsmonth', 'fromday', 'fromstatsday_sday', 'fromstatsmonth_sday', 'today', 'tostatsday_sday', 'tostatsmonth_sday', 'stitle', 'atmenu', 'current_page', 'order', 'sens','popup_select')); 
    34 
     
    158159$HD_Form -> FG_GO_LINK_AFTER_ACTION_DELETE = $_SERVER['PHP_SELF']."?atmenu=document&stitle=Document&wh=AC&id="; 
    159160 
    160 ?> 
  • trunk/DataBase/mysql-5.x/UPDATE-a2billing-v1.3.0-to-v1.4.0-mysql.sql

    r882 r883  
    961961 
    962962CREATE TABLE cc_card_group ( 
    963         id INT NOT NULL AUTO_INCREMENT , 
    964         name CHAR( 30 ) NOT NULL collate utf8_bin , 
    965         id_agi_conf INT NOT NULL , 
     963        id                                      INT NOT NULL AUTO_INCREMENT , 
     964        name                            CHAR( 30 ) NOT NULL collate utf8_bin , 
     965        id_agi_conf             INT NOT NULL , 
     966        description             MEDIUMTEXT CHARACTER  
    966967        PRIMARY KEY ( id ) 
    967968) ENGINE = MYISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin; 
     
    10131014ALTER TABLE cc_logpayment ADD description MEDIUMTEXT CHARACTER SET utf8 COLLATE utf8_bin NULL ; 
    10141015ALTER TABLE cc_logrefill ADD description MEDIUMTEXT CHARACTER SET utf8 COLLATE utf8_bin NULL ; 
     1016 
  • trunk/DataBase/psql/UPDATE-a2billing-v1.3.0-to-v1.4.0-pgsql.sql

    r882 r883  
    947947 
    948948CREATE TABLE cc_agent_tariffgroup ( 
    949 id_agent bigint NOT NULL , 
    950 id_tariffgroup integer NOT NULL, 
    951 CONSTRAINT cc_agent_tariffgroup_pkey PRIMARY KEY (id_agent, id_tariffgroup) 
     949       id_agent bigint NOT NULL , 
     950       id_tariffgroup integer NOT NULL, 
     951       CONSTRAINT cc_agent_tariffgroup_pkey PRIMARY KEY (id_agent, id_tariffgroup) 
    952952); 
    953953 
     
    958958-- Card Group      
    959959CREATE TABLE cc_card_group ( 
    960 id                      serial NOT NULL , 
    961 name            character varying( 30 ) NOT NULL , 
    962 id_agi_conf integer NOT NULL , 
    963 CONSTRAINT cc_card_group_pkey PRIMARY KEY (id) 
     960        id                      serial NOT NULL , 
     961        name            character varying( 30 ) NOT NULL , 
     962        id_agi_conf integer NOT NULL , 
     963        description text, 
     964        CONSTRAINT cc_card_group_pkey PRIMARY KEY (id) 
    964965) ; 
    965966 
     
    971972ALTER TABLE cc_card ADD id_group integer NOT NULL DEFAULT 1; 
    972973 
     974 
    973975-- new syteme of package based on group 
    974  
    975  CREATE TABLE cc_package_group ( 
    976 id                              serial NOT NULL  , 
    977 name                    character varying( 30 )  NOT NULL , 
    978 description     text , 
    979 CONSTRAINT cc_package_group_pkey PRIMARY KEY (id) 
     976CREATE TABLE cc_package_group ( 
     977        id                              serial NOT NULL  , 
     978        name                    character varying( 30 )  NOT NULL , 
     979        description     text , 
     980        CONSTRAINT cc_package_group_pkey PRIMARY KEY (id) 
    980981) ; 
    981982 
    982  CREATE TABLE cc_packgroup_package ( 
    983 packagegroup_id       integer NOT NULL , 
    984 package_id            integer NOT NULL , 
    985 CONSTRAINT cc_packgroup_package_pkey PRIMARY KEY  ( packagegroup_id , package_id ) 
    986 )
     983CREATE TABLE cc_packgroup_package ( 
     984       packagegroup_id        integer NOT NULL , 
     985       package_id             integer NOT NULL , 
     986       CONSTRAINT cc_packgroup_package_pkey PRIMARY KEY  ( packagegroup_id , package_id ) 
     987)
    987988 
    988989CREATE TABLE cc_package_rate ( 
    989 package_id integer NOT NULL , 
    990 rate_id integer NOT NULL , 
    991 CONSTRAINT cc_package_rate_pkey PRIMARY KEY  ( package_id , rate_id ) 
    992 )
     990       package_id integer NOT NULL , 
     991       rate_id integer NOT NULL , 
     992       CONSTRAINT cc_package_rate_pkey PRIMARY KEY  ( package_id , rate_id ) 
     993)
    993994 
    994995 
     
    997998 ( 'Max Time For Free Calls', 'maxtime_tofree_calls', '5400', 'For free calls, limit the duration: amount in seconds .', '0', '11', NULL); 
    998999 
    999  ALTER TABLE cc_ratecard DROP freetimetocall_package_offer;  
     1000ALTER TABLE cc_ratecard DROP freetimetocall_package_offer;  
     1001 
    10001002-- add additionnal grace to the ratecard 
    1001  
    10021003ALTER TABLE cc_ratecard ADD additional_grace integer NOT NULL DEFAULT 0; 
    10031004 
     
    10081009ALTER TABLE cc_logpayment ADD description text  ; 
    10091010ALTER TABLE cc_logrefill ADD description text  ; 
     1011 
     1012 
     1013 


Google