OS Property support center

Changing/Adding Price for options

More
6 years 8 months ago #102073 by BWS
Is there a way to add or edit the options in the Price For field? We have a client that doesn't need all of the options that are there and does need some options that aren't there. I know that we could have a custom field, but we're trying to make this as easy as we can for the client.

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago #102142 by Mr. Dam
Replied by Mr. Dam on topic Changing/Adding Price for options
Hi Bws,
In fact, you can use Translation tool at Back-end of OS Property to filter and change the "Price for" field options. But if you want to modify source code, you can follow these steps
1. Open file:

root > components > com_osproperty > classes > listing.php

and

root > administrator > components > com_osproperty > classes > property.php

2. Find:
Code:
$timeArr[] = JHTML::_('select.option','',JText::_('OS_NOT_APPLICABLE')); $timeArr[] = JHTML::_('select.option','OS_PER_NIGHT',JText::_('OS_PER_NIGHT')); $timeArr[] = JHTML::_('select.option','OS_PER_WEEK',JText::_('OS_PER_WEEK')); $timeArr[] = JHTML::_('select.option','OS_PER_MONTH',JText::_('OS_PER_MONTH')); $timeArr[] = JHTML::_('select.option','OS_PER_SQUARE_FEET',JText::_('OS_PER_SQUARE_FEET')); $timeArr[] = JHTML::_('select.option','OS_PER_SQUARE_METRE',JText::_('OS_PER_SQUARE_METRE'));
here you can add new option for field Price for if you need.
Thanks
Dam

Please Log in or Create an account to join the conversation.

More
6 years 8 months ago - 6 years 8 months ago #102262 by BWS
Replied by BWS on topic Changing/Adding Price for options
I'm assuming that I'll have to be careful while updating to avoid overwriting the file.

Edit: Would it be possible to have custom Price for options as a feature in a future update.
Last edit: 6 years 8 months ago by BWS. Reason: feature request

Please Log in or Create an account to join the conversation.

More
6 years 4 months ago #106888 by MelanieB
Replied by MelanieB on topic Changing/Adding Price for options
Hi,

I would like to see this too as I forget I have made these changes and then when I upgrade the file in the classes folder is overwritten - even if we could add these changes to the template/html/ folder so they were not overwritten it woulds be better. I have a number of customisations that require changes to the classes files, so this would save a lot of work if they were not over-written every time I upgraded.

Mel

Please Log in or Create an account to join the conversation.

Moderators: Mr. DamNguyen Phu Quan