stelz Posted January 27, 2010 Share Posted January 27, 2010 Hello, i want integrate our control panel and write module, but i don`t understand how to write Custom Field value from module script to billing system automatic. I create Custom Field - veid How i can set "veid" parmeter(returned from control panel api) in function myadmin_CreateAccount($params) for save it? I see this work in HyperVM and SolusVM modules, but sources is closed. Please help me, thanks! 0 Quote Link to comment Share on other sites More sharing options...
stelz Posted January 28, 2010 Author Share Posted January 28, 2010 Answer on my ticket: Hi, To set a custom field value from within a module function you would need to perform an SQL update query on the database directly, for example: mysql_query("UPDATE tblcustomfieldsvalues SET value='xxxx' WHERE fieldid=X and relid=$params['serviceid']"); Regards, Matt 0 Quote Link to comment Share on other sites More sharing options...
zoilodiaz Posted February 20, 2010 Share Posted February 20, 2010 Hello, a module for SolusVM like this one ? http://wiki.solusvm.com/index.php/HostBill_Module 0 Quote Link to comment Share on other sites More sharing options...
cwik Posted August 19, 2012 Share Posted August 19, 2012 Opening up an old thread because my question seems relevant. I have written a custom module, which has 3 custom fields to store the server, username and password for the product. The custom fields are displayed in the client area. All the integration (create, suspend, unsuspend, delete) works great, and now I want to allow changing passwords by the user. I've written a <module>_ChangePassword function and got it to work fine. To update the custom field with the new password, I use: # Update the DB $ChangePassword_query = "UPDATE tblcustomfieldsvalues SET value='".$vpn_password."' WHERE fieldid='5' AND relid=".$params['serviceid']; mysql_query($ChangePassword_query); The only problem is that the password displayed after a successful update is the previous password. To see the new password, I have to go back to services list then view details again, at which point the new password is displayed. Is there any way to update the display of the custom fields in the ChangePassword function, or are the values already loaded into the template before the function runs? Thanks in advance. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.