blob: c8603424bb3c1bb62daad71db211e08bd0410d21 [file] [log] [blame]
Michael Landodd603392017-07-12 00:54:52 +03001/*-
2 * ============LICENSE_START=======================================================
3 * SDC
4 * ================================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
Idan Amitcb1095e2018-01-22 20:55:42 +020010 *
Michael Landodd603392017-07-12 00:54:52 +030011 * http://www.apache.org/licenses/LICENSE-2.0
Idan Amitcb1095e2018-01-22 20:55:42 +020012 *
Michael Landodd603392017-07-12 00:54:52 +030013 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
19 */
20
Michael Landoed64b5e2017-06-09 03:19:04 +030021/**
22 * Created by obarda on 2/18/2016.
23 */
24
25export let DEFAULT_ICON = 'defaulticon';
26export let CP_END_POINT = 'CpEndPoint';
27export let CHANGE_COMPONENT_CSAR_VERSION_FLAG = 'changeComponentCsarVersion';
28
29export class ComponentType {
30 static SERVICE = 'SERVICE';
31 static RESOURCE = 'RESOURCE';
Tal Gitelman51d50f02017-12-10 18:55:03 +020032 static SERVICE_PROXY = 'ServiceProxy'
Michael Landoed64b5e2017-06-09 03:19:04 +030033}
34
35export class ServerTypeUrl {
36 static RESOURCES = 'resources/';
37 static SERVICES = 'services/';
Michael Landoed64b5e2017-06-09 03:19:04 +030038}
39
40export class ResourceType {
41 static VF = 'VF';
42 static VL = 'VL';
43 static CP = 'CP';
44 static VFC = 'VFC';
45 static VFCMT = 'VFCMT';
Tal Gitelman153a3582017-07-03 20:16:55 +030046 static PNF = 'PNF';
Michael Lando75aacbb2017-07-17 21:12:03 +030047 static CVFC = 'CVFC';
Tal Gitelman51d50f02017-12-10 18:55:03 +020048 static CONFIGURATION = 'Configuration';
Michael Landoa5445102018-03-04 14:53:33 +020049 static CR = 'CR';
Michael Landoed64b5e2017-06-09 03:19:04 +030050}
51
52export class ComponentState {
53 static CERTIFICATION_IN_PROGRESS = 'CERTIFICATION_IN_PROGRESS';
54 static CERTIFIED = 'CERTIFIED';
55 static NOT_CERTIFIED_CHECKOUT = 'NOT_CERTIFIED_CHECKOUT';
56 static NOT_CERTIFIED_CHECKIN = 'NOT_CERTIFIED_CHECKIN';
57 static READY_FOR_CERTIFICATION = 'READY_FOR_CERTIFICATION';
58}
59
60export class DistributionStatus {
61 DISTRIBUTION_NOT_APPROVED = 'DISTRIBUTION_NOT_APPROVED';
62 DISTRIBUTION_APPROVED = 'DISTRIBUTION_APPROVED';
63 DISTRIBUTED = 'DISTRIBUTED';
64 DISTRIBUTION_REJECTED = 'DISTRIBUTION_REJECTED';
65}
66
67export class ArtifactGroupType {
68 static DEPLOYMENT = "DEPLOYMENT";
69 static INFORMATION = "INFORMATIONAL";
70 static SERVICE_API = "SERVICE_API";
71}
72
73export class ArtifactType {
74 static HEAT = "HEAT";
75 static HEAT_VOL = "HEAT_VOL";
76 static HEAT_NET = "HEAT_NET";
77 static VF_LICENSE = "VF_LICENSE";
78 static VENDOR_LICENSE = "VENDOR_LICENSE";
79 static THIRD_PARTY_RESERVED_TYPES = {
80 WORKFLOW: "WORKFLOW",
81 NETWORK_CALL_FLOW: "NETWORK_CALL_FLOW",
82 AAI_SERVICE_MODEL: "AAI_SERVICE_MODEL",
83 AAI_VF_MODEL: "AAI_VF_MODEL",
84 AAI_VF_MODULE_MODEL: "AAI_VF_MODULE_MODEL",
85 AAI_VF_INSTANCE_MODEL: "AAI_VF_INSTANCE_MODEL"
86 };
87 static TOSCA = {TOSCA_TEMPLATE: "TOSCA_TEMPLATE", TOSCA_CSAR: "TOSCA_CSAR"};
88}
89
90export class SEVERITY {
91 public static DEBUG = 'DEBUG';
92 public static INFO = 'INFO';
93 public static WARNING = 'WARNING';
94 public static ERROR = 'ERROR';
95}
96
97export class PROPERTY_TYPES {
98 public static STRING = 'string';
99 public static INTEGER = 'integer';
100 public static FLOAT = 'float';
101 public static BOOLEAN = 'boolean';
102 public static JSON = 'json';
103 public static MAP = 'map';
104 public static LIST = 'list';
Tal Gitelman153a3582017-07-03 20:16:55 +0300105 public static SCALAR = 'scalar-unit';
106 public static SCALAR_FREQUENCY = 'scalar-unit.frequency';
107 public static SCALAR_SIZE = 'scalar-unit.size';
108 public static SCALAR_TIME = 'scalar-unit.time';
Michael Landoed64b5e2017-06-09 03:19:04 +0300109}
110
111export class SOURCES {
112 public static A_AND_AI = 'A&AI';
113 public static ORDER = 'Order';
114 public static RUNTIME = 'Runtime';
115}
116
117export class PROPERTY_DATA {
Tal Gitelman153a3582017-07-03 20:16:55 +0300118 public static TYPES = [PROPERTY_TYPES.STRING, PROPERTY_TYPES.INTEGER, PROPERTY_TYPES.FLOAT, PROPERTY_TYPES.BOOLEAN, PROPERTY_TYPES.JSON, PROPERTY_TYPES.SCALAR, PROPERTY_TYPES.SCALAR_FREQUENCY, PROPERTY_TYPES.SCALAR_SIZE, PROPERTY_TYPES.SCALAR_TIME, PROPERTY_TYPES.LIST, PROPERTY_TYPES.MAP];
119 public static SIMPLE_TYPES = [PROPERTY_TYPES.STRING, PROPERTY_TYPES.INTEGER, PROPERTY_TYPES.FLOAT, PROPERTY_TYPES.BOOLEAN, PROPERTY_TYPES.JSON, PROPERTY_TYPES.SCALAR, PROPERTY_TYPES.SCALAR_FREQUENCY, PROPERTY_TYPES.SCALAR_SIZE, PROPERTY_TYPES.SCALAR_TIME];
Tal Gitelman51d50f02017-12-10 18:55:03 +0200120 public static SCALAR_TYPES = [PROPERTY_TYPES.SCALAR, PROPERTY_TYPES.SCALAR_FREQUENCY, PROPERTY_TYPES.SCALAR_SIZE, PROPERTY_TYPES.SCALAR_TIME];
Michael Landoed64b5e2017-06-09 03:19:04 +0300121 public static ROOT_DATA_TYPE = "tosca.datatypes.Root";
Michael Landob3d48982017-06-11 14:22:02 +0300122 public static OPENECOMP_ROOT = "org.openecomp.datatypes.Root";
123 public static SUPPLEMENTAL_DATA = "supplemental_data";
Michael Landoed64b5e2017-06-09 03:19:04 +0300124 public static SOURCES = [SOURCES.A_AND_AI, SOURCES.ORDER, SOURCES.RUNTIME];
125}
126
127export class PROPERTY_VALUE_CONSTRAINTS {
Michael Landob3d48982017-06-11 14:22:02 +0300128 public static MAX_LENGTH = 2500;
Michael Landoed64b5e2017-06-09 03:19:04 +0300129 public static JSON_MAX_LENGTH = 4096;
130}
131
132export class Role {
133 public static ADMIN = 'ADMIN';
134 public static DESIGNER = 'DESIGNER';
Michael Landoed64b5e2017-06-09 03:19:04 +0300135 public static TESTER = 'TESTER';
136 public static OPS = 'OPS';
137 public static GOVERNOR = 'GOVERNOR';
138}
139
140export enum FormState{
141 CREATE,
142 UPDATE,
143 IMPORT,
144 VIEW
145}
146
147export class WorkspaceMode {
148 public static CREATE = 'create';
149 public static EDIT = 'edit';
150 public static IMPORT = 'import';
151 public static VIEW = 'view';
152}
153
154export class ImagesUrl {
155 public static RESOURCE_ICONS = '/assets/styles/images/resource-icons/';
156 public static SERVICE_ICONS = '/assets/styles/images/service-icons/';
Tal Gitelman51d50f02017-12-10 18:55:03 +0200157 public static SERVICE_PROXY_ICONS = '/assets/styles/images/service-proxy-icons/';
Michael Landoed64b5e2017-06-09 03:19:04 +0300158 public static SELECTED_UCPE_INSTANCE = '/assets/styles/images/resource-icons/selectedUcpeInstance.png';
159 public static SELECTED_CP_INSTANCE = '/assets/styles/images/resource-icons/selectedCPInstance.png';
160 public static SELECTED_VL_INSTANCE = '/assets/styles/images/resource-icons/selectedVLInstance.png';
161 public static CANVAS_PLUS_ICON = '/assets/styles/images/resource-icons/canvasPlusIcon.png';
162 public static MODULE_ICON = '/assets/styles/images/resource-icons/module.png';
163 public static OPEN_MODULE_ICON = '/assets/styles/images/resource-icons/openModule.png';
164 public static OPEN_MODULE_HOVER_ICON = '/assets/styles/images/resource-icons/openModuleHover.png';
165 public static CLOSE_MODULE_ICON = '/assets/styles/images/resource-icons/closeModule.png';
166 public static CLOSE_MODULE_HOVER_ICON = '/assets/styles/images/resource-icons/closeModuleHover.png';
167}
168
169export class ModalType {
170 static STANDARD = 'standard';
171 static ERROR = 'error';
172 static ALERT = 'alert';
173}
174
Avi Zivf5854fd2017-07-31 15:50:46 +0300175export class ServerErrors {
176 static ERROR_TITLE = 'Error';
177 static DEFAULT_ERROR = 'Error getting response from server';
178 static MESSAGE_ERROR = 'Wrong error format from server';
179}
180
Michael Landoed64b5e2017-06-09 03:19:04 +0300181export class GraphColors {
182 public static NOT_CERTIFIED_LINK = 'rgb(218,31,61)';
183 public static VL_LINK = 'rgb(216,216,216)';
184 public static ACTIVE_LINK = '#30bdf2';
185 public static BASE_LINK = 'rgb(55,55,55)';
186 public static NODE_BACKGROUND_COLOR = 'rgba(46, 162, 157, 0.24)';
187 public static NODE_SHADOW_COLOR = 'rgba(198, 230, 228, 0.7)';
188 public static NODE_OVERLAPPING_BACKGROUND_COLOR = 'rgba(179, 10, 60, 0.24)';
189 public static NODE_OVERLAPPING_SHADOW_COLOR = 'rgba(236, 194, 206, 0.7)';
190 public static NODE_UCPE_CP = '#9063cd';
191 public static NODE_UCPE = '#fbfbfb';
192 public static NODE_SELECTED_BORDER_COLOR = '#30bdf2';
Michael Landoa5445102018-03-04 14:53:33 +0200193 public static SERVICE_PATH_LINK = '#70208a';
Michael Landoed64b5e2017-06-09 03:19:04 +0300194}
195export class GraphTransactionLogText {
196 public static REMOVE_TEMP_LINK = "remove tempLink";
197 public static DELETE_LINK = "delete link";
198 public static ADD_LINK = "delete link";
199 public static ADD_NODE = "adding node";
200}
201
202export class GraphUIObjects {
Idan Amitcb1095e2018-01-22 20:55:42 +0200203 public static HANDLE_SIZE = 18;
204 public static NODE_OVERLAP_MIN_SIZE = 30;
Michael Lando9db40522017-07-22 17:10:02 +0300205 public static DEFAULT_RESOURCE_WIDTH = 65;
206 public static SMALL_RESOURCE_WIDTH = 21;
Michael Landoed64b5e2017-06-09 03:19:04 +0300207 public static LINK_MENU_HEIGHT = 420;
208 public static TOP_HEADER_HEIGHT = 200;
209 public static TOOLTIP_OFFSET_X = 50;
210 public static TOOLTIP_OFFSET_Y = 145;
211 public static TOOLTIP_LINK_OFFSET_X = 35;
212 public static TOOLTIP_LINK_OFFSET_Y = 75;
213 public static MENU_LINK_VL_HEIGHT_OFFSET = 250;
214 public static MENU_LINK_VL_WIDTH_OFFSET = 200;
215 public static MENU_LINK_SIMPLE_HEIGHT_OFFSET = 180;
216 public static MENU_LINK_SIMPLE_WIDTH_OFFSET = 130;
217 public static DIAGRAM_RIGHT_WIDTH_OFFSET = 248;
218 public static DIAGRAM_HEADER_OFFSET = 103;
219 public static DIAGRAM_PALETTE_WIDTH_OFFSET = 247;
220 // public static COMPOSITION_HEADER_OFFSET = 50;
221 // public static COMPOSITION_NODE_MENU_WIDTH = 230;
222 // public static COMPOSITION_NODE_MENU_HEIGHT = 200;
223 // public static COMPOSITION_RIGHT_PANEL_OFFSET = 300;
224}
225
226
227export class States {
228 public static WORKSPACE_GENERAL = 'workspace.general';
Michael Landoed64b5e2017-06-09 03:19:04 +0300229 public static WORKSPACE_ACTIVITY_LOG = 'workspace.activity_log';
230 public static WORKSPACE_DEPLOYMENT_ARTIFACTS = 'workspace.deployment_artifacts';
231 public static WORKSPACE_PROPERTIES = 'workspace.properties';
232 public static WORKSPACE_SERVICE_INPUTS = 'workspace.service_inputs';
233 public static WORKSPACE_RESOURCE_INPUTS = 'workspace.resource_inputs';
234 public static WORKSPACE_ATTRIBUTES = 'workspace.attributes';
Michael Landoed64b5e2017-06-09 03:19:04 +0300235 public static WORKSPACE_INFORMATION_ARTIFACTS = 'workspace.information_artifacts';
236 public static WORKSPACE_TOSCA_ARTIFACTS = 'workspace.tosca_artifacts';
237 public static WORKSPACE_COMPOSITION = 'workspace.composition';
238 public static WORKSPACE_NETWORK_CALL_FLOW = 'workspace.network_call_flow';
239 public static WORKSPACE_MANAGEMENT_WORKFLOW = 'workspace.management_workflow';
240 public static WORKSPACE_DEPLOYMENT = 'workspace.deployment';
241 public static WORKSPACE_DISTRIBUTION = 'workspace.distribution';
242 public static WORKSPACE_PROPERTIES_ASSIGNMENT = 'workspace.properties_assignment';
243 public static WORKSPACE_REQUIREMENTS_AND_CAPABILITIES = 'workspace.reqAndCap';
Idan Amiteedaaf92018-01-31 13:27:33 +0200244 public static WORKSPACE_PLUGINS = 'workspace.plugins';
Michael Landoed64b5e2017-06-09 03:19:04 +0300245 public static WORKSPACE_NG2 = 'workspace.ng2';
246}
247
248export class EVENTS {
Michael Landoa5445102018-03-04 14:53:33 +0200249 // static RESOURCE_LEFT_PALETTE_UPDATE_EVENT = "resourceLeftPanelUpdateEvent";
250 // static RESOURCE_PNF_LEFT_PALETTE_UPDATE_EVENT = "resourcePNFLeftPanelUpdateEvent";
251 // static SERVICE_LEFT_PALETTE_UPDATE_EVENT = "serviceLeftPanelUpdateEvent";
252 //static VL_LEFT_PALETTE_UPDATE_EVENT = "vlLeftPanelUdateEvent";
253 static LEFT_PALETTE_UPDATE_EVENT = "leftPanelUpdateEvent";
Michael Landoed64b5e2017-06-09 03:19:04 +0300254 static ON_CSAR_LOADING = "onCsarLoading";
255 static DOWNLOAD_ARTIFACT_FINISH_EVENT = "downloadArtifactFinishEvent";
256 static ON_WORKSPACE_SAVE_BUTTON_CLICK = "onWorkspaceSaveButtonClick";
257 static ON_WORKSPACE_SAVE_BUTTON_SUCCESS = "onWorkspaceSaveButtonSuccess";
258 static ON_WORKSPACE_SAVE_BUTTON_ERROR = "onWorkspaceSaveButtonError";
Michael Landob3d48982017-06-11 14:22:02 +0300259 static ON_CHECKOUT = "onCheckout";
Tal Gitelman51d50f02017-12-10 18:55:03 +0200260 static ON_REVERT = "onRevert";
Michael Landoed64b5e2017-06-09 03:19:04 +0300261
262 //Loader events
263 static SHOW_LOADER_EVENT = "showLoaderEvent";
264 static HIDE_LOADER_EVENT = "hideLoaderEvent";
265}
266
267
268export class UNIQUE_GROUP_PROPERTIES_NAME {
269 public static MIN_VF_MODULE_INSTANCES = 'min_vf_module_instances';
270 public static MAX_VF_MODULE_INSTANCES = 'max_vf_module_instances';
271 public static INITIAL_COUNT = 'initial_count';
272 public static IS_BASE = 'isBase';
273 public static VF_MODULE_TYPE = 'vf_module_type';
274 public static VF_MODULE_LABEL = 'vf_module_label';
275 public static VF_MODULE_DESCRIPTION = 'vf_module_description';
276 public static VOLUME_GROUP = 'volume_group';
277}
278
279
280export class GRAPH_EVENTS {
281 static ON_COMPOSITION_GRAPH_DATA_LOADED = 'onCompositionGraphDataLoaded';
282 static ON_DEPLOYMENT_GRAPH_DATA_LOADED = 'onDeploymentGraphDataLoaded';
283 static ON_NODE_SELECTED = "onNodeSelected";
284 static ON_GRAPH_BACKGROUND_CLICKED = "onGraphBackgroundClicked";
285 static ON_PALETTE_COMPONENT_HOVER_IN = 'onPaletteComponentHoverIn';
286 static ON_PALETTE_COMPONENT_HOVER_OUT = 'onPaletteComponentHoverOut';
287 static ON_PALETTE_COMPONENT_DRAG_START = 'onPaletteComponentDragStart';
288 static ON_PALETTE_COMPONENT_DRAG_ACTION = 'onPaletteComponentDragAction';
Michael Landoa5445102018-03-04 14:53:33 +0200289 static ON_PALETTE_COMPONENT_SHOW_POPUP_PANEL = 'onPaletteComponentShowPopupPanel';
290 static ON_PALETTE_COMPONENT_HIDE_POPUP_PANEL = 'onPaletteComponentHidePopupPanel';
Michael Landoed64b5e2017-06-09 03:19:04 +0300291 static ON_COMPONENT_INSTANCE_NAME_CHANGED = 'onComponentInstanceNameChanged';
292 static ON_DELETE_COMPONENT_INSTANCE = 'onDeleteComponentInstance';
293 static ON_DELETE_MULTIPLE_COMPONENTS = 'onDeleteMultipleComponents';
294 static ON_DELETE_EDGE = 'onDeleteEdge';
295 static ON_INSERT_NODE_TO_UCPE = 'onInsertNodeToUCPE';
296 static ON_REMOVE_NODE_FROM_UCPE = 'onRemoveNodeFromUCPE';
297 static ON_VERSION_CHANGED = 'onVersionChanged';
298 static ON_CREATE_COMPONENT_INSTANCE = 'onCreateComponentInstance';
Michael Landoa5445102018-03-04 14:53:33 +0200299 static ON_ADD_COMPONENT_INSTANCE_ZONE_START = 'onCreateComponentInstanceZone';
300 static ON_FINISH_ANIMATION_ZONE = 'onFinishAnimationZone';
301 static ON_ZONE_SIZE_CHANGE = 'onZoneSizeChange';
Michael Landoed64b5e2017-06-09 03:19:04 +0300302}
303
304
305export class COMPONENT_FIELDS {
306 static COMPONENT_INSTANCES_PROPERTIES = "componentInstancesProperties";
307 static COMPONENT_INSTANCES_ATTRIBUTES = "componentInstancesAttributes";
308 static COMPONENT_ATTRIBUTES = "attributes";
309 static COMPONENT_INSTANCES = "componentInstances";
310 static COMPONENT_INSTANCES_RELATION = "componentInstancesRelations";
311 static COMPONENT_INPUTS = "inputs";
312 static COMPONENT_METADATA = "metadata";
313 static COMPONENT_DEPLOYMENT_ARTIFACTS = "deploymentArtifacts";
314 static COMPONENT_INFORMATIONAL_ARTIFACTS = "artifacts";
315 static COMPONENT_PROPERTIES = "properties";
316 static COMPONENT_CAPABILITIES = "capabilities";
317 static COMPONENT_REQUIREMENTS = "requirements";
318 static COMPONENT_TOSCA_ARTIFACTS = "toscaArtifacts";
Michael Landoa5445102018-03-04 14:53:33 +0200319 static COMPONENT_POLICIES = "policies";
Michael Landoed64b5e2017-06-09 03:19:04 +0300320 static COMPONENT_GROUPS = "groups";
321
322}
Michael Landoa5445102018-03-04 14:53:33 +0200323
324export class SERVICE_FIELDS {
325 static FORWARDING_PATHS = "forwardingPaths";
326}
327
Michael Landoed64b5e2017-06-09 03:19:04 +0300328export class API_QUERY_PARAMS {
329 static INCLUDE = "include";
330}