예제 #1
0
파일: index.php 프로젝트: junctiontech/dbho
 //my_print($ap_details);
 if (!count($ap_details)) {
     $ob_log->write("Appointment details not found for {$result['appointmentID']}. Cron skip this appointment.");
     continue;
 }
 if ($result['propertyPurpose'] == 1) {
     $propertyPurpose = 'Sell';
 } elseif ($result['propertyPurpose'] == 2) {
     $propertyPurpose = 'Rent';
 }
 // property data array
 $arr_property = array('propertyKey' => $ob_property::get_rand_id(), 'userID' => $result['userTypeID'], 'propertyTypeID' => $property_type, 'propertyFeatured' => 'OFF', 'propertyPurpose' => $propertyPurpose, 'propertyCoverImage' => NULL, 'propertyAddedDate' => date("Y-m-d H:i:s"), 'propertyUpdateDate' => date("Y-m-d H:i:s"), 'propertyApprovedDate' => NULL, 'propertySoldOutStatus' => 'No', 'propertySoldOutPrice' => 0, 'propertySoldOutDate' => NULL, 'propertyLatitude' => NULL, 'propertyLongitude' => NULL, 'countryID' => 99, 'stateID' => NULL, 'cityID' => NULL, 'cityLocID' => NULL, 'communityID' => 0, 'subCommunityID' => 0, 'buildingID' => 0, 'propertyZipCode' => $ap_details[0]['pincode'], 'propertyStatus' => 'draft', 'propertyPopularity' => 0, 'propertyThreeSixtyView' => NULL, 'propertyRank' => 0, 'projectID' => $result['projectID'], 'type' => 'Property', 'isNegotiable' => $ap_details[0]['rentNegotiable'] ? 'Yes' : 'No');
 // Save the property
 $property_id = $ob_property::save_data('rp_properties', $arr_property);
 ##$property_id = 520;
 $property_name = join(array($ap_details[0]['bhkType'], $ob_map->get_property_name($ap_details[0]['propertyType'])), ' ');
 $propertyDescription = join(array($property_name, 'at', $result['address']), ' ');
 $arr_property_address2 = array($ap_details[0]['building_no_or_name'], $ap_details[0]['flatNO'], $ap_details[0]['apointmentWing'], $ap_details[0]['apponitmentStreet'], $ap_details[0]['locality'], $ap_details[0]['subLocality'], $ap_details[0]['pincode'], $ap_details[0]['landmark']);
 $propertyAddress2 = join($arr_property_address2, ' ');
 $arr_property_details = array('propertyID' => $property_id, 'versionID' => 1, 'languageID' => 1, 'propertyName' => $property_name, 'propertyAddress1' => $result['address'], 'propertyAddress2' => $propertyAddress2, 'propertyDescription' => $propertyDescription, 'propertyLocality' => $ap_details[0]['locality'], 'propertyMetaTitle' => $propertyDescription, 'propertyMetaKeyword' => $propertyDescription, 'propertyMetaDescription' => $propertyDescription, 'propertyShortDescription' => $propertyDescription, 'propertySpecifications' => $property_name, 'propertyCurrentStatus' => '');
 $arr_property_prices = array('propertyID' => $property_id, 'currencyID' => 3, 'propertyPrice' => $ap_details[0]['rentAmount']);
 $app_data = array();
 // Get appointment mapping
 $app_data['app_details'] = $ap_details;
 $app_data['app_kitchens'] = $ak_details;
 $app_data['app_images'] = $ai_details;
 $app_data['app_livingroom'] = $al_details;
 $app_data['app_toilets'] = $at_details;
 $app_data['app_bedrooms'] = $ab_details;
 //$app_data['app_washdry_area'] = $aw_details;
 $attributes_map = $ob_map->get_attributes_map();