Jump to content

CraigA

Members
  • Posts

    42
  • Joined

  • Last visited

Profile Information

  • Gender
    Male
  • Location
    Toronto, ON

Recent Profile Visitors

885 profile views

CraigA's Achievements

Newbie

Newbie (1/14)

5

Reputation

  1. I know this has been asked before, but hopefully there is some kind of solution. I just had a customer put his credit card information in to a ticket. I want to remove the number so that I can't be held liable in the very slim chance that my Blesta instance/web server gets hacked. Any ideas?
  2. I ran it manually in cli and saw the output: Undefined variable: argv on line I was able to fix it by following @Evaske's instructions here http://www.blesta.com/forums/index.php?/topic/1226-cron-issues/?hl=cron (enable register_argc_argv)
  3. Manually runs fine. I've been trying to run it manually as much as I can to make sure account activations are completing.
  4. As the title says, cron hasn't been running since the upgrade. (or perhaps shortly before, not sure) I've been running it manually. I checked crontab as root and the cron string is in there. I'm not sure where else to look to trouble shoot this. Any ideas?
  5. $coupon = $GET['code']; $id = $api->put("Coupons", "add", array('code' => $coupon, 'company_id' => "1", 'max_qty' => "1", 'end_date' => "2013-11-17 03:59:59",'recurring' => "0", 'limit_recurring' => "0", 'packages' => array('0' => "10"), 'currency' => "USD", 'amount' => "100.0000"))->response(); returns "Internal error: Failed to retrieve the default value" can you point me in the right direction Tyson?
  6. Sounds good. I'm going to write a utility to iterate through this CSV and import it all the codes then. If I could get some confirmation on which tables need to be updated that would really help. Basically these Wag Jag coupon codes are going to give a 100% discount and will expire November 16th. I created a special package just for the Wag Jag customers, which got assigned package id "10" Looking at the DB I came up with this: table: coupons fields: id, code, company_id, used_qty, max_qty, start_date, end_date, status, type, recurring, limit_recurring table: coupon_amounts fields: coupon_id, currency, amount, type table: coupon_packages fields: coupon_id, package_id %fcid% = first coupon code available Pseudo code: for $i = %fcid% to 1500+%fcid% table coupons id = $i, code = from csv, company_id = my company id, used_qty = 0, max_qty = 1, start_date = 2013-10-08 00:00:00, end_date = 2013-11-17 00:00:00, status = active, type = exclusive, recurring = 0, limit_recurring = 0 table coupon_amounts coupon_id = $i, currency = my currency, amount = 100.0000, type = percent table coupon_packages coupon_id = $i, package_id = 10 loop other than these three tables, are there any other tables I would have to update with the utility for a successful import?
  7. Does anyone know a quick way to import coupon codes? WagJag.com is going to be running a special on my company and they've provided me with 1500 codes to import
  8. Life saver! I forgot to move over the definition. I really love your guys support.
  9. Hello all, I just upgraded from 3.0.1 to 3.0.4. I edited the app/controller/client_main.pdt to include custom field data as I have in all previous version, however, the info just isn't showing up anymore in the my info section of the main login for the client. (echoing the variable shows nothing). app/controller/client_main.pdt $myinfo_settings = array( 'invoice' => array( 'enabled' => ("true" == $client->settings['client_set_invoice']), 'description' => Language::_("ClientMain.myinfo.setting_invoices", true, $invoice_method_language) ), 'autodebit' => array( 'enabled' => true, 'description' => $this->getAutodebitDescription() ), 'customfield' => $field_values[0]->value ); app/view/client/default/client_main_myinfo.pdt $customfield = $this->Html->_($myinfo_settings['customfield'], true); echo "Custom field: <b>" . $customfield . "</b><br />"; Any ideas why this isn't working on the new version?
  10. Ahhh I didn't see the getByUserid there, must've been too tired. Thanks a lot Tyson, exactly what I needed
  11. Hello all, I'm trying to write something based on the API SDK $api = new BlestaApi($url, $user, $key); $response = $api->get("users", "getByUsername", array('username' => $_GET["username"])); $valid = $api->get("users","validatePasswordEquals", array('password' => $_GET["password"], 'user_id' => $response->response()->id)); //setCustomField( integer $field_id, integer $client_id, string $value ) //getCustomField( integer $field_id, integer $company_id = null ) $cf = $api->get("Clients","getCustomField", array('field_id' => 5)); print_r($response->response()); print_r($valid->response()); print_r($cf->response()); print_r($response->errors()); I'm pretty sure someone is going to tell me my logic is wrong here. Basically what I was going to do here is something along the lines of: if $valid->response() = 1 setCustomField(blah blah blah) The issue I'm having is although both the client_id and user_id exist in the 'clients' database table, I'm not sure how to equate the user_id to the client_id so that I can use the 'setCustomField' call. Any help/suggestions/reprimand for not doing this the correct way/pointers on how to do it the correct way? Thanks, Craig
  12. Must have been an anomaly on my end. Thanks for helping me verify Mike.
  13. Thanks Mike, Could you do me a favour and check the contents in the contacts table of your dev db? When this was recreated on my end it didn't show both ID's until the person with the new ID made a purchase. I just wonder if that might have something to do with it.
  14. do this without creating an invoice/buying a service to test. Regards, CraigA www.usaccess.ca
×
×
  • Create New...