Changeset 15155 for branches/feature-module-update/data
- Timestamp:
- 2007/08/01 12:21:06 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/feature-module-update/data/class/util/SC_Utils.php
r15141 r15155 486 486 // sfErrorHeader('>> referrerが無効になっています。'); 487 487 } else { 488 $domain = sfIsHTTPS() ? SSL_URL : SITE_URL;488 $domain = SC_Utils::sfIsHTTPS() ? SSL_URL : SITE_URL; 489 489 $pattern = sprintf('|^%s.*|', $domain); 490 490 $referer = $_SERVER['HTTP_REFERER']; … … 934 934 for($cnt = 0; $cnt < $max; $cnt++) { 935 935 if($keysize != "") { 936 $key = sfCutString($arrList[$cnt][$keyname], $keysize);936 $key = $this->sfCutString($arrList[$cnt][$keyname], $keysize); 937 937 } else { 938 938 $key = $arrList[$cnt][$keyname]; … … 959 959 for($cnt = 0; $cnt < $max; $cnt++) { 960 960 if($keysize != "") { 961 $key = sfCutString($arrList[$cnt][$keyname], $keysize);961 $key = $this->sfCutString($arrList[$cnt][$keyname], $keysize); 962 962 } else { 963 963 $key = $arrList[$cnt][$keyname]; … … 1231 1231 /* 子IDの配列を返す */ 1232 1232 function sfGetChildsID($table, $pid_name, $id_name, $id) { 1233 $arrRet = sfGetChildrenArray($table, $pid_name, $id_name, $id);1233 $arrRet = SC_Utils::sfGetChildrenArray($table, $pid_name, $id_name, $id); 1234 1234 return $arrRet; 1235 1235 } … … 1323 1323 /* ポイント付与 */ 1324 1324 function sfPrePoint($price, $point_rate, $rule = POINT_RULE, $product_id = "") { 1325 if( sfIsInt($product_id)) {1325 if(SC_Utils::sfIsInt($product_id)) { 1326 1326 $objQuery = new SC_Query(); 1327 1327 $where = "now() >= cast(start_date as date) AND "; … … 1999 1999 $category_id = (int) $category_id; 2000 2000 $product_id = (int) $product_id; 2001 if(SC_Utils ::sfIsInt($category_id) &&sfIsRecord("dtb_category","category_id", $category_id)) {2001 if(SC_Utils_Ex::sfIsInt($category_id) && SC_Utils_Ex::sfIsRecord("dtb_category","category_id", $category_id)) { 2002 2002 $g_category_id = $category_id; 2003 } else if (SC_Utils ::sfIsInt($product_id) &&sfIsRecord("dtb_products","product_id", $product_id, "status = 1")) {2003 } else if (SC_Utils_Ex::sfIsInt($product_id) && SC_Utils_Ex::sfIsRecord("dtb_products","product_id", $product_id, "status = 1")) { 2004 2004 $objQuery = new SC_Query(); 2005 2005 $where = "product_id = ?"; … … 2027 2027 if($_GET['product_id'] != "" || $_GET['category_id'] != "") { 2028 2028 // 選択中のカテゴリIDを判定する 2029 $category_id = sfGetCategoryId($_GET['product_id'], $_GET['category_id']);2029 $category_id = SC_Utils::sfGetCategoryId($_GET['product_id'], $_GET['category_id']); 2030 2030 // ROOTカテゴリIDの取得 2031 $arrRet = sfGetParents($objQuery, 'dtb_category', 'parent_category_id', 'category_id', $category_id);2031 $arrRet = SC_Utils::sfGetParents($objQuery, 'dtb_category', 'parent_category_id', 'category_id', $category_id); 2032 2032 $root_id = $arrRet[0]; 2033 2033 } else { … … 2043 2043 function sfGetCatWhere($category_id) { 2044 2044 // 子カテゴリIDの取得 2045 $arrRet = sfGetChildsID("dtb_category", "parent_category_id", "category_id", $category_id);2045 $arrRet = SC_Utils::sfGetChildsID("dtb_category", "parent_category_id", "category_id", $category_id); 2046 2046 $tmp_where = ""; 2047 2047 foreach ($arrRet as $val) { … … 2558 2558 $arrChildren[] = $id; 2559 2559 2560 $arrRet = sfGetChildrenArraySub($arrData, $pid_name, $id_name, $arrPID);2560 $arrRet = SC_Utils::sfGetChildrenArraySub($arrData, $pid_name, $id_name, $arrPID); 2561 2561 2562 2562 while(count($arrRet) > 0) { 2563 2563 $arrChildren = array_merge($arrChildren, $arrRet); 2564 $arrRet = sfGetChildrenArraySub($arrData, $pid_name, $id_name, $arrRet);2564 $arrRet = SC_Utils::sfGetChildrenArraySub($arrData, $pid_name, $id_name, $arrRet); 2565 2565 } 2566 2566 … … 2720 2720 $objQuery = new SC_Query(); 2721 2721 $arrRet = array(); 2722 $arrCatID = sfGetParents($objQuery, "dtb_category", "parent_category_id", "category_id", $category_id);2722 $arrCatID = SC_Utils_Ex::sfGetParents($objQuery, "dtb_category", "parent_category_id", "category_id", $category_id); 2723 2723 $arrRet['id'] = $arrCatID[0]; 2724 2724
Note: See TracChangeset
for help on using the changeset viewer.