some advice please: billing + shipping address

Author Message

Pascal Specht

Wednesday 11 July 2007 4:24:13 am

Hi friends,

I need a quick advice on how to best proceed to customize eZ Publish's user class for doing e-commerce. I'm pretty sure some of you already did that before, and I would like to avoid reinventing the wheel. It may well be that I've overseen some contributions or configuration settings, so I'm looking forward for your feedback.

Here's what I need, and how I solved it so far:

<i>1. a user should be able to add products to a cart without being identified.</i>
(solved with a role: anonymous:shop/buy/no limits)

<i>2. a user should be able to sign up with just a few infos: e-mail, first and last name and username.</i>
Since I didn't like the way it was done in ezwebin, I wrote an extension, and wrote templates
for user/login.tpl, user/register.tpl etc to fit my needs.

<i>3. If a user goes to actually buy something, I need the user to complete both a billing AND a shipping adress latest now.</i>
I did not really find if there's a best/easiest way to do that: Should I modify the user class and add all the address fields as class attributes? Or should I create an address class, and attach it to the user? Did someone already write this kind of things as an extension? I didn't find it... The user's information should be persistant, i.e. the user should be able to change it via 'my account' at a later moment.

<i>4. Is there already a good shipping handler?</i>
I've been looking into the fedexshipping extension, but it looks very hard-coded and more of a quick solution for a field problem than a generic approach...

Thanks a lot in advance!

-Pascal

Clay Pereira

Wednesday 11 July 2007 10:20:47 am

Hi Pascal,

We we released our older version of our shipping extension through Brookins Consulting. Graham added significant documentation and cleaned up the code. You can find it in the projects area, BC_Static_shipping. http://projects.ez.no/bcstaticshipping

This is a good example to follow. We will be releasing our real time shipping extension which grabs current UPS and USPS shipping rates in the near future. You can see it in action by going to http://Alconeco.com The static shipping was the base for our real time extension developed by Ez Partner Xrowe.

Additionally you may want to look at this extension http://projects.ez.no/recurringorders

Pascal Specht

Friday 13 July 2007 6:20:39 am

Hi Clay,

Many thanks you for the information, I'm going to have a look at the topics and ideas you suggested.

Pascal

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 11:43:45
Script start
Timing: Jan 18 2025 11:43:45
Module start 'layout'
Timing: Jan 18 2025 11:43:45
Module start 'content'
Timing: Jan 18 2025 11:43:45
Module end 'content'
Timing: Jan 18 2025 11:43:45
Script end

Main resources:

Total runtime0.0194 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0073 589.2813152.6563
Module start 'layout' 0.00730.0043 741.937539.5078
Module start 'content' 0.01170.0047 781.445389.3984
Module end 'content' 0.01630.0030 870.843834.3047
Script end 0.0193  905.1484 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.003518.1718140.0003
Check MTime0.00189.0625140.0001
Mysql Total
Database connection0.00126.147010.0012
Mysqli_queries0.003719.057130.0012
Looping result0.00000.124210.0000
Template Total0.002010.510.0020
Template load0.00115.741210.0011
Template processing0.00094.677610.0009
Override
Cache load0.00084.043110.0008
General
dbfile0.00031.664980.0000
String conversion0.00000.056640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs