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


PHP astercrm::variableFiler方法代码示例

本文整理汇总了PHP中astercrm::variableFiler方法的典型用法代码示例。如果您正苦于以下问题:PHP astercrm::variableFiler方法的具体用法?PHP astercrm::variableFiler怎么用?PHP astercrm::variableFiler使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在astercrm的用法示例。


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

示例1: updateWorktimeRecord

 function updateWorktimeRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE worktimes SET " . "starttime='" . $f['starttime'] . "', " . "endtime='" . $f['endtime'] . "', " . "startweek='" . $f['startweek'] . "', " . "endweek='" . $f['endweek'] . "', " . "groupid='" . $f['groupid'] . "' " . "WHERE id=" . $f['id'];
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:9,代码来源:worktime.grid.inc.php

示例2: updateRateRecord

 function updateRateRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $sql = "UPDATE myrate SET " . "dialprefix = '" . $f['dialprefix'] . "', " . "numlen = '" . $f['numlen'] . "', " . "destination = '" . $f['destination'] . "', " . "rateinitial = '" . $f['rateinitial'] . "', " . "initblock = '" . $f['initblock'] . "', " . "billingblock = '" . $f['billingblock'] . "', " . "connectcharge= '" . $f['connectcharge'] . "', " . "groupid = '" . $f['groupid'] . "', " . "resellerid = '" . $f['resellerid'] . "', " . "addtime= now() " . "WHERE id = " . $f['id'];
     astercrm::events($sql);
     $res =& $db->query($sql);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:9,代码来源:rate.grid.inc.php

示例3: updateWorktimepackage

 function updateWorktimepackage($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE worktimepackages SET " . "worktimepackage_name=" . $db->quote($f['worktimepackage_name']) . ", " . "worktimepackage_note=" . $db->quote($f['worktimepackage_note']) . ", " . "worktimepackage_status='" . $f['worktimepackage_status'] . "', " . "groupid='" . $f['groupid'] . "' " . "WHERE id=" . $f['id'];
     $wp_res = Customer::deleteRecords("worktimepackage_id", $f['id'], 'worktimepackage_worktimes');
     $sltedWorktimes = split(',', rtrim($f['sltedWorktimes'], ','));
     foreach ($sltedWorktimes as $worktimeid) {
         $sql = "INSERT INTO worktimepackage_worktimes SET " . "worktimepackage_id='" . $f['id'] . "', " . "worktime_id='" . $worktimeid . "', " . "creby = '" . $_SESSION['curuser']['username'] . "'," . "cretime = now()";
         $wp_res =& $db->query($sql);
     }
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:15,代码来源:worktimepackages.grid.inc.php

示例4: updateTrunkinfoRecord

 function updateTrunkinfoRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE trunkinfo SET " . "trunkname='" . $f['trunkname'] . "', " . "trunkchannel='" . $f['trunkchannel'] . "', " . "didnumber='" . $f['didnumber'] . "', " . "trunk_number='" . $f['trunk_number'] . "', " . "trunknote='" . $f['trunknote'] . "', " . "cretime= now() " . "WHERE id= " . $f['id'] . " ";
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:9,代码来源:trunkinfo.grid.inc.php

示例5: updateResellergroupRecord

 /**
  *  update resellergroup table
  *
  *	@param $f			(array)		array contain customer fields.
  *	@return $res		(object) 		object
  */
 function updateResellergroupRecord($f)
 {
     global $db, $config;
     $f = astercrm::variableFiler($f);
     if ($f['creditmodtype'] == '') {
         $newcurcredit = $f['curcredit'];
     } elseif ($f['creditmodtype'] == 'add' && is_numeric($f['creditmod'])) {
         $newcurcredit = $f['curcredit'] + $f['creditmod'];
         $newcurcreditstr = "curcredit=curcredit + " . $f['creditmod'] . ", ";
         $historysql = "INSERT INTO credithistory SET " . "modifytime= now(), " . "resellerid='" . $f['resellerid'] . "', " . "srccredit='" . $f['curcredit'] . "', " . "modifystatus= 'add', " . "modifyamount='" . $f['creditmod'] . "', " . "comment='" . $f['comment'] . "', " . "operator='" . $_SESSION['curuser']['userid'] . "'";
         $historyres =& $db->query($historysql);
     } elseif ($f['creditmodtype'] == 'reduce' && is_numeric($f['creditmod'])) {
         $newcurcredit = $f['curcredit'] - $f['creditmod'];
         $newcurcreditstr = "curcredit=curcredit - " . $f['creditmod'] . ", ";
         $historysql = "INSERT INTO credithistory SET " . "modifytime= now(), " . "resellerid='" . $f['resellerid'] . "', " . "srccredit='" . $f['curcredit'] . "', " . "modifystatus= 'reduce', " . "modifyamount='" . $f['creditmod'] . "', " . "comment='" . $f['comment'] . "', " . "operator='" . $_SESSION['curuser']['userid'] . "'";
         $historyres =& $db->query($historysql);
     }
     $sql = "UPDATE resellergroup SET " . "resellername='" . $f['resellername'] . "', " . "accountcode='" . $f['accountcode'] . "', " . "clid_context='" . $f['clid_context'] . "', " . $newcurcreditstr . "creditlimit='" . $f['creditlimit'] . "', " . "limittype='" . $f['limittype'] . "', " . "multiple= '" . $f['multiple'] . "', " . "trunk1_id= '" . $f['trunk1_id'] . "', " . "trunk2_id= '" . $f['trunk2_id'] . "', " . "allowcallback='no', " . "addtime= now() " . "WHERE id='" . $f['resellerid'] . "'";
     astercrm::events($sql);
     $res =& $db->query($sql);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:28,代码来源:resellergroup.grid.inc.php

示例6: updateRemindercallsRecord

 function updateRemindercallsRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE remindercalls SET " . "customerid='" . $f['customerid'] . "', " . "contactid='" . $f['contactid'] . "', " . "phonenumber= '" . $f['phonenumber'] . "', " . "asteriskcallsid= '" . $f['asteriskcallsid'] . "', " . "note= '" . $f['note'] . "', " . "dialtime= '" . $f['dialtime'] . "', " . "groupid = " . $f['groupid'] . ", " . "cretime = now() " . "WHERE id= " . $f['id'] . " ";
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:9,代码来源:remindercalls.grid.inc.php

示例7: updateCustomer

 function updateCustomer($f)
 {
     global $customers_db, $config;
     //print_r($f);exit;
     $f = astercrm::variableFiler($f);
     $sql = "UPDATE " . $config['customers']['customertable'] . " SET " . "first_name='" . $f['first_name'] . "', " . "last_name = '" . $f['last_name'] . "', " . "discount = '" . $f['discount'] . " 'WHERE pin = '" . $f['pin'] . "'";
     astercrm::events($sql);
     $res =& $customers_db->query($sql);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:10,代码来源:customers.grid.inc.php

示例8: updateUserTypeRecord

 function updateUserTypeRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $sql = "UPDATE user_types SET " . "usertype_name='" . $f['usertype_name'] . "', " . "memo='" . $f['memo'] . "' where id=" . $f['Id'] . " ";
     astercrm::events($sql);
     $res =& $db->query($sql);
     //下面是编辑权限,先删除这个用户的所有权限,然后进行重新分配
     astercrm::events("DELETE FROM user_privileges WHERE user_type_id=" . $f['Id'] . " ");
     $delete =& $db->query("DELETE FROM user_privileges WHERE user_type_id=" . $f['Id'] . " ");
     if (!$delete) {
         return $res;
     }
     //删除权限失败就不重新插如新的权限
     $insertArray = array();
     $curView = explode(',', rtrim($f['chkView'], ','));
     foreach ($curView as $view) {
         $obj = explode('=', $view);
         $checked = $obj[1];
         $page = str_replace("_view", "", $obj[0]);
         if ($checked) {
             $insertArray[] = array('view', $page, $f['Id']);
         }
     }
     $curEdit = explode(',', rtrim($f['chkEdit'], ','));
     foreach ($curEdit as $edit) {
         $Eobj = explode('=', $edit);
         $Echecked = $Eobj[1];
         $Epage = str_replace("_edit", "", $Eobj[0]);
         if ($Echecked) {
             $insertArray[] = array('edit', $Epage, $f['Id']);
         }
     }
     $curDel = explode(',', rtrim($f['ckdelete'], ','));
     foreach ($curDel as $del) {
         $Dobj = explode('=', $del);
         $Dchecked = $Dobj[1];
         $Dpage = str_replace("_delete", "", $Dobj[0]);
         if ($Dchecked) {
             $insertArray[] = array('delete', $Dpage, $f['Id']);
         }
     }
     if (!empty($insertArray)) {
         $privilege_sql = "INSERT INTO `user_privileges` (`action`,`page`,`user_type_id`,`created`) VALUES ";
         foreach ($insertArray as $tmp) {
             $privilege_sql .= "('" . $tmp[0] . "','" . $tmp[1] . "'," . $tmp[2] . ",now()),";
         }
         $new_sql .= rtrim($privilege_sql, ',') . ';';
         astercrm::events($new_sql);
         $result =& $db->query($new_sql);
     }
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:53,代码来源:user_types.grid.inc.php

示例9: updateField

 /**
  *  update a field in a table 
  *
  *	@param  $table		(string)	table name
  *	@param  $field		(string)	field need to be updated
  *	@param  $value		(string)	value want to update to
  *	@param  $id			(int)		identity of the record
  *	@return $res		(object)	object
  */
 function updateField($table, $field, $value, $id, $fld = "id")
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $sql = "UPDATE {$table} SET {$field}='{$value}' WHERE {$fld} = '{$id}'";
     astercrm::events($sql);
     $res =& $db->query($sql);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:18,代码来源:astercrm.class.php

示例10: updateTCategoryRecord

 /**
  *  Actualiza un registro de la tabla.
  *
  *	@param $f	(array)		Arreglo que contiene los datos del formulario pasado.
  *	@return $res	(object)	Devuelve el objeto con la respuesta de la sentencia SQL ejecutada del UPDATE.
  */
 function updateTCategoryRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE tickets SET " . "ticketname='" . $f['ticketname'] . "', " . "campaignid='" . $f['campaignid'] . "', " . "groupid='" . $f['groupid'] . "', " . "fid=" . $f['fid'] . " " . "WHERE id='" . $f['id'] . "'";
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:15,代码来源:ticketcategory.grid.inc.php

示例11: updateCampaignResultRecord

 function updateCampaignResultRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $bindqueue = 0;
     if ($f['bindqueue'] == "on") {
         $bindqueue = 1;
     }
     $query = "UPDATE campaignresult SET " . "resultname='" . $f['resultname'] . "', " . "resultnote='" . $f['resultnote'] . "', " . "status='" . $f['status'] . "', " . "campaignid='" . $f['campaignid'] . "', " . "parentid='" . $f['parentid'] . "', " . "groupid='" . $f['groupid'] . "' " . "WHERE id=" . $f['id'];
     astercrm::events($query);
     //		echo $query;exit;
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:14,代码来源:campaignresult.grid.inc.php

示例12: updateDNCRecord

 function updateDNCRecord($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE dnc_list SET " . "number='" . astercrm::getDigitsInStr($f['number']) . "', " . "groupid='" . $f['groupid'] . "', " . "campaignid= '" . $f['campaignid'] . "' " . "WHERE id='" . $f['id'] . "'";
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:9,代码来源:dnc.grid.inc.php

示例13: updateRemind

 function updateRemind($f)
 {
     //修改提醒
     global $db;
     $f = astercrm::variableFiler($f);
     $remindtime = $f['remindtime'];
     $touser = trim($f['touser']);
     //if($touser == ''){
     $touser = $_SESSION['curuser']['username'];
     //}
     $query = "UPDATE remind SET " . "title='" . $f['remindtitle'] . "', " . "content='" . $f['content'] . "', " . "remindtime='" . $remindtime . "'," . "remindtype='" . $f['remindtype'] . "'," . "priority='" . $f['priority'] . "'," . "username='" . $f['username'] . "', " . "remindabout='" . $f['remindabout'] . "', " . "touser='" . $touser . "'  " . "WHERE id='" . $f['id'] . "'";
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:15,代码来源:astercrm.class.php

示例14: updateCurTicket

 function updateCurTicket($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "UPDATE ticket_details SET " . "ticketcategoryid=" . $f['ticketcategoryid'] . ", " . "ticketid=" . $f['ticketid'] . ", " . "parent_id='" . ($f['parent_id'] == '' ? '' : str_pad($f['parent_id'], 8, '0', STR_PAD_LEFT)) . "'," . "customerid=" . $f['customerid'] . ", " . "assignto=" . $f['assignto'] . "," . "status='" . $f['status'] . "', " . "groupid=" . $f['groupid'] . "," . "memo='" . $f['memo'] . "' " . "WHERE id=" . $f['id'] . "";
     astercrm::events($query);
     $res =& $db->query($query);
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:9,代码来源:portal.grid.inc.php

示例15: saveCustomerLeadNote

 function saveCustomerLeadNote($f)
 {
     global $db;
     $f = astercrm::variableFiler($f);
     $query = "INSERT INTO note_leads SET " . "note='" . $f['note'] . "', " . "callerid='" . $f['iptcallerid'] . "', " . "attitude='" . $f['attitude'] . "', " . "priority=" . $f['priority'] . ", " . "private='" . $f['private'] . "', " . "cretime=now(), " . "creby='" . $_SESSION['curuser']['username'] . "', " . "groupid = " . $_SESSION['curuser']['groupid'] . ", " . "customerid=" . $f['customerid'] . ", " . "contactid=" . $f['contactid'] . ", " . "codes='" . $f['note_code'] . "' ";
     astercrm::events($query);
     $res =& $db->query($query);
     if ($res) {
         $noteId = mysql_insert_id();
         $sql = "UPDATE customer_leads SET last_note_id={$noteId} WHERE id=" . $f['customerid'] . " ";
         $res =& $db->query($sql);
     }
     return $res;
 }
开发者ID:ljhcj,项目名称:IRISCC,代码行数:14,代码来源:customer_leads.grid.inc.php


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