<function name="rpcf_get_tariffs_list" id="0x3010"> <input> </input> <output> <integer name="tariffs_count" /> <for name="i" from="0" count="tariffs_count"> <integer name="id" array_index="i" /> <string name="name" array_index="i" /> <integer name="create_date" array_index="i" /> <integer name="who_create" array_index="i" /> <string name="login" array_index="i" /> <integer name="change_create" array_index="i" /> <integer name="who_change" array_index="i" /> <string name="login_change" array_index="i" /> <integer name="expire_date" array_index="i" /> <integer name="is_blocked" array_index="i" /> <integer name="balance_rollover" array_index="i" /> </for> </output> </function>
function rpcf_get_tariffs_list() { //0x3010 $ret=array(); if (!$this->connection->urfa_call(0x3010)) { print "Error calling function ". __FUNCTION__ ."\n"; return FALSE; } $x = $this->connection->urfa_get_data();// Tariff count $count = $x->DataGetInt(); $ret['count'] = $count; for ($i=0;$i<$count;$i++) { // $x = $this->connection->urfa_get_data(); $tariff['id']=$x->DataGetInt(); $tariff['name']=$x->DataGetString(); $tariff['create_date']=$x->DataGetInt(); $tariff['who_create']=$x->DataGetInt(); $tariff['login']=$x->DataGetString(); $tariff['change_create']=$x->DataGetInt(); $tariff['who_change']=$x->DataGetInt(); $tariff['login_change']=$x->DataGetString(); $tariff['expire_date']=$x->DataGetInt(); $tariff['is_blocked']=$x->DataGetInt(); $tariff['balance_rollover']=$x->DataGetInt(); $ret['tariffs'][]=$tariff; } // $this->connection->urfa_get_data(); return $ret; }