-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
220 lines (183 loc) · 10.5 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">
<title>Get your Organisational ID</title>
<!-- Bootstrap core CSS -->
<link href="bower_components/bootstrap/dist/css/bootstrap.css" rel="stylesheet">
<!-- Custom styles for this template -->
<link href="css/jumbotron-narrow.css" rel="stylesheet">
<link href="css/custom.css" rel="stylesheet">
<!-- Just for debugging purposes. Don't actually copy this line! -->
<!--[if lt IE 9]><script src="../../docs-assets/js/ie8-responsive-file-warning.js"></script><![endif]-->
<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
<script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
<![endif]-->
<meta http-equiv="refresh" content="1; url=http://org-id.guide/">
</head>
<body>
<div class="container">
<div class="header">
<ul class="nav nav-pills pull-right">
<li class="active"><a href="#top">Home</a></li>
<li><a href="#about">About</a></li>
<li><a href="#plans">Plans</a></li>
</ul>
<h3 class="text-muted">Organisation ID-a-tron</h3>
</div>
<a name="top"></a>
<div class="jumbotron">
<div class="countrySelect">
Select the country where the organisation is registered:<br/> <select id="countrySelectList"></select>
</div>
<div class="agencySelect" style="display:none;">
Select the agency it is registered with: <select id="agencySelectList"></select>
</div>
<div class="idBuilder" style="display:none;">
<div class="idDetails">Look up the organisations existing identifier from <span id="idSource">the selected registration agency</span> and enter it below.</div>
<input id="idPrefix" size="11" readonly/>-<input id="idSuffix" size="20" placeholder="Enter ID"/>
<span id="clippy"></span>
<div id="opencirce">
</div>
</div>
<div id="statistics">
</div>
</div>
<div class="row marketing">
<div class="col-lg-12">
<a name="about"></a>
<h4>About</h4>
<p>This is an unofficial proof-of-concept service to help publishers of data to the <a href="http://www.iatistandard.org">International Aid Transparency Initiative</a>, and related standards, to identify the Organisation Identifier they should use, based on the draft <a href="http://iatistandard.org/getting-started/organisation-data/organisation-identifiers/">Organisational Identifier Conventions</a>. </p>
<p>
The idea of the IATI Organisation Identifier Conventions is to provide a best-efforts approach to linking up different data sources that talk about the same organisation. The convention suggests defining 'namespace' prefixes for all the agencies which commonly register organisations (companies, charities, government departments), and then re-using the existing identifiers these organisations have been assigned. By suggesting an order of priority for different namespaces, and encouraging anyone who knows of relationships between two identifiers (e.g. they are the same organisation; or one is a sub-unit of another) to publish this too, users of the data have an improved chance of finding out where heterogenous data sources are referring to transactions and interactions involving the same organisations.
</p>
<p>
In practice, the IATI Organisation Identifier Conventions are only partially applied. A <a href="https://docs.google.com/spreadsheet/ccc?key=0AnWngmdQt3stdFppMWdkcXJqVTRWTk9menR1N0FXNGc#gid=0">partial list of prefixes is maintained here</a>. This service simplifies the process of identifying appropriate registration agencies and generating an ID from that list.
</p>
<p>
Some of the things this service <i>could</i> be developed to do are outlined below.
<a name="plans"></a>
<h4>Plans</h4>
<p>Future features could include:
<ul>
<li>A form for suggesting new prefixes</li>
<li>Validation tools to check IDs - where a resolution service is available and documented in the prefix source file</li>
<li>A tool to turn IATI IDs back into their component parts</li>
<li>Guidance on declaring relationships between different organisational IDs</li>
</ul>
</p>
</div>
</div>
<div class="footer">
<p>Created by <a href="http://www.twitter.com/timdavies">Tim Davies</a> at <a href="http://www.open-dev-ouvert.ca/">Developers for Development</a>, Montreal, January 2014 as a demonstrator.</p>
</div>
<a href="https://github.com/practicalparticipation/organisation-id-tool/"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://s3.amazonaws.com/github/ribbons/forkme_right_darkblue_121621.png" alt="Fork me on GitHub"></a>
</div> <!-- /container -->
<!-- Bootstrap core JavaScript
================================================== -->
<!-- Placed at the end of the document so the pages load faster -->
<script src="bower_components/jquery/jquery.min.js"></script>
<script src="bower_components/jquery-sheetrock/src/jquery.sheetrock.js"></script>
<script><!--
// Define spreadsheet URL.
var mySpreadsheet = 'https://docs.google.com/spreadsheet/ccc?key=0AnWngmdQt3stdFppMWdkcXJqVTRWTk9menR1N0FXNGc#gid=0';
function countryHandler(data) {
$.each(data.table.rows,function() {
$("#countrySelectList").append("<option value='"+ $(this)[0].c[0].v +"'>"+$(this)[0].c[0].v+"</option>")
});
}
function agencyHandler(data) {
$(".agencySelect").show();
$("#agencySelectList").empty();
$("#agencySelectList").append("<option value='SELECT'>---Select---</option>");
$.each(data.table.rows,function() {
$("#agencySelectList").append("<option value='"+ $(this)[0].c[0].v +"'>"+$(this)[0].c[1].v+"</option>")
});
$("#agencySelectList").append("<option value='__NEW'>--Agency not listed: suggest new--</option>");
}
function agencyDetailHandler(data) {
$.each(data.table.rows,function() {
$("#idSource").empty()
$("#idSource").append("<a href='"+$(this)[0].c[0].v+"' target='_blank'>"+$(this)[0].c[1].v+"</a>");
});
}
function newClippy(text) {
$('#clippy').remove();
var clippy = $('<object id="clippy" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000"'+
'width="110"'+
'height="14"'+
'id="clippy" >'+
'<param name="movie" value="bower_components/clippy/build/clippy.swf"/>'+
'<param name="allowScriptAccess" value="always" />'+
'<param name="quality" value="high" />'+
'<param name="scale" value="noscale" />'+
'<param NAME="FlashVars" value="text='+text+'">'+
'<param name="bgcolor" value="#eeeeee">'+
'<embed src="bower_components/clippy/build/clippy.swf"'+
'width="110"'+
'height="14"'+
'name="clippy"'+
'quality="high"'+
'allowScriptAccess="always"'+
'type="application/x-shockwave-flash"'+
'pluginspage="http://www.macromedia.com/go/getflashplayer"'+
'FlashVars="text='+text+'"'+
'bgcolor="#eeeeee"'+
'/>'+
'</object>');
$("#idSuffix").after(clippy);
}
//Initial country list load
$('#countrySelect').sheetrock({
url: mySpreadsheet,
columns: {A: 'Code', B: 'Country', C: 'Agency', D: 'Website', E: 'Public', F: 'IATI_Rules', G: 'Added'},
sql: "select %Country%, COUNT(%Code%) WHERE not %Country% = 'Country' GROUP BY %Country% ORDER BY %Country%",
headersOff:true,
debug: true,
dataHandler: countryHandler
});
//Set up handler for country selection
$("#countrySelectList").change(function() {
$(".idBuilder").hide();
country = $(this).val();
$('#agencySelect').sheetrock({
url: mySpreadsheet,
columns: {A: 'Code', B: 'Country', C: 'Agency', D: 'Website', E: 'Public', F: 'IATI_Rules', G: 'Added'},
sql: "select %Code%, %Agency% WHERE %Country% = '"+country+"'",
headersOff:true,
debug: true,
dataHandler: agencyHandler
});
});
//Set up hander for ID selection
$("#agencySelectList").change(function() {
$(".idBuilder").show();
prefix = $(this).val();
$("#idPrefix").val(prefix);
$('#idSource').sheetrock({
url: mySpreadsheet,
columns: {A: 'Code', B: 'Country', C: 'Agency', D: 'Website', E: 'Public', F: 'IATI_Rules', G: 'Added'},
sql: "select %Website%, %Agency% WHERE %Code% = '"+prefix+"'",
headersOff:true,
debug: true,
dataHandler: agencyDetailHandler
});
});
//Set up editor handler
$("#idSuffix").blur(function() {
suffix = $.trim($(this).val()).replace(/ /g,'_').replace('/\//g','_').replace('/\-/g','_').replace(/[_]{2,}/g,'_')
$(this).val(suffix);
fullid = $("#idPrefix").val() + "-"+suffix;
newClippy(fullid);
$("#opencirce").empty();
$("#opencirce").append("<a href='http://opencirce.org/org/code/" + fullid + "'>Lookup on Open Circe</a>");
});
--></script>
</body>
</html>