本文整理汇总了PHP中wf_CheckPost函数的典型用法代码示例。如果您正苦于以下问题:PHP wf_CheckPost函数的具体用法?PHP wf_CheckPost怎么用?PHP wf_CheckPost使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了wf_CheckPost函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: web_CardShowDateForm
/**
* Renders year-month search interface
*
* @return void
*/
function web_CardShowDateForm()
{
$curmonth = wf_CheckPost(array('monthsel')) ? vf($_POST['monthsel'], 3) : date("m");
$curyear = wf_CheckPost(array('yearsel')) ? vf($_POST['yearsel'], 3) : date("Y");
$inputs = wf_YearSelectorPreset('yearsel', __('Year'), false, $curyear) . ' ';
$inputs .= wf_MonthSelector('monthsel', 'Month', $curmonth, false);
$inputs .= wf_Submit('Show');
$form = wf_Form("", 'POST', $inputs, 'glamour');
show_window(__('Date'), $form);
}
开发者ID:nightflyza,项目名称:Ubilling,代码行数:15,代码来源:index.php
示例2: __construct
public function __construct()
{
//sets display year
if (wf_CheckPost(array('setyear'))) {
$this->curyear = vf($_POST['setyear'], 3);
} else {
$this->curyear = curyear();
}
//load actual month data
$this->loadData();
//load user tariffs
$this->loadTariffs();
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:13,代码来源:index.php
示例3: setDateFilters
/**
* Sets required year/month filter properties
*
* @return void
*/
protected function setDateFilters()
{
if (wf_CheckPost(array('yearsel'))) {
$this->year = vf($_POST['yearsel']);
} else {
$this->year = date("Y");
}
if (wf_CheckPost(array('monthsel'))) {
$this->month = vf($_POST['monthsel']);
} else {
$this->month = date("m");
}
}
开发者ID:nightflyza,项目名称:Ubilling,代码行数:18,代码来源:index.php
示例4: wf_PlPingerOptionsForm
function wf_PlPingerOptionsForm()
{
//previous setting
if (wf_CheckPost(array('packet'))) {
$currentpack = vf($_POST['packet'], 3);
} else {
$currentpack = '';
}
if (wf_CheckPost(array('count'))) {
$getCount = vf($_POST['count'], 3);
if ($getCount <= 10000) {
$currentcount = $getCount;
} else {
$currentcount = '';
}
} else {
$currentcount = '';
}
$inputs = wf_TextInput('packet', __('Packet size'), $currentpack, false, 5);
$inputs .= wf_TextInput('count', __('Count'), $currentcount, false, 5);
$inputs .= wf_Submit(__('Save'));
$result = wf_Form('', 'POST', $inputs, 'glamour');
return $result;
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:24,代码来源:index.php
示例5: 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
示例6: savePassport
/**
* saves new passport data for some build
*
* @return void
*/
protected function savePassport()
{
if (wf_CheckPost(array('savebuildpassport'))) {
$buildid = vf($_POST['savebuildpassport'], 3);
// Yep, im know - thats shitty solution. Need to refactor this later.
$clean_query = "DELETE FROM `buildpassport` WHERE `buildid`='" . $buildid . "';";
nr_query($clean_query);
$owner = mysql_real_escape_string($_POST['powner']);
$ownername = mysql_real_escape_string($_POST['pownername']);
$ownerphone = mysql_real_escape_string($_POST['pownerphone']);
$ownercontact = mysql_real_escape_string($_POST['pownercontact']);
$keys = isset($_POST['pkeys']) ? 1 : 0;
$accessnotices = mysql_real_escape_string($_POST['paccessnotices']);
$floors = mysql_real_escape_string($_POST['pfloors']);
$entrances = mysql_real_escape_string($_POST['pentrances']);
$apts = mysql_real_escape_string($_POST['papts']);
$notes = mysql_real_escape_string($_POST['pnotes']);
$query = "INSERT INTO `buildpassport` (\n `id` ,\n `buildid` ,\n `owner` ,\n `ownername` ,\n `ownerphone` ,\n `ownercontact` ,\n `keys` ,\n `accessnotices` ,\n `floors` ,\n `apts` ,\n `entrances` ,\n `notes`\n )\n VALUES (\n NULL ,\n '" . $buildid . "',\n '" . $owner . "',\n '" . $ownername . "',\n '" . $ownerphone . "',\n '" . $ownercontact . "',\n '" . $keys . "',\n '" . $accessnotices . "',\n '" . $floors . "',\n '" . $apts . "',\n '" . $entrances . "',\n '" . $notes . "'\n );\n ";
nr_query($query);
log_register('BUILD PASSPORT SAVE [' . $buildid . ']');
}
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:27,代码来源:api.address.php
示例7: vf
}
}
// Удаление атрибута
if (wf_CheckGet(array('delete'))) {
$id = vf($_GET['delete'], 3);
$query = "DELETE FROM `radius_attributes` WHERE `id` = '{$id}'";
if (nr_query($query)) {
rcms_redirect("?module=freeradius&netid={$netid}");
}
}
// Редактирование атрибута
if (wf_CheckGet(array('edit'))) {
// ID редактируемого атрибута
$id = vf($_GET['edit'], 3);
// Сабмит формы редактирования атрибута
if (wf_CheckPost(array('edit'))) {
// Экранируем все введённые данные
foreach ($_POST['edit'] as &$value) {
$value = mysql_real_escape_string($value);
}
extract($_POST['edit']);
$login = isset($login) ? "'{$login}'" : 'NULL';
$query = "UPDATE `radius_attributes` SET `scenario` = '{$scenario}', `login` = {$login}, `Attribute` = '{$Attribute}', `op` = '{$op}', `Value` = '{$Value}' WHERE `id` = '{$id}'";
if (nr_query($query)) {
rcms_redirect("?module=freeradius&netid={$netid}");
}
}
$query = "SELECT * FROM `radius_attributes` WHERE `id` = '{$id}'";
$result = simple_query($query);
// Форма редактирования
$form = new InputForm('', 'POST', __('Save'), '', '', '', 'edit');
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:31,代码来源:index.php
示例8: catv_GlobalControlsShow
<?php
// check for right of current admin on this module
if (cfr('CATVSTATS')) {
catv_GlobalControlsShow();
if (wf_CheckGet(array('userid'))) {
$userid = vf($_GET['userid'], 3);
$userdata = catv_UserGetData($userid);
$realname = $userdata['realname'];
$address = $userdata['street'] . ' ' . $userdata['build'] . '/' . $userdata['apt'];
//target year selection
$yearforminputs = wf_YearSelector('yearselect', 'Year', false);
$yearforminputs .= ' ';
$yearforminputs .= wf_Submit('Show');
$yearform = wf_Form('', 'POST', $yearforminputs, 'glamour', '');
show_window($address . ' ' . $realname, $yearform . '<div style="clear: both;"></div>');
if (wf_CheckPost(array('yearselect'))) {
$target_year = $_POST['yearselect'];
} else {
$target_year = curyear();
}
catv_UserStatsByYear($userid, $target_year);
catv_DecoderShowAllChanges($userid);
catv_ActivityShowAll($userid);
catv_ProfileBack($userid);
}
} else {
show_error(__('You cant control this module'));
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:29,代码来源:index.php
示例9: getCemeteryControls
/**
* Cemetery controls
*
* @return string
*/
protected function getCemeteryControls()
{
$result = '';
if (isset($this->alterCfg['CEMETERY_ENABLED'])) {
if ($this->alterCfg['CEMETERY_ENABLED']) {
$cemetery = new Cemetery();
//integrated controller
if (wf_CheckPost(array('cemeterysetasundead'))) {
$cemetery->setUndead($_POST['cemeterysetasundead']);
rcms_redirect('?module=userprofile&username=' . $this->login);
}
if (wf_CheckPost(array('cemeterysetasdead'))) {
$cemetery->setDead($_POST['cemeterysetasdead']);
rcms_redirect('?module=userprofile&username=' . $this->login);
}
//activity view
if ($cemetery->isUserDead($this->login)) {
$log = wf_modalAuto(wf_img_sized('skins/dead_icon.png', '', '12', '12'), __('User lifestory'), $cemetery->renderCemeteryLog($this->login));
$result = ' / ' . __('Subscriber is not connected') . ' ' . $log;
} else {
$log = wf_modalAuto(wf_img_sized('skins/pigeon_icon.png', '', '12', '12'), __('User lifestory'), $cemetery->renderCemeteryLog($this->login));
$result = ' / ' . __('Subscriber is connected') . ' ' . $log;
}
}
}
return $result;
}
开发者ID:nightflyza,项目名称:Ubilling,代码行数:32,代码来源:api.userprofile.php
示例10: dateControl
/**
* show calendar contol form
*
* @return string
*/
public function dateControl()
{
if (wf_CheckPost(array('showdate'))) {
$curdate = $_POST['showdate'];
} else {
$curdate = curdate();
}
$inputs = wf_DatePickerPreset('showdate', $curdate);
$inputs .= wf_Submit(__('Show'));
$result = wf_Form('', 'POST', $inputs, 'glamour');
return $result;
}
开发者ID:carriercomm,项目名称:Ubilling,代码行数:17,代码来源:api.documents.php
示例11: zb_StorageDelete
zb_StorageDelete($_GET['edittemplate']);
zb_PhpConsoleCreateTemplate($_POST['edittemplatename'], $_POST['edittemplatebody']);
log_register("DEVCONSOLE TEMPLATE EDIT");
rcms_redirect("?module=sqlconsole&devconsole=true");
}
//construct query forms
$sqlinputs = wf_Link("?module=sqlconsole", 'SQL Console', false, 'ubButton');
$sqlinputs .= wf_Link("?module=sqlconsole&devconsole=true", 'PHP Console', false, 'ubButton');
if (cfr('ROOT')) {
$sqlinputs .= wf_Link("?module=migration", __('Migration'), false, 'ubButton');
$sqlinputs .= wf_Link("?module=migration2", __('Migration') . ' 2', false, 'ubButton');
if (cfr('MIKMIGR')) {
$sqlinputs .= wf_Link("?module=mikbill_migration", __('Migration') . ' mikbill', true, 'ubButton');
}
}
if (wf_CheckPost(array('sqlq'))) {
if ($alterconf['DEVCON_SQL_KEEP']) {
$startQuery = trim($_POST['sqlq']);
} else {
$startQuery = '';
}
} else {
$startQuery = '';
}
$sqlinputs .= wf_TextArea('sqlq', '', $startQuery, true, '80x10');
$sqlinputs .= wf_CheckInput('tableresult', 'Display query result as table', true, false);
$sqlinputs .= wf_Submit('Process query');
$sqlform = wf_Form('', 'POST', $sqlinputs, 'glamour');
$phpinputs = wf_Link("?module=sqlconsole", 'SQL Console', false, 'ubButton');
$phpinputs .= wf_Link("?module=sqlconsole&devconsole=true", 'PHP Console', false, 'ubButton');
if (cfr('ROOT')) {
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:31,代码来源:index.php
示例12: show_window
} else {
show_window(__('Error'), __('No mobile'));
}
}
}
//group user sending
if (wf_CheckPost(array('msendtype'))) {
$filterParams = '';
if (wf_CheckPost(array('msendtariffname'))) {
$filterParams = $_POST['msendtariffname'];
}
$userFilters = tsms_UserFilter($_POST['msendtype'], $filterParams);
show_window(__('Confirmation'), web_TsmsMassendConfirm($userFilters));
}
//sending subroutine
if (wf_CheckPost(array('massendConfirm'))) {
$smsTemplate = tsms_GetTemplate();
$smsWap = tsms_GetWap();
$smsSign = tsms_GetSign();
$smsTz = tsms_GetTz();
$unpackData = base64_decode($_POST['massendConfirm']);
$unpackData = unserialize($unpackData);
if (!empty($_POST['massendConfirm'])) {
if (!empty($unpackData)) {
log_register("TSMS SEND MASS FOR `" . sizeof($unpackData) . "` USERS");
foreach ($unpackData as $eachLogin => $eachPhone) {
$newMessage = tsms_ParseTemplate($eachLogin, $smsTemplate);
tsms_SendSMS($eachPhone, $smsSign, $newMessage, $smsWap, $smsTz);
}
$notifyText = sizeof($unpackData) . ' ' . __('SMS queued and waiting to send') . wf_Link('?module=turbosms', __('Click here to view today sending queue'), true, 'ubButton');
$doneNotify = wf_modalOpened(__('Send SMS for user group'), $notifyText, '400', '200');
开发者ID:syscenter,项目名称:ubilling-sms,代码行数:31,代码来源:index.php
示例13: wf_TableCell
$cells .= wf_TableCell(__('Visual'));
$rows = wf_TableRow($cells, 'row1');
$result = $this->panel();
if (!empty($this->data)) {
foreach ($this->data as $line => $data) {
$monthArpu = $data['count'] != 0 ? $mountArpu = round($data['summ'] / $data['count'], 2) : 0;
$cells = wf_TableCell($line);
$cells .= wf_TableCell($data['count']);
$cells .= wf_TableCell($monthArpu);
$cells .= wf_TableCell($data['summ']);
$cells .= wf_TableCell(web_bar($data['summ'], $this->totalsum), '', '', 'sorttable_customkey="' . $data['summ'] . '"');
$rows .= wf_TableRow($cells, 'row3');
}
}
$result .= wf_TableBody($rows, '100%', '0', 'sortable');
return $result;
}
}
$arpuReport = new ReportArpu();
//config data controller
if (wf_CheckPost(array('newtarifflines'))) {
$arpuReport->saveConfig($_POST['newtarifflines']);
rcms_redirect("?module=report_arpu");
} else {
//or some report rendering
$arpuReport->parsePayments();
show_window(__('Tariff lines ARPU report'), $arpuReport->render());
}
} else {
show_error(__('You cant control this module'));
}
开发者ID:carriercomm,项目名称:Ubilling,代码行数:31,代码来源:index.php
示例14: web_PaymentSearch
function web_PaymentSearch($markers)
{
if (wf_CheckPost(array('searchtable'))) {
if ($_POST['searchtable'] == 'payments') {
$table = 'payments';
}
if ($_POST['searchtable'] == 'corrections') {
$table = 'paymentscorr';
}
} else {
$table = 'payments';
}
$query = "SELECT * from `" . $table . "`";
$query .= $markers;
$altercfg = rcms_parse_ini_file(CONFIG_PATH . "alter.ini");
$csvdata = '';
$allpayments = simple_queryall($query);
if ($altercfg['FINREP_CONTRACT']) {
$allcontracts = zb_UserGetAllContracts();
$allcontracts = array_flip($allcontracts);
}
if ($altercfg['FINREP_TARIFF']) {
$alltariffs = zb_TariffsGetAllUsers();
}
$allrealnames = zb_UserGetAllRealnames();
$alladdress = zb_AddressGetFulladdresslist();
$alltypes = zb_CashGetAllCashTypes();
$allservicenames = zb_VservicesGetAllNamesLabeled();
$allpaysyspercents = zb_PaySysPercentGetAll();
$totalsumm = 0;
$paysyssumm = 0;
$profitsumm = 0;
$totalcount = 0;
$cells = wf_TableCell(__('ID'));
$cells .= wf_TableCell(__('Date'));
$cells .= wf_TableCell(__('Cash'));
$cells .= wf_TableCell(__('PS%'));
$cells .= wf_TableCell(__('Profit'));
$cells .= wf_TableCell(__('Login'));
if ($altercfg['FINREP_CONTRACT']) {
$cells .= wf_TableCell(__('Contract'));
}
$cells .= wf_TableCell(__('Full address'));
$cells .= wf_TableCell(__('Real Name'));
if ($altercfg['FINREP_TARIFF']) {
$cells .= wf_TableCell(__('Tariff'));
}
$cells .= wf_TableCell(__('Payment type'));
$cells .= wf_TableCell(__('Notes'));
$cells .= wf_TableCell(__('Admin'));
$rows = wf_TableRow($cells, 'row1');
if (!empty($allpayments)) {
if ($altercfg['FINREP_TARIFF']) {
$csvTariffColumn = ';' . __('Tariff');
} else {
$csvTariffColumn = '';
}
$csvdata .= __('ID') . ';' . __('Date') . ';' . __('Cash') . ';' . __('PS%') . ';' . __('Profit') . ';' . __('Login') . ';' . __('Full address') . ';' . __('Real Name') . $csvTariffColumn . ';' . __('Payment type') . ';' . __('Notes') . ';' . __('Admin') . "\n";
foreach ($allpayments as $io => $each) {
$cells = wf_TableCell($each['id']);
$cells .= wf_TableCell($each['date']);
$cells .= wf_TableCell($each['summ']);
//detecting paymentsystem and calc percent
if (isset($allpaysyspercents[$each['note']])) {
$currPc = $allpaysyspercents[$each['note']]['percent'];
$rawSumm = $each['summ'];
$paySysPc = $rawSumm / 100 * $currPc;
$ourProfit = $rawSumm - $paySysPc;
} else {
$paySysPc = 0;
$ourProfit = $each['summ'];
}
$cells .= wf_TableCell($paySysPc);
$cells .= wf_TableCell($ourProfit);
$cells .= wf_TableCell(wf_Link('?module=userprofile&username=' . $each['login'], web_profile_icon() . ' ' . $each['login'], false, ''));
if ($altercfg['FINREP_CONTRACT']) {
$cells .= wf_TableCell(@$allcontracts[$each['login']]);
}
@($paymentRealname = $allrealnames[$each['login']]);
@($paymentCashType = __($alltypes[$each['cashtypeid']]));
@($paymentAddress = $alladdress[$each['login']]);
$cells .= wf_TableCell($paymentAddress);
$cells .= wf_TableCell($paymentRealname);
if ($altercfg['FINREP_TARIFF']) {
@($userTariff = $alltariffs[$each['login']]);
$cells .= wf_TableCell($userTariff);
$csvTariff = ';' . $userTariff;
} else {
$csvTariff = '';
}
$cells .= wf_TableCell($paymentCashType);
//payment notes translation
if ($altercfg['TRANSLATE_PAYMENTS_NOTES']) {
$paynote = zb_TranslatePaymentNote($each['note'], $allservicenames);
} else {
$paynote = $each['note'];
}
$cells .= wf_TableCell($paynote);
$cells .= wf_TableCell($each['admin']);
$rows .= wf_TableRow($cells, 'row3');
//.........这里部分代码省略.........
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:101,代码来源:index.php
示例15: SendDog
<?php
if (cfr('SENDDOG')) {
$altCfg = $ubillingConfig->getAlter();
if ($altCfg['SENDDOG_ENABLED']) {
$sendDog = new SendDog();
//editing config
if (wf_CheckPost(array('editconfig'))) {
$sendDog->saveConfig();
rcms_redirect($sendDog->getBaseUrl());
}
if (!wf_CheckGet(array('showmisc'))) {
//render config interface
show_window(__('SendDog configuration'), $sendDog->renderConfigForm());
} else {
//render SMS queue
$smsQueue = $_GET['showmisc'];
switch ($smsQueue) {
case 'tsms':
show_window(__('View SMS sending queue'), $sendDog->renderTurboSMSQueue());
break;
case 'smsflybalance':
show_window(__('SMS-Fly') . ' ' . __('Balance'), $sendDog->renderSmsflyBalance());
break;
case 'telegramcontacts':
show_window(__('Telegram bot contacts'), $sendDog->renderTelegramContacts());
break;
}
}
} else {
show_error(__('This module is disabled'));
开发者ID:nightflyza,项目名称:Ubilling,代码行数:31,代码来源:index.php
示例16: show_error
if ($tsSheetCreateResult == 1) {
//date duplicate
show_error(__('Timesheets with that date already exist'));
}
}
}
$tsCf = $salary->timesheetCreateForm();
if ($tsCf) {
$timesheetsControls = wf_modal(web_add_icon() . ' ' . __('Create'), __('Create') . ' ' . __('Timesheet'), $tsCf, 'ubButton', '800', '600');
show_window('', $timesheetsControls);
if (!wf_CheckGet(array('showdate'))) {
//render available timesheets list by date
show_window(__('Timesheets'), $salary->timesheetsListRender('?module=salary_timesheets'));
} else {
//saving changes for single timesheet row
if (wf_CheckPost(array('edittimesheetid'))) {
$salary->timesheetSaveChanges();
rcms_redirect('?module=salary_timesheets&showdate=' . $_GET['showdate']);
}
//render timesheet by date (edit form)
show_window(__('Timesheet') . ' ' . $_GET['showdate'], $salary->timesheetEditForm($_GET['showdate']));
show_window('', wf_Link('?module=salary_timesheets', __('Back'), false, 'ubButton'));
}
} else {
show_warning(__('No available workers for timesheets'));
}
} else {
show_error(__('No license key available'));
}
} else {
show_error(__('This module is disabled'));
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:31,代码来源:index.php
示例17: rcms_redirect
if (wf_CheckPost(array('editname'))) {
$interface->changeTask();
rcms_redirect("?module=watchdog");
}
//changing watchdog settings
if (wf_CheckPost(array('changealert'))) {
$interface->saveSettings();
rcms_redirect("?module=watchdog");
}
//show watchdog main control panel
show_window('', $interface->panel());
if (!wf_CheckGet(array('edit'))) {
//show previous detections
if (wf_CheckGet(array('previousalerts'))) {
$interface->loadAllPreviousAlerts();
if (wf_CheckPost(array('previousalertsearch'))) {
//do the search
show_window(__('Search results'), $interface->alertSearchResults($_POST['previousalertsearch']));
} else {
//calendar
show_window(__('Previous alerts'), $interface->renderAlertsCalendar());
}
} else {
//or list of existing tasks
show_window(__('Available Watchdog tasks'), $interface->listAllTasks());
}
} else {
//show task edit form
show_window(__('Edit task'), $interface->editTaskForm($_GET['edit']));
}
} else {
开发者ID:nightflyza,项目名称:Ubilling,代码行数:31,代码来源:index.php
示例18: ts_TaskProblemsEditForm
/**
* Returns task typical problems editing form
*
* @return string
*/
function ts_TaskProblemsEditForm()
{
$rawNotes = zb_StorageGet('PROBLEMS');
//extract old or create new typical problems array
if (!empty($rawNotes)) {
$rawNotes = base64_decode($rawNotes);
$rawNotes = unserialize($rawNotes);
} else {
$emptyArray = array();
$newNotes = serialize($emptyArray);
$newNotes = base64_encode($newNotes);
zb_StorageSet('PROBLEMS', $newNotes);
$rawNotes = $emptyArray;
}
//adding and deletion subroutines
if (wf_CheckPost(array('createtypicalnote'))) {
$toPush = strip_tags($_POST['createtypicalnote']);
array_push($rawNotes, $toPush);
$newNotes = serialize($rawNotes);
$newNotes = base64_encode($newNotes);
zb_StorageSet('PROBLEMS', $newNotes);
log_register('TASKMAN ADD TYPICALPROBLEM');
rcms_redirect("?module=taskman&probsettings=true");
}
if (wf_CheckPost(array('deletetypicalnote', 'typicalnote'))) {
$toUnset = $_POST['typicalnote'];
if (($delkey = array_search($toUnset, $rawNotes)) !== false) {
unset($rawNotes[$delkey]);
}
$newNotes = serialize($rawNotes);
$newNotes = base64_encode($newNotes);
zb_StorageSet('PROBLEMS', $newNotes);
log_register('TASKMAN DELETE TYPICALPROBLEM');
rcms_redirect("?module=taskman&probsettings=true");
}
$rows = '';
$result = wf_Link("?module=taskman", __('Back'), true, 'ubButton');
if (!empty($rawNotes)) {
foreach ($rawNotes as $eachNote) {
$cells = wf_TableCell($eachNote);
$rows .= wf_TableRow($cells, 'row3');
}
}
$result .= wf_TableBody($rows, '100%', '0', '');
$result .= wf_delimiter();
$addinputs = wf_TextInput('createtypicalnote', __('Create'), '', true, '20');
$addinputs .= wf_Submit(__('Save'));
$addform = wf_Form("", "POST", $addinputs, 'glamour');
$result .= $addform;
$delinputs = ts_TaskTypicalNotesSelector(false);
$delinputs .= wf_HiddenInput('deletetypicalnote', 'true');
$delinputs .= wf_Submit(__('Delete'));
$delform = wf_Form("", "POST", $delinputs, 'glamour');
$result .= $delform;
return $result;
}
开发者ID:carriercomm,项目名称:Ubilling,代码行数:61,代码来源:api.teskman.php
示例19: show_window
<?php
if ($system->checkForRight('STGNEWADMIN')) {
if (!isset($_POST['registration_form'])) {
show_window(__('Administrator registration'), rcms_parse_module_template('user-profile.tpl', array('mode' => 'registration_form', 'fields' => $system->data['apf'])));
show_window('', wf_Link('?module=permissions', __('Back'), true, 'ubButton'));
}
if (isset($_POST['registration_form'])) {
if (wf_CheckPost(array('username', 'nickname', 'password', 'confirmation', 'email'))) {
$system->registerUser($_POST['username'], $_POST['nickname'], @$_POST['password'], @$_POST['confirmation'], $_POST['email'], $_POST['userdata']);
$system->updateUser($_POST['username'], $_POST['nickname'], $_POST['password'], $_POST['confirmation'], $_POST['email'], $_POST['userdata']);
stg_putlogevent('ADMREG {' . $_POST['username'] . '}');
show_window(__('Administrator registered'), wf_link('?module=permissions&edit=' . $_POST['username'], __('His permissions you can setup via corresponding module'), true, 'ubButton'));
} else {
show_error(__('No all of required fields is filled'));
show_window('', wf_Link('?module=adminreg', __('Back'), true, 'ubButton'));
}
}
} else {
show_error(__('Access denied'));
}
开发者ID:l1ght13aby,项目名称:Ubilling,代码行数:21,代码来源:index.php
示例20: multinet_rebuild_all_handlers
}
}
//edits existing ONU in database
if (wf_CheckPost(array('editonu', 'editoltid', 'editmac'))) {
$pon->onuSave($_POST['editonu'], $_POST['editonumodelid'], $_POST['editoltid'], $_POST['editip'], $_POST['editmac'], $_POST['editserial'], $_POST['editlogin']);
multinet_rebuild_all_handlers();
rcms_redirect('?module=ponizer&editonu=' . $_POST['editonu']);
}
//deleting existing ONU
if (wf_CheckGet(array('deleteonu'))) {
$pon->onuDelete($_GET['deleteonu']);
multinet_rebuild_all_handlers();
rcms_redirect('?module=ponizer');
}
//assigning ONU with some user
if (wf_CheckPost(array('assignonulogin', 'assignonuid'))) {
$pon->onuAssign($_POST['assignonuid'], $_POST['assignonulogin']);
multinet_rebuild_all_handlers();
rcms_redirect('?module=ponizer&editonu=' . $_POST['assignonuid']);
}
if (!wf_CheckGet(array('editonu'))) {
if (wf_CheckGet(array('username'))) {
//try to detect ONU id by user login
$login = $_GET['username'];
$userOnuId = $pon->getOnuIdByUser($login);
//redirecting to assigned ONU
if ($userOnuId) {
rcms_redirect('?module=ponizer&editonu=' . $userOnuId);
} else {
//rendering assign form
show_window(__('ONU assign'), $pon->onuAssignForm($login));
开发者ID:nightflyza,项目名称:Ubilling,代码行数:31,代码来源:index.php
注:本文中的wf_CheckPost函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论