当前位置: 首页>>代码示例>>PHP>>正文


PHP wf_Link函数代码示例

本文整理汇总了PHP中wf_Link函数的典型用法代码示例。如果您正苦于以下问题:PHP wf_Link函数的具体用法?PHP wf_Link怎么用?PHP wf_Link使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了wf_Link函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: render

 public function render()
 {
     $cells = wf_TableCell(__('ID'));
     $cells .= wf_TableCell(__('Date'));
     $cells .= wf_TableCell(__('Text'));
     $cells .= wf_TableCell(__('Processed'));
     $cells .= wf_TableCell(__('Actions'));
     $rows = wf_TableRow($cells, 'row1');
     if (!empty($this->alltickets)) {
         foreach ($this->alltickets as $io => $each) {
             $cells = wf_TableCell($each['id']);
             $cells .= wf_TableCell($each['date']);
             if (strlen($each['text']) > 140) {
                 $textPreview = mb_substr(strip_tags($each['text']), 0, 140, 'utf-8') . '...';
             } else {
                 $textPreview = strip_tags($each['text']);
             }
             $cells .= wf_TableCell($textPreview);
             $cells .= wf_TableCell(web_bool_led($each['status']));
             $cells .= wf_TableCell(wf_Link('?module=ticketing&showticket=' . $each['id'], __('Show'), false, 'ubButton'));
             $rows .= wf_TableRow($cells, 'row3');
         }
     }
     $result = wf_TableBody($rows, '100%', 0, 'sortable');
     return $result;
 }
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:26,代码来源:index.php

示例2: web_CardShowUsageByMonth

 /**
  * Renders search results for used cards
  * 
  * @param int $year
  * @param string $month
  * 
  * @return void
  */
 function web_CardShowUsageByMonth($year, $month)
 {
     $month = mysql_real_escape_string($month);
     $year = mysql_real_escape_string($year);
     $query = "SELECT * from `cardbank` WHERE `usedate` LIKE '%" . $year . "-" . $month . "-%'";
     $allusedcards = simple_queryall($query);
     $allrealnames = zb_UserGetAllRealnames();
     $alladdress = zb_AddressGetFulladdresslist();
     $totalsumm = 0;
     $totalcount = 0;
     $csvdata = '';
     $tablecells = wf_TableCell(__('ID'));
     $tablecells .= wf_TableCell(__('Serial number'));
     $tablecells .= wf_TableCell(__('Cash'));
     $tablecells .= wf_TableCell(__('Usage date'));
     $tablecells .= wf_TableCell(__('Used login'));
     $tablecells .= wf_TableCell(__('Full address'));
     $tablecells .= wf_TableCell(__('Real name'));
     $tablerows = wf_TableRow($tablecells, 'row1');
     if (!empty($allusedcards)) {
         $csvdata = __('ID') . ';' . __('Serial number') . ';' . __('Cash') . ';' . __('Usage date') . ';' . __('Used login') . ';' . __('Full address') . ';' . __('Real name') . "\n";
         foreach ($allusedcards as $io => $eachcard) {
             $tablecells = wf_TableCell($eachcard['id']);
             $tablecells .= wf_TableCell($eachcard['serial']);
             $tablecells .= wf_TableCell($eachcard['cash']);
             $tablecells .= wf_TableCell($eachcard['usedate']);
             $profilelink = wf_Link("?module=userprofile&username=" . $eachcard['usedlogin'], web_profile_icon() . ' ' . $eachcard['usedlogin'], false);
             $tablecells .= wf_TableCell($profilelink);
             @($useraddress = $alladdress[$eachcard['usedlogin']]);
             $tablecells .= wf_TableCell($useraddress);
             @($userrealname = $allrealnames[$eachcard['usedlogin']]);
             $tablecells .= wf_TableCell($userrealname);
             $tablerows .= wf_TableRow($tablecells, 'row3');
             $totalcount++;
             $totalsumm = $totalsumm + $eachcard['cash'];
             $csvdata .= $eachcard['id'] . ';' . $eachcard['serial'] . ';' . $eachcard['cash'] . ';' . $eachcard['usedate'] . ';' . $eachcard['usedlogin'] . ';' . $useraddress . ';' . $userrealname . "\n";
         }
     }
     if (!empty($csvdata)) {
         $exportFilename = 'exports/cardreport_' . $year . '-' . $month . '.csv';
         $csvdata = iconv('utf-8', 'windows-1251', $csvdata);
         file_put_contents($exportFilename, $csvdata);
         $exportLink = wf_Link('?module=cardreport&dloadcsv=' . base64_encode($exportFilename), wf_img('skins/excel.gif', __('Export')), false, '');
     } else {
         $exportLink = '';
     }
     $result = wf_TableBody($tablerows, '100%', '0', 'sortable');
     $result .= __('Total') . ': ' . $totalcount . ' ' . __('payments') . ', ' . __('with total amount') . ': ' . $totalsumm;
     show_window(__('Payment cards usage report') . ' ' . $exportLink, $result);
 }
开发者ID:nightflyza,项目名称:Ubilling,代码行数:58,代码来源:index.php

示例3: multinet_show_serviceeditform

function multinet_show_serviceeditform($serviceid)
{
    $serviceid = vf($serviceid);
    $servicedata = multinet_get_service_params($serviceid);
    $form = '
        <form action="" method="POST" class="glamour">
        <input type="hidden" name="serviceedit" value="true">
        ' . multinet_network_selector($servicedata['netid']) . ' ' . __('Service network') . ' <br>
        <input type="text" name="editservicename" size="15" value="' . $servicedata['desc'] . '"> ' . __('Service description') . '<sup>*</sup> <br>
        <input type="submit" value="' . __('Save') . '">
        </form>
         <div style="clear:both;"></div>
        ';
    $form .= wf_Link('?module=multinet', 'Back', true, 'ubButton');
    show_window(__('Edit'), $form);
}
开发者ID:nightflyza,项目名称:Ubilling,代码行数:16,代码来源:api.networking.php

示例4: ajaxGetData

 /**
  * Returns JSON reply for jquery datatables with full list of available UHW usages
  * 
  * @return string
  */
 public function ajaxGetData()
 {
     $query = "SELECT * from `uhw_log` ORDER by `id` DESC;";
     $alluhw = simple_queryall($query);
     $alladdress = zb_AddressGetFulladdresslist();
     $allrealnames = zb_UserGetAllRealnames();
     $result = '{ 
               "aaData": [ ';
     if (!empty($alluhw)) {
         foreach ($alluhw as $io => $each) {
             $profileLink = wf_Link('?module=userprofile&username=' . $each['login'], web_profile_icon() . ' ' . $each['login'], false);
             $profileLink = str_replace('"', '', $profileLink);
             $profileLink = str_replace("'", '', $profileLink);
             $profileLink = trim($profileLink);
             $userAddress = @$alladdress[$each['login']];
             $userAddress = str_replace("'", '`', $userAddress);
             $userAddress = str_replace('"', '``', $userAddress);
             $userAddress = trim($userAddress);
             $userRealname = @$allrealnames[$each['login']];
             $userRealname = str_replace("'", '`', $userRealname);
             $userRealname = str_replace('"', '``', $userRealname);
             $userRealname = trim($userRealname);
             $result .= '
                 [
                 "' . $each['id'] . '",
                 "' . $each['date'] . '",
                 "' . $each['password'] . '",
                 "' . $profileLink . '",
                 "' . $userAddress . '",
                 "' . $userRealname . '",
                 "' . $each['ip'] . '",
                 "' . $each['nhid'] . '",
                 "' . $each['oldmac'] . '",
                 "' . $each['newmac'] . '"
                 ],';
         }
     }
     $result = substr($result, 0, -1);
     $result .= '] 
     }';
     return $result;
 }
开发者ID:nightflyza,项目名称:Ubilling,代码行数:47,代码来源:api.uhw.php

示例5: web_UsersLister

 function web_UsersLister($users)
 {
     $tablecells = wf_TableCell(__('Login'));
     $tablecells .= wf_TableCell(__('Real Name'));
     $tablecells .= wf_TableCell(__('Full address'));
     $tablecells .= wf_TableCell(__('Tariff'));
     $tablecells .= wf_TableCell(__('Tariff speeds'));
     $tablecells .= wf_TableCell(__('Speed override'));
     $tablecells .= wf_TableCell(__('Actions'));
     $tablerows = wf_TableRow($tablecells, 'row1');
     if (!empty($users)) {
         $udata = array();
         $alluserdata = zb_UserGetAllStargazerData();
         $alladdress = zb_AddressGetFulladdresslist();
         $allrealnames = zb_UserGetAllRealnames();
         $allspeeds = zb_TariffGetAllSpeeds();
         if (!empty($alluserdata)) {
             foreach ($alluserdata as $ia => $eachdata) {
                 $udata[$eachdata['login']]['Tariff'] = $eachdata['Tariff'];
                 @($udata[$eachdata['login']]['Address'] = $alladdress[$eachdata['login']]);
                 @($udata[$eachdata['login']]['RealName'] = $allrealnames[$eachdata['login']]);
                 @($udata[$eachdata['login']]['NormalSpeedDown'] = $allspeeds[$eachdata['Tariff']]['speeddown']);
                 @($udata[$eachdata['login']]['NormalSpeedUp'] = $allspeeds[$eachdata['Tariff']]['speedup']);
             }
         }
         foreach ($users as $io => $eachuser) {
             $tablecells = wf_TableCell(wf_Link('?module=userprofile&username=' . $eachuser['login'], web_profile_icon() . ' ' . $eachuser['login']));
             $tablecells .= wf_TableCell($udata[$eachuser['login']]['RealName']);
             $tablecells .= wf_TableCell($udata[$eachuser['login']]['Address']);
             $tablecells .= wf_TableCell($udata[$eachuser['login']]['Tariff']);
             $tablecells .= wf_TableCell($udata[$eachuser['login']]['NormalSpeedDown'] . '/' . $udata[$eachuser['login']]['NormalSpeedUp']);
             $tablecells .= wf_TableCell(zb_UserGetSpeedOverride($eachuser['login']));
             $fixlink = wf_JSAlert('?module=speedcontrol&fix=' . $eachuser['login'], '<img src="skins/icon_repair.gif" title=' . __('Fix') . '>', 'Are you serious');
             $tablecells .= wf_TableCell($fixlink);
             $tablerows .= wf_TableRow($tablecells, 'row3');
         }
     }
     $result = wf_TableBody($tablerows, '100%', '0', 'sortable');
     return $result;
 }
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:40,代码来源:index.php

示例6: web_PhpConsoleShowTemplates

 function web_PhpConsoleShowTemplates()
 {
     $alltemplatekeys = zb_StorageFindKeys('PHPCONSOLETEMPLATE:');
     $tablecells = wf_TableCell(__('Template'), '80%');
     $tablecells .= wf_TableCell(__('Actions'));
     $tablerows = wf_TableRow($tablecells, 'row1');
     if (!empty($alltemplatekeys)) {
         foreach ($alltemplatekeys as $eachtemplatekey) {
             $templatearray = zb_PhpConsoleGetTemplate($eachtemplatekey['key']);
             $templatename = $templatearray['name'];
             $templatebody = $templatearray['body'];
             //show code template
             $runlink = wf_JSAlert('?module=sqlconsole&devconsole=true&runtpl=' . $eachtemplatekey['key'], $templatename, 'Insert this template into PHP console');
             $tablecells = wf_TableCell($runlink);
             $actionlinks = wf_JSAlert('?module=sqlconsole&devconsole=true&deltemplate=' . $eachtemplatekey['key'], web_delete_icon(), 'Are you serious');
             $actionlinks .= wf_Link('?module=sqlconsole&devconsole=true&edittemplate=' . $eachtemplatekey['key'], web_edit_icon());
             $tablecells .= wf_TableCell($actionlinks);
             $tablerows .= wf_TableRow($tablecells, 'row3');
         }
     }
     $createlink = __('Available code templates') . ' ' . wf_Link("?module=sqlconsole&devconsole=true&templateadd=true", wf_img("skins/icon_add.gif", __('Create')), false);
     $result = $createlink . ' ' . wf_TableBody($tablerows, '100%', '0', 'sortable');
     return $result;
 }
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:24,代码来源:index.php

示例7: web_NasTemplatesShow

function web_NasTemplatesShow()
{
    $query = "SELECT * from `nastemplates`";
    $alltemplates = simple_queryall($query);
    $tablecells = wf_TableCell(__('ID'));
    $tablecells .= wf_TableCell(__('NAS'));
    $tablecells .= wf_TableCell(__('Template'));
    $tablecells .= wf_TableCell(__('Actions'));
    $tablerows = wf_TableRow($tablecells, 'row1');
    if (!empty($alltemplates)) {
        foreach ($alltemplates as $io => $eachtemplate) {
            $nasdata = zb_NasGetData($eachtemplate['nasid']);
            $tablecells = wf_TableCell($eachtemplate['id']);
            $tablecells .= wf_TableCell($eachtemplate['nasid'] . ':' . $nasdata['nasname']);
            $tablecells .= wf_TableCell('<pre>' . $eachtemplate['template'] . '</pre>');
            $actions = wf_JSAlert("?module=radiust&delete=" . $eachtemplate['id'], web_delete_icon(), 'Are you serious');
            $actions .= wf_Link("?module=radiust&edit=" . $eachtemplate['id'], web_edit_icon(), false, '');
            $tablecells .= wf_TableCell($actions);
            $tablerows .= wf_TableRow($tablecells, 'row3');
        }
    }
    $result = wf_TableBody($tablerows, '100%', '0', 'sortable');
    show_window(__('Available NAS Radius attribute templates'), $result);
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:24,代码来源:api.radius.php

示例8: foreach

     foreach ($results as $result) {
         $cells = wf_TableCell($result['id']);
         $cells .= wf_TableCell($result['scenario']);
         $cells .= wf_TableCell($result['Attribute']);
         $cells .= wf_TableCell($result['op']);
         $cells .= wf_TableCell($result['Value']);
         $content = web_bool_led($result['login'] == '*');
         $cells .= wf_TableCell($content);
         $content = wf_Link("?module=freeradius&netid={$netid}&edit=" . $result['id'], web_edit_icon());
         $content .= wf_JSAlert("?module=freeradius&netid={$netid}&delete=" . $result['id'], web_delete_icon(), 'Are you serious');
         $cells .= wf_TableCell($content);
         $rows .= wf_TableRow($cells, 'row3');
     }
 }
 /* Кнопка "Назад" */
 $html .= wf_Link("?module=multinet", __('Back'), false, 'ubButton');
 // Форма добавления нового атрибута
 $form = new InputForm('', 'POST', __('Save'), '', '', '', 'add');
 //  - Сценарий
 $content = $form->radio_button('add[scenario]', $scenarios, 'check');
 $form->addrow(__('Scenario'), $content);
 //  - Сервис (disabled)
 $content = $form->select_tag('add[netid]', getServiceIdDesc(), $netid, 'disabled');
 $content .= $form->checkbox('add[login]', '*', __('Foreach'), '');
 $form->addrow(__('Service'), $content);
 //  - Атрибут
 $content = $form->text_box('add[Attribute]', '');
 $form->addrow(__('Attribute'), $content);
 //  - Оператор
 $content = $form->select_tag('add[op]', $operators, '');
 $form->addrow(__('op'), $content);
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:31,代码来源:index.php

示例9: show_window

                            if (method_exists($corps, $beggar['BU']['F'])) {
                                $corpAttachControls = $corps->{$beggar}['BU']['F']($login);
                                show_window(__('Private user'), $corpAttachControls);
                            }
                            if (method_exists($corps, $beggar['BU']['AB'])) {
                                $corpAddAttachControls = $corps->{$beggar}['BU']['AB']($login);
                                show_window(__('Create') . ' ' . __('Corporate user'), $corpAddAttachControls);
                            }
                        }
                    }
                }
                if ($route == Corps::URL_SEARCH) {
                    $searchResults = $corps->searchUsersByCorpName($_POST['searchcorpname']);
                    if (!empty($searchResults)) {
                        show_window(__('Search results'), $searchResults);
                    }
                    show_window('', wf_Link('?module=usersearch', __('Back'), false, 'ubButton'));
                }
            } else {
                //default list route
                rcms_redirect(Corps::URL_CORPS_LIST);
            }
        } else {
            show_error(__('No license key available'));
        }
    } else {
        show_error(__('This module is disabled'));
    }
} else {
    show_error(__('Access denied'));
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:31,代码来源:index.php

示例10: render


//.........这里部分代码省略.........
     $profile .= $this->addRow(__('Full address') . $this->getTaskCreateControl(), $this->useraddress . $this->getBuildControls());
     //apt data like floor and entrance row
     $profile .= $this->addRow(__('Entrance') . ', ' . __('Floor'), @$this->aptdata['entrance'] . ' ' . @$this->aptdata['floor']);
     //realname row
     $profile .= $this->addRow(__('Real name') . $this->getPhotostorageControls() . $this->getPassportDataControl(), $this->realname, true);
     //contract row
     $profile .= $this->addRow(__('Contract'), $this->contract, false);
     //contract date row
     $profile .= $this->getContractDate();
     //assigned agents row
     $profile .= $this->getAgentsControls();
     //old corporate users aka userlinking
     $profile .= $this->getCorporateControls();
     //phone
     $profile .= $this->addRow(__('Phone'), $this->phone);
     //and mobile data rows
     $profile .= $this->addRow(__('Mobile'), $this->mobile);
     //Email data row
     $profile .= $this->addRow(__('Email'), $this->mail);
     //payment ID data
     $profile .= $this->addRow(__('Payment ID'), $this->paymentid, true);
     //LAT data row
     $profile .= $this->getUserLat();
     //login row
     $profile .= $this->addRow(__('Login'), $this->userdata['login'], true);
     //password row
     $profile .= $this->addRow(__('Password'), $this->getUserPassword(), true);
     //User IP data and extended networks controls if available
     $profile .= $this->addRow(__('IP'), $this->userdata['IP'] . $this->getExtNetsControls(), true);
     //MAC address row
     $profile .= $this->addRow(__('MAC') . ' ' . $this->getSearchmacControl() . ' ' . $this->getProfileFdbSearchControl(), $this->mac);
     //User tariff row
     $profile .= $this->addRow(__('Tariff') . $this->getTariffInfoControls($this->userdata['Tariff']), $this->userdata['Tariff'] . $this->getTariffInfoContrainer(), true);
     //Tariff change row
     $profile .= $this->addRow(__('Planned tariff change') . $this->getTariffInfoControls($this->userdata['TariffChange']), $this->userdata['TariffChange']);
     //old CaTv backlink if needed
     $profile .= $this->getCatvBacklinks();
     //Speed override row
     $profile .= $this->addRow(__('Speed override'), $this->speedoverride);
     // signup pricing row
     $profile .= $this->getSignupPricing();
     //User current cash row
     $profile .= $this->addRow(__('Balance'), $this->getUserCash(), true);
     //User credit row & easycredit control if needed
     $profile .= $this->addRow(__('Credit') . ' ' . $this->getEasyCreditController(), $this->userdata['Credit'], true);
     //credit expire row
     $profile .= $this->addRow(__('Credit expire'), $this->getUserCreditExpire());
     //Prepayed traffic
     $profile .= $this->addRow(__('Prepayed traffic'), $this->userdata['FreeMb']);
     //finance activity row
     $profile .= $this->addRow(__('Active') . $this->getCemeteryControls(), $activity);
     //DN online detection row
     $profile .= $this->getUserOnlineDN();
     //Always online flag row
     $profile .= $this->addRow(__('Always Online'), web_trigger($this->userdata['AlwaysOnline']));
     //Detail stats flag row
     $profile .= $this->addRow(__('Disable detailed stats'), web_trigger($this->userdata['DisabledDetailStat']));
     //Frozen aka passive flag row
     $profile .= $this->addRow(__('Freezed'), $passiveicon . web_trigger($this->userdata['Passive']), true);
     //Disable aka Down flag row
     $profile .= $this->addRow(__('Disabled'), $downicon . web_trigger($this->userdata['Down']), true);
     //Connection details  row
     $profile .= $this->getUserConnectionDetails();
     //User notes row
     $profile .= $this->addRow(__('Notes'), zb_UserGetNotes($this->login) . $this->getAdcommentsIndicator());
     $profile .= wf_tag('tbody', true);
     $profile .= wf_tag('table', true);
     $profile .= wf_tag('td', true);
     //end of main profile container
     $profile .= wf_tag('td', false, '', 'valign="top" width="10%"');
     //profile plugins container
     $profile .= $this->plugins;
     $profile .= wf_tag('td', true);
     // end of plugins container
     $profile .= wf_tag('tr', true);
     // close profile+plugins row
     $profile .= wf_tag('tbody', true);
     $profile .= wf_tag('table', true);
     //end of all profile container
     //profile switch port controls
     $profile .= $this->getSwitchAssignControls();
     //profile onu signal controls
     $profile .= $this->getPonSignalControl();
     //profile vlan controls
     $profile .= $this->getVlanAssignControls();
     //profile vlan online
     $profile .= $this->getVlanOnline();
     //Custom filelds display
     $profile .= cf_FieldShower($this->login);
     //Tags add control and exiting tags listing
     if (cfr('TAGS')) {
         $profile .= wf_Link('?module=usertags&username=' . $this->login, web_add_icon(__('Tags')), false);
     }
     $profile .= stg_show_user_tags($this->login);
     //main profile controls here
     $profile .= $this->getMainControls();
     //Profile ending anchor for addcash links scroll
     $profile .= wf_tag('a', false, '', 'id="profileending"') . wf_tag('a', true);
     return $profile;
 }
开发者ID:nightflyza,项目名称:Ubilling,代码行数:101,代码来源:api.userprofile.php

示例11: renderTransactionList

 /**
  * Renders transaction list container
  * 
  * @return void
  */
 public function renderTransactionList()
 {
     $columns = array('ID', 'Date', 'Cash', 'Payment ID', 'Real Name', 'Full address', 'Payment system', 'Processed');
     $graphsUrl = wf_Link(self::URL_CHARTS, wf_img('skins/icon_stats.gif', __('Graphs')), false, '');
     show_window(__('OpenPayz transactions') . ' ' . $graphsUrl, wf_JqDtLoader($columns, self::URL_AJAX_SOURCE, true, 'payments', 100));
 }
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:11,代码来源:api.opayz.php

示例12: simple_update_field

                simple_update_field('switches', 'snmp', $_POST['editsnmp'], "WHERE `id`='" . $switchid . "'");
                simple_update_field('switches', 'geo', $_POST['editgeo'], "WHERE `id`='" . $switchid . "'");
                if ($_POST['editparentid'] != $switchid) {
                    simple_update_field('switches', 'parentid', $_POST['editparentid'], "WHERE `id`='" . $switchid . "'");
                }
                log_register('SWITCH CHANGE [' . $switchid . ']' . ' IP ' . $_POST['editip'] . " LOC `" . $_POST['editlocation'] . "`");
                rcms_redirect("?module=switches&edit=" . $switchid);
            } else {
                show_error(__('Access denied'));
            }
        }
        //render switch edit form
        show_window(__('Edit switch'), web_SwitchEditForm($switchid));
        //minimap container
        if ($altCfg['SWYMAP_ENABLED']) {
            if (!empty($switchdata['geo'])) {
                show_window(__('Mini-map'), wf_delimiter() . web_SwitchMiniMap($switchdata));
            }
        }
        //downlinks list
        web_SwitchDownlinksList($switchid);
        //additional comments engine
        if ($altCfg['ADCOMMENTS_ENABLED']) {
            $adcomments = new ADcomments('SWITCHES');
            show_window(__('Additional comments'), $adcomments->renderComments($switchid));
        }
        show_window('', wf_Link('?module=switches', 'Back', true, 'ubButton'));
    }
} else {
    show_error(__('Access denied'));
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:31,代码来源:index.php

示例13: mysql_real_escape_string

            $nasbwdurl = mysql_real_escape_string($_POST['editnasbwdurl']);
            $netid = vf($_POST['networkselect']);
            simple_update_field('nas', 'nastype', $nastype, $targetnas);
            simple_update_field('nas', 'nasip', $nasip, $targetnas);
            simple_update_field('nas', 'nasname', $nasname, $targetnas);
            simple_update_field('nas', 'bandw', $nasbwdurl, $targetnas);
            simple_update_field('nas', 'netid', $netid, $targetnas);
            zb_NasConfigSave();
            log_register("NAS EDIT " . $nasip);
            rcms_redirect("?module=nas&edit=" . $nasid);
        }
        $nasdata = zb_NasGetData($nasid);
        $currentnetid = $nasdata['netid'];
        $currentnasip = $nasdata['nasip'];
        $currentnasname = $nasdata['nasname'];
        $currentnastype = $nasdata['nastype'];
        $currentbwdurl = $nasdata['bandw'];
        $nastypes = array('local' => 'Local NAS', 'rscriptd' => 'rscriptd', 'mikrotik' => 'MikroTik', 'radius' => 'Radius');
        $editinputs = multinet_network_selector($currentnetid) . "<br>";
        $editinputs .= wf_Selector('editnastype', $nastypes, 'NAS type', $currentnastype, true);
        $editinputs .= wf_TextInput('editnasip', 'IP', $currentnasip, true, '15');
        $editinputs .= wf_TextInput('editnasname', 'NAS name', $currentnasname, true, '15');
        $editinputs .= wf_TextInput('editnasbwdurl', 'Bandwidthd URL', $currentbwdurl, true, '25');
        $editinputs .= wf_Submit('Save');
        $editform = wf_Form('', 'POST', $editinputs, 'glamour');
        show_window(__('Edit') . ' NAS', $editform);
        show_window('', wf_Link("?module=nas", 'Back', true, 'ubButton'));
    }
} else {
    show_error(__('You cant control this module'));
}
开发者ID:nightflyza,项目名称:Ubilling,代码行数:31,代码来源:index.php

示例14: web_CityEditForm

/**
 * Returns existing city editing form
 * 
 * @param int $cityid
 * @return string
 */
function web_CityEditForm($cityid)
{
    $citydata = zb_AddressGetCityData($cityid);
    $cityname = $citydata['cityname'];
    $cityalias = $citydata['cityalias'];
    $sup = wf_tag('sup') . '*' . wf_tag('sup', true);
    $inputs = wf_TextInput('editcityname', __('City name') . $sup, $cityname, true);
    $inputs .= wf_TextInput('editcityalias', __('City alias'), $cityalias, true);
    $inputs .= wf_Submit(__('Save'));
    $form = wf_Form('', 'POST', $inputs, 'glamour');
    $form .= wf_Link('?module=city', 'Back', true, 'ubButton');
    return $form;
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:19,代码来源:api.address.php

示例15: reportStreets

 /**
  * renders streets report
  * 
  * @return void
  */
 public function reportStreets()
 {
     $ukvCities = array();
     $ukvStreets = array();
     //loads cities and streets occupied by UKV users
     $ukvCities_q = "SELECT DISTINCT `city` from `ukv_users` ORDER BY `city` ASC";
     $ukvCitiesRaw = simple_queryall($ukvCities_q);
     if (!empty($ukvCitiesRaw)) {
         foreach ($ukvCitiesRaw as $ieuc => $euc) {
             $ukvCities[$euc['city']] = $euc['city'];
         }
     }
     $ukvStreets_q = "SELECT DISTINCT `street` from `ukv_users` ORDER BY `street` ASC";
     $ukvStreetsRaw = simple_queryall($ukvStreets_q);
     if (!empty($ukvStreetsRaw)) {
         foreach ($ukvStreetsRaw as $ieus => $eus) {
             $ukvStreets[$eus['street']] = $eus['street'];
         }
     }
     //main codepart
     $citySelected = wf_CheckPost(array('streetreportcity')) ? $_POST['streetreportcity'] : '';
     $streetSelected = wf_CheckPost(array('streetreportstreet')) ? $_POST['streetreportstreet'] : '';
     $inputs = wf_Selector('streetreportcity', $ukvCities, __('City'), $citySelected, false);
     $inputs .= wf_Selector('streetreportstreet', $ukvStreets, __('Street'), $streetSelected, false);
     $inputs .= wf_Submit(__('Show'));
     $form = wf_Form('', 'POST', $inputs, 'glamour');
     show_window(__('Streets report'), $form);
     if (wf_CheckPost(array('streetreportcity', 'streetreportstreet')) or wf_CheckGet(array('rc', 'rs'))) {
         //set form data
         if (wf_CheckPost(array('streetreportcity', 'streetreportstreet'))) {
             $citySearch = $_POST['streetreportcity'];
             $streetSearch = $_POST['streetreportstreet'];
         }
         //or printable report
         if (wf_CheckGet(array('rc', 'rs'))) {
             $citySearch = $_GET['rc'];
             $streetSearch = $_GET['rs'];
         }
         if (!empty($this->users)) {
             $counter = 0;
             $cells = wf_TableCell(__('Contract'), '10%');
             $cells .= wf_TableCell(__('Full address'), '31%');
             $cells .= wf_TableCell(__('Real Name'), '30%');
             $cells .= wf_TableCell(__('Tariff'), '15%');
             $cells .= wf_TableCell(__('Cash'), '7%');
             $cells .= wf_TableCell(__('Status'), '7%');
             $rows = wf_TableRow($cells, 'row1');
             foreach ($this->users as $io => $eachUser) {
                 if ($eachUser['city'] == $citySearch and $eachUser['street'] == $streetSearch) {
                     $cells = wf_TableCell($eachUser['contract']);
                     $fullAddress = $this->userGetFullAddress($eachUser['id']);
                     $profileLink = wf_Link(self::URL_USERS_PROFILE . $eachUser['id'], web_profile_icon() . ' ', false, '');
                     $cells .= wf_TableCell($profileLink . $fullAddress);
                     $cells .= wf_TableCell($eachUser['realname']);
                     $cells .= wf_TableCell($this->tariffs[$eachUser['tariffid']]['tariffname']);
                     $cells .= wf_TableCell($eachUser['cash']);
                     $cells .= wf_TableCell(web_bool_led($eachUser['active'], true));
                     $rows .= wf_TableRow($cells, 'row3');
                     $counter++;
                 }
             }
             $result = wf_TableBody($rows, '100%', '0', 'sortable');
             $result .= __('Total') . ': ' . $counter;
             if (wf_CheckGet(array('printable'))) {
                 $this->reportPrintable($citySearch . ' / ' . $streetSearch, $result);
             } else {
                 $printlink = wf_Link(self::URL_REPORTS_MGMT . 'reportStreets&rc=' . $citySearch . '&rs=' . $streetSearch . '&printable=true', wf_img('skins/icon_print.png', __('Print')), false, '');
                 show_window($citySearch . ' / ' . $streetSearch . ' ' . $printlink, $result);
             }
         } else {
             show_window(__('Result'), __('Any users found'));
         }
     }
 }
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:79,代码来源:api.ukv.php


注:本文中的wf_Link函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。