Mercurial > roundup-cc
comparison doc/collect_demo1.py @ 34:916fa83b4144
Clean up repository. 'Update README.creole'
* /doc added for the old demos.
* Added comments to config.ini.
author | Magnus Schieder <mschieder@intevation.de> |
---|---|
date | Mon, 26 Nov 2018 16:08:27 +0100 |
parents | examples/collect_demo1.py@adca5b3780d2 |
children |
comparison
equal
deleted
inserted
replaced
33:946b9f458fcc | 34:916fa83b4144 |
---|---|
1 #!/usr/bin/env python3 | |
2 """Connect to roundup-tracker and save status to db for example demo1. | |
3 | |
4 Run periodically as often as you want data points to be saved. | |
5 demo1 only tracks issues with a priority. | |
6 """ | |
7 from collect_issues import save_stats_in_db | |
8 import roundup_content_data as rcd | |
9 | |
10 BASE_URL_DEMO = "http://localhost:8917/demo/" | |
11 SEARCH_URL_DEMO = "issue?@action=export_csv&@columns=title,priority&@filter=status&@pagesize=50&@startwith=0&status=-1,1,2,3,4,5,6,7" | |
12 | |
13 LOGIN_PARAMETERS_DEMO = ( | |
14 ("__login_name", "demo"), | |
15 ("__login_password", "demo"), | |
16 ("@action", "Login"), | |
17 ) | |
18 | |
19 save_stats_in_db(LOGIN_PARAMETERS_DEMO, BASE_URL_DEMO, "./demo1.py", | |
20 rcd.COLUMNS, rcd.CREATE_DB, rcd.INSERT_NEW, SEARCH_URL_DEMO) |