質問 > フロント機能 > LC_Page_Admin_Products_Product.phpのfunctionをLC_Page_FrontParts_Bloc_New_Products.phpで起動することは可能でしょうか。 |
フロント機能
フラット表示 | 前のトピック | 次のトピック |
投稿者 | スレッド |
---|---|
aozora |
投稿日時: 2013/4/17 17:45
対応状況: −−−
|
常連 登録日: 2013/3/21 居住地: 投稿: 40 |
Re: LC_Page_Admin_Products_Product.phpのfunctionをLC_Page_FrontParts_Bloc_New_Products.phpで起動することは可能でしょうか。 Yuh様
お世話になっております。そしてご教授頂きましてありがとうございます。 新着商品の記述は反映されました。ありがとうございます。 現在、商品詳細ページおよび最近チェックした商品に取り組んでおります。両方ともSC_Product.phpのgetDetailを使用していると思われます。現在のところ以下の記述に行き着きましたが、エラーはでないものの金額が同じままです。(getListByProductIdsが反映されません。)何かお分かりになりますでしょうか。ご教授のほどお願い致します。 function getDetail($productId) { $objQuery =& SC_Query_Ex::getSingletonInstance(); $objProduct = new SC_Product_Ex(); $arrProduct = $objQuery->getRow('*', $this->alldtlSQL('product_id = ?'),'product_id = ?',array($productId, $productId)); $arrProduct = (array)$arrProduct; // 税込金額を設定する SC_Product_Ex::setIncTaxToProduct($arrProduct); ********************(getDetailの記述の変更はなく、*****内だけ追加) $arrProductId = array(); foreach ($arrProductData as $productdetail) {$arrProductId[] = $productdetail['product_id'];} $arrProducts = $objProduct->getListByProductIds($objQuery, $arrProductId); $arrProductdetail = array(); foreach ($arrProductData as $key => $arrRow) { $arrProductData[$key] = array_merge($arrRow, $arrProducts[$arrRow['product_id']]); } ******************** return $arrProduct; } |
フラット表示 | 前のトピック | 次のトピック |