05c6138fa972364ce566b0c487aed8e298135515
[vfc/nfvo/wfengine.git] / winery / org.eclipse.winery.topologymodeler / src / main / webapp / WEB-INF / tags / common / artifacttemplateselection.tag
1 <%--
2 /*******************************************************************************
3  * Copyright (c) 2012-2013 University of Stuttgart.
4  * All rights reserved. This program and the accompanying materials
5  * are made available under the terms of the Eclipse Public License v1.0
6  * and the Apache License 2.0 which both accompany this distribution,
7  * and are available at http://www.eclipse.org/legal/epl-v10.html
8  * and http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Contributors:
11  *    Oliver Kopp - initial API and implementation and/or initial documentation
12  *******************************************************************************/
13 --%>
14 <%@tag description="dialog for selecting one artifacttemplate" pageEncoding="UTF-8"%>
15
16 <%@attribute name="allNamespaces" required="true" type="java.util.Collection" description="All known namespaces"%>
17 <%@attribute name="repositoryURL" required="true" description="the URL of Winery's repository"%>
18 <%@attribute name="defaultNSForArtifactTemplate" required="true" description="the default namespace of the artifact template"%>
19
20 <%@taglib prefix="t" tagdir="/WEB-INF/tags"%>
21
22 <div class="form-group-grouping">
23         <!-- createArtifactTemplate class is required for artifactcreationdialog -->
24         <div class="form-group createArtifactTemplate">
25                 <label>Artifact Template Name</label>
26                 <!-- name is an NCName -->
27                 <input class="artifactData form-control" id="artifactTemplateName" name="artifactTemplateName" type="text" required="required" autocomplete="on" placeholder="Enter name for artifact template" pattern="[\i-[:]][\c-[:]]*"/>
28                 <div id="artifactTemplateNameIsValid" class="invalid">
29                         <span id="artifactTemplateNameIsInvalidReason"></span>
30                 </div>
31         </div>
32
33         <t:namespaceChooser allNamespaces="${allNamespaces}" idOfInput="artifactTemplateNS" selected="${defaultNSForArtifactTemplate}"></t:namespaceChooser>
34 </div>
35
36 <script>
37 require(["artifacttemplateselection"], function(ast) {
38         // configure the plugin
39         ast.setRepositoryURL("${repositoryURL}");
40 });
41 </script>