Project

General

Profile

1
$common/master(
2

    
3
header={
4
	$ui/repos/header()$
5
	<script type="text/javascript" src="../resources/js/dnet_param_values_functions.js"></script>
6
	<script type="text/javascript" src="../resources/js/addRepo.js"></script>
7
	<script type="text/javascript">
8
		function getTypes()     { return $types$ }
9
		function getCountries() { return $countries$ }
10
	</script>
11
	
12
	<style>
13
		.popover { max-width: 450px;  width: auto; }
14
	</style>
15
	
16
	
17
},
18
onLoad={},
19
body={
20
<div ng-app="addRepoUI" ng-controller="addRepoCtrl">
21
	<div ng-show="done" class="text-center">
22
		<h2>A new datasource has been registered !</h2> 
23
	</div>
24
	<div ng-hide="done">
25
		<form class="form-horizontal" role="form" name="newRepoForm">
26
		
27
			<fieldset>
28
				<legend>General Info</legend>
29
				<ng-simple-edit-field label="Datasource ID (template: 12Chars_____::theId)" selection="repo.id" regex="^\w{12}::\w+\$"></ng-simple-edit-field>
30
				<ng-simple-edit-field label="Official Name" selection="repo.officialname"></ng-simple-edit-field>
31
				<ng-simple-edit-field label="English Name" selection="repo.englishname" optional="true"></ng-simple-edit-field>
32
				<ng-simple-edit-field label="Organization" selection="org.legalname"></ng-simple-edit-field>
33
				<ng-select-vocabulary-field label="Typology Class" vocabulary="validTypes" selection="repo.typology"></ng-select-vocabulary-field>
34
			</fieldset>
35
			
36
			<fieldset>
37
				<legend>Contacts</legend>
38
				<ng-simple-edit-field label="WebSite Url" selection="repo.websiteurl" regex="^(http|https):\/\/"></ng-simple-edit-field>
39
				<ng-simple-edit-field label="Contact Email" selection="repo.contactemail" regex="^.+@.+"></ng-simple-edit-field>
40
			</fieldset>
41
				
42
			<fieldset>
43
				<legend>Geographical Info</legend>
44
				<ng-select-vocabulary-field label="Country" vocabulary="validCountries" selection="org.country"></ng-select-vocabulary-field>
45
				<ng-simple-edit-field label="Latitude" selection="repo.latitude" type="NUMBER"></ng-simple-edit-field>
46
				<ng-simple-edit-field label="Longitude" selection="repo.longitude" type="NUMBER"></ng-simple-edit-field>
47
			</fieldset>
48
			
49
			<fieldset>
50
				<legend>Technical Info</legend>
51
				<ng-simple-edit-field label="Namespace Prefix (12 chars)" selection="repo.namespaceprefix" regex="^\w{12}\$"></ng-simple-edit-field>
52
				<ng-simple-edit-field label="Software Typology" selection="repo.platform" optional="true"></ng-simple-edit-field>
53
				<ng-simple-edit-field label="Logo Url" selection="repo.logourl" regex="^(http|https):\/\/" optional="true"></ng-simple-edit-field>
54
			</fieldset>
55
			
56
			<br /><br />
57
			<div class="form-group">
58
				<div class="col-sm-offset-3 col-sm-9">
59
					<button class="btn btn-default" type="button" ng-click="resetForm()">reset</button>
60
					<button class="btn btn-primary" ng-disabled="newRepoForm.\$invalid" ng-click="registerRepo()">add</button>
61
				</div>
62
			</div>
63
		</form>
64
		<hr />
65
	</div>
66
	
67
	<!-- ENABLE TO DEBUG -->
68
	
69
	<!-- <p><b>Repo:</b> {{repo}}</p> -->
70
	
71
	
72
</div>
73
}
74

    
75
)$
(1-1/5)