Module: PortfolioManager::Services::PropertyUse::UseDetails::Live

Included in:
All::Live
Defined in:
lib/portfolio_manager/services/property_use.rb

Overview

Live Environment

Instance Method Summary collapse

Instance Method Details

#edit_use_details(property_use_id, use_detail, elename = nil) ⇒ PortfolioManager::Xml::ResponseType

Edit Use Details

This web service updates a specific set of use details based on the information provided in the XML request. The update is performed by creating a revision history. It returns the unique identifier to the use details and a link to the corresponding web service to retrieve it. To specify the use of default values, just omit the “value” XML tag for that particular use detail information from the XML request or omit the entire reference to the particular use detail information from the XML request altogether.

Parameters:

Returns:

Raises:

See Also:



180
181
182
# File 'lib/portfolio_manager/services/property_use.rb', line 180

def edit_use_details(property_use_id, use_detail, elename = nil)
  request(Net::HTTP::Post, path_for("propertyUse", property_use_id, "useDetails"), {}, {}, use_detail, elename, PortfolioManager::Xml::ResponseType, basic_auth: true)
end

#edit_use_details_correction(use_detail_id, use_detail, elename = nil) ⇒ PortfolioManager::Xml::ResponseType

Edit Use Details - Correction

This web service updates a specific set of use details based on the information provided in the XML request. The update is performed as a correction. It returns the unique identifier to the use details and a link to the corresponding web service to retrieve it. The corresponding property must already be shared with you. To specify the use of default values, just omit the “value” XML tag for that particular use detail information from the XML request or omit the entire reference to the particular use detail information from the XML request altogether.

Parameters:

Returns:

Raises:

See Also:



203
204
205
# File 'lib/portfolio_manager/services/property_use.rb', line 203

def edit_use_details_correction(use_detail_id, use_detail, elename = nil)
  request(Net::HTTP::Put, path_for("useDetails", use_detail_id), {}, {}, use_detail, elename, PortfolioManager::Xml::ResponseType, basic_auth: true)
end

#get_id_hierarchy_for_use_detail(use_detail_id) ⇒ PortfolioManager::Xml::HierarchyType, PortfolioManager::Xml::ResponseType

Get ID Hierarchy for Use Detail

This web service returns the accountId, propertyId, and propertyUseId that corresponds to a specific use detail record. The accountId returned is the Property Data Administrator (PDA). The corresponding property must already be shared with you or you must have pending share access.



220
221
222
# File 'lib/portfolio_manager/services/property_use.rb', line 220

def get_id_hierarchy_for_use_detail(use_detail_id)
  request(Net::HTTP::Get, path_for("idHierarchy", "useDetails", use_detail_id), {}, {}, nil, nil, PortfolioManager::Xml::HierarchyType, basic_auth: true)
end

#get_use_details(use_detail_id, klass = nil) ⇒ PortfolioManager::Xml::AmountOfLaundryProcessedAnnuallyType, ...

Get Use Details

This web service retrieves specific use detail information for a given use detail. The corresponding property must already be shared with you.

Parameters:

  • use_detail_id (Integer)
  • klass (nil, Class) (defaults to: nil)

Returns:

Raises:

See Also:



236
237
238
# File 'lib/portfolio_manager/services/property_use.rb', line 236

def get_use_details(use_detail_id, klass = nil)
  request(Net::HTTP::Get, path_for("useDetails", use_detail_id), {}, {}, nil, nil, klass, basic_auth: true)
end

#get_use_details_revision_history(property_use_id, current_as_of_start, current_as_of_end) ⇒ PortfolioManager::Xml::UseDetails, PortfolioManager::Xml::ResponseType

Get Use Details Revision History

This web service retrieves the use details revision history for a specific property use. The corresponding property must be already shared with you.



253
254
255
256
257
258
# File 'lib/portfolio_manager/services/property_use.rb', line 253

def get_use_details_revision_history(property_use_id, current_as_of_start, current_as_of_end)
  request(Net::HTTP::Get, path_for("propertyUse", property_use_id, "useDetailsRevisions"), {
    "currentAsOfStart" => current_as_of_start.strftime("%Y-%m-%d"),
    "currentAsOfEnd" => current_as_of_end.strftime("%Y-%m-%d"),
  }, {}, nil, nil, PortfolioManager::Xml::UseDetails, basic_auth: true)
end

#get_what_changed_property_use_list_from_use_detail_changes_only(customer_id, date) ⇒ PortfolioManager::Xml::ResponseType

Get What Changed Property Use List (from use detail changes only)

This web service returns a list of property uses that have had their use details changed since a user specified date. The list of property uses returned are account specific. Results are returned in increments of 1,000 per set. The returned list only shows property uses that you have permission to view. Actions that trigger a property use to be included in the returned list may have been performed by any user with permission to edit the property use details. A property use is displayed if it’s corresponding use details are corrected, or updated with a new historical record.



278
279
280
281
282
# File 'lib/portfolio_manager/services/property_use.rb', line 278

def get_what_changed_property_use_list_from_use_detail_changes_only(customer_id, date)
  request(Net::HTTP::Get, path_for("customer", customer_id, "useDetails", "whatChanged"), {
    "date" => date.strftime("%Y-%m-%d"),
  }, {}, nil, nil, PortfolioManager::Xml::ResponseType, basic_auth: true)
end