AWOcoupon version 2.0.15 and Virtuemart 3.3.6: Cannot save new coupons


  • Default avatar
    jimbiddle    
     9 years ago
    0

    I have set up a new new website (Joomla 3.3.6), VirtueMart 3.0.2 (upgraded from Joomla 1.5.26 & VirtueMart 1.1.9 - Stable). This was created/ migrated by a VirtueMart migration tool called VirueMart Migrator. The upgrade was successful and the site operates well and the shop works OK. The website is: http://tinataylortemp.freesite.host/

    The 2 standard Viruemart coupons (using the built-in VirtueMart coupons) were migrated sucessfully and I was able to create another one without problems from within VirtueMart.

    I then installed the latest version of AwoCoupon: version 2.0.15 (for Virtuemart 3). The installation reported that it was successful. This is the free version.

    Unfortunately, I have not been able to save any new AwoCoupons (using the AwoCoupon control panel). I tried uninstalling and reinstalling the component but had the same result. Here are examples of error messages:

    1st attempt:
    An error has occurred.
    1054 Unknown column 'id' in 'field list' SQL=INSERT INTO `tmt_virtuemart_coupons` (`virtuemart_coupon_id`,`coupon_code`,`percent_or_total`,`coupon_type`,`coupon_value`,`coupon_start_date`,`coupon_expiry_date`,`coupon_value_valid`,`coupon_used`,`created_on`,`created_by`,`modified_on`,`modified_by`,`id`,`function_type`) VALUES ('0','test98','percent','gift','98','','','0','0','2014-12-29 10:22:33','831','2014-12-29 10:22:33','831','0','coupon')

    2nd attempt, using different parameters:
    An error has occurred.
    1054 Unknown column 'id' in 'field list' SQL=INSERT INTO `tmt_virtuemart_coupons` (`virtuemart_coupon_id`,`coupon_code`,`percent_or_total`,`coupon_type`,`coupon_value`,`coupon_start_date`,`coupon_expiry_date`,`coupon_value_valid`,`coupon_used`,`created_on`,`created_by`,`modified_on`,`modified_by`,`id`,`function_type`) VALUES ('0','test97','percent','gift','97','','','0','0','2014-12-29 10:25:52','831','2014-12-29 10:25:52','831','0','coupon')

    I read some of the posts on this error but these seem to be for earlier versions of AwoCoupon/ VirueMart. I am not confident about making changes to MySQL database but willing to give it a go - with an 'idiot guide'. I am happy to give over the site log-in and hosting admin panel log-in details if required - I am not sure how to do this without telling everyone who reads this.

    Thanks in advance for your help. I used the earlier (free) version of AwoCoupon on the Joomla 1.5 website/ shop and it was excellent. However, if I need to upgrade to the PRO version in order to get this working, please let me know.

    Very Best Regards,

    Jim Biddle.
    jimbiddlebsc@gmail.com


  • Your avatar
    seyi    
     9 years ago
    0

    Hello,

    The errors you posted are for the virtuemart coupon table, #__virtuemart_coupon. AwoCoupon does not alter this at all. It has its own table #__awocoupon. So exactly where are you getting this error? When you try to save a coupon in components->awocoupon? Do you see a trace of where that error is coming from? Maybe it is a plugin you installed that is somehow interacting with AwoCoupon?

    And no, you should not need the pro version, unless you need some of its functionality.
  • Default avatar
    jimbiddle    
     9 years ago
    0

    Thanks for your quick reply.

    I can confirm that the errors I see are when I save a new coupon in components->awocoupon. It's a new installation and so only have one other plug-in installed - this is AllVideos (by JoomlaWorks) which is a plugin for playing audio and video on the site. I tried unpublishing this plugin but still saw the same error.

    I also tried deleting all the coupons in the built-in VirtueMart Coupon section and then uninstalling the component and reinstalling (i.e. a clean install - with no coupons at all) - but that made no difference.

    I then looked at the tables in the MySQL database and saw that there were 4 tables associated with AWO coupon. They all report as being empty tables. When I uninstalled the AwoCoupon component, these tables disappeared. they reappeared after reinstalling the component.

    Here is a list of the 'awocoupon' tables and 'virtuemart coupons' tables that I can see in the database....

    Structure tmt_awocoupon_vm
    Structure tmt_awocoupon_vm_category
    Structure tmt_awocoupon_vm_history
    Structure tmt_awocoupon_vm_product
    Structure tmt_awocoupon_vm_user
    ..
    ..
    Structure tmt_virtuemart_coupons
    ..
    ..

    The table tmt_awocoupon_vm appears to have all the fields corresponding to the AwoCoupon Component control panel.

    The table tmt_virtuemart_coupons appear to have only those fields associated with the VirtueMart built-in coupon.

    So I can see what you mean that trying to save a AwoCoupon into the tmt_virtuemart_coupons table would fit with the error that is being reported when saving a new coupon.


    As a further test, I then added 2 of the standard VirtueMart coupons to the VirtueMart built-in coupon manager. These saved Ok and I could see these in the correct table: tmt_virtuemart_coupons.

    I then uninstalled and reinstalled the AwoCoupon Component. The above two coupons then showed in the table: tmt_awocoupon_vm.

    So, it appears that these 2 coupons were successfully saved (copied) to the correct table during the installation process of the AwoCoupon Component. i.e. AwoCoupon was able to access the correct table at this time.

    Again, saving a new coupon from within the AwoCoupon component produced the same error. Here it is for reference ....

    1054 Unknown column 'id' in 'field list' SQL=INSERT INTO `tmt_virtuemart_coupons` (`virtuemart_coupon_id`,`coupon_code`,`percent_or_total`,`coupon_type`,`coupon_value`,`coupon_start_date`,`coupon_expiry_date`,`coupon_value_valid`,`coupon_used`,`created_on`,`created_by`,`modified_on`,`modified_by`,`id`,`function_type`) VALUES ('0','jimtest90','percent','gift','90','','','0','0','2014-12-29 22:57:27','831','2014-12-29 22:57:27','831','0','coupon')

    It seems reasonable to me that if AwoCoupon could successfully generate and write to the correct table during the Component installation, then it should also be able to write to the correct table later on - i.e creating new coupons after installation.

    However, I am now at the end of things I can think of - Is there anything more I can do to help this along?

    Very Best Regards,

    Jim Biddle.



  • Your avatar
    seyi    
     9 years ago
    0

    Thanks for the detailed explanation. Unfortunately cant reproduce. I created a new install of Virtumeart 3.0.2, Joomla 3.3.6 and AwoCoupon 2.0.15 and for me, it just works.

    Is it possible to pm temp admin and ftp access so I can debug the problem?
  • Default avatar
    jimbiddle    
     9 years ago
    0

    Hi Seyi,

    I sent the PM email with all the information a few hours ago.

    And, I hope that you received it OK but if not, would you please let me know and I can re-send the information.

    Very Best Regards,

    Jim Biddle.
  • Your avatar
    seyi    
     9 years ago
    0

    Hi Jim,

    Thanks for the access. I have fixed your installation. Will be releasing a new version of the free version in the next 24 hours that includes the fix.
  • Default avatar
    jimbiddle    
     9 years ago
    0

    Hi Seyi,

    A big THANK YOU for your help and support.

    I checked it out on the website and, just as you said, it's all working now and this completes the Joomla + Virtuemart website upgrade for me.

    And I am glad to hear that you are updating the software with the fix, as this may hopefully help others as well.


    Very Best Regards,

    Jim Biddle.