aboutsummaryrefslogtreecommitdiffstats
path: root/vid-app-common/src/test/resources
diff options
context:
space:
mode:
Diffstat (limited to 'vid-app-common/src/test/resources')
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/asdc.properties17
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/quartz.properties36
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/raptor.properties168
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/raptor_app_fusion.properties20
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/raptor_db_fusion.properties0
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/raptor_pdf.properties30
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/sql.properties303
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/system.properties167
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/conf/system.properties.cml97
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/conf/fusion.properties69
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/defs/definitions.xml242
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/footer.jsp34
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/header.jsp236
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/left-menu.jsp804
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ebz/ebz_header.jsp833
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/fusion/orm/RNoteBookIntegration.hbm.xml44
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/index.jsp24
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/createnewserviceinstance.jsp146
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/login.jsp125
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/login_external.jsp126
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/searchexistingsi.jsp81
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/serviceModels.jsp82
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/subscriberdetails.jsp184
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/testMso.jsp174
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/testViewEdit.jsp172
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/viewlog.jsp33
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/jsp/welcome.jsp49
-rw-r--r--vid-app-common/src/test/resources/WEB-INF/web.xml11
-rw-r--r--vid-app-common/src/test/resources/pnf.csarbin0 -> 33299 bytes
-rw-r--r--vid-app-common/src/test/resources/roles.json8
-rw-r--r--vid-app-common/src/test/resources/vf-csar.JSON5
-rw-r--r--vid-app-common/src/test/resources/vl-csar.JSON8
32 files changed, 4324 insertions, 4 deletions
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/asdc.properties b/vid-app-common/src/test/resources/WEB-INF/conf/asdc.properties
new file mode 100644
index 00000000..c16d3f5d
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/asdc.properties
@@ -0,0 +1,17 @@
+asdc.client.type=REST
+#
+#asdc.client.rest.protocol=http
+#asdc.client.rest.host=135.21.125.36
+#asdc.client.rest.port=8080
+#asdc.client.rest.auth=Basic VklEOnZpbjNSaXBlbmVkSnVtYjBKZXRTcHJpbmtsZXM=
+#
+#dev
+#asdc.client.rest.protocol=http
+#asdc.client.rest.host=135.21.125.105
+#asdc.client.rest.port=8080
+#asdc.client.rest.auth=Basic VGVzdDoxMjM0NTY=
+#IST
+asdc.client.rest.protocol=https
+asdc.client.rest.host=asdcbe.mtsnjpw1.aic.cip.att.com
+asdc.client.rest.port=8443
+asdc.client.rest.auth=Basic dmlkOnZpZGlzdA==
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/quartz.properties b/vid-app-common/src/test/resources/WEB-INF/conf/quartz.properties
new file mode 100644
index 00000000..81f2bbc3
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/quartz.properties
@@ -0,0 +1,36 @@
+#################################################################################
+# Quartz configurations for Quantum Work Flow #
+#################################################################################
+
+org.quartz.scheduler.instanceId = AUTO
+
+#################################################################################
+# Main configurations
+org.quartz.threadPool.class = org.quartz.simpl.SimpleThreadPool
+org.quartz.threadPool.threadCount = 30
+
+============================================================================
+# Configure JobStore
+#============================================================================
+
+org.quartz.jobStore.misfireThreshold = 60000
+
+org.quartz.jobStore.class = org.quartz.impl.jdbcjobstore.JobStoreTX
+org.quartz.jobStore.driverDelegateClass = org.quartz.impl.jdbcjobstore.StdJDBCDelegate
+org.quartz.jobStore.useProperties = false
+#org.quartz.jobStore.dataSource = myDS
+org.quartz.jobStore.tablePrefix = FN_QZ_
+
+org.quartz.jobStore.isClustered = true
+org.quartz.jobStore.clusterCheckinInterval = 20000
+
+#============================================================================
+# Configure Datasources
+#============================================================================
+
+org.quartz.dataSource.myDS.driver = com.mysql.jdbc.Driver
+org.quartz.dataSource.myDS.URL = jdbc:mysql://localhost:3306/vid_portal
+org.quartz.dataSource.myDS.user = euser
+org.quartz.dataSource.myDS.password = euser
+org.quartz.dataSource.myDS.maxConnections = 5
+org.quartz.dataSource.myDS.validationQuery=select 0 from dual
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/raptor.properties b/vid-app-common/src/test/resources/WEB-INF/conf/raptor.properties
new file mode 100644
index 00000000..3eb0f7ce
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/raptor.properties
@@ -0,0 +1,168 @@
+##C## Mention the name of the framework. At present RAPTOR supports FUSION
+system=fusion
+##C## Determines the priority for the debug message.
+debug_level=5
+##C## Determines the number of records can be downloaded in excel when you select "download all" option.
+download_limit=65000
+csv_download_limit=10
+##C## Determines the number of records to be displayed in a single page.
+default_page_size=50
+##C## Determines the list size in the form field.
+form_fields_list_size=99000
+##C## Determines the scheduler interval
+#scheduler_interval=0 => disabled
+scheduler_interval=0
+##C## System Name
+system_name=RAPTOR
+##C## This is used for Bread crumbs.
+base_title=ANALYSIS
+##C## whether to allow SQL-based report definition (security risk); super users are always allowed to create SQL-based reports
+allow_sql_based_reports=yes
+##C## Determines whether to include disclaimer page at the bottom of each screen
+show_disclaimer=yes
+disclaimer_positioned_top_in_csvexcel=yes
+##C## Determines whether to display the form page as a separate page before running the report
+display_form_before_run=yes
+##C## Determines whether to include the form page on the report data page
+include_form_with_data=yes
+##C## Determines whether to cache chart data in the session => faster re-display if the data volume does not get too large
+cache_chart_data=yes
+##C## Determines whether to cache report data for the currently displayed page in the session => faster re-display
+ ##C## if the data volume does not get too large
+cache_cur_page_data=yes
+##C## Determines Chart width
+default_chart_width=700
+##C## Determines Chart height
+default_chart_height=420
+##C## Determines whether to permit report deletion only by report owner or by everyone with "write" access
+delete_only_by_owner=no
+##C## Determines whether to log each report execution and update time and user ID
+enable_report_log=yes
+##C## Determines whether to cache user roles info in memory (saves many DB reads, but does not account for roles
+ ##C## assigned after the cache was loaded)
+cache_user_roles=yes
+##C## Determines whether to convert month formats (e.g. MM/YYYY) to the last day of the month (true) or
+ ##C## first day (false) - like 12/2003 is converted to either 12/31/2003 or 12/01/2003
+month_format_use_last_day=no
+##C## Determines whether to print the report title in the download files
+print_title_in_download=yes
+##C## Determines whether to show report description when the report is run and in the quick links
+show_descr_at_runtime=no
+##C## Determines whether to skip labels on the Line chart axis when they overlap
+#DEPRECATED skip_chart_labels_to_fit=no
+##C## Determines whether to show chart types that are purpose and/or data specific
+show_nonstandard_charts=yes
+##C## Determines whether to allow the user to change the chart type at runtime
+allow_runtime_chart_sel=yes
+##C## Determines whether to display the report title as chart title as well
+display_chart_title=yes
+##C## Determines whether to merge/blank multi-level row headings in cross-tab report
+merge_crosstab_row_headings=yes
+##C## Determines whether to display chart when displaying the report at first or just a "Show Chart" button
+display_chart_by_default=yes
+##C## Determines whether to print the form field values in the download files
+print_params_in_download=yes
+##C## Determines the limitation to the characters in chart label.
+skip_chart_labels_limit=30
+##C## Determines whether to users with read-only rights for a report can copy it
+can_copy_on_read_only=yes
+##C## Determines the no of decimals to be displayed in Totals column
+#max_decimals_on_totals=-1 => don't truncate, display all decimal digits
+max_decimals_on_totals=2
+##C## Determines which JFreeChart to use.
+jfree_version=latest
+#jfree_version=0.9.11
+# Added this restriction so that heavily used system which contain
+# more than 1000 users can enable this feature not to display whole
+# users in the drop down menu
+display_all_users=yes
+##Sheet name
+sheet_name=raptor
+#shell_script_name=/home/sundar/test.sh
+#download_query_folder=/titan/PROJECT3/RAPTOR/raptor/dwnld/query/
+## this directory is mentioned if the flat file is downloaded using shell script
+shell_script_dir=/titan/PROJECT3/RAPTOR/raptor/dwnld/
+flat_file_lower_limit=1
+flat_file_upper_limit=200000
+## whatever request mentioned here would be parsed in sql and request parameter would be filled
+request_get_params=isEmbedded
+print_footer_in_download=yes
+## footer mentioned here appears in downloaded excel
+footer_first_line=AT&T Proprietary
+footer_second_line=Use Pursuant to Company Instructions
+## to run report in popup window
+report_in_popup_window=yes
+## to run each report in new popup window if the above is selected
+popup_in_new_window=yes
+## "Yes" allows the request param to be passed to the drill down report
+pass_request_param_in_drilldown=yes
+## Show PDF download icon
+show_pdf_download=yes
+# Show Folder Tree
+show_folder_tree=no
+#Show folder tree only for Admin Users
+show_folder_tree_only_to_admin_users=no
+#folder tree should be minimized
+folder_tree_minimized=yes
+## whatever session mentioned here would be parsed in sql and session parameter would be filled
+session_params=login_id
+display_formfield_info=yes
+customize_formfield_info=yes
+#schedule limit for end users
+schedule_limit=10
+# customized query if you need any restrictions for schedule and security tab for fusion
+#schedule_custom_query_for_users=getAllUsersByCustomer
+#schedule_custom_query_for_roles=getAllRolesByCustomer
+# customized query if you need any restrictions for schedule and security tab for prisms example
+#schedule_custom_query_for_users=SELECT au.user_id, au.first_name||' '||au.last_name user_name FROM app_user au order by 2
+schedule_custom_query_for_users=SELECT au.user_id id, au.first_name||' '||au.last_name name FROM app_user au where user_id = 1 order by 2
+#schedule_custom_query_for_roles=SELECT ar.role_id, ar.descr role_name FROM app_role ar order by 2
+schedule_date_pattern=MM/dd/yyyy hh:mm:ss a
+## This is used to display in right format in chart timestamp axis as we give in the sql
+#chart_yearly_format=yyyy
+#chart_monthly_format=MMM-yyyy
+chart_daily_format=MM/dd/yyyy
+chart_hourly_format=MM/dd HH
+#chart_minute_format=HH:mm
+chart_minute_format=MM-dd-yyyy-HH:mm
+#chart_second_format=HH:mm:ss
+chart_second_format=MM-dd-yyyy
+#chart_millisecond_format=HH:mm:ss.S
+schedule_help_text=This form is used to schedule a specific Reporting Platform report to be delivered to one or more email addresses associated with your Company's Business Direct user logins. Note that report output delivered via email does not include the capability to drill down/back up to additional data levels. So, select the appropriate data level report for the scheduled report. View the status of scheduled report requests in the My Schedules menu item.
+use_loginid_in_schedYN=Y
+session_params_for_scheduling=login_id
+session_date_formfield_auto_incr=yes
+display_session_param_pdfexcel=login_id;Login Id
+session_params_for_displaying_in_scheduling=login_id;Login Id
+application_server=tomcat
+#gmap properties
+gmap_key=ABQIAAAAToJSSetKBMjBJx8MiRw4ghQiU0SbbKnm8C5eu25cpyLwgkLzyRShrQTbgZtqnKAqZU9JwcSq1bKwiA
+PROJECT-FOLDER=/Users/sundar/git/st_quantum/quantum/target/quantum-1.0
+#
+MARKET-SHAPEFILE-FOLDER=resources/files
+# output folder for files generated on server side
+OUTPUT-FOLDER=resources/temp
+# tile size in pixel
+TILE-SIZE=256
+#check if map is disabled or not
+map_allowed=Y
+max_drilldown_level=2
+admin_role_equiv_to_super_role=N
+show_loading_during_formfield_chain=Y
+show_print_icon=N
+globally_nowrap=N
+calendar_output_date_format=MM/dd/yyyy
+memory_threshold_percentage=99
+print_params_in_csv_download=yes
+notitle_in_dashboard=yes
+generate_store_sched_reports=yes
+show_excel_2007_download=yes
+print_excel_in_landscape=yes
+show_animated_chart_option=yes
+show_animated_chart_only=no
+adjust_content_based_on_height=yes
+custom_submit_button_text=Run Button
+customize_formfield_layout=yes
+#db_type=postgresql
+#db_type=oracle
+db_type=mysql
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/raptor_app_fusion.properties b/vid-app-common/src/test/resources/WEB-INF/conf/raptor_app_fusion.properties
new file mode 100644
index 00000000..4006c166
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/raptor_app_fusion.properties
@@ -0,0 +1,20 @@
+temp_folder_path=/demeter/WebApps/dev/ECOMP_PORTAL/temp/
+upload_folder_path=/demeter/WebApps/dev/ECOMP_PORTAL/files/
+excel_template_path=/demeter/WebApps/dev/ECOMP_PORTAL/files/raptor_template/
+temp_folder_url=temp/
+upload_folder_url=upload/
+smtp_server=zeus.homer.att.com
+default_email_sender=dev-local@homer.att.com
+error_page=error_page.jsp
+jsp_context_path=raptor/
+img_folder_url=static/fusion/raptor/images/
+base_folder_url=static/fusion/raptor/
+direct_access_url=http://localhost:8080/quantum/raptor_email_attachment.htm?action=raptor&source_page=report_run&display_content=y
+#base_action_url=report.htm#/report_run/
+drill_action_url=report.htm#/report_run/c_master=
+base_action_url=report_wizard.htm?action=
+base_action_url_ng=report#/
+base_action_param=c_master=
+super_role_id=1
+admin_role_ids=1
+quick_links_menu_ids=HOME,CUSTOMER,REPORTS
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/raptor_db_fusion.properties b/vid-app-common/src/test/resources/WEB-INF/conf/raptor_db_fusion.properties
new file mode 100644
index 00000000..e69de29b
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/raptor_db_fusion.properties
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/raptor_pdf.properties b/vid-app-common/src/test/resources/WEB-INF/conf/raptor_pdf.properties
new file mode 100644
index 00000000..33fa1a0e
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/raptor_pdf.properties
@@ -0,0 +1,30 @@
+## pdf file specific properties
+pdf_data_font_size=9
+pdf_data_font_family=Arial
+#reduce the font size from html config
+pdf_data_font_size_offset=2
+pdf_data_alternate_color=true
+#data row background(white), alternate(light light blue/gray)
+pdf_data_background_alternate_hex_code=#EDEDED
+pdf_data_default_background_hex_code=#FFFFFF
+#header font (white) background (gray)
+pdf_data_table_header_font_hex_code=#FFFFFF
+pdf_data_table_header_background_hex_code=#8A9BB3
+#footer header
+pdf_footer_font_size=9
+pdf_footer_font_family=Arial
+pdf_att_proprietary=AT&T Proprietary\nUse Pursuant to Company Instructions
+pdf_att_proprierary_font_size=7
+pdf_date_timezone=GMT
+pdf_date_pattern=MM/dd/yyyy hh:mm:ss a
+##page number position at 1 - footer middle, 0 -- header right, 2 - both
+pdf_page_number_position=1
+pdf_word_before_page_number=Page
+pdf_word_after_page_number=
+pdf_coverpage_firstcolumn_size=0.3
+pdf_image_auto_rotate=false
+display_create_owner_info=true
+#session_info=customer,customerId
+display_loginid_for_downloaded_by=false
+# please use false if you want landscape to be default.
+is_default_orientation_portrait=true
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/sql.properties b/vid-app-common/src/test/resources/WEB-INF/conf/sql.properties
new file mode 100644
index 00000000..62aac68d
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/sql.properties
@@ -0,0 +1,303 @@
+#SQL Statements for PostgreSQL
+
+#ReportLoader.java
+
+load.custom.report.xml = SELECT cr.report_xml FROM cr_report cr WHERE rep_id=?
+
+# need to copy to oracle
+load.remoteDB.schema = SELECT 'local' SCHEMA_ID, 'local' SCHEMA_DESC, null DATASOURCE_TYPE FROM dual union SELECT a.SCHEMA_ID, a.SCHEMA_DESC, DATASOURCE_TYPE FROM SCHEMA_INFO a where schema_id <> 'local' order by schema_id
+load.remoteDB.schema.where = SELECT a.SCHEMA_ID, a.SCHEMA_DESC, DATASOURCE_TYPE FROM SCHEMA_INFO a where schema_id = '[schema_id]'
+#formfield rendering
+
+formfield.id.name.sql.prefix=SELECT id, name FROM (
+formfield.id.name.sql=SELECT id, name
+
+formfield.id.name.sql.suffix=
+
+report.security.create= SELECT coalesce(cr.owner_id, cr.create_id) AS owner_id, cr.create_id, DATE_FORMAT(cr.create_date, '%m/%d/%Y') create_date, maint_id, DATE_FORMAT(cr.maint_date, '%m/%d/%Y') update_date, cr.public_yn FROM cr_report cr WHERE cr.rep_id = [rw.getReportID()]
+
+db.update.report.xml = SELECT cr.rep_id, cr.report_xml FROM cr_report cr WHERE rep_id=? FOR UPDATE
+
+update.custom.report.rec = UPDATE cr_report SET title='[Utils.oracleSafe(rw.getReportName())]', descr='[Utils.oracleSafe(rw.getReportDescr())]', public_yn='[(rw.isPublic()]', menu_id='[rw.getMenuID()]', menu_approved_yn='[(rw.isMenuApproved()]', owner_id=[rw.getOwnerID()], maint_id=[rw.getUpdateID()], maint_date=STR_TO_DATE('[rw.getUpdateDate()]', '[Globals.getOracleTimeFormat()]'), dashboard_type_yn='[(rw.isDashboardType()]', dashboard_yn= '[(rw.getReportType().equals(AppConstants.RT_DASHBOARD)]' WHERE rep_id = [rw.getReportID()]
+
+is.report.already.scheduled = select rep_id from cr_report_schedule where rep_id = ?
+
+create.custom.report.rec = INSERT INTO cr_report(rep_id, title, descr, public_yn, menu_id, menu_approved_yn, report_xml, owner_id, create_id, create_date, maint_id, maint_date, dashboard_type_yn, dashboard_yn, folder_id) VALUES([rw.getReportID()], '[Utils.oracleSafe(rw.getReportName())]', '[Utils.oracleSafe(rw.getReportDescr())]', '[rw.isPublic()]', '[rw.getMenuID()]', '[rw.isMenuApproved()]', '<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>', [rw.getOwnerID()], [rw.getCreateID()], STR_TO_DATE('[rw.getCreateDate()]', '[Globals.getOracleTimeFormat()]'), [rw.getUpdateID()], STR_TO_DATE('[rw.getUpdateDate()]', '[Globals.getOracleTimeFormat()]'), '[rw.isDashboardType()]', '[rw.getReportType().equals(AppConstants.RT_DASHBOARD)]',[rw.getFolderId()])
+
+get.user.report.names = SELECT cr.rep_id, cr.title FROM cr_report cr WHERE coalesce(cr.owner_id, cr.create_id) = [userID]
+
+get.report.owner.id = SELECT coalesce(cr.owner_id, cr.create_id) AS owner FROM cr_report cr WHERE rep_id = ?
+
+delete.report.record.log = DELETE FROM cr_report_log WHERE rep_id = [reportID]
+
+delete.report.record.users = DELETE FROM cr_report_schedule_users WHERE rep_id = [reportID]
+
+delete.report.record.schedule = DELETE FROM cr_report_schedule WHERE rep_id = [reportID]
+
+delete.report.record.access = DELETE FROM cr_report_access WHERE rep_id = [reportID]
+
+delete.report.record.email = DELETE FROM cr_report_email_sent_log WHERE rep_id = [reportID]
+
+delete.report.record.favorite = DELETE FROM cr_favorite_reports WHERE rep_id = [reportID]
+
+delete.report.record.report = DELETE FROM cr_report WHERE rep_id = [reportID]
+
+load.quick.links = select finalcr.rep_id, finalcr.title, finalcr.descr from (SELECT cr.rep_id, cr.title, cr.descr FROM (SELECT rep_id, MIN(read_only_yn) read_only_yn FROM ((SELECT ua.rep_id, ua.read_only_yn FROM cr_report_access ua WHERE ua.user_id = [userID]) UNION ALL (SELECT ra.rep_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.role_id IN ([roleList.toString()]))) report_access GROUP BY rep_id) ra LEFT JOIN cr_report cr ON cr.rep_id = ra.rep_id WHERE cr.menu_id LIKE '%[nvls(menuId)]%' AND cr.menu_approved_yn = 'Y' AND (coalesce(cr.owner_id, cr.create_id) = [userID] OR cr.public_yn = 'Y' OR ra.read_only_yn IS NOT NULL) UNION SELECT cr.rep_id, cr.title, cr.descr FROM cr_report cr WHERE cr.menu_id LIKE '%[nvls(menuId)]%' AND (coalesce(cr.owner_id, cr.create_id) = [userID] OR cr.public_yn = 'Y' or EXISTS (select * from fn_user_role where user_id=[userID] and role_id in (1)))) finalcr ORDER BY finalcr.title
+
+load.folder.reports = SELECT cr.rep_id, cr.rep_id report_id, concat([rep_title_sql] , (CASE WHEN cr.public_yn = 'Y' THEN '' ELSE '[PRIVATE_ICON]' END),cr.title,'</a>') title, cr.descr, concat(au.first_name,' ',au.last_name) owner_name, DATE_FORMAT(cr.create_date, '%m/%d/%Y') create_date, CASE WHEN coalesce(cr.owner_id, cr.create_id) = [userID] THEN 'N' ELSE coalesce(ra.read_only_yn, 'Y') END read_only_yn, CASE WHEN coalesce(cr.owner_id, cr.create_id) = [userID] THEN 'Y' ELSE 'N' END user_is_owner_yn FROM cr_report cr JOIN app_user au ON coalesce(cr.owner_id, cr.create_id) = au.user_id AND cr.folder_id= '[folderId]' LEFT JOIN (SELECT rep_id, MIN(read_only_yn) read_only_yn FROM ((SELECT ua.rep_id, ua.read_only_yn FROM cr_report_access ua WHERE ua.user_id = [userID]) UNION ALL(SELECT ra.rep_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.role_id IN ([roleList.toString()]))) report_access GROUP BY rep_id) ra ON cr.rep_id = ra.rep_id
+#If roleList.toString() is '' PostgreSQL returns an error - needs to be null instead of empty
+
+load.folder.reports.user = AND coalesce(cr.owner_id, cr.create_id) = [userID]
+
+load.folder.reports.publicsql = AND (coalesce(cr.owner_id, cr.create_id) = [userID] OR cr.public_yn = 'Y' OR ra.read_only_yn IS NOT NULL)
+
+load.quick.download.links = SELECT a.file_name, b.title,DATE_FORMAT(a.dwnld_start_time, '%W %d-%m-%Y %H:%i:%s') as time, a.dwnld_start_time FROM cr_report_dwnld_log a, cr_report b where a.user_id = [userID] and a.rep_id = b.rep_id and (a.dwnld_start_time) >= STR_TO_DATE(DATE_FORMAT(now() - INTERVAL 1 DAY, '%m/%d/%Y'), '%m/%d/%Y') and a.record_ready_time is not null order by a.dwnld_start_time
+
+load.reports.to.schedule = SELECT cr.rep_id, Initcap(cr.title), cr.descr FROM cr_report cr LEFT OUTER JOIN (SELECT rep_id, MIN(read_only_yn) read_only_yn FROM ((SELECT ua.rep_id, ua.read_only_yn FROM cr_report_access ua WHERE ua.user_id = [userID]) UNION ALL (SELECT ra.rep_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.role_id IN ([roleList.toString()]))) report_access GROUP BY rep_id) ra ON cr.rep_id = ra.rep_id AND (cr.public_yn = 'Y' OR ra.read_only_yn IS NOT NULL or cr.owner_id = [userID] )ORDER BY Initcap(cr.title)
+
+load.reports.to.add.in.dashboard = SELECT cr.rep_id, cr.title, cr.descr FROM cr_report cr LEFT OUTER JOIN (SELECT rep_id, MIN(read_only_yn) read_only_yn FROM ((SELECT ua.rep_id, ua.read_only_yn FROM cr_report_access ua WHERE ua.user_id = [userID]) UNION ALL (SELECT ra.rep_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.role_id IN ([roleList.toString()]))) report_access GROUP BY rep_id) ra ON cr.rep_id = ra.rep_id AND (coalesce(cr.owner_id, cr.create_id) = [userID] OR cr.public_yn = 'Y' OR ra.read_only_yn IS NOT NULL) AND (cr.dashboard_yn = 'N' or cr.dashboard_yn is null) ORDER BY cr.title
+
+load.my.recent.links = select rep_id, title, descr, form_fields from ( select rep_id, title, descr, form_fields from (select cr.rep_id, cr.title, a.form_fields, cr.descr, a.log_time, a.user_id, a.action, a.action_value from cr_report_log a, cr_report cr where user_id = [userID] AND action = 'Report Execution Time' and a.rep_id = cr.rep_id order by log_time desc) AS x) AS y where LIMIT 1, 6
+
+create.report.log.entry = INSERT INTO cr_report_log (rep_id, log_time, user_id, action, action_value, form_fields) VALUES([reportID], now(), [userID], '[action]' , '[executionTime]', '[form_fields]')
+
+create.report.log.entry.exec.time = INSERT INTO cr_report_log (rep_id, log_time, user_id, action, action_value, form_fields) VALUES([reportID], NOW() + INTERVAL 1 SECOND, [userID], '[action]' , '[executionTime]', '[formFields]')
+
+clear.report.log.entries = DELETE FROM cr_report_log WHERE rep_id = ? and user_id = ?
+
+load.report.log.entries = SELECT x.log_time, x.user_id, (CASE WHEN x.action = 'Report Execution Time' THEN concat('<a href=\"[AppUtils.getRaptorActionURL()]report.run.container&c_master=',x.rep_id,'&',x.form_fields,'&fromReportLog=Y&display_content=Y&noFormFields=Y&refresh=Y\">',x.action,'</a>') ELSE x.action END) action, (CASE WHEN x.action = 'Report Execution Time' THEN action_value ELSE 'N/A' END) time_taken, (CASE WHEN x.action = 'Report Execution Time' THEN concat('<a href=\"[AppUtils.getRaptorActionURL()]report.run.container&c_master=',x.rep_id,'&',x.form_fields,'&fromReportLog=Y&display_content=Y&noFormFields=Y&refresh=Y\"><img src=\"[AppUtils.getImgFolderURL()]test_run.gif" width=\"12\" height=\"12\" border=0 alt=\"Run report\"/></a>') ELSE 'N/A' END) run_image, x.name FROM (SELECT rl.rep_id, DATE_FORMAT(rl.log_time, '%m/%d/%Y %h:%i:%s %p') log_time, rl.action_value, concat(fuser.last_name ,', ',fuser.first_name) name, rl.user_id, rl.action, rl.form_fields FROM cr_report_log rl, fn_user fuser WHERE rl.rep_id = [nvls(reportId)] and rl.action != 'Report Run' and fuser.user_id = rl.user_id ORDER BY rl.log_time DESC) x LIMIT 100
+
+does.user.can.schedule.report = select crs.sched_user_id, count(*) from cr_report_schedule crs where sched_user_id = [userId] group by crs.sched_user_id having count(*) >= [Globals.getScheduleLimit()]
+
+does.user.can.schedule = select crs.schedule_id from cr_report_schedule crs where schedule_id = [scheduleId]
+
+get.system.date.time = select DATE_FORMAT(now(),'%m/%d/%Y %H:%i:%s')
+
+get.next.day.date.time = select DATE_FORMAT(NOW() + INTERVAL 1 DAY,'%m/%d/%Y %H:%i:%s')
+
+get.next.fifteen.minutes.date.time = select DATE_FORMAT(NOW() + INTERVAL 15 MINUTES,'%m/%d/%Y %H:%i:%s')
+
+get.next.thirty.minutes.date.time = select DATE_FORMAT(NOW() + INTERVAL 30 MINUTES,'%m/%d/%Y %H:%i:%s')
+
+get.template.file = select template_file from cr_report_template_map where report_id = [reportId]
+
+load.pdf.img.lookup = select image_id, image_loc from cr_raptor_pdf_img
+
+load.action.img.lookup = select image_id, image_loc from cr_raptor_action_img
+
+
+#ActionHandler.java
+
+report.values.map.def.a = SELECT x FROM (SELECT DISTINCT
+
+report.values.map.def.b = TO_CHAR([colName], '[nvl(displayFormat, AppConstants.DEFAULT_DATE_FORMAT)]')
+
+report.values.map.def.c = [colName]
+
+report.values.map.def.d = x FROM [rdef.getTableById(tableId).getTableName()] WHERE [colName] IS NOT NULL ORDER BY 1) xx LIMIT <= [Globals.getDefaultPageSize()]
+
+test.sched.cond.popup = SELECT 1 WHERE EXISTS ([sql])
+
+download.all.email.sent = Select user_id, rep_id from CR_REPORT_EMAIL_SENT_LOG where gen_key='[pdfAttachmentKey.trim()]' and log_id =[report_email_sent_log_id.trim()] and (now() - sent_date) < '1 day' limit 1
+
+download.all.gen.key = select schedule_id from cr_report_email_sent_log u where U.GEN_KEY = '[pdfAttachmentKey]'
+
+download.all.retrieve = SELECT au.user_id FROM (SELECT rs.schedule_id, rs.rep_id FROM cr_report_schedule rs WHERE rs.enabled_yn='Y' AND rs.run_date IS NOT NULL AND rs.schedule_id = [scheduleId]) x, cr_report r, app_user au WHERE x.rep_id = r.rep_id AND au.user_id IN (SELECT rsu.user_id FROM cr_report_schedule_users rsu WHERE rsu.schedule_id = x.schedule_id and rsu.schedule_id = [scheduleId] UNION SELECT ur.user_id FROM fn_user_role ur WHERE ur.role_id IN (SELECT rsu2.role_id FROM cr_report_schedule_users rsu2 WHERE rsu2.schedule_id = x.schedule_id and rsu2.schedule_id = [scheduleId]))
+
+download.all.insert = insert into cr_report_dwnld_log (user_id,rep_id,file_name,dwnld_start_time,filter_params) values (?,?,?,?,?)
+
+#ReportWrapper.java
+
+report.wrapper.format = SELECT coalesce(cr.owner_id, cr.create_id) owner_id, cr.create_id, DATE_FORMAT(cr.create_date, '[Globals.getOracleTimeFormat()]') create_date, maint_id, DATE_FORMAT(cr.maint_date, '[Globals.getOracleTimeFormat()]') update_date, cr.menu_id, cr.menu_approved_yn FROM cr_report cr WHERE cr.rep_id= [reportID]
+
+generate.subset.sql = SELECT [colNames.toString()] FROM (SELECT [colNames.toString()] FROM ([reportSQL]) AS x ) AS y
+
+report.sql.only.first.part = SELECT [colNames.toString()] FROM (SELECT [colNames.toString()] FROM (
+
+report.sql.only.second.part.a = [startRow]
+
+report.sql.only.second.part.b = [pageSize]
+#MYSQL: LIMIT [startRow], [pageSize]
+#ORacle: rownum >= [startRow] and rownum <= ([startRow]+[pageSize])
+#Postgre: limit [pageSize] offset [startRow]
+
+report.sql.only.second.part.b.noorderby = LIMIT [startRow]
+
+generate.sql.visual.select = SELECT
+
+generate.sql.visual.count = COUNT(*) cnt
+
+generate.sql.visual.dual =
+#No DUAL table in PostgreSQL so this is blank
+
+#ReportRuntime.java
+
+load.crosstab.report.data = SELECT [colNames.toString()] FROM ( [reportSQL]
+
+#RaptorRunHandler.java
+
+generate.sql.handler = SELECT x.* from ([sql]) AS x LIMIT 2
+
+generate.sql.select = SELECT [colNames.toString()] FROM (SELECT [colNames.toString()] FROM ([sql]) AS y) AS x
+
+#ReportSchedule.java
+
+load.schedule.data = SELECT rs.enabled_yn, DATE_FORMAT(rs.start_date, '%m/%d/%Y') start_date, DATE_FORMAT(rs.end_date, '%m/%d/%Y') end_date, DATE_FORMAT(rs.run_date, '%m/%d/%Y') run_date, coalesce(DATE_FORMAT(rs.run_date, '%h'), '12') run_hour, coalesce(DATE_FORMAT(rs.run_date, '%i'), '00') run_min, coalesce(DATE_FORMAT(rs.run_date, '%p'), 'AM') run_ampm, rs.recurrence, rs.conditional_yn, rs.notify_type, rs.max_row, rs.initial_formfields, rs.schedule_id, coalesce(DATE_FORMAT(rs.end_date, '%h'), '11') end_hour, coalesce(DATE_FORMAT(rs.end_date, '%i'), '45') end_min, coalesce(DATE_FORMAT(rs.end_date, '%p'), 'PM') end_ampm, encrypt_yn, attachment_yn FROM cr_report_schedule rs WHERE rs.rep_id = [reportID]
+
+load.schedule.getid = SELECT rsu.user_id, concat(fuser.last_name,', ',fuser.first_name), fuser.login_id FROM cr_report_schedule_users rsu, fn_user fuser WHERE rsu.rep_id = [reportID] AND rsu.schedule_id = [getScheduleID()] and rsu.user_id IS NOT NULL and rsu.user_id = fuser.user_id
+
+load.schedule.users = SELECT rsu.role_id FROM cr_report_schedule_users rsu WHERE rsu.rep_id = [reportID] AND rsu.schedule_id = [getScheduleID()] AND rsu.role_id IS NOT NULL
+
+new.schedule.data = select coalesce(max(schedule_id),0)+1 AS sequence from cr_report_schedule
+
+new.report.data = select coalesce(max(rep_id),0)+1 AS rep_id from cr_report
+
+execute.update = DELETE FROM cr_report_schedule_users WHERE rep_id = [reportID] and schedule_id = [getScheduleID()]
+
+execute.update.users = INSERT INTO cr_report_schedule_users (schedule_id, rep_id, user_id, role_id, order_no) VALUES([getScheduleID()], [reportID], [emailToUsers.get(i)).getId()], NULL, [(i + 1)])
+
+execute.update.roles = INSERT INTO cr_report_schedule_users (schedule_id, rep_id, user_id, role_id, order_no) VALUES([getScheduleID()], [reportID], NULL, [emailToRoles.get(i)).getId()], [((emailToUsers.size() + i + 1)])
+
+execute.update.activity = INSERT into cr_schedule_activity_log (schedule_id, notes, run_time) values ([getScheduleID()],'Submitted:Schedule',TO_DATE('[getRunDate()] [getRunHour()]:[getRunMin()] [getRunAMPM()]', 'MM/DD/YYYY HH:MI AM'))
+
+delete.schedule.data = SELECT 1 FROM cr_report_schedule WHERE rep_id = [reportID] and sched_user_id = [getScheduleUserID()] and schedule_id = [getScheduleID()]
+
+delete.schedule.data.users = DELETE FROM cr_report_schedule_users WHERE rep_id = [reportID] and schedule_id = [getScheduleID()]
+
+delete.schedule.data.id = DELETE FROM cr_report_schedule where rep_id = [reportID] and sched_user_id = [getScheduleUserID()] and schedule_id = [getScheduleID()]
+
+load.cond.sql = SELECT condition_large_sql FROM cr_report_schedule WHERE schedule_id=?
+
+load.cond.sql.select = SELECT condition_sql FROM cr_report_schedule WHERE schedule_id = [scheduleId]
+
+persist.cond.sql.update = update cr_report_schedule set condition_large_sql = '' where schedule_id = [scheduleId]
+#EMPTY CLOB() changed to ''
+
+persist.cond.sql.large = SELECT condition_large_sql FROM cr_report_schedule cr WHERE schedule_id=? FOR UPDATE
+
+persist.cond.sql.set = update cr_report_schedule set condition_sql = ? where schedule_id = [scheduleId]
+
+#DataCache.java
+
+get.data.view.actions = SELECT ts.web_view_action FROM cr_table_source ts WHERE ts.web_view_action IS NOT NULL
+
+get.public.report.id.names = SELECT rep_id, title FROM cr_report WHERE public_yn = 'Y' ORDER BY title
+
+get.private.accessible.names.a = SELECT cr.rep_id, cr.title FROM cr_report cr WHERE cr.rep_id not in (select rep_id from cr_report_access cra where user_id = '[user_id]'
+
+get.private.accessible.names.if = OR role_id in (
+
+get.private.accessible.names.b = ) AND public_yn = 'N' and cr.owner_id = '[user_id]' order by 2
+
+get.group.accessible.names.a = SELECT cr.rep_id, cr.title FROM cr_report cr WHERE cr.rep_id in (select rep_id from cr_report_access cra where user_id = '[user_id]'
+
+get.group.accessible.names.b = ) AND public_yn = 'N' order by 2
+
+get.report.table.sources.a = SELECT table_name, display_name, pk_fields, web_view_action, large_data_source_yn, filter_sql FROM cr_table_source
+
+get.report.table.sources.where = where SOURCE_DB= '[dBInfo]'
+
+get.report.table.sources.if = where SOURCE_DB is null or SOURCE_DB = '[AppConstants.DB_LOCAL]'
+
+get.report.table.sources.else = ORDER BY table_name
+
+grab.report.table.a = SELECT ts.table_name, ts.display_name, ts.pk_fields, ts.web_view_action, ts.large_data_source_yn, ts.filter_sql FROM cr_table_source ts WHERE
+
+grab.report.table.if = ts.SOURCE_DB= '[dBInfo]'
+
+grab.report.table.else = (ts.SOURCE_DB is null or ts.SOURCE_DB = '[AppConstants.DB_LOCAL]')
+
+grab.report.table.b = except SELECT ts.table_name, ts.display_name, ts.pk_fields, ts.web_view_action, ts.large_data_source_yn, ts.filter_sql from cr_table_source ts where table_name in (select table_name from cr_table_role where role_id not IN [sb.toString()]) and
+
+grab.report.table.c = ORDER BY 1
+
+get.report.table.crjoin = SELECT src_table_name, dest_table_name, join_expr FROM cr_table_join
+
+get.report.table.joins = SELECT tj.src_table_name, tj.dest_table_name, tj.join_expr FROM cr_table_join tj WHERE ((EXISTS (SELECT 1 FROM cr_table_role trs WHERE trs.table_name=tj.src_table_name AND trs.role_id IN [sb.toString()])) OR (NOT EXISTS (SELECT 1 FROM cr_table_role trs WHERE trs.table_name=tj.src_table_name))) AND ((EXISTS (SELECT 1 FROM cr_table_role trd WHERE trd.table_name=tj.dest_table_name AND trd.role_id IN [sb.toString()])) OR (NOT EXISTS (SELECT 1 FROM cr_table_role trd WHERE trd.table_name=tj.dest_table_name)))
+
+generate.report.table.col = SELECT a.table_name, a.column_name, a.data_type, a.label FROM user_column_def a WHERE a.table_name = '[tableName.toUpperCase()]' ORDER BY a.column_id
+
+generate.db.user.sql.a = SELECT utc.table_name, utc.column_name, utc.data_type,
+
+generate.db.user.sql.if = utc.column_name FROM user_tab_columns utc
+
+generate.db.user.sql.else = coalesce(x.label, utc.column_name) FROM user_tab_columns utc
+
+generate.db.user.sql.b = WHERE utc.table_name = '[tableName.toUpperCase()]'
+
+generate.db.user.sql.c = AND utc.table_name = x.table_name AND utc.column_name = x.column_name
+
+generate.db.user.sql.d = ORDER BY utc.column_id
+
+#SearchHandler.java
+
+load.report.search.result = SELECT cr.rep_id, cr.rep_id report_id, [rep_title_sql] title, cr.descr, concat(au.first_name,' ',au.last_name) owner_name, DATE_FORMAT(cr.create_date, '%m/%d/%Y') create_date, CASE WHEN coalesce(cr.owner_id, cr.create_id) = [userID] THEN 'N' ELSE coalesce(ra.read_only_yn, 'Y') END read_only_yn, CASE WHEN coalesce(cr.owner_id, cr.create_id) = [userID] THEN 'Y' ELSE 'N' END user_is_owner_yn, case when report_xml like '%<allowSchedule>N</allowSchedule>%' then 'N' when report_xml like '%<allowSchedule>Y</allowSchedule>%' or 1 = (select distinct 1 from cr_report_schedule where rep_id = cr.rep_id) then 'Y' else 'N' end FROM cr_report cr JOIN fn_user au ON coalesce (cr.owner_id, cr.create_id) = au.user_id [fReportID] [fReportName] LEFT JOIN(SELECT rep_id, MIN(read_only_yn) read_only_yn FROM ((SELECT ua.rep_id, ua.read_only_yn FROM cr_report_access ua WHERE ua.user_id = [userID]) UNION ALL (SELECT ra.rep_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.role_id IN ([roleList.toString()]))) report_access GROUP BY rep_id) ra ON ra.rep_id = cr.rep_id
+
+load.report.search.instr = WHERE cr.menu_id LIKE '%[menuId]%'
+
+load.report.search.result.user = WHERE coalesce(cr.owner_id, cr.create_id) = [userID]
+
+load.report.search.result.public = WHERE (coalesce(cr.owner_id, cr.create_id) = [userID] OR cr.public_yn = 'Y' OR ra.read_only_yn IS NOT NULL)
+
+load.report.search.result.fav = WHERE cr.rep_id in (select rep_id from cr_favorite_reports where user_id = [userID]
+
+load.report.search.result.sort = ORDER BY CASE coalesce(cr.owner_id, cr.create_id) WHEN [userID] THEN ' ' WHEN 'upper(concat(au.first_name,' ',au.last_name))' ELSE 'upper(cr.title)' END
+
+load.folder.report.result = SELECT cr.rep_id, cr.rep_id report_id, concat([rep_title_sql] , (CASE WHEN cr.public_yn = 'Y' THEN '' ELSE '[PRIVATE_ICON]' END),cr.title,'</a>') title, cr.descr, concat(au.first_name,' ',au.last_name) owner_name, TO_CHAR(cr.create_date, 'MM/DD/YYYY') create_date, CASE WHEN coalesce(cr.owner_id, cr.create_id) = [userID] THEN 'N' ELSE coalesce(ra.read_only_yn, 'Y') END read_only_yn, CASE WHEN coalesce(cr.owner_id, cr.create_id) = [userID] THEN 'Y' ELSE 'N' END user_is_owner_yn FROM cr_report cr JOIN fn_user au ON coalesce (cr.owner_id, cr.create_id) = au.user_id AND TO_CHAR(cr.rep_id, 'FM99999999') like coalesce('%[fReportID]%', TO_CHAR(cr.rep_id, 'FM99999999')) AND UPPER(cr.title) LIKE UPPER('%[fReportName]%') LEFT JOIN(SELECT rep_id, MIN(read_only_yn) read_only_yn FROM ((SELECT ua.rep_id, ua.read_only_yn FROM cr_report_access ua WHERE ua.user_id = [userID]) UNION ALL (SELECT ra.rep_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.role_id IN ([roleList.toString()]))) report_access GROUP BY rep_id) ra ON ra.rep_id = cr.rep_id
+
+load.folder.report.result.sort = ORDER BY CASE coalesce(cr.owner_id, cr.create_id) WHEN [userID] THEN ' ' WHEN '(concat(au.first_name,' ',au.last_name))' ELSE 'cr.title' END
+
+#WizardProcessor.java
+
+process.filter.add.edit = '[argValue]'
+
+#ReportDefinition.java
+
+persist.report.adhoc = SELECT nextval('[Globals.getAdhocReportSequence()]') AS sequence
+
+#Globals.java
+
+initialize.roles = SELECT 1 WHERE EXISTS (SELECT 1 FROM cr_table_role)
+
+initialize.version = SELECT cr_raptor.get_version
+
+# scheduler
+
+
+scheduler.available.schedules = SELECT x.rep_id, x.schedule_id, x.conditional_yn, x.condition_large_sql, x.notify_type, x.max_row, x.initial_formfields, x.processed_formfields, r.title, x.user_id FROM ( SELECT rs.rep_id, rs.schedule_id, rs.sched_user_id user_id, rs.conditional_yn, rs.condition_large_sql, rs.notify_type, rs.max_row, rs.initial_formfields, rs.processed_formfields FROM cr_report_schedule rs WHERE rs.enabled_yn='Y' AND rs.start_date <= [currentDate] AND (rs.end_date >= [currentDate] or rs.end_date is null ) AND rs.run_date IS NOT NULL ) x, cr_report r WHERE x.rep_id = r.rep_id
+
+random.string = select ( concat('Z' , round(random() * 1000000000000) ) )
+
+
+scheduler.user.emails = SELECT au.user_id FROM (SELECT rs.schedule_id, rs.rep_id FROM cr_report_schedule rs WHERE rs.enabled_yn='Y' AND rs.start_date <= now() AND rs.end_date >= now() AND rs.run_date IS NOT NULL AND rs.schedule_id = [p_schedule_id] ) x, cr_report r, fn_user au WHERE x.rep_id = r.rep_id AND au.user_id IN (SELECT rsu.user_id FROM cr_report_schedule_users rsu WHERE rsu.schedule_id = x.schedule_id and rsu.schedule_id = [p_schedule_id] UNION SELECT ur.user_id FROM fn_user_role ur WHERE ur.role_id IN (SELECT rsu2.role_id FROM cr_report_schedule_users rsu2 WHERE rsu2.schedule_id = x.schedule_id and rsu2.schedule_id = [p_schedule_id]))
+
+
+# my logins
+
+app.query = SELECT APP_ID, ML_APP_NAME, MOTS_ID from fn_app
+
+user.log.query = SELECT DISTINCT IFNULL(SBCID, '') CUID, '' AWID, CONCAT('"',IFNULL(SBCID, ''),'"') APPLICATIONUSERID, CONCAT('"',IFNULL(FIRST_NAME, ''),'"') FIRST_NAME, CONCAT('"',substr(IFNULL(MIDDLE_NAME, ''), 0, 1),'"') MIDDLE_INITIAL, CONCAT('"',IFNULL(LAST_NAME, ''),'"') LAST_NAME, IFNULL(DATE_FORMAT(LAST_LOGIN_DATE, '%Y/%m/%d'), '') LAST_LOGON_DATE, DATE_FORMAT(CREATED_DATE, '%Y/%m/%d') ACCOUNT_ACTIVATION_DATE, IFNULL(DATE_FORMAT(MODIFIED_DATE, '%Y/%m/%d'), '') LAST_DATE_ACCOUNT_MODIFIED, '' LAST_PASSWORD_CHANGE_DATE, CONCAT('"',IFNULL(FIRST_NAME, ''),' ',IFNULL(MIDDLE_NAME, ''),' ',IFNULL(LAST_NAME, ''),'"') FULL_USER_NAME, '' NT_ID, IFNULL(EMAIL, '') EMAIL FROM FN_USER FU, FN_USER_ROLE FUR WHERE FU.USER_ID \= FUR.USER_ID and FUR.app_id \= ? and ACTIVE_YN \= 'Y' and sbcid is not null order by 1
+
+profile.log.query = SELECT DISTINCT CONCAT('"' , ROLE_NAME , '"') PROFILE_NAME, '""' SECURITY_SETTINGS FROM FN_ROLE FR, FN_USER_ROLE FUR WHERE FUR.ROLE_ID \= FR.ROLE_ID and FR.ACTIVE_YN \= 'Y' and ((FUR.APP_ID \= 1 and FR.ROLE_NAME <> 'Standard User') or (FUR.APP_ID \= ? and FUR.APP_ID <> 1)) ORDER BY 1
+
+user.profile.log.query = SELECT DISTINCT IFNULL(SBCID, '') CUID, '' AWID, CONCAT('"' , IFNULL(SBCID, '') , '"') APPLICATIONUSERID , CONCAT('"' , ROLE_NAME , '"') PROFILE_NAME FROM FN_USER A, FN_USER_ROLE B, FN_ROLE C WHERE A.USER_ID \= B.USER_ID AND B.ROLE_ID \= C.ROLE_ID AND A.ACTIVE_YN \= 'Y' AND C.ACTIVE_YN \= 'Y' AND a.sbcid is not null AND ((B.APP_ID \= 1 and C.ROLE_NAME <> 'Standard User') or (B.APP_ID \= ? and B.APP_ID <> 1)) ORDER BY 1
+
+all.accounts.log.query = SELECT DISTINCT IFNULL(SBCID, '') CUID, (case when A.ACTIVE_YN\='Y' then 'ACTIVE' else 'INACTIVE' end) ACTIVE_YN, CONCAT('"' , IFNULL(SBCID, '') , '"') APPLICATIONUSERID , IFNULL(DATE_FORMAT(LAST_LOGIN_DATE, '%Y/%m/%d'), '') LAST_LOGON_DATE, '' LAST_PASSWORD_CHANGE_DATE, CONCAT('"' , ROLE_NAME , '"') PROFILE_NAME FROM FN_USER A, FN_USER_ROLE B, FN_ROLE C WHERE A.USER_ID \= B.USER_ID AND B.ROLE_ID \= C.ROLE_ID AND a.sbcid is not null AND ((B.APP_ID \= 1 and C.ROLE_NAME <> 'Standard User') or (B.APP_ID \= ? and B.APP_ID <> 1)) ORDER BY 1
+
+# basic sql
+
+seq.next.val = SELECT nextval('[sequenceName]') AS id
+
+current.date = now()
+
+nvl = IFNULL
+
+# report security
+report.user.access = SELECT ra.role_id, ra.user_id, ra.read_only_yn FROM cr_report_access ra WHERE ra.rep_id = [reportID]
+add.user.access = INSERT INTO cr_report_access (rep_id, order_no, role_id, user_id, read_only_yn) VALUES([reportID], IFNULL((select order_no from (SELECT MAX(order_no) AS order_no FROM cr_report_access WHERE rep_id=[reportID]) AS temp), 0)+1, NULL, [userID], '[readOnlyAccess]')
+update.user.access = UPDATE cr_report_access SET read_only_yn='[readOnlyAccess]' WHERE rep_id=[reportID] AND user_id=[userID]
+remove.user.access = DELETE FROM cr_report_access WHERE rep_id=[reportID] AND user_id=[userID]
+add.role.access = INSERT INTO cr_report_access (rep_id, order_no, role_id, user_id, read_only_yn) VALUES([reportID], IFNULL((select order_no from (SELECT MAX(order_no) AS order_no FROM cr_report_access WHERE rep_id=[reportID]) AS temp), 0)+1, [roleID], NULL, '[readOnlyAccess]')
+update.role.access = UPDATE cr_report_access SET read_only_yn='[readOnlyAccess]' WHERE rep_id=[reportID] AND role_id=[roleID]
+remove.role.access = DELETE FROM cr_report_access WHERE rep_id=[reportID] AND role_id=[roleID]
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/system.properties b/vid-app-common/src/test/resources/WEB-INF/conf/system.properties
new file mode 100644
index 00000000..4fbbe7cf
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/system.properties
@@ -0,0 +1,167 @@
+# Properties read by ECOMP Core library, epsdk-core.jar
+
+##########################################################################
+# The following properties should NOT be changed by partner applications.
+##########################################################################
+
+application_user_id = 30000
+post_default_role_id = 16
+clustered = true
+
+#Enable Fusion Mobile capabilities for the application
+mobile_enable = false
+
+# Cache config file is needed on the classpath
+cache_config_file_path = /WEB-INF/classes/cache.ccf
+cache_switch = 199
+cache_load_on_startup = false
+
+user_name = fullName
+decryption_key = AGLDdG4D04BKm2IxIWEr8o==
+#db.userName=XXXX
+#db.password=XXXX
+#db.connectionURL=jdbc:oracle:thin:@XXXX/XX
+#db.hib.dialect=org.hibernate.dialect.Oracle10gDialect
+#db.driver=oracle.jdbc.driver.OracleDriver
+#Hibernate
+#hb.dialect=org.hibernate.dialect.Oracle10gDialect
+#hb.show_sql=true
+
+#Postgre
+#db.userName=XXXX
+#db.password=XXXX
+#db.connectionURL=jdbc:postgresql://XXXX/XX
+#db.hib.dialect=org.hibernate.dialect.PostgreSQLDialect
+#db.driver=org.postgresql.Driver
+#hb.dialect=org.hibernate.dialect.PostgreSQLDialect
+#hb.show_sql=true
+
+#Mysql
+db.driver = com.mysql.jdbc.Driver
+#db.connectionURL = jdbc:mysql://demeter.homer.att.com:3306/ecomp_sdk_1707_att
+db.connectionURL = jdbc:mysql://localhost:3306/vid_portal
+db.userName = euser
+db.password = euser
+db.hib.dialect = org.hibernate.dialect.MySQLDialect
+db.min_pool_size = 5
+db.max_pool_size = 10
+hb.dialect = org.hibernate.dialect.MySQLDialect
+# SQL statements are logged to stdout
+hb.show_sql = true
+hb.idle_connection_test_period = 3600
+app_display_name = VID
+files_path = /opt/app/vid/license
+
+# menu settings
+#menu_query_name = menuData
+#menu_properties_file_location = /WEB-INF/fusion/menu/
+#application_menu_set_name = APP
+#application_menu_attribute_name = applicationMenuData
+#application_menu_properties_name = menu.properties
+#business_direct_menu_set_name = BD
+#business_direct_menu_properties_name = bd.menu.properties
+#business_direct_menu_attribute_name = businessDirectMenuData
+
+application_name = Virtual Infrastructure Deployment
+
+
+#element map files
+#element_map_file_path = /tmp
+#element_map_icon_path = app/vid/icons/
+element_map_file_path = app/fusionapp/files/
+element_map_icon_path = app/fusionapp/icons/
+
+#aai related properties
+#dev server
+#aai.server.url.base=https://mtanjv9aaas40.aic.cip.att.com:8443/aai/
+#aai.server.url=https://mtanjv9aaas40.aic.cip.att.com:8443/aai/v10/
+#aai.oldserver.url.base=https://mtanjv9aaas40.aic.cip.att.com:8443/aai/servers/
+#aai.oldserver.url=https://mtanjv9aaas40.aic.cip.att.com:8443/aai/servers/v3/
+#ist servers
+aai.server.url.base=https://aai-ext1.test.att.com:8443/aai/
+aai.server.url=https://aai-ext1.test.att.com:8443/aai/v10/
+aai.oldserver.url.base=https://aai-ext1.test.att.com:8443/aai/servers/
+aai.oldserver.url=https://aai-ext1.test.att.com:8443/aai/servers/v3/
+aai.truststore.filename=tomcat_keystore
+aai.truststore.passwd.x=OBF:1i9a1u2a1unz1lr61wn51wn11lss1unz1u301i6o
+aai.keystore.filename=aai-client-cert.p12
+aai.keystore.passwd.x=OBF:1i9a1u2a1unz1lr61wn51wn11lss1unz1u301i6o
+aai.use.client.cert=true
+aai.vnf.provstatus=PREPROV,NVTPROV,PROV,CAPPED
+
+#Cron Schedules have 6 required fields and 1 optional field:
+# Seconds Minutes Hours Day-of-Month Month Day-of-Week Year
+log_cron = 0 0/1 * * * ?;
+mylogins_feed_cron = 0 0/60 * * * ?;
+#sessiontimeout_feed_cron = 0 * * * * ? *
+my_login_feed_output_dir = /tmp/MyLogins
+
+# ECOMP Portal Shared Context REST API URL
+ecomp_shared_context_rest_url= https://www.ecomp.att.com:8080/ecompportal/context
+
+# Link shown in Help menu
+contact_us_link = https://wiki.web.att.com/display/EcompPortal/ECOMP+Portal+Home
+
+# Camunda cockpit link
+camunda_cockpit_link = https://cloopwf.client.research.att.com:8443/camunda/app/cockpit/default/#/dashboard
+# An Unique 128-bit value defined to identify a specific version
+# of an application deployed on a specific virtual machine.
+# This value must be generated and updated by the application
+# which is using the ECOMP SDK at the time of its deployment.
+# Online Unique UUID generator - https://www.uuidgenerator.net/
+instance_uuid=8da691c9-987d-43ed-a358-00ac2f35685d
+
+# R Cloud feature
+guard_notebook_url=https://rcloud.research.att.com/mini.html?notebook=a06a9cf14211012e221bf842c168849d&
+
+#ECOMP redirect url
+#ecomp_redirect_url = https://webtest.csp.att.com/ecomp_portal_dev_n1/ecompui/process_csp
+#ecomp_rest_url = https://webtest.csp.att.com/ecomp_portal_dev_n1/ecompui/auxapi
+# Replace these default values with the ones for your specific App. Ecomp Portal admin obtains from EP website.
+#ueb_app_mailbox_name = ECOMP-PORTAL-OUTBOX-90
+#ueb_app_key = sYH0NJnsKmJC1B2A
+#ueb_app_secret = YOtknsT2wVFz9WISlSPDaAtd
+
+#MSO related properties
+#simulator
+#mso.server.url=http://localhost:8089
+#mso.server.url=https://msoapih-app.mtsnj.aic.cip.att.com:8443/ecomp/mso/infra
+#dev2dev
+#good
+#dev
+#mso.server.url=http://mtanjv9moah10-eth0.aic.cip.att.com:8080/ecomp/mso/infra
+#istScrum-Master
+mso.server.url=https://msoapih-app-st.ecomp.cci.att.com:8443/ecomp/mso/infra
+#mso.server.url=https://msoapih-app.mtsnj.aic.cip.att.com:8443/ecomp/mso/infra
+#mso.server.url=http://mtanjv9moah01-eth0.aic.cip.att.com:8080/ecomp/mso/infra
+#mso.server.url=http://mtanjv9moah11-eth1-0.aic.cip.att.com:8080
+mso.polling.interval.msecs=10000
+mso.max.polls=10
+mso.user.name=infraportal
+mso.password.x=OBF:1ghz1kfx1j1w1m7w1i271e8q1eas1hzj1m4i1iyy1kch1gdz
+mso.restapi.svc.instance=/serviceInstances/v4
+mso.restapi.vnf.instance=/serviceInstances/v4/<service_instance_id>/vnfs
+mso.restapi.network.instance=/serviceInstances/v4/<service_instance_id>/networks
+mso.restapi.vf.module.instance=/serviceInstances/v4/<service_instance_id>/vnfs/<vnf_instance_id>/vfModules
+mso.restapi.volume.group.instance=/serviceInstances/v4/<service_instance_id>/vnfs/<vnf_instance_id>/volumeGroups
+mso.restapi.get.orc.req=/orchestrationRequests/v4
+mso.restapi.get.orc.reqs=/orchestrationRequests/v4?
+vid.truststore.filename=/opt/app/vid/etc/vid_keystore.jks
+mso.dme2.client.timeout=30000
+mso.dme2.client.read.timeout=120000
+
+#vid.truststore.filename=/Users/Oren/Downloads/vid_keystore2.jks
+
+vid.truststore.passwd.x=OBF:1wgg1wfq1uus1uui1x131x0r1x1v1x1j1uvo1uve1wg81wfi
+#mso.dme2.server.url=http://mso-api-handler-anap-v1.mso.ecomp.att.com/services/ecomp/mso?
+mso.dme2.server.url=http://mso-api-handler-anap-v1.mso.ecomp.att.com/services/ecomp/mso?version=1607&envContext=TEST&routeOffer=st_mtsnj
+#mso.dme2.server.url=https://ActiveAndAvailableInventory-CloudNetwork-v1.aai.att.com/aai?version=1&envContext=DEV&routeOffer=devINT1
+mso.dme2.enabled=false
+asdc.model.namespace=org.openecomp.
+sdc.svc.api.path=asdc/v1/catalog/services
+sdc.resource.api.path=asdc/v1/catalog/resource
+
+# Application base URL has the host and app context only; a proper prefix of the on-boarded URL.
+# Only required for applications using WebJunction or FE/BE separation. For example:
+# app_base_url = https://www.e-access.att.com/app_junction/app_context/
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/conf/system.properties.cml b/vid-app-common/src/test/resources/WEB-INF/conf/system.properties.cml
new file mode 100644
index 00000000..bc4040e6
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/conf/system.properties.cml
@@ -0,0 +1,97 @@
+# Properties read by ECOMP Core library, epsdk-core.jar
+
+##########################################################################
+# The following properties should NOT be changed by partner applications.
+##########################################################################
+
+application_user_id = 30000
+post_default_role_id = 16
+clustered = true
+
+#Enable Fusion Mobile capabilities for the application
+mobile_enable = false
+
+# Cache config file is needed on the classpath
+cache_config_file_path = /WEB-INF/classes/cache.ccf
+cache_switch = 199
+cache_load_on_startup = false
+
+user_name = fullName
+decryption_key = AGLDdG4D04BKm2IxIWEr8o==
+
+##########################################################################
+# The following properties REQUIRE changes by partner applications.
+##########################################################################
+
+#Oracle
+#db.userName=quantumbd
+#db.password=c1syn2yhmr
+#db.connectionURL=jdbc:oracle:thin:@dbhost.yourcompany.com:1527:mod112a
+#db.hib.dialect=org.hibernate.dialect.Oracle10gDialect
+#db.driver=oracle.jdbc.driver.OracleDriver
+#Hibernate
+#hb.dialect=org.hibernate.dialect.Oracle10gDialect
+#hb.show_sql=true
+
+#Postgres
+#db.userName=quantumbd
+#db.password=c1syn2yhmr
+#db.connectionURL=jdbc:postgresql://dbhost.yourcompany.com:61382/quantum
+#db.hib.dialect=org.hibernate.dialect.PostgreSQLDialect
+#db.driver=org.postgresql.Driver
+#hb.dialect=org.hibernate.dialect.PostgreSQLDialect
+#hb.show_sql=true
+
+ db.connectionURL = jdbc:mysql://demeter.homer.att.com:3306/ecomp_sdk_1707_att
+ db.userName = portal
+ db.password = P0rt@l
+
+
+
+#Mysql
+db.driver = com.mysql.jdbc.Driver
+#db.connectionURL = jdbc:mysql://localhost:3306/ecomp_sdk
+#db.userName = ecomp_sdk_user
+#db.password = ecomp_sdk_pass
+db.hib.dialect = org.hibernate.dialect.MySQLDialect
+db.min_pool_size = 5
+db.max_pool_size = 10
+hb.dialect = org.hibernate.dialect.MySQLDialect
+# SQL statements are logged to stdout
+hb.show_sql = true
+hb.idle_connection_test_period = 3600
+
+app_display_name = EPSDK App ATT
+# license file area
+files_path = /tmp
+
+#element map files
+element_map_file_path = app/fusionapp/files/
+element_map_icon_path = app/fusionapp/icons/
+
+#Cron Schedules have 6 required fields and 1 optional field:
+# Seconds Minutes Hours Day-of-Month Month Day-of-Week Year
+log_cron = 0 0/1 * * * ?;
+
+# ECOMP Portal Shared Context REST API URL
+ecomp_shared_context_rest_url= https://www.ecomp.att.com:8080/ecompportal/context
+
+# Link shown in Help menu
+contact_us_link = https://wiki.web.att.com/display/EcompPortal/ECOMP+Portal+Home
+
+# Camunda cockpit link
+camunda_cockpit_link = https://cloopwf.client.research.att.com:8443/camunda/app/cockpit/default/#/dashboard
+
+# An Unique 128-bit value defined to identify a specific version
+# of an application deployed on a specific virtual machine.
+# This value must be generated and updated by the application
+# which is using the ECOMP SDK at the time of its deployment.
+# Online Unique UUID generator - https://www.uuidgenerator.net/
+instance_uuid=8da691c9-987d-43ed-a358-00ac2f35685d
+
+# R Cloud feature
+guard_notebook_url=https://rcloud.research.att.com/mini.html?notebook=a06a9cf14211012e221bf842c168849d&
+
+# Application base URL has the host and app context only; a proper prefix of the on-boarded URL.
+# Only required for applications using WebJunction or FE/BE separation. For example:
+# app_base_url = https://www.e-access.att.com/app_junction/app_context/
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/conf/fusion.properties b/vid-app-common/src/test/resources/WEB-INF/fusion/conf/fusion.properties
new file mode 100644
index 00000000..3d8e8155
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/conf/fusion.properties
@@ -0,0 +1,69 @@
+# domain settings
+#domain_class_location = com.att.fusion.domain.
+
+# validator settings
+#default_error_message = Default error message
+
+# login settings
+login_method_csp = csp
+login_method_web_junction = web_junction
+login_method_backdoor = backdoor
+login_method_attribute_name = login_method
+
+#login message
+login.error.hrid.empty = Login failed, please contact system administrator.
+login.error.hrid.not-found = User not found, please contact system administrator.
+login.error.user.inactive = Account is disabled, please contact system administrator.
+
+# CSP settings
+csp_cookie_name = attESSec
+csp_gate_keeper_data_key = MgmtSysCtr
+csp_gate_keeper_prod_key = PROD
+csp_login_url = https://www.e-access.att.com/empsvcs/hrpinmgt/pagLogin/?sysName=MgmtSysCtr&retURL=
+csp_logout_url = https://www.e-access.att.com/empsvcs/hrpinmgt/pagLogout/?retURL=
+
+authentication_mechanism = BOTH
+
+#csp_gate_keeper_prod_key = DEVL
+user_attribute_name = user
+#csp_login_url = https://www.e-access.att.com/empsvcs/hrpinmgt/pagLogin/?sysName=MgmtSysCtr&retURL=
+#csp_logout_url = https://webtest.csp.att.com/empsvcs/hrpinmgt/pagLogout/?retURL=
+
+# Web Junction settings
+#web_junction_user_id_header_name = iv-user
+
+# User Session settings
+#user_attribute_name = user
+roles_attribute_name = roles
+role_functions_attribute_name = role_functions
+role_function_list = role_function_list
+#client_device_attribute_name = client_device
+#client_device_emulation = false
+#client_device_type_to_emulate = com.att.fusion.web.clientdevice.mobile.IPhoneDevice
+
+# POST settings
+post_initial_context_factory = com.sun.jndi.ldap.LdapCtxFactory
+post_provider_url = ldap://ldap.webphone.att.com:389
+post_security_principal = ou=people,o=att,c=us
+post_max_result_size = 499
+
+# menu settings
+menu_query_name = menuData
+#menu_properties_file_location = /WEB-INF/fusion/menu/
+application_menu_set_name = APP
+application_menu_attribute_name = applicationMenuData
+#application_menu_properties_name = menu.properties
+business_direct_menu_set_name = BD
+#business_direct_menu_properties_name = bd.menu.properties
+business_direct_menu_attribute_name = businessDirectMenuData
+
+# RAPTOR config settings
+#raptor_config_file_path = /WEB-INF/conf/
+
+# Role settings
+sys_admin_role_id = 1
+#sys_admin_role_function_delete_from_ui = true
+
+# Profile Search settings
+#profile_search_report_id=181
+#callable_profile_search_report_id=386
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/defs/definitions.xml b/vid-app-common/src/test/resources/WEB-INF/fusion/defs/definitions.xml
new file mode 100644
index 00000000..c9e10a16
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/defs/definitions.xml
@@ -0,0 +1,242 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE tiles-definitions PUBLIC
+ "-//Apache Software Foundation//DTD Tiles Configuration 3.0//EN"
+ "http://tiles.apache.org/dtds/tiles-config_3_0.dtd">
+
+<!-- This tiles definitions file is fusion/defs/definitions.xml. It maps
+ tokens used by SDK-core controllers to JSP file paths. To minimize upgrade
+ effort, this file should not be changed by on-boarding applications. -->
+
+<tiles-definitions>
+
+ <definition name="ebz_template" template="/WEB-INF/fusion/jsp/ebz_template.jsp">
+ <put-attribute name="title" value=""></put-attribute>
+ <put-attribute name="header"
+ value="/WEB-INF/fusion/jsp/ebz/ebz_header.jsp"></put-attribute>
+ <put-attribute name="body" value=""></put-attribute>
+ <put-attribute name="footer"
+ value="/WEB-INF/fusion/jsp/ebz/ebz_footer.jsp"></put-attribute>
+ </definition>
+
+ <definition name="ebz_template_noheader_nofooter"
+ template="/WEB-INF/fusion/jsp/ebz_template_noheader_nofooter.jsp">
+ <put-attribute name="body" value=""></put-attribute>
+ </definition>
+
+ <definition name="ebz_template_report_embedded"
+ template="/WEB-INF/fusion/jsp/ebz_template_report_embedded.jsp">
+ <put-attribute name="body" value=""></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="es_search_demo">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/es_search_demo.jsp"></put-attribute>
+ <put-attribute name="viewName" value="elastic_search"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="es_suggest_demo">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/es_suggest_demo.jsp"></put-attribute>
+ <put-attribute name="viewName" value="elastic_search"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="user_profile">
+ <put-attribute name="body" value="/WEB-INF/jsp/user_profile.jsp"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="profile_search">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/profile_search.jsp"></put-attribute>
+ <put-attribute name="viewName" value="profile_search"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="profile">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/profile.jsp"></put-attribute>
+ <put-attribute name="viewName" value="profile"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="menu">
+ <put-attribute name="body" value="/WEB-INF/jsp/menu.jsp"></put-attribute>
+ <put-attribute name="viewName" value="menu"></put-attribute>
+ </definition>
+
+
+ <definition extends="ebz_template" name="role_list">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/role_list.jsp"></put-attribute>
+ <put-attribute name="viewName" value="role_list"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="role">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/role.jsp"></put-attribute>
+ <put-attribute name="viewName" value="role"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="role_function_list">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/role_function_list.jsp"></put-attribute>
+ <put-attribute name="viewName" value="role_function_list"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="post_search">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/post_search.jsp"></put-attribute>
+ <put-attribute name="viewName" value="post_search"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="error">
+ <put-attribute name="body" value="/WEB-INF/jsp/error.jsp"></put-attribute>
+ <put-attribute name="viewName" value="error"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="collaborate_list">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/collaborateList.jsp"></put-attribute>
+ </definition>
+
+ <!-- <definition extends="ebz_template" name="notebook">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/notebook.jsp"></put-attribute>
+ </definition> -->
+
+ <definition name="notebook"
+ template="app/fusion/notebook-integration/scripts/view-models/notebook.htm" />
+
+
+ <definition name="nbooktest"
+ template="app/fusion/notebook-integration/scripts/view-models/notebook-frame.html"/>
+
+
+ <definition extends="ebz_template" name="jcs_admin">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/jcs_admin.jsp"></put-attribute>
+ <put-attribute name="viewName" value="jcs_admin"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="usage_list">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/usage_list.jsp"></put-attribute>
+ <put-attribute name="viewName" value="usage_list"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="broadcast_list">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/broadcast_list.jsp"></put-attribute>
+ <put-attribute name="viewName" value="broadcast_list"></put-attribute>
+ </definition>
+ <definition extends="ebz_template" name="broadcast">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/broadcast.jsp"></put-attribute>
+ <put-attribute name="viewName" value="broadcast"></put-attribute>
+ </definition>
+
+
+ <definition extends="ebz_template" name="chart_wizard">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/chart_wizard.jsp"></put-attribute>
+ <put-attribute name="viewName" value="chart_wizard"></put-attribute>
+ </definition>
+
+ <!-- <definition extends="ebz_template_noheader_nofooter" name="collaboration">
+ <put-attribute name="body" value="/WEB-INF/fusion/jsp/webrtc/collaboration.jsp"></put-attribute>
+ </definition> -->
+ <definition name="collaboration"
+ template="/WEB-INF/fusion/jsp/webrtc/collaboration.jsp" />
+ <definition name="user_profile_list"
+ template="/app/fusion/scripts/DS2-view-models/ds2-profile/profile.html" />
+ <definition name="admin"
+ template="/app/fusion/scripts/DS2-view-models/ds2-admin/admin.html" />
+ <definition name="workflows"
+ template="/app/fusion/scripts/view-models/workflows/workflow-landing.html" />
+ <definition name="report_dashboard"
+ template="/app/fusion/scripts/view-models/reportdashboard-page/src/report-dashboard.html" />
+ <definition name="samplePage"
+ template="/app/fusion/scripts/DS2-view-models/ds2-samplePages/samplePage.html" />
+ <definition name="ds2_sample" template="/app/fusionapp/scripts/DS2-view-models/sampleDS2.html" />
+
+
+ <definition extends="ebz_template" name="report_wizard">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/report_wizard.jsp"></put-attribute>
+ <put-attribute name="viewName" value="report_wizard"></put-attribute>
+ </definition>
+ <definition extends="ebz_template" name="wizard_schedule_only">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/wizard_schedule_only.jsp"></put-attribute>
+ <put-attribute name="viewName" value="wizard_schedule_only"></put-attribute>
+ </definition>
+
+ <definition extends="ebz_template" name="report_import">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/report_import.jsp"></put-attribute>
+ <put-attribute name="viewName" value="report_import"></put-attribute>
+ </definition>
+
+
+ <definition extends="ebz_template" name="report">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/report_ebz.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_report_embedded" name="report_embedded">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/report_ebz.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template" name="report_sample">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/report_sample.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="test_run_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/test_run_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="date_start_field_run_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/date_start_field_run_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="date_end_field_run_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/date_end_field_run_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="test_field_run_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/test_field_run_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="default_field_run_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/default_field_run_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="popup_testrun_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/popup_testrun_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="popup_semaphore">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/popup_semaphore.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="popup_import_semaphore">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/popup_import_semaphore.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="popup_table_cols">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/popup_table_cols.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="popup_drill_down_report">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/popup_drill_down_report.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template_noheader_nofooter" name="popup_sql">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/popup_sql.jsp"></put-attribute>
+ </definition>
+ <definition extends="ebz_template" name="error_page">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/raptor/error_page.jsp"></put-attribute>
+ </definition>
+ <definition name="data_out" template="/WEB-INF/fusion/jsp/data_out.jsp" />
+
+ <definition extends="ebz_template" name="frame_insert">
+ <put-attribute name="body"
+ value="/WEB-INF/fusion/jsp/frame_insert.jsp"></put-attribute>
+ </definition>
+
+ <!-- <definition name="test_field_run_sql" template="/WEB-INF/fusion/raptor/test_field_run_sql.jsp"/>
+ <definition name="popup_testrun_sql" template="/WEB-INF/fusion/raptor/popup_testrun_sql.jsp"/> -->
+
+</tiles-definitions>
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/footer.jsp b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/footer.jsp
new file mode 100644
index 00000000..7a2bbc43
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/footer.jsp
@@ -0,0 +1,34 @@
+<script src="./app/fusion/external/angular-1.5/angular.min.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-messages.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-touch.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-sanitize.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-route.min.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-cookies.min.js"></script>
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/b2b-angular/b2b-angular.css"></style>
+<script src="app/fusion/external/ds2/js/b2b-angular/b2b-library.min.js"></script>
+<!-- b2b-column-switch-footer can only found in b2b-library.min.js -->
+
+
+<div style="position: relative; bottom: 0; left: 0; width: 100%">
+ <footer class="b2b-footer-wrapper" role="contentinfo" aria-label="footer">
+ <div class="b2b-footer-container" b2b-column-switch-footer>
+ <div style="margin-top: -25px;" class="divider-bottom-footer">
+ <div style="text-align: center;" class="span12 footerLogo">
+ <div class="span8 copyright-text">
+ <a href="//www.att.com/gen/privacy-policy?pid=2587" target="_blank">&copy; 2017 AT&amp;T Intellectual Property.</a> All rights reserved. AT&T, the AT&T Globe logo and all other AT&T marks contained herein are trademarks of AT&T intellectual property and/or AT&T affiliated companies.
+ </div>
+ <div class="span3" style="margin-left:30px;">
+ <a href="welcome.htm" class="footer-logo">
+ <span class="footer-global">
+ <i class="icon-att-globe" >
+ <span class="hidden-spoken">A T &amp; T</span>
+ </i>
+ </span>
+ <h2 class="logo-title" id="at&amp;t">AT&amp;T</h2>
+ </a>
+ </div>
+ </div>
+ </div>
+ </div>
+ </footer>
+</div> \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/header.jsp b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/header.jsp
new file mode 100644
index 00000000..e3928734
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/header.jsp
@@ -0,0 +1,236 @@
+<script src="./app/fusion/external/angular-1.5/angular.min.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-messages.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-touch.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-sanitize.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-route.min.js"></script>
+<script src="./app/fusion/external/angular-1.5/angular-cookies.min.js"></script>
+<script src="./app/fusion/external/ds2/js/b2b-angular/b2b-library.min.js"></script>
+<script src="./app/fusion/external/ds2/js/digital-ng-library/digital-design-library.js"></script>
+<script src="./app/fusion/scripts/DS2-services/leftMenuServiceDS2.js"></script>
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/b2b-angular/b2b-angular.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/b2b-angular/b2b-angular.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/extras/ds2-accordion.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/extras/ds2-bootstrap-datepicker.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/extras/ds2-cc-input-field.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/extras/ds2-tooltip.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/extras/x-tabs-pills.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-accordion.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-bootstrap-datepicker.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-c2c.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-cc-input-field.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-filmstrip.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-filters.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-legacynav-fix.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-marquee.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-pagination.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-popover.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-progressbar.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ds2-tooltip.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/global.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/digital-design-library.css">
+
+<link rel="stylesheet" type="text/css" href="./app/fusion/external/ds2/css/digital-ng-library/ionicons.css">
+<link rel="stylesheet" type="text/css" href="./app/fusion/styles/ecomp.css">
+<script>
+angular.module('att.abs.helper', []);
+angular.module('quantum', []);
+//angular.module('ui.bootstrap', []);
+var appDS2=angular.module("abs", ["ngRoute", 'ngMessages', 'ngCookies', 'b2b.att.tpls', 'ddh.att.tpls', 'ddh.att.switches', 'b2b.att.footer', 'b2b.att.header']);
+</script>
+
+<script src="./app/fusion/scripts/DS2-services/leftMenuServiceDS2.js"></script>
+
+<script>
+appDS2.controller("leftMenuController", ['$scope', '$filter','$http','$timeout','$cookies','LeftMenuServiceDS2', function ($scope, $filter, $http, $timeout, $cookies, LeftMenuServiceDS2) {
+ $scope.menuData = [];
+ $scope.leftChildData=[];
+ $scope.leftParentData=[];
+ $scope.leftMenuItems = [];
+ $scope.app_name = "";
+ $scope.app_name_full;
+ LeftMenuServiceDS2.getLeftMenu().then(function(response){
+ var j = response;
+ try{
+ if(j && j !== "null" && j!== "undefined"){
+ $scope.leftParentData = JSON.parse(j.data);
+ $scope.leftChildData = JSON.parse(j.data2);
+ }else{
+ throw "Get Left Menu respsone is not an object/is empty";
+ }
+ try{
+ var leftChildItemList = $scope.leftChildData;
+ var pageUrl = window.location.href.split('/')[window.location.href.split('/').length-1];
+ var leftParentList =$scope.leftParentData;
+
+ for (var i = 0; i < leftParentList.length; i++) {
+ var parentItem = {};
+ parentItem.name = leftParentList[i].label;
+ if(parentItem.name == 'Home'){
+ parentItem.imageSrc = /*"icon-location-pinpoint"*/ "icon-building-home";
+ } else if(parentItem.name == 'Sample Pages'){
+ parentItem.imageSrc = "icon-documents-book";
+ } else if(parentItem.name == 'Reports'){
+ parentItem.imageSrc = "icon-misc-piechart";
+ } else if(parentItem.name == 'Profile'){
+ parentItem.imageSrc = "icon-people-oneperson";
+ } else if(parentItem.name == 'Admin'){
+ parentItem.imageSrc = "icon-content-star";
+ } else if(parentItem.name == 'Sample Pages'){
+ parentItem.imageSrc = "icon-content-searchchannels";
+ } else {
+ parentItem.imageSrc = "icon-building-door";
+ }
+ parentItem.menuItems = [];
+ for (var j = 0; j < leftChildItemList[i].length; j++) {
+ if(leftChildItemList[i][j].label != null && leftChildItemList[i][j].label.length > 0) {
+ var childItem = {};
+ childItem.name = leftChildItemList[i][j].label;
+ childItem.href = leftChildItemList[i][j].action;
+ parentItem.menuItems.push(childItem)
+ }
+ }
+ $scope.menuData.push(parentItem);
+ }
+
+
+ //For Home, add href
+ $scope.menuData[0].href = leftParentList[0].action;
+
+ for (var i = 0; i < leftParentList.length; i++) {
+ $scope.item = {
+ parentLabel : leftParentList[i].label,
+ parentAction : leftParentList[i].action,
+ parentImageSrc : leftParentList[i].imageSrc,
+ open:pageUrl==leftParentList[i].action?true:false,
+ childItemList : leftChildItemList[i]
+ };
+ };
+ }catch(err){
+ console.log("error happened while trying to set left menu structure"+err);
+ }
+ }catch (e) {
+ console.log("error happened while trying to get left menu items"+e);
+ reloadPageOnce();
+ return;
+ }
+},function(error){
+ console.log("error happened while calling getLeftMenu"+error);
+});
+
+LeftMenuServiceDS2.getAppName().then(function(response){
+ var j = response;
+ try{
+ if(j && j !== "null" && j!== "undefined"){
+ console.log("app name is " + $scope.app_name);
+ $scope.app_name_full = j.data;
+ var processed_app_name = j.data;
+ var n = processed_app_name.length;
+ if (n > 15) {
+ n = 15;
+ }
+ $scope.app_name = processed_app_name.substr(0, n);
+ }else{
+ throw "Get app_name respsone is not an object/is empty";
+ }
+ }catch (e) {
+ console.log("error happened while trying to get app name "+e);
+ return;
+ }
+},function(error){
+ console.log("error happened while calling getAppName "+error);
+});
+
+$scope.adjustHeader=function() {
+ $scope.showHeader = ($cookies.show_app_header == undefined ? true : $cookies.show_app_header);
+
+ if($scope.showHeader == true) {
+ $scope.drawer_margin_top = 50;
+ $scope.drawer_custom_top = 54;
+ $scope.toggle_drawer_top = 55;
+ }
+ else {
+
+ $scope.drawer_margin_ top = 40;
+ $scope.drawer_custom_top = 0;
+ $scope.toggle_drawer_top = 10;
+ }
+
+
+};
+
+$scope.adjustHLeftMenu = function (type){
+ $scope.showHeader = ($cookies.show_app_header == undefined ? true : $cookies.show_app_header);
+
+ if($scope.showHeader == true) {
+ $scope.drawer_margin_top = 60;
+ $scope.drawer_custom_top = 54;
+ $scope.toggle_drawer_top = 55;
+ }
+ else {
+
+ $scope.drawer_margin_top = 50;
+ $scope.drawer_custom_top = 0;
+ $scope.toggle_drawer_top = 10;
+ }
+ if(type=='burgerIcon'){
+ return { "top": $scope.toggle_drawer_top+"px"};
+ }else if(type=='leftMenu'){
+ return { "margin-top": $scope.drawer_margin_top+"px"};
+ }else
+ return;
+}
+$scope.adjustHeader();
+$scope.drawerOpen = true;
+
+$scope.toggleDrawer = function() {
+ $scope.drawerOpen = !($scope.drawerOpen);
+ if ($scope.drawerOpen) {
+ // setCookie('drawerOpen','open',30);
+ $scope.arrowShow = true;
+
+
+ if (document.getElementById('fnMenueContent')!=null)
+ document.getElementById('fnMenueContent').style.marginLeft = "0px";
+
+ if (document.getElementById('rightContentAdmin')!=null)
+ document.getElementById('rightContentAdmin').style.marginLeft = "210px";
+
+ else if (document.getElementById('rightContentProfile')!=null)
+ document.getElementById('rightContentProfile').style.marginLeft = "210px";
+ } else {
+
+ $scope.arrowShow = false;
+
+ if (document.getElementById('fnMenueContent')!=null)
+ document.getElementById('fnMenueContent').style.marginLeft = "-150px";
+
+ if (document.getElementById('rightContentAdmin')!=null) {
+ document.getElementById('rightContentAdmin').style.marginLeft = "50px";
+ }
+
+ else if (document.getElementById('rightContentProfile')!=null)
+ document.getElementById('rightContentProfile').style.marginLeft = "50px";
+ }
+ };
+
+$timeout(function() {
+ //detectScrollEvent();
+ }, 800);
+}]);
+</script>
+
+<style>
+#page-content{
+margin-top:-250px;
+}
+
+#page-content td, th {
+ padding: 0px;
+ border:none;
+}
+</style>
+<div ng-app="abs">
+ <div ng-controller = "leftMenuController">
+ <ddh-left-navigation menu-data="menuData"></ddh-left-navigation>
+ </div>
+</div> \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/left-menu.jsp b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/left-menu.jsp
new file mode 100644
index 00000000..445aa080
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ds2/left-menu.jsp
@@ -0,0 +1,804 @@
+<%--
+ ================================================================================
+ eCOMP Portal SDK
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property
+ ================================================================================
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ================================================================================
+ --%>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
+<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
+<%@ page isELIgnored="false"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%@ page import="org.openecomp.portalsdk.core.onboarding.util.PortalApiProperties"%>
+<%@ page import="org.openecomp.portalsdk.core.onboarding.util.PortalApiConstants"%>
+<%@ page import="org.openecomp.portalsdk.core.domain.MenuData"%>
+<link rel="stylesheet" type="text/css" href="app/fusion/external/ebz/ebz_header/header.css">
+<link rel="stylesheet" type="text/css" href="app/fusion/external/ebz/ebz_header/portal_ebz_header.css">
+<link rel="stylesheet" type="text/css" href="app/fusion/external/ebz/sandbox/styles/style.css" >
+
+
+<!-- <script src= "app/fusion/external/ebz/angular_js/angular.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/angular-route.min.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/angular-sanitize.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/angular-cookies.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/app.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/gestures.js"></script>
+<script src="static/js/jquery-1.10.2.js"></script>
+<script src="app/fusion/scripts/modalService.js"></script>
+<script src="static/js/jquery.mask.min.js" type="text/javascript"></script>
+<script src="static/js/jquery-ui.js" type="text/javascript"></script>
+<script src="app/fusion/external/ebz/sandbox/att-abs-tpls.js" type="text/javascript"></script>
+<script src="static/fusion/js/att_angular_gridster/ui-gridster-tpls.js"></script>
+<script src="static/fusion/js/att_angular_gridster/angular-gridster.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/checklist-model.js"></script>
+<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/lodash.js/0.10.0/lodash.min.js"></script>
+<script src="app/fusion/external/angular-ui/ui-bootstrap-tpls-1.1.2.min.js"></script>
+<script src="app/fusion/scripts/services/userInfoService.js"></script>
+<script src="app/fusion/scripts/services/leftMenuService.js"></script> -->
+
+
+<jsp:include page="/WEB-INF/fusion/jsp/ebz/loginSnippet.html" ></jsp:include>
+
+
+<c:set var="UserName" value="<%= session.getAttribute(\"fullName\")%>" />
+<c:set var="UserFirstName" value="<%= session.getAttribute(\"first_name\")%>" />
+
+<%
+ String contactUsLink = SystemProperties.getProperty(SystemProperties.CONTACT_US_LINK);
+ String redirectUrl = PortalApiProperties.getProperty(PortalApiConstants.ECOMP_REDIRECT_URL);
+ String portalUrl = redirectUrl.substring(0, redirectUrl.lastIndexOf('/')) + "/process_csp";
+ String getAccessLink = redirectUrl.substring(0, redirectUrl.lastIndexOf('/')) + "/get_access";
+%>
+<c:set var="returnPortalUrl" value="<%=portalUrl%>" />
+<c:set var="contactUsLink" value="<%=contactUsLink%>" />
+<c:set var="getAccessLink" value="<%=getAccessLink%>" />
+
+<style>
+</style>
+
+<%@include file="/WEB-INF/fusion/jsp/ebz/loginSnippet.html" %>
+
+<div style="position: relative; z-index: 999;">
+ <div ng-controller="headerController">
+
+ <div class="headerContainer" id="headerContainer" ng-cloak ng-show="{{showHeader}}">
+ <div id="megaMenuContainer" class="megaMenuContainer" style="margin-top: 0; overflow: visible;">
+ <div>
+ <!--for mega Menu-->
+ <!-- Mega Menu parent-tab directive with three models menu-items, active-sub-menu, active-menu -->
+ <div id="topMenu" class="top-megamenu" ng-mouseleave="activeClickSubMenu.x.active=false; activeClickMenu.x.active=false">
+ <div style="float:left;width:100%;"parent-tab menu-items="megaMenuDataObject" active-sub-menu='activeClickSubMenu.x' active-menu='activeClickMenu.x'>
+ <div parentmenu-tabs mega-menu="true" menu-items="megaMenuDataObject" style="height:55px;">
+ <div style="float:left">
+ <li class="megamenu__item" style="line-height:55px;" onclick="returnToPortal()">
+ <img src="app/fusion/external/ebz/images/att_logo.png" class="ATTLogo" ></span>
+<!-- <a id='returnPortal' class="primaryMenuOptionLink" style="font-weight: 400 !important; font-family: clearview_att_bold !important; font-size: 18px;">ECOMP</a>
+ --> <strong style="font-weight: 400 !important; font-family: clearview_att_bold !important; font-size: 18px;" id='returnPortal' >ECOMP Portal</strong>
+ </li>
+ <div menu-tabs mega-menu="true" tab-name="item.text" menu-item="item" active-menu="activeClickMenu.x"
+ ng-repeat="item in megaMenuDataObject" style="font-size: 18px;" ng-mousedown="loadFavorites()" >
+ <div parentmenu-tabs sub-menu="true" ng-show="activeClickMenu.x.active && item.active" menu-items="activeClickMenu.x.children">
+ <!-- Second level menu -->
+ <div>
+ <div menu-tabs sub-menu="true" tab-name="subItem.text"
+ tab-url="subItem.url" menu-item="subItem"
+ ng-repeat="subItem in activeClickMenu.x.children | orderBy : 'column'" active-menu="activeClickSubMenu.x"
+ sub-item-active="{{subItem.active}}" style="float:left;" aria-label="{{subItem.text}}"
+ ng-mouseenter="submenuLevelAction(subItem.text,subItem.column)"
+ ng-mouseleave="submenuLevelAction(subItem.text,subItem.column)"
+ ng-click="submenuLevelAction(subItem.text,subItem.column)" >
+ <i ng-if="subItem.text=='Favorites'" id="favorite-star"
+ class="icon-star favorites-icon-active">
+ </i>
+ </div>
+
+ <div class="sub__menu" ng-mouseleave="activeClickSubMenu.x.active=false" >
+ <ul ng-show="activeClickSubMenu.x.active" role="menubar" class="columns">
+ <!-- Third level menu -->
+ <div menu-tabs menu-item="subItem"
+ class="columns-div"
+ ng-repeat="subItem in activeClickSubMenu.x.children | orderBy : 'column'"
+ ng-show="activeClickSubMenu.x.active">
+
+ <i id="favorite-selector-third-level"
+ ng-show="isUrlFavorite(subItem.menuId)==false"
+ class="icon-star favorites-icon-inactive"
+ ng-if="subItem.url.length > 1">
+ </i>
+ <i id="favorite-selector-third-level"
+ ng-show="isUrlFavorite(subItem.menuId)"
+ class="icon-star favorites-icon-active"
+ ng-if="subItem.url.length > 1">
+ </i>
+ <span class="title" aria-label="{{subItem.text}}"
+ ng-click="goToUrl(subItem)">{{subItem.text}}</span>
+ <!-- Fourth level menus -->
+ <div att-links-list="">
+ <i id="favorite-selector-fourth-level"
+ class="icon-star favorites-icon-inactive"
+ ng-show="isUrlFavorite(tabValue.menuId)==false"
+ ng-if="tabValue.url.length > 1">
+
+ </i>
+ <i id="favorite-selector-fourth-level"
+ class="icon-star favorites-icon-active"
+ ng-show="isUrlFavorite(tabValue.menuId)"
+ ng-if="tabValue.url.length > 1">
+
+ </i>
+ <span role="menuitem" att-links-list-item=""
+ ng-repeat="tabValue in subItem.children"
+ ng-click="goToUrl(tabValue)"
+ att-accessibility-click="13,32"
+ ng-class="{'disabled': tabValue.disabled}">{{tabValue.text}}</span>
+ </div>
+ <hr ng-show="!$last"/>
+
+ </div>
+ </ul>
+ <!-- Favorites level menu -->
+ <div class="favorites-window" ng-show='favoritesWindow' ng-mouseleave="hideFavoritesWindow()">
+ <div id="favorites-menu-items" ng-show="showFavorites">
+ <div ng-repeat="subItem in favoritesMenuItems" att-links-list="" style='display: inline'>
+ <i id="favorite-selector-favorites-list" class="icon-star favorites-icon-active">
+ </i>
+ <a id="favorites-list" aria-label="{{subItem.text}}"
+ ng-click="goToUrl(subItem)"
+ style="margin-left: 3px; margin-right: 20px; text-decoration: none; color: #666666;">
+ {{subItem.text}}
+ </a>
+ </div>
+ <div>
+ <br>
+ <p style='font-weight: 400; font-family: clearview_att_bold !important;
+ font-size: 18px; text-align: center; background-color: lightgray;
+ width: 400px; margin-left: 25%; margin-right: 25%;'>
+ Manage favorites on ECOMP Portal.
+ </p>
+ </div>
+ </div>
+ <!-- Favorites when empty -->
+ <div id="favorites-empty" ng-show='favoritesWindow' ng-show="emptyFavorites">
+ <div id="favorites-empty" ng-show="emptyFavorites" class="favorites-window-empty">
+ <div>
+ <img src="app/fusion/external/ebz/images/no_favorites_star.png">
+ <p class='favoritesLargeText'>No Favorites</p>
+ <p class='favoritesNormalText'>Manage favorites on ECOMP Portal.</p>
+ </div>
+ </div>
+ </div>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ </div >
+ <li class="megamenu__item" style="line-height:55px;" ng-if="loadMenufail">
+ <strong style="font-weight: 400 !important; font-family: clearview_att_bold !important; font-size: 18px;" >Unable to load menus</strong>
+ </li>
+<!-- <li class="megamenu__item" style="width: 20%;">&nbsp;</li>
+ --> </div>
+ <!-- Login Snippet-->
+ <div style="float:right">
+ <li id="bcLoginSnippet" class="megamenu__item" style="width: 140px;" >
+ <div popover="loginSnippet.html" aria-label="Login Snippet" referby="loginSnippet" att-accessibility-click="13,32" popover-style="\" popover-placement="below" style="width: 200px;">
+ <div class="icon-user-small login-snippet-icon"></div>
+ <div class="login-snippet-text" style="display: inline-block; font-size:12px; margin-left:5px;overflow: hidden; max-height: 31px; max-width:120px; padding-top: 0px; margin-top: 0px; white-space: nowrap;" ng-bind="userProfile.firstName"></div>
+ </div>
+ </li>
+ <li class="megamenu__item" style="width:120px;">&nbsp;</li>
+ </div>
+
+ </div>
+ </div>
+ <div style="clear: both"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="license-notification" id="license-notification">
+ <a href="javascript:void(0)" style="background-color:#bbb;" class="button button--small" tooltip="Please contact ECOMP Portal team to get the license" tooltip-placement="below" tooltip-style="light" tooltip-popup-delay="500" >
+ <span style="">{{app_name_full}}</span>
+ </a>
+ </div>
+ <div style="position: relative; color: black; top: 70px;">
+ <div ng-cloak>
+ <span ng-style="adjustHLeftMenu('burgerIcon')" style="z-index:998; position:fixed; left:0%; font-size:35px; margin-left:10px;text-decoration:none;">
+ <a ng-click="toggleDrawer();isOpen = !isOpen" href="javascript:void(0);" class="arrow-icon-left" >
+ <span class="icon-hamburger"></span></a>
+ <span ng-init="isOpen = true" ng-show="isOpen" style="font-size:16px; position:relative; top:-8px; left:-15px;">&nbsp&nbsp&nbsp {{app_name}}</span>
+ </span>
+ <div att-drawer drawer-slide="left" drawer-custom-top="{{drawer_custom_top}}px" drawer-size="200px" drawer-open="drawerOpen" drawer-custom-height="100%" >
+ <div ng-style="adjustHLeftMenu('leftMenu')">
+ <div class="attDrawer" style="margin-top:{{drawer_margin_top}}px;">
+ <div style="margin-left:10px; margin-right:10px;">
+ <accordion close-others="true" css="att-accordion--no-box">
+ <accordion-group ng-repeat="parent in menuItems" heading="{{parent.parentLabel}}" child="{{parent.parentAction}}" parent-link="{{parent.parentAction}}" image-source="{{parent.parentImageSrc}}" child-length="{{parent.childItemList.length}}" is-open="parent.open">
+ <div ng-repeat="subMenu in parent.childItemList" style="font-size:12px; margin-left:10px;">
+ <a href="{{subMenu.action}}" style="font-size:12px; color:#666666;" >{{subMenu.label}}</a>
+ </div>
+ </accordion-group>
+ </accordion>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+
+<script>
+ function returnToPortal(){
+ window.location.href = "<c:out value='${returnPortalUrl}'/>";
+ }
+ detectScrollEvent = function() {
+ var footerOff = $('#footerContainer').offset().top;
+ var headOff = $('#headerContainer').offset().top;
+ var winHeight = $(window).height();
+ if ((footerOff - headOff) <= winHeight) {
+ $('.att-drawer').css({
+ "height" : footerOff - headOff - 55
+ });
+ } else {
+ $('.att-drawer').css({
+ "height" : "94vh"
+ });
+ }
+ }
+ $(window).scroll(function() {
+ if ($('.att-drawer').is(':visible')) {
+ detectScrollEvent();
+ }
+ });
+ app.controller("headerController", function($scope, $timeout, $log, $http, UserInfoService, $window, $cookies,LeftMenuService) {
+ // $log.debug('HeaderController started');
+ $scope.jsonMenuData = [];
+ $scope.loadMenufail=false;
+ $scope.app_name = "";
+ $scope.app_name_full = "";
+ $scope.megaMenuDataObject =[];
+ $scope.activeClickSubMenu = {
+ x: ''
+ };
+ $scope.activeClickMenu = {
+ x: ''
+ };
+ $scope.favoritesMenuItems = [];
+ $scope.favoriteItemsCount = 0;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ $scope.favoritesWindow = false;
+ $scope.userProfile={
+ firstName:'',
+ lastName:'',
+ fullName:'',
+ email:''
+ }
+ /*Put user info into fields*/
+ $scope.inputUserInfo = function(userInfo){
+ if (typeof(userInfo) != "undefined" && userInfo!=null && userInfo!=''){
+ if (typeof(userInfo.USER_FIRST_NAME) != "undefined" && userInfo.USER_FIRST_NAME!=null && userInfo.USER_FIRST_NAME!='')
+ $scope.userProfile.firstName = userInfo.USER_FIRST_NAME;
+ if (typeof(userInfo.USER_LAST_NAME) != "undefined" && userInfo.USER_LAST_NAME!=null && userInfo.USER_LAST_NAME!='')
+ $scope.userProfile.lastName = userInfo.USER_LAST_NAME;
+ if (typeof(userInfo.USER_EMAIL) != "undefined" && userInfo.USER_EMAIL!=null && userInfo.USER_EMAIL!='')
+ $scope.userProfile.email = userInfo.USER_EMAIL;
+ }
+ }
+ /*getting user info from session*/
+ $scope.getUserNameFromSession = function(){
+ UserInfoService.getFunctionalMenuStaticDetailSession()
+ .then(function (res) {
+ $scope.userProfile.firstName = res.firstName;
+ $scope.redirectUrl = res.portalUrl;
+ });
+ }
+ $scope.getTopMenuStaticInfo=function() {
+ var promise = UserInfoService.getFunctionalMenuStaticDetailShareContext();
+ promise.then(
+ function(res) {
+ if(res==null || res==''){
+ $log.info('failed getting static User information');
+ $scope.getUserNameFromSession();
+ }else{
+ $log.info('Received static User information');
+ var resData = res;
+ $scope.inputUserInfo(resData);
+ $scope.userProfile.fullName = $scope.userProfile.firstName+ ' '+ $scope.userProfile.lastName;
+ }
+ },
+ function(err) {
+ $log.info('failed getting static User information');
+ }
+ );
+ }
+
+ var unflatten = function( array, parent, tree ){
+ tree = typeof tree !== 'undefined' ? tree : [];
+ parent = typeof parent !== 'undefined' ? parent : { menuId: null };
+ var children = _.filter( array, function(child){ return child.parentMenuId == parent.menuId; });
+
+ if( !_.isEmpty( children ) ){
+ if( parent.menuId === null ){
+ tree = children;
+ }else{
+ parent['children'] = children
+ }
+ _.each( children, function( child ){ unflatten( array, child ) } );
+ }
+
+ return tree;
+ }
+
+ var menuStructureConvert = function(menuItems) {
+ var megaMenuDataObjectTemp = [
+ {
+ text: "ECOMP",
+ children:menuItems
+ },
+ {
+ text: "Help",
+ children: [{
+ text:"Contact Us",
+ url:"<c:out value='${contactUsLink}'/>"
+ },
+ {
+ text:"Get Access",
+ url:"<c:out value='${getAccessLink}'/>"
+ }]
+ }
+ ];
+ return megaMenuDataObjectTemp;
+ };
+
+
+ /*Left Menu*/
+ LeftMenuService.getAppName().then(function(response){
+ var j = response;
+ try{
+ if(j && j !== "null" && j!== "undefined"){
+ // console.log("app name is " + $scope.app_name);
+ $scope.app_name_full = j.data;
+ var processed_app_name = j.data;
+ if(processed_app_name.indexOf("[")<=-1) {
+ if (document.getElementById('license-notification')!=null)
+ document.getElementById('license-notification').style.display = "none";
+ }
+ var n = processed_app_name.length;
+ if (n > 15) {
+ n = 15;
+ }
+ $scope.app_name = processed_app_name.substr(0, n);
+ }else{
+ throw "Get app_name response is not an object/is empty";
+ }
+ }catch (e) {
+ console.log("error happened while trying to get app name "+e);
+ return;
+ }
+ },function(error){
+ console.log('getAppName failed', error);
+ });
+
+ $scope.getTopMenuStaticInfo();
+ $scope.getMenu=function() {
+
+ $http({
+ method: "GET",
+ url: 'get_functional_menu',
+// TIMEOUT USED FOR LOCAL TESTING ONLY
+// timeout: 100
+ }).success(function (response) {
+ if(response == '101: Timeout') {
+ $log.error('Timeout attempting to get_functional_menu');
+ // TIMEOUT USED FOR LOCAL TESTING ONLY
+// $scope.createErrorMenu();
+ $scope.megaMenuDataObject = menuStructureConvert('');
+ }else {
+ $log.debug('get_functional_menu success: ' + response);
+ if(typeof response != 'undefined' && response.length!=0 && typeof response[0] != 'undefined' && typeof response[0].error!="undefined"){
+// createErrorMenu() USED FOR LOCAL TESTING ONLY
+// $scope.createErrorMenu();
+ $scope.megaMenuDataObject = menuStructureConvert('');
+ // $scope.loadMenufail=true;
+ }else{
+ $scope.jsonMenuData = unflatten( response );
+ $scope.megaMenuDataObject = menuStructureConvert($scope.jsonMenuData);
+ }
+ }
+ }).error(function (response){
+// createErrorMenu() USED FOR LOCAL TESTING ONLY
+// $scope.createErrorMenu();
+
+ //$scope.loadMenufail=true;
+ $scope.megaMenuDataObject = menuStructureConvert('');
+ $log.debug('REST API failed get_functional_menu...'+ response);
+ });
+ }
+ $scope.adjustHLeftMenu = function (type){
+ $scope.showHeader = ($cookies.show_app_header == undefined ? true : $cookies.show_app_header);
+
+ if($scope.showHeader == true) {
+ $scope.drawer_margin_top = 60;
+ $scope.drawer_custom_top = 54;
+ $scope.toggle_drawer_top = 55;
+ }
+ else {
+
+ $scope.drawer_margin_top = 50;
+ $scope.drawer_custom_top = 0;
+ $scope.toggle_drawer_top = 10;
+ }
+ if(type=='burgerIcon'){
+ return { "top": $scope.toggle_drawer_top+"px"};
+ }else if(type=='leftMenu'){
+ return { "margin-top": $scope.drawer_margin_top+"px"};
+ }else
+ return;
+ }
+ $scope.adjustHeader=function() {
+ $scope.showHeader = ($cookies.show_app_header == undefined ? true : $cookies.show_app_header);
+
+ if($scope.showHeader == true) {
+ $scope.drawer_margin_top = 50;
+ $scope.drawer_custom_top = 54;
+ $scope.toggle_drawer_top = 55;
+ }
+ else {
+
+ $scope.drawer_margin_top = 40;
+ $scope.drawer_custom_top = 0;
+ $scope.toggle_drawer_top = 10;
+ }
+
+
+ }
+
+
+ //$scope.getMenu();
+ $scope.adjustHeader();
+
+
+ /* **************************************************************************/
+ /* Logic for the favorite menus is here */
+
+ $scope.loadFavorites = function () {
+ $log.debug('loadFavorites has happened.');
+ if ($scope.favoritesMenuItems == '') {
+ $scope.generateFavoriteItems();
+ $log.debug('loadFavorites is calling generateFavoriteItems()');
+ } else {
+ $log.debug('loadFavorites is NOT calling generateFavoriteItems()');
+ }
+ }
+
+ $scope.goToUrl = function (item) {
+ $log.info("goToUrl called")
+ $log.info(item);
+
+ var url = item.url;
+ var restrictedApp = item.restrictedApp;
+ $log.debug('Restricted app status is: ' + restrictedApp);
+ if (!url) {
+ $log.info('No url found for this application, doing nothing..');
+ return;
+ }
+ if (restrictedApp) {
+ $window.open(url, '_blank');
+ } else {
+ $window.open(url, '_self');
+ }
+
+ }
+
+ $scope.submenuLevelAction = function(index, column) {
+ if ($scope.favoritesMenuItems == '') {
+ $scope.generateFavoriteItems();
+ $log.debug('submenuLevelAction is calling generateFavoriteItems()');
+ }
+ $log.debug('item hovered/clicked: ' + index + '; column = ' + column);
+ if (column == 2) { // 2 is Design
+ $scope.favoritesWindow = false;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ }
+ if (index=='Favorites' && $scope.favoriteItemsCount != 0) {
+ $log.debug('Showing Favorites window');
+ $scope.favoritesWindow = true;
+ $scope.showFavorites = true;
+ $scope.emptyFavorites = false;
+ }
+ if (index=='Favorites' && $scope.favoriteItemsCount == 0) {
+ $log.debug('Hiding Favorites window in favor of No Favorites Window');
+ $scope.favoritesWindow = true;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = true;
+ }
+ if (column > 2) {
+ $scope.favoritesWindow = false;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ }
+ };
+
+ $scope.hideFavoritesWindow = function() {
+ $log.debug('$scope.hideFavoritesWindow has been called');
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ }
+
+ $scope.isUrlFavorite = function (menuId) {
+// $log.debug('array objects in menu favorites = ' + $scope.favoriteItemsCount + '; menuId=' + menuId);
+ var jsonMenu = JSON.stringify($scope.favoritesMenuItems);
+ var isMenuFavorite = jsonMenu.indexOf('menuId\":' + menuId);
+ if (isMenuFavorite==-1) {
+ return false;
+ } else {
+ return true;
+ }
+
+ }
+
+ $scope.generateFavoriteItems = function() {
+ $http({
+ method: "GET",
+ url: 'get_favorites',
+ // TIMEOUT USED FOR LOCAL TESTING ONLY
+// timeout: 100
+ }).success(function (response) {
+ if (response == '101: Timeout') {
+ $log.error('Timeout attempting to get_favorites_menu');
+ } else {
+ if(typeof response != 'undefined' && response.length!=0 && typeof response[0] != 'undefined' && typeof response[0].error!="undefined"){
+ $log.error('REST API failed get_favorites' + response);
+ }else{
+ $log.debug('get_favorites = ' + JSON.stringify(response));
+ $scope.favoritesMenuItems = response;
+ $scope.favoriteItemsCount = Object.keys($scope.favoritesMenuItems).length;
+ $log.info('number of favorite menus: ' + $scope.favoriteItemsCount);
+ }
+ }
+ }).error(function (response){
+ $log.error('REST API failed get_favorites' + response);
+ //createFavoriteErrorMenu() USED FOR LOCAL TESTING ONLY
+// $scope.createFavoriteErrorMenu();
+ });
+ }
+
+ $scope.createFavoriteErrorMenu=function() {
+ $scope.favoritesMenuItems = [
+// {
+// "menuId": "93",
+// "text": "JSONLint",
+// "url": "http://http://jsonlint.com"
+// },
+// {
+// "menuId": "22",
+// "text": "ECOMP Wasteland",
+// "url": "https://ecomp.homer.att.com/ecompportal/applicationsHome"
+// },
+// {
+// "menuId": "94",
+// "text": "HROneStop",
+// "url": "http://ebiz.sbc.com/hronestop"
+// },
+// {
+// "menuId": "91",
+// "text": "Andy and his Astrophotgraphy",
+// "url": "https://ecomp.homer.att.com/ecompportal/applicationsHome"
+// }
+ ];
+ $scope.favoriteItemsCount = Object.keys($scope.favoritesMenuItems).length;
+ $log.info('number of favorite menus: ' + $scope.favoriteItemsCount);
+ }
+
+ /* end of Favorite Menu code */
+ /* **************************************************************************/
+
+
+ /* **************************************************************************/
+ // THIS IS USED FOR LOCAL TESTING ONLY
+ /* **************************************************************************/
+
+ $scope.createErrorMenu=function() {
+ $scope.jsonMenuData = [
+ {
+ "menuId": 1,
+ "column": 2,
+ "text": "Design",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 2,
+ "column": 3,
+ "text": "Infrastructure Ordering",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 3,
+ "column": 4,
+ "text": "Service Creation",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 4,
+ "column": 5,
+ "text": "Service Mgmt",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 90,
+ "column": 1,
+ "text": "Google",
+ "parentMenuId": 1,
+ "url": "http://google.com"
+ },
+ {
+ "menuId": 91,
+ "column": 1,
+ "text": "Mike Little's Coffee Cup",
+ "parentMenuId": 2,
+ "url": "http://coffee.com"
+ },
+ {
+ "menuId": 92,
+ "column": 2,
+ "text": "Andy and his Astrophotgraphy",
+ "parentMenuId": 3,
+ "url": "http://nightskypix.com"
+ },
+ {
+ "menuId": 93,
+ "column": 1,
+ "text": "JSONLint",
+ "parentMenuId": 4,
+ "url": "http://http://jsonlint.com"
+ },
+ {
+ "menuId": 94,
+ "column": 2,
+ "text": "HROneStop",
+ "parentMenuId": 4,
+ "url": "http://ebiz.sbc.com/hronestop"
+ },
+ {
+ "menuId": 95,
+ "column": 2,
+ "text": "4th Level App4a R16",
+ "parentMenuId": 4,
+ "url": "http://www.e-access.att.com/ecomp_portal_ist/ecompportal/widgets"
+ },
+ {
+ "menuId": 96,
+ "column": 3,
+ "text": "3rd Level App1c R200",
+ "parentMenuId": 4,
+ "url": "http://app1c.com"
+ },
+ {
+ "menuId": 97,
+ "column": 1,
+ "text": "3rd Level App4b R16",
+ "parentMenuId": 5,
+ "url": "http://app4b.com"
+ },
+ {
+ "menuId": 98,
+ "column": 2,
+ "text": "3rd Level App2b R16",
+ "parentMenuId": 5,
+ "url": "http://app2b.com"
+ },
+ {
+ "menuId": 99,
+ "column": 1,
+ "text": "Favorites",
+ "parentMenuId": null,
+ "url": ""
+ }
+ ];
+ $scope.jsonMenuData = unflatten( $scope.jsonMenuData );
+ $scope.megaMenuDataObject = menuStructureConvert($scope.jsonMenuData);
+// $log.debug(JSON.stringify($scope.jsonMenuData));
+ }
+ var childItemList="";
+ var parentList = "";
+ try{
+ childItemList = ${menu.childItemList};
+ parentList = ${menu.parentList};
+ }catch(err){
+ console.log("ebz_header: failed to get child/parent lists", err);
+ }
+
+ var pageUrl = window.location.href.split('/')[window.location.href.split('/').length-1];
+
+ $scope.menuItems = [];
+ for (var i = 0; i < parentList.length; i++) {
+ $scope.openCurrentMenu = false;
+ if(pageUrl==parentList[i].action)
+ $scope.openCurrentMenu = true;
+ $scope.childItemList = childItemList[i];
+ for(chIndex in $scope.childItemList){
+ if($scope.childItemList.length>0)
+ if($scope.childItemList[chIndex].action!=null){
+ if($scope.childItemList[chIndex].action==pageUrl)
+ $scope.openCurrentMenu = true;
+ }
+ }
+ $scope.item = {
+ parentLabel : parentList[i].label,
+ parentAction : parentList[i].action,
+ parentImageSrc : parentList[i].imageSrc,
+ open:$scope.openCurrentMenu,
+ childItemList : $scope.childItemList
+ }
+ $scope.menuItems.push($scope.item);
+ }
+ $scope.arrowShow = true;
+ $scope.drawerOpen = false;
+ $scope.subMenuContent = false;
+ $scope.toggleSubMenu = function() {
+ $scope.subMenuContent = !$scope.subMenuContent;
+ };
+
+ var drawerOpen = 'open';
+ if (drawerOpen == 'open') {
+ $scope.drawerOpen = true;
+ $scope.arrowShow = true;
+ } else {
+ $scope.arrowShow = false;
+ }
+ $scope.arrowShow = true;
+ $scope.drawerOpen = false;
+ $scope.toggleDrawer = function() {
+ $scope.drawerOpen = !($scope.drawerOpen);
+ if ($scope.drawerOpen) {
+ $scope.arrowShow = true;
+ if (document.getElementById('mContent')!=null)
+ document.getElementById('mContent').style.marginLeft = "0px";
+ } else {
+ $scope.arrowShow = false;
+ if (document.getElementById('mContent')!=null)
+ document.getElementById('mContent').style.marginLeft = "-150px";
+ }
+ };
+ //var drawerOpen = getCookie('drawerOpen');
+ if (drawerOpen == 'open') {
+ $scope.drawerOpen = true;
+ $scope.arrowShow = true;
+ } else {
+ $scope.arrowShow = false;
+ }
+ $timeout(function() {
+ detectScrollEvent();
+ }, 800);
+
+ });
+
+ app.filter("ellipsis", function(){
+ return function(text, length){
+ if (text) {
+ var ellipsis = text.length > length ? "..." : "";
+ return text.slice(0, length) + ellipsis;
+ };
+ return text;
+ }
+ });
+</script> \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ebz/ebz_header.jsp b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ebz/ebz_header.jsp
new file mode 100644
index 00000000..4a5cce4b
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/jsp/ebz/ebz_header.jsp
@@ -0,0 +1,833 @@
+<%--
+ ================================================================================
+ eCOMP Portal SDK
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property
+ ================================================================================
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ================================================================================
+ --%>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
+<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
+<%@ page isELIgnored="false"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%@ page import="org.openecomp.portalsdk.core.onboarding.util.PortalApiProperties"%>
+<%@ page import="org.openecomp.portalsdk.core.onboarding.util.PortalApiConstants"%>
+<%@ page import="org.openecomp.portalsdk.core.domain.MenuData"%>
+<link rel="stylesheet" type="text/css" href="app/fusion/external/ebz/ebz_header/header.css">
+<link rel="stylesheet" type="text/css" href="app/fusion/external/ebz/ebz_header/portal_ebz_header.css">
+<link rel="stylesheet" type="text/css" href="app/fusion/external/ebz/sandbox/styles/style.css" >
+
+
+<script src= "app/fusion/external/ebz/angular_js/angular.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/angular-route.min.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/angular-sanitize.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/angular-cookies.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/app.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/gestures.js"></script>
+<script src="static/js/jquery-1.10.2.js"></script>
+<script src="app/fusion/scripts/modalService.js"></script>
+<script src="static/js/jquery.mask.min.js" type="text/javascript"></script>
+<script src="static/js/jquery-ui.js" type="text/javascript"></script>
+<script src="app/fusion/external/ebz/sandbox/att-abs-tpls.js" type="text/javascript"></script>
+<script src="static/fusion/js/att_angular_gridster/ui-gridster-tpls.js"></script>
+<script src="static/fusion/js/att_angular_gridster/angular-gridster.js"></script>
+<script src= "app/fusion/external/ebz/angular_js/checklist-model.js"></script>
+<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/lodash.js/0.10.0/lodash.min.js"></script>
+<script src="app/fusion/external/angular-ui/ui-bootstrap-tpls-1.1.2.min.js"></script>
+<script src="app/fusion/scripts/services/userInfoService.js"></script>
+<script src="app/fusion/scripts/services/leftMenuService.js"></script>
+
+
+<jsp:include page="/WEB-INF/fusion/jsp/ebz/loginSnippet.html" ></jsp:include>
+
+<c:set var="UserName" value="<%= session.getAttribute(\"fullName\")%>" />
+<c:set var="UserFirstName" value="<%= session.getAttribute(\"first_name\")%>" />
+
+<%
+ String contactUsLink = SystemProperties.getProperty(SystemProperties.CONTACT_US_LINK);
+ String redirectUrl = PortalApiProperties.getProperty(PortalApiConstants.ECOMP_REDIRECT_URL);
+ String portalUrl = redirectUrl.substring(0, redirectUrl.lastIndexOf('/')) + "/process_csp";
+ String getAccessLink = redirectUrl.substring(0, redirectUrl.lastIndexOf('/')) + "/get_access";
+%>
+<c:set var="returnPortalUrl" value="<%=portalUrl%>" />
+<c:set var="contactUsLink" value="<%=contactUsLink%>" />
+<c:set var="getAccessLink" value="<%=getAccessLink%>" />
+<style>
+.att-drawer{
+ z-index:997 !important;
+}
+
+.secondaryMenuContainer{
+ z-index:1000;
+}
+.megamenu-tabs .megamenu__item {
+ padding: 0 0;
+}
+.megamenu-tabs .megamenu__item span {
+ font-size: 18px;
+}
+
+.submenu-tabs {
+ line-height:50px;
+}
+.submenu-tabs .sub__menu{
+ top:54px;
+}
+
+.top-megamenu .megamenu-tabs ul{
+ width:98%;
+ list-style: none;
+}
+
+</style>
+<%@include file="/WEB-INF/fusion/jsp/ebz/loginSnippet.html" %>
+
+<div style="position: relative; z-index: 999;">
+ <div ng-controller="headerController">
+
+ <div class="headerContainer" id="headerContainer" ng-cloak ng-show="{{showHeader}}">
+ <div id="megaMenuContainer" class="megaMenuContainer" style="margin-top: 0; overflow: visible;">
+ <div>
+ <!--for mega Menu-->
+ <!-- Mega Menu parent-tab directive with three models menu-items, active-sub-menu, active-menu -->
+ <div id="topMenu" class="top-megamenu" ng-mouseleave="activeClickSubMenu.x.active=false; activeClickMenu.x.active=false">
+ <div style="float:left;width:100%;"parent-tab menu-items="megaMenuDataObject" active-sub-menu='activeClickSubMenu.x' active-menu='activeClickMenu.x'>
+ <div parentmenu-tabs mega-menu="true" menu-items="megaMenuDataObject" style="height:55px;">
+ <div style="float:left">
+ <li class="megamenu__item" style="line-height:55px;" onclick="returnToPortal()">
+ <img src="app/fusion/external/ebz/images/att_logo.png" class="ATTLogo" ></span>
+<!-- <a id='returnPortal' class="primaryMenuOptionLink" style="font-weight: 400 !important; font-family: clearview_att_bold !important; font-size: 18px;">ECOMP</a>
+ --> <strong style="font-weight: 400 !important; font-family: clearview_att_bold !important; font-size: 18px;" id='returnPortal' >ECOMP Portal</strong>
+ </li>
+ <div menu-tabs mega-menu="true" tab-name="item.text" menu-item="item" active-menu="activeClickMenu.x"
+ ng-repeat="item in megaMenuDataObject" style="font-size: 18px;" ng-mousedown="loadFavorites()" >
+ <div parentmenu-tabs sub-menu="true" ng-show="activeClickMenu.x.active && item.active" menu-items="activeClickMenu.x.children">
+ <!-- Second level menu -->
+ <div>
+ <div menu-tabs sub-menu="true" tab-name="subItem.text"
+ tab-url="subItem.url" menu-item="subItem"
+ ng-repeat="subItem in activeClickMenu.x.children | orderBy : 'column'" active-menu="activeClickSubMenu.x"
+ sub-item-active="{{subItem.active}}" style="float:left;" aria-label="{{subItem.text}}"
+ ng-mouseenter="submenuLevelAction(subItem.text,subItem.column)"
+ ng-mouseleave="submenuLevelAction(subItem.text,subItem.column)"
+ ng-click="submenuLevelAction(subItem.text,subItem.column)" >
+ <i ng-if="subItem.text=='Favorites'" id="favorite-star"
+ class="icon-star favorites-icon-active">
+ </i>
+ </div>
+
+ <div class="sub__menu" ng-mouseleave="activeClickSubMenu.x.active=false" >
+ <ul ng-show="activeClickSubMenu.x.active" role="menubar" class="columns">
+ <!-- Third level menu -->
+ <div menu-tabs menu-item="subItem"
+ class="columns-div"
+ ng-repeat="subItem in activeClickSubMenu.x.children | orderBy : 'column'"
+ ng-show="activeClickSubMenu.x.active">
+
+ <i id="favorite-selector-third-level"
+ ng-show="isUrlFavorite(subItem.menuId)==false"
+ class="icon-star favorites-icon-inactive"
+ ng-if="subItem.url.length > 1">
+ </i>
+ <i id="favorite-selector-third-level"
+ ng-show="isUrlFavorite(subItem.menuId)"
+ class="icon-star favorites-icon-active"
+ ng-if="subItem.url.length > 1">
+ </i>
+ <span class="title" aria-label="{{subItem.text}}"
+ ng-click="goToUrl(subItem)">{{subItem.text}}</span>
+ <!-- Fourth level menus -->
+ <div att-links-list="">
+ <i id="favorite-selector-fourth-level"
+ class="icon-star favorites-icon-inactive"
+ ng-show="isUrlFavorite(tabValue.menuId)==false"
+ ng-if="tabValue.url.length > 1">
+
+ </i>
+ <i id="favorite-selector-fourth-level"
+ class="icon-star favorites-icon-active"
+ ng-show="isUrlFavorite(tabValue.menuId)"
+ ng-if="tabValue.url.length > 1">
+
+ </i>
+ <span role="menuitem" att-links-list-item=""
+ ng-repeat="tabValue in subItem.children"
+ ng-click="goToUrl(tabValue)"
+ att-accessibility-click="13,32"
+ ng-class="{'disabled': tabValue.disabled}">{{tabValue.text}}</span>
+ </div>
+ <hr ng-show="!$last"/>
+
+ </div>
+ </ul>
+ <!-- Favorites level menu -->
+ <div class="favorites-window" ng-show='favoritesWindow' ng-mouseleave="hideFavoritesWindow()">
+ <div id="favorites-menu-items" ng-show="showFavorites">
+ <div ng-repeat="subItem in favoritesMenuItems" att-links-list="" style='display: inline'>
+ <i id="favorite-selector-favorites-list" class="icon-star favorites-icon-active">
+ </i>
+ <a id="favorites-list" aria-label="{{subItem.text}}"
+ ng-click="goToUrl(subItem)"
+ style="margin-left: 3px; margin-right: 20px; text-decoration: none; color: #666666;">
+ {{subItem.text}}
+ </a>
+ </div>
+ <div>
+ <br>
+ <p style='font-weight: 400; font-family: clearview_att_bold !important;
+ font-size: 18px; text-align: center; background-color: lightgray;
+ width: 400px; margin-left: 25%; margin-right: 25%;'>
+ Manage favorites on ECOMP Portal.
+ </p>
+ </div>
+ </div>
+ <!-- Favorites when empty -->
+ <div id="favorites-empty" ng-show='favoritesWindow' ng-show="emptyFavorites">
+ <div id="favorites-empty" ng-show="emptyFavorites" class="favorites-window-empty">
+ <div>
+ <img src="app/fusion/external/ebz/images/no_favorites_star.png">
+ <p class='favoritesLargeText'>No Favorites</p>
+ <p class='favoritesNormalText'>Manage favorites on ECOMP Portal.</p>
+ </div>
+ </div>
+ </div>
+ </div>
+
+ </div>
+ </div>
+ </div>
+ </div >
+ <li class="megamenu__item" style="line-height:55px;" ng-if="loadMenufail">
+ <strong style="font-weight: 400 !important; font-family: clearview_att_bold !important; font-size: 18px;" >Unable to load menus</strong>
+ </li>
+<!-- <li class="megamenu__item" style="width: 20%;">&nbsp;</li>
+ --> </div>
+ <!-- Login Snippet-->
+ <div style="float:right">
+ <li id="bcLoginSnippet" class="megamenu__item" style="width: 140px;" >
+ <div popover="loginSnippet.html" aria-label="Login Snippet" referby="loginSnippet" att-accessibility-click="13,32" popover-style="\" popover-placement="below" style="width: 200px;">
+ <div class="icon-user-small login-snippet-icon"></div>
+ <div class="login-snippet-text" style="display: inline-block; font-size:12px; margin-left:5px;overflow: hidden; max-height: 31px; max-width:120px; padding-top: 0px; margin-top: 0px; white-space: nowrap;" ng-bind="userProfile.firstName"></div>
+ </div>
+ </li>
+ <li class="megamenu__item" style="width:120px;">&nbsp;</li>
+ </div>
+
+ </div>
+ </div>
+ <div style="clear: both"></div>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="license-notification" id="license-notification">
+ <a href="javascript:void(0)" style="background-color:#bbb;" class="button button--small" tooltip="Please contact ECOMP Portal team to get the license" tooltip-placement="below" tooltip-style="light" tooltip-popup-delay="500" >
+ <span style="">{{app_name_full}}</span>
+ </a>
+ </div>
+ <div style="position: relative; color: black; top: 70px;">
+ <div ng-cloak>
+ <span ng-style="adjustHLeftMenu('burgerIcon')" style="z-index:998; position:fixed; left:0%; font-size:35px; margin-left:10px;text-decoration:none;">
+ <a ng-click="toggleDrawer();isOpen = !isOpen" href="javascript:void(0);" class="arrow-icon-left" >
+ <span class="icon-hamburger"></span></a>
+ <span ng-init="isOpen = true" ng-show="isOpen" style="font-size:16px; position:relative; top:-8px; left:-15px;">&nbsp&nbsp&nbsp {{app_name}}</span>
+ </span>
+ <div att-drawer drawer-slide="left" drawer-custom-top="{{drawer_custom_top}}px" drawer-size="200px" drawer-open="drawerOpen" drawer-custom-height="100%" >
+ <div ng-style="adjustHLeftMenu('leftMenu')">
+ <div class="attDrawer" style="margin-top:{{drawer_margin_top}}px;">
+ <div style="margin-left:10px; margin-right:10px;">
+ <accordion close-others="true" css="att-accordion--no-box">
+ <accordion-group ng-repeat="parent in menuItems" heading="{{parent.parentLabel}}" child="{{parent.parentAction}}" parent-link="{{parent.parentAction}}" image-source="{{parent.parentImageSrc}}" child-length="{{parent.childItemList.length}}" is-open="parent.open">
+ <div ng-repeat="subMenu in parent.childItemList" style="font-size:12px; margin-left:10px;">
+ <a href="{{subMenu.action}}" style="font-size:12px; color:#666666;" >{{subMenu.label}}</a>
+ </div>
+ </accordion-group>
+ </accordion>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+</div>
+<script>
+ function returnToPortal(){
+ window.location.href = "<c:out value='${returnPortalUrl}'/>";
+ }
+ detectScrollEvent = function() {
+ var footerOff = $('#footerContainer').offset().top;
+ var headOff = $('#headerContainer').offset().top;
+ var winHeight = $(window).height();
+ if ((footerOff - headOff) <= winHeight) {
+ $('.att-drawer').css({
+ "height" : footerOff - headOff - 55
+ });
+ } else {
+ $('.att-drawer').css({
+ "height" : "94vh"
+ });
+ }
+ }
+ $(window).scroll(function() {
+ if ($('.att-drawer').is(':visible')) {
+ detectScrollEvent();
+ }
+ });
+ app.controller("headerController", function($scope, $timeout, $log, $http, UserInfoService, $window, $cookies,LeftMenuService) {
+ // $log.debug('HeaderController started');
+ $scope.jsonMenuData = [];
+ $scope.loadMenufail=false;
+ $scope.app_name = "";
+ $scope.app_name_full = "";
+ $scope.megaMenuDataObject =[];
+ $scope.activeClickSubMenu = {
+ x: ''
+ };
+ $scope.activeClickMenu = {
+ x: ''
+ };
+ $scope.favoritesMenuItems = [];
+ $scope.favoriteItemsCount = 0;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ $scope.favoritesWindow = false;
+ $scope.userProfile={
+ firstName:'',
+ lastName:'',
+ fullName:'',
+ email:''
+ }
+ /*Put user info into fields*/
+ $scope.inputUserInfo = function(userInfo){
+ if (typeof(userInfo) != "undefined" && userInfo!=null && userInfo!=''){
+ if (typeof(userInfo.USER_FIRST_NAME) != "undefined" && userInfo.USER_FIRST_NAME!=null && userInfo.USER_FIRST_NAME!='')
+ $scope.userProfile.firstName = userInfo.USER_FIRST_NAME;
+ if (typeof(userInfo.USER_LAST_NAME) != "undefined" && userInfo.USER_LAST_NAME!=null && userInfo.USER_LAST_NAME!='')
+ $scope.userProfile.lastName = userInfo.USER_LAST_NAME;
+ if (typeof(userInfo.USER_EMAIL) != "undefined" && userInfo.USER_EMAIL!=null && userInfo.USER_EMAIL!='')
+ $scope.userProfile.email = userInfo.USER_EMAIL;
+ }
+ }
+ /*getting user info from session*/
+ $scope.getUserNameFromSession = function(){
+ UserInfoService.getFunctionalMenuStaticDetailSession()
+ .then(function (res) {
+ $scope.userProfile.firstName = res.firstName;
+ $scope.redirectUrl = res.portalUrl;
+ });
+ }
+ $scope.getTopMenuStaticInfo=function() {
+ var promise = UserInfoService.getFunctionalMenuStaticDetailShareContext();
+ promise.then(
+ function(res) {
+ if(res==null || res==''){
+ $log.info('failed getting static User information');
+ $scope.getUserNameFromSession();
+ }else{
+ $log.info('Received static User information');
+ var resData = res;
+ $scope.inputUserInfo(resData);
+ $scope.userProfile.fullName = $scope.userProfile.firstName+ ' '+ $scope.userProfile.lastName;
+ }
+ },
+ function(err) {
+ $log.info('failed getting static User information');
+ }
+ );
+ }
+
+ var unflatten = function( array, parent, tree ){
+ tree = typeof tree !== 'undefined' ? tree : [];
+ parent = typeof parent !== 'undefined' ? parent : { menuId: null };
+ var children = _.filter( array, function(child){ return child.parentMenuId == parent.menuId; });
+
+ if( !_.isEmpty( children ) ){
+ if( parent.menuId === null ){
+ tree = children;
+ }else{
+ parent['children'] = children
+ }
+ _.each( children, function( child ){ unflatten( array, child ) } );
+ }
+
+ return tree;
+ }
+
+ var menuStructureConvert = function(menuItems) {
+ var megaMenuDataObjectTemp = [
+ {
+ text: "ECOMP",
+ children:menuItems
+ },
+ {
+ text: "Help",
+ children: [{
+ text:"Contact Us",
+ url:"<c:out value='${contactUsLink}'/>"
+ },
+ {
+ text:"Get Access",
+ url:"<c:out value='${getAccessLink}'/>"
+ }]
+ }
+ ];
+ return megaMenuDataObjectTemp;
+ };
+
+
+ /*Left Menu*/
+ LeftMenuService.getAppName().then(function(response){
+ var j = response;
+ try{
+ if(j && j !== "null" && j!== "undefined"){
+ // console.log("app name is " + $scope.app_name);
+ $scope.app_name_full = j.data;
+ var processed_app_name = j.data;
+ var indexOfLic = processed_app_name.indexOf('[');
+ if(indexOfLic>-1) {
+ if (jQuery('.license-notification')!=null)
+ jQuery('.license-notification').css("display", "none");
+ }
+ var n = processed_app_name.length;
+ if (n > 15) {
+ n = 15;
+ }
+ if(n > indexOfLic && indexOfLic > 0) {
+ n = indexOfLic;
+ }
+ $scope.app_name_full = $scope.app_name_full.substr(0, n);
+ $scope.app_name = processed_app_name.substr(0, n);
+
+ }else{
+ throw "Get app_name response is not an object/is empty";
+ }
+ }catch (e) {
+ console.log("error happened while trying to get app name "+e);
+ return;
+ }
+ },function(error){
+ console.log('getAppName failed', error);
+ });
+
+
+ $scope.getTopMenuStaticInfo();
+ $scope.getMenu=function() {
+
+ $http({
+ method: "GET",
+ url: 'get_functional_menu',
+// TIMEOUT USED FOR LOCAL TESTING ONLY
+// timeout: 100
+ }).success(function (response) {
+ if(response == '101: Timeout') {
+ $log.error('Timeout attempting to get_functional_menu');
+ // TIMEOUT USED FOR LOCAL TESTING ONLY
+// $scope.createErrorMenu();
+ $scope.megaMenuDataObject = menuStructureConvert('');
+ }else {
+ $log.debug('get_functional_menu success: ' + response);
+ if(typeof response != 'undefined' && response.length!=0 && typeof response[0] != 'undefined' && typeof response[0].error!="undefined"){
+// createErrorMenu() USED FOR LOCAL TESTING ONLY
+// $scope.createErrorMenu();
+ $scope.megaMenuDataObject = menuStructureConvert('');
+ // $scope.loadMenufail=true;
+ }else{
+ $scope.jsonMenuData = unflatten( response );
+ $scope.megaMenuDataObject = menuStructureConvert($scope.jsonMenuData);
+ }
+ }
+ }).error(function (response){
+// createErrorMenu() USED FOR LOCAL TESTING ONLY
+// $scope.createErrorMenu();
+
+ //$scope.loadMenufail=true;
+ $scope.megaMenuDataObject = menuStructureConvert('');
+ $log.debug('REST API failed get_functional_menu...'+ response);
+ });
+ }
+ $scope.adjustHLeftMenu = function (type){
+ $scope.showHeader = ($cookies.show_app_header == undefined ? true : $cookies.show_app_header);
+
+ if($scope.showHeader == true) {
+ $scope.drawer_margin_top = 60;
+ $scope.drawer_custom_top = 54;
+ $scope.toggle_drawer_top = 55;
+ }
+ else {
+
+ $scope.drawer_margin_top = 50;
+ $scope.drawer_custom_top = 0;
+ $scope.toggle_drawer_top = 10;
+ }
+ if(type=='burgerIcon'){
+ return { "top": $scope.toggle_drawer_top+"px"};
+ }else if(type=='leftMenu'){
+ return { "margin-top": $scope.drawer_margin_top+"px"};
+ }else
+ return;
+ }
+ $scope.adjustHeader=function() {
+ $scope.showHeader = ($cookies.show_app_header == undefined ? true : $cookies.show_app_header);
+
+ if($scope.showHeader == true) {
+ $scope.drawer_margin_top = 50;
+ $scope.drawer_custom_top = 54;
+ $scope.toggle_drawer_top = 55;
+ }
+ else {
+
+ $scope.drawer_margin_top = 40;
+ $scope.drawer_custom_top = 0;
+ $scope.toggle_drawer_top = 10;
+ }
+
+
+ }
+
+
+ //$scope.getMenu();
+ $scope.adjustHeader();
+
+
+ /* **************************************************************************/
+ /* Logic for the favorite menus is here */
+
+ $scope.loadFavorites = function () {
+ $log.debug('loadFavorites has happened.');
+ if ($scope.favoritesMenuItems == '') {
+ $scope.generateFavoriteItems();
+ $log.debug('loadFavorites is calling generateFavoriteItems()');
+ } else {
+ $log.debug('loadFavorites is NOT calling generateFavoriteItems()');
+ }
+ }
+
+ $scope.goToUrl = function (item) {
+ $log.info("goToUrl called")
+ $log.info(item);
+
+ var url = item.url;
+ var restrictedApp = item.restrictedApp;
+ $log.debug('Restricted app status is: ' + restrictedApp);
+ if (!url) {
+ $log.info('No url found for this application, doing nothing..');
+ return;
+ }
+ if (restrictedApp) {
+ $window.open(url, '_blank');
+ } else {
+ $window.open(url, '_self');
+ }
+
+ }
+
+ $scope.submenuLevelAction = function(index, column) {
+ if ($scope.favoritesMenuItems == '') {
+ $scope.generateFavoriteItems();
+ $log.debug('submenuLevelAction is calling generateFavoriteItems()');
+ }
+ $log.debug('item hovered/clicked: ' + index + '; column = ' + column);
+ if (column == 2) { // 2 is Design
+ $scope.favoritesWindow = false;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ }
+ if (index=='Favorites' && $scope.favoriteItemsCount != 0) {
+ $log.debug('Showing Favorites window');
+ $scope.favoritesWindow = true;
+ $scope.showFavorites = true;
+ $scope.emptyFavorites = false;
+ }
+ if (index=='Favorites' && $scope.favoriteItemsCount == 0) {
+ $log.debug('Hiding Favorites window in favor of No Favorites Window');
+ $scope.favoritesWindow = true;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = true;
+ }
+ if (column > 2) {
+ $scope.favoritesWindow = false;
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ }
+ };
+
+ $scope.hideFavoritesWindow = function() {
+ $log.debug('$scope.hideFavoritesWindow has been called');
+ $scope.showFavorites = false;
+ $scope.emptyFavorites = false;
+ }
+
+ $scope.isUrlFavorite = function (menuId) {
+// $log.debug('array objects in menu favorites = ' + $scope.favoriteItemsCount + '; menuId=' + menuId);
+ var jsonMenu = JSON.stringify($scope.favoritesMenuItems);
+ var isMenuFavorite = jsonMenu.indexOf('menuId\":' + menuId);
+ if (isMenuFavorite==-1) {
+ return false;
+ } else {
+ return true;
+ }
+
+ }
+
+ $scope.generateFavoriteItems = function() {
+ $http({
+ method: "GET",
+ url: 'get_favorites',
+ // TIMEOUT USED FOR LOCAL TESTING ONLY
+// timeout: 100
+ }).success(function (response) {
+ if (response == '101: Timeout') {
+ $log.error('Timeout attempting to get_favorites_menu');
+ } else {
+ if(typeof response != 'undefined' && response.length!=0 && typeof response[0] != 'undefined' && typeof response[0].error!="undefined"){
+ $log.error('REST API failed get_favorites' + response);
+ }else{
+ $log.debug('get_favorites = ' + JSON.stringify(response));
+ $scope.favoritesMenuItems = response;
+ $scope.favoriteItemsCount = Object.keys($scope.favoritesMenuItems).length;
+ $log.info('number of favorite menus: ' + $scope.favoriteItemsCount);
+ }
+ }
+ }).error(function (response){
+ $log.error('REST API failed get_favorites' + response);
+ //createFavoriteErrorMenu() USED FOR LOCAL TESTING ONLY
+// $scope.createFavoriteErrorMenu();
+ });
+ }
+
+ $scope.createFavoriteErrorMenu=function() {
+ $scope.favoritesMenuItems = [
+// {
+// "menuId": "93",
+// "text": "JSONLint",
+// "url": "http://http://jsonlint.com"
+// },
+// {
+// "menuId": "22",
+// "text": "ECOMP Wasteland",
+// "url": "https://ecomp.homer.att.com/ecompportal/applicationsHome"
+// },
+// {
+// "menuId": "94",
+// "text": "HROneStop",
+// "url": "http://ebiz.sbc.com/hronestop"
+// },
+// {
+// "menuId": "91",
+// "text": "Andy and his Astrophotgraphy",
+// "url": "https://ecomp.homer.att.com/ecompportal/applicationsHome"
+// }
+ ];
+ $scope.favoriteItemsCount = Object.keys($scope.favoritesMenuItems).length;
+ $log.info('number of favorite menus: ' + $scope.favoriteItemsCount);
+ }
+
+ /* end of Favorite Menu code */
+ /* **************************************************************************/
+
+
+ /* **************************************************************************/
+ // THIS IS USED FOR LOCAL TESTING ONLY
+ /* **************************************************************************/
+
+ $scope.createErrorMenu=function() {
+ $scope.jsonMenuData = [
+ {
+ "menuId": 1,
+ "column": 2,
+ "text": "Design",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 2,
+ "column": 3,
+ "text": "Infrastructure Ordering",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 3,
+ "column": 4,
+ "text": "Service Creation",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 4,
+ "column": 5,
+ "text": "Service Mgmt",
+ "parentMenuId": null,
+ "url": ""
+ },
+ {
+ "menuId": 90,
+ "column": 1,
+ "text": "Google",
+ "parentMenuId": 1,
+ "url": "http://google.com"
+ },
+ {
+ "menuId": 91,
+ "column": 1,
+ "text": "Mike Little's Coffee Cup",
+ "parentMenuId": 2,
+ "url": "http://coffee.com"
+ },
+ {
+ "menuId": 92,
+ "column": 2,
+ "text": "Andy and his Astrophotgraphy",
+ "parentMenuId": 3,
+ "url": "http://nightskypix.com"
+ },
+ {
+ "menuId": 93,
+ "column": 1,
+ "text": "JSONLint",
+ "parentMenuId": 4,
+ "url": "http://http://jsonlint.com"
+ },
+ {
+ "menuId": 94,
+ "column": 2,
+ "text": "HROneStop",
+ "parentMenuId": 4,
+ "url": "http://ebiz.sbc.com/hronestop"
+ },
+ {
+ "menuId": 95,
+ "column": 2,
+ "text": "4th Level App4a R16",
+ "parentMenuId": 4,
+ "url": "http://www.e-access.att.com/ecomp_portal_ist/ecompportal/widgets"
+ },
+ {
+ "menuId": 96,
+ "column": 3,
+ "text": "3rd Level App1c R200",
+ "parentMenuId": 4,
+ "url": "http://app1c.com"
+ },
+ {
+ "menuId": 97,
+ "column": 1,
+ "text": "3rd Level App4b R16",
+ "parentMenuId": 5,
+ "url": "http://app4b.com"
+ },
+ {
+ "menuId": 98,
+ "column": 2,
+ "text": "3rd Level App2b R16",
+ "parentMenuId": 5,
+ "url": "http://app2b.com"
+ },
+ {
+ "menuId": 99,
+ "column": 1,
+ "text": "Favorites",
+ "parentMenuId": null,
+ "url": ""
+ }
+ ];
+ $scope.jsonMenuData = unflatten( $scope.jsonMenuData );
+ $scope.megaMenuDataObject = menuStructureConvert($scope.jsonMenuData);
+// $log.debug(JSON.stringify($scope.jsonMenuData));
+ }
+ var childItemList="";
+ var parentList = "";
+ try{
+ childItemList = ${menu.childItemList};
+ parentList = ${menu.parentList};
+ }catch(err){
+ console.log("ebz_header: failed to get child/parent lists", err);
+ }
+
+ var pageUrl = window.location.href.split('/')[window.location.href.split('/').length-1];
+
+ $scope.menuItems = [];
+ for (var i = 0; i < parentList.length; i++) {
+ $scope.openCurrentMenu = false;
+ if(pageUrl==parentList[i].action)
+ $scope.openCurrentMenu = true;
+ $scope.childItemList = childItemList[i];
+ for(chIndex in $scope.childItemList){
+ if($scope.childItemList.length>0)
+ if($scope.childItemList[chIndex].action!=null){
+ if($scope.childItemList[chIndex].action==pageUrl)
+ $scope.openCurrentMenu = true;
+ }
+ }
+ $scope.item = {
+ parentLabel : parentList[i].label,
+ parentAction : parentList[i].action,
+ parentImageSrc : parentList[i].imageSrc,
+ open:$scope.openCurrentMenu,
+ childItemList : $scope.childItemList
+ }
+ $scope.menuItems.push($scope.item);
+ }
+ $scope.arrowShow = true;
+ $scope.drawerOpen = false;
+ $scope.subMenuContent = false;
+ $scope.toggleSubMenu = function() {
+ $scope.subMenuContent = !$scope.subMenuContent;
+ };
+
+ var drawerOpen = 'open';
+ if (drawerOpen == 'open') {
+ $scope.drawerOpen = true;
+ $scope.arrowShow = true;
+ } else {
+ $scope.arrowShow = false;
+ }
+ $scope.arrowShow = true;
+ $scope.drawerOpen = false;
+ $scope.toggleDrawer = function() {
+ $scope.drawerOpen = !($scope.drawerOpen);
+ if ($scope.drawerOpen) {
+ $scope.arrowShow = true;
+ if (document.getElementById('mContent')!=null)
+ document.getElementById('mContent').style.marginLeft = "0px";
+ } else {
+ $scope.arrowShow = false;
+ if (document.getElementById('mContent')!=null)
+ document.getElementById('mContent').style.marginLeft = "-150px";
+ }
+ };
+ //var drawerOpen = getCookie('drawerOpen');
+ if (drawerOpen == 'open') {
+ $scope.drawerOpen = true;
+ $scope.arrowShow = true;
+ } else {
+ $scope.arrowShow = false;
+ }
+ $timeout(function() {
+ detectScrollEvent();
+ }, 800);
+
+ });
+
+ app.filter("ellipsis", function(){
+ return function(text, length){
+ if (text) {
+ var ellipsis = text.length > length ? "..." : "";
+ return text.slice(0, length) + ellipsis;
+ };
+ return text;
+ }
+ });
+</script> \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/WEB-INF/fusion/orm/RNoteBookIntegration.hbm.xml b/vid-app-common/src/test/resources/WEB-INF/fusion/orm/RNoteBookIntegration.hbm.xml
new file mode 100644
index 00000000..6638b4bc
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/fusion/orm/RNoteBookIntegration.hbm.xml
@@ -0,0 +1,44 @@
+<?xml version="1.0"?>
+<!--
+ ================================================================================
+ eCOMP Portal SDK
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property
+ ================================================================================
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ================================================================================
+ -->
+
+<!DOCTYPE hibernate-mapping PUBLIC
+ "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
+ "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
+
+<hibernate-mapping package="org.openecomp.portalsdk.rnotebookintegration.domain">
+
+
+ <!-- RNotebookIntegration mapping details -->
+ <class name="RNoteBookCredentials" table="rcloudinvocation">
+ <id name="token" column="ID">
+
+ </id>
+ <property name="createdDate" column="created"/>
+ <property name="userString" column="userInfo"/>
+ <property name="notebookID" column="notebookID"/>
+ <property name="parametersString" column="parameters"/>
+ <property name="tokenReadDate" column="tokenreaddate"/>
+
+ </class>
+
+
+
+</hibernate-mapping>
diff --git a/vid-app-common/src/test/resources/WEB-INF/index.jsp b/vid-app-common/src/test/resources/WEB-INF/index.jsp
new file mode 100644
index 00000000..f6030c97
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/index.jsp
@@ -0,0 +1,24 @@
+<%--
+ ================================================================================
+ eCOMP Portal SDK
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property
+ ================================================================================
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ================================================================================
+ --%>
+<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
+
+<%-- Redirected because we can't set the welcome page to a virtual URL. --%>
+<%-- Forward to the intended start page to reduce frustration for new users. --%>
+<c:redirect url="/login.htm"></c:redirect>
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/createnewserviceinstance.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/createnewserviceinstance.jsp
new file mode 100644
index 00000000..fd2030e6
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/createnewserviceinstance.jsp
@@ -0,0 +1,146 @@
+<script>
+app.controller('createNewSIController',['$scope','$http',function ($scope,$http) {
+
+ $scope.searchCategory = "";
+ $scope.searchString = "";
+ $scope.tableData=[];
+ $scope.displayData=[];
+ $scope.selectedSubscriber = $scope.tableData[0];
+ $scope.selectedServiceType = "Select Service Type";
+ function escapeRegExp(str) {
+ return str.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|\&]/g, " ");
+ }
+ $scope.serviceTypes=["Select Service Type", "uCPE-VMS", "SDN-L3-BONDING", "SDN-ETHERNET-INTERNET"];
+
+ $scope.getSubscribers = function(refresh){
+
+ var refreshTxt = 'refresh_subscribers';
+ var getTxt = 'get_subscribers';
+ var selectedTxt = getTxt;
+ if (refresh)
+ selectedTxt = refreshTxt;
+ $http.get(selectedTxt).
+ then(function(response){
+ var data = JSON.parse(response.data.result);
+ $scope.tableData = data['customer'];
+ $scope.initSubscriberList();
+ })
+ .catch(function(data,status){
+ console.log("Error: " + status + " : " + data);
+ })
+ .finally(function() {
+
+ });
+
+ }
+
+
+ $scope.initSubscriberList = function () {
+ //$scope.selectedSubscriber = $scope.selectedSubscriber['subscriber-name'] || $scope.tableData[0]['subscriber-name'];
+ $scope.selectedSubscriber = 'Select Subscriber Name';
+ }
+
+ $scope.initSrvcTypeList = function () {
+ $scope.selectedServiceType = $scope.serviceTypes[0];
+ }
+
+ $scope.getSubscriberDetails = function(selectedSubscriber){
+ if (selectedSubscriber == 'Select Subscriber Name')
+ return;
+ $http.get('createsubscriber/' + encodeURIComponent(selectedSubscriber)).
+ then(function(response){
+ // window.location.href = 'createsubscriberdetails.htm';
+ })
+ .catch(function(data,status){
+ console.log("Error: " + status + " : " + data);
+ })
+ .finally(function() {
+
+ });
+ }
+
+ $scope.disableSubmitBtn = function (subName, svcType) {
+ return (typeof subName === "undefined") && (svcType == 'Select Service Type');
+ //return (subName == 'Select Subscriber Name') && (svcType == 'Select Service Type');
+ }
+
+ $scope.cancelCreateSI = function(selectedSubscriber){
+
+ window.location.href = 'welcome.htm';
+
+ }
+
+ $scope.getSubscribers(false);
+ //$scope.initSubscriberList();
+
+}]);
+
+
+</script>
+
+<div ng-controller="createNewSIController">
+
+ <h1 class="heading1"><center>Create New Service Instance</center></h1>
+
+
+<BR>
+ <table> <tr>
+
+ <td width="5%" align="left">
+ <!-- <a ng-click="getSubscriberDetails(selectedSubscriber['global-customer-id']);" ng-disabled="disableSubmitBtn(selectedSubscriber['subscriber-name'], selectedServiceType);" ><img src="static/fusion/images/plus.png"></a>-->
+ <input type="image" ng-click="getSubscriberDetails(selectedSubscriber['global-customer-id']);" ng-disabled="disableSubmitBtn(selectedSubscriber['subscriber-name'], selectedServiceType);" src="static/fusion/images/plus.png"/>
+ </td>
+
+ <td style="width:10%" align="left"><div class="fn-ebz-container">
+ <label class="fn-ebz-text-label">Subscriber:</label>
+ </div> </td>
+ <td style="width:30%"><div class="fn-ebz-container">
+ <select ng-model="selectedSubscriber" ng-options="resultdata['subscriber-name'] for resultdata in tableData" required>
+ <option value="">Select Subscriber Name</option>
+ </select>
+ </div></td>
+ <td width="5%" align="left">
+ <input type="image" ng-click="getSubscribers(true);" src="static/fusion/images/refresh.jpg"/>
+ </td>
+
+ <td width="5%"> </td>
+<td style="width:10%" align="left">
+
+
+ <div class="fn-ebz-container">
+ <label class="fn-ebz-text-label">Service Type:</label>
+ </div> </td>
+ <td style="width:32%"><div class="fn-ebz-container">
+ <select ng-model="selectedServiceType" ng-options="sType for sType in serviceTypes" ng-init="initSrvcTypeList();" ></select>
+ </div> </td>
+
+ <td width="5%"> </td>
+
+ </tr>
+ </table>
+
+ <center>
+ <button type="cancel" ng-click="cancelCreateSI();" att-button size="small">Cancel</button>
+ </center>
+
+
+
+</div>
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/login.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/login.jsp
new file mode 100644
index 00000000..804c0bfe
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/login.jsp
@@ -0,0 +1,125 @@
+<%@ page import="java.net.URLEncoder"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%
+ // Requests are handled by class ProcessCspController in the EP-SDK-Core library.
+ // On login error, that controller returns a model that is a String->String map.
+
+ // CSP property is defined in fusion.properties file
+ final String cspLoginUrl = SystemProperties.getProperty(SystemProperties.CSP_LOGIN_URL);
+ // Name is defined by app; do not throw if missing
+ final String appDisplayName = SystemProperties.containsProperty(SystemProperties.APP_DISPLAY_NAME)
+ ? SystemProperties.getProperty(SystemProperties.APP_DISPLAY_NAME)
+ : SystemProperties.APP_DISPLAY_NAME;
+ // Build login-link URL using parameters and/or system properties
+ String returnUrl = request.getParameter("returnUrl");
+ if (returnUrl == null) {
+ final String cspPage = "doLogin";
+ if (SystemProperties.containsProperty(SystemProperties.APP_BASE_URL)) {
+ // Use property with the application URL; e.g., WebJunction
+ String appUrl = SystemProperties.getProperty(SystemProperties.APP_BASE_URL);
+ returnUrl = appUrl + (appUrl.endsWith("/") ? "" : "/") + cspPage;
+ } else {
+ // Use server info; incorrect for sites behind WebJunction.
+ returnUrl = (request.isSecure() ? "https://" : "http://") + request.getServerName() + ":"
+ + request.getServerPort() + request.getContextPath() + "/" + cspPage;
+ }
+ } else {
+ // Request has a parameter with the return URL
+ returnUrl = URLEncoder.encode(returnUrl, "UTF-8");
+ }
+%>
+<!DOCTYPE html>
+<html>
+<head>
+<meta charset="utf-8">
+<meta http-equiv="X-UA-Compatible" content="IE=edge">
+<meta name="viewport" content="width=device-width, initial-scale=1">
+<!-- The above 3 meta tags *must* come first in the head; any other head content must come *after* these tags -->
+<style>
+html {
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+}
+
+body {
+ padding-top: 15px;
+}
+
+.logo {
+ position: fixed;
+ left: 15px;
+ top: 15px;
+ z-index: -1;
+}
+
+.loginError {
+ font-size: 18px;
+ color: red;
+ text-align: center;
+}
+
+.login {
+ font-size: 16px;
+ display: block;
+ margin-left: auto;
+ margin-right: auto;
+ text-align: center;
+ width: 100%;
+}
+
+.login a {
+ font-size: 16px;
+}
+
+.terms {
+ font-size: 10px;
+ text-align: center;
+ margin-left: auto;
+ margin-right: auto;
+}
+
+.terms a {
+ font-size: 10px;
+ text-align: center;
+ margin-left: auto;
+ margin-right: auto;
+}
+</style>
+</head>
+<body>
+ <!-- AT&T Logo -->
+ <div class="logo">
+ <img src="static/fusion/images/logo_att_header.jpg" alt="AT&T" />
+ </div>
+ <div class="login">
+ <img src="static/fusion/images/ecomp-login-550x360.jpg" />
+ <h2>
+ <%=appDisplayName%>
+ </h2>
+ <a href="<%=cspLoginUrl%><%=returnUrl%>">Click here to login</a>
+ </div>
+ <br />
+ <br />
+ <br />
+ <div class="loginError">${model.error}</div>
+ <br />
+ <br />
+ <br />
+ <br />
+ <br />
+ <br />
+ <div id="footer">
+ <div class="terms">
+ Warning: This system is restricted to AT&amp;T authorized users for
+ business purposes. Unauthorized access is a violation of the law. <br />
+ This service may be monitored for administrative and security
+ reasons. By proceeding, you consent to this monitoring.
+ </div>
+ <p>
+ <div class="terms">
+ <a target="_top" href="http://www.att.com/terms/">Terms and
+ Conditions</a> | <a target="_top" href="http://www.att.com/privacy/">Privacy
+ Policy</a> <br> &copy; 2017 AT&amp;T. All rights reserved.
+ </div>
+ </div>
+</body>
+</html>
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/login_external.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/login_external.jsp
new file mode 100644
index 00000000..dfa3305f
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/login_external.jsp
@@ -0,0 +1,126 @@
+<%--
+ ================================================================================
+ ECOMP Portal SDK
+ ================================================================================
+ Copyright (C) 2017 AT&T Intellectual Property
+ ================================================================================
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ ================================================================================
+--%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<!DOCTYPE html>
+<%
+ // Name is defined by app; do not throw if missing
+ final String appDisplayName = SystemProperties.containsProperty(SystemProperties.APP_DISPLAY_NAME)
+ ? SystemProperties.getProperty(SystemProperties.APP_DISPLAY_NAME)
+ : SystemProperties.APP_DISPLAY_NAME;
+%>
+
+<html>
+ <head>
+ <meta charset="utf-8">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+ <style>
+ html {
+ font-family: Verdana, Arial, Helvetica, sans-serif;
+ }
+ body {
+ padding-top: 15px;
+ }
+ .logo {
+ position: fixed;
+ left: 15px;
+ top: 15px;
+ z-index: -1;
+ }
+ .loginError {
+ font-size: 18px;
+ color: red;
+ text-align: center;
+ }
+ .login {
+ font-size: 16px;
+ display: block;
+ margin-left: auto;
+ margin-right: auto;
+ text-align: center;
+ width: 100%;
+ }
+ .login input[type=submit] {
+ font-size: 16px;
+ }
+ .terms {
+ font-size: 10px;
+ text-align: center;
+ margin-left: auto;
+ margin-right: auto;
+ }
+ .terms a {
+ font-size: 10px;
+ text-align: center;
+ margin-left: auto;
+ margin-right: auto;
+ }
+ </style>
+ </head>
+ <body>
+ <!-- AT&T Logo -->
+ <div class="logo">
+ <img src="static/fusion/images/logo_att_header.jpg" alt="AT&T" />
+ </div>
+ <div class="login">
+ <img src="static/fusion/images/ecomp_trans.png" />
+ <h2>
+ <%=appDisplayName%>
+ </h2>
+ <br />
+ <form action="login_external" method="POST">
+ <label for="loginId">Login ID:</label>
+ <input id="loginId" name="loginId" type="text" style="width: 140px;height:25px;border-radius:7px;font-size:18px;padding-left:5px;" maxlength="30">
+ <br/>
+ <br/>
+ <label for="password">Password:</label>
+ <input id="password" name="password" type="password" style="width: 140px;height:25px;border-radius:7px;font-size:18px;padding-left:5px;"
+ maxlength="30" >
+ <br />
+ <br />
+ <input id="loginBtn" type="submit" alt="Login" value="Login">
+ </form>
+ </div>
+ <br />
+ <br />
+ <div class="loginError">${model.error}</div>
+ <br />
+ <br />
+ <br />
+ <br />
+ <br />
+ <br />
+ <div id="footer">
+ <div class="terms">
+ Warning: This system is restricted to AT&amp;T authorized users for
+ business purposes. Unauthorized access is a violation of the law.
+ <br />
+ This service may be monitored for administrative and security
+ reasons. By proceeding, you consent to this monitoring.
+ </div>
+ <p>
+ <div class="terms">
+ <a target="_top" href="http://www.att.com/terms/">Terms and
+ Conditions</a> | <a target="_top" href="http://www.att.com/privacy/">Privacy
+ Policy</a> <br> &copy; 2017 AT&amp;T. All rights reserved.
+ </div>
+ </div>
+ </body>
+</html>
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/searchexistingsi.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/searchexistingsi.jsp
new file mode 100644
index 00000000..2c7dd9f5
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/searchexistingsi.jsp
@@ -0,0 +1,81 @@
+<link rel="stylesheet" type="text/css" href="app/vid/styles/subscriberSearch.css" />
+
+<script src="app/vid/scripts/controller/VidApp.js"></script>
+<script src="app/vid/scripts/controller/subscriberSearch.js"></script>
+
+<script src="app/vid/scripts/controller/aaiSubscriberController.js"></script>
+<script src="app/vid/scripts/services/utilityService.js"></script>
+<script src="app/vid/scripts/angular-ui-tree.js"></script>
+
+<link rel="stylesheet" type="text/css" href="app/vid/styles/dialogs.css" />
+
+<script src="app/vid/test/testAaiData.js"></script>
+
+<script src="app/vid/scripts/controller/creationDialogController.js"></script>
+<script src="app/vid/scripts/controller/deletionDialogController.js"></script>
+<script src="app/vid/scripts/controller/detailsDialogController.js"></script>
+<script src="app/vid/scripts/controller/statusDialogController.js"></script>
+<script src="app/vid/scripts/controller/msoCommitController.js"></script>
+
+<script src="app/vid/scripts/services/aaiService.js"></script>
+<script src="app/vid/scripts/services/asdcService.js"></script>
+<script src="app/vid/scripts/services/creationService.js"></script>
+<script src="app/vid/scripts/services/dataService.js"></script>
+<script src="app/vid/scripts/services/deletionService.js"></script>
+<script src="app/vid/scripts/services/detailsService.js"></script>
+<script src="app/vid/scripts/services/statusService.js"></script>
+<script src="app/vid/scripts/services/componentService.js"></script>
+<script src="app/vid/scripts/services/msoService.js"></script>
+<script src="app/vid/scripts/services/propertyService.js"></script>
+<script src="app/vid/scripts/services/utilityService.js"></script>
+
+<script src="app/vid/scripts/directives/extensionsDirective.js"></script>
+<script src="app/vid/scripts/directives/parameterBlockDirective.js"></script>
+<script src="app/vid/scripts/directives/popupWindowDirective.js"></script>
+<script src="app/vid/scripts/directives/progressBarDirective.js"></script>
+
+<script src="app/vid/scripts/constants/componentConstants.js"></script>
+<script src="app/vid/scripts/constants/fieldConstants.js"></script>
+<script src="app/vid/scripts/constants/parameterConstants.js"></script>
+
+<link rel="stylesheet" type="text/css" href="app/vid/styles/aaiGetSubs.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/aaiSubDetails.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/angular-ui-tree.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/vidTree.css" />
+
+<%@ page import="org.openecomp.vid.mso.*"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%
+ String properties = "{msoMaxPolls:" + SystemProperties.getProperty(MsoProperties.MSO_MAX_POLLS)
+ + ",msoMaxPollingIntervalMsec:"
+ + SystemProperties.getProperty(MsoProperties.MSO_POLLING_INTERVAL_MSECS) + "}";
+%>
+
+<div ng-controller="aaiSubscriberSearchController"
+ ng-init="init(<%=properties%>);" ng-cloak>
+
+
+
+ <div ng-view></div>
+
+</div>
+
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
+ \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/serviceModels.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/serviceModels.jsp
new file mode 100644
index 00000000..3280bc65
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/serviceModels.jsp
@@ -0,0 +1,82 @@
+<link rel="stylesheet" type="text/css" href="app/vid/styles/aaiGetSubs.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/aaiSubDetails.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/aaiSubViewEdit.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/angular-ui-tree.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/dialogs.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/instantiate.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/vidTree.css" />
+<link rel="stylesheet" type="text/css" href="app/vid/styles/dialogs.css" />
+
+
+ <script>
+
+ var appDS2 = app;
+</script>
+ <script src="app/vid/scripts/controller/VidApp.js"></script>
+
+<!-- Latest compiled and minified JavaScript -->
+
+<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
+
+
+<script src="app/vid/scripts/angular-ui-tree.js"></script>
+
+<script src="app/vid/scripts/constants/componentConstants.js"></script>
+<script src="app/vid/scripts/constants/fieldConstants.js"></script>
+<script src="app/vid/scripts/constants/vidConfiguration.js"></script>
+<script src="app/vid/scripts/constants/parameterConstants.js"></script>
+<script src="app/vid/scripts/controller/aaiSubscriberController.js"></script>
+<script src="app/vid/scripts/controller/creationDialogController.js"></script>
+<script src="app/vid/scripts/controller/deletionDialogController.js"></script>
+<script src="app/vid/scripts/controller/detailsDialogController.js"></script>
+<script src="app/vid/scripts/controller/statusDialogController.js"></script>
+<script src="app/vid/scripts/controller/InstantiationController.js"></script>
+<script src="app/vid/scripts/controller/msoCommitController.js"></script>
+<script src="app/vid/scripts/controller/ServiceModelController.js"></script>
+<script src="app/vid/scripts/controller/previousVersionDialogController.js"></script>
+<script src="app/vid/scripts/controller/previousVersionContoller.js"></script>
+<script src="app/vid/scripts/directives/extensionsDirective.js"></script>
+<script src="app/vid/scripts/directives/parameterBlockDirective.js"></script>
+<script src="app/vid/scripts/directives/popupWindowDirective.js"></script>
+<script src="app/vid/scripts/directives/progressBarDirective.js"></script>
+<script src="app/vid/scripts/services/aaiService.js"></script>
+<script src="app/vid/scripts/services/asdcService.js"></script>
+<script src="app/vid/scripts/services/componentService.js"></script>
+<script src="app/vid/scripts/services/creationService.js"></script>
+<script src="app/vid/scripts/services/dataService.js"></script>
+<script src="app/vid/scripts/services/deletionService.js"></script>
+<script src="app/vid/scripts/services/detailsService.js"></script>
+<script src="app/vid/scripts/services/statusService.js"></script>
+<script src="app/vid/scripts/services/msoService.js"></script>
+<script src="app/vid/scripts/services/propertyService.js"></script>
+<script src="app/vid/scripts/services/utilityService.js"></script>
+<script src="app/vid/scripts/services/vnfService.js"></script>
+
+<%@ page import="org.openecomp.vid.mso.*"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%
+ String properties = "{msoMaxPolls:" + SystemProperties.getProperty(MsoProperties.MSO_MAX_POLLS)
+ + ",msoMaxPollingIntervalMsec:"
+ + SystemProperties.getProperty(MsoProperties.MSO_POLLING_INTERVAL_MSECS) + "}";
+%>
+
+<div ng-controller="ServiceModelController"
+ ng-init="init(<%=properties%>);" ng-cloak>
+ <div ng-view></div>
+</div>
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/subscriberdetails.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/subscriberdetails.jsp
new file mode 100644
index 00000000..ca92b152
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/subscriberdetails.jsp
@@ -0,0 +1,184 @@
+<%@ include file="/WEB-INF/fusion/jsp/popup_modal.html" %>
+<div ng-controller="subscriberDetailsController">
+ <div>
+ <h1 class="heading1" style="margin-top:20px;">Selected Subscriber's Service Instance Details:</h1>
+ <div style="margin-top:30px">
+ <table att-table table-data="tableData">
+
+ <thead att-table-row type="header">
+ <tr>
+ <th att-table-header key="viewSubDetails">View/Edit</th>
+ <th att-table-header key="global-customer-id">Global Customer ID</th>
+ <th att-table-header key="subscriber-name">Subscriber Name</th>
+ <th att-table-header key="service-type">Service Type</th>
+ <th att-table-header key="service-instance-id">Service Instance ID</th>
+ </tr>
+ </thead>
+ <tbody att-table-row type="body" row-repeat="disData in displayData">
+ <tr>
+ <td att-table-body>
+ <div ng-controller="viewEditSubController">
+ <a href="#" ng-click="postsubscriberID(disData.subscriberName)" alt="View/Edit">
+ View/Edit
+ </a>
+ </div>
+ </td>
+ <td att-table-body >{{disData.globalCustomerId}}</td>
+ <td att-table-body >{{disData.subscriberName}}</td>
+ <td att-table-body >{{disData.serviceType}}</td>
+ <td att-table-body >{{disData.serviceInstanceId}}</td>
+ </tr>
+ </tbody>
+ </table>
+ </div>
+ </div>
+ <table><tr>
+ <td>
+ <div ng-controller="searchExistingSIController" align="left" >
+ <button type="submit" ng-click="cancelSubDetails();" att-button
+ btn-type="primary" size="small">Cancel</button>
+ </div>
+ </td></tr>
+
+ </table>
+
+</div>
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/25/2016 -->
+
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
+<script>
+app.controller("subscriberDetailsController", function ($scope,$http,modalService, $modal) {
+ $scope.tableData=${model.customerInfo};
+ $scope.displayData= [];
+ $scope.subscriberData=[];
+ $scope.serviceInstanceData= new Array();
+ $scope.globalcustomerid = $scope.tableData['global-customer-id'];
+ $scope.subscriberName = $scope.tableData['subscriber-name'];
+ $scope.subscriberData = $scope.tableData['service-subscriptions'];
+
+ $scope.setDisplaynoSTSI = function(){
+ $scope.displayData.push({
+ globalCustomerId : $scope.globalcustomerid,
+ subscriberName : $scope.subscriberName,
+ serviceType : "No Service Subscription Found",
+ serviceInstanceId : "No Service Instance Found"
+ });
+ }
+
+ $scope.setDisplaynoSI = function(servcType){
+ $scope.displayData.push({
+ globalCustomerId : $scope.globalcustomerid,
+ subscriberName : $scope.subscriberName,
+ serviceType : servcType,
+ serviceInstanceId : "No Service Instance Found"
+ });
+ }
+
+ if ($scope.subscriberData != null)
+ {
+ if ($scope.numberofSubscribers = $scope.subscriberData['service-subscription'] != null)
+ {
+ $scope.numberofSubscribers = $scope.subscriberData['service-subscription'].length;
+ if ($scope.numberofSubscribers > 0)
+ {
+ var index = 0;
+ for(i=0; i < $scope.numberofSubscribers; i++) {
+ $scope.serviceInstanceData[i] = new Array();
+ var servicesubscription = $scope.subscriberData['service-subscription'][i];
+ $scope.serviceInstanceData[i] = servicesubscription['service-instances'];
+ if ($scope.serviceInstanceData[i] != null)
+ {
+ if ($scope.serviceInstanceData[i]['service-instance'] != null)
+ {
+ var numberofserviceInstance = $scope.serviceInstanceData[i]['service-instance'].length;
+ if (numberofserviceInstance > 0)
+ {
+ for(j=0; j < numberofserviceInstance; j++)
+ {
+ $scope.displayData.push({
+ globalCustomerId : $scope.globalcustomerid,
+ subscriberName : $scope.subscriberName,
+ serviceType : servicesubscription['service-type'],
+ serviceInstanceId : $scope.serviceInstanceData[i]['service-instance'][j]['service-instance-id']
+ });
+ }
+ }
+ else
+ {
+ $scope.setDisplaynoSI(servicesubscription['service-type']);
+ }
+ }
+ else
+ {
+ $scope.setDisplaynoSI(servicesubscription['service-type']);
+ }
+ }
+ else
+ {
+ $scope.setDisplaynoSI(servicesubscription['service-type']);
+ }
+ }
+ }
+ else
+ {
+ $scope.setDisplaynoSTSI();
+ }
+ }
+ else
+ {
+ $scope.setDisplaynoSTSI();
+ }
+ }
+ else
+ {
+ $scope.setDisplaynoSTSI();
+ }
+
+
+});
+
+app.controller('viewEditSubController',['$scope','$http',function ($scope,$http) {
+
+ $scope.postsubscriberID = function(subID){
+ $.ajax({
+ url: "vieweditsub/subedit?"+"subscriberID="+encodeURIComponent(subID),
+ type : "POST",
+ success:function (response){
+ window.location.href = 'instantiate.htm';
+ },
+ error:function( jqXHR, status,error ){
+ $("#errorInfo").show();
+ }
+
+ });
+ }
+
+}]);
+
+app.controller('searchExistingSIController',['$scope','$http',function ($scope,$http) {
+
+ $scope.cancelSubDetails = function(selectedSubscriber){
+
+ window.location.href = 'searchexistingsi.htm';
+
+ }
+
+}]);
+</script>
+
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/testMso.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/testMso.jsp
new file mode 100644
index 00000000..abcc8e26
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/testMso.jsp
@@ -0,0 +1,174 @@
+<link rel="stylesheet" type="text/css" href="app/vid/test/testMso.css" />
+<script src="app/vid/test/testMso.js"></script>
+
+<link rel="stylesheet" type="text/css" href="app/vid/styles/dialogs.css" />
+
+<script src="app/vid/scripts/controller/msoCommitController.js"></script>
+<script src="app/vid/scripts/controller/detailsDialogController.js"></script>
+<script src="app/vid/scripts/controller/statusDialogController.js"></script>
+
+<script src="app/vid/scripts/services/dataService.js"></script>
+<script src="app/vid/scripts/services/detailsService.js"></script>
+<script src="app/vid/scripts/services/statusService.js"></script>
+<script src="app/vid/scripts/services/componentService.js"></script>
+<script src="app/vid/scripts/services/propertyService.js"></script>
+<script src="app/vid/scripts/services/msoService.js"></script>
+<script src="app/vid/scripts/services/utilityService.js"></script>
+
+<script src="app/vid/scripts/directives/extensionsDirective.js"></script>
+<script src="app/vid/scripts/directives/parameterBlockDirective.js"></script>
+<script src="app/vid/scripts/directives/popupWindowDirective.js"></script>
+<script src="app/vid/scripts/directives/progressBarDirective.js"></script>
+
+<script src="app/vid/scripts/constants/componentConstants.js"></script>
+<script src="app/vid/scripts/constants/fieldConstants.js"></script>
+<script src="app/vid/scripts/constants/parameterConstants.js"></script>
+
+<!--
+ Read configuration properties from server-side properties settings and
+ pass to the test controller via the ng-include onload event.
+
+ Consider / investigate replacing this approach with an alternative
+ REST / Angular mechanism.
+-->
+<%@ page import="org.openecomp.vid.mso.*"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%
+ String properties = "{msoMaxPolls:" + SystemProperties.getProperty(MsoProperties.MSO_MAX_POLLS)
+ + ",msoMaxPollingIntervalMsec:"
+ + SystemProperties.getProperty(MsoProperties.MSO_POLLING_INTERVAL_MSECS) + "}";
+%>
+
+<div ng-controller="testController" ng-init="init(<%=properties%>);"
+ ng-cloak>
+ <div popup-window class="popupContents" ngx-show="{{popup.isVisible}}"
+ ng-cloak>
+ <div ng-include="'app/vid/scripts/view-models/msoCommit.htm'"
+ onload="autoStartCommitTest();"></div>
+ <div ng-include="'app/vid/scripts/view-models/detailsDialog.htm'"
+ onload="autoStartQueryTest();"></div>
+ </div>
+
+ <h1 class="heading2">
+ <center>Various MSO Tests</center>
+ </h1>
+ <div>
+ <input type="checkbox" ng-change="testMsoModeChanged();"
+ ng-model="isTestMsoMode"></input> <span>Use test MSO
+ controller</span>
+ </div>
+ <div>
+ <h3>These actions are expected to return successfully.</h3>
+ <button type="button" ng-click="queryServiceInstance();" att-button
+ btn-type="primary" size="small">Query Service Instance</button>
+ <button type="button" ng-click="createServiceInstance();" att-button
+ btn-type="primary" size="small">Create Service Instance</button>
+ <button type="button" ng-click="deleteServiceInstance();" att-button
+ btn-type="primary" size="small">Delete Service Instance</button>
+ <button type="button" ng-click="createNetworkInstance();" att-button
+ btn-type="primary" size="small">Create Network Instance</button>
+ <button type="button" ng-click="deleteNetworkInstance();" att-button
+ btn-type="primary" size="small">Delete Network Instance</button>
+ <button type="button" ng-click="createVNFInstance();" att-button
+ btn-type="primary" size="small">Create VNF Instance</button>
+ <button type="button" ng-click="deleteVNFInstance();" att-button
+ btn-type="primary" size="small">Delete VNF Instance</button>
+ <button type="button" ng-click="createVolumeGroupInstance();"
+ att-button btn-type="primary" size="small">Create Volume
+ Group</button>
+ <button type="button" ng-click="deleteVolumeGroupInstance();"
+ att-button btn-type="primary" size="small">Delete Volume
+ Group</button>
+ <button type="button" ng-click="createVFModuleInstance();" att-button
+ btn-type="primary" size="small">Create VF Module</button>
+ <button type="button" ng-click="deleteVFModuleInstance();" att-button
+ btn-type="primary" size="small">Delete VF Module</button>
+ </div>
+ <hr />
+ <h3>These actions are expected to generate errors. These tests assume the above
+ "Use test MSO controller" checkbox is checked. All tests are base on the Create Service
+ Instance transaction.</h3>
+ <ol>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_POLICY_EXCEPTION');" att-button
+ btn-type="primary" size="small">Policy Exception</button> <span>Initial
+ response contains policy exception</span>
+ </li>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_SERVICE_EXCEPTION');" att-button
+ btn-type="primary" size="small">Service Exception</button> <span>Initial
+ response contains service exception</span>
+ </li>
+ <li>
+ <button type="button" ng-click="generateError('ERROR_POLL_FAILURE');"
+ att-button btn-type="primary" size="small">Poll Failure</button> <span>Subsequent
+ getOrchestrationRequest poll response contains MSO failure condition</span>
+ </li>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_INVALID_FIELD_INITIAL');" att-button
+ btn-type="primary" size="small">Initial Invalid</button> <span>Initial
+ response contains invalid data field</span>
+ </li>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_INVALID_FIELD_POLL');" att-button
+ btn-type="primary" size="small">Poll Invalid</button> <span>Subsequent
+ getOrchestrationRequest poll response contains invalid data field</span>
+ </li>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_GENERAL_SERVER_EXCEPTION');"
+ att-button btn-type="primary" size="small">Server Exception</button>
+ <span>VID controller code generates general exception</span>
+ </li>
+ <li>
+ <button type="button" ng-click="generateError('ERROR_MAX_POLLS');"
+ att-button btn-type="primary" size="small">Maximum Polls</button> <span>Maximum
+ poll attempts exceeded</span>
+ </li>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_SERVER_TIMEOUT_INITIAL');" att-button
+ btn-type="primary" size="small">Initial Timeout</button> <span>Timeout
+ on initial response</span>
+ </li>
+ <li>
+ <button type="button"
+ ng-click="generateError('ERROR_SERVER_TIMEOUT_POLL');" att-button
+ btn-type="primary" size="small">Poll Timeout</button> <span>Timeout
+ on subsequent getOrchestrationRequest poll response</span>
+ </li>
+ <li>
+ <button type="button" ng-click="generateInvalidUrl404();" att-button
+ btn-type="primary" size="small">Invalid URL (404)</button> <span>GUI
+ front-end specifies invalid URL - HTTP 404 response expected</span>
+ </li>
+ <li>
+ <button type="button" ng-click="generateInvalidUrl405();" att-button
+ btn-type="primary" size="small">Invalid URL (405)</button> <span>GUI
+ front-end specifies invalid URL - HTTP 405 response expected</span>
+ </li>
+ </ol>
+
+</div>
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/testViewEdit.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/testViewEdit.jsp
new file mode 100644
index 00000000..031fedf8
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/testViewEdit.jsp
@@ -0,0 +1,172 @@
+<link rel="stylesheet" type="text/css"
+ href="app/vid/test/testViewEdit.css" />
+
+<script src="app/vid/test/testAaiData.js"></script>
+<script src="app/vid/test/testViewEdit.js"></script>
+
+<link rel="stylesheet" type="text/css" href="app/vid/styles/dialogs.css" />
+
+<script src="app/vid/scripts/controller/creationDialogController.js"></script>
+<script src="app/vid/scripts/controller/deletionDialogController.js"></script>
+<script src="app/vid/scripts/controller/detailsDialogController.js"></script>
+<script src="app/vid/scripts/controller/statusDialogController.js"></script>
+<script src="app/vid/scripts/controller/msoCommitController.js"></script>
+
+<script src="app/vid/scripts/services/aaiService.js"></script>
+<script src="app/vid/scripts/services/asdcService.js"></script>
+<script src="app/vid/scripts/services/creationService.js"></script>
+<script src="app/vid/scripts/services/dataService.js"></script>
+<script src="app/vid/scripts/services/deletionService.js"></script>
+<script src="app/vid/scripts/services/detailsService.js"></script>
+<script src="app/vid/scripts/services/statusService.js"></script>
+<script src="app/vid/scripts/services/componentService.js"></script>
+<script src="app/vid/scripts/services/msoService.js"></script>
+<script src="app/vid/scripts/services/propertyService.js"></script>
+<script src="app/vid/scripts/services/utilityService.js"></script>
+
+<script src="app/vid/scripts/directives/extensionsDirective.js"></script>
+<script src="app/vid/scripts/directives/parameterBlockDirective.js"></script>
+<script src="app/vid/scripts/directives/popupWindowDirective.js"></script>
+<script src="app/vid/scripts/directives/progressBarDirective.js"></script>
+
+<script src="app/vid/scripts/constants/componentConstants.js"></script>
+<script src="app/vid/scripts/constants/fieldConstants.js"></script>
+<script src="app/vid/scripts/constants/parameterConstants.js"></script>
+
+<!--
+ Read configuration properties from server-side properties settings and
+ pass to the test controller via the ng-include onload event.
+
+ Consider / investigate replacing this approach with an alternative
+ REST / Angular mechanism.
+-->
+<%@ page import="org.openecomp.vid.mso.*"%>
+<%@ page import="org.openecomp.portalsdk.core.util.SystemProperties"%>
+<%
+ String properties = "{msoMaxPolls:" + SystemProperties.getProperty(MsoProperties.MSO_MAX_POLLS)
+ + ",msoMaxPollingIntervalMsec:"
+ + SystemProperties.getProperty(MsoProperties.MSO_POLLING_INTERVAL_MSECS) + "}";
+%>
+
+<div ng-controller="testViewEditController"
+ ng-init="init(<%=properties%>);" ng-cloak>
+
+ <div popup-window class="popupContents" ngx-show="{{popup.isVisible}}"
+ ng-cloak>
+ <div ng-include="'app/vid/scripts/view-models/creationDialog.htm'"></div>
+ <div ng-include="'app/vid/scripts/view-models/deletionDialog.htm'"></div>
+ <div ng-include="'app/vid/scripts/view-models/detailsDialog.htm'"
+ onload="autoStartTest();"></div>
+ </div>
+
+ <h1 class="heading2">
+ <center>Test View Edit Page</center>
+ </h1>
+ <hr />
+ These buttons simulate the add, delete and "show details" (called
+ "script" in User Stories) icons (or buttons) that are expected on the
+ view / edit page.
+ <hr />
+ <div>
+ <input type="checkbox" ng-change="testMsoModeChanged();"
+ ng-model="isTestMsoMode"></input> <span>Use test MSO
+ controller</span>
+ </div>
+ <h3 ng-style="callbackStyle">CALLBACK: {{callbackResults}}</h3>
+ <table>
+ <tr>
+ <td>Service</td>
+ <td>
+ <button type="button" ng-click="createService();" att-button
+ btn-type="primary" size="small">Add</button>
+ </td>
+ <td>
+ <button type="button" ng-click="deleteService();" att-button
+ btn-type="primary" size="small">Delete</button>
+ </td>
+ <td>
+ <button type="button" ng-click="showServiceDetails();" att-button
+ btn-type="primary" size="small">Show Details</button>
+ </td>
+ </tr>
+ <tr>
+ <td>VNF</td>
+ <td>
+ <button type="button" ng-click="createVnf();" att-button
+ btn-type="primary" size="small">Add</button>
+ </td>
+ <td>
+ <button type="button" ng-click="deleteVnf();" att-button
+ btn-type="primary" size="small">Delete</button>
+ </td>
+ <td>
+ <button type="button" ng-click="showVnfDetails();" att-button
+ btn-type="primary" size="small">Show Details</button>
+ </td>
+ </tr>
+ <tr>
+ <td>VF Module</td>
+ <td>
+ <button type="button" ng-click="createVfModule();" att-button
+ btn-type="primary" size="small">Add</button>
+ </td>
+ <td>
+ <button type="button" ng-click="deleteVfModule();" att-button
+ btn-type="primary" size="small">Delete</button>
+ </td>
+ <td>
+ <button type="button" ng-click="showVfModuleDetails();" att-button
+ btn-type="primary" size="small">Show Details</button>
+ </td>
+ </tr>
+ <tr>
+ <td>Volume Group</td>
+ <td>
+ <button type="button" ng-click="createVolumeGroup();" att-button
+ btn-type="primary" size="small">Add</button>
+ </td>
+ <td>
+ <button type="button" ng-click="deleteVolumeGroup();" att-button
+ btn-type="primary" size="small">Delete</button>
+ </td>
+ <td>
+ <button type="button" ng-click="showVolumeGroupDetails();"
+ att-button btn-type="primary" size="small">Show Details</button>
+ </td>
+ </tr>
+ <tr>
+ <td>Network</td>
+ <td>
+ <button type="button" ng-click="createNetwork();" att-button
+ btn-type="primary" size="small">Add</button>
+ </td>
+ <td>
+ <button type="button" ng-click="deleteNetwork();" att-button
+ btn-type="primary" size="small">Delete</button>
+ </td>
+ <td>
+ <button type="button" ng-click="showNetworkDetails();" att-button
+ btn-type="primary" size="small">Show Details</button>
+ </td>
+ </tr>
+ </table>
+</div>
+
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/viewlog.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/viewlog.jsp
new file mode 100644
index 00000000..920298e1
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/viewlog.jsp
@@ -0,0 +1,33 @@
+
+
+<div ng-controller="viewLogController">
+
+ <h1 class="heading1"><center>View Log - Page under Construction...</center></h1>
+ <br>
+
+
+</div>
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/jsp/welcome.jsp b/vid-app-common/src/test/resources/WEB-INF/jsp/welcome.jsp
new file mode 100644
index 00000000..dcd99689
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/jsp/welcome.jsp
@@ -0,0 +1,49 @@
+
+<div>
+ <h1 class="heading1">AT&T Domain 2.0 Network</h1>
+ <br>
+ <h1 class="heading1"><u>Welcome to VID</u></h1>
+ <br>
+ The Virtual Infrastructure Deployment (VID) application allows infrastructure service deployment operators
+ to instantiate service instances and their constituent parts for Distributed service models required by the
+ internal AT&T service operations organizations that manage them, such as Mobility Network Services,
+ Netbond Services, or FlexReach Services. The models are defined by ECOMP component ASDC. The service
+ deployment operator selects the service operations owner and model that they wish to instantiate. After
+ entry of appropriate data, the operator instructs VID to direct another ECOMP component, MSO, to instantiate
+ the selected service model. Once the service instance has been instantiated, the service operator can instruct
+ VID to direct MSO to instantiate the service instance's component VNFs, VF Modules, Networks and Volume Groups.
+ The VID user can also search for, and display, existing service instances and direct the instantiation of
+ subsequent instance components.
+ <br><br>
+ <h1 class="heading1"><u>About VID</u></h1>
+ VID was originally developed for the October 2016 release by an integrated IT and Labs team, under the
+ direction of Steve Smokowski and Vivian Pressley.
+ <br><br>
+ <h1 class="heading1"><a href="mailto:DL-VIDDeliveryTeam@att.com" target="_top">Contact Us</a></h1>
+ <a href="mailto:DL-VIDDeliveryTeam@att.com" target="_top">Please click here to contact us.</a>
+
+
+
+<BR>
+
+
+
+</div>
+<!-- Temporary solution for footer overlapping the men after talking to EComp SDK developer on 06/16/2016 -->
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+
+
diff --git a/vid-app-common/src/test/resources/WEB-INF/web.xml b/vid-app-common/src/test/resources/WEB-INF/web.xml
new file mode 100644
index 00000000..273544d6
--- /dev/null
+++ b/vid-app-common/src/test/resources/WEB-INF/web.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_5.xsd" version="2.5">
+
+ <display-name>ecomp-sdk-app-att</display-name>
+ <distributable/>
+ <session-config>
+ <session-timeout>7</session-timeout>
+ <tracking-mode>COOKIE</tracking-mode>
+ </session-config>
+</web-app> \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/pnf.csar b/vid-app-common/src/test/resources/pnf.csar
new file mode 100644
index 00000000..eb424846
--- /dev/null
+++ b/vid-app-common/src/test/resources/pnf.csar
Binary files differ
diff --git a/vid-app-common/src/test/resources/roles.json b/vid-app-common/src/test/resources/roles.json
new file mode 100644
index 00000000..159be82f
--- /dev/null
+++ b/vid-app-common/src/test/resources/roles.json
@@ -0,0 +1,8 @@
+{
+ "roles": [
+ "VID_Subscriber_serviceType1_Tenant1",
+ "VID_Subscriber_serviceType1_Tenant2",
+ "read_motorola_epost_tow",
+ "read_motorola_epost"
+ ]
+} \ No newline at end of file
diff --git a/vid-app-common/src/test/resources/vf-csar.JSON b/vid-app-common/src/test/resources/vf-csar.JSON
index bd1a0193..097b319a 100644
--- a/vid-app-common/src/test/resources/vf-csar.JSON
+++ b/vid-app-common/src/test/resources/vf-csar.JSON
@@ -4,6 +4,9 @@
"service": {
"category": "Mobility",
"description": "Bla bla",
+ "serviceRole":"null",
+ "serviceType":"null",
+
"inputs": {
"greatdefect0_availability_zone_max_count": {
"constraints": [
@@ -38,7 +41,7 @@
"serviceEcompNaming": "true",
"toscaModelURL": null,
"uuid": "48a52540-8772-4368-9cdb-1f124ea5c931",
- "version": "1.0"
+ "version": "0.1"
},
"vfModules": {
"greatdefect0..Greatdefect..base_ixla..module-0": {
diff --git a/vid-app-common/src/test/resources/vl-csar.JSON b/vid-app-common/src/test/resources/vl-csar.JSON
index ce1f1b79..78f6a63d 100644
--- a/vid-app-common/src/test/resources/vl-csar.JSON
+++ b/vid-app-common/src/test/resources/vl-csar.JSON
@@ -34,7 +34,7 @@
"constraints": [
],
"default": null,
- "description": "Reference to naming policy that ECOMP will use when the name is auto-generated",
+ "description": "Unique label that defines the role that this network performs. example: vce oam network, vnat sr-iov1 network\n",
"entry_schema": null,
"required": true,
"type": "string"
@@ -43,7 +43,7 @@
"constraints": [
],
"default": null,
- "description": "Reference to naming policy that ECOMP will use when the name is auto-generated",
+ "description": "Uniquely identifies the network scope. Valid values for the network scope includes: VF - VF-level network. Intra-VF network which connects the VFCs (VMs) inside the VF. SERVICE - Service-level network. Intra-Service network which connects the VFs within the service GLOBAL - Global network which can be shared by multiple services\n",
"entry_schema": null,
"required": true,
"type": "string"
@@ -64,6 +64,8 @@
"service": {
"category": "Network L1-3",
"description": "dsfg",
+ "serviceRole":"null",
+ "serviceType":"null",
"inputs": {
"extvl0_exVL_naming_naming_policy": {
"constraints": [
@@ -98,7 +100,7 @@
"serviceEcompNaming": "true",
"toscaModelURL": null,
"uuid": "68101369-6f08-4e99-9a28-fa6327d344f3",
- "version": "1.0"
+ "version": "0.1"
},
"vfModules": {
},