Repository: ignite Updated Branches: refs/heads/ignite-1.6 a284d053c -> eb5ac0ae5
http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/settings/profile.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/settings/profile.jade b/modules/web-console/src/main/js/views/settings/profile.jade new file mode 100644 index 0000000..355d232 --- /dev/null +++ b/modules/web-console/src/main/js/views/settings/profile.jade @@ -0,0 +1,76 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +mixin lbl(txt) + label.col-sm-2.required.labelFormField #{txt} + +.row(ng-controller='profileController') + .docs-content.greedy + .docs-header + h1 User profile + hr + .docs-body + form.form-horizontal(name='profileForm' novalidate) + .col-sm-10(style='padding: 0') + .details-row + +lbl('First name:') + .col-xs-5.col-sm-4 + input#profile-firstname.form-control(type='text' ng-model='user.firstName' placeholder='Input first name' required auto-focus) + .details-row + +lbl('Last name:') + .col-xs-5.col-sm-4 + input#profile-lastname.form-control(type='text' ng-model='user.lastName' placeholder='Input last name' required) + .details-row + +lbl('Email:') + .col-xs-5.col-sm-4 + input#profile-email.form-control(type='email' ng-model='user.email' placeholder='Input email' required) + .details-row + +lbl('Company:') + .col-xs-5.col-sm-4 + input#profile-company.form-control(type='text' ng-model='user.company' placeholder='Input company name' required) + .details-row + +lbl('Country:') + .col-xs-5.col-sm-4 + button#profile-country.select-toggle.form-control(bs-select bs-options='item.name as item.name for item in countries' type='text' ng-model='user.country' placeholder='Choose your country' required) + .details-row + .advanced-options + i.fa( + ng-click='expandedToken = !expandedToken' + ng-class='expandedToken ? "fa-chevron-circle-down" : "fa-chevron-circle-right"') + a(ng-click='expandedToken = !expandedToken') {{expandedToken ? 'Cancel security token changing...' : 'Show security token...'}} + div(ng-if='expandedToken') + +lbl('Security token:') + label(ng-init='user.token = $root.user.token') {{user.token || 'No security token. Regenerate please.'}} + i.tipLabel.fa.fa-refresh(ng-click='generateToken()' bs-tooltip='' data-title='Generate random security token') + i.tipLabel.fa.fa-clipboard(ng-click-copy='{{user.token}}' bs-tooltip='' data-title='Copy security token to clipboard') + i.tipLabel.fa.fa-question-circle(ng-if=lines bs-tooltip='' data-title='The security token is used for authorization of web agent') + .details-row + .advanced-options + i.fa( + ng-click='expandedPassword = !expandedPassword' + ng-class='expandedPassword ? "fa-chevron-circle-down" : "fa-chevron-circle-right"') + a(ng-click='expandedPassword = !expandedPassword') {{expandedPassword ? 'Cancel password changing...' : 'Change password...'}} + div(ng-if='expandedPassword') + .details-row + +lbl('New password:') + .col-xs-5.col-sm-4 + input.form-control(ng-init='user.password=null' type='password' ng-model='user.password' placeholder='New password') + .details-row + +lbl('Confirm:') + .col-xs-5.col-sm-4 + input.form-control(ng-init='user.confirm=null' type='password' ng-model='user.confirm' match='user.password' placeholder='Confirm new password') + .col-xs-12.col-sm-12.details-row + a.btn.btn-primary(ng-disabled='!profileCouldBeSaved()' ng-click='profileCouldBeSaved() && saveUser()' bs-tooltip='' data-title='{{saveBtnTipText()}}' data-placement='bottom' data-trigger='hover') Save http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/signin.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/signin.jade b/modules/web-console/src/main/js/views/signin.jade new file mode 100644 index 0000000..7c25a5a --- /dev/null +++ b/modules/web-console/src/main/js/views/signin.jade @@ -0,0 +1,159 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +mixin lblRequired(txt) + label.col-xs-3.col-md-3.required #{txt} + +header#header.header + table.container + tr + td.col-xs-3.col-sm-3.col-md-2 + ignite-header-logo + td + ignite-header-title + +.container.body-container + .main-content(ng-controller='auth') + .row.home + .signin-greedy + .col-xs-12.col-md-6 + form(name='form' novalidate) + .modal-body.row(style='padding: 0 0 10px 0; margin: 0') + .settings-row(ng-if='action == "signup"') + h3.login-header Sign Up + .settings-row(ng-if='action == "signin"') + h3.login-header Sign In + .settings-row(ng-if='action == "password/forgot"') + h3.login-header Forgot password? + .settings-row + p.col-xs-12.col-md-11(ng-show='action == "password/forgot"') + | That's ok! Simply enter your email below and a reset password link will be sent to you via email. You can then follow that link and select a new password. + .settings-row(ng-show='action == "signup"') + +lblRequired('First Name:') + .col-xs-9.col-md-8 + input#first_name.form-control(enter-focus-next='last_name' type='text' ng-model='ui.firstName' placeholder='Input first name' ng-required='action=="signup"') + .settings-row(ng-show='action == "signup"') + +lblRequired('Last Name:') + .col-xs-9.col-md-8 + input#last_name.form-control(enter-focus-next='email' type='text' ng-model='ui.lastName' placeholder='Input last name' ng-required='action=="signup"') + .settings-row(ng-show='action != "signup"') + +lblRequired('Email:') + .col-xs-9.col-md-8 + input#signin_email.form-control(enter-focus-next='company' type='email' ng-model='ui.email' placeholder='Input email' required) + .settings-row(ng-show='action == "signup"') + +lblRequired('Email:') + .col-xs-9.col-md-8 + input#signup_email.form-control(enter-focus-next='company' type='email' ng-model='ui.email' placeholder='Input email' required) + .settings-row(ng-show='action == "signup"') + +lblRequired('Company:') + .col-xs-9.col-md-8 + input#company.form-control(enter-focus-next='country' type='search' ng-model='ui.company' placeholder='Input company name' ng-required='action=="signup"') + .settings-row(ng-show='action == "signup"') + +lblRequired('Country:') + .col-xs-9.col-md-8 + button#country.select-toggle.form-control(bs-select bs-options='item.name as item.name for item in countries' enter-focus-next='user_password' type='search' ng-model='ui.country' placeholder='Choose your country' ng-required='action=="signup"') + .settings-row(ng-show='action != "password/forgot"') + +lblRequired('Password:') + .col-xs-9.col-md-8 + input#user_password.form-control(enter-focus-next='user_confirm' type='password' ng-model='ui.password' placeholder='Password' ng-required='action != "password/forgot"' on-enter='action == "signin" && form.$valid && auth(action, ui)') + .settings-row(ng-if='action == "signup"') + +lblRequired('Confirm:') + .col-xs-9.col-md-8 + input#user_confirm.form-control(type='password' ng-model='ui_exclude.confirm' match='ui.password' placeholder='Confirm password' ng-required='action == "signup"' on-enter='form.$valid && auth(action, ui)') + .settings-row(ignite-terms) + .col-md-offset-3(ng-if='action == "signup" && terms.termsState') + label + input(type='checkbox' ng-model='ui_exclude.agree', ng-required='true') + | I agree to the #[a(ui-sref='{{::terms.termsState}}' target='_blank') terms and conditions] + .col-xs-12.col-md-11 + .login-footer(ng-show='action == "signup"') + a.labelField(ng-click='action = "password/forgot"' on-click-focus='email') Forgot password? + a.labelLogin(ng-click='action = "signin"' on-click-focus='email') Sign In + button#signup.btn.btn-primary(ng-click='auth(action, ui)' ng-disabled='form.$invalid') Sign Up + .col-xs-12.col-md-11 + .login-footer(ng-show='action == "password/forgot"') + a.labelField(ng-click='action = "signin"' on-click-focus='email') Sign In + button#forgot.btn.btn-primary(ng-click='auth(action, ui)' ng-disabled='form.$invalid') Send it to me + .col-xs-12.col-md-11 + .login-footer(ng-show='action == "signin"') + a.labelField(ng-click='action = "password/forgot"' on-click-focus='email') Forgot password? + a.labelLogin(ng-click='action = "signup"' on-click-focus='user_name') Sign Up + button#login.btn.btn-primary(ng-click='auth(action, ui)' ng-disabled='form.$invalid') Sign In + + .col-xs-12.col-md-11.home-panel + ignite-features + .col-xs-12.col-md-6 + #carousel.carousel.slide + // Indicators + ol.carousel-indicators + li.active(data-target='#carousel', data-slide-to='0') + li(data-target='#carousel', data-slide-to='1') + li(data-target='#carousel', data-slide-to='2') + li(data-target='#carousel', data-slide-to='3') + li(data-target='#carousel', data-slide-to='4') + li(data-target='#carousel', data-slide-to='5') + li(data-target='#carousel', data-slide-to='6') + // Wrapper for slides + .carousel-inner(role='listbox') + .item.active + img(src='/images/cluster.png', alt='Clusters screen') + .carousel-caption + h3 Clusters screen + p Configure clusters, link clusters to caches + .item + img(src='/images/cache.png', alt='Caches screen') + .carousel-caption + h3 Caches screen + p Configure caches, link domain models to caches, link caches to clusters + .item + img(src='/images/domains.png', alt='Domain model screen') + .carousel-caption + h3 Domain model screen + p Manually enter domain model or import from database + .item + img(src='/images/summary.png', alt='Summary screen') + .carousel-caption + h3 Summary screen + p Preview XML config, JAVA code,Docker file and download project + .item + img(src='/images/query-table.png', alt='Query') + .carousel-caption + h3 Query + p Explain SQL, execute, scan queries + .item + img(src='/images/query-metadata.png', alt='Cache metadata') + .carousel-caption + h3 Cache metadata + p View cache type metadata + .item + img(src='/images/query-chart.png', alt='Query chart') + .carousel-caption + h3 Query chart + p View data in tabular form and as charts + // Controls + a.left.carousel-control(href='#carousel', role='button', data-slide='prev') + span.fa.fa-chevron-left(aria-hidden='true') + span.sr-only Previous + a.right.carousel-control(href='#carousel', role='button', data-slide='next') + span.fa.fa-chevron-right(aria-hidden='true') + span.sr-only Next + +include includes/footer + +script. + $('.carousel').carousel() + + http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/sql/cache-metadata.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/sql/cache-metadata.jade b/modules/web-console/src/main/js/views/sql/cache-metadata.jade new file mode 100644 index 0000000..40b7a6b --- /dev/null +++ b/modules/web-console/src/main/js/views/sql/cache-metadata.jade @@ -0,0 +1,40 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. +.popover.cache-metadata(tabindex='-1' ignite-loading='loadingCacheMetadata' ignite-loading-text='Loading metadata...' ng-init='importMetadata()') + h3.popover-title + label.labelField Metadata for caches: + button.close(id='cache-metadata-close' ng-click='$hide()') × + .input-tip + input.form-control(type='text' ng-model='metaFilter' placeholder='Filter metadata...') + .popover-content(ng-if='metadata && metadata.length > 0') + treecontrol.tree-classic(tree-model='metadata' options='metaOptions' filter-expression='metaFilter') + span(ng-switch='' on='node.type') + span(ng-switch-when='type' ng-dblclick='dblclickMetadata(paragraph, node)') + i.fa.fa-table + label.clickable(ng-bind-html='node.displayMame') + span(ng-switch-when='plain') + label {{node.name}} + span(ng-switch-when='field' ng-dblclick='dblclickMetadata(paragraph, node)') + i.fa(ng-class='node.system ? "fa-file-text-o" : "fa-file-o"') + label.clickable {{node.name}} [{{node.clazz}}] + label(ng-switch-when='indexes') {{node.name}} + label(ng-switch-when='index') {{node.name}} + span(ng-switch-when='index-field' ng-dblclick='dblclickMetadata(paragraph, node)') + i.fa(ng-class='node.order ? "fa-sort-amount-desc" : "fa-sort-amount-asc"') + label.clickable {{node.name}} + .popover-content(ng-if='!metadata || metadata.length == 0') + label.content-empty No types found + h3.popover-footer Double click to paste into editor http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/sql/chart-settings.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/sql/chart-settings.jade b/modules/web-console/src/main/js/views/sql/chart-settings.jade new file mode 100644 index 0000000..5a1ceed --- /dev/null +++ b/modules/web-console/src/main/js/views/sql/chart-settings.jade @@ -0,0 +1,40 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.popover.settings(tabindex='-1' style='width: 300px') + .arrow + h3.popover-title(style='color: black') Chart settings + button.close(id='chart-settings-close' ng-click='$hide()') × + .popover-content + form.form-horizontal.chart-settings(name='chartSettingsForm' novalidate) + .form-group.chart-settings + -var btnClass = 'col.value < 0 ? "btn-success" : "btn-default"' + + label All columns (drag columns to axis) + ul.chart-settings-columns-list(dnd-list='paragraph.chartColumns' dnd-allowed-types='[]') + li(ng-repeat='col in paragraph.chartColumns track by $index') + .btn.btn-default.btn-chart-column-movable(ng-class=btnClass dnd-draggable='col' dnd-effect-allowed='copy') {{col.label}} + label X axis (accept only one column) + ul.chart-settings-columns-list(dnd-list='paragraph.chartKeyCols' dnd-drop='chartAcceptKeyColumn(paragraph, item)') + li(ng-repeat='col in paragraph.chartKeyCols track by $index') + .btn.btn-default.btn-chart-column(ng-class=btnClass) {{col.label}} + i.fa.fa-close(ng-click='chartRemoveKeyColumn(paragraph, $index)') + label Y axis (accept only numeric columns) + ul.chart-settings-columns-list(dnd-list='paragraph.chartValCols' dnd-drop='chartAcceptValColumn(paragraph, item)') + li(ng-repeat='col in paragraph.chartValCols track by $index') + .btn.btn-default.btn-chart-column(ng-style='chartColor($index)') {{col.label}} + button.btn-chart-column-agg-fx.select-toggle(ng-change='applyChartSettings(paragraph)' ng-show='paragraphTimeSpanVisible(paragraph)' ng-style='chartColor($index)' ng-model='col.aggFx' placeholder='...' bs-select bs-options='item for item in aggregateFxs' data-container='false' tabindex='-1') + i.fa.fa-close(ng-click='chartRemoveValColumn(paragraph, $index)') http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/sql/notebook-new.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/sql/notebook-new.jade b/modules/web-console/src/main/js/views/sql/notebook-new.jade new file mode 100644 index 0000000..2a50137 --- /dev/null +++ b/modules/web-console/src/main/js/views/sql/notebook-new.jade @@ -0,0 +1,31 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal(tabindex='-1' role='dialog') + .modal-dialog + .modal-content + .modal-header + button.close(ng-click='$hide()') × + h4.modal-title New SQL notebook + form.form-horizontal.modal-body.row(name='ui.inputForm' novalidate) + div + .col-sm-2 + label.required.labelFormField Name: + .col-sm-10 + input.form-control(id='create-notebook' type='text' ng-model='name' required on-enter='ui.inputForm.$valid && createNewNotebook(name)' auto-focus) + .modal-footer + button.btn.btn-default(id='copy-btn-cancel' ng-click='$hide()') Cancel + button.btn.btn-primary(id='copy-btn-confirm' ng-disabled='ui.inputForm.$invalid' ng-click='createNewNotebook(name)') Create http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/sql/paragraph-rate.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/sql/paragraph-rate.jade b/modules/web-console/src/main/js/views/sql/paragraph-rate.jade new file mode 100644 index 0000000..f6f105f --- /dev/null +++ b/modules/web-console/src/main/js/views/sql/paragraph-rate.jade @@ -0,0 +1,31 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.popover.settings(tabindex='-1' style='width: 200px') + .arrow + h3.popover-title(style='color: black') Refresh rate + button.close(id='paragraph-rate-close' ng-click='$hide()') × + .popover-content + form(name='popoverForm' novalidate) + .form-group(style='padding: 5px') + .col-sm-4 + input.form-control(id='paragraph-rate' ng-init='value = paragraph.rate.value' ng-model='value' type='number' min='1' required auto-focus) + .col-sm-8(style='padding-left: 5px') + button.form-control.select-toggle(id='paragraph-unit' ng-init='unit = paragraph.rate.unit' ng-model='unit' required placeholder='Time unit' bs-select bs-options='item.value as item.label for item in timeUnit' data-container='false' tabindex='0') + .form-actions(style='margin-top: 30px; padding: 5px') + button.btn.btn-primary(id='paragraph-rate-start' ng-disabled='popoverForm.$invalid' ng-click='startRefresh(paragraph, value, unit); $hide()') Start + button.btn.btn-primary.btn-default(id='paragraph-rate-stop' ng-click='stopRefresh(paragraph); $hide()' ng-disabled='!paragraph.rate.installed') Stop + http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/sql/sql.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/sql/sql.jade b/modules/web-console/src/main/js/views/sql/sql.jade new file mode 100644 index 0000000..5eade69 --- /dev/null +++ b/modules/web-console/src/main/js/views/sql/sql.jade @@ -0,0 +1,180 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +mixin btn-toolbar(btn, click, tip, focusId) + i.btn.btn-default.fa(class=btn ng-click=click bs-tooltip='' data-title=tip on-click-focus=focusId data-trigger='hover' data-placement='bottom') + +mixin btn-toolbar-data(btn, kind, tip) + i.btn.btn-default.fa(class=btn ng-click='setResult(paragraph, "#{kind}")' ng-class='{active: resultEq(paragraph, "#{kind}")}' bs-tooltip='' data-title=tip data-trigger='hover' data-placement='bottom') + +mixin result-toolbar + .btn-group(ng-model='paragraph.result' ng-click='$event.stopPropagation()' style='left: 50%; margin: 0 0 0 -70px;display: block;') + +btn-toolbar-data('fa-table', 'table', 'Show data in tabular form') + +btn-toolbar-data('fa-bar-chart', 'bar', 'Show bar chart<br/>By default first column - X values, second column - Y values<br/>In case of one column it will be treated as Y values') + +btn-toolbar-data('fa-pie-chart', 'pie', 'Show pie chart<br/>By default first column - pie labels, second column - pie values<br/>In case of one column it will be treated as pie values') + +btn-toolbar-data('fa-line-chart', 'line', 'Show line chart<br/>By default first column - X values, second column - Y values<br/>In case of one column it will be treated as Y values') + +btn-toolbar-data('fa-area-chart', 'area', 'Show area chart<br/>By default first column - X values, second column - Y values<br/>In case of one column it will be treated as Y values') + +mixin chart-settings(mdl) + .row + .col-xs-4 + .chart-settings-link(ng-show='paragraph.chart && paragraph.chartColumns.length > 0') + a(title='Click to show chart settings dialog' ng-click='$event.stopPropagation()' bs-popover data-template-url='/sql/chart-settings.html' data-placement='bottom' data-auto-close='1' data-trigger='click') + i.fa.fa-bars + | Chart settings + div(ng-show='paragraphTimeSpanVisible(paragraph)') + label Show + button.select-manual-caret.btn.btn-default(ng-model='paragraph.timeLineSpan' ng-change='applyChartSettings(paragraph)' bs-options='item for item in timeLineSpans' bs-select data-caret-html='<span class="caret"></span>') + label min + .col-xs-4 + +result-toolbar + +.row(ng-controller='sqlController') + .docs-content + .row(ng-if='notebook' bs-affix style='margin-bottom: 20px;') + .docs-header.notebook-header + h1.col-sm-6(ng-hide='notebook.edit') + label(style='max-width: calc(100% - 60px)') {{notebook.name}} + .btn-group(ng-if='!demo') + +btn-toolbar('fa-pencil', 'notebook.edit = true;notebook.editName = notebook.name', 'Rename notebook') + +btn-toolbar('fa-trash', 'removeNotebook()', 'Remove notebook') + h1.col-sm-6(ng-show='notebook.edit') + i.btn.fa.fa-floppy-o(ng-show='notebook.editName' ng-click='renameNotebook(notebook.editName)' bs-tooltip data-title='Save notebook name' data-trigger='hover') + .input-tip + input.form-control(ng-model='notebook.editName' required on-enter='renameNotebook(notebook.editName)' on-escape='notebook.edit = false;') + h1.pull-right + a.dropdown-toggle(data-toggle='dropdown' bs-dropdown='scrollParagraphs' data-placement='bottom-right') Scroll to query + span.caret + .btn-group(style='margin-top: 2px') + +btn-toolbar('fa-plus', 'addParagraph()', 'Add new query') + + ignite-information(data-title='With SQL notebook you can' style='margin-top: 0; margin-bottom: 30px') + ul + li Create any number of queries + li Execute and explain SQL queries + li Execute scan queries + li View data in tabular form and as charts + + div(ng-if='notebookLoadFailed' style='text-align: center') + h2 Failed to load notebook + label.col-sm-12 Notebook not accessible any more. Go back to configuration or open to another notebook. + button.h3.btn.btn-primary(ui-sref='base.configuration.clusters') Back to configuration + div(ng-if='notebook' ignite-loading='sqlLoading' ignite-loading-text='{{ loadingText }}' ignite-loading-position='top') + .docs-body.paragraphs + .panel-group(bs-collapse ng-model='notebook.expandedParagraphs' data-allow-multiple='true' data-start-collapsed='false') + .panel.panel-default(ng-repeat='paragraph in notebook.paragraphs') + .panel-heading(id='{{paragraph.id}}' bs-collapse-toggle) + .row + .col-sm-6(ng-hide='paragraph.edit') + i.tipLabel.fa(ng-class='paragraphExpanded(paragraph) ? "fa-chevron-circle-down" : "fa-chevron-circle-right"') + label {{paragraph.name}} + + .btn-group(ng-hide='notebook.paragraphs.length > 1') + +btn-toolbar('fa-pencil', 'paragraph.edit = true; paragraph.editName = paragraph.name; $event.stopPropagation();', 'Rename query', 'paragraph-name-{{paragraph.id}}') + + .btn-group(ng-show='notebook.paragraphs.length > 1' ng-click='$event.stopPropagation();') + +btn-toolbar('fa-pencil', 'paragraph.edit = true; paragraph.editName = paragraph.name;', 'Rename query', 'paragraph-name-{{paragraph.id}}') + +btn-toolbar('fa-remove', 'removeParagraph(paragraph)', 'Remove query') + + .col-sm-6(ng-show='paragraph.edit') + i.tipLabel.fa(style='float: left;' ng-class='paragraphExpanded(paragraph) ? "fa-chevron-circle-down" : "fa-chevron-circle-right"') + i.tipLabel.fa.fa-floppy-o(style='float: right;' ng-show='paragraph.editName' ng-click='renameParagraph(paragraph, paragraph.editName); $event.stopPropagation();' bs-tooltip data-title='Save query name' data-trigger='hover') + .input-tip + input.form-control(id='paragraph-name-{{paragraph.id}}' ng-model='paragraph.editName' required ng-click='$event.stopPropagation();' on-enter='renameParagraph(paragraph, paragraph.editName)' on-escape='paragraph.edit = false') + .panel-collapse(role='tabpanel' bs-collapse-target) + .col-sm-12 + .col-xs-8.col-sm-9(style='border-right: 1px solid #eee') + .sql-editor(ignite-ace='{onLoad: aceInit(paragraph), theme: "chrome", mode: "sql", require: ["ace/ext/language_tools"],' + + 'advanced: {enableSnippets: false, enableBasicAutocompletion: true, enableLiveAutocompletion: true}}' + ng-model='paragraph.query') + .col-xs-4.col-sm-3 + div(ng-show='caches.length > 0' style='padding: 5px 10px' st-table='displayedCaches' st-safe-src='caches') + lable.labelField.labelFormField Caches: + i.fa.fa-database.tipField(title='Click to show cache types metadata dialog' bs-popover data-template-url='/sql/cache-metadata.html', data-placement='bottom', data-trigger='click') + .input-tip + input.form-control(type='text' st-search='name' placeholder='Filter caches...') + table.links + tbody.scrollable-y(style='max-height: 15em;display:block;' ng-model='paragraph.cacheName' bs-radio-group) + tr(ng-repeat='cache in displayedCaches track by cache.name') + td(style='width: 100%') + input.labelField(type='radio' value='{{cache.name}}') + label(ng-bind-html='maskCacheName(cache.name)') + .empty-caches(ng-show='displayedCaches.length == 0 && caches.length != 0') + label Wrong caches filter + .empty-caches(ng-show='caches.length == 0') + label No caches + .col-sm-12 + hr(style='margin: 0') + .col-sm-12 + .sql-controls + a.btn.btn-primary(ng-disabled='!actionAvailable(paragraph, true)' ng-click='actionAvailable(paragraph, true) && execute(paragraph)' data-placement='bottom' bs-tooltip data-title='{{actionTooltip(paragraph, "execute", true)}}') Execute + a.btn.btn-primary(ng-disabled='!actionAvailable(paragraph, true)' ng-click='actionAvailable(paragraph, true) && explain(paragraph)' data-placement='bottom' bs-tooltip data-title='{{actionTooltip(paragraph, "explain", true)}}') Explain + a.btn.btn-primary(ng-disabled='!actionAvailable(paragraph, false)' ng-click='actionAvailable(paragraph, false) && scan(paragraph)' data-placement='bottom' bs-tooltip data-title='{{actionTooltip(paragraph, "execute scan", false)}}') Scan + .pull-right + labelHide System columns: + a.btn.btn-default.fa.fa-bars.tipLabel(ng-class='{"btn-info": paragraph.systemColumns}' ng-click='toggleSystemColumns(paragraph)' ng-disabled='paragraph.disabledSystemColumns' bs-tooltip data-title='Show "_KEY", "_VAL" columns') + label.tipLabel Refresh rate: + button.btn.btn-default.fa.fa-clock-o.tipLabel(title='Click to show refresh rate dialog' ng-class='{"btn-info": paragraph.rate && paragraph.rate.installed}' bs-popover data-template-url='/sql/paragraph-rate.html' data-placement='left' data-auto-close='1' data-trigger='click') {{rateAsString(paragraph)}} + label.tipLabel Page size: + button.select-toggle.fieldButton.btn.btn-default(ng-model='paragraph.pageSize' bs-options='item for item in pageSizes' bs-select bs-tooltip data-title='Max number of rows to show in query result as one page') + .col-sm-12.sql-error-result(ng-show='paragraph.errMsg') Error: {{paragraph.errMsg}} + .col-sm-12(ng-show='!paragraph.errMsg && paragraph.result != "none"') + hr(style='margin-top: 0; margin-bottom: 10px') + .sql-empty-result(ng-show='!paragraph.nonEmpty()') Result set is empty + div(ng-show='paragraph.table() && paragraph.nonEmpty()') + .sql-table-total.row + .col-xs-4 + label Page # + b {{paragraph.page}} + label Results so far: + b {{paragraph.rows.length + paragraph.total}} + .col-xs-4 + +result-toolbar + .col-xs-4 + .btn-group.pull-right(ng-disabled='paragraph.loading') + button.btn.btn-primary.fieldButton(ng-click='exportCsv(paragraph)' bs-tooltip data-title='{{actionTooltip(paragraph, "export", false)}}') Export + button.btn.btn-primary(id='export-item-dropdown' data-toggle='dropdown' data-container='body' bs-dropdown='exportDropdown' data-placement='bottom-right') + span.caret + .grid(ui-grid='paragraph.gridOptions' ui-grid-auto-resize ui-grid-exporter ng-style='{ height: paragraph.gridOptions.height }') + div(ng-show='paragraph.chart() && paragraph.nonEmpty()') + div(ng-show='paragraph.queryExecuted()') + +chart-settings + div(ng-show='paragraph.chartColumns.length > 0 && !paragraph.chartColumnsConfigured()') + .sql-empty-result Cannot display chart. Please configure axis using #[b Chart settings] + div(ng-show='paragraph.chartColumns.length == 0') + .sql-empty-result Cannot display chart. Result set must contain Java build-in type columns. Please change query and execute it again. + div(ng-show='paragraph.chartColumnsConfigured()') + div(ng-show='paragraph.timeLineSupported() || !paragraph.chartTimeLineEnabled()') + div(ng-repeat='chart in paragraph.charts') + nvd3(options='chart.options' data='chart.data' api='chart.api') + .sql-empty-result(ng-show='!paragraph.timeLineSupported() && paragraph.chartTimeLineEnabled()') Pie chart does not support 'TIME_LINE' column for X-axis. Please use another column for X-axis or switch to another chart. + .sql-empty-result(ng-hide='paragraph.queryExecuted()') + .row + .col-xs-4.col-xs-offset-4 + +result-toolbar + label.margin-top-dflt Charts do not support  + b Explain + | and + b Scan + | query + div(ng-show='paragraph.queryArgs && !paragraph.refreshExecuting()') + -var nextVisibleCondition = 'paragraph.queryId && (paragraph.table() || paragraph.chart() && paragraph.queryExecute() && (paragraph.timeLineSupported() || !paragraph.chartTimeLineEnabled()))' + + hr(style='margin-top: 0; margin-bottom: 5px') + a(style='float: left; margin-left: 10px; margin-bottom: 5px' ng-click='showResultQuery(paragraph)') Show query + .sql-next(ng-show=nextVisibleCondition ) + i.fa.fa-chevron-circle-right(ng-class='{disabled: paragraph.loading}' ng-click='!paragraph.loading && nextPage(paragraph)') + a(ng-class='{disabled: paragraph.loading}' ng-click='!paragraph.loading && nextPage(paragraph)') Next http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/agent-download.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/agent-download.jade b/modules/web-console/src/main/js/views/templates/agent-download.jade new file mode 100644 index 0000000..f17dac8 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/agent-download.jade @@ -0,0 +1,48 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal.center(tabindex='-1' role='dialog') + .modal-dialog + .modal-content + #errors-container.modal-header.header + h4.modal-title(ng-if='!hasAgents') Connection to Ignite Web Agent is not established + h4.modal-title(ng-if='hasAgents') Connection to Ignite Node is not established + .agent-download(ng-if='!hasAgents') + p Please download and run #[a(href='javascript:void(0)' ng-click='downloadAgent()') ignite-web-agent] in order to {{::agentGoal}} + p For run: + ul + li Download and unzip #[a(href='javascript:void(0)' ng-click='downloadAgent()') ignite-web-agent] archive + li Run shell file #[b ignite-web-agent.{sh|bat}] + p Refer to #[b README.txt] in agent folder for more information + .modal-advanced-options + i.fa.fa-chevron-circle-down(ng-show='agentLoad.showToken' ng-click='agentLoad.showToken = ! agentLoad.showToken') + i.fa.fa-chevron-circle-right(ng-show='!agentLoad.showToken' ng-click='agentLoad.showToken = ! agentLoad.showToken') + a(ng-click='agentLoad.showToken = ! agentLoad.showToken') {{agentLoad.showToken ? 'Hide security token...' : 'Show security token...'}} + .details-row(ng-show='agentLoad.showToken') + label.labelField Security token: {{user.token}} + i.tipLabel.fa.fa-clipboard(ng-click-copy='{{user.token}}' bs-tooltip='' data-title='Copy security token to clipboard') + i.tipLabel.fa.fa-question-circle(ng-if=lines bs-tooltip='' data-title='The security token is used for authorization of web agent') + .agent-download(ng-if='hasAgents') + p Connection to Ignite Web Agent is established, but agent failed to connect to Ignite Node + p Please check the following: + ul + li Ignite Grid is up and running + li In agent settings check URI for connect to Ignite REST server + li Check agent logs for errors + li Refer to #[b README.txt] in agent folder for more information + .modal-footer + button.btn.btn-default(ng-click='back()') {{::backText}} + button.btn.btn-primary(ng-if='!hasAgents' ng-click='downloadAgent()') Download agent http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/alert.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/alert.jade b/modules/web-console/src/main/js/views/templates/alert.jade new file mode 100644 index 0000000..0ab3dd9 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/alert.jade @@ -0,0 +1,21 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.alert(ng-show='type' ng-class='[type ? "alert-" + type : null]') + button.close(type='button', ng-if='dismissable', ng-click='$hide()') × + i.alert-icon.fa(ng-if='icon' ng-class='[icon]') + span.alert-title(ng-bind='title') + span.alert-content(ng-bind-html='content') http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/batch-confirm.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/batch-confirm.jade b/modules/web-console/src/main/js/views/templates/batch-confirm.jade new file mode 100644 index 0000000..7451314 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/batch-confirm.jade @@ -0,0 +1,32 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal(tabindex='-1' role='dialog') + .modal-dialog + .modal-content + .modal-header + button.close(ng-click='cancel()' aria-hidden='true') × + h4.modal-title Confirmation + .modal-body(ng-show='content') + p(ng-bind-html='content' style='text-align: center') + .modal-footer + .checkbox.labelField + label + input(type='checkbox' ng-model='applyToAll') + | Apply to all + button.btn.btn-default(id='batch-confirm-btn-cancel' ng-click='cancel()') Cancel + button.btn.btn-default(id='batch-confirm-btn-skip' ng-click='skip(applyToAll)') Skip + button.btn.btn-primary(id='batch-confirm-btn-overwrite' ng-click='overwrite(applyToAll)') Overwrite http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/clone.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/clone.jade b/modules/web-console/src/main/js/views/templates/clone.jade new file mode 100644 index 0000000..c94c534 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/clone.jade @@ -0,0 +1,31 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal(tabindex='-1' role='dialog') + .modal-dialog + .modal-content + .modal-header + button.close(ng-click='$hide()') × + h4.modal-title Clone + form.form-horizontal.modal-body.row(name='ui.inputForm' novalidate) + div + .col-sm-2 + label.required.labelFormField New name: + .col-sm-10 + input.form-control(id='copy-new-name' type='text' ng-model='newName' on-enter='form.$valid && ok(newName)' required auto-focus) + .modal-footer + button.btn.btn-default(id='copy-btn-cancel' ng-click='$hide()') Cancel + button.btn.btn-primary(id='copy-btn-confirm' ng-disabled='ui.inputForm.$invalid' ng-click='ok(newName)') Confirm http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/confirm.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/confirm.jade b/modules/web-console/src/main/js/views/templates/confirm.jade new file mode 100644 index 0000000..26af061 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/confirm.jade @@ -0,0 +1,31 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal(tabindex='-1' role='dialog') + .modal-dialog + .modal-content + .modal-header + button.close(ng-click='confirmCancel()' aria-hidden='true') × + h4.modal-title Confirmation + .modal-body(ng-show='content') + p(ng-bind-html='content' style='text-align: center;') + .modal-footer + button#confirm-btn-cancel.btn.btn-default(ng-click='confirmCancel()') Cancel + + button#confirm-btn-no.btn.btn-default(ng-if='yesNo' ng-click='confirmNo()') No + button#confirm-btn-yes.btn.btn-primary(ng-if='yesNo' ng-click='confirmYes()') Yes + + button#confirm-btn-ok.btn.btn-primary(ng-if='!yesNo' ng-click='confirmYes()') Confirm http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/demo-info.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/demo-info.jade b/modules/web-console/src/main/js/views/templates/demo-info.jade new file mode 100644 index 0000000..100e806 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/demo-info.jade @@ -0,0 +1,45 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal.center(role='dialog') + .modal-dialog + .modal-content + #errors-container.modal-header.header + button.close(ng-click='close()' aria-hidden='true') × + h4.modal-title {{title}} + .modal-body + div(ng-bind-html='message') + div(ng-hide='hasAgents') + p + div + h4 + i.fa.fa-download.fa-cursor-default + | How To Start Demo + ul + li + a(ng-click='downloadAgent()') #[b Download] + | and unzip ignite-web-agent archive + li #[b Run] shell file ignite-web-agent.{sh|bat} + div(ng-show='hasAgents') + h4 + i.fa.fa-star-o.fa-cursor-default + | Start Demo + ul + li Web Agent is already started + li Close dialog and try Web Console + .modal-footer + button.btn.btn-default(ng-class='hasAgents ? "btn-primary" : "btn-default"' ng-click='close()') Close + button.btn.btn-primary(ng-hide='hasAgents' ng-click='downloadAgent()') Download agent http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/dropdown.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/dropdown.jade b/modules/web-console/src/main/js/views/templates/dropdown.jade new file mode 100644 index 0000000..96cc43d --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/dropdown.jade @@ -0,0 +1,21 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +ul.dropdown-menu(tabindex='-1' role='menu' ng-show='content && content.length') + li(role='presentation' ui-sref-active='active' ng-class='{divider: item.divider, active: item.active, custom: item.custom}' ng-repeat='item in content') + a(role='menuitem' tabindex='-1' ui-sref='{{item.sref}}' ng-if='!item.divider && item.sref' ng-bind='item.text') + a(role='menuitem' tabindex='-1' ng-href='{{item.href}}' ng-if='!item.divider && item.href' target='{{item.target || ""}}' ng-bind='item.text') + a(role='menuitem' tabindex='-1' href='javascript:void(0)' ng-if='!item.divider && item.click' ng-click='$eval(item.click);$hide()' ng-bind='item.text') http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/getting-started.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/getting-started.jade b/modules/web-console/src/main/js/views/templates/getting-started.jade new file mode 100644 index 0000000..98bc265 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/getting-started.jade @@ -0,0 +1,32 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal.center(role='dialog') + .modal-dialog + .modal-content + #errors-container.modal-header.header + button.close(ng-click='close()' aria-hidden='true') × + h4.modal-title {{title}} + .getting-started + .col-xs-12(ng-bind-html='message') + .modal-footer + .checkbox + label + input(type='checkbox' ng-model='ui.showGettingStarted') + | Show getting started on next login + a.btn.btn-primary(ng-disabled='isFirst()' ng-click='!isFirst() && prev()') Prev + a.btn.btn-primary(ng-disabled='isLast()' ng-click='!isLast() && next()') Next + a.btn.btn-primary(ng-click='close()') Close http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/message.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/message.jade b/modules/web-console/src/main/js/views/templates/message.jade new file mode 100644 index 0000000..6dcf445 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/message.jade @@ -0,0 +1,26 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.modal(tabindex='-1' role='dialog') + .modal-dialog + .modal-content + .modal-header + button.close(ng-click='$hide()' aria-hidden='true') × + h4.modal-title {{title}} + .modal-body(ng-show='content') + p(ng-bind-html='content.join("<br/>")' style='text-align: left;') + .modal-footer + button.btn.btn-primary(id='confirm-btn-confirm' ng-click='$hide()') Ok http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/pagination.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/pagination.jade b/modules/web-console/src/main/js/views/templates/pagination.jade new file mode 100644 index 0000000..08ced60 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/pagination.jade @@ -0,0 +1,32 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +nav(ng-if='numPages && pages.length >= 2') + ul.pagination + li(ng-if='currentPage > 1') + a(href='javascript:void(0);' ng-click='selectPage(1)' bs-tooltip='' data-title='First page' data-placement='bottom') + i.fa.fa-angle-double-left + li(ng-if='currentPage > 1') + a(href='javascript:void(0);' ng-click='selectPage(currentPage-1)' bs-tooltip='' data-title='Previous page' data-placement='bottom') + i.fa.fa-angle-left + li(ng-repeat='page in pages' ng-class='{active: page==currentPage}') + a(href='javascript:void(0);' ng-click='selectPage(page)') {{page}} + li(ng-if='currentPage < numPages') + a(href='javascript:void(0);' ng-click='selectPage(currentPage+1)' bs-tooltip='' data-title='Next page' data-placement='bottom') + i.fa.fa-angle-right + li(ng-if='currentPage < numPages') + a(href='javascript:void(0);' ng-click='selectPage(numPages)' bs-tooltip='' data-title='Last page' data-placement='bottom') + i.fa.fa-angle-double-right \ No newline at end of file http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/select.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/select.jade b/modules/web-console/src/main/js/views/templates/select.jade new file mode 100644 index 0000000..3feee61 --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/select.jade @@ -0,0 +1,26 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +ul.select.dropdown-menu(tabindex='-1' ng-show='$isVisible()' role='select') + li(ng-if='$showAllNoneButtons || ($isMultiple && $matches.length > 2)') + a(id='li-dropdown-select-all' ng-click='$selectAll()') {{$allText}} ({{$matches.length}}) + a(id='li-dropdown-select-none' ng-click='$selectNone()') {{$noneText}} + hr(style='margin: 5px 0') + li(role='presentation' ng-repeat='match in $matches') + hr(ng-if='match.value == undefined' style='margin: 5px 0') + a(id='li-dropdown-item-{{$index}}' role='menuitem' tabindex='-1' ng-class='{active: $isActive($index)}' ng-click='$select($index, $event)' bs-tooltip='widthIsSufficient && !widthIsSufficient("li-dropdown-item-{{$index}}", $index, match.label) ? match.label : ""' data-placement='bottom') + i(class='{{$iconCheckmark}}' ng-if='$isActive($index)' ng-class='{active: $isActive($index)}') + span(ng-bind='match.label') http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/main/js/views/templates/validation-error.jade ---------------------------------------------------------------------- diff --git a/modules/web-console/src/main/js/views/templates/validation-error.jade b/modules/web-console/src/main/js/views/templates/validation-error.jade new file mode 100644 index 0000000..13deb9b --- /dev/null +++ b/modules/web-console/src/main/js/views/templates/validation-error.jade @@ -0,0 +1,25 @@ +//- + Licensed to the Apache Software Foundation (ASF) under one or more + contributor license agreements. See the NOTICE file distributed with + this work for additional information regarding copyright ownership. + The ASF licenses this file to You 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. + +.popover.validation-error + .arrow + .popover-content + table + tr + td + label {{content}}   + td + button.close(id='popover-btn-close' ng-click='$hide()') × http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/modules/web-console/src/test/js/routes/agent.js ---------------------------------------------------------------------- diff --git a/modules/web-console/src/test/js/routes/agent.js b/modules/web-console/src/test/js/routes/agent.js new file mode 100644 index 0000000..1c4aff5 --- /dev/null +++ b/modules/web-console/src/test/js/routes/agent.js @@ -0,0 +1,94 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You 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. + */ + +var request = require('supertest'), + should = require('should'), + app = require('../../app'), + fs = require('fs'), + https = require('https'), + config = require('../../helpers/configuration-loader.js'), + agentManager = require('../../agents/agent-manager'); + +/** + * Create HTTP server. + */ +/** + * Start agent server. + */ +var agentServer = https.createServer({ + key: fs.readFileSync(config.get('monitor:server:key')), + cert: fs.readFileSync(config.get('monitor:server:cert')), + passphrase: config.get('monitor:server:keyPassphrase') +}); + +agentServer.listen(config.get('monitor:server:port')); + +agentManager.createManager(agentServer); + +describe('request from agent', function() { + var agent = request.agent(app); + + before(function (done) { + this.timeout(10000); + + agent + .post('/login') + .send({email: '[email protected]', password: 'test'}) + .expect(302) + .end(function (err) { + if (error) + throw error; + + setTimeout(done, 5000); + }); + }); + + it('should return topology snapshot', function(done){ + agent + .post('/agent/topology') + .send({}) + .end(function(err, nodes) { + if (error) { + console.log(error.response.text); + + throw error; + } + + console.log(nodes); + + done(); + }); + }); + + //it('should query result', function(done){ + // agent + // .post('/agent/query') + // .send({ + // username: 'nva', + // password: 'nva.141', + // host: 'localhost', + // port: '5432', + // dbName: 'ggmonitor' + // }) + // .end(function(err, res) { + // if (err) + // throw err; + // + // done(); + // }); + //}); +}); http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/parent/pom.xml ---------------------------------------------------------------------- diff --git a/parent/pom.xml b/parent/pom.xml index 211884f..0af3374 100644 --- a/parent/pom.xml +++ b/parent/pom.xml @@ -872,6 +872,18 @@ <exclude>**/*.dxg</exclude> <exclude>**/*.cmd</exclude> <exclude>**/*.ps1</exclude> + <!--web console--> + <exclude>**/src/main/js/package.json</exclude> + <exclude>**/src/main/js/*.babelrc</exclude> + <exclude>**/src/main/js/*.eslintrc</exclude> + <exclude>**/src/main/js/*.npmrc</exclude> + <exclude>**/src/main/js/app/data/*.json</exclude> + <exclude>**/src/main/js/build/**</exclude> + <exclude>**/src/main/js/node_modules/**</exclude> + <exclude>**/src/main/js/ignite_modules_temp/**</exclude> + <exclude>**/src/main/js/serve/config/settings.json.sample</exclude> + <exclude>**/src/main/js/serve/keys/test.*</exclude> + <exclude>**/src/main/js/serve/routes/demo/*.json</exclude> </excludes> </configuration> </execution> http://git-wip-us.apache.org/repos/asf/ignite/blob/eb5ac0ae/pom.xml ---------------------------------------------------------------------- diff --git a/pom.xml b/pom.xml index 5945842..044efea 100644 --- a/pom.xml +++ b/pom.xml @@ -787,6 +787,15 @@ </profile> <profile> + <id>web-console</id> + <modules> + <module>modules/web-agent</module> + <module>modules/web-console</module> + <module>modules/schema-import-db</module> + </modules> + </profile> + + <profile> <id>update-versions</id> <!-- updates dotnet & cpp versions --> <build>
