diff options
author | Étienne Loks <etienne.loks@peacefrogs.net> | 2012-10-07 20:09:26 +0200 |
---|---|---|
committer | Étienne Loks <etienne.loks@peacefrogs.net> | 2012-10-07 20:09:26 +0200 |
commit | 94c23b986d3986667351971487761d59f9c50438 (patch) | |
tree | 3c63223e9df46af086649435a39b328d90763f86 | |
parent | 1d216cca64eaaf222a8dbceca5eda361634baec7 (diff) | |
download | Chimère-94c23b986d3986667351971487761d59f9c50438.tar.bz2 Chimère-94c23b986d3986667351971487761d59f9c50438.zip |
Move default data to another JSON file.
-rw-r--r-- | chimere/fixtures/default_data.json | 69 | ||||
-rw-r--r-- | chimere/fixtures/initial_data.json | 67 | ||||
-rw-r--r-- | docs/install.rst | 5 |
3 files changed, 74 insertions, 67 deletions
diff --git a/chimere/fixtures/default_data.json b/chimere/fixtures/default_data.json new file mode 100644 index 0000000..56df4c3 --- /dev/null +++ b/chimere/fixtures/default_data.json @@ -0,0 +1,69 @@ +[ + { + "pk": 1, + "model": "chimere.colortheme", + "fields": { + "name": "Blue" + } + }, + { + "pk": 1, + "model": "chimere.color", + "fields": { + "code": "0000FF", + "color_theme": 1, + "order": 10 + } + }, + { + "pk": 2, + "model": "chimere.color", + "fields": { + "code": "2222FF", + "color_theme": 1, + "order": 20 + } + }, + { + "pk": 3, + "model": "chimere.color", + "fields": { + "code": "4444FF", + "color_theme": 1, + "order": 30 + } + }, + { + "pk": 1, + "model": "chimere.category", + "fields": { + "available": true, + "description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc blandit porta eros, quis varius orci luctus nec. Suspendisse tempor sagittis tortor. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Vivamus imperdiet consequat dolor. Etiam risus orci, auctor nec hendrerit ut, congue at ante. Aliquam et accumsan neque. Aliquam ac massa felis, ac porttitor nunc. Curabitur blandit odio id enim sodales blandit. Curabitur eleifend commodo lorem a feugiat. Nam at quam semper justo ultricies tempor.\r\n", + "name": "Default category", + "order": 10 + } + }, + { + "pk": 1, + "model": "chimere.icon", + "fields": { + "width": 21, + "image": "icons/marker.png", + "name": "Default icon", + "height": 25 + } + }, + { + "pk": 1, + "model": "chimere.subcategory", + "fields": { + "category": 1, + "available": true, + "name": "Default subcategory", + "item_type": "M", + "color_theme": null, + "order": 10, + "icon": 1 + } + } +] diff --git a/chimere/fixtures/initial_data.json b/chimere/fixtures/initial_data.json index fe1cc98..473640c 100644 --- a/chimere/fixtures/initial_data.json +++ b/chimere/fixtures/initial_data.json @@ -1,72 +1,5 @@ [ { - "pk": 1, - "model": "chimere.colortheme", - "fields": { - "name": "Blue" - } - }, - { - "pk": 1, - "model": "chimere.color", - "fields": { - "code": "0000FF", - "color_theme": 1, - "order": 10 - } - }, - { - "pk": 2, - "model": "chimere.color", - "fields": { - "code": "2222FF", - "color_theme": 1, - "order": 20 - } - }, - { - "pk": 3, - "model": "chimere.color", - "fields": { - "code": "4444FF", - "color_theme": 1, - "order": 30 - } - }, - { - "pk": 1, - "model": "chimere.category", - "fields": { - "available": true, - "description": "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc blandit porta eros, quis varius orci luctus nec. Suspendisse tempor sagittis tortor. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Vivamus imperdiet consequat dolor. Etiam risus orci, auctor nec hendrerit ut, congue at ante. Aliquam et accumsan neque. Aliquam ac massa felis, ac porttitor nunc. Curabitur blandit odio id enim sodales blandit. Curabitur eleifend commodo lorem a feugiat. Nam at quam semper justo ultricies tempor.\r\n", - "name": "Default category", - "order": 10 - } - }, - { - "pk": 1, - "model": "chimere.icon", - "fields": { - "width": 21, - "image": "icons/marker.png", - "name": "Default icon", - "height": 25 - } - }, - { - "pk": 1, - "model": "chimere.subcategory", - "fields": { - "category": 1, - "available": true, - "name": "Default subcategory", - "item_type": "M", - "color_theme": null, - "order": 10, - "icon": 1 - } - }, - { "pk": 7, "model": "chimere.multimediatype", "fields": { diff --git a/docs/install.rst b/docs/install.rst index a6d3558..c8b91b3 100644 --- a/docs/install.rst +++ b/docs/install.rst @@ -242,6 +242,11 @@ to create tables managed with south:: The database is set, congratulations! +If you want to populate your installation with default data (don't do this on +an already populated instance!):: + + ./manage.py loaddata ../chimere/fixtures/default_data.json + Webserver configuration *********************** |