Jump to content

Believe_

Member
  • Content Count

    19
  • Joined

  • Last visited

Community Reputation

0 Neutral

1 Follower

About Believe_

  • Rank
    Junior Member

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hi @steven99, @brian! But there is no other AcceptOrder hook present, so how do another hook process when we perform an order accept? If you wish, I could provide the full hook content to review it further. Please advise
  2. Hi @steven99, @brian! , @DennisHermannsen Sorry for the delay as I was on holidays and affected Covid-19. I implemented this check in one of our AcceptOrder hook, and it works perfectly however, noticed an error in Activity Log when we place a order for the product that is not in list as below. Any idea why this is occuring? Email Sending Failed - Invalid user id provided (Subject: Reset your password) This is coming just before the 'Order Accepted - Order ID: 105' line in Log and tested several times and same happening. Any idea from where this email is trying to generate and fail? I think the if statement [if (in_array( $Serviceid->packageId, $ProductsCaredAbout) )] is failing and trying to generate this message. Any way to get rid of this one? Otherwise everything okay with this one. Thanks, Fasal
  3. Hello @steven99, Thanks for your reply, and I've hooks for following actions: AddonActivation AcceptOrder AfterModuleCreate AfterProductUpgrade AddonTerminated AfterModuleTerminate Please shed some light on how to implement this with if/switch case with sample codes Thanks
  4. Hello @steven99 Can you provide a sample code for this with if statement for one product alone and an array of products, that would be much helpful. Thanks
  5. Hello, We have a few hooks on our system to run some additional tasks while accepting order, and which is working fine on our system. We are planning to create a few more products for which we don't have to run these hooks (rather a different hook functions). I don't see any way to execute hooks against a specific product(s) as it seems globally executing on all products. I've seen a thread on this community from back 2013 but no response on it - Please let me know if this is even possible? If yes, how can we apply it or a if condition to check out the product might get it done but not sure how we could integrate it with so sample code would be helpful. @DennisHermannsen / @brian! - you both have been helpful so far with such things, so any advise on this would be appreciable 🙂 Please shed some light on this as soon as possible, thanks 🙂
  6. Any update on above guys? @DennisHermannsen you were helpful in other thread (thanks for that). Any idea about this you could share? Thanks, 🙂
  7. Hello, I was looking to create a product with setup fee, but have a doubt with its payment style. The product cost is $20 and setup fee is $5, so the first payment a client should pay would be $25 and renewals would be $20 going forward. Here the doubt is, when the client make the payment through Paypal it should ask for adding recurring payment subscription to automate future payments. Does this subscription would have the first invoice amount of $25 (including setup fee) or just the product price $20? If the setup fee include in Paypal subscription, then is there any way to avoid this on Paypal subcriptions? Since the renewal is $20 and Paypal subscription adds for $25, then the extra $5 would be add as credit for nothing and may cause so much confusion. Can anyone advise me on this working style, and thanks in advance! 🙂
  8. @DennisHermannsen I've tested this and put it in production and all works fine until now. Something I missing out is a notification email to administrators, is this something you could implement on this?
  9. Great @DennisHermannsen There shouldn't be that case you've mentioned at first, since only one Late Fee entry would be there on a invoice. Even if there are multiple items, there should only be one Late Fee line so there is no issues with it. Anyway, I'll test this out with my test cases and let you know the result as soon as possible. Did you also include the email notifications to the administrator users upon these actions? If this even possible to implement? If so, including that would be a good function. Thanks very much for this help, much appreciated 🙂
  10. He @DennisHermannsen At this stage with that above hook code; If the invoice having the item + Late Fee, then when we terminate the service the item gets removed from the invoice but since the Late fee is there the invoice remains unpaid with just the late fee amount. If the last remaining line is Late fee then the invoice should mark as cancelled.
  11. Just a correction on my above screenshot, that was manually edited invoice item. Here is the actual WHMCS created late fee table raw: http://i.is.cc/1HYVpUpj.png The type column has the unique "LateFee" text by default, so I guess we could get it by cross checking the invoice id + type section and get it removed. Any help would be much appreciated 🙂
  12. Hi @DennisHermannsen I've gone through this and here are the details that you asked. WHMCS invoice page: http://i.is.cc/1HU5jht3.png Database has this line in "tblinvoiceitems" table: http://i.is.cc/1HTJHzBc.png When the Late Fee added to an invoice, I guess it is adding a new table row in tblinvoiceitems as shown in above screenshot. I hope this information is enough to include on above hook functions. Please also include a email notification to all administrators when an invoice modified and invoice cancelled. Please let me know if you require any further information/details. Thanks, 🙂
  13. @DennisHermannsen Thanks for including all these functions, however, I've come across a silly mistake on this hook. The invoices that has the Late Fee added which is treating as a separate line, so the item gets removed from the invoice and invoice stay unpaid with just the Late fees value. This is not correct! I think it is best to add an additional check for the remaining line is whether Late fee or not, and if yes, then cancel off the entire invoice. I'm also looking to add an email notification of these actions to administrators along with that activity log entries. Can you sort this up or help me to include these two functions on above hook, that would be highly appreciated :)
  14. Hello, I was looking to create a promo code that can be applied only if the customer purchased 5 services at a time while ordering. Also, those clients who have at least 5 active services on their account should be able to use this promo code to get the discount. Is there any way to set this up? Also, if the client purchased 10 service at a time or when they has 10 active services, then need to provide quite more discount with another promo code. Is it possible to set up? Any help/advise would be much appreciated. Thanks, 🙂
  15. Hello Guys, I was writing up a hook to run while activating an Addon product. The issue I found is the vars on AddonActivation is throwing the values twice that affecting my script. For eg: The debug output shows in accaddon.log file is: Here the service id is 16 and client id is 1, the output should be like 161 not 161161. Why this hook throwing the values twice? I also tried AddonActivated hook but this even not showing anything. Can someone shed some light on this, thanks 🙂
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated