- Posts: 93
- Thank you received: 3
Plugins
12 years 3 months ago #161721
by bettston
-- url of the page with the problem -- :
mywebsite.com/mypage
-- HikaShop version -- : 2.3.1
-- Joomla version -- : 3.3
-- PHP version -- : x.x.x
-- Browser(s) name and version -- : XXXXX x.x.x
-- Error-message(debug-mod must be tuned on) -- : Error_message
Hi,
is there a place where all the current extra plugins are listed for download, in particular I need the custom_quantity plugin but cannot find it in the forum anywhere.
Thanks
Tony
-- HikaShop version -- : 2.3.1
-- Joomla version -- : 3.3
-- PHP version -- : x.x.x
-- Browser(s) name and version -- : XXXXX x.x.x
-- Error-message(debug-mod must be tuned on) -- : Error_message
Hi,
is there a place where all the current extra plugins are listed for download, in particular I need the custom_quantity plugin but cannot find it in the forum anywhere.
Thanks
Tony
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
12 years 3 months ago #161736
by Mohamed Thelji
Replied by Mohamed Thelji on topic Plugins
Hi Tony,
Here is the last version of the Hikashop custom_quantity plugin :
I thought this plugin was automatically installed through the the Hikashop install package.
Here is the last version of the Hikashop custom_quantity plugin :
This attachment is hidden for guests.
Please log in or register to see it.
Please log in or register to see it.
I thought this plugin was automatically installed through the the Hikashop install package.
Please Log in or Create an account to join the conversation.
12 years 3 months ago #161754
by bettston
Hi,
I couldn't see it in the install any way I have altered what is there to suit what I want but I cannot figure out how to get one calculation to work,
I altered the code to use ordered_length instead of quantity which works great but I also added a new field ordered_cutouts which is a dropdown with umbers 1 to 10.. This is supposed to add £15*the dropdown quantity to the price so if a customer enters 1.5 in length and pick 2 from the dropdown the total would be X x 1.5 + (15*dropdown)
I added this line to the secondond function in the code but its ignoring it
$product->order_product_total_price_no_vat = $product->order_product_price*$quantity+($product->ordered_cutouts*15);
$product->order_product_total_price = ($product->order_product_price+$product->order_product_tax)*$quantity+(($product->ordered_cutouts*15)*1.2);;
}
Have I done something wrong here or is there a better way? you can see what I am trying to achieve here:
demo.battleva.co.uk/nextday/next-day-cub...-vanity-and-frontage
Thanks
Tony
I couldn't see it in the install any way I have altered what is there to suit what I want but I cannot figure out how to get one calculation to work,
I altered the code to use ordered_length instead of quantity which works great but I also added a new field ordered_cutouts which is a dropdown with umbers 1 to 10.. This is supposed to add £15*the dropdown quantity to the price so if a customer enters 1.5 in length and pick 2 from the dropdown the total would be X x 1.5 + (15*dropdown)
I added this line to the secondond function in the code but its ignoring it
$product->order_product_total_price_no_vat = $product->order_product_price*$quantity+($product->ordered_cutouts*15);
$product->order_product_total_price = ($product->order_product_price+$product->order_product_tax)*$quantity+(($product->ordered_cutouts*15)*1.2);;
}
Have I done something wrong here or is there a better way? you can see what I am trying to achieve here:
demo.battleva.co.uk/nextday/next-day-cub...-vanity-and-frontage
Thanks
Tony
Please Log in or Create an account to join the conversation.
12 years 3 months ago #161764
by bettston
I have made a change ad left the length in as a variable and added the cutouts as an option.
The problem is that it calculates the length after adding the options to the price so they are not really option. How can I alter the plugin so that the length*price is calculated before the options are added on.
Thanks
Tony
The problem is that it calculates the length after adding the options to the price so they are not really option. How can I alter the plugin so that the length*price is calculated before the options are added on.
Thanks
Tony
Please Log in or Create an account to join the conversation.
Less
More
- Posts: 12953
- Thank you received: 1778
12 years 3 months ago #161801
by Mohamed Thelji
Replied by Mohamed Thelji on topic Plugins
Hello,
I didn't totally understood your issue, so can you tell me how do you exactly want to edit your product quantity and price regarding the value of your 2 custom fields ?
I didn't totally understood your issue, so can you tell me how do you exactly want to edit your product quantity and price regarding the value of your 2 custom fields ?
Please Log in or Create an account to join the conversation.
12 years 3 months ago #161887
by bettston
Hi,
The issue is that a customer can order any length he wants so with a length custom plugin at the point you add to cart it multiplies the price x length which is perfect but we also have an option which is number of cutouts these are £15 each . The problem is that the options field alters the price the moment you select so the price when you add to cart is (originsl price + options)* length. Whereas it should be (original price * length ) + options.
I dont mind changing the option to a custom field if necessary but i need to get the cutouts added to the price after the length calculation
Does this make sense?
Tony
The issue is that a customer can order any length he wants so with a length custom plugin at the point you add to cart it multiplies the price x length which is perfect but we also have an option which is number of cutouts these are £15 each . The problem is that the options field alters the price the moment you select so the price when you add to cart is (originsl price + options)* length. Whereas it should be (original price * length ) + options.
I dont mind changing the option to a custom field if necessary but i need to get the cutouts added to the price after the length calculation
Does this make sense?
Tony
Please Log in or Create an account to join the conversation.
12 years 3 months ago #161918
by Xavier
Hi,
So for your needs, you will have to edit the plugin in order to make the desired calculation.
It require good PHP knowledges, if you don't have this knwoledge you can ask to a third developer or post a request on the commercial jobs section of this forum.
So for your needs, you will have to edit the plugin in order to make the desired calculation.
It require good PHP knowledges, if you don't have this knwoledge you can ask to a third developer or post a request on the commercial jobs section of this forum.
Please Log in or Create an account to join the conversation.
12 years 3 months ago #162006
by bettston
Hi
I have no problem editing the plugin, however, what i ned guidance on is what trigger or $order fields i would need recalculate on. ie how do i manipulate the original price
Tony
I have no problem editing the plugin, however, what i ned guidance on is what trigger or $order fields i would need recalculate on. ie how do i manipulate the original price
Tony
Please Log in or Create an account to join the conversation.
12 years 3 months ago #162080
by Xavier
Hi,
In the trigger "hikashop_product_price_for_quantity_in_cart" you will have to change the value of "$product->prices", you should find all the required informations in the $product object.
And for the trigger "hikashop_product_price_for_quantity_in_order" you have to change the value of "$product->order_product_total_price_no_vat" and "$product->order_product_total_price".
As you can see in the plugin these things are the only ones which are edited.
In the trigger "hikashop_product_price_for_quantity_in_cart" you will have to change the value of "$product->prices", you should find all the required informations in the $product object.
And for the trigger "hikashop_product_price_for_quantity_in_order" you have to change the value of "$product->order_product_total_price_no_vat" and "$product->order_product_total_price".
As you can see in the plugin these things are the only ones which are edited.
Please Log in or Create an account to join the conversation.
Time to create page: 0.246 seconds