Created
January 13, 2026 15:29
-
-
Save propertyhive/6ef6ec97842d21f613b09cdbcc4d235c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| add_filter( 'houzez_property_feed_expertagent_departments_to_import', 'customise_ea_depts' ); | |
| function customise_ea_depts($departments) | |
| { | |
| $departments[] = 'catering'; | |
| $departments[] = 'development'; | |
| $departments[] = 'flat'; | |
| $departments[] = 'hotels'; | |
| $departments[] = 'house'; | |
| $departments[] = 'industrial'; | |
| $departments[] = 'investment'; | |
| $departments[] = 'lifestyle'; | |
| $departments[] = 'misc'; | |
| $departments[] = 'office'; | |
| $departments[] = 'other'; | |
| $departments[] = 'pub'; | |
| $departments[] = 'retail'; | |
| return $departments; | |
| } | |
| add_filter( "houzez_property_feed_properties_due_import_expertagent", 'correct_department', 10, 2 ); | |
| function correct_department( $properties, $import_id ) | |
| { | |
| foreach ( $properties as $i => $property ) | |
| { | |
| if ( | |
| isset($property->numeric_price) && | |
| !empty((int)$property->numeric_price) && | |
| (int)$property->numeric_price < 10000 | |
| ) | |
| { | |
| $properties[$i]->department = (string)$property->department . ' lettings'; | |
| } | |
| } | |
| return $properties; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment