Jump to content

EpoxyElegant

Member
  • Posts

    7
  • Joined

  • Last visited

Everything posted by EpoxyElegant

  1. EDIT: Found the culprit. It's within our code after all. Someone decided to reset the currency ID for some reason. We've been developing a module for our own custom solutions. Today, I noticed that the logged in user's currencyId is reset to '0' whenever they move back to the previous page. The flow of our custom module is like this: User chooses product -> Opens custom order page -> user proceeds. If the user decided to press back, their currencyId will be reset to '0'. The back button is simply a href to the previous page. None of the module actions write to the user's currencyId, only reading them. I noticed this while debugging the multi-currency bug we've been getting. Did anyone else had the same problem? If yes, how do I stop this behaviour?
  2. Hi, sorry for the bump. Not sure if I should make a new thread since I asked the question in this thread although the question is a different question than the one in the OP. I explained the need in the 2nd post, however. Anyway, the question was, is there any hook that I can use that would trigger immediately after an Admin created a new order into a customer's account? I want to use the hook to run some custom codes or scripts and then send out an email to the customer about the new order which the Admin added into their account. Thank you in advance!
  3. Thank you, @WHMCS Marcus and @radwebhosting. So, in order to make this work with an admin created order, the order need to be accepted first. Is there a hook that I can use so that my script would be executed immediately after adding an order for a specific type of products?
  4. I can't edit my post, so I'll write this here. What I'm trying to do is run a script that will trigger right after an Administrator creates a new order. The hook will grab the order and executes some codes to do stuff internally. I tried AfterModuleCreate, but the hook wasn't triggered after adding an order from the admin dashboard. I also added some lines of codes that should add an entry into the Modules Log. No entries were added so I assumed it did not work. So what hook should I use? Why can't WHMCS just make a hook that is executes after an order has been placed and checked out (completed), regardless of it being paid or not. $params should provide us those value about the payment and whether it's from admin or client. Or just make two separate hooks for that. But anyway, I have to make do with just what I have right now. I'm certain that AfterModuleCreate is the right one but I still can't get it to work.
  5. Hello, I'm trying to use the AfterModuleCreate hook but I don't understand how or what triggers this hook. The documentation says, "Executes upon successful completion of the module function." I thought that was helpful enough but it's not. What module function? What determines it's success? When does this happen? Is it after adding an order? Can this be triggered when adding an order from the admin dashboard immediately without changing any of the status? Thank you.
  6. @Kian That's a great idea, thank you. But how do I do that? I looked through the Hooks Index, there doesn't seem to be any hooks that I can use like "ProductAdd"?
  7. Hello, I am developing an extension for WHMCS that integrates a certain product with WHMCS. The provisioning module will provide the product module that our users can choose in the Module Settings tab when adding a new product. This product requires a lot of custom fields. Is there any way to define custom fields for a product through the module itself? It doesn't make sense to let users of the module to add the custom fields manually for every single product they want to add. Any suggestions and ideas are very much appreciated. Thank you!
×
×
  • 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