Code Monkey home page Code Monkey logo

Comments (2)

Cramac avatar Cramac commented on September 2, 2024

вот что удалось мне самому сварганить, полурабочее:

	<function name="rpcf_user5_get_turbo_mode_settings" id="-0x1200c">
        <input>
            <integer name="slink_id"/>
        </input>
        <output>
		    <integer name="cnt"/>
            <for name="i" from="0" count="cnt">
				<integer name="id" array_index="i"/>
				<string name="name" array_index="i"/>
				<integer name="incoming_rate" array_index="i"/>
				<integer name="outgoing_rate" array_index="i"/>
				<long name="incoming_limit" array_index="i"/>
				<long name="outgoing_limit" array_index="i"/>
				<double name="cost" array_index="i"/>
			</for>
        </output>
    </function>

в ЛК от утм это выглядит так:

                $this->urfa->call(-0x1200c);
                $this->urfa->put_int($this->slink_id);
                $this->urfa->send();

                $modesCnt = $this->urfa->get_int();

                $modes = array();

                for($m = 0; $m < $modesCnt; $m++){
                    $modes[$m] = array();
                    $modes[$m]['id'] = $this->urfa->get_int();
                    $modes[$m]['name'] = $this->urfa->get_string();
                    $modes[$m]['incoming_rate'] = $this->urfa->get_int();
                    $modes[$m]['outgoing_rate'] = $this->urfa->get_int();

                    if($modes[$m]['incoming_rate'] == 0)
                        $modes[$m]['incoming_rate'] = $modes[$m]['outgoing_rate'];

                    if($modes[$m]['outgoing_rate'] == 0)
                        $modes[$m]['outgoing_rate'] = $modes[$m]['incoming_rate'];

                    $isDuration = $this->urfa->get_int();
                    if($isDuration)
                        $modes[$m]['duration'] = $this->urfa->get_int();
                    else {
                        $modes[$m]['incoming_limit'] = $this->urfa->get_long();
                        $modes[$m]['outgoing_limit'] = $this->urfa->get_long();
                    }

                    $modes[$m]['cost'] = $this->urfa->get_double();
                }

                $this->urfa->finish();

from urfaclient.

k-shym avatar k-shym commented on September 2, 2024

Функция есть, её номер -0x1200b
-0x1200c эта версия для личного кабинета, вы можете добавить её в свой api.xml

from urfaclient.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.