Forums / Developer / Donation module instead of Shop

Donation module instead of Shop

Author Message

Rana Faheem

Wednesday 23 April 2008 11:31:30 pm

Hello All,
I am developing a site for NGO here i am dealing Donation module in which donation is paid through Paypal for three categories
Projects (Pay for one project from the project list)
Direct For NGO itself
For different poor families (Pay for one family at a time )
I want to ask how i can customize the shop for these or i have to develop a new module.
Please guide me.

With Regards
Amir Faheem

Bruce Morrison

Thursday 24 April 2008 12:26:56 am

Hi

Have a look at http://ez.no/developer/forum/developer/shop_donation . It's quite long but probably worth your while having a look.

The end result, at least on my part, was: http://www.thebutterflyfoundation.org.au/how_to_support_butterfly/donations

I ended up created a specific donation content type with a price & options attribute. In the actual content object the price is 0 and the various donation amounts are set in the options.

These will also make good reading:
http://ez.no/doc/ez_publish/technical_manual/4_0/concepts_and_basics/webshop
http://ez.no/doc/ez_publish/technical_manual/4_0/reference/datatypes/price
http://ez.no/doc/ez_publish/technical_manual/4_0/reference/datatypes/option

Cheers
Bruce

My Blog: http://www.stuffandcontent.com/
Follow me on twitter: http://twitter.com/brucemorrison
Consolidated eZ Publish Feed : http://friendfeed.com/rooms/ez-publish

Rana Faheem

Monday 28 April 2008 2:38:44 am

Hi Bruce Morrison,
Thank you for your Answer and hoping again.
I read all the links you mentioned. Now what i did.I copied the shop module and made copy with the name Donation and with parallel /shop/basket.tpl i can access /donation/basket.tpl
I want to customize the donation module. Now Its working but when i used donate button whose link is given in line_view_donation.tpl
and link should follow template in

  <a href={"/donation/basket"|ezurl}>
      <div>
{attribute_view_gui attribute=$node.object.data_map.ngoimage image_class ="small"}
         <div class="basketlink">
                     <a class="tobasket" href={"donation/basket" | ezurl}>
                            <input class="button" type="submit" name="ngoDonate" value="{'Donate'|i18n('design/ezwebin/donation/basket')}" />
                    </a>

          </div>
   </div>
      </a>

It is going in /shop/basket template.If i make changes here it will effect to webshop for which i am using this and i want separate behavior from donation and webshop.

with Regards
Rana Amir Faheem

Bruce Morrison

Monday 28 April 2008 3:38:00 am

Hi Rana

I don't understand why you copied the shop module to do this. There are many ways (discussed the thread from my previous message) to do this that don't require such a drastic approach.

Perhaps you can outline your reasoning for this approach?

cheers
Bruce

My Blog: http://www.stuffandcontent.com/
Follow me on twitter: http://twitter.com/brucemorrison
Consolidated eZ Publish Feed : http://friendfeed.com/rooms/ez-publish

Rana Faheem

Monday 05 May 2008 11:04:23 pm

Hi Bruce Morrison,

I want to keep separate basket for both webshop and donation module and
some changes in donation module that will not effect in the working of webshop
see one website

http://www.sciaf.org.uk/

and also site referred by you both consider donation in different way even some columns are not required used in it just to continue the shop.

with Regards
Rana Amir Faheem

Rana Faheem

Wednesday 07 May 2008 4:32:57 am

Hello All,

Currently i am facing a problem that is related to basket.I want different basket for two modules one for donation and second is obviously webshop.
When i select items for donation after that items from webshop can be selected and vice versa for webshop that in real i do not want to do in this way.

But i want this deal separate. Webshop items should deal nothing with donation items.

what i think one object of basket is created and all selected items goes in to that current global basket.

Now any one can guide me here to deal the situation and HOW?

With Regards
Rana Amer Faheem

eZ debug

Timing: Jan 18 2025 15:54:48
Script start
Timing: Jan 18 2025 15:54:48
Module start 'content'
Timing: Jan 18 2025 15:54:49
Module end 'content'
Timing: Jan 18 2025 15:54:49
Script end

Main resources:

Total runtime1.2358 sec
Peak memory usage4,096.0000 KB
Database Queries203

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0074 591.4375180.8359
Module start 'content' 0.00741.0403 772.2734598.5156
Module end 'content' 1.04770.1881 1,370.7891341.3750
Script end 1.2358  1,712.1641 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00420.3371210.0002
Check MTime0.00160.1281210.0001
Mysql Total
Database connection0.00100.079110.0010
Mysqli_queries1.139492.19432030.0056
Looping result0.00230.18242010.0000
Template Total1.205197.520.6026
Template load0.00180.148320.0009
Template processing1.203397.364820.6016
Template load and register function0.00010.008310.0001
states
state_id_array0.00110.086610.0011
state_identifier_array0.00260.211820.0013
Override
Cache load0.00160.1319630.0000
Sytem overhead
Fetch class attribute can translate value0.00120.096230.0004
Fetch class attribute name0.00140.115780.0002
XML
Image XML parsing0.00500.407330.0017
class_abstraction
Instantiating content class attribute0.00000.0019120.0000
General
dbfile0.00820.6625330.0002
String conversion0.00000.000530.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
11content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
17content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 44
 Number of unique templates used: 7

Time used to render debug report: 0.0002 secs