/** * 获取房源定价消费信息 * * @param int $houseId * @param int $brokerId * @return array */ public static function getHouseFixSpreadCostInfo($houseId, $brokerId) { $startTime = strtotime(date('Y-m-d 00:00:00', strtotime('-6 day '))); $tempFixSpreadCostInfoList = Bll_Ppc_ServiceAPI::getHouseCostInfo(array($houseId), $startTime, time(), $brokerId); $fixSpreadCostInfoList = array(); foreach ($tempFixSpreadCostInfoList as $fixSpreadCostInfo) { $key = date('m.d', strtotime($fixSpreadCostInfo['time'])); if (isset($fixSpreadCostInfoList[$fixSpreadCostInfo['time']])) { $fixSpreadCostInfoList[$key] += max(0, intval($fixSpreadCostInfo['amount'])) / 100; } else { $fixSpreadCostInfoList[$key] = max(0, intval($fixSpreadCostInfo['amount'])) / 100; } } return $fixSpreadCostInfoList; }