• Hi there,

    I’m looking for a template or plug-in that’s designed to have a parent post inherit the fields of a child post. It doesn’t necessarily need to be setup for real estate but that’s what I’ll use it for.

    We’ve tried a few plugins and themes in the past but have been unable to find anything that specifically addresses this issue. We’ve used WP-Property, Estatement, and Realia.

    By jumping through several filter loopholes we’ve been able to label property posts as buildings and suites, then setup searches that exclude the building type. We want people to search by suite because we update that twice a week through an importer that changes an availability field so leased suites don’t show up. That way, we can still link back to the building from the suites and setup property lists of all vacant suites on the building page, which is a very roundabout way to show what’s vacant in each building. The problem is, the building doesn’t have any fields to search by because it’s not updated like the suites are.

    It seems this would be easy to do if a post inherited designated fields of a child post. Although, it would also have to be able to query a range of results for a single field, such as square footage. Then we could return results by buildings instead of having dozens of units show up, usually in the same building. For example (with search terms in quotes), a user searches for “1000” to “1,500” square feet of “office” space in “NE Portland”. The result would return the buildings with vacancies that meet that criteria (and could be implemented in a grid, map, or list result page).

    I hope it’s okay to do this, but a perfect example would be something like the results for Officespace.com (you’ll need to click on one of the map pins): https://www.officespace.com/map#zoom:17|center_lng:-122.67603492055571|center_lat:45.51743471315313

    Each building is pinned on the map and shown on the list below with the number of suites that meet the criteria in that building and a list of the min – max rent and square footage for all vacancies within that building.

    I suppose this seems like a specific request and I’ll probably get recommended to hire a coder for us. Unfortunately, that’s not an option. I’m hoping someone knows of something or I think it’s a missed opportunity for a theme or plug-in on WordPress that commercial and multi-family firms would pay for, since apartment buildings work much in the same way. It would be easy enough to setup an import function with a plug-in like WP All Import, which is what we do now, but we’re simply missing the inherit function that would allow us to return more manageable search results to our users.

    Anyone have thoughts on this? Is it even possible to do in WordPress? Thanks for taking the time to read this long post.

Viewing 3 replies - 1 through 3 (of 3 total)
  • First, anything is possible in WordPress. I’ve only been developing with WordPress for under a year, but I have yet to find something that is not achievable with WordPress.

    Unfortunately, I have not seen anything that has this functionality already. However, someone out there may come along and point something out that will work for your needs. I can set out some guidelines for what I think would be the easiest (although, not most efficient) way to achieve the relationship portion of this aspect.

    • A “suite” post would have a meta field that relates it to a “building” post. This would be the post ID of the “building” post.
    • A “suite” post would also have additional meta fields that contain the values of square footage, rent, vacancy, latitude/longitude, suite number, number of entrances/exits, bathroom count, sink count, suite type (office/retail/medical/industrial), etc. Ideally these would be customizable by the site administrator and provide endless possibilities.
    • A “building” post would have multiple meta fields, mostly arrays, that would contain all of the information of each of its children “suite” posts:
      [sqft] => Array
      (
      	[120] => 1055
      	[131] => 1228
      	[153] => 1480
      )
      [rent] => Array
      (
      	[120] => 23.50
      	[153] => 11.00
      )
      [vacancy] => Array
      (
      	[120] => true
      	[131] => true
      	[153] => false
      )
      [type] => Array
      (
      	[120] => office
      	[131] => retail
      	[153] => industrial
      )

      In this example, 120, 131 and 153 are “suite” post IDs. The missing rent for “suite” post ID 131 was intentional to demonstrate that we do not have to duplicate empty fields.

    • The “save_post” hook can be used to detect when a “suite” post is updated. Using that hook, we can update the “building” post’s meta data.
    • Using this technique, it would be very simple for WP_Query or get_posts to search posts containing all relevant data.

    The reason I say that this is not the most efficient way to do it is because we are literally duplicating the data just to make it easily searchable.

    I will keep an eye out for anything that may work for your needs. I really hope you’re able to find a solution soon!

    I think you are looking for Complex/Building package. please check here:

    https://wpl.realtyna.com/building-complex-or-community-add-on

    Our framework is fully customisable.

    Thread Starter APMPortland

    (@apmportland)

    @ Dale3h

    Thank you for taking the time to reply with so much helpful information. I think the array would work for our needs, especially since we have unique 7-digit unit numbers assigned to each suite (because most of our buildings have duplicate suite numbers like 101, 102, etc…).

    I believe realtyna has linked to a solution that may do exactly what I’m looking for. I’ll post back in here if their solution does what I described in my original post. Thanks again!

    @ realtyna

    I think you may be right and I’m looking through all your features now. I have no doubt I’ll be contacting you soon to discuss the minutia of integrating an import system and other features we already have setup.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Real estate template/plug-in with inherited fields’ is closed to new replies.