maxipack-showroom /

Filename Size Date modified Message
apibased
basic
blueprintcss
common-apps
media
showroom
templates
335 B
3.7 KB
0 B
524 B
72 B
107 B
677 B
272 B
689 B
2.3 KB
504 B
DEV ENVIRONMENT
===============

This project uses http://www.allbuttonspressed.com/projects/djangoappengine

Setup
-----
Change dir to projects.

Clone repos:
hg clone http://bitbucket.org/wkornewald/djangotoolbox|django-nonrel|djangoappengine

hg clone https://fikander@bitbucket.org/fikander/django-registration # Version that works with django-nonrel and djangoappengine

svn checkout http://django-tagging.googlecode.com/svn/trunk/ django-tagging

hg clone https://fikander@bitbucket.org/jezdez/django-staticfiles

hg clone http://bitbucket.org/jespern/django-piston

Your folder structure should now look similar to this:

    * .../django-nonrel/django
    * .../djangoappengine
    * .../djangotoolbox
    * .../maxipack-pl
    * .../maxipack-pl/common-apps/djangoappengine -> ../../djangoappengine
    * .../maxipack-pl/common-apps/djangotoolbox -> ../../djangotoolbox
    * .../maxipack-pl/common-apps/django -> ../../django-nonrel/django

    .../maxipack-pl/common-apps/registration -> ../../django-registration/registration
    .../maxipack-pl/common-apps/tagging -> ../../django-tagging/tagging
    .../maxipack-pl/common-apps/staticfiles -> ../../django-staticfiles/staticfiles
    .../maxipack-pl/common-apps/piston -> ../../django-piston/piston

NOTE: Example of making symbolic links in Windows:
D:\cygwin\home\tomek>mklink /D maxipack-pl\common-apps\piston ..\..\django-piston\piston

NOTE: Setup hosts file (<WINDOWS>/System32/drivers/etc/hosts) to map dev.maxipack.pl to localhost:
127.0.0.1 dev.maxipack.pl

SMTP mail server
----------------
Application sends some emails, so you need to have SMTP server working in order to test it.
Run server by running python script utils/smtp_server.py
Server will store all mails in _mail directory.

NOTE: This doesnt work (due to appengine SDK bug) with Python 2.5.4. Use python 2.5.2 or 2.6 instead.

DEPLOYMENT
============

#!/bin/bash

rm -rf ./_staticfiles
./manage.py build_static --noinput
./manage.py deploy


TEST DATA
==========

./manage.py loaddata products/sample.json
./manage.py loaddata bundles/sample.json

OR

./manage.py maxipack_init


Python/cygwin setup
===================

- install cygwin, with:
  - make
  - gcc
  - python 2.5.2

- install easy_install: http://pypi.python.org/pypi/setuptools
  download .egg and execute like sheel script (bash ....egg)
- install PIL:
- install Sphinx: easy_install -U Sphinx

- build django documenation:
  >cd django-nonrel/docs
  >make html

  
TODO
====

Integration types:
 - maxipack site shop
   - add fake payment system integration
   - add paypal fake integration
 - widget - simple version
   - how to know in widget that calls come from valid website (hacker didnt integrate hijacked widget) - widget has to pass http_referer or sth like that - research necessary - how to communicate with JS inside iframe??
   - http://www.dyn-web.com/tutorials/iframes/
   - http://www.dyn-web.com/tutorials/iframes/refs.php
   - after user selected stuff - redirect to maxipack payment system (separate page or in-place?)
 - widget - more involved stuff
   - widget has to pass data about current price outside, so that customer's site can do checkout
     - client side - javascript somehow?
     - server side - through transaction id: widget pushes transaction id, customer's server retrieves it - how to communicate transaction id form widget to customer? callback?
     - things client should know: customer's session id, email of user (to send things)
     - things server should know: transaction id, so that he can then mark transaction with 'paid'
 - full integration - copy of maxipack site shop using API
   - should maxipack site shop itself be implemented using API - probably easier!
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.