CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • CiviDiscount Module Extension
Pages: [1] 2 3 ... 8

Author Topic: CiviDiscount Module Extension  (Read 24793 times)

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
CiviDiscount Module Extension
May 23, 2012, 01:48:38 pm
On a Drupal 7.14 CiviCRM 4.1.2 site I followed the instructions at https://github.com/dlobo/org.civicrm.module.cividiscount/wiki/Install-instructions-for-4.1.x and it installs but on civicrm/cividiscount/discount/list&reset=1 I get

Fatal error: Cannot make non static method CRM_Core_DAO::getTableName() static in class CDM_DAO_Item in /home/xxx/www/www/sites/all/extensions/dlobo-org.civicrm.module.cividiscount-5f105ae/CDM/DAO/Item.php on line 367
CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

Hershel

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4640
  • Karma: 176
    • CiviHosting
  • CiviCRM version: Latest
  • CMS version: Mostly WordPress and Drupal
Re: CiviDiscount Module Extension
May 23, 2012, 02:03:56 pm
A bit more data. I ran civicrm/menu/rebuild?reset=1 according to the install several times, but civicrm/cividiscount/discount/list&reset=1 was just showing the dashboard. Finally I thought to run

civicrm/menu/rebuild?reset=1&directoryCleanup=3

and now half the CiviCRM pages show the above error. Furthermore, I can't disable the extension via the web interface. No event pages work now.

I didn't see how (offhand) to disable via the DB, so I changed the function getTableName to be not static and anyhow now the site works, and civicrm/cividiscount/discount/list&reset=1 also works--at least I see the page.

CiviHosting and CiviOnline -- The CiviCRM hosting experts, since 2007

See here for the official: What to do if you think you've found a bug.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: CiviDiscount Module Extension
May 23, 2012, 08:44:25 pm

The 4.1 module extension has a few bugs like cannot disable cleanly etc. Definitely not recommended to use it unless u know what u r doing / willing to debug etc

I fixed the static issue and created a new 4.1.1 tag

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

joshathedone

  • I post occasionally
  • **
  • Posts: 50
  • Karma: 0
  • CiviCRM version: Civicrm4
  • CMS version: Drupal 7
  • MySQL version: 5.1.41
  • PHP version: 5
Re: CiviDiscount Module Extension
June 05, 2012, 05:53:01 am
Having the same problem on 4.1.1.  Can anyone advise how to manually uninstall the extension?

joshathedone

  • I post occasionally
  • **
  • Posts: 50
  • Karma: 0
  • CiviCRM version: Civicrm4
  • CMS version: Drupal 7
  • MySQL version: 5.1.41
  • PHP version: 5
Re: CiviDiscount Module Extension
June 05, 2012, 05:56:20 am
FYI, changing "Static Function" to Function in Item.php allows me to use my site without getting the error.  Does not make Cividiscount work.

zkrebs

  • I post occasionally
  • **
  • Posts: 69
  • Karma: 1
Re: CiviDiscount Module Extension
June 05, 2012, 09:55:33 am
I tried the steps and I can't even get it to find the admin section, and it also won't uninstall. Hmmm.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: CiviDiscount Module Extension
June 05, 2012, 11:01:51 am

the 4.1.1 zip from github should have fixed the static issue

You can delete the option_value record found via the below sql:

select v.* from civicrm_option_value v, civicrm_option_group g where g.name = 'system_extensions' and v.option_group_id = g.id;

for 4.1 to disable the extension

lobo


A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

joshathedone

  • I post occasionally
  • **
  • Posts: 50
  • Karma: 0
  • CiviCRM version: Civicrm4
  • CMS version: Drupal 7
  • MySQL version: 5.1.41
  • PHP version: 5
Re: CiviDiscount Module Extension
June 06, 2012, 04:24:55 am
@Lobo - Thanks, I am going to try uninstalling and reinstalling 4.11.1 in case I did something wrong.  Before I run the above sql against my database do I run it exactly as typed above or do I need to substitute somewhere?

zkrebs

  • I post occasionally
  • **
  • Posts: 69
  • Karma: 1
Re: CiviDiscount Module Extension
June 11, 2012, 02:22:14 pm
I upgraded to CiviCRM 4.1.3 on D6 and when I enable the extension (4.1.1 tag) it seems to enable OK. When I rebuild menus it does that (but menu appears black/blank after rebuild, until I reload). Then I notice that most of my Admin URLs's, and public contribute pages all produce 500 error, until I disable the module, then they work again.

What's going on? I absolutely need this tool for a project - would be willing to contribute to get it fixed.

4.1.1 definitely not working.
Tried again with 4.1 version and it works, but only works with % discounts. How can I get $ discounts to work?
« Last Edit: June 11, 2012, 03:19:16 pm by zkrebs »

mclyde

  • I post frequently
  • ***
  • Posts: 171
  • Karma: 3
    • International Society for Bayesian Analysis
  • CiviCRM version: 4.2.7
  • CMS version: Drupal 6.x
  • MySQL version: 5.136
  • PHP version: 5.2.16
Re: CiviDiscount Module Extension
June 13, 2012, 08:30:54 pm
Zkrebs -  I have two sites where I really want to use the module (did get it installed under 4.1.2 and D6 after a couple of wrong starts)

I would be interested in also supporting a MIH project to support development of it - I was going to start a blog on this to see what the community interest is but just need to get some free time!

best,
Merlise
Merlise Clyde

PRedmond

  • I’m new here
  • *
  • Posts: 21
  • Karma: 0
Re: CiviDiscount Module Extension
June 27, 2012, 11:51:04 pm
Confirming the "Cannot make non static method" error still exists.

PRedmond

  • I’m new here
  • *
  • Posts: 21
  • Karma: 0
Re: CiviDiscount Module Extension
June 27, 2012, 11:52:38 pm
Also confirming that the module doesn't disable from the Extensions page

czmike

  • I’m new here
  • *
  • Posts: 1
  • Karma: 0
  • CiviCRM version: 4.1.0
  • CMS version: Drupal
  • MySQL version: 5.1.41
  • PHP version: 5.3.2
Re: CiviDiscount Module Extension
June 28, 2012, 10:49:42 am
I am also having the same error message and the module is not disabling  :(

ChrisChinchilla

  • I post occasionally
  • **
  • Posts: 104
  • Karma: 3
  • CiviCRM version: 4.1.2
  • CMS version: Drupal 6 & 7
Re: CiviDiscount Module Extension
July 16, 2012, 06:33:21 pm
Can't get this to work either… Tried the 4.1.1 tag to… Nothing really happens, though I'm not entirely sure what is supposed to happen as there's no documentation (Happy to help write when I know what's supposed to happen!)

Is the best thing at this point to support the MIH?
Melbourne CiviCRM meetup group - http://www.meetup.com/MelbourneCiviCRM/

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: CiviDiscount Module Extension
July 16, 2012, 08:13:03 pm

hey chris:

did u follow the instructions here:

https://github.com/dlobo/org.civicrm.module.cividiscount/wiki/Install-instructions-for-4.1.x

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1] 2 3 ... 8
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviEvent (Moderator: Yashodha Chaku) »
  • CiviDiscount Module Extension

This forum was archived on 2017-11-26.