當前位置: 首頁>>代碼示例>>PHP>>正文


PHP PSU::createSlug方法代碼示例

本文整理匯總了PHP中PSU::createSlug方法的典型用法代碼示例。如果您正苦於以下問題:PHP PSU::createSlug方法的具體用法?PHP PSU::createSlug怎麽用?PHP PSU::createSlug使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在PSU的用法示例。


在下文中一共展示了PSU::createSlug方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: _prep_args

 /**
  * prepares arguments for DML
  */
 protected function _prep_args()
 {
     // this is the data prepared for binding.
     // these fields are ordered as they are in the table
     $args = array('the_id' => $this->id, 'gate_id' => $this->gate_id, 'name' => $this->name, 'slug' => $this->slug ?: \PSU::createSlug($this->name), 'legacy_code' => $this->legacy_code);
     return $args;
 }
開發者ID:AholibamaSI,項目名稱:plymouth-webapp,代碼行數:10,代碼來源:ChecklistItem.php

示例2: _prep_args

 /**
  * prepares arguments for DML
  */
 protected function _prep_args()
 {
     // this is the data prepared for binding.
     // these fields are ordered as they are in the table
     $args = array('the_id' => $this->id, 'sau_id' => $this->sau_id, 'district_id' => $this->district_id, 'school_type_id' => $this->school_type_id, 'school_approval_level_id' => $this->school_approval_level_id, 'name' => $this->name, 'slug' => $this->slug ?: \PSU::createSlug($this->name), 'grade_span' => $this->grade_span, 'enrollment' => $this->enrollment, 'street_line1' => $this->street_line1, 'street_line2' => $this->street_line2, 'city' => $this->city, 'state' => $this->state, 'zip' => $this->zip, 'phone' => $this->phone, 'fax' => $this->fax, 'legacy_code' => $this->legacy_code);
     return $args;
 }
開發者ID:AholibamaSI,項目名稱:plymouth-webapp,代碼行數:10,代碼來源:School.php

示例3: _prep_args

 /**
  * prepares arguments for DML
  */
 protected function _prep_args()
 {
     // this is the data prepared for binding.
     // these fields are ordered as they are in the table
     $args = array('the_id' => $this->id, 'name' => $this->name, 'slug' => $this->slug ?: \PSU::createSlug($this->name), 'street_line1' => $this->street_line1, 'street_line2' => $this->street_line2, 'city' => $this->city, 'state' => $this->state, 'zip' => $this->zip, 'phone' => $this->phone, 'fax' => $this->fax, 'legacy_code' => $this->legacy_code);
     return $args;
 }
開發者ID:AholibamaSI,項目名稱:plymouth-webapp,代碼行數:10,代碼來源:SAU.php

示例4: types

 public function types($search = null)
 {
     $types = array();
     foreach (self::items($search) as $item) {
         $types[\PSU::createSlug($item['type'])] = $item['type'];
     }
     //end foreach
     return $types;
 }
開發者ID:AholibamaSI,項目名稱:plymouth-webapp,代碼行數:9,代碼來源:ITSurplusAPI.class.php

示例5: getReceivableNetAmount

 public function getReceivableNetAmount($params = '')
 {
     $params = \PSU::params($params);
     $token = '';
     if (count($params) == 0) {
         $token = 'total';
     } else {
         ksort($params);
         foreach ($params as $key => $param) {
             $token .= $key . $param;
         }
         //end foreach
     }
     //end else
     $token = \PSU::createSlug($token);
     if (isset($this->data['receivable_net_amount'][$token])) {
         $total = $this->data['receivable_net_amount'][$token];
     } else {
         $total = 0;
         $sql = "BEGIN :val := tb_receivable.f_sum_net_amount(p_pidm => :pidm";
         foreach ($params as $key => $p) {
             if ($key == 'bill_date' || $key == 'as_of_date') {
                 $sql .= ", p_" . $key . " => to_date('" . $p . "', 'RRRR-MM-DD')";
             } else {
                 $sql .= ", p_" . $key . " => :" . $key;
             }
         }
         //end foreach
         $sql .= "); END;";
         $stmt = \PSU::db('banner')->PrepareSP($sql);
         \PSU::db('banner')->InParameter($stmt, $this->pidm, 'pidm');
         foreach ($params as $key => $p) {
             if ($key != 'bill_date' && $key != 'as_of_date') {
                 \PSU::db('banner')->InParameter($stmt, $p, $key);
             }
         }
         //end foreach
         \PSU::db('banner')->OutParameter($stmt, $total, 'val');
         \PSU::db('banner')->Execute($stmt);
         $this->data['receivable_net_amount'][$token] = $total ? $total : 0;
     }
     //end else
     return $total;
 }
開發者ID:AholibamaSI,項目名稱:plymouth-webapp,代碼行數:44,代碼來源:Bill.php


注:本文中的PSU::createSlug方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。