diff --git a/components/device-mgt/io.entgra.device.mgt.ui/pom.xml b/components/device-mgt/io.entgra.device.mgt.ui/pom.xml deleted file mode 100644 index 6e62bc0fc4..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/pom.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - - 4.0.0 - - - org.wso2.carbon.devicemgt - device-mgt - 4.1.7-SNAPSHOT - - io.entgra.device.mgt.ui - 4.1.7-SNAPSHOT - war - Entgra - Device Management UI Component - https://entgra.io - This Component contains Device Management UI - - - - - - - maven-war-plugin - - WEB-INF/lib/*cxf*.jar - entgra - - - ${npm.output.directory}/dist - - - ${npm.output.directory}/public - public - - - - - - com.github.eirslett - frontend-maven-plugin - ${frontend.mave.version} - - ${npm.working.dir} - - ${npm.install.dir} - - - - install node and npm - - install-node-and-npm - - generate-resources - - ${node.version} - ${npm.version} - - - - npm install - - npm - - - - install - - - - lint - - npm - - - run-script lint - - generate-resources - - - prod - - npm - - - run-script ${npm.build.command} - - generate-resources - - - - - - - - platform-windows - - - windows - - - - - npm.cmd - - - - - false - npm - build_prod - ./react-app - ./react-app/tmp - UTF-8 - react-app - - diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/.eslintrc b/components/device-mgt/io.entgra.device.mgt.ui/react-app/.eslintrc deleted file mode 100644 index 7958a91eaf..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/.eslintrc +++ /dev/null @@ -1,325 +0,0 @@ -{ - "parser": "babel-eslint", - "plugins": [ - "react", - "babel", - "jsx", - "prettier" - ], - "extends": [ - "eslint:recommended", - "plugin:react/recommended" - ], - "parserOptions": { - "ecmaVersion": 2016, - "sourceType": "module", - "ecmaFeatures": { - "jsx": true - } - }, - "settings": { - "react": { - "createClass": "createReactClass", - "pragma": "React", - "version": "16.8.6" - } - }, - "env": { - "node": true, - "commonjs": true, - "browser": true, - "jasmine": true, - "es6": true - }, - "globals": { - "document": true, - "console": true, - // Only for development purposes - "setTimeout": true, - "window" : true - }, - "rules": { - "prettier/prettier": "error", - // Enforce the spacing around the * in generator functions. - "generator-star-spacing": [2, "after"], - // Disallow using variables outside the blocks they are defined (especially - // since only let and const are used, see "no-var"). - "block-scoped-var": 2, - // Require camel case names - "camelcase": 2, - // Allow trailing commas for easy list extension. Having them does not - // impair readability, but also not required either. - "comma-dangle": 0, - // Warn about cyclomatic complexity in functions. - "complexity": 1, - // Don't warn for inconsistent naming when capturing this (not so important - // with auto-binding fat arrow functions). - "consistent-this": 0, - // Enforce curly brace conventions for all control statements. - "curly": 2, - // Don't require a default case in switch statements. Avoid being forced to - // add a bogus default when you know all possible cases are handled. - "default-case": 0, - // Encourage the use of dot notation whenever possible. - "dot-notation": 2, - // Allow mixed 'LF' and 'CRLF' as linebreaks. - "linebreak-style": 0, - // Don't enforce the maximum depth that blocks can be nested. - "max-depth": 0, - // Maximum length of a line. - "max-len": [2, 120, 2, { "ignoreStrings": true, "ignoreUrls": true}], - // Maximum depth callbacks can be nested. - "max-nested-callbacks": [2, 3], - // Don't limit the number of parameters that can be used in a function. - "max-params": 0, - // Don't limit the maximum number of statement allowed in a function. - "max-statements": 0, - // Require a capital letter for constructors, only check if all new - // operators are followed by a capital letter. Don't warn when capitalized - // functions are used without the new operator. - "new-cap": [2, {"capIsNew": false}], - // Disallow use of the Array constructor. - "no-array-constructor": 2, - // Allow use of bitwise operators. - "no-bitwise": 0, - // Disallow use of arguments.caller or arguments.callee. - "no-caller": 2, - // Disallow the catch clause parameter name being the same as a variable in - // the outer scope, to avoid confusion. - "no-catch-shadow": 2, - // Disallow assignment in conditional expressions. - "no-cond-assign": 2, - // Allow using the console API. - "no-console": 0, - // Allow using constant expressions in conditions like while (true) - "no-constant-condition": 0, - // Allow use of the continue statement. - "no-continue": 0, - // Disallow control characters in regular expressions. - "no-control-regex": 2, - // Disallow deletion of variables (deleting properties is fine). - "no-delete-var": 2, - // Disallow duplicate arguments in functions. - "no-dupe-args": 2, - // Disallow duplicate keys when creating object literals. - "no-dupe-keys": 2, - // Disallow multiple empty lines - "no-multiple-empty-lines": "error", - // Disallow a duplicate case label. - "no-duplicate-case": 2, - // Disallow else after a return in an if. The else around the second return - // here is useless: - // if (something) { return false; } else { return true; } - "no-else-return": 2, - // Disallow empty statements. This will report an error for: - // try { something(); } catch (e) {} - // but will not report it for: - // try { something(); } catch (e) { /* Silencing the error because ...*/ } - // which is a valid use case. - "no-empty": 2, - // Disallow the use of empty character classes in regular expressions. - "no-empty-character-class": 2, - // Disallow use of labels for anything other then loops and switches. - "no-labels": 2, - // Disallow use of eval(). We have other APIs to evaluate code in content. - "no-eval": 2, - // Disallow assigning to the exception in a catch block. - "no-ex-assign": 2, - // Disallow adding to native types - "no-extend-native": 2, - // Disallow unnecessary function binding. - "no-extra-bind": 2, - // Disallow double-negation boolean casts in a boolean context. - "no-extra-boolean-cast": 2, - // Allow unnecessary parentheses, as they may make the code more readable. - "no-extra-parens": 0, - // Disallow fallthrough of case statements, except if there is a comment. - "no-fallthrough": 2, - // Allow the use of leading or trailing decimal points in numeric literals. - "no-floating-decimal": 0, - // Disallow if as the only statement in an else block. - "no-lonely-if": 2, - // Disallow use of multiline strings (use template strings instead). - "no-multi-str": 2, - // Disallow reassignments of native objects. - "no-native-reassign": 2, - // Disallow nested ternary expressions, they make the code hard to read. - "no-nested-ternary": 2, - // Allow use of new operator with the require function. - "no-new-require": 0, - // Disallow use of octal literals. - "no-octal": 2, - // Allow reassignment of function parameters. - "no-param-reassign": 0, - // Allow string concatenation with __dirname and __filename (not a node env). - "no-path-concat": 0, - // Allow use of unary operators, ++ and --. - "no-plusplus": 0, - // Allow using process.env (not a node environment). - "no-process-env": 0, - // Allow using process.exit (not a node environment). - "no-process-exit": 0, - // Disallow usage of __proto__ property. - "no-proto": 2, - // Disallow declaring the same variable more than once (we use let anyway). - "no-redeclare": 2, - // Disallow multiple spaces in a regular expression literal. - "no-regex-spaces": 2, - // Allow reserved words being used as object literal keys. - "no-reserved-keys": 0, - // Don't restrict usage of specified node modules (not a node environment). - "no-restricted-modules": 0, - // Disallow use of assignment in return statement. It is preferable for a - // single line of code to have only one easily predictable effect. - "no-return-assign": 2, - // Allow use of javascript: urls. - "no-script-url": 0, - // Disallow comparisons where both sides are exactly the same. - "no-self-compare": 2, - // Disallow use of comma operator. - "no-sequences": 2, - // Warn about declaration of variables already declared in the outer scope. - // This isn't an error because it sometimes is useful to use the same name - // in a small helper function rather than having to come up with another - // random name. - // Still, making this a warning can help people avoid being confused. - "no-shadow": 0, - // Require empty line at end of file - "eol-last": "error", - // Disallow shadowing of names such as arguments. - "no-shadow-restricted-names": 2, - "no-space-before-semi": 0, - // Disallow sparse arrays, eg. let arr = [,,2]. - // Array destructuring is fine though: - // for (let [, breakpointPromise] of aPromises) - "no-sparse-arrays": 2, - // Allow use of synchronous methods (not a node environment). - "no-sync": 0, - // Allow the use of ternary operators. - "no-ternary": 0, - // Don't allow spaces after end of line - "no-trailing-spaces": "error", - // Disallow throwing literals (eg. throw "error" instead of - // throw new Error("error")). - "no-throw-literal": 2, - // Disallow use of undeclared variables unless mentioned in a /*global */ - // block. Note that globals from head.js are automatically imported in tests - // by the import-headjs-globals rule form the mozilla eslint plugin. - "no-undef": 2, - // Allow use of undefined variable. - "no-undefined": 0, - // Disallow the use of Boolean literals in conditional expressions. - "no-unneeded-ternary": 2, - // Disallow unreachable statements after a return, throw, continue, or break - // statement. - "no-unreachable": 2, - // Allow using variables before they are defined. - "no-unused-vars": [2, {"vars": "all", "args": "none"}], - // Disallow global and local variables that arent used, but allow unused function arguments. - "no-use-before-define": 0, - // We use var-only-at-top-level instead of no-var as we allow top level - // vars. - "no-var": 0, - // Allow using TODO/FIXME comments. - "no-warning-comments": 0, - // Disallow use of the with statement. - "no-with": 2, - // Dont require method and property shorthand syntax for object literals. - // We use this in the code a lot, but not consistently, and this seems more - // like something to check at code review time. - "object-shorthand": 0, - // Allow more than one variable declaration per function. - "one-var": 0, - // Single quotes should be used. - "quotes": [2, "single", "avoid-escape"], - // Require use of the second argument for parseInt(). - "radix": 2, - // Dont require to sort variables within the same declaration block. - // Anyway, one-var is disabled. - "sort-vars": 0, - "space-after-function-name": 0, - "space-before-function-parentheses": 0, - // Disallow space before function opening parenthesis. - //"space-before-function-paren": [2, "never"], - // Disable the rule that checks if spaces inside {} and [] are there or not. - // Our code is split on conventions, and itd be nice to have 2 rules - // instead, one for [] and one for {}. So, disabling until we write them. - "space-in-brackets": 0, - // Deprecated, will be removed in 1.0. - "space-unary-word-ops": 0, - // Require a space immediately following the // in a line comment. - "spaced-comment": [2, "always"], - // Require "use strict" to be defined globally in the script. - "strict": [2, "global"], - // Disallow comparisons with the value NaN. - "use-isnan": 2, - // Warn about invalid JSDoc comments. - // Disabled for now because of https://github.com/eslint/eslint/issues/2270 - // The rule fails on some jsdoc comments like in: - // devtools/client/webconsole/console-output.js - "valid-jsdoc": 0, - // Ensure that the results of typeof are compared against a valid string. - "valid-typeof": 2, - // Allow vars to be declared anywhere in the scope. - "vars-on-top": 0, - // Dont require immediate function invocation to be wrapped in parentheses. - "wrap-iife": 0, - // Don't require regex literals to be wrapped in parentheses (which - // supposedly prevent them from being mistaken for division operators). - "wrap-regex": 0, - // Require for-in loops to have an if statement. - "guard-for-in": 0, - // allow/disallow an empty newline after var statement - "newline-after-var": 0, - // disallow the use of alert, confirm, and prompt - "no-alert": 0, - // disallow the use of deprecated react changes and lifecycle methods - "react/no-deprecated": 0, - // disallow comparisons to null without a type-checking operator - "no-eq-null": 0, - // disallow overwriting functions written as function declarations - "no-func-assign": 0, - // disallow use of eval()-like methods - "no-implied-eval": 0, - // disallow function or variable declarations in nested blocks - "no-inner-declarations": 0, - // disallow invalid regular expression strings in the RegExp constructor - "no-invalid-regexp": 0, - // disallow irregular whitespace outside of strings and comments - "no-irregular-whitespace": 0, - // disallow unnecessary nested blocks - "no-lone-blocks": 0, - // disallow creation of functions within loops - "no-loop-func": 0, - // disallow use of new operator when not part of the assignment or - // comparison - "no-new": 0, - // disallow use of new operator for Function object - "no-new-func": 0, - // disallow use of the Object constructor - "no-new-object": 0, - // disallows creating new instances of String,Number, and Boolean - "no-new-wrappers": 0, - // disallow the use of object properties of the global object (Math and - // JSON) as functions - "no-obj-calls": 0, - // disallow use of octal escape sequences in string literals, such as - // var foo = "Copyright \251"; - "no-octal-escape": 0, - // disallow use of undefined when initializing variables - "no-undef-init": 0, - // disallow usage of expressions in statement position - "no-unused-expressions": 0, - // disallow use of void operator - "no-void": 0, - // disallow wrapping of non-IIFE statements in parens - "no-wrap-func": 0, - // require assignment operator shorthand where possible or prohibit it - // entirely - "operator-assignment": 0, - // enforce operators to be placed before or after line breaks - "operator-linebreak": 0, - // disable chacking prop types - "react/prop-types": 0 - } -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/.prettierrc b/components/device-mgt/io.entgra.device.mgt.ui/react-app/.prettierrc deleted file mode 100644 index d281e2bd55..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/.prettierrc +++ /dev/null @@ -1,5 +0,0 @@ -{ - "singleQuote": true, - "trailingComma": "all", - "parser": "flow" -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/babel.config.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/babel.config.js deleted file mode 100644 index 482333ff45..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/babel.config.js +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -module.exports = function(api) { - api.cache(true); - const presets = ['@babel/preset-env', '@babel/preset-react']; - const plugins = ['@babel/plugin-proposal-class-properties']; - - return { - presets, - plugins, - }; -}; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/package.json b/components/device-mgt/io.entgra.device.mgt.ui/react-app/package.json deleted file mode 100644 index 84b0d6c416..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/package.json +++ /dev/null @@ -1,101 +0,0 @@ -{ - "name": "entgra", - "version": "1.0.0", - "description": "Entgra device management", - "main": "App.js", - "license": "Apache License 2.0", - "dependencies": { - "acorn": "^6.2.0", - "antd": "^3.23.5", - "axios": "^0.18.1", - "babel-eslint": "^9.0.0", - "bizcharts": "^3.5.6", - "bootstrap": "^4.3.1", - "javascript-time-ago": "^2.0.1", - "keymirror": "^0.1.1", - "leaflet": "^1.3.4", - "leaflet-routing-machine": "^3.2.12", - "lodash.debounce": "^4.0.8", - "moment": "latest", - "prop-types": "latest", - "rc-viewer": "0.0.9", - "react-bootstrap": "^1.0.0-beta.12", - "react-highlight-words": "^0.16.0", - "react-icons": "^3.8.0", - "react-image-viewer-zoom": "^1.0.36", - "react-infinite-scroller": "^1.2.4", - "react-leaflet": "^2.4.0", - "react-moment": "^0.9.7", - "react-router": "^5.0.1", - "react-router-config": "^5.0.1", - "react-router-dom": "^5.0.1", - "react-scripts": "2.1.8", - "react-star-ratings": "^2.3.0", - "react-twemoji": "^0.2.3", - "react-virtualized": "^9.21.1", - "react-websocket": "^2.1.0", - "reqwest": "^2.0.5", - "storm-react-diagrams": "^5.2.1" - }, - "devDependencies": { - "@antv/data-set": "^0.10.2", - "@babel/core": "^7.5.4", - "@babel/plugin-proposal-class-properties": "^7.5.0", - "@babel/preset-env": "^7.5.4", - "@babel/preset-react": "^7.0.0", - "@babel/register": "^7.4.4", - "babel-loader": "^8.0.6", - "body-parser": "^1.19.0", - "chai": "^4.1.2", - "cross-env": "^7.0.0", - "css-loader": "^0.28.11", - "eslint": "^5.16.0", - "eslint-config-prettier": "4.3.0", - "eslint-plugin-babel": "5.3.0", - "eslint-plugin-jsx": "0.0.2", - "eslint-plugin-prettier": "3.1.0", - "eslint-plugin-react": "7.14.2", - "express": "^4.17.1", - "express-pino-logger": "^4.0.0", - "file-loader": "^2.0.0", - "html-loader": "^0.5.5", - "html-webpack-plugin": "^3.2.0", - "img-loader": "^3.0.1", - "json-loader": "^0.5.7", - "less": "^3.9.0", - "less-loader": "^4.1.0", - "mini-css-extract-plugin": "^0.5.0", - "mocha": "^5.2.0", - "mock-local-storage": "^1.0.5", - "node-env-run": "^3.0.2", - "node-sass": "^4.12.0", - "nodemon": "^1.19.1", - "npm-run-all": "^4.1.5", - "pino-colada": "^1.4.5", - "postcss-loader": "^3.0.0", - "prettier": "1.18.1", - "qrcode.react": "^1.0.0", - "react": "^16.8.6", - "react-dom": "^16.8.6", - "react-intl": "^2.9.0", - "sass-loader": "^6.0.7", - "style-loader": "^0.18.2", - "url-loader": "^1.1.2", - "webpack": "^4.35.3", - "webpack-cli": "^3.3.5", - "webpack-dev-server": "^3.7.2" - }, - "scripts": { - "start": "webpack-dev-server --mode development --open", - "dev": "webpack --mode development", - "build": "webpack --mode production", - "watch": "webpack --watch --mode development", - "test": "react-scripts test --env=jsdom", - "eject": "react-scripts eject", - "build_prod": "cross-env NODE_ENV=production NODE_OPTIONS=--max_old_space_size=4096 webpack -p --display errors-only --hide-modules", - "build_dev": "cross-env NODE_ENV=development webpack -d --watch ", - "server": "node-env-run server --exec nodemon | pino-colada", - "dev2": "run-p server start", - "lint": "eslint \"src/**/*.js\"" - } -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/config.json b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/config.json deleted file mode 100644 index cb3821751b..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/config.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "theme": { - "logo": "https://entgra.io/assets/images/svg/logo.svg", - "primaryColor": "rgb(24, 144, 255)" - }, - "serverConfig": { - "invoker": { - "uri": "/entgra-ui-request-handler/invoke", - "deviceMgt": "/device-mgt/v1.0" - }, - "loginUri": "/entgra-ui-request-handler/login", - "logoutUri": "/entgra-ui-request-handler/logout", - "platform": "entgra" - }, - "defaultPlatformIcons": { - "default": { - "icon": "hdd", - "color": "#535c68", - "theme": "outlined" - }, - "android": { - "icon": "android", - "color": "#7db343", - "theme": "filled" - }, - "ios": { - "icon": "apple", - "color": "#535c68", - "theme": "filled" - }, - "windows": { - "icon": "windows", - "color": "#008cc4", - "theme": "filled" - } - }, - "geoMap": { - "url": "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", - "attribution": "© OpenStreetMap contributors", - "defaultZoomLevel": 16, - "timeout": 120 - } -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/icons.json b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/icons.json deleted file mode 100644 index 0bd52ef51e..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/icons.json +++ /dev/null @@ -1,306 +0,0 @@ -{ - "airplay": "", - "api": "", - "apn": "", - "vpn": "", - "apple": "", - "windows": "", - "android": "", - "wifi": "", - "application": "", - "configarations": "", - "battery": "", - "notification": "", - "blank-document": "", - "bookmark": "", - "bpel": "", - "bpmn": "", - "compare": "", - "bug": "", - "calendar": "", - "camera": "", - "contract": "", - "add": "", - "minus": "", - "check": "", - "cancel": "", - "checklist": "", - "circle": "", - "clear": "", - "expand": "", - "clock": "", - "cloud": "", - "circle-outline": "", - "contact": "", - "copy": "", - "dashboard": "", - "database": "", - "delete": "", - "deploy": "", - "display": "", - "dial-up": "", - "document": "", - "ellipsis": "", - "dss": "", - "ebook": "", - "edit": "", - "endpoint": "", - "folder": "", - "faq": "", - "error": "", - "export": "", - "factory-reset": "", - "file-browse": "", - "filter": "", - "message": "", - "forum": "", - "gadget": "", - "grid": "", - "hdd": "", - "home": "", - "hour-glass": "", - "import": "", - "incoming-call": "", - "info": "", - "invitation": "", - "jaggery": "", - "java": "", - "javaee": "", - "javascript": "", - "java-spring": "", - "jaxrs": "", - "jquery": "", - "key": "", - "laptop": "", - "ldap": "", - "lifecycle": "", - "sort-up": "", - "list": "", - "list-sort": "", - "lock": "", - "mail": "", - "map-location": "", - "menu": "", - "mobile": "", - "computer": "", - "ms-document": "", - "mute": "", - "nodejs": "", - "success": "", - "paste": "", - "pdf": "", - "pie-chart": "", - "chat": "", - "publish": "", - "redo": "", - "register": "", - "download": "", - "resource": "", - "rest-api": "", - "rest-service": "", - "sort-down": "", - "rules": "", - "save": "", - "scep": "", - "schema": "", - "search": "", - "security": "", - "send": "", - "sequence": "", - "server": "", - "service": "", - "service-provider": "", - "settings": "", - "share": "", - "sign-in": "", - "soap": "", - "sort": "", - "star": "", - "statistics": "", - "store": "", - "subscribe": "", - "fan": "", - "swagger": "", - "tag": "", - "task": "", - "text": "", - "policy": "", - "security-policy": "", - "throttling-policy": "", - "light": "", - "tiles": "", - "uncheck": "", - "undo": "", - "up": "", - "down": "", - "left": "", - "right": "", - "up-arrow": "", - "down-arrow": "", - "left-arrow": "", - "right-arrow": "", - "upload": "", - "uri": "", - "usb-drive": "", - "user": "", - "bar-chart": "", - "view": "", - "refresh": "", - "warning": "", - "ringing": "", - "block": "", - "web-app": "", - "globe": "", - "web-clip": "", - "proxy": "", - "web-service": "", - "website": "", - "xml": "", - "html": "\t\t\t\t", - "war": "", - "xacml": "", - "wsdl": "", - "wadl": "", - "xq": "", - "xsd": "", - "xslt": "", - "zoom-in": "", - "zoom-out": "", - "wso2-logo": "", - "wso2": "", - "hardware": "", - "raspberry": "", - "arduino": "", - "organization": "", - "public": "", - "unmute": "", - "group": "", - "question": "", - "square": "", - "square-outline": "", - "sync": "", - "loader": "", - "ungroup": "", - "enterprise": "", - "grip": "", - "sign-out": "", - "retweet": "", - "loader2": "", - "loader3": "", - "loader4": "", - "loader5": "", - "alert": "", - "layout": "", - "pages": "", - "build": "", - "alarm": "", - "heart": "", - "table": "", - "carbon": "", - "depend": "", - "jaxws": "", - "own": "", - "php": "", - "use": "", - "deprecate": "", - "prototype": "", - "retire": "", - "micro-services": "", - "activate": "", - "disabled": "", - "hide": "", - "facebook": "", - "github": "", - "google": "", - "google-docs": "", - "google-sheets": "", - "google-slides": "", - "google-plus": "", - "google-drive": "", - "instagram": "", - "linkedin": "", - "pinterest": "", - "skype": "", - "twitter": "", - "youtube": "", - "slash": "", - "analytics-extensions": "", - "esb-connector": "", - "extensions": "", - "is-connector": "", - "annotation": "", - "dgm-fork": "", - "dgm-header": "", - "dgm-if-else": "", - "dgm-lifeline": "", - "dgm-logger": "\t", - "dgm-try-catch": "", - "invoke": "", - "variable": "", - "worker": "", - "code": "", - "cut": "", - "type-converter": "", - "dgm-connector": "", - "dgm-constant-definition": "", - "dgm-resource": "", - "dgm-service": "", - "dgm-type-convertor": "", - "dgm-type": "", - "format": "", - "function": "", - "rename": "", - "package": "", - "action-invoke": "", - "assign": "", - "connector": "", - "constant": "", - "logical": "", - "try-catch": "", - "devices": "", - "http": "", - "main-function": "", - "dgm-while": "", - "run": "", - "action": "", - "image": "", - "folder-open": "", - "docker": "", - "polygon": "", - "code-view": "", - "design-view": "", - "comment": "", - "dgm-action": "", - "dgm-action-invoke": "", - "function-invoke": "", - "reply": "", - "return": "", - "struct": "", - "dgm-import": "", - "start": "", - "stepin": "", - "stepout": "", - "stepover": "", - "stop": "", - "console": "", - "resume": "", - "iterate": "", - "fork-join": "", - "break": "", - "throw": "", - "worker-invoke": "", - "worker-reply": "", - "shortcut": "", - "theme": "", - "pending": "", - "ballerina": "", - "ballerina-service": "", - "abort": "", - "transaction": "", - "android-logcat": "", - "android-sense": "", - "geo-fence-inbound": "", - "geo-fence-outbound": "", - "shell": "", - "speed-alert": "" -} \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/manifest.json b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/manifest.json deleted file mode 100644 index 60f712111e..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/conf/manifest.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "short_name": "App Store", - "name": "WSO2 IoT App Store", - "icons": [ - { - "src": "images/favicon.png", - "sizes": "16x16", - "type": "image/png" - } - ], - "start_url": "./index.html", - "display": "standalone", - "theme_color": "#000000", - "background_color": "#ffffff" -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/font-wso2.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/font-wso2.css deleted file mode 100644 index c0b458da32..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/font-wso2.css +++ /dev/null @@ -1,1508 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - - -@font-face { - font-family:"font-wso2"; - src:local("font-wso2"), url("../fonts/font-wso2.eot?6563fa91278f239ef8c827d90a165223"); - src:local("font-wso2"), - url("../fonts/font-wso2.eot?#iefix") format("embedded-opentype"), - url("../fonts/font-wso2.woff2?6563fa91278f239ef8c827d90a165223") format("woff2"), - url("../fonts/font-wso2.woff?6563fa91278f239ef8c827d90a165223") format("woff"), - url("../fonts/font-wso2.ttf?6563fa91278f239ef8c827d90a165223") format("truetype"), - url("../fonts/font-wso2.svg?6563fa91278f239ef8c827d90a165223#font-wso2") format("svg"); - font-weight:normal; - font-style:normal; -} - -.fw, [class^="fw-"], [class*=" fw-"] { - font: normal normal normal 14px/1 font-wso2; - display: inline-block; - font-weight: normal; - font-style: normal; - font-size: inherit; - font-variant: normal; - speak: none; - text-decoration: inherit; - - /* Better Font Rendering =========== */ - text-transform: none; - text-rendering: auto; - -webkit-font-smoothing: antialiased; - -moz-osx-font-smoothing: grayscale; -} - - -/* ======================================================================== - * font options - * ======================================================================== */ - -.fw-lg { - font-size: 1.33333333em; - line-height: 0.75em; - vertical-align: -15%; -} -.fw-2x { - font-size: 2em; -} -.fw-3x { - font-size: 3em; -} -.fw-4x { - font-size: 4em; -} -.fw-5x { - font-size: 5em; -} -.fw-fw { - width: 1.28571429em; - text-align: center; -} -.fw-ul { - padding-left: 0; - margin-left: 2.14285714em; - list-style-type: none; -} -.fw-ul > li { - position: relative; -} -.fw-li { - position: absolute; - left: -2.14285714em; - width: 2.14285714em; - top: 0.14285714em; - text-align: center; -} -.fw-li.fw-lg { - left: -1.85714286em; -} -.fw-border { - padding: .2em .25em .15em; - border: solid 0.08em #eeeeee; - border-radius: .1em; -} -.fw-background { - background: #888; - border-radius: .3em; - padding: .4em .50em .45em; -} -.fw-pull-left { - float: left; -} -.fw-pull-right { - float: right; -} -.fw.fw-pull-left { - margin-right: .3em; -} -.fw.fw-pull-right { - margin-left: .3em; -} -.fw-spin { - -webkit-animation: fw-spin 2s infinite linear; - animation: fw-spin 2s infinite linear; -} -@-webkit-keyframes fw-spin { - 0% { - -webkit-transform: rotate(0deg); - transform: rotate(0deg); - } - 100% { - -webkit-transform: rotate(359deg); - transform: rotate(359deg); - } -} -@keyframes fw-spin { - 0% { - -webkit-transform: rotate(0deg); - transform: rotate(0deg); - } - 100% { - -webkit-transform: rotate(359deg); - transform: rotate(359deg); - } -} -.fw-pulse { - -webkit-animation: fw-pulse 2s ease-out infinite; - animation: fw-pulse 2s ease-out infinite; -} -@-webkit-keyframes fw-pulse { - 0%, 30% { - opacity: 0.3; - } - 40% { - opacity: 1; - } - 100% { - opacity: 0.3; - } -} -@keyframes fw-pulse { - 0%, 30% { - opacity: 0.3; - } - 40% { - opacity: 1; - } - 100% { - opacity: 0.3; - } -} -.fw-rotate-90 { - filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=1); - -webkit-transform: rotate(90deg); - -ms-transform: rotate(90deg); - transform: rotate(90deg); -} -.fw-rotate-180 { - filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2); - -webkit-transform: rotate(180deg); - -ms-transform: rotate(180deg); - transform: rotate(180deg); -} -.fw-rotate-270 { - filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=3); - -webkit-transform: rotate(270deg); - -ms-transform: rotate(270deg); - transform: rotate(270deg); -} -.fw-flip-horizontal { - filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1); - -webkit-transform: scale(-1, 1); - -ms-transform: scale(-1, 1); - transform: scale(-1, 1); -} -.fw-flip-vertical { - filter: progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1); - -webkit-transform: scale(1, -1); - -ms-transform: scale(1, -1); - transform: scale(1, -1); -} -:root .fw-rotate-90, -:root .fw-rotate-180, -:root .fw-rotate-270, -:root .fw-flip-horizontal, -:root .fw-flip-vertical { - filter: none; -} -.fw-stack, -.fw-helper { - position: relative; - display: inline-block; - width: 2em; - height: 2em; - line-height: 1.85em; - vertical-align: middle; -} -.fw-stack-1x, -.fw-stack-2x, -.fw-helper:before, -.fw-helper:after { - position: absolute; - left: 0; - width: 100%; - text-align: center; -} -.fw-stack-1x, -.fw-helper:before { - line-height: inherit; -} -.fw-stack-2x, -.fw-helper:after { - font-size: 1.9em; -} -.fw-helper-slash:before { - font-size: 1.4em; -} -.fw-helper-circle:before, -.fw-helper-square:before { - z-index: 1; -} -.fw-helper-circle-outline:after { - content: "\e61f"; -} -.fw-helper-circle:after { - content: "\e61a"; -} -.fw-helper-square-outline:after { - content: "\e6b2"; -} -.fw-helper-square:after { - content: "\e6b1"; -} -.fw-helper-slash:after { - content: "\e6e1"; -} -.fw-stack > .fw-stack { - position: absolute; - font-size: 0.5em; -} -.fw-stack > .fw-stack.fw-move-top { - top: -0.2em; -} -.fw-stack > .fw-stack.fw-move-bottom { - bottom: -0.2em; -} -.fw-stack > .fw.stack.fw-move-left { - left: -0.5em; -} -.fw-stack > .fw-stack.fw-move-right { - right: -0.5em; -} -.fw-inverse:before, -.fw-helper-inverse:after, -.fw-number { - color: #ffffff; -} -.fw-shadow:before, -.fw-helper-shadow:after { - text-shadow: #ffffff 1px 1px 0; -} -.fw-stroke:before, -.fw-helper-stroke:after { - text-shadow: -2px -2px 0 #ffffff, - 2px -2px 0 #ffffff, - -2px 2px 0 #ffffff, - 2px 2px 0 #ffffff; -} -.fw-number { - line-height: 2em; - font-family: Arial, Helvetica, sans-serif; -} - - -/* ======================================================================== - * font icons - * ======================================================================== */ - -.fw-abort:before { - content:"\e72a"; -} - -.fw-action-invoke:before { - content:"\e6fe"; -} - -.fw-action:before { - content:"\e709"; -} - -.fw-activate:before { - content:"\e6cf"; -} - -.fw-add:before { - content:"\e615"; -} - -.fw-airplay:before { - content:"\e600"; -} - -.fw-alarm:before { - content:"\e6c2"; -} - -.fw-alert:before { - content:"\e6be"; -} - -.fw-analytics-extensions:before { - content:"\e6e2"; -} - -.fw-android-logcat:before { - content:"\e72c"; -} - -.fw-android-sense:before { - content:"\e72d"; -} - -.fw-android:before { - content:"\e606"; -} - -.fw-annotation:before { - content:"\e6e6"; -} - -.fw-api:before { - content:"\e601"; -} - -.fw-apn:before { - content:"\e602"; -} - -.fw-apple:before { - content:"\e604"; -} - -.fw-application:before { - content:"\e608"; -} - -.fw-arduino:before { - content:"\e6ab"; -} - -.fw-assign:before { - content:"\e6ff"; -} - -.fw-ballerina-service:before { - content:"\e729"; -} - -.fw-ballerina:before { - content:"\e728"; -} - -.fw-bar-chart:before { - content:"\e690"; -} - -.fw-battery:before { - content:"\e60a"; -} - -.fw-blank-document:before { - content:"\e60c"; -} - -.fw-block:before { - content:"\e695"; -} - -.fw-bookmark:before { - content:"\e60d"; -} - -.fw-bpel:before { - content:"\e60e"; -} - -.fw-bpmn:before { - content:"\e60f"; -} - -.fw-break:before { - content:"\e721"; -} - -.fw-bug:before { - content:"\e611"; -} - -.fw-build:before { - content:"\e6c1"; -} - -.fw-calendar:before { - content:"\e612"; -} - -.fw-camera:before { - content:"\e613"; -} - -.fw-cancel:before { - content:"\e618"; -} - -.fw-carbon:before { - content:"\e6c5"; -} - -.fw-chat:before { - content:"\e65b"; -} - -.fw-check:before { - content:"\e617"; -} - -.fw-checklist:before { - content:"\e619"; -} - -.fw-circle-outline:before { - content:"\e61f"; -} - -.fw-circle:before { - content:"\e61a"; -} - -.fw-clear:before { - content:"\e61b"; -} - -.fw-clock:before { - content:"\e61d"; -} - -.fw-cloud:before { - content:"\e61e"; -} - -.fw-code-view:before { - content:"\e70e"; -} - -.fw-code:before { - content:"\e6f1"; -} - -.fw-comment:before { - content:"\e710"; -} - -.fw-compare:before { - content:"\e610"; -} - -.fw-computer:before { - content:"\e653"; -} - -.fw-configarations:before { - content:"\e609"; -} - -.fw-connector:before { - content:"\e700"; -} - -.fw-console:before { - content:"\e71d"; -} - -.fw-constant:before { - content:"\e701"; -} - -.fw-contact:before { - content:"\e620"; -} - -.fw-contract:before { - content:"\e614"; -} - -.fw-copy:before { - content:"\e621"; -} - -.fw-cut:before { - content:"\e6f2"; -} - -.fw-dashboard:before { - content:"\e622"; -} - -.fw-database:before { - content:"\e623"; -} - -.fw-delete:before { - content:"\e624"; -} - -.fw-depend:before { - content:"\e6c6"; -} - -.fw-deploy:before { - content:"\e625"; -} - -.fw-deprecate:before { - content:"\e6cb"; -} - -.fw-design-view:before { - content:"\e70f"; -} - -.fw-devices:before { - content:"\e704"; -} - -.fw-dgm-action-invoke:before { - content:"\e712"; -} - -.fw-dgm-action:before { - content:"\e711"; -} - -.fw-dgm-connector:before { - content:"\e6f4"; -} - -.fw-dgm-constant-definition:before { - content:"\e6f5"; -} - -.fw-dgm-fork:before { - content:"\e6e7"; -} - -.fw-dgm-header:before { - content:"\e6e8"; -} - -.fw-dgm-if-else:before { - content:"\e6e9"; -} - -.fw-dgm-import:before { - content:"\e717"; -} - -.fw-dgm-lifeline:before { - content:"\e6ea"; -} - -.fw-dgm-logger:before { - content:"\e6eb"; -} - -.fw-dgm-resource:before { - content:"\e6f6"; -} - -.fw-dgm-service:before { - content:"\e6f7"; -} - -.fw-dgm-try-catch:before { - content:"\e6ec"; -} - -.fw-dgm-type-convertor:before { - content:"\e6f8"; -} - -.fw-dgm-type:before { - content:"\e6f9"; -} - -.fw-dgm-while:before { - content:"\e707"; -} - -.fw-dial-up:before { - content:"\e627"; -} - -.fw-disabled:before { - content:"\e6d1"; -} - -.fw-display:before { - content:"\e626"; -} - -.fw-docker:before { - content:"\e70c"; -} - -.fw-document:before { - content:"\e628"; -} - -.fw-down-arrow:before { - content:"\e689"; -} - -.fw-down:before { - content:"\e685"; -} - -.fw-download:before { - content:"\e65f"; -} - -.fw-dss:before { - content:"\e62a"; -} - -.fw-ebook:before { - content:"\e62b"; -} - -.fw-edit:before { - content:"\e62c"; -} - -.fw-ellipsis:before { - content:"\e629"; -} - -.fw-endpoint:before { - content:"\e62d"; -} - -.fw-enterprise:before { - content:"\e6b6"; -} - -.fw-error:before { - content:"\e630"; -} - -.fw-esb-connector:before { - content:"\e6e3"; -} - -.fw-expand:before { - content:"\e61c"; -} - -.fw-export:before { - content:"\e631"; -} - -.fw-extensions:before { - content:"\e6e4"; -} - -.fw-facebook:before { - content:"\e6d3"; -} - -.fw-factory-reset:before { - content:"\e632"; -} - -.fw-fan:before { - content:"\e678"; -} - -.fw-faq:before { - content:"\e62f"; -} - -.fw-file-browse:before { - content:"\e633"; -} - -.fw-filter:before { - content:"\e634"; -} - -.fw-folder-open:before { - content:"\e70b"; -} - -.fw-folder:before { - content:"\e62e"; -} - -.fw-fork-join:before { - content:"\e720"; -} - -.fw-format:before { - content:"\e6fa"; -} - -.fw-forum:before { - content:"\e636"; -} - -.fw-function-invoke:before { - content:"\e713"; -} - -.fw-function:before { - content:"\e6fb"; -} - -.fw-gadget:before { - content:"\e637"; -} - -.fw-geo-fence-inbound:before { - content:"\e72e"; -} - -.fw-geo-fence-outbound:before { - content:"\e72f"; -} - -.fw-github:before { - content:"\e6d4"; -} - -.fw-globe:before { - content:"\e697"; -} - -.fw-google-docs:before { - content:"\e6d6"; -} - -.fw-google-drive:before { - content:"\e6da"; -} - -.fw-google-plus:before { - content:"\e6d9"; -} - -.fw-google-sheets:before { - content:"\e6d7"; -} - -.fw-google-slides:before { - content:"\e6d8"; -} - -.fw-google:before { - content:"\e6d5"; -} - -.fw-grid:before { - content:"\e638"; -} - -.fw-grip:before { - content:"\e6b7"; -} - -.fw-group:before { - content:"\e6af"; -} - -.fw-hardware:before { - content:"\e6a9"; -} - -.fw-hdd:before { - content:"\e639"; -} - -.fw-heart:before { - content:"\e6c3"; -} - -.fw-hide:before { - content:"\e6d2"; -} - -.fw-home:before { - content:"\e63a"; -} - -.fw-hour-glass:before { - content:"\e63b"; -} - -.fw-html:before { - content:"\e69d"; -} - -.fw-http:before { - content:"\e705"; -} - -.fw-image:before { - content:"\e70a"; -} - -.fw-import:before { - content:"\e63c"; -} - -.fw-incoming-call:before { - content:"\e63d"; -} - -.fw-info:before { - content:"\e63e"; -} - -.fw-instagram:before { - content:"\e6db"; -} - -.fw-invitation:before { - content:"\e63f"; -} - -.fw-invoke:before { - content:"\e6ed"; -} - -.fw-is-connector:before { - content:"\e6e5"; -} - -.fw-iterate:before { - content:"\e71f"; -} - -.fw-jaggery:before { - content:"\e640"; -} - -.fw-java-spring:before { - content:"\e644"; -} - -.fw-java:before { - content:"\e641"; -} - -.fw-javaee:before { - content:"\e642"; -} - -.fw-javascript:before { - content:"\e643"; -} - -.fw-jaxrs:before { - content:"\e645"; -} - -.fw-jaxws:before { - content:"\e6c7"; -} - -.fw-jquery:before { - content:"\e646"; -} - -.fw-key:before { - content:"\e647"; -} - -.fw-laptop:before { - content:"\e648"; -} - -.fw-layout:before { - content:"\e6bf"; -} - -.fw-ldap:before { - content:"\e649"; -} - -.fw-left-arrow:before { - content:"\e68a"; -} - -.fw-left:before { - content:"\e686"; -} - -.fw-lifecycle:before { - content:"\e64a"; -} - -.fw-light:before { - content:"\e680"; -} - -.fw-linkedin:before { - content:"\e6dc"; -} - -.fw-list-sort:before { - content:"\e64d"; -} - -.fw-list:before { - content:"\e64c"; -} - -.fw-loader:before { - content:"\e6b4"; -} - -.fw-loader2:before { - content:"\e6ba"; -} - -.fw-loader3:before { - content:"\e6bb"; -} - -.fw-loader4:before { - content:"\e6bc"; -} - -.fw-loader5:before { - content:"\e6bd"; -} - -.fw-lock:before { - content:"\e64e"; -} - -.fw-logical:before { - content:"\e702"; -} - -.fw-mail:before { - content:"\e64f"; -} - -.fw-main-function:before { - content:"\e706"; -} - -.fw-map-location:before { - content:"\e650"; -} - -.fw-menu:before { - content:"\e651"; -} - -.fw-message:before { - content:"\e635"; -} - -.fw-micro-services:before { - content:"\e6ce"; -} - -.fw-minus:before, .fw-hyphen:before, .fw-dash:before { - content:"\e616"; -} - -.fw-mobile:before { - content:"\e652"; -} - -.fw-ms-document:before { - content:"\e654"; -} - -.fw-mute:before { - content:"\e655"; -} - -.fw-nodejs:before { - content:"\e656"; -} - -.fw-notification:before { - content:"\e60b"; -} - -.fw-organization:before { - content:"\e6ac"; -} - -.fw-own:before { - content:"\e6c8"; -} - -.fw-package:before { - content:"\e6fd"; -} - -.fw-pages:before { - content:"\e6c0"; -} - -.fw-paste:before { - content:"\e658"; -} - -.fw-pdf:before { - content:"\e659"; -} - -.fw-pending:before { - content:"\e727"; -} - -.fw-php:before { - content:"\e6c9"; -} - -.fw-pie-chart:before { - content:"\e65a"; -} - -.fw-pinterest:before { - content:"\e6dd"; -} - -.fw-policy:before { - content:"\e67d"; -} - -.fw-polygon:before { - content:"\e70d"; -} - -.fw-prototype:before { - content:"\e6cc"; -} - -.fw-proxy:before { - content:"\e699"; -} - -.fw-public:before { - content:"\e6ad"; -} - -.fw-publish:before { - content:"\e65c"; -} - -.fw-question:before { - content:"\e6b0"; -} - -.fw-raspberry:before { - content:"\e6aa"; -} - -.fw-redo:before { - content:"\e65d"; -} - -.fw-refresh:before { - content:"\e692"; -} - -.fw-register:before { - content:"\e65e"; -} - -.fw-rename:before { - content:"\e6fc"; -} - -.fw-reply:before { - content:"\e714"; -} - -.fw-resource:before { - content:"\e660"; -} - -.fw-rest-api:before { - content:"\e661"; -} - -.fw-rest-service:before { - content:"\e662"; -} - -.fw-resume:before { - content:"\e71e"; -} - -.fw-retire:before { - content:"\e6cd"; -} - -.fw-return:before { - content:"\e715"; -} - -.fw-retweet:before { - content:"\e6b9"; -} - -.fw-right-arrow:before { - content:"\e68b"; -} - -.fw-right:before { - content:"\e687"; -} - -.fw-ringing:before { - content:"\e694"; -} - -.fw-rules:before { - content:"\e664"; -} - -.fw-run:before { - content:"\e708"; -} - -.fw-save:before { - content:"\e665"; -} - -.fw-scep:before { - content:"\e666"; -} - -.fw-schema:before { - content:"\e667"; -} - -.fw-search:before { - content:"\e668"; -} - -.fw-security-policy:before { - content:"\e67e"; -} - -.fw-security:before { - content:"\e669"; -} - -.fw-send:before, .fw-paper-rocket:before { - content:"\e66a"; -} - -.fw-sequence:before { - content:"\e66b"; -} - -.fw-server:before { - content:"\e66c"; -} - -.fw-service-provider:before { - content:"\e66e"; -} - -.fw-service:before, .fw-cogwheels:before, .fw-gears:before, .fw-sprockets:before { - content:"\e66d"; -} - -.fw-settings:before, .fw-cogwheel:before, .fw-gear:before, .fw-sprocket:before { - content:"\e66f"; -} - -.fw-share:before { - content:"\e670"; -} - -.fw-shell:before { - content:"\e730"; -} - -.fw-shortcut:before { - content:"\e725"; -} - -.fw-sign-in:before { - content:"\e671"; -} - -.fw-sign-out:before { - content:"\e6b8"; -} - -.fw-skype:before { - content:"\e6de"; -} - -.fw-slash:before { - content:"\e6e1"; -} - -.fw-soap:before { - content:"\e672"; -} - -.fw-sort-down:before { - content:"\e663"; -} - -.fw-sort-up:before { - content:"\e64b"; -} - -.fw-sort:before { - content:"\e673"; -} - -.fw-speed-alert:before { - content:"\e731"; -} - -.fw-square-outline:before { - content:"\e6b2"; -} - -.fw-square:before { - content:"\e6b1"; -} - -.fw-star:before { - content:"\e674"; -} - -.fw-start:before { - content:"\e718"; -} - -.fw-statistics:before { - content:"\e675"; -} - -.fw-stepin:before { - content:"\e719"; -} - -.fw-stepout:before { - content:"\e71a"; -} - -.fw-stepover:before { - content:"\e71b"; -} - -.fw-stop:before { - content:"\e71c"; -} - -.fw-store:before, .fw-cart:before { - content:"\e676"; -} - -.fw-struct:before { - content:"\e716"; -} - -.fw-subscribe:before { - content:"\e677"; -} - -.fw-success:before { - content:"\e657"; -} - -.fw-swagger:before { - content:"\e679"; -} - -.fw-sync:before { - content:"\e6b3"; -} - -.fw-table:before { - content:"\e6c4"; -} - -.fw-tag:before { - content:"\e67a"; -} - -.fw-task:before { - content:"\e67b"; -} - -.fw-text:before { - content:"\e67c"; -} - -.fw-theme:before { - content:"\e726"; -} - -.fw-throttling-policy:before { - content:"\e67f"; -} - -.fw-throw:before { - content:"\e722"; -} - -.fw-tiles:before { - content:"\e681"; -} - -.fw-transaction:before { - content:"\e72b"; -} - -.fw-try-catch:before { - content:"\e703"; -} - -.fw-twitter:before { - content:"\e6df"; -} - -.fw-type-converter:before { - content:"\e6f3"; -} - -.fw-uncheck:before { - content:"\e682"; -} - -.fw-undo:before { - content:"\e683"; -} - -.fw-ungroup:before { - content:"\e6b5"; -} - -.fw-unmute:before { - content:"\e6ae"; -} - -.fw-up-arrow:before { - content:"\e688"; -} - -.fw-up:before { - content:"\e684"; -} - -.fw-upload:before { - content:"\e68c"; -} - -.fw-uri:before { - content:"\e68d"; -} - -.fw-usb-drive:before { - content:"\e68e"; -} - -.fw-use:before { - content:"\e6ca"; -} - -.fw-user:before { - content:"\e68f"; -} - -.fw-variable:before { - content:"\e6ee"; -} - -.fw-view:before { - content:"\e691"; -} - -.fw-vpn:before { - content:"\e603"; -} - -.fw-wadl:before { - content:"\e6a1"; -} - -.fw-war:before { - content:"\e69e"; -} - -.fw-warning:before { - content:"\e693"; -} - -.fw-web-app:before { - content:"\e696"; -} - -.fw-web-clip:before { - content:"\e698"; -} - -.fw-web-service:before { - content:"\e69a"; -} - -.fw-website:before { - content:"\e69b"; -} - -.fw-wifi:before { - content:"\e607"; -} - -.fw-windows:before { - content:"\e605"; -} - -.fw-worker-invoke:before { - content:"\e723"; -} - -.fw-worker-reply:before { - content:"\e724"; -} - -.fw-worker:before { - content:"\e6ef"; -} - -.fw-wsdl:before { - content:"\e6a0"; -} - -.fw-wso2-logo:before { - content:"\e6a7"; -} - -.fw-wso2:before { - content:"\e6a8"; -} - -.fw-xacml:before { - content:"\e69f"; -} - -.fw-xml:before { - content:"\e69c"; -} - -.fw-xq:before { - content:"\e6a2"; -} - -.fw-xsd:before { - content:"\e6a3"; -} - -.fw-xslt:before { - content:"\e6a4"; -} - -.fw-youtube:before { - content:"\e6e0"; -} - -.fw-zoom-in:before { - content:"\e6a5"; -} - -.fw-zoom-out:before { - content:"\e6a6"; -} - diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/font-wso2.min.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/font-wso2.min.css deleted file mode 100644 index 8d948cfa6b..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/font-wso2.min.css +++ /dev/null @@ -1,17 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */.fw-fw,.fw-li{text-align:center}@font-face{font-family:font-wso2;src:local("font-wso2"),url(../fonts/font-wso2.eot?6563fa91278f239ef8c827d90a165223);src:local("font-wso2"),url(../fonts/font-wso2.eot?#iefix) format("embedded-opentype"),url(../fonts/font-wso2.woff2?6563fa91278f239ef8c827d90a165223) format("woff2"),url(../fonts/font-wso2.woff?6563fa91278f239ef8c827d90a165223) format("woff"),url(../fonts/font-wso2.ttf?6563fa91278f239ef8c827d90a165223) format("truetype"),url(../fonts/font-wso2.svg?6563fa91278f239ef8c827d90a165223#font-wso2) format("svg");font-weight:400;font-style:normal}.fw,[class*=" fw-"],[class^=fw-]{font:normal normal normal 14px/1 font-wso2;display:inline-block;font-weight:400;font-style:normal;font-size:inherit;font-variant:normal;speak:none;text-decoration:inherit;text-transform:none;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fw-lg{font-size:1.33333333em;line-height:.75em;vertical-align:-15%}.fw-2x{font-size:2em}.fw-3x{font-size:3em}.fw-4x{font-size:4em}.fw-5x{font-size:5em}.fw-fw{width:1.28571429em}.fw-ul{padding-left:0;margin-left:2.14285714em;list-style-type:none}.fw-ul>li{position:relative}.fw-li{position:absolute;left:-2.14285714em;width:2.14285714em;top:.14285714em}.fw-li.fw-lg{left:-1.85714286em}.fw-border{padding:.2em .25em .15em;border:.08em solid #eee;border-radius:.1em}.fw-background{background:#888;border-radius:.3em;padding:.4em .5em .45em}.fw-pull-left{float:left}.fw-pull-right{float:right}.fw.fw-pull-left{margin-right:.3em}.fw.fw-pull-right{margin-left:.3em}.fw-spin{-webkit-animation:fw-spin 2s infinite linear;animation:fw-spin 2s infinite linear}@-webkit-keyframes fw-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fw-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fw-pulse{-webkit-animation:fw-pulse 2s ease-out infinite;animation:fw-pulse 2s ease-out infinite}@-webkit-keyframes fw-pulse{0%,100%,30%{opacity:.3}40%{opacity:1}}@keyframes fw-pulse{0%,100%,30%{opacity:.3}40%{opacity:1}}.fw-rotate-90{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=1);-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fw-rotate-180{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fw-rotate-270{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fw-flip-horizontal{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1);-webkit-transform:scale(-1,1);-ms-transform:scale(-1,1);transform:scale(-1,1)}.fw-flip-vertical{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1);-webkit-transform:scale(1,-1);-ms-transform:scale(1,-1);transform:scale(1,-1)}:root .fw-flip-horizontal,:root .fw-flip-vertical,:root .fw-rotate-180,:root .fw-rotate-270,:root .fw-rotate-90{filter:none}.fw-helper,.fw-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:1.85em;vertical-align:middle}.fw-helper:after,.fw-helper:before,.fw-stack-1x,.fw-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fw-helper:before,.fw-stack-1x{line-height:inherit}.fw-helper:after,.fw-stack-2x{font-size:1.9em}.fw-helper-slash:before{font-size:1.4em}.fw-helper-circle:before,.fw-helper-square:before{z-index:1}.fw-helper-circle-outline:after{content:"\e61f"}.fw-helper-circle:after{content:"\e61a"}.fw-helper-square-outline:after{content:"\e6b2"}.fw-helper-square:after{content:"\e6b1"}.fw-helper-slash:after{content:"\e6e1"}.fw-stack>.fw-stack{position:absolute;font-size:.5em}.fw-stack>.fw-stack.fw-move-top{top:-.2em}.fw-stack>.fw-stack.fw-move-bottom{bottom:-.2em}.fw-stack>.fw.stack.fw-move-left{left:-.5em}.fw-stack>.fw-stack.fw-move-right{right:-.5em}.fw-helper-inverse:after,.fw-inverse:before,.fw-number{color:#fff}.fw-helper-shadow:after,.fw-shadow:before{text-shadow:#fff 1px 1px 0}.fw-helper-stroke:after,.fw-stroke:before{text-shadow:-2px -2px 0 #fff,2px -2px 0 #fff,-2px 2px 0 #fff,2px 2px 0 #fff}.fw-number{line-height:2em;font-family:Arial,Helvetica,sans-serif}.fw-abort:before{content:"\e72a"}.fw-action-invoke:before{content:"\e6fe"}.fw-action:before{content:"\e709"}.fw-activate:before{content:"\e6cf"}.fw-add:before{content:"\e615"}.fw-airplay:before{content:"\e600"}.fw-alarm:before{content:"\e6c2"}.fw-alert:before{content:"\e6be"}.fw-analytics-extensions:before{content:"\e6e2"}.fw-android-logcat:before{content:"\e72c"}.fw-android-sense:before{content:"\e72d"}.fw-android:before{content:"\e606"}.fw-annotation:before{content:"\e6e6"}.fw-api:before{content:"\e601"}.fw-apn:before{content:"\e602"}.fw-apple:before{content:"\e604"}.fw-application:before{content:"\e608"}.fw-arduino:before{content:"\e6ab"}.fw-assign:before{content:"\e6ff"}.fw-ballerina-service:before{content:"\e729"}.fw-ballerina:before{content:"\e728"}.fw-bar-chart:before{content:"\e690"}.fw-battery:before{content:"\e60a"}.fw-blank-document:before{content:"\e60c"}.fw-block:before{content:"\e695"}.fw-bookmark:before{content:"\e60d"}.fw-bpel:before{content:"\e60e"}.fw-bpmn:before{content:"\e60f"}.fw-break:before{content:"\e721"}.fw-bug:before{content:"\e611"}.fw-build:before{content:"\e6c1"}.fw-calendar:before{content:"\e612"}.fw-camera:before{content:"\e613"}.fw-cancel:before{content:"\e618"}.fw-carbon:before{content:"\e6c5"}.fw-chat:before{content:"\e65b"}.fw-check:before{content:"\e617"}.fw-checklist:before{content:"\e619"}.fw-circle-outline:before{content:"\e61f"}.fw-circle:before{content:"\e61a"}.fw-clear:before{content:"\e61b"}.fw-clock:before{content:"\e61d"}.fw-cloud:before{content:"\e61e"}.fw-code-view:before{content:"\e70e"}.fw-code:before{content:"\e6f1"}.fw-comment:before{content:"\e710"}.fw-compare:before{content:"\e610"}.fw-computer:before{content:"\e653"}.fw-configarations:before{content:"\e609"}.fw-connector:before{content:"\e700"}.fw-console:before{content:"\e71d"}.fw-constant:before{content:"\e701"}.fw-contact:before{content:"\e620"}.fw-contract:before{content:"\e614"}.fw-copy:before{content:"\e621"}.fw-cut:before{content:"\e6f2"}.fw-dashboard:before{content:"\e622"}.fw-database:before{content:"\e623"}.fw-delete:before{content:"\e624"}.fw-depend:before{content:"\e6c6"}.fw-deploy:before{content:"\e625"}.fw-deprecate:before{content:"\e6cb"}.fw-design-view:before{content:"\e70f"}.fw-devices:before{content:"\e704"}.fw-dgm-action-invoke:before{content:"\e712"}.fw-dgm-action:before{content:"\e711"}.fw-dgm-connector:before{content:"\e6f4"}.fw-dgm-constant-definition:before{content:"\e6f5"}.fw-dgm-fork:before{content:"\e6e7"}.fw-dgm-header:before{content:"\e6e8"}.fw-dgm-if-else:before{content:"\e6e9"}.fw-dgm-import:before{content:"\e717"}.fw-dgm-lifeline:before{content:"\e6ea"}.fw-dgm-logger:before{content:"\e6eb"}.fw-dgm-resource:before{content:"\e6f6"}.fw-dgm-service:before{content:"\e6f7"}.fw-dgm-try-catch:before{content:"\e6ec"}.fw-dgm-type-convertor:before{content:"\e6f8"}.fw-dgm-type:before{content:"\e6f9"}.fw-dgm-while:before{content:"\e707"}.fw-dial-up:before{content:"\e627"}.fw-disabled:before{content:"\e6d1"}.fw-display:before{content:"\e626"}.fw-docker:before{content:"\e70c"}.fw-document:before{content:"\e628"}.fw-down-arrow:before{content:"\e689"}.fw-down:before{content:"\e685"}.fw-download:before{content:"\e65f"}.fw-dss:before{content:"\e62a"}.fw-ebook:before{content:"\e62b"}.fw-edit:before{content:"\e62c"}.fw-ellipsis:before{content:"\e629"}.fw-endpoint:before{content:"\e62d"}.fw-enterprise:before{content:"\e6b6"}.fw-error:before{content:"\e630"}.fw-esb-connector:before{content:"\e6e3"}.fw-expand:before{content:"\e61c"}.fw-export:before{content:"\e631"}.fw-extensions:before{content:"\e6e4"}.fw-facebook:before{content:"\e6d3"}.fw-factory-reset:before{content:"\e632"}.fw-fan:before{content:"\e678"}.fw-faq:before{content:"\e62f"}.fw-file-browse:before{content:"\e633"}.fw-filter:before{content:"\e634"}.fw-folder-open:before{content:"\e70b"}.fw-folder:before{content:"\e62e"}.fw-fork-join:before{content:"\e720"}.fw-format:before{content:"\e6fa"}.fw-forum:before{content:"\e636"}.fw-function-invoke:before{content:"\e713"}.fw-function:before{content:"\e6fb"}.fw-gadget:before{content:"\e637"}.fw-geo-fence-inbound:before{content:"\e72e"}.fw-geo-fence-outbound:before{content:"\e72f"}.fw-github:before{content:"\e6d4"}.fw-globe:before{content:"\e697"}.fw-google-docs:before{content:"\e6d6"}.fw-google-drive:before{content:"\e6da"}.fw-google-plus:before{content:"\e6d9"}.fw-google-sheets:before{content:"\e6d7"}.fw-google-slides:before{content:"\e6d8"}.fw-google:before{content:"\e6d5"}.fw-grid:before{content:"\e638"}.fw-grip:before{content:"\e6b7"}.fw-group:before{content:"\e6af"}.fw-hardware:before{content:"\e6a9"}.fw-hdd:before{content:"\e639"}.fw-heart:before{content:"\e6c3"}.fw-hide:before{content:"\e6d2"}.fw-home:before{content:"\e63a"}.fw-hour-glass:before{content:"\e63b"}.fw-html:before{content:"\e69d"}.fw-http:before{content:"\e705"}.fw-image:before{content:"\e70a"}.fw-import:before{content:"\e63c"}.fw-incoming-call:before{content:"\e63d"}.fw-info:before{content:"\e63e"}.fw-instagram:before{content:"\e6db"}.fw-invitation:before{content:"\e63f"}.fw-invoke:before{content:"\e6ed"}.fw-is-connector:before{content:"\e6e5"}.fw-iterate:before{content:"\e71f"}.fw-jaggery:before{content:"\e640"}.fw-java-spring:before{content:"\e644"}.fw-java:before{content:"\e641"}.fw-javaee:before{content:"\e642"}.fw-javascript:before{content:"\e643"}.fw-jaxrs:before{content:"\e645"}.fw-jaxws:before{content:"\e6c7"}.fw-jquery:before{content:"\e646"}.fw-key:before{content:"\e647"}.fw-laptop:before{content:"\e648"}.fw-layout:before{content:"\e6bf"}.fw-ldap:before{content:"\e649"}.fw-left-arrow:before{content:"\e68a"}.fw-left:before{content:"\e686"}.fw-lifecycle:before{content:"\e64a"}.fw-light:before{content:"\e680"}.fw-linkedin:before{content:"\e6dc"}.fw-list-sort:before{content:"\e64d"}.fw-list:before{content:"\e64c"}.fw-loader:before{content:"\e6b4"}.fw-loader2:before{content:"\e6ba"}.fw-loader3:before{content:"\e6bb"}.fw-loader4:before{content:"\e6bc"}.fw-loader5:before{content:"\e6bd"}.fw-lock:before{content:"\e64e"}.fw-logical:before{content:"\e702"}.fw-mail:before{content:"\e64f"}.fw-main-function:before{content:"\e706"}.fw-map-location:before{content:"\e650"}.fw-menu:before{content:"\e651"}.fw-message:before{content:"\e635"}.fw-micro-services:before{content:"\e6ce"}.fw-dash:before,.fw-hyphen:before,.fw-minus:before{content:"\e616"}.fw-mobile:before{content:"\e652"}.fw-ms-document:before{content:"\e654"}.fw-mute:before{content:"\e655"}.fw-nodejs:before{content:"\e656"}.fw-notification:before{content:"\e60b"}.fw-organization:before{content:"\e6ac"}.fw-own:before{content:"\e6c8"}.fw-package:before{content:"\e6fd"}.fw-pages:before{content:"\e6c0"}.fw-paste:before{content:"\e658"}.fw-pdf:before{content:"\e659"}.fw-pending:before{content:"\e727"}.fw-php:before{content:"\e6c9"}.fw-pie-chart:before{content:"\e65a"}.fw-pinterest:before{content:"\e6dd"}.fw-policy:before{content:"\e67d"}.fw-polygon:before{content:"\e70d"}.fw-prototype:before{content:"\e6cc"}.fw-proxy:before{content:"\e699"}.fw-public:before{content:"\e6ad"}.fw-publish:before{content:"\e65c"}.fw-question:before{content:"\e6b0"}.fw-raspberry:before{content:"\e6aa"}.fw-redo:before{content:"\e65d"}.fw-refresh:before{content:"\e692"}.fw-register:before{content:"\e65e"}.fw-rename:before{content:"\e6fc"}.fw-reply:before{content:"\e714"}.fw-resource:before{content:"\e660"}.fw-rest-api:before{content:"\e661"}.fw-rest-service:before{content:"\e662"}.fw-resume:before{content:"\e71e"}.fw-retire:before{content:"\e6cd"}.fw-return:before{content:"\e715"}.fw-retweet:before{content:"\e6b9"}.fw-right-arrow:before{content:"\e68b"}.fw-right:before{content:"\e687"}.fw-ringing:before{content:"\e694"}.fw-rules:before{content:"\e664"}.fw-run:before{content:"\e708"}.fw-save:before{content:"\e665"}.fw-scep:before{content:"\e666"}.fw-schema:before{content:"\e667"}.fw-search:before{content:"\e668"}.fw-security-policy:before{content:"\e67e"}.fw-security:before{content:"\e669"}.fw-paper-rocket:before,.fw-send:before{content:"\e66a"}.fw-sequence:before{content:"\e66b"}.fw-server:before{content:"\e66c"}.fw-service-provider:before{content:"\e66e"}.fw-cogwheels:before,.fw-gears:before,.fw-service:before,.fw-sprockets:before{content:"\e66d"}.fw-cogwheel:before,.fw-gear:before,.fw-settings:before,.fw-sprocket:before{content:"\e66f"}.fw-share:before{content:"\e670"}.fw-shell:before{content:"\e730"}.fw-shortcut:before{content:"\e725"}.fw-sign-in:before{content:"\e671"}.fw-sign-out:before{content:"\e6b8"}.fw-skype:before{content:"\e6de"}.fw-slash:before{content:"\e6e1"}.fw-soap:before{content:"\e672"}.fw-sort-down:before{content:"\e663"}.fw-sort-up:before{content:"\e64b"}.fw-sort:before{content:"\e673"}.fw-speed-alert:before{content:"\e731"}.fw-square-outline:before{content:"\e6b2"}.fw-square:before{content:"\e6b1"}.fw-star:before{content:"\e674"}.fw-start:before{content:"\e718"}.fw-statistics:before{content:"\e675"}.fw-stepin:before{content:"\e719"}.fw-stepout:before{content:"\e71a"}.fw-stepover:before{content:"\e71b"}.fw-stop:before{content:"\e71c"}.fw-cart:before,.fw-store:before{content:"\e676"}.fw-struct:before{content:"\e716"}.fw-subscribe:before{content:"\e677"}.fw-success:before{content:"\e657"}.fw-swagger:before{content:"\e679"}.fw-sync:before{content:"\e6b3"}.fw-table:before{content:"\e6c4"}.fw-tag:before{content:"\e67a"}.fw-task:before{content:"\e67b"}.fw-text:before{content:"\e67c"}.fw-theme:before{content:"\e726"}.fw-throttling-policy:before{content:"\e67f"}.fw-throw:before{content:"\e722"}.fw-tiles:before{content:"\e681"}.fw-transaction:before{content:"\e72b"}.fw-try-catch:before{content:"\e703"}.fw-twitter:before{content:"\e6df"}.fw-type-converter:before{content:"\e6f3"}.fw-uncheck:before{content:"\e682"}.fw-undo:before{content:"\e683"}.fw-ungroup:before{content:"\e6b5"}.fw-unmute:before{content:"\e6ae"}.fw-up-arrow:before{content:"\e688"}.fw-up:before{content:"\e684"}.fw-upload:before{content:"\e68c"}.fw-uri:before{content:"\e68d"}.fw-usb-drive:before{content:"\e68e"}.fw-use:before{content:"\e6ca"}.fw-user:before{content:"\e68f"}.fw-variable:before{content:"\e6ee"}.fw-view:before{content:"\e691"}.fw-vpn:before{content:"\e603"}.fw-wadl:before{content:"\e6a1"}.fw-war:before{content:"\e69e"}.fw-warning:before{content:"\e693"}.fw-web-app:before{content:"\e696"}.fw-web-clip:before{content:"\e698"}.fw-web-service:before{content:"\e69a"}.fw-website:before{content:"\e69b"}.fw-wifi:before{content:"\e607"}.fw-windows:before{content:"\e605"}.fw-worker-invoke:before{content:"\e723"}.fw-worker-reply:before{content:"\e724"}.fw-worker:before{content:"\e6ef"}.fw-wsdl:before{content:"\e6a0"}.fw-wso2-logo:before{content:"\e6a7"}.fw-wso2:before{content:"\e6a8"}.fw-xacml:before{content:"\e69f"}.fw-xml:before{content:"\e69c"}.fw-xq:before{content:"\e6a2"}.fw-xsd:before{content:"\e6a3"}.fw-xslt:before{content:"\e6a4"}.fw-youtube:before{content:"\e6e0"}.fw-zoom-in:before{content:"\e6a5"}.fw-zoom-out:before{content:"\e6a6"} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/leaflet.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/leaflet.css deleted file mode 100644 index 6f609e1180..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/css/leaflet.css +++ /dev/null @@ -1,636 +0,0 @@ -/* required styles */ - -.leaflet-pane, -.leaflet-tile, -.leaflet-marker-icon, -.leaflet-marker-shadow, -.leaflet-tile-container, -.leaflet-pane > svg, -.leaflet-pane > canvas, -.leaflet-zoom-box, -.leaflet-image-layer, -.leaflet-layer { - position: absolute; - left: 0; - top: 0; -} -.leaflet-container { - overflow: hidden; -} -.leaflet-tile, -.leaflet-marker-icon, -.leaflet-marker-shadow { - -webkit-user-select: none; - -moz-user-select: none; - user-select: none; - -webkit-user-drag: none; -} -/* Safari renders non-retina tile on retina better with this, but Chrome is worse */ -.leaflet-safari .leaflet-tile { - image-rendering: -webkit-optimize-contrast; -} -/* hack that prevents hw layers "stretching" when loading new tiles */ -.leaflet-safari .leaflet-tile-container { - width: 1600px; - height: 1600px; - -webkit-transform-origin: 0 0; -} -.leaflet-marker-icon, -.leaflet-marker-shadow { - display: block; -} -/* .leaflet-container svg: reset svg max-width decleration shipped in Joomla! (joomla.org) 3.x */ -/* .leaflet-container img: map is broken in FF if you have max-width: 100% on tiles */ -.leaflet-container .leaflet-overlay-pane svg, -.leaflet-container .leaflet-marker-pane img, -.leaflet-container .leaflet-shadow-pane img, -.leaflet-container .leaflet-tile-pane img, -.leaflet-container img.leaflet-image-layer { - max-width: none !important; - max-height: none !important; -} - -.leaflet-container.leaflet-touch-zoom { - -ms-touch-action: pan-x pan-y; - touch-action: pan-x pan-y; -} -.leaflet-container.leaflet-touch-drag { - -ms-touch-action: pinch-zoom; - /* Fallback for FF which doesn't support pinch-zoom */ - touch-action: none; - touch-action: pinch-zoom; -} -.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom { - -ms-touch-action: none; - touch-action: none; -} -.leaflet-container { - -webkit-tap-highlight-color: transparent; -} -.leaflet-container a { - -webkit-tap-highlight-color: rgba(51, 181, 229, 0.4); -} -.leaflet-tile { - filter: inherit; - visibility: hidden; -} -.leaflet-tile-loaded { - visibility: inherit; -} -.leaflet-zoom-box { - width: 0; - height: 0; - -moz-box-sizing: border-box; - box-sizing: border-box; - z-index: 800; -} -/* workaround for https://bugzilla.mozilla.org/show_bug.cgi?id=888319 */ -.leaflet-overlay-pane svg { - -moz-user-select: none; -} - -.leaflet-pane { z-index: 400; } - -.leaflet-tile-pane { z-index: 200; } -.leaflet-overlay-pane { z-index: 400; } -.leaflet-shadow-pane { z-index: 500; } -.leaflet-marker-pane { z-index: 600; } -.leaflet-tooltip-pane { z-index: 650; } -.leaflet-popup-pane { z-index: 700; } - -.leaflet-map-pane canvas { z-index: 100; } -.leaflet-map-pane svg { z-index: 200; } - -.leaflet-vml-shape { - width: 1px; - height: 1px; -} -.lvml { - behavior: url(#default#VML); - display: inline-block; - position: absolute; -} - - -/* control positioning */ - -.leaflet-control { - position: relative; - z-index: 800; - pointer-events: visiblePainted; /* IE 9-10 doesn't have auto */ - pointer-events: auto; -} -.leaflet-top, -.leaflet-bottom { - position: absolute; - z-index: 1000; - pointer-events: none; -} -.leaflet-top { - top: 0; -} -.leaflet-right { - right: 0; -} -.leaflet-bottom { - bottom: 0; -} -.leaflet-left { - left: 0; -} -.leaflet-control { - float: left; - clear: both; -} -.leaflet-right .leaflet-control { - float: right; -} -.leaflet-top .leaflet-control { - margin-top: 10px; -} -.leaflet-bottom .leaflet-control { - margin-bottom: 10px; -} -.leaflet-left .leaflet-control { - margin-left: 10px; -} -.leaflet-right .leaflet-control { - margin-right: 10px; -} - - -/* zoom and fade animations */ - -.leaflet-fade-anim .leaflet-tile { - will-change: opacity; -} -.leaflet-fade-anim .leaflet-popup { - opacity: 0; - -webkit-transition: opacity 0.2s linear; - -moz-transition: opacity 0.2s linear; - -o-transition: opacity 0.2s linear; - transition: opacity 0.2s linear; -} -.leaflet-fade-anim .leaflet-map-pane .leaflet-popup { - opacity: 1; -} -.leaflet-zoom-animated { - -webkit-transform-origin: 0 0; - -ms-transform-origin: 0 0; - transform-origin: 0 0; -} -.leaflet-zoom-anim .leaflet-zoom-animated { - will-change: transform; -} -.leaflet-zoom-anim .leaflet-zoom-animated { - -webkit-transition: -webkit-transform 0.25s cubic-bezier(0,0,0.25,1); - -moz-transition: -moz-transform 0.25s cubic-bezier(0,0,0.25,1); - -o-transition: -o-transform 0.25s cubic-bezier(0,0,0.25,1); - transition: transform 0.25s cubic-bezier(0,0,0.25,1); -} -.leaflet-zoom-anim .leaflet-tile, -.leaflet-pan-anim .leaflet-tile { - -webkit-transition: none; - -moz-transition: none; - -o-transition: none; - transition: none; -} - -.leaflet-zoom-anim .leaflet-zoom-hide { - visibility: hidden; -} - - -/* cursors */ - -.leaflet-interactive { - cursor: pointer; -} -.leaflet-grab { - cursor: -webkit-grab; - cursor: -moz-grab; -} -.leaflet-crosshair, -.leaflet-crosshair .leaflet-interactive { - cursor: crosshair; -} -.leaflet-popup-pane, -.leaflet-control { - cursor: auto; -} -.leaflet-dragging .leaflet-grab, -.leaflet-dragging .leaflet-grab .leaflet-interactive, -.leaflet-dragging .leaflet-marker-draggable { - cursor: move; - cursor: -webkit-grabbing; - cursor: -moz-grabbing; -} - -/* marker & overlays interactivity */ -.leaflet-marker-icon, -.leaflet-marker-shadow, -.leaflet-image-layer, -.leaflet-pane > svg path, -.leaflet-tile-container { - pointer-events: none; -} - -.leaflet-marker-icon.leaflet-interactive, -.leaflet-image-layer.leaflet-interactive, -.leaflet-pane > svg path.leaflet-interactive { - pointer-events: visiblePainted; /* IE 9-10 doesn't have auto */ - pointer-events: auto; -} - -/* visual tweaks */ - -.leaflet-container { - background: #ddd; - outline: 0; -} -.leaflet-container a { - color: #0078A8; -} -.leaflet-container a.leaflet-active { - outline: 2px solid orange; -} -.leaflet-zoom-box { - border: 2px dotted #38f; - background: rgba(255,255,255,0.5); -} - - -/* general typography */ -.leaflet-container { - font: 12px/1.5 "Helvetica Neue", Arial, Helvetica, sans-serif; -} - - -/* general toolbar styles */ - -.leaflet-bar { - box-shadow: 0 1px 5px rgba(0,0,0,0.65); - border-radius: 4px; -} -.leaflet-bar a, -.leaflet-bar a:hover { - background-color: #fff; - border-bottom: 1px solid #ccc; - width: 26px; - height: 26px; - line-height: 26px; - display: block; - text-align: center; - text-decoration: none; - color: black; -} -.leaflet-bar a, -.leaflet-control-layers-toggle { - background-position: 50% 50%; - background-repeat: no-repeat; - display: block; -} -.leaflet-bar a:hover { - background-color: #f4f4f4; -} -.leaflet-bar a:first-child { - border-top-left-radius: 4px; - border-top-right-radius: 4px; -} -.leaflet-bar a:last-child { - border-bottom-left-radius: 4px; - border-bottom-right-radius: 4px; - border-bottom: none; -} -.leaflet-bar a.leaflet-disabled { - cursor: default; - background-color: #f4f4f4; - color: #bbb; -} - -.leaflet-touch .leaflet-bar a { - width: 30px; - height: 30px; - line-height: 30px; -} -.leaflet-touch .leaflet-bar a:first-child { - border-top-left-radius: 2px; - border-top-right-radius: 2px; -} -.leaflet-touch .leaflet-bar a:last-child { - border-bottom-left-radius: 2px; - border-bottom-right-radius: 2px; -} - -/* zoom control */ - -.leaflet-control-zoom-in, -.leaflet-control-zoom-out { - font: bold 18px 'Lucida Console', Monaco, monospace; - text-indent: 1px; -} - -.leaflet-touch .leaflet-control-zoom-in, .leaflet-touch .leaflet-control-zoom-out { - font-size: 22px; -} - - -/* layers control */ - -.leaflet-control-layers { - box-shadow: 0 1px 5px rgba(0,0,0,0.4); - background: #fff; - border-radius: 5px; -} -.leaflet-control-layers-toggle { - background-image: url(images/layers.png); - width: 36px; - height: 36px; -} -.leaflet-retina .leaflet-control-layers-toggle { - background-image: url(images/layers-2x.png); - background-size: 26px 26px; -} -.leaflet-touch .leaflet-control-layers-toggle { - width: 44px; - height: 44px; -} -.leaflet-control-layers .leaflet-control-layers-list, -.leaflet-control-layers-expanded .leaflet-control-layers-toggle { - display: none; -} -.leaflet-control-layers-expanded .leaflet-control-layers-list { - display: block; - position: relative; -} -.leaflet-control-layers-expanded { - padding: 6px 10px 6px 6px; - color: #333; - background: #fff; -} -.leaflet-control-layers-scrollbar { - overflow-y: scroll; - overflow-x: hidden; - padding-right: 5px; -} -.leaflet-control-layers-selector { - margin-top: 2px; - position: relative; - top: 1px; -} -.leaflet-control-layers label { - display: block; -} -.leaflet-control-layers-separator { - height: 0; - border-top: 1px solid #ddd; - margin: 5px -10px 5px -6px; -} - -/* Default icon URLs */ -.leaflet-default-icon-path { - background-image: url(images/marker-icon.png); -} - - -/* attribution and scale controls */ - -.leaflet-container .leaflet-control-attribution { - background: #fff; - background: rgba(255, 255, 255, 0.7); - margin: 0; -} -.leaflet-control-attribution, -.leaflet-control-scale-line { - padding: 0 5px; - color: #333; -} -.leaflet-control-attribution a { - text-decoration: none; -} -.leaflet-control-attribution a:hover { - text-decoration: underline; -} -.leaflet-container .leaflet-control-attribution, -.leaflet-container .leaflet-control-scale { - font-size: 11px; -} -.leaflet-left .leaflet-control-scale { - margin-left: 5px; -} -.leaflet-bottom .leaflet-control-scale { - margin-bottom: 5px; -} -.leaflet-control-scale-line { - border: 2px solid #777; - border-top: none; - line-height: 1.1; - padding: 2px 5px 1px; - font-size: 11px; - white-space: nowrap; - overflow: hidden; - -moz-box-sizing: border-box; - box-sizing: border-box; - - background: #fff; - background: rgba(255, 255, 255, 0.5); -} -.leaflet-control-scale-line:not(:first-child) { - border-top: 2px solid #777; - border-bottom: none; - margin-top: -2px; -} -.leaflet-control-scale-line:not(:first-child):not(:last-child) { - border-bottom: 2px solid #777; -} - -.leaflet-touch .leaflet-control-attribution, -.leaflet-touch .leaflet-control-layers, -.leaflet-touch .leaflet-bar { - box-shadow: none; -} -.leaflet-touch .leaflet-control-layers, -.leaflet-touch .leaflet-bar { - border: 2px solid rgba(0,0,0,0.2); - background-clip: padding-box; -} - - -/* popup */ - -.leaflet-popup { - position: absolute; - text-align: center; - margin-bottom: 20px; -} -.leaflet-popup-content-wrapper { - padding: 1px; - text-align: left; - border-radius: 12px; -} -.leaflet-popup-content { - margin: 13px 19px; - line-height: 1.4; -} -.leaflet-popup-content p { - margin: 18px 0; -} -.leaflet-popup-tip-container { - width: 40px; - height: 20px; - position: absolute; - left: 50%; - margin-left: -20px; - overflow: hidden; - pointer-events: none; -} -.leaflet-popup-tip { - width: 17px; - height: 17px; - padding: 1px; - - margin: -10px auto 0; - - -webkit-transform: rotate(45deg); - -moz-transform: rotate(45deg); - -ms-transform: rotate(45deg); - -o-transform: rotate(45deg); - transform: rotate(45deg); -} -.leaflet-popup-content-wrapper, -.leaflet-popup-tip { - background: white; - color: #333; - box-shadow: 0 3px 14px rgba(0,0,0,0.4); -} -.leaflet-container a.leaflet-popup-close-button { - position: absolute; - top: 0; - right: 0; - padding: 4px 4px 0 0; - border: none; - text-align: center; - width: 18px; - height: 14px; - font: 16px/14px Tahoma, Verdana, sans-serif; - color: #c3c3c3; - text-decoration: none; - font-weight: bold; - background: transparent; -} -.leaflet-container a.leaflet-popup-close-button:hover { - color: #999; -} -.leaflet-popup-scrolled { - overflow: auto; - border-bottom: 1px solid #ddd; - border-top: 1px solid #ddd; -} - -.leaflet-oldie .leaflet-popup-content-wrapper { - zoom: 1; -} -.leaflet-oldie .leaflet-popup-tip { - width: 24px; - margin: 0 auto; - - -ms-filter: "progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)"; - filter: progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678); -} -.leaflet-oldie .leaflet-popup-tip-container { - margin-top: -1px; -} - -.leaflet-oldie .leaflet-control-zoom, -.leaflet-oldie .leaflet-control-layers, -.leaflet-oldie .leaflet-popup-content-wrapper, -.leaflet-oldie .leaflet-popup-tip { - border: 1px solid #999; -} - - -/* div icon */ - -.leaflet-div-icon { - background: #fff; - border: 1px solid #666; -} - - -/* Tooltip */ -/* Base styles for the element that has a tooltip */ -.leaflet-tooltip { - position: absolute; - padding: 6px; - background-color: #fff; - border: 1px solid #fff; - border-radius: 3px; - color: #222; - white-space: nowrap; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; - pointer-events: none; - box-shadow: 0 1px 3px rgba(0,0,0,0.4); -} -.leaflet-tooltip.leaflet-clickable { - cursor: pointer; - pointer-events: auto; -} -.leaflet-tooltip-top:before, -.leaflet-tooltip-bottom:before, -.leaflet-tooltip-left:before, -.leaflet-tooltip-right:before { - position: absolute; - pointer-events: none; - border: 6px solid transparent; - background: transparent; - content: ""; -} - -/* Directions */ - -.leaflet-tooltip-bottom { - margin-top: 6px; -} -.leaflet-tooltip-top { - margin-top: -6px; -} -.leaflet-tooltip-bottom:before, -.leaflet-tooltip-top:before { - left: 50%; - margin-left: -6px; -} -.leaflet-tooltip-top:before { - bottom: 0; - margin-bottom: -12px; - border-top-color: #fff; -} -.leaflet-tooltip-bottom:before { - top: 0; - margin-top: -12px; - margin-left: -6px; - border-bottom-color: #fff; -} -.leaflet-tooltip-left { - margin-left: -6px; -} -.leaflet-tooltip-right { - margin-left: 6px; -} -.leaflet-tooltip-left:before, -.leaflet-tooltip-right:before { - top: 50%; - margin-top: -6px; -} -.leaflet-tooltip-left:before { - right: 0; - margin-right: -12px; - border-left-color: #fff; -} -.leaflet-tooltip-right:before { - left: 0; - margin-left: -12px; - border-right-color: #fff; -} \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.ttf b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.ttf deleted file mode 100644 index aa00de0ef9..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.ttf and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.woff b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.woff deleted file mode 100644 index ced7907e94..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.woff and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.woff2 b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.woff2 deleted file mode 100644 index 723a32343b..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Medium.woff2 and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.ttf b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.ttf deleted file mode 100644 index 3e6e2e7613..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.ttf and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.woff b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.woff deleted file mode 100644 index e401bcf528..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.woff and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.woff2 b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.woff2 deleted file mode 100644 index 5bd7bd6500..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/Roboto-Regular.woff2 and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.svg deleted file mode 100644 index 91614ea75e..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.svg +++ /dev/null @@ -1,2326 +0,0 @@ - - - - - -Created by FontForge 20161004 at Wed Jun 21 08:31:03 2017 - By dimal - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.ttf b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.ttf deleted file mode 100644 index 27735b2820..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.ttf and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.woff b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.woff deleted file mode 100644 index 80fd5a7fc2..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.woff and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.woff2 b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.woff2 deleted file mode 100644 index 6087330889..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/fonts/font-wso2.woff2 and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar-2.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar-2.png deleted file mode 100644 index 9467f5eb76..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar-2.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar-3.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar-3.png deleted file mode 100644 index f1d980e55c..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar-3.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar.png deleted file mode 100644 index 5fab5dee57..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/avatar.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/favicon.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/favicon.png deleted file mode 100644 index a1deab3581..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/favicon.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/install_agent.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/install_agent.png deleted file mode 100644 index 2686c87b5d..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/install_agent.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/logo.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/logo.svg deleted file mode 100644 index 7986a8d1b4..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/logo.svg +++ /dev/null @@ -1,798 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/qr-code.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/qr-code.png deleted file mode 100644 index 00c8544c19..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/qr-code.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/register.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/register.png deleted file mode 100644 index f7e4bfedfe..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/register.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/registration.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/registration.png deleted file mode 100644 index f7a3bad6b6..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/registration.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/set_profile.png b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/set_profile.png deleted file mode 100644 index 81de7a5993..0000000000 Binary files a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/images/set_profile.png and /dev/null differ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/locales/en.json b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/locales/en.json deleted file mode 100644 index 5be6f63bd4..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/locales/en.json +++ /dev/null @@ -1,67 +0,0 @@ -{ - "Title" : "Title", - "Description" : "Description", - "ShortDescription" : "Short Description", - "Category" : "Category", - "Visibility" : "Visibility", - "Devices" : "Devices", - "Roles" : "Roles", - "Groups" : "Groups", - "Tags" : "Tags", - "Platform" : "Platform", - "Platforms" : "Platforms", - "Applications": "Applications", - "No.Platform" : "No Platforms", - "Screenshots" : "Screenshots", - "Icon" : "Icon", - "Info" : "Info", - "Banner" : "Banner", - "Create.Application" : "Create Application", - "Back" : "Back", - "Cancel" : "Cancel", - "Finish" : "Finish", - "Continue" : "Continue", - "Name" : "Name", - "Application.Name" : "Application Name", - "General" : "General", - "App.Releases" : "Application Releases", - "Package.Manager" : "Package Manager", - "Save" : "Save", - "Create.Release" : "Create Release", - "Release.Channel" : "Release Channel", - "Release" : "Release", - "New.Release.For" : "New Release for", - "Upload.Package.File" : "Upload Package File", - "Upload" : "Upload", - "Select.from.package.library" : "Select from package library", - "Release.Name" : "Release Name", - "Release.Notes" : "Release Notes", - "Send.for.Review" : "Send for Review", - "Production.Releases" : "Production Releases", - "Beta.Releases" : "Beta Releases", - "Alpha.Releases" : "Alpha Releases", - "Version" : "Version", - "Status" : "Status", - "App.Publisher" : "Application Publisher", - "Search.Apps" : "Search for Applications", - "View.In.Store" : "View in Store", - "Last.Updated" : "Last updated on", - "Installs" : "Installs", - "General.Info" : "General Info", - "Select.Platform": "Select Platform", - "Add.Release" : "Add Release to Application", - "Share.With.Tenants" : "Share with Tenants", - "Disable" : "Disable", - "File.Based" : "File Based", - "Activate" : "Activate", - "Yes" : "Yes", - "No" : "No", - "No.Platform.Tags" : "No Platform Tags", - "Create.Platform" : "Create Platform", - "Optional": "Optional", - "Identifier": "Identifier", - "Next": "Next", - "Platform.Enable": "Enable Platform", - "Share.with.Tenants": "Share between all tenants", - "Platform.Properties": "Platform Properties" -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/scss/_mixin.scss b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/scss/_mixin.scss deleted file mode 100644 index e1cc046bc5..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/scss/_mixin.scss +++ /dev/null @@ -1,1254 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -%icon-base { - &:before { - font-family: "font-wso2"; - -webkit-font-smoothing: antialiased; - } - b { - // hide text - height: 0; - display: block; - text-indent: 100%; - white-space: nowrap; - overflow: hidden; - } -} - -@mixin font-wso2($icon) { - @extend %icon-base; - - - @if ($icon == "abort") { - content:"\e72a"; - } - - @else if ($icon == "action-invoke") { - content:"\e6fe"; - } - - @else if ($icon == "action") { - content:"\e709"; - } - - @else if ($icon == "activate") { - content:"\e6cf"; - } - - @else if ($icon == "add") { - content:"\e615"; - } - - @else if ($icon == "airplay") { - content:"\e600"; - } - - @else if ($icon == "alarm") { - content:"\e6c2"; - } - - @else if ($icon == "alert") { - content:"\e6be"; - } - - @else if ($icon == "analytics-extensions") { - content:"\e6e2"; - } - - @else if ($icon == "android-logcat") { - content:"\e72c"; - } - - @else if ($icon == "android-sense") { - content:"\e72d"; - } - - @else if ($icon == "android") { - content:"\e606"; - } - - @else if ($icon == "annotation") { - content:"\e6e6"; - } - - @else if ($icon == "api") { - content:"\e601"; - } - - @else if ($icon == "apn") { - content:"\e602"; - } - - @else if ($icon == "apple") { - content:"\e604"; - } - - @else if ($icon == "application") { - content:"\e608"; - } - - @else if ($icon == "arduino") { - content:"\e6ab"; - } - - @else if ($icon == "assign") { - content:"\e6ff"; - } - - @else if ($icon == "ballerina-service") { - content:"\e729"; - } - - @else if ($icon == "ballerina") { - content:"\e728"; - } - - @else if ($icon == "bar-chart") { - content:"\e690"; - } - - @else if ($icon == "battery") { - content:"\e60a"; - } - - @else if ($icon == "blank-document") { - content:"\e60c"; - } - - @else if ($icon == "block") { - content:"\e695"; - } - - @else if ($icon == "bookmark") { - content:"\e60d"; - } - - @else if ($icon == "bpel") { - content:"\e60e"; - } - - @else if ($icon == "bpmn") { - content:"\e60f"; - } - - @else if ($icon == "break") { - content:"\e721"; - } - - @else if ($icon == "bug") { - content:"\e611"; - } - - @else if ($icon == "build") { - content:"\e6c1"; - } - - @else if ($icon == "calendar") { - content:"\e612"; - } - - @else if ($icon == "camera") { - content:"\e613"; - } - - @else if ($icon == "cancel") { - content:"\e618"; - } - - @else if ($icon == "carbon") { - content:"\e6c5"; - } - - @else if ($icon == "chat") { - content:"\e65b"; - } - - @else if ($icon == "check") { - content:"\e617"; - } - - @else if ($icon == "checklist") { - content:"\e619"; - } - - @else if ($icon == "circle-outline") { - content:"\e61f"; - } - - @else if ($icon == "circle") { - content:"\e61a"; - } - - @else if ($icon == "clear") { - content:"\e61b"; - } - - @else if ($icon == "clock") { - content:"\e61d"; - } - - @else if ($icon == "cloud") { - content:"\e61e"; - } - - @else if ($icon == "code-view") { - content:"\e70e"; - } - - @else if ($icon == "code") { - content:"\e6f1"; - } - - @else if ($icon == "comment") { - content:"\e710"; - } - - @else if ($icon == "compare") { - content:"\e610"; - } - - @else if ($icon == "computer") { - content:"\e653"; - } - - @else if ($icon == "configarations") { - content:"\e609"; - } - - @else if ($icon == "connector") { - content:"\e700"; - } - - @else if ($icon == "console") { - content:"\e71d"; - } - - @else if ($icon == "constant") { - content:"\e701"; - } - - @else if ($icon == "contact") { - content:"\e620"; - } - - @else if ($icon == "contract") { - content:"\e614"; - } - - @else if ($icon == "copy") { - content:"\e621"; - } - - @else if ($icon == "cut") { - content:"\e6f2"; - } - - @else if ($icon == "dashboard") { - content:"\e622"; - } - - @else if ($icon == "database") { - content:"\e623"; - } - - @else if ($icon == "delete") { - content:"\e624"; - } - - @else if ($icon == "depend") { - content:"\e6c6"; - } - - @else if ($icon == "deploy") { - content:"\e625"; - } - - @else if ($icon == "deprecate") { - content:"\e6cb"; - } - - @else if ($icon == "design-view") { - content:"\e70f"; - } - - @else if ($icon == "devices") { - content:"\e704"; - } - - @else if ($icon == "dgm-action-invoke") { - content:"\e712"; - } - - @else if ($icon == "dgm-action") { - content:"\e711"; - } - - @else if ($icon == "dgm-connector") { - content:"\e6f4"; - } - - @else if ($icon == "dgm-constant-definition") { - content:"\e6f5"; - } - - @else if ($icon == "dgm-fork") { - content:"\e6e7"; - } - - @else if ($icon == "dgm-header") { - content:"\e6e8"; - } - - @else if ($icon == "dgm-if-else") { - content:"\e6e9"; - } - - @else if ($icon == "dgm-import") { - content:"\e717"; - } - - @else if ($icon == "dgm-lifeline") { - content:"\e6ea"; - } - - @else if ($icon == "dgm-logger") { - content:"\e6eb"; - } - - @else if ($icon == "dgm-resource") { - content:"\e6f6"; - } - - @else if ($icon == "dgm-service") { - content:"\e6f7"; - } - - @else if ($icon == "dgm-try-catch") { - content:"\e6ec"; - } - - @else if ($icon == "dgm-type-convertor") { - content:"\e6f8"; - } - - @else if ($icon == "dgm-type") { - content:"\e6f9"; - } - - @else if ($icon == "dgm-while") { - content:"\e707"; - } - - @else if ($icon == "dial-up") { - content:"\e627"; - } - - @else if ($icon == "disabled") { - content:"\e6d1"; - } - - @else if ($icon == "display") { - content:"\e626"; - } - - @else if ($icon == "docker") { - content:"\e70c"; - } - - @else if ($icon == "document") { - content:"\e628"; - } - - @else if ($icon == "down-arrow") { - content:"\e689"; - } - - @else if ($icon == "down") { - content:"\e685"; - } - - @else if ($icon == "download") { - content:"\e65f"; - } - - @else if ($icon == "dss") { - content:"\e62a"; - } - - @else if ($icon == "ebook") { - content:"\e62b"; - } - - @else if ($icon == "edit") { - content:"\e62c"; - } - - @else if ($icon == "ellipsis") { - content:"\e629"; - } - - @else if ($icon == "endpoint") { - content:"\e62d"; - } - - @else if ($icon == "enterprise") { - content:"\e6b6"; - } - - @else if ($icon == "error") { - content:"\e630"; - } - - @else if ($icon == "esb-connector") { - content:"\e6e3"; - } - - @else if ($icon == "expand") { - content:"\e61c"; - } - - @else if ($icon == "export") { - content:"\e631"; - } - - @else if ($icon == "extensions") { - content:"\e6e4"; - } - - @else if ($icon == "facebook") { - content:"\e6d3"; - } - - @else if ($icon == "factory-reset") { - content:"\e632"; - } - - @else if ($icon == "fan") { - content:"\e678"; - } - - @else if ($icon == "faq") { - content:"\e62f"; - } - - @else if ($icon == "file-browse") { - content:"\e633"; - } - - @else if ($icon == "filter") { - content:"\e634"; - } - - @else if ($icon == "folder-open") { - content:"\e70b"; - } - - @else if ($icon == "folder") { - content:"\e62e"; - } - - @else if ($icon == "fork-join") { - content:"\e720"; - } - - @else if ($icon == "format") { - content:"\e6fa"; - } - - @else if ($icon == "forum") { - content:"\e636"; - } - - @else if ($icon == "function-invoke") { - content:"\e713"; - } - - @else if ($icon == "function") { - content:"\e6fb"; - } - - @else if ($icon == "gadget") { - content:"\e637"; - } - - @else if ($icon == "geo-fence-inbound") { - content:"\e72e"; - } - - @else if ($icon == "geo-fence-outbound") { - content:"\e72f"; - } - - @else if ($icon == "github") { - content:"\e6d4"; - } - - @else if ($icon == "globe") { - content:"\e697"; - } - - @else if ($icon == "google-docs") { - content:"\e6d6"; - } - - @else if ($icon == "google-drive") { - content:"\e6da"; - } - - @else if ($icon == "google-plus") { - content:"\e6d9"; - } - - @else if ($icon == "google-sheets") { - content:"\e6d7"; - } - - @else if ($icon == "google-slides") { - content:"\e6d8"; - } - - @else if ($icon == "google") { - content:"\e6d5"; - } - - @else if ($icon == "grid") { - content:"\e638"; - } - - @else if ($icon == "grip") { - content:"\e6b7"; - } - - @else if ($icon == "group") { - content:"\e6af"; - } - - @else if ($icon == "hardware") { - content:"\e6a9"; - } - - @else if ($icon == "hdd") { - content:"\e639"; - } - - @else if ($icon == "heart") { - content:"\e6c3"; - } - - @else if ($icon == "hide") { - content:"\e6d2"; - } - - @else if ($icon == "home") { - content:"\e63a"; - } - - @else if ($icon == "hour-glass") { - content:"\e63b"; - } - - @else if ($icon == "html") { - content:"\e69d"; - } - - @else if ($icon == "http") { - content:"\e705"; - } - - @else if ($icon == "image") { - content:"\e70a"; - } - - @else if ($icon == "import") { - content:"\e63c"; - } - - @else if ($icon == "incoming-call") { - content:"\e63d"; - } - - @else if ($icon == "info") { - content:"\e63e"; - } - - @else if ($icon == "instagram") { - content:"\e6db"; - } - - @else if ($icon == "invitation") { - content:"\e63f"; - } - - @else if ($icon == "invoke") { - content:"\e6ed"; - } - - @else if ($icon == "is-connector") { - content:"\e6e5"; - } - - @else if ($icon == "iterate") { - content:"\e71f"; - } - - @else if ($icon == "jaggery") { - content:"\e640"; - } - - @else if ($icon == "java-spring") { - content:"\e644"; - } - - @else if ($icon == "java") { - content:"\e641"; - } - - @else if ($icon == "javaee") { - content:"\e642"; - } - - @else if ($icon == "javascript") { - content:"\e643"; - } - - @else if ($icon == "jaxrs") { - content:"\e645"; - } - - @else if ($icon == "jaxws") { - content:"\e6c7"; - } - - @else if ($icon == "jquery") { - content:"\e646"; - } - - @else if ($icon == "key") { - content:"\e647"; - } - - @else if ($icon == "laptop") { - content:"\e648"; - } - - @else if ($icon == "layout") { - content:"\e6bf"; - } - - @else if ($icon == "ldap") { - content:"\e649"; - } - - @else if ($icon == "left-arrow") { - content:"\e68a"; - } - - @else if ($icon == "left") { - content:"\e686"; - } - - @else if ($icon == "lifecycle") { - content:"\e64a"; - } - - @else if ($icon == "light") { - content:"\e680"; - } - - @else if ($icon == "linkedin") { - content:"\e6dc"; - } - - @else if ($icon == "list-sort") { - content:"\e64d"; - } - - @else if ($icon == "list") { - content:"\e64c"; - } - - @else if ($icon == "loader") { - content:"\e6b4"; - } - - @else if ($icon == "loader2") { - content:"\e6ba"; - } - - @else if ($icon == "loader3") { - content:"\e6bb"; - } - - @else if ($icon == "loader4") { - content:"\e6bc"; - } - - @else if ($icon == "loader5") { - content:"\e6bd"; - } - - @else if ($icon == "lock") { - content:"\e64e"; - } - - @else if ($icon == "logical") { - content:"\e702"; - } - - @else if ($icon == "mail") { - content:"\e64f"; - } - - @else if ($icon == "main-function") { - content:"\e706"; - } - - @else if ($icon == "map-location") { - content:"\e650"; - } - - @else if ($icon == "menu") { - content:"\e651"; - } - - @else if ($icon == "message") { - content:"\e635"; - } - - @else if ($icon == "micro-services") { - content:"\e6ce"; - } - - @else if ($icon == "minus") { - content:"\e616"; - } - - @else if ($icon == "mobile") { - content:"\e652"; - } - - @else if ($icon == "ms-document") { - content:"\e654"; - } - - @else if ($icon == "mute") { - content:"\e655"; - } - - @else if ($icon == "nodejs") { - content:"\e656"; - } - - @else if ($icon == "notification") { - content:"\e60b"; - } - - @else if ($icon == "organization") { - content:"\e6ac"; - } - - @else if ($icon == "own") { - content:"\e6c8"; - } - - @else if ($icon == "package") { - content:"\e6fd"; - } - - @else if ($icon == "pages") { - content:"\e6c0"; - } - - @else if ($icon == "paste") { - content:"\e658"; - } - - @else if ($icon == "pdf") { - content:"\e659"; - } - - @else if ($icon == "pending") { - content:"\e727"; - } - - @else if ($icon == "php") { - content:"\e6c9"; - } - - @else if ($icon == "pie-chart") { - content:"\e65a"; - } - - @else if ($icon == "pinterest") { - content:"\e6dd"; - } - - @else if ($icon == "policy") { - content:"\e67d"; - } - - @else if ($icon == "polygon") { - content:"\e70d"; - } - - @else if ($icon == "prototype") { - content:"\e6cc"; - } - - @else if ($icon == "proxy") { - content:"\e699"; - } - - @else if ($icon == "public") { - content:"\e6ad"; - } - - @else if ($icon == "publish") { - content:"\e65c"; - } - - @else if ($icon == "question") { - content:"\e6b0"; - } - - @else if ($icon == "raspberry") { - content:"\e6aa"; - } - - @else if ($icon == "redo") { - content:"\e65d"; - } - - @else if ($icon == "refresh") { - content:"\e692"; - } - - @else if ($icon == "register") { - content:"\e65e"; - } - - @else if ($icon == "rename") { - content:"\e6fc"; - } - - @else if ($icon == "reply") { - content:"\e714"; - } - - @else if ($icon == "resource") { - content:"\e660"; - } - - @else if ($icon == "rest-api") { - content:"\e661"; - } - - @else if ($icon == "rest-service") { - content:"\e662"; - } - - @else if ($icon == "resume") { - content:"\e71e"; - } - - @else if ($icon == "retire") { - content:"\e6cd"; - } - - @else if ($icon == "return") { - content:"\e715"; - } - - @else if ($icon == "retweet") { - content:"\e6b9"; - } - - @else if ($icon == "right-arrow") { - content:"\e68b"; - } - - @else if ($icon == "right") { - content:"\e687"; - } - - @else if ($icon == "ringing") { - content:"\e694"; - } - - @else if ($icon == "rules") { - content:"\e664"; - } - - @else if ($icon == "run") { - content:"\e708"; - } - - @else if ($icon == "save") { - content:"\e665"; - } - - @else if ($icon == "scep") { - content:"\e666"; - } - - @else if ($icon == "schema") { - content:"\e667"; - } - - @else if ($icon == "search") { - content:"\e668"; - } - - @else if ($icon == "security-policy") { - content:"\e67e"; - } - - @else if ($icon == "security") { - content:"\e669"; - } - - @else if ($icon == "send") { - content:"\e66a"; - } - - @else if ($icon == "sequence") { - content:"\e66b"; - } - - @else if ($icon == "server") { - content:"\e66c"; - } - - @else if ($icon == "service-provider") { - content:"\e66e"; - } - - @else if ($icon == "service") { - content:"\e66d"; - } - - @else if ($icon == "settings") { - content:"\e66f"; - } - - @else if ($icon == "share") { - content:"\e670"; - } - - @else if ($icon == "shell") { - content:"\e730"; - } - - @else if ($icon == "shortcut") { - content:"\e725"; - } - - @else if ($icon == "sign-in") { - content:"\e671"; - } - - @else if ($icon == "sign-out") { - content:"\e6b8"; - } - - @else if ($icon == "skype") { - content:"\e6de"; - } - - @else if ($icon == "slash") { - content:"\e6e1"; - } - - @else if ($icon == "soap") { - content:"\e672"; - } - - @else if ($icon == "sort-down") { - content:"\e663"; - } - - @else if ($icon == "sort-up") { - content:"\e64b"; - } - - @else if ($icon == "sort") { - content:"\e673"; - } - - @else if ($icon == "speed-alert") { - content:"\e731"; - } - - @else if ($icon == "square-outline") { - content:"\e6b2"; - } - - @else if ($icon == "square") { - content:"\e6b1"; - } - - @else if ($icon == "star") { - content:"\e674"; - } - - @else if ($icon == "start") { - content:"\e718"; - } - - @else if ($icon == "statistics") { - content:"\e675"; - } - - @else if ($icon == "stepin") { - content:"\e719"; - } - - @else if ($icon == "stepout") { - content:"\e71a"; - } - - @else if ($icon == "stepover") { - content:"\e71b"; - } - - @else if ($icon == "stop") { - content:"\e71c"; - } - - @else if ($icon == "store") { - content:"\e676"; - } - - @else if ($icon == "struct") { - content:"\e716"; - } - - @else if ($icon == "subscribe") { - content:"\e677"; - } - - @else if ($icon == "success") { - content:"\e657"; - } - - @else if ($icon == "swagger") { - content:"\e679"; - } - - @else if ($icon == "sync") { - content:"\e6b3"; - } - - @else if ($icon == "table") { - content:"\e6c4"; - } - - @else if ($icon == "tag") { - content:"\e67a"; - } - - @else if ($icon == "task") { - content:"\e67b"; - } - - @else if ($icon == "text") { - content:"\e67c"; - } - - @else if ($icon == "theme") { - content:"\e726"; - } - - @else if ($icon == "throttling-policy") { - content:"\e67f"; - } - - @else if ($icon == "throw") { - content:"\e722"; - } - - @else if ($icon == "tiles") { - content:"\e681"; - } - - @else if ($icon == "transaction") { - content:"\e72b"; - } - - @else if ($icon == "try-catch") { - content:"\e703"; - } - - @else if ($icon == "twitter") { - content:"\e6df"; - } - - @else if ($icon == "type-converter") { - content:"\e6f3"; - } - - @else if ($icon == "uncheck") { - content:"\e682"; - } - - @else if ($icon == "undo") { - content:"\e683"; - } - - @else if ($icon == "ungroup") { - content:"\e6b5"; - } - - @else if ($icon == "unmute") { - content:"\e6ae"; - } - - @else if ($icon == "up-arrow") { - content:"\e688"; - } - - @else if ($icon == "up") { - content:"\e684"; - } - - @else if ($icon == "upload") { - content:"\e68c"; - } - - @else if ($icon == "uri") { - content:"\e68d"; - } - - @else if ($icon == "usb-drive") { - content:"\e68e"; - } - - @else if ($icon == "use") { - content:"\e6ca"; - } - - @else if ($icon == "user") { - content:"\e68f"; - } - - @else if ($icon == "variable") { - content:"\e6ee"; - } - - @else if ($icon == "view") { - content:"\e691"; - } - - @else if ($icon == "vpn") { - content:"\e603"; - } - - @else if ($icon == "wadl") { - content:"\e6a1"; - } - - @else if ($icon == "war") { - content:"\e69e"; - } - - @else if ($icon == "warning") { - content:"\e693"; - } - - @else if ($icon == "web-app") { - content:"\e696"; - } - - @else if ($icon == "web-clip") { - content:"\e698"; - } - - @else if ($icon == "web-service") { - content:"\e69a"; - } - - @else if ($icon == "website") { - content:"\e69b"; - } - - @else if ($icon == "wifi") { - content:"\e607"; - } - - @else if ($icon == "windows") { - content:"\e605"; - } - - @else if ($icon == "worker-invoke") { - content:"\e723"; - } - - @else if ($icon == "worker-reply") { - content:"\e724"; - } - - @else if ($icon == "worker") { - content:"\e6ef"; - } - - @else if ($icon == "wsdl") { - content:"\e6a0"; - } - - @else if ($icon == "wso2-logo") { - content:"\e6a7"; - } - - @else if ($icon == "wso2") { - content:"\e6a8"; - } - - @else if ($icon == "xacml") { - content:"\e69f"; - } - - @else if ($icon == "xml") { - content:"\e69c"; - } - - @else if ($icon == "xq") { - content:"\e6a2"; - } - - @else if ($icon == "xsd") { - content:"\e6a3"; - } - - @else if ($icon == "xslt") { - content:"\e6a4"; - } - - @else if ($icon == "youtube") { - content:"\e6e0"; - } - - @else if ($icon == "zoom-in") { - content:"\e6a5"; - } - - @else if ($icon == "zoom-out") { - content:"\e6a6"; - } - -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/themes/default/default-theme.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/themes/default/default-theme.css deleted file mode 100644 index 941606c0c8..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/public/themes/default/default-theme.css +++ /dev/null @@ -1,903 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -@font-face { - font-family: "Roboto-Medium"; - src: url('../../fonts/Roboto-Medium.woff'); - src: local("Roboto-Medium"), url("../../fonts/Roboto-Medium.ttf") format("ttf"); - src: local("Roboto-Medium"), url("../../fonts/Roboto-Medium.woff") format("woff"); - src: local("Roboto-Medium"), url("../../fonts/Roboto-Medium.woff2") format("woff2"); -} - -@font-face { - font-family: "Roboto-Regular"; - src: url("../../fonts/Roboto-Regular.woff"); - src: local("Roboto-Regular"), url("../../fonts/Roboto-Regular.ttf") format("ttf"); - src: local("Roboto-Regular"), url("../../fonts/Roboto-Regular.woff") format("woff"); - src: local("Roboto-Regular"), url("../../fonts/Roboto-Regular.woff2") format("woff2"); -} - -/*Colors*/ -.primary { - color: white; - background-color: #2196f3 !important; -} - -.primary-flat { - color: #2196F3 !important; -} - -.danger { - color: white; - background-color: #e91e63 !important; -} - -.danger-flat { - color: #e91e63 !important; -} - -.grey { - color: #b3b3b3 !important; -} - -/* ==================================================================== */ -/* Custom button styles based on material design specs. */ - -.custom-raised { - font-family: Roboto-Medium; - text-transform: uppercase !important; - font-size: 14px !important; - padding-left: 16px !important; - border-radius: 2px !important; - padding-right: 16px !important; - height: 36px !important; - border: none !important; -} - -.custom-raised:hover { - cursor: pointer; - box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.08) !important; - -webkit-box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.08) !important; - background-color: #1976D2 !important; -} - -.custom-raised:focus { - box-shadow: none !important; - -webkit-box-shadow: none !important; - background-color: #1976D2 !important; -} - -.custom-flat { - font-family: Roboto-Medium; - height: 36px !important; - border-radius: 2px !important; - margin-left: 8px !important; - margin-right: 8px !important; - padding-left: 8px !important; - padding-right: 8px !important; - background-color: transparent !important; - text-transform: uppercase; - outline: none !important; - border: none !important; -} - -.custom-flat:hover { - cursor: pointer; - background-color: rgba(0, 0, 0, 0.12) !important; -} - -.custom-flat:focus { - outline: none !important; - border: none !important; - -webkit-box-shadow: none !important; - box-shadow: none !important; - background-color: rgba(0, 0, 0, 0.40) !important; -} - -.circle-button { - border-radius: 100% !important; - height: 36px !important; - width: 36px; -} - -/* ==================================================================== */ - -/* Body Styling */ -body { - width: 100%; - font-family: "Roboto-Regular" !important; - font-size: 14px !important; - background-color: #e8e8e8 !important; -} - -.app-manager-title { - font-family: "Roboto-Medium"; - font-size: 20px; -} - -.app-manager-sub-title { - font-family: "Roboto-Regular"; - font-size: 18px; -} - -#app-mgt-footer { - clear: both; - position: relative; - height: 50px; - width: 100%; - color: white; - background-color: #334d88; -} - -/* Login page styles*/ -#userName { - border-radius: 0; -} - -#password { - border-radius: 0; -} - -.login-btn { - float: right; -} - -.login-header { - background-color: #3f50b5; - color: white; - height: 128px; - width: 100%; - margin: 0 !important; - padding: 20px; - box-shadow: -2px 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); -} - -#login-card { - width: 25%; - height: 50%; - margin: 10% auto; - font-family: Roboto-Regular; - font-size: 14px; - border-radius: 0; - background-color: #ffffff; - box-shadow: -2px 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); -} - -.login-header-title { - font-family: Roboto-Medium; - font-size: 20px; - font-weight: 500; -} - -.login-header-logo { - height: 70px; - width: 150px; -} - -.login-form { - margin: 0 !important; - padding: 40px; -} - -/* Base layout container */ - -/* Base layout header content*/ -.header-content { - height: 128px !important; - width: 100% !important; - margin: 0 10px 0 0; - background-color: #3f50b5 !important; - position: fixed; /* Set the navbar to fixed position */ - top: 0; /* Position the navbar at the top of the page */ - z-index: 2; - box-shadow: -2px 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); -} - -/* Contains the header styles.*/ -.header { - padding: 24px 24px 10px 24px; - /*margin: 16px 16px 20px 16px;*/ - position: relative; -} - -#header-text { - color: #ffffff; - font-size: 20px; - font-family: Roboto-Medium; - top: 10px; - margin-left: 10px; -} - -/* The buttons in the header (User and Notification)*/ -.header-button-container { - display: flex; - justify-content: flex-end; -} - -.header-user-name { - font-family: Roboto-Medium; - font-size: 14px; - padding-top: 15px; - color: white; -} - -.header-image { - height: 43px; - width: 100px; - margin-right: 24px; -} - -#header-button { - border-radius: 50%; - background-color: transparent; - border: none; - height: 50px; - width: 50px; - margin-right: 10px; - position: relative; - outline: none; -} - -#header-button:hover { - background-color: #4353bd; - cursor: pointer; -} - -#header-button i { - position: absolute; - bottom: 19px; - left: 17px; -} - -.btn-header { - margin-top: 15px; - margin-right: 20px; - color: white; -} - -#sub-title { - font-family: Roboto-Regular; - font-size: 18px; - font-weight: 600; - padding-top: 5px; - padding-left: 18px; - color: RGBA(0, 0, 0, 1); -} - -/* Search box styles */ -.search-box { - display: flex; - float: right; -} - -.search-box i { - position: absolute; - top: 5px; - color: #BaBaBa; -} - -#search { - position: relative; - color: white; - background-color: transparent; - left: 15px; - top: 0px; - height: 25px; - outline: none; - border: none; - border-radius: 0%; -} - -/* Application Add button */ -#add-btn-container { - position: absolute; - top: 98px; -} - -.add-btn { - background-color: #ff5722; -} - -.add-btn:hover { - background-color: #E64A19; -} - -#sub-title-container { - height: 100px; - padding: 50px 0 20px 0; -} - -.application-container { - padding: 0 !important; - min-height: 100% !important; - margin-top: 128px !important; -} - -/* Holds the app pages. */ -.store-card { - height: auto; - background-color: white; - box-shadow: 2px 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); - padding: 24px; -} - -.platform-link-placeholder { - color: #888888; - float: right; - padding-bottom: 10px; -} - -.platform-link-placeholder i { - margin-right: 4px; -} - -.application-list { - transition: margin-right .5s; -} - -#batch-content { - display: flex; - margin-top: 5px; -} - -.app-list-icon { - border-radius: 50%; - height: 50px; - width: 50px -} - -.app-table-row { - height: 62px; - cursor: pointer; - padding-top: 6px; - font-family: "Roboto-Regular"; - font-size: medium; -} - -.app-table-row:hover { - color: white; - background-color: #3f50b5; -} - -.app-list-table-header { - margin-top: 30px; - margin-bottom: 10px; - font-family: "Roboto-Medium"; - font-size: 15px; -} - -.app-view-image { - height: 100px; - width: 100px; - border-radius: 50%; -} - -#app-visibility-default { - display: none; -} - -#app-image-screenshot { - width: 300px; - height: 300px; -} - -#app-image-icon { - width: 300px; - height: 300px; -} - -#app-image-banner { - width: 400px; - height: 300px; -} - -#form-error { - color: red; -} - -.application-create-banner-dropzone { - width: 300px; - height: 150px; - border-radius: 5%; - position: relative; - border: dashed #888888 2px; -} - -.application-create-banner-dropzone i { - position: absolute; - top: 65px; - left: 145px; -} - -.application-create-screenshot-dropzone { - width: 150px; - height: 150px; - margin: 0 5px 0 5px; - border-radius: 10%; - position: relative; - border: dashed #888888 2px; -} - -.application-create-screenshot-dropzone i { - position: absolute; - top: 65px; - left: 65px; -} - -.application-create-icon-dropzone { - width: 150px; - height: 150px; - border-radius: 10%; - position: relative; - border: dashed #888888 2px; -} - -.application-create-icon-dropzone i { - position: absolute; - top: 65px; - left: 65px; -} - -#screenshot-container { - max-width: 600px; - display: flex; - overflow-x: auto; - height: 200px; -} - -#app-icon-container { - height: 300px; - overflow-x: auto; -} - -#modal-body-content { - max-height: 700px; - padding-left: 24px; - overflow-y: auto; -} - -.custom-footer { - justify-content: inherit !important; - margin: 0 !important; -} - -.footer-main-btn { - display: flex; - justify-content: flex-end; -} - -#img-btn-screenshot { - margin: 0 5px 0 5px; -} - -#app-create-modal { - max-width: 850px; - border-radius: 0% !important; -} - -.app-create-modal-header { - background-color: #4353bd; - color: white; - padding: 24px !important; -} - -.app-create-modal-content { - padding: 0 !important; -} - -#store { - border: none; - border-bottom: solid #BDBDBD 1px; - border-radius: 0px; - width: 200px; -} - -#version { - border: none; - border-bottom: solid #BDBDBD 1px; - border-radius: 0px; - width: 200px; -} - -#app-release-switch-content { - display: flex; -} - -#app-release-switch-label { - position: absolute; - float: left; -} - -#app-release-switch { - position: absolute; - right: 10px; -} - -.image-sub-title { - font-style: italic; - font-size: 12px; - color: #818181; -} - -/* Application View */ - -#application-view-content { - width: 100%; -} - -#application-view-row { - margin: 10px 10px 0 20px; -} - -#app-icon { - height: 100px; - width: 100px; - border: solid 1px black; - border-radius: 50%; -} - -.app-updated-date { - color: #888888; -} - -.app-install-count { - font-style: italic; -} - -.app-details-tbl { - outline: none; - border-color: #2196F3; -} - -.app-details-tbl tr { - margin: 20px 0 0 0; -} - -.app-details-tbl td { - margin-left: 10px; - max-width: 400px; -} - -/* Application Edit Base Layout */ - -#application-edit-header { - height: 40px; - width: 100%; - margin-top: 20px; - margin-bottom: 20px; - font-size: 25px; -} - -.application-header-text { - margin: 10px 0px 0px 10px; -} - -#save-btn-content { - float: right; - -} - -#app-save-btn { - border-radius: 0%; -} - -.save-btn { - margin: 5px 5px 5px 0px; - height: 70%; - width: 50%; - float: right; -} - -.save-btn:hover { - cursor: pointer; -} - -/*Tab styling*/ - -div.tab { - float: left; - border-right: 1px solid #d8d8d8; - height: 100%; -} - -/* Style the tab buttons */ - -div.tab button { - display: block; - background-color: inherit; - color: black; - padding: 15px 16px; - width: 100%; - border: none; - outline: none; - text-align: left; - cursor: pointer; - transition: 0.3s; -} - -/* Change background color of buttons on hover */ - -div.tab button:hover { - background-color: #ddd6d7; - cursor: pointer; -} - -/* Create an active/current "tab button" class */ - -div.tab button.active { - background-color: #1b3bcc; - color: white; -} - -#application-edit-main-container { - display: flex; -} - -#application-edit-outer-content { - height: auto; -} - -#app-edit-content { - height: 100%; - position: relative; -} - -.back-to-app { - position: absolute; - height: 50px; - width: 50px; - border-radius: 50%; -} - -.back-to-app i { - padding: 12px 10px 10px 12px; -} - -.back-to-app:hover { - cursor: pointer; - background-color: #dedede; - transition: .5s; -} - -/* Create Release and Release management */ - -.release-header { - margin-top: 20px; - margin-bottom: 20px; -} - -.release-create { - height: 150px; - margin-bottom: 20px; -} - -.release-detail-content { - width: 100%; - margin-top: 20%; - height: 300px; -} - -.form-btn { - float: right; - margin-bottom: 10px; -} - -.release-content { - height: 180px; - width: 95%; - border: dashed 1px #626262; - border-radius: 2%; - position: relative; - background-color: #e8e8e8; -} - -.release-content:after { - content: ""; - letter-spacing: 4px; -} - -.release { - margin: 30px 10px 20px 30px; -} - -.no-release-content { - position: absolute; - margin-top: 10px; - left: 40%; -} - -.button-add:hover { - cursor: pointer; -} - -.release-inner { - margin-top: 5%; -} - -/* Application Edit General Info */ - -.app-edit-general-info { - margin-top: 20px; - max-width: 100%; -} - -.save-info { - float: right; - margin-bottom: 10px; -} - -.app-view-field { - font-family: Roboto-Medium; - font-size: 14px; -} - -.app-view-text { - font-family: Roboto-Regular; - font-size: 14px; -} - -/* Platform Specific Styles. */ -#platform-listing { - margin: 10px; -} - -.create-platform i { - margin-right: 10px; -} - -#platform-list { - margin-top: 20px; - display: flex; - flex-flow: wrap; -} - -.platform-content { - margin: 10px; - padding-top: 16px; - box-shadow: 2px 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); -} - -.platform-content .row { - margin: 0; -} - -.platform-content .col { - padding: 0; -} - -.platform-content-basic { - padding: 0 16px 0 16px; - display: flex; -} - -.platform-content-more-outer { - -} - -.platform-content-more { - padding: 16px 16px 24px 16px; -} - -.platform-content-footer { - display: flex; - padding: 8px 8px 8px 8px; -} - -.platform-text-container { - padding: 8px 16px 0 16px; -} - -.circle-button { - float: right; -} - -.platform-icon-letter { - text-align: center; - text-transform: uppercase; - font-family: Roboto-Medium; - font-size: 70px; - color: white; - padding-top: 15px; -} - -.platform-icon-container { - height: 120px; - width: 120px; - background-color: #01579B; - box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.08) !important; - -webkit-box-shadow: 0 2px 2px 0 rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0, 0, 0, 0.08) !important; -} - -.platform-property-container { - padding-top: 20px; - font-family: Roboto-Regular; - font-size: 14px; -} - -.platform-property-row { - align-items: center; -} - -.circle-btn-clear { - background-color: white !important; - color: rgba(0, 0, 0, 0.50) !important; -} - -.circle-btn-clear:hover { - background-color: white !important; - color: rgba(0, 0, 0, 0.38) !important; -} - -.circle-btn-clear:focus { - background-color: white !important; - color: rgba(0, 0, 0, 0.60) !important; -} - -.data-table-row-cell { - padding-top: 14px; -} - -.error-code { - text-align: center; - font-family: Roboto-Medium; - font-weight: 800; - font-size: 15em; - color: #BaBaBa; -} - -.error-code p { - -} - -.error-text { - text-align: center; - font-family: Roboto-Regular; - font-size: 14px; - font-weight: 500; - color: #9e9e9e; -} - -.circle-btn-add { - background-color: #bababa !important; - border-radius: 50% !important; - height: 30px !important; - width: 30px; - text-align: -webkit-center; - font-size: 18px; - padding: 6px !important; -} - -.circle-btn-add:hover { - background-color: #828282 !important; -} - -/** - If you need to change the color of active steps in stepper, - uncomment the following and set the background color and font color as needed. -*/ -/* -.stepper-active-index { - background-color: #0a6eff !important; - color: white !important; -} - -.stepper-passed-index { - background-color: #0a6eff !important; - color: green !important; -} -*/ diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.css deleted file mode 100644 index 3bb708d982..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.css +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -.ant-upload.ant-upload-drag { - height: 170px; -} - -.release .release-icon { - margin-right: 15px; -} - -.release .release-icon img { - width: 100%; - border-radius: 28%; -} - -.release .release-title { - margin-left: 15px; -} - -.release .release-screenshot img { - width: 100%; - border-radius: 15px; - padding: 5px; -} - -.main-container { - background: #f0f2f5; - min-height: 780px -} - -@media only screen and (min-width: 768px) { - .main-container { - padding: 24px; - } -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.js deleted file mode 100644 index 61cce9fc07..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.js +++ /dev/null @@ -1,173 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import 'antd/dist/antd.less'; -import RouteWithSubRoutes from './components/RouteWithSubRoutes'; -import { BrowserRouter as Router, Redirect, Switch } from 'react-router-dom'; -import axios from 'axios'; -import { Layout, Spin, Result, notification } from 'antd'; -import ConfigContext from './components/ConfigContext'; - -const { Content } = Layout; -const loadingView = ( - - - - - -); - -const errorView = ( - -); - -class App extends React.Component { - constructor(props) { - super(props); - this.state = { - loading: true, - error: false, - config: {}, - }; - } - - componentDidMount() { - axios - .get(window.location.origin + '/entgra/public/conf/config.json') - .then(res => { - const config = res.data; - this.checkUserLoggedIn(config); - }) - .catch(error => { - this.setState({ - loading: false, - error: true, - }); - }); - } - - checkUserLoggedIn = config => { - axios - .post( - window.location.origin + '/entgra-ui-request-handler/user', - 'platform=entgra', - ) - .then(res => { - config.user = res.data.data; - const pageURL = window.location.pathname; - const lastURLSegment = pageURL.substr(pageURL.lastIndexOf('/') + 1); - if (lastURLSegment === 'login') { - window.location.href = window.location.origin + '/entgra/'; - } else { - this.getDeviceTypes(config); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - const redirectUrl = encodeURI(window.location.href); - const pageURL = window.location.pathname; - const lastURLSegment = pageURL.substr(pageURL.lastIndexOf('/') + 1); - if (lastURLSegment !== 'login') { - window.location.href = - window.location.origin + `/entgra/login?redirect=${redirectUrl}`; - } else { - this.setState({ - loading: false, - config: config, - }); - } - } else { - this.setState({ - loading: false, - error: true, - }); - } - }); - }; - - getDeviceTypes = config => { - axios - .get( - window.location.origin + - '/entgra-ui-request-handler/invoke/device-mgt/v1.0/device-types', - ) - .then(res => { - config.deviceTypes = JSON.parse(res.data.data); - config.supportedOStypes = []; - config.deviceTypes.forEach(type => { - if (['ios', 'android'].includes(type.name)) { - config.supportedOStypes.push(type); - } - }); - this.setState({ - config: config, - loading: false, - }); - }) - .catch(error => { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load device types.', - }); - }); - }; - - render() { - const { loading, error } = this.state; - const applicationView = ( - - -
- - - {this.props.routes.map(route => ( - - ))} - -
-
-
- ); - - return ( -
- {loading && loadingView} - {!loading && !error && applicationView} - {error && errorView} -
- ); - } -} - -export default App; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.test.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.test.js deleted file mode 100644 index cda5c5ee25..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/App.test.js +++ /dev/null @@ -1,27 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import ReactDOM from 'react-dom'; -import App from './App'; - -it('renders without crashing', () => { - const div = document.createElement('div'); - ReactDOM.render(, div); - ReactDOM.unmountComponentAtNode(div); -}); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/components/ConfigContext/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/components/ConfigContext/index.js deleted file mode 100644 index f7c4f685fd..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/components/ConfigContext/index.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; - -const ConfigContext = React.createContext(); - -export const withConfigContext = Component => { - // eslint-disable-next-line react/display-name - return props => ( - - {context => { - return ; - }} - - ); -}; - -export default ConfigContext; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/components/RouteWithSubRoutes/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/components/RouteWithSubRoutes/index.js deleted file mode 100644 index 935bcd2e24..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/components/RouteWithSubRoutes/index.js +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Route } from 'react-router-dom'; -class RouteWithSubRoutes extends React.Component { - props; - constructor(props) { - super(props); - this.props = props; - } - render() { - return ( - ( - - )} - /> - ); - } -} - -export default RouteWithSubRoutes; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.css deleted file mode 100644 index 54d2bb2e1c..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.css +++ /dev/null @@ -1,45 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -.App { - padding: 20px; -} - -.ant-layout-header{ - padding: 0; - height: auto; - box-shadow: 0 2px 8px #f0f1f2; -} - -.steps-content { - margin-top: 16px; - border: 1px dashed #e9e9e9; - border-radius: 6px; - background-color: #fafafa; - min-height: 200px; - text-align: center; - padding-top: 80px; -} - -.steps-action { - margin-top: 24px; -} - -.ant-input-affix-wrapper .ant-input{ - min-height: 0; -} diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.html b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.html deleted file mode 100644 index eb2a94b6a7..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.html +++ /dev/null @@ -1,28 +0,0 @@ - - - - - - - - Entgra Device Management - - -
- diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.js deleted file mode 100644 index 04a9b4b2b4..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/index.js +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import ReactDOM from 'react-dom'; -import * as serviceWorker from './services/serviceWorkers/serviceWorker'; -import App from './App'; -import Login from './scenes/Login'; -import Home from './scenes/Home'; -import './index.css'; -import Geo from './scenes/Home/scenes/Geo'; -import Notifications from './scenes/Home/scenes/Notifications'; -import DeviceEnroll from './scenes/Home/scenes/Devices/scenes/Enroll'; -import Groups from './scenes/Home/scenes/Groups'; -import Users from './scenes/Home/scenes/Users'; -import Policies from './scenes/Home/scenes/Policies'; -import AddNewPolicy from './scenes/Home/scenes/Policies/scenes/AddNewPolicy'; -import Roles from './scenes/Home/scenes/Roles'; -import DeviceTypes from './scenes/Home/scenes/DeviceTypes'; -import Certificates from './scenes/Home/scenes/Configurations/scenes/Certificates'; -import Devices from './scenes/Home/scenes/Devices'; -import ViewPolicy from './scenes/Home/scenes/Policies/scenes/ViewPolicy'; -import EditSelectedPolicy from './scenes/Home/scenes/Policies/scenes/EditSelectedPolicy'; -import DeviceLocations from './scenes/Home/scenes/DeviceLocations'; - -const routes = [ - { - path: '/entgra/login', - exact: true, - component: Login, - }, - { - path: '/entgra', - exact: false, - component: Home, - routes: [ - { - path: '/entgra/devices', - component: Devices, - exact: true, - }, - { - path: '/entgra/devices/enroll', - component: DeviceEnroll, - exact: true, - }, - { - path: '/entgra/geo/history/:deviceType/:deviceIdentifier', - component: Geo, - exact: true, - }, - { - path: '/entgra/groups', - component: Groups, - exact: true, - }, - { - path: '/entgra/users', - component: Users, - exact: true, - }, - { - path: '/entgra/policies', - component: Policies, - exact: true, - }, - { - path: '/entgra/policy/add', - component: AddNewPolicy, - exact: true, - }, - { - path: '/entgra/policy/view/:policyId', - component: ViewPolicy, - exact: true, - }, - { - path: '/entgra/policy/edit/:policyId', - component: EditSelectedPolicy, - exact: true, - }, - { - path: '/entgra/roles', - component: Roles, - exact: true, - }, - { - path: '/entgra/devicetypes', - component: DeviceTypes, - exact: true, - }, - { - path: '/entgra/configurations/certificates', - component: Certificates, - exact: true, - }, - { - path: '/entgra/notifications', - component: Notifications, - exact: true, - }, - { - path: '/entgra/device-locations', - component: DeviceLocations, - exact: true, - }, - ], - }, -]; - -ReactDOM.render(, document.getElementById('root')); - -// If you want your app e and load faster, you can change -// unregister() to register() below. Note this comes with some pitfalls. -// Learn more about service workers: https://bit.ly/CRA-PWA -serviceWorker.unregister(); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/components/DevicesTable/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/components/DevicesTable/index.js deleted file mode 100644 index 79ad40585f..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/components/DevicesTable/index.js +++ /dev/null @@ -1,260 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import axios from 'axios'; -import { Icon, message, notification, Table, Tag, Tooltip } from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../components/ConfigContext'; - -let config = null; - -const columns = [ - { - title: 'Device', - dataIndex: 'name', - width: 100, - }, - { - title: 'Type', - dataIndex: 'type', - key: 'type', - // eslint-disable-next-line react/display-name - render: type => { - const defaultPlatformIcons = config.defaultPlatformIcons; - let icon = defaultPlatformIcons.default.icon; - let color = defaultPlatformIcons.default.color; - let theme = defaultPlatformIcons.default.theme; - - if (defaultPlatformIcons.hasOwnProperty(type)) { - icon = defaultPlatformIcons[type].icon; - color = defaultPlatformIcons[type].color; - theme = defaultPlatformIcons[type].theme; - } - - return ( - - - - ); - }, - // todo add filtering options - }, - { - title: 'Owner', - dataIndex: 'enrolmentInfo', - key: 'owner', - render: enrolmentInfo => enrolmentInfo.owner, - // todo add filtering options - }, - { - title: 'Ownership', - dataIndex: 'enrolmentInfo', - key: 'ownership', - render: enrolmentInfo => enrolmentInfo.ownership, - // todo add filtering options - }, - { - title: 'Status', - dataIndex: 'enrolmentInfo', - key: 'status', - // eslint-disable-next-line react/display-name - render: enrolmentInfo => { - const status = enrolmentInfo.status.toLowerCase(); - let color = '#f9ca24'; - switch (status) { - case 'active': - color = '#badc58'; - break; - case 'created': - color = '#6ab04c'; - break; - case 'removed': - color = '#ff7979'; - break; - case 'inactive': - color = '#f9ca24'; - break; - case 'blocked': - color = '#636e72'; - break; - } - return {status}; - }, - // todo add filtering options - }, - { - title: 'Last Updated', - dataIndex: 'enrolmentInfo', - key: 'dateOfLastUpdate', - // eslint-disable-next-line react/display-name - render: data => { - const { dateOfLastUpdate } = data; - const timeAgoString = getTimeAgo(dateOfLastUpdate); - return ( - - {timeAgoString} - - ); - }, - // todo add filtering options - }, -]; - -const getTimeAgo = time => { - const timeAgo = new TimeAgo('en-US'); - return timeAgo.format(time); -}; - -class deviceTable extends React.Component { - constructor(props) { - super(props); - config = this.props.context; - TimeAgo.addLocale(en); - this.state = { - data: [], - pagination: {}, - loading: false, - selectedRows: [], - paramsObj: {}, - }; - } - - rowSelection = { - onChange: (selectedRowKeys, selectedRows) => { - this.setState({ - selectedRows: selectedRows, - }); - }, - }; - - componentDidMount() { - if (this.props.apiUrl) { - this.fetch(); - } - } - - // Rerender component when parameters change - componentDidUpdate(prevProps, prevState, snapshot) { - if (prevProps.apiUrl !== this.props.apiUrl) { - this.fetch(); - } - } - - // fetch data from api - fetch = (params = {}) => { - this.setState({ loading: true }); - // get current page - const currentPage = params.hasOwnProperty('page') ? params.page : 1; - - const extraParams = { - offset: 10 * (currentPage - 1), // calculate the offset - limit: 10, - }; - - const encodedExtraParams = Object.keys(extraParams) - .map(key => key + '=' + extraParams[key]) - .join('&'); - - // send request to the invokerss - axios - .get(this.props.apiUrl + encodedExtraParams) - .then(res => { - if (res.status === 200) { - const pagination = { ...this.state.pagination }; - if ( - res.data.data.devices.length && - res.data.data.devices[0].hasOwnProperty('deviceInfo') - ) { - columns.push({ - title: 'OS Version', - dataIndex: 'deviceInfo', - key: 'osVersion', - render: deviceInfo => deviceInfo.osVersion, - }); - } - this.setState({ - loading: false, - data: res.data.data, - pagination, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load devices.', - }); - } - - this.setState({ loading: false }); - }); - }; - - handleTableChange = (pagination, filters, sorter) => { - const pager = { ...this.state.pagination }; - pager.current = pagination.current; - this.setState({ - pagination: pager, - }); - this.fetch({ - results: pagination.pageSize, - page: pagination.current, - sortField: sorter.field, - sortOrder: sorter.order, - ...filters, - }); - }; - - render() { - const { data, pagination, loading } = this.state; - return ( -
- - record.deviceIdentifier + - record.enrolmentInfo.owner + - record.enrolmentInfo.ownership - } - dataSource={data.devices} - pagination={{ - ...pagination, - size: 'small', - total: data.count, - showTotal: (total, range) => - `showing ${range[0]}-${range[1]} of ${total} devices`, - }} - loading={loading} - onChange={this.handleTableChange} - rowSelection={this.rowSelection} - /> - - ); - } -} - -export default withConfigContext(deviceTable); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/components/Filter/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/components/Filter/index.js deleted file mode 100644 index 72fc45eb75..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/components/Filter/index.js +++ /dev/null @@ -1,38 +0,0 @@ -import React from 'react'; - -import { Form, Input, Button } from 'antd'; - -class Filter extends React.Component { - handleSubmit = e => { - e.preventDefault(); - this.props.form.validateFields((err, values) => { - if (!err) { - Object.keys(values).forEach( - key => values[key] === undefined && delete values[key], - ); - this.props.callback({}, values); - } - }); - }; - - render() { - const { getFieldDecorator } = this.props.form; - - return ( - - {this.props.fields.map(field => ( - - {getFieldDecorator(field.name)( - , - )} - - ))} - -
record.serialNumber} - dataSource={data} - pagination={{ - ...pagination, - size: 'small', - // position: "top", - showTotal: (total, range) => - `showing ${range[0]}-${range[1]} of ${total} devices`, - // showQuickJumper: true - }} - loading={loading} - onChange={this.handleTableChange} - /> - - - ); - } -} - -export default withConfigContext(CertificateTable); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Configurations/scenes/Certificates/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Configurations/scenes/Certificates/index.js deleted file mode 100644 index f4bdc4862a..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Configurations/scenes/Certificates/index.js +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { PageHeader, Typography, Breadcrumb, Icon } from 'antd'; -import { Link } from 'react-router-dom'; -import CertificateTable from './components/CertificateTable'; - -const { Paragraph } = Typography; - -class Certificates extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - return ( -
- - - - - Home - - - Configurations - Certificates - -
-

Certificates

- Certificate configurations -
-
- -
-
-
-
- ); - } -} - -export default Certificates; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/index.js deleted file mode 100644 index 20cb9fd0f9..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/index.js +++ /dev/null @@ -1,254 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React, { Component } from 'react'; -import { Map, TileLayer, Marker, Popup, CircleMarker } from 'react-leaflet'; -import L from 'leaflet'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; -import axios from 'axios'; -import { message, notification } from 'antd'; - -// const { Title, Text } = Typography; - -// Icons for the location markers -const pinStart = new L.Icon({ - iconUrl: require('./pin_start.svg'), - iconRetinaUrl: require('./pin_start.svg'), - shadowUrl: require('./pin_shadow.svg'), - shadowSize: new L.Point(51, 51), - shadowAnchor: [22, 22], - popupAnchor: [0, -22], - iconSize: new L.Point(50, 50), - tooltipAnchor: [0, -22], -}); - -class DeviceLocationMap extends Component { - constructor(props) { - super(props); - this.config = this.props.context; - this.customMap = React.createRef(); - this.state = { - defaultZoomLevel: 3, - locations: [], - deviceData: {}, - minLatitute: -37.43997405227057, - maxLatitute: 37.43997405227057, - minLongtitute: -151.171875, - maxLongtitute: 151.34765625, - zoomLevel: 3, - deviceName: null, - isPopup: false, - }; - } - - componentDidMount() { - this.getDeviceLocations( - -37.43997405227057, - 37.43997405227057, - -151.171875, - 151.34765625, - 3, - ); - } - - getDeviceLocations = ( - minLatitute, - maxLatitute, - minLongtitute, - maxLongtitute, - zoomLevel, - ) => { - axios - .get( - window.location.origin + - this.config.serverConfig.invoker.uri + - this.config.serverConfig.invoker.deviceMgt + - '/geo-services/1.0.0/stats' + - '/device-locations?' + - 'minLat=' + - minLatitute + - '&maxLat=' + - maxLatitute + - '&minLong=' + - minLongtitute + - '&maxLong=' + - maxLongtitute + - '&zoom=' + - zoomLevel, - ) - .then(res => { - if (res.status === 200) { - // console.log(JSON.parse(res.data.data)); - this.setState({ - locations: JSON.parse(res.data.data), - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to fetch locations......', - }); - } - }); - }; - - setMarkers = positions => { - let markers = []; - positions.map(location => { - if (location.count > 1) { - markers.push( - - {location.count} - , - ); - } else { - markers.push( - - - {/* {this.getPopupData(*/} - {/* // location.deviceType, // location.deviceIdentification, // )}*/} - {/* {this.state.deviceData.name}*/} - {this.state.deviceName} - - , - ); - } - }); - - return ( -
- {markers.map(markker => { - return markker; - })} -
- ); - }; - - mouseOut = () => { - this.setState({ - isPopup: false, - }); - }; - - // todo get device details when mouse over the maker - mouseOver = (deviceType, deviceIdentification) => { - // let aaa = null; - // axios - // .get( - // window.location.origin + - // this.config.serverConfig.invoker.uri + - // this.config.serverConfig.invoker.deviceMgt + - // `/devices/1.0.0/${deviceType}/${deviceIdentification}`, - // ) - // .then(res => { - // if (res.status === 200) { - // // console.log(res.data.data); - // this.setState({ - // deviceData: res.data.data, - // isPopup: true, - // }); - // // aaa = res.data.data; - // // return ( - // //
- // // {aaa.name} - // // - // // Type : {aaa.type} - // // - // // - // // Status : {aaa.enrolmentInfo.status} - // // - // // - // // Owner : {aaa.enrolmentInfo.owner} - // // - // //
- // // ); - // } - // }) - // .catch(error => { - // if (error.hasOwnProperty('response') && error.response.status === 401) { - // message.error('You are not logged in'); - // window.location.href = window.location.origin + '/entgra/login'; - // } else { - // notification.error({ - // message: 'There was a problem', - // duration: 0, - // description: 'Error occurred while trying to fetch locations......', - // }); - // } - // }); - }; - - // Todo : get bound and zoom level when doing movement and pass id to getDeviceLocations function - handleMovements = event => { - console.log(this.customMap.current.leafletElement.getZoom()); - }; - - render() { - const position = [this.state.lat, this.state.lng]; - const attribution = this.config.geoMap.attribution; - const url = this.config.geoMap.url; - return ( -
- - - {this.setMarkers(this.state.locations)} - -
- ); - } -} - -export default withConfigContext(DeviceLocationMap); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/pin_shadow.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/pin_shadow.svg deleted file mode 100644 index ea27ab26a4..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/pin_shadow.svg +++ /dev/null @@ -1 +0,0 @@ -map \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/pin_start.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/pin_start.svg deleted file mode 100644 index 3a51859bfd..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/Component/DeviceLocationMap/pin_start.svg +++ /dev/null @@ -1 +0,0 @@ -map \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/index.js deleted file mode 100644 index 9cacbd879a..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceLocations/index.js +++ /dev/null @@ -1,39 +0,0 @@ -import React from 'react'; -import { Breadcrumb, PageHeader } from 'antd'; -import DeviceLocationMap from './Component/DeviceLocationMap'; - -class DeviceLocations extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - return ( -
- - - Devices Location - -
-

Devices Location

-
-
-
- -
-
- ); - } -} - -export default DeviceLocations; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceTypes/components/DeviceTypesTable/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceTypes/components/DeviceTypesTable/index.js deleted file mode 100644 index 2405a0dbce..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceTypes/components/DeviceTypesTable/index.js +++ /dev/null @@ -1,130 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import axios from 'axios'; -import { Card, Col, Icon, message, notification, Row } from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; - -let apiUrl; - -class Index extends React.Component { - constructor(props) { - super(props); - TimeAgo.addLocale(en); - this.state = { - data: [], - pagination: {}, - loading: false, - selectedRows: [], - }; - } - - componentDidMount() { - this.fetchUsers(); - } - - // fetch data from api - fetchUsers = (params = {}) => { - const config = this.props.context; - this.setState({ loading: true }); - - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/device-types'; - - // send request to the invokerss - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - const pagination = { ...this.state.pagination }; - this.setState({ - loading: false, - data: JSON.parse(res.data.data), - pagination, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load device types.', - }); - } - - this.setState({ loading: false }); - }); - }; - - handleTableChange = (pagination, filters, sorter) => { - const pager = { ...this.state.pagination }; - pager.current = pagination.current; - this.setState({ - pagination: pager, - }); - this.fetch({ - results: pagination.pageSize, - page: pagination.current, - sortField: sorter.field, - sortOrder: sorter.order, - ...filters, - }); - }; - - render() { - const { data } = this.state; - const { Meta } = Card; - const itemCard = data.map(data => ( - - , - , - ]} - > - } - title={data.name} - /> - - - )); - return ( -
- {itemCard} -
- ); - } -} - -export default withConfigContext(Index); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceTypes/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceTypes/index.js deleted file mode 100644 index 2ef4b495a3..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/DeviceTypes/index.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { PageHeader, Typography, Breadcrumb, Icon } from 'antd'; -import { Link } from 'react-router-dom'; -import DeviceTypesTable from './components/DeviceTypesTable'; - -const { Paragraph } = Typography; - -class DeviceTypes extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - return ( -
- - - - - Home - - - Device Types - -
-

Device Types

- All device types for device management. -
-
- -
-
-
-
- ); - } -} - -export default DeviceTypes; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/components/DevicesTable/components/BulkActionBar/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/components/DevicesTable/components/BulkActionBar/index.js deleted file mode 100644 index f55d6b2440..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/components/DevicesTable/components/BulkActionBar/index.js +++ /dev/null @@ -1,133 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Button, Tooltip, Popconfirm, Divider } from 'antd'; - -class BulkActionBar extends React.Component { - constructor(props) { - super(props); - this.state = { - selectedMultiple: false, - selectedSingle: false, - canDelete: true, - }; - } - - // This method checks whether NON-REMOVED devices are selected - onDeleteDeviceCall = () => { - let tempDeleteState; - for (let i = 0; i < this.props.selectedRows.length; i++) { - if (this.props.selectedRows[i].enrolmentInfo.status != 'REMOVED') { - tempDeleteState = false; - break; - } - tempDeleteState = true; - } - this.setState({ canDelete: tempDeleteState }); - }; - - onConfirmDelete = () => { - if (this.state.canDelete) { - this.props.deleteDevice(); - } - }; - - onConfirmDisenroll = () => { - this.props.disenrollDevice(); - }; - - onDeviceGroupCall = () => { - this.props.getGroups(); - }; - - render() { - const isSelected = this.props.selectedRows.length > 0; - const isSelectedSingle = this.props.selectedRows.length == 1; - - return ( -
- - -
- ); - } -} - -export default BulkActionBar; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/components/DevicesTable/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/components/DevicesTable/index.js deleted file mode 100644 index e2e1a2b778..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/components/DevicesTable/index.js +++ /dev/null @@ -1,553 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import axios from 'axios'; -import { - Icon, - message, - Modal, - notification, - Select, - Table, - Tag, - Tooltip, -} from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; -import BulkActionBar from './components/BulkActionBar'; -import { Link } from 'react-router-dom'; - -let config = null; - -const columns = [ - { - title: 'Device', - dataIndex: 'name', - width: 100, - }, - { - title: 'Type', - dataIndex: 'type', - key: 'type', - // eslint-disable-next-line react/display-name - render: type => { - const defaultPlatformIcons = config.defaultPlatformIcons; - let icon = defaultPlatformIcons.default.icon; - let color = defaultPlatformIcons.default.color; - let theme = defaultPlatformIcons.default.theme; - - if (defaultPlatformIcons.hasOwnProperty(type)) { - icon = defaultPlatformIcons[type].icon; - color = defaultPlatformIcons[type].color; - theme = defaultPlatformIcons[type].theme; - } - - return ( - - - - ); - }, - // todo add filtering options - }, - { - title: 'Owner', - dataIndex: 'enrolmentInfo', - key: 'owner', - render: enrolmentInfo => enrolmentInfo.owner, - // todo add filtering options - }, - { - title: 'Ownership', - dataIndex: 'enrolmentInfo', - key: 'ownership', - render: enrolmentInfo => enrolmentInfo.ownership, - // todo add filtering options - }, - { - title: 'Status', - dataIndex: 'enrolmentInfo', - key: 'status', - // eslint-disable-next-line react/display-name - render: enrolmentInfo => { - const status = enrolmentInfo.status.toLowerCase(); - let color = '#f9ca24'; - switch (status) { - case 'active': - color = '#badc58'; - break; - case 'created': - color = '#6ab04c'; - break; - case 'removed': - color = '#ff7979'; - break; - case 'inactive': - color = '#f9ca24'; - break; - case 'blocked': - color = '#636e72'; - break; - } - return {status}; - }, - // todo add filtering options - }, - { - title: 'Last Updated', - dataIndex: 'enrolmentInfo', - key: 'dateOfLastUpdate', - // eslint-disable-next-line react/display-name - render: data => { - const { dateOfLastUpdate } = data; - const timeAgoString = getTimeAgo(dateOfLastUpdate); - return ( - - {timeAgoString} - - ); - }, - // todo add filtering options - }, - { - title: '', - dataIndex: 'deviceIdentifier', - key: 'actions', - // eslint-disable-next-line react/display-name - render: (data, row) => { - const { type, deviceIdentifier } = row; - return ( - - Location History - - ); - }, - }, -]; - -const getTimeAgo = time => { - const timeAgo = new TimeAgo('en-US'); - return timeAgo.format(time); -}; - -class DeviceTable extends React.Component { - constructor(props) { - super(props); - config = this.props.context; - TimeAgo.addLocale(en); - this.state = { - data: [], - pagination: {}, - loading: false, - selectedRows: [], - deviceGroups: [], - groupModalVisible: false, - selectedGroupId: [], - selectedRowKeys: [], - }; - } - - componentDidMount() { - this.fetch(); - } - - // fetch data from api - fetch = (params = {}) => { - const config = this.props.context; - this.setState({ loading: true }); - // get current page - const currentPage = params.hasOwnProperty('page') ? params.page : 1; - - const extraParams = { - offset: 10 * (currentPage - 1), // calculate the offset - limit: 10, - requireDeviceInfo: true, - }; - - const encodedExtraParams = Object.keys(extraParams) - .map(key => key + '=' + extraParams[key]) - .join('&'); - - // send request to the invoker - axios - .get( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/devices?' + - encodedExtraParams, - ) - .then(res => { - if (res.status === 200) { - const pagination = { ...this.state.pagination }; - this.setState({ - loading: false, - data: res.data.data.devices, - pagination, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load devices.', - }); - } - - this.setState({ loading: false }); - }); - }; - - deleteDevice = () => { - const config = this.props.context; - this.setState({ loading: true }); - - const deviceData = this.state.selectedRows.map(obj => obj.deviceIdentifier); - - // send request to the invoker - axios - .put( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/admin/devices/permanent-delete', - deviceData, - { headers: { 'Content-Type': 'application/json' } }, - ) - .then(res => { - if (res.status === 200) { - this.fetch(); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to delete devices.', - }); - } - - this.setState({ loading: false }); - }); - }; - - disenrollDevice = () => { - const config = this.props.context; - this.setState({ loading: true }); - - const deviceData = this.state.selectedRows[0]; - - // send request to the invoker - axios - .delete( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/devices/type/' + - deviceData.type + - '/id/' + - deviceData.deviceIdentifier, - { headers: { 'Content-Type': 'application/json' } }, - ) - .then(res => { - if (res.status === 200) { - this.fetch(); - this.setState({ - selectedRowKeys: [], - }); - notification.success({ - message: 'Done', - duration: 4, - description: 'Successfully dis-enrolled the device.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to dis-enroll devices.', - }); - } - - this.setState({ loading: false }); - }); - }; - - addDevicesToGroup = groupId => { - const config = this.props.context; - this.setState({ loading: true }); - - let apiUrl; - let deviceData; - if (this.state.selectedRows.length === 1) { - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups/device/assign'; - deviceData = { - deviceIdentifier: { - id: this.state.selectedRows[0].deviceIdentifier, - type: this.state.selectedRows[0].type, - }, - deviceGroupIds: groupId, - }; - } else if (!groupId[0]) { - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups/id/' + - groupId + - '/devices/add'; - deviceData = this.state.selectedRows.map(obj => ({ - id: obj.deviceIdentifier, - type: obj.type, - })); - } else { - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups/id/' + - groupId[0] + - '/devices/add'; - deviceData = this.state.selectedRows.map(obj => ({ - id: obj.deviceIdentifier, - type: obj.type, - })); - } - - // send request to the invoker - axios - .post(apiUrl, deviceData, { - headers: { 'Content-Type': 'application/json' }, - }) - .then(res => { - if (res.status === 200) { - this.setState({ - loading: false, - }); - notification.success({ - message: 'Done', - duration: 4, - description: 'Successfully added to the device group.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while adding to the device group.', - }); - } - - this.setState({ loading: false }); - }); - }; - - getGroups = () => { - this.setState({ - groupModalVisible: true, - }); - // send request to the invoker - axios - .get( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups', - ) - .then(res => { - this.setState({ deviceGroups: res.data.data.deviceGroups }); - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while retrieving device groups.', - }); - } - - this.setState({ loading: false }); - }); - }; - - handleOk = e => { - if (this.state.selectedGroupId) { - this.addDevicesToGroup(this.state.selectedGroupId); - this.setState({ - groupModalVisible: false, - }); - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Please select a group.', - }); - } - }; - - handleCancel = e => { - this.setState({ - groupModalVisible: false, - }); - }; - - onGroupSelectChange = value => { - this.setState({ selectedGroupId: value }); - }; - - handleTableChange = (pagination, filters, sorter) => { - const pager = { ...this.state.pagination }; - pager.current = pagination.current; - this.setState({ - pagination: pager, - }); - this.fetch({ - results: pagination.pageSize, - page: pagination.current, - sortField: sorter.field, - sortOrder: sorter.order, - ...filters, - }); - }; - - onSelectChange = (selectedRowKeys, selectedRows) => { - this.setState({ - selectedRowKeys, - selectedRows: selectedRows, - }); - }; - - render() { - const { - data, - pagination, - loading, - selectedRows, - selectedRowKeys, - } = this.state; - const isSelectedSingle = this.state.selectedRows.length == 1; - - let selectedText; - if (isSelectedSingle) { - selectedText = 'You have selected 1 device'; - } else { - selectedText = - 'You have selected ' + this.state.selectedRows.length + ' devices'; - } - - const rowSelection = { - selectedRowKeys, - selectedRows, - onChange: this.onSelectChange, - }; - - let item = this.state.deviceGroups.map(data => ( - - {data.name} - - )); - return ( -
- -
-
- record.deviceIdentifier + - record.enrolmentInfo.owner + - record.enrolmentInfo.ownership - } - dataSource={data} - pagination={{ - ...pagination, - size: 'small', - // position: "top", - showTotal: (total, range) => - `showing ${range[0]}-${range[1]} of ${total} devices`, - // showQuickJumper: true - }} - loading={loading} - onChange={this.handleTableChange} - rowSelection={rowSelection} - /> - - - -

{selectedText}

- -
- - ); - } -} - -export default withConfigContext(DeviceTable); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/index.js deleted file mode 100644 index 542fb88ec6..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/index.js +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { PageHeader, Typography, Breadcrumb, Icon } from 'antd'; -import { Link } from 'react-router-dom'; -import DeviceTable from './components/DevicesTable'; - -const { Paragraph } = Typography; - -class Devices extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - return ( -
- - - - - Home - - - Devices - -
-

Devices

- All enrolled devices -
-
- -
-
-
-
- ); - } -} - -export default Devices; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/AddDevice/components/DeviceType/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/AddDevice/components/DeviceType/index.js deleted file mode 100644 index f9ec0718c6..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/AddDevice/components/DeviceType/index.js +++ /dev/null @@ -1,78 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Card, Col, Icon, Row } from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../../../../../components/ConfigContext'; - -class DeviceType extends React.Component { - constructor(props) { - super(props); - TimeAgo.addLocale(en); - this.config = this.props.context; - this.state = { - data: this.config.deviceTypes, - pagination: {}, - loading: false, - selectedRows: [], - }; - } - - onClickCard = (e, deviceType) => { - this.props.getDeviceType(deviceType); - }; - - render() { - const { data } = this.state; - const { Meta } = Card; - const itemCard = data.map(data => ( - - this.onClickCard(e, data.name)} - cover={ - - } - > - - - - )); - return ( -
- {itemCard} -
- ); - } -} - -export default withConfigContext(DeviceType); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/AddDevice/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/AddDevice/index.js deleted file mode 100644 index a0bfb21a53..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/AddDevice/index.js +++ /dev/null @@ -1,128 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Form, Row, Col, Card, Steps } from 'antd'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; -import DeviceType from './components/DeviceType'; -import SelectEnrollmentType from '../SelectEnrolmentType'; -import EnrollDevice from '../EnrollDevice'; -import DownloadAgent from '../DownloadAgent'; -const { Step } = Steps; - -class AddDevice extends React.Component { - constructor(props) { - super(props); - this.config = this.props.context; - this.state = { - isAddDeviceModalVisible: false, - current: 0, - deviceType: 'android', - enrollmentType: 'qr', - }; - } - - getDeviceType = deviceType => { - this.setState({ - current: 1, - deviceType: deviceType, - }); - }; - - goNext = () => { - this.setState({ - current: 2, - }); - }; - - goBackToDeviceType = () => { - this.setState({ - current: 0, - }); - }; - - goBackToDownloadAgent = () => { - this.setState({ - current: 1, - }); - }; - - goBackToEnrollmentType = () => { - this.setState({ - current: 2, - }); - }; - - getEnrollmentData = enrollmentType => { - this.setState({ - current: 3, - enrollmentType: enrollmentType, - }); - }; - - render() { - const { current, deviceType, enrollmentType } = this.state; - return ( -
- -
- - - - - - - - - -
- -
-
- -
-
- -
- -
- -
-
- - - - ); - } -} - -export default withConfigContext( - Form.create({ name: 'add-device' })(AddDevice), -); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/DownloadAgent/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/DownloadAgent/index.js deleted file mode 100644 index 8a628ee439..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/DownloadAgent/index.js +++ /dev/null @@ -1,173 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Button, Card, Divider, message, notification } from 'antd'; -import TimeAgo from 'javascript-time-ago/modules/JavascriptTimeAgo'; -import en from 'javascript-time-ago/locale/en'; -import axios from 'axios'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; -import QRCode from 'qrcode.react'; - -class DownloadAgent extends React.Component { - constructor(props) { - super(props); - this.config = this.props.context; - TimeAgo.addLocale(en); - this.state = { - pagination: {}, - loading: false, - selectedRows: [], - buttonTitle: 'Download Agent', - skipButtonTitle: 'Skip', - }; - } - - onClickSkip = () => { - this.props.goNext(); - }; - - onClickGoBack = () => { - this.props.goBack(); - }; - - onClickDownloadAgent = () => { - this.downloadAgent(); - }; - - // fetch data from api - downloadAgent = () => { - const { deviceType } = this.props; - this.setState({ loading: true, buttonTitle: 'Downloading..' }); - - const apiUrl = - window.location.origin + - '/api/application-mgt/v1.0/artifact/' + - deviceType + - '/agent/-1234'; - - // send request to the invokerss - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - // Download file in same window - const url = window.URL.createObjectURL(new Blob([res.data])); - const link = document.createElement('a'); - link.href = url; - link.setAttribute('download', 'android-agent.apk'); // or any other extension - document.body.appendChild(link); - link.click(); - this.setState({ - loading: false, - buttonTitle: 'Download Agent', - skipButtonTitle: 'Next', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: - 'Error occurred while trying to download Entgra Android Agent', - }); - } - - this.setState({ loading: false }); - }); - }; - - render() { - const { loading, buttonTitle, skipButtonTitle } = this.state; - const { deviceType } = this.props; - - const apiUrl = - window.location.origin + - '/api/application-mgt/v1.0/artifact/' + - deviceType + - '/agent/-1234'; - return ( -
- Step 01 - Get your Android Agent. -
-

- The Android agent can be downloaded by using following QR. The - generated QR code can be scanned, and the agent APK downloaded from - the link, and transferred to the device and then installed. -

-
-
- Scan to get the Android Agent. -
- - - -
- OR -
- -
-

- Need help? Read  - - Entgra IoT Server documentation. - -

-
-
- - -
-
- ); - } -} - -export default withConfigContext(DownloadAgent); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/EnrollDevice/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/EnrollDevice/index.js deleted file mode 100644 index 72a63ea8ac..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/EnrollDevice/index.js +++ /dev/null @@ -1,217 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { - Divider, - message, - notification, - Select, - Card, - Spin, - Button, - Row, - Col, -} from 'antd'; -import TimeAgo from 'javascript-time-ago/modules/JavascriptTimeAgo'; -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; -import axios from 'axios'; -import QRCode from 'qrcode.react'; -import QRPlaceholder from '../../../../../../../../../public/images/qr-code.png'; -import installAgent from '../../../../../../../../../public/images/install_agent.png'; -import register from '../../../../../../../../../public/images/register.png'; -import registration from '../../../../../../../../../public/images/registration.png'; -import setProfile from '../../../../../../../../../public/images/set_profile.png'; - -const { Option } = Select; - -class EnrollDevice extends React.Component { - constructor(props) { - super(props); - this.config = this.props.context; - TimeAgo.addLocale(en); - this.state = { - isSelected: false, - loading: false, - payload: {}, - }; - } - - // fetch data from api - generateQRCode = ownershipType => { - const { deviceType } = this.props; - this.setState({ loading: true }); - - let apiUrl = - window.location.origin + - this.config.serverConfig.invoker.uri + - '/device-mgt/' + - deviceType + - '/v1.0/configuration/enrollment-qr-config/' + - ownershipType; - - // send request to the invokerss - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - this.setState({ - loading: false, - payload: res.data.data, - isSelected: true, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to get QR code payload.', - }); - } - - this.setState({ loading: false }); - }); - }; - - onChange = value => { - this.generateQRCode(value); - }; - - onClick = () => { - this.props.goBack(); - }; - - render() { - const { payload, isSelected, loading } = this.state; - const { enrollmentType } = this.props; - return ( -
-
- -
-

Step 1

-

- {/* eslint-disable-next-line react/no-unescaped-entities */} - Let's start by installing the Android agent on your device. Open - the downloaded file, and tap INSTALL. -

- - - -

Step 2

-

Tap Skip to proceed with the default enrollment process.

- - - -

Step 3

-

- Enter the server address based on your environment, in the text - box provided. -

- - - -

Step 4

-

Enter your:

-
-

Organization: carbon.super

-

Username: admin

-

Password: Your password

-
- - - - - -
- Generate QR code to QR based Provisioning. -
-
- -
- -
- - - -
-
- - - -
-
-
-
-
- -
- - ); - } -} - -export default withConfigContext(EnrollDevice); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/SelectEnrolmentType/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/SelectEnrolmentType/index.js deleted file mode 100644 index 3c18db71e9..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/components/SelectEnrolmentType/index.js +++ /dev/null @@ -1,94 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Button, Divider } from 'antd'; -import TimeAgo from 'javascript-time-ago/modules/JavascriptTimeAgo'; -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; - -class SelectEnrollmentType extends React.Component { - constructor(props) { - super(props); - this.config = this.props.context; - TimeAgo.addLocale(en); - this.state = { - pagination: {}, - loading: false, - selectedRows: [], - }; - } - - onEnrollWithQR = () => { - this.props.getEnrollmentData('qr'); - }; - - onEnrollManually = () => { - this.props.getEnrollmentData('manual'); - }; - - onClick = () => { - this.props.goBack(); - }; - - render() { - return ( -
- - Step 02 - Enroll the Android Agent. - - -
-

- {' '} - Your device can be enrolled with Entgra IoTS automatically via QR - code. To enroll first download agent as mentioned in Step 1 then - proceed with the ENROLL WITH QR option from the device setup - activity. Thereafter select the ownership configuration and scan the - generated QR to complete the process. -

-
-
- - - -
-
- -
-
- ); - } -} - -export default withConfigContext(SelectEnrollmentType); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/index.js deleted file mode 100644 index 9b5f78c316..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Devices/scenes/Enroll/index.js +++ /dev/null @@ -1,47 +0,0 @@ -import React from 'react'; -import { PageHeader, Typography, Breadcrumb, Icon } from 'antd'; -import { Link } from 'react-router-dom'; -import AddDevice from './components/AddDevice'; - -const { Paragraph } = Typography; - -class DeviceEnroll extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - return ( -
- - - - - Home - - - - Devices - - Enroll Device - -
-

Devices

- All enrolled devices -
-
- -
-
-
-
- ); - } -} - -export default DeviceEnroll; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/index.js deleted file mode 100644 index 7b3a88bfc2..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/index.js +++ /dev/null @@ -1,145 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React, { Component, Fragment } from 'react'; -import { - Map, - TileLayer, - Marker, - Polyline, - Popup, - Tooltip, -} from 'react-leaflet'; -import L from 'leaflet'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; - -// Icons for the location markers -const pinStart = new L.Icon({ - iconUrl: require('./pin_start.svg'), - iconRetinaUrl: require('./pin_start.svg'), - shadowUrl: require('./pin_shadow.svg'), - shadowSize: new L.Point(51, 51), - shadowAnchor: [22, 22], - popupAnchor: [0, -22], - iconSize: new L.Point(50, 50), - tooltipAnchor: [0, -22], -}); -const pinEnd = new L.Icon({ - iconUrl: require('./pin_end.svg'), - iconRetinaUrl: require('./pin_end.svg'), - shadowUrl: require('./pin_shadow.svg'), - shadowSize: new L.Point(51, 51), - shadowAnchor: [22, 22], - popupAnchor: [0, -22], - iconSize: new L.Point(65, 65), - tooltipAnchor: [0, -28], -}); - -class CustomMap extends Component { - constructor(props) { - super(props); - } - - /** - * Polyline draw for historical locations - * @param locationHistorySnapshots - location data object - * @returns content - */ - polylineMarker = locationHistorySnapshots => { - const polyLines = []; - locationHistorySnapshots.forEach(locationHistorySnapshots => { - polyLines.push( - { - return [snapshot.latitude, snapshot.longitude]; - })} - smoothFactor={10} - weight={5} - />, - ); - }); - - for (let i = 1; i < locationHistorySnapshots.length; i++) { - const startPosition = locationHistorySnapshots[i][0]; - const endingPosition = - locationHistorySnapshots[i - 1][ - locationHistorySnapshots[i - 1].length - 1 - ]; - polyLines.push( - , - ); - } - - return ( -
- {polyLines.map(polyLine => { - return polyLine; - })} -
- ); - }; - - render() { - const locationHistorySnapshots = this.props.locationHistorySnapshots; - const config = this.props.context; - const attribution = config.geoMap.attribution; - const url = config.geoMap.url; - const firstSnapshot = locationHistorySnapshots[0][0]; - const lastSnapshotList = - locationHistorySnapshots[locationHistorySnapshots.length - 1]; - const lastSnapshot = lastSnapshotList[lastSnapshotList.length - 1]; - const startingPoint = [firstSnapshot.latitude, firstSnapshot.longitude]; - const endPoint = [lastSnapshot.latitude, lastSnapshot.longitude]; - const zoom = config.geoMap.defaultZoomLevel; - return ( -
- - - - {this.polylineMarker(locationHistorySnapshots)} - - Start - - Start - - - - - End - - - - -
- ); - } -} - -export default withConfigContext(CustomMap); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_end.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_end.svg deleted file mode 100644 index 95b746b838..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_end.svg +++ /dev/null @@ -1 +0,0 @@ -map \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_shadow.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_shadow.svg deleted file mode 100644 index ea27ab26a4..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_shadow.svg +++ /dev/null @@ -1 +0,0 @@ -map \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_start.svg b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_start.svg deleted file mode 100644 index 3a51859bfd..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/CustomMap/pin_start.svg +++ /dev/null @@ -1 +0,0 @@ -map \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/GeoDashboard/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/GeoDashboard/index.js deleted file mode 100644 index d8f5951d0a..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/GeoDashboard/index.js +++ /dev/null @@ -1,172 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import moment from 'moment'; -import { message, notification, Empty, DatePicker } from 'antd'; -import axios from 'axios'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; -import GeoCustomMap from '../CustomMap'; -import './styles.css'; - -class GeoDashboard extends React.Component { - constructor(props) { - super(props); - let start = moment( - new Date( - new Date().getFullYear(), - new Date().getMonth(), - new Date().getDate(), - 0, - 0, - 0, - 0, - ), - ); - let end = moment(start) - .add(1, 'days') - .subtract(1, 'seconds'); - this.state = { - deviceData: [], - selectedDevice: '', - locationHistorySnapshots: [], - loading: false, - start: start, - end: end, - buttonTooltip: 'Fetch Locations', - }; - } - - componentDidMount() { - this.fetchLocationHistory(); - } - /** - * Call back on apply button in the date time picker - * @param startDate - start date - * @param endDate - end date - */ - applyCallback = (dates, dateStrings) => { - this.setState({ - start: dateStrings[0], - end: dateStrings[1], - }); - }; - - fetchLocationHistory = () => { - const toInMills = moment(this.state.end); - const fromInMills = moment(this.state.start); - const config = this.props.context; - this.setState({ loading: true }); - - axios - .get( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/devices/' + - this.props.deviceType + - '/' + - this.props.deviceIdentifier + - '/location-history?' + - 'from=' + - fromInMills + - '&to=' + - toInMills, - ) - .then(res => { - if (res.status === 200) { - this.setState({ - loading: false, - locationHistorySnapshots: res.data.data.locationHistorySnapshots, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to fetch locations......', - }); - } - - this.setState({ loading: false }); - console.log(error); - }); - }; - - /** - * Geo Dashboard controller - */ - controllerBar = () => { - const { RangePicker } = DatePicker; - let now = new Date(); - let start = moment( - new Date(now.getFullYear(), now.getMonth(), now.getDate(), 0, 0, 0, 0), - ); - let end = moment(start) - .add(1, 'days') - .subtract(1, 'seconds'); - let ranges = { - 'Today Only': [moment(start), moment(end)], - 'Yesterday Only': [ - moment(start).subtract(1, 'days'), - moment(end).subtract(1, 'days'), - ], - '3 Days': [moment(start).subtract(3, 'days'), moment(end)], - '5 Days': [moment(start).subtract(5, 'days'), moment(end)], - '1 Week': [moment(start).subtract(7, 'days'), moment(end)], - '2 Weeks': [moment(start).subtract(14, 'days'), moment(end)], - '1 Month': [moment(start).subtract(1, 'months'), moment(end)], - }; - - return ( -
- -
- ); - }; - - render() { - const { locationHistorySnapshots } = this.state; - return ( -
- {this.controllerBar()} - {locationHistorySnapshots.length > 0 ? ( - - ) : ( - - )} -
- ); - } -} - -export default withConfigContext(GeoDashboard); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/GeoDashboard/styles.css b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/GeoDashboard/styles.css deleted file mode 100644 index abd20795db..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/components/GeoDashboard/styles.css +++ /dev/null @@ -1,10 +0,0 @@ -.leaflet-container { - align-content: center; - padding-top: 80px; - height: 550px; - width: 100%; -} - -.controllerDiv { - padding-bottom: 30px; -} \ No newline at end of file diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/index.js deleted file mode 100644 index c313b91252..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Geo/index.js +++ /dev/null @@ -1,73 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { PageHeader, Typography, Breadcrumb, Icon } from 'antd'; -import { Link } from 'react-router-dom'; -import GeoDashboard from './components/GeoDashboard'; - -const { Paragraph } = Typography; - -class Geo extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - const { deviceIdentifier, deviceType } = this.props.match.params; - return ( -
- - - - - Home - - - - Devices - - {`Location History - ${deviceType} / ${deviceIdentifier}`} - -
-

Location History

- {`${deviceType} / ${deviceIdentifier}`} -
-
-
- -
-
- ); - } -} - -export default Geo; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/AddGroup/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/AddGroup/index.js deleted file mode 100644 index dfd1f0e3c1..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/AddGroup/index.js +++ /dev/null @@ -1,174 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { Button, Form, Input, message, Modal, notification } from 'antd'; -import axios from 'axios'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; - -class AddGroup extends React.Component { - constructor(props) { - super(props); - this.state = { - addModalVisible: false, - name: '', - description: '', - }; - } - - onConfirmAdGroup = () => { - const config = this.props.context; - - const groupData = { - name: this.state.name, - description: this.state.description, - }; - - // send request to the invoker - axios - .post( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups', - groupData, - { headers: { 'Content-Type': 'application/json' } }, - ) - .then(res => { - if (res.status === 201) { - this.props.fetchGroups(); - notification.success({ - message: 'Done', - duration: 4, - description: 'Successfully added the group.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to add group.', - }); - } - }); - }; - - openAddModal = () => { - this.setState({ - addModalVisible: true, - }); - }; - - handleAddOk = e => { - this.props.form.validateFields(err => { - if (!err) { - this.onConfirmAdGroup(); - this.setState({ - addModalVisible: false, - }); - } - }); - }; - - handleAddCancel = e => { - this.setState({ - addModalVisible: false, - }); - }; - - onChangeName = e => { - this.setState({ - name: e.currentTarget.value, - }); - }; - - onChangeDescription = e => { - this.setState({ - description: e.currentTarget.value, - }); - }; - - render() { - const { getFieldDecorator } = this.props.form; - return ( -
-
- -
-
- - Cancel - , - , - ]} - > -
-

Create new device group on IoT Server.

-
- - {getFieldDecorator('name', { - rules: [ - { - required: true, - message: 'Please input group name', - }, - ], - })()} - - - {getFieldDecorator('description', { - rules: [ - { - required: true, - message: 'Please input group description', - }, - ], - })()} - - -
-
-
-
- ); - } -} - -export default withConfigContext(Form.create({ name: 'add-group' })(AddGroup)); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/GroupActions/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/GroupActions/index.js deleted file mode 100644 index 80b8ed1380..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/GroupActions/index.js +++ /dev/null @@ -1,395 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { - Button, - Divider, - Form, - Icon, - Input, - message, - Modal, - notification, - Popconfirm, - Select, - Tooltip, - Typography, -} from 'antd'; -import axios from 'axios'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; - -const { Text } = Typography; - -class GroupActions extends React.Component { - constructor(props) { - super(props); - this.state = { - editModalVisible: false, - shareModalVisible: false, - name: this.props.data.name, - description: this.props.data.description, - groupDataObject: {}, - rolesData: [], - shareRolesData: [], - }; - } - - onConfirmDeleteGroup = () => { - const config = this.props.context; - - // send request to the invoker - axios - .delete( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups/id/' + - this.props.data.id, - { headers: { 'Content-Type': 'application/json' } }, - ) - .then(res => { - if (res.status === 200) { - this.props.fetchGroups(); - notification.success({ - message: 'Done', - duration: 4, - description: 'Successfully deleted the group.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to delete group.', - }); - } - }); - }; - - onConfirmUpdateGroup = data => { - const config = this.props.context; - - // send request to the invoker - axios - .put( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups/id/' + - this.props.data.id, - data, - ) - .then(res => { - if (res.status === 200) { - this.props.fetchGroups(); - notification.success({ - message: 'Done', - duration: 4, - description: 'Successfully updated the group.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to update group.', - }); - } - }); - }; - - fetchUserRoles = (params = {}) => { - const config = this.props.context; - - const apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/roles'; - - // send request to the invokerss - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - this.setState({ - rolesData: res.data.data.roles, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load roles.', - }); - } - }); - }; - - onConfirmShareGroup = data => { - const config = this.props.context; - - // send request to the invoker - axios - .post( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/groups/id/' + - this.props.data.id + - '/share', - data, - ) - .then(res => { - if (res.status === 200) { - this.props.fetchGroups(); - notification.success({ - message: 'Done', - duration: 4, - description: 'Successfully shared the group.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to share group.', - }); - } - }); - }; - - openEditModal = () => { - this.setState({ - editModalVisible: true, - }); - }; - - openShareModal = () => { - this.fetchUserRoles(); - this.setState({ - shareModalVisible: true, - }); - }; - - handleEditOk = e => { - const groupDataObject = { - name: this.state.name, - description: this.state.description, - id: this.props.data.id, - owner: this.props.data.owner, - groupProperties: this.props.data.groupProperties, - }; - - this.setState({ groupDataObject }); - - this.props.form.validateFields(err => { - if (!err) { - this.onConfirmUpdateGroup(this.state.groupDataObject); - this.setState({ - editModalVisible: false, - }); - } - }); - }; - - handleEditCancel = e => { - this.setState({ - editModalVisible: false, - }); - }; - - handleShareOk = e => { - this.setState({ - shareModalVisible: false, - }); - this.onConfirmShareGroup(this.state.shareRolesData); - }; - - handleShareCancel = e => { - this.setState({ - shareModalVisible: false, - }); - }; - - onChangeName = e => { - this.setState({ - name: e.currentTarget.value, - }); - }; - - onChangeDescription = e => { - this.setState({ - description: e.currentTarget.value, - }); - }; - - handleRolesDropdownChange = value => { - this.setState({ - shareRolesData: value, - }); - }; - - render() { - const isAdminGroups = this.props.data.id == 1 || this.props.data.id == 2; - const { getFieldDecorator } = this.props.form; - let item = this.state.rolesData.map(data => ( - - {data} - - )); - return ( -
-
- - - - - - - - - - - - - - - - - - - - - -
-
- - Cancel - , - , - ]} - > -
-

Enter new name and description for the group

-
- - {getFieldDecorator('name', { - initialValue: this.props.data.name, - rules: [ - { - required: true, - message: 'Please input group name', - }, - ], - })()} - - - {getFieldDecorator('description', { - initialValue: this.props.data.description, - rules: [ - { - required: true, - message: 'Please input group description', - }, - ], - })()} - - -
-
-
-
- - New Role - , - , - , - ]} - > -

Select user role(s)

- - , -
-
-
- ); - } -} - -export default withConfigContext( - Form.create({ name: 'group-actions' })(GroupActions), -); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/GroupDevicesModal/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/GroupDevicesModal/index.js deleted file mode 100644 index f844b79db2..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/components/GroupDevicesModal/index.js +++ /dev/null @@ -1,136 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; - -import { Button, Modal } from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; -import DevicesTable from '../../../../../../components/DevicesTable'; - -let apiUrl; - -class GroupDevicesModal extends React.Component { - constructor(props) { - super(props); - TimeAgo.addLocale(en); - this.state = { - data: [], - pagination: {}, - loading: false, - selectedRows: [], - visible: false, - apiUrl: null, - }; - } - - openDrawer = () => { - this.setState({ visible: true }); - const groupData = { - groupId: this.props.groupData.id, - groupName: this.props.groupData.name, - }; - this.fetchGroupDevices(groupData); - }; - - handleModalCancel = () => { - this.setState({ - visible: false, - }); - }; - - // fetch data from api - fetchGroupDevices = (params = {}, filters = {}) => { - const config = this.props.context; - - // get current page - const currentPage = params.hasOwnProperty('page') ? params.page : 1; - - const extraParams = { - offset: 10 * (currentPage - 1), // calculate the offset - limit: 10, - ...params, - }; - - const encodedExtraParams = Object.keys(extraParams) - .map(key => key + '=' + extraParams[key]) - .join('&'); - - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/devices?' + - encodedExtraParams; - - this.setState({ apiUrl: apiUrl }); - }; - - handleTableChange = (pagination, filters, sorter) => { - const pager = { ...this.state.pagination }; - pager.current = pagination.current; - this.setState({ - pagination: pager, - }); - this.fetchGroupDevices({ - results: pagination.pageSize, - page: pagination.current, - sortField: sorter.field, - sortOrder: sorter.order, - ...filters, - }); - }; - - render() { - const { apiUrl, visible } = this.state; - return ( -
- - - Cancel - , - , - ]} - > -
- -
-
-
- ); - } -} - -export default withConfigContext(GroupDevicesModal); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/index.js deleted file mode 100644 index 5ba0a8497b..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/components/GroupsTable/index.js +++ /dev/null @@ -1,219 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import axios from 'axios'; -import { message, notification, Table } from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; -import GroupActions from './components/GroupActions'; -import AddGroup from './components/AddGroup'; -import Filter from '../../../../components/Filter'; -import GroupDevicesModal from './components/GroupDevicesModal'; - -const searchFields = [ - { - name: 'name', - placeholder: 'Name', - }, - { - name: 'owner', - placeholder: 'Owner', - }, -]; - -let apiUrl; - -class GroupsTable extends React.Component { - constructor(props) { - super(props); - TimeAgo.addLocale(en); - this.state = { - data: [], - pagination: {}, - loading: false, - selectedRows: [], - }; - } - - columns = [ - { - title: 'Group Name', - dataIndex: 'name', - width: 100, - }, - { - title: 'Owner', - dataIndex: 'owner', - key: 'owner', - // render: enrolmentInfo => enrolmentInfo.owner - // todo add filtering options - }, - { - title: 'Description', - dataIndex: 'description', - key: 'description', - // render: enrolmentInfo => enrolmentInfo.ownership - // todo add filtering options - }, - { - title: 'Action', - dataIndex: 'id', - key: 'action', - render: (id, row) => ( - - - - ), - }, - { - title: 'Devices', - dataIndex: 'id', - key: 'details', - render: (id, row) => , - }, - { - title: 'Devices', - dataIndex: 'id', - key: 'details', - render: (id, row) => , - }, - ]; - - rowSelection = { - onChange: (selectedRowKeys, selectedRows) => { - this.setState({ - selectedRows: selectedRows, - }); - }, - }; - - componentDidMount() { - this.fetchGroups(); - } - - // fetch data from api - fetchGroups = (params = {}, filters = {}) => { - const config = this.props.context; - this.setState({ loading: true }); - - // get current page - const currentPage = params.hasOwnProperty('page') ? params.page : 1; - - const extraParams = { - offset: 10 * (currentPage - 1), // calculate the offset - limit: 10, - ...filters, - }; - - const encodedExtraParams = Object.keys(extraParams) - .map(key => key + '=' + extraParams[key]) - .join('&'); - - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/admin/groups?' + - encodedExtraParams; - - // send request to the invokerss - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - const pagination = { ...this.state.pagination }; - this.setState({ - loading: false, - data: res.data.data, - pagination, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load device groups.', - }); - } - - this.setState({ loading: false }); - }); - }; - - handleTableChange = (pagination, filters, sorter) => { - const pager = { ...this.state.pagination }; - pager.current = pagination.current; - this.setState({ - pagination: pager, - }); - this.fetchGroups({ - results: pagination.pageSize, - page: pagination.current, - sortField: sorter.field, - sortOrder: sorter.order, - ...filters, - }); - }; - - render() { - const { data, pagination, loading } = this.state; - - return ( -
-
- -
-
- -
-
-
record.id} - dataSource={data.deviceGroups} - pagination={{ - ...pagination, - size: 'small', - total: data.count, - pageSize: 10, - showTotal: (total, range) => - `showing ${range[0]}-${range[1]} of ${total} groups`, - }} - loading={loading} - onChange={this.handleTableChange} - rowSelection={this.rowSelection} - /> - - - ); - } -} - -export default withConfigContext(GroupsTable); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/index.js deleted file mode 100644 index 5dac20d050..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Groups/index.js +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { PageHeader, Typography, Breadcrumb, Icon } from 'antd'; -import { Link } from 'react-router-dom'; -import GroupsTable from './components/GroupsTable'; - -const { Paragraph } = Typography; - -class Groups extends React.Component { - routes; - - constructor(props) { - super(props); - this.routes = props.routes; - } - - render() { - return ( -
- - - - - Home - - - Groups - -
-

Groups

- All device groups. -
-
-
- -
-
- ); - } -} - -export default Groups; diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Notifications/Components/NotificationsTable/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Notifications/Components/NotificationsTable/index.js deleted file mode 100644 index 2b5b2bfc66..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Notifications/Components/NotificationsTable/index.js +++ /dev/null @@ -1,197 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import axios from 'axios'; -import { Icon, Table } from 'antd'; -import TimeAgo from 'javascript-time-ago'; -// Load locale-specific relative date/time formatting rules. -import en from 'javascript-time-ago/locale/en'; -import { withConfigContext } from '../../../../../../components/ConfigContext'; -import { handleApiError } from '../../../../../../services/utils/errorHandler'; - -let config = null; - -const columns = [ - { - title: 'Device', - dataIndex: 'deviceName', - width: 100, - sorter: (a, b) => a.deviceName.localeCompare(b.deviceName), - }, - { - title: 'Type', - dataIndex: 'deviceType', - key: 'type', - // eslint-disable-next-line react/display-name - render: type => { - const defaultPlatformIcons = config.defaultPlatformIcons; - let icon = defaultPlatformIcons.default.icon; - let color = defaultPlatformIcons.default.color; - let theme = defaultPlatformIcons.default.theme; - - if (defaultPlatformIcons.hasOwnProperty(type)) { - icon = defaultPlatformIcons[type].icon; - color = defaultPlatformIcons[type].color; - theme = defaultPlatformIcons[type].theme; - } - - return ( - - - - ); - }, - }, - { - title: 'Description', - dataIndex: 'description', - key: 'description', - }, -]; - -class NotificationsTable extends React.Component { - constructor(props) { - super(props); - config = this.props.context; - TimeAgo.addLocale(en); - this.state = { - data: [], - pagination: {}, - loading: false, - selectedRows: [], - paramsObj: {}, - }; - } - - rowSelection = { - onChange: (selectedRowKeys, selectedRows) => { - this.setState({ - selectedRows: selectedRows, - }); - }, - }; - - componentDidMount() { - this.fetchData(); - } - - // Rerender component when parameters change - componentDidUpdate(prevProps, prevState, snapshot) { - if (prevProps.notificationType !== this.props.notificationType) { - this.fetchData(); - } - } - - // fetch data from api - fetchData = (params = {}) => { - // const policyReportData = this.props; - this.setState({ loading: true }); - // get current page - const currentPage = params.hasOwnProperty('page') ? params.page : 1; - - let extraParams; - - extraParams = { - offset: 10 * (currentPage - 1), // calculate the offset - limit: 10, - }; - - const encodedExtraParams = Object.keys(extraParams) - .map(key => key + '=' + extraParams[key]) - .join('&'); - - let apiUrl; - - if (this.props.notificationType === 'unread') { - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/notifications?status=NEW&' + - encodedExtraParams; - } else { - apiUrl = - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/notifications?' + - encodedExtraParams; - } - - // send request to the invoker - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - const pagination = { ...this.state.pagination }; - this.setState({ - loading: false, - data: res.data.data, - pagination, - }); - } - }) - .catch(error => { - handleApiError(error, 'Error occurred while trying to load devices.'); - this.setState({ loading: false }); - }); - }; - - handleTableChange = (pagination, filters, sorter) => { - const pager = { ...this.state.pagination }; - pager.current = pagination.current; - this.setState({ - pagination: pager, - }); - this.fetchData({ - results: pagination.pageSize, - page: pagination.current, - sortField: sorter.field, - sortOrder: sorter.order, - ...filters, - }); - }; - - render() { - let { data, pagination, loading } = this.state; - - return ( -
-
record.id} - dataSource={data.notifications} - pagination={{ - ...pagination, - size: 'small', - // position: "top", - total: data.count, - showTotal: (total, range) => - `showing ${range[0]}-${range[1]} of ${total} notifications`, - }} - loading={loading} - onChange={this.handleTableChange} - rowSelection={this.rowSelection} - /> - - ); - } -} - -export default withConfigContext(NotificationsTable); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Notifications/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Notifications/index.js deleted file mode 100644 index 456c3a9dab..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Notifications/index.js +++ /dev/null @@ -1,132 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { - message, - notification, - Button, - PageHeader, - Breadcrumb, - Icon, - Radio, -} from 'antd'; -import { withConfigContext } from '../../../../components/ConfigContext'; -import axios from 'axios'; -import { Link } from 'react-router-dom'; - -import NotificationsTable from './Components/NotificationsTable'; - -class Notifications extends React.Component { - constructor(props) { - super(props); - this.state = { - visible: false, - data: [], - notificationType: 'all', - }; - } - - handleModeChange = e => { - const notificationType = e.target.value; - this.setState({ notificationType }); - }; - - clearNotifications = () => { - const config = this.props.context; - axios - .put( - window.location.origin + - config.serverConfig.invoker.uri + - config.serverConfig.invoker.deviceMgt + - '/notifications/clear-all', - { 'Content-Type': 'application/json; charset=utf-8' }, - ) - .then(res => { - if (res.status === 200) { - notification.success({ - message: 'Done', - duration: 0, - description: 'All notifications are cleared.', - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to clear notifications.', - }); - } - }); - }; - - render() { - const { notificationType } = this.state; - return ( -
- - - - - Home - - - Notifications - -
-

DEVICE NOTIFICATIONS

- - All Notifications - Unread Notifications - - -
- -
-
-
-
-
- ); - } -} - -export default withConfigContext(Notifications); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Policies/components/AddPolicy/components/AssignGroups/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Policies/components/AddPolicy/components/AssignGroups/index.js deleted file mode 100644 index e90d0fa9dd..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Policies/components/AddPolicy/components/AssignGroups/index.js +++ /dev/null @@ -1,260 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ -import React from 'react'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; -import { Button, Col, Form, message, notification, Radio, Select } from 'antd'; -import axios from 'axios'; -const { Option } = Select; - -class AssignGroups extends React.Component { - constructor(props) { - super(props); - this.config = this.props.context; - this.userSelector = React.createRef(); - this.roleSelector = React.createRef(); - this.state = { - roles: [], - users: [], - groups: [], - }; - } - componentDidMount() { - this.getRolesList(); - this.getGroupsList(); - } - - handleSetUserRoleFormItem = event => { - if (event.target.value === 'roleSelector') { - this.roleSelector.current.style.cssText = 'display: block;'; - this.userSelector.current.style.cssText = 'display: none;'; - } else { - this.roleSelector.current.style.cssText = 'display: none;'; - this.userSelector.current.style.cssText = 'display: block;'; - } - }; - - // generate payload by adding Assign Groups - onHandleContinue = (e, formName) => { - this.props.form.validateFields((err, values) => { - if (!err) { - if (typeof values.roles === 'string') { - values.roles = [values.roles]; - } - if (!values.users) { - delete values.users; - } - - if (values.deviceGroups === 'NONE') { - delete values.deviceGroups; - } - - this.props.getPolicyPayloadData(formName, values); - this.props.getNextStep(); - } - }); - }; - - getRolesList = () => { - let apiURL = - window.location.origin + - this.config.serverConfig.invoker.uri + - this.config.serverConfig.invoker.deviceMgt + - '/roles?user-store=PRIMARY&limit=100'; - - axios - .get(apiURL) - .then(res => { - if (res.status === 200) { - this.setState({ - roles: res.data.data.roles, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load roles.', - }); - } - }); - }; - - getUsersList = value => { - let apiURL = - window.location.origin + - this.config.serverConfig.invoker.uri + - this.config.serverConfig.invoker.deviceMgt + - '/users/search/usernames?filter=' + - value + - '&domain=Primary'; - axios - .get(apiURL) - .then(res => { - if (res.status === 200) { - let users = JSON.parse(res.data.data); - this.setState({ - users, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load users.', - }); - } - }); - }; - - // fetch data from api - getGroupsList = () => { - let apiUrl = - window.location.origin + - this.config.serverConfig.invoker.uri + - this.config.serverConfig.invoker.deviceMgt + - '/admin/groups'; - - // send request to the invokerss - axios - .get(apiUrl) - .then(res => { - if (res.status === 200) { - this.setState({ - groups: res.data.data.deviceGroups, - }); - } - }) - .catch(error => { - if (error.hasOwnProperty('response') && error.response.status === 401) { - // todo display a popop with error - message.error('You are not logged in'); - window.location.href = window.location.origin + '/entgra/login'; - } else { - notification.error({ - message: 'There was a problem', - duration: 0, - description: 'Error occurred while trying to load device groups.', - }); - } - }); - }; - - render() { - const { getFieldDecorator } = this.props.form; - return ( -
-
- - Set User role(s) - Set User(s) - -
- - {getFieldDecorator('roles', { - initialValue: 'ANY', - })( - , - )} - -
-
- - {getFieldDecorator('users', {})( - , - )} - -
-
- - {getFieldDecorator('deviceGroups', { - initialValue: 'NONE', - })( - , - )} - -
-
- - -
- - - ); - } -} - -export default withConfigContext(Form.create()(AssignGroups)); diff --git a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Policies/components/AddPolicy/components/ConfigureProfile/index.js b/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Policies/components/AddPolicy/components/ConfigureProfile/index.js deleted file mode 100644 index 87e42ee0ca..0000000000 --- a/components/device-mgt/io.entgra.device.mgt.ui/react-app/src/scenes/Home/scenes/Policies/components/AddPolicy/components/ConfigureProfile/index.js +++ /dev/null @@ -1,971 +0,0 @@ -/* - * Copyright (c) 2020, Entgra (pvt) Ltd. (http://entgra.io) All Rights Reserved. - * - * Entgra (pvt) Ltd. 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. - */ - -import React from 'react'; -import { - Tabs, - Row, - Col, - Switch, - Input, - Typography, - Form, - Collapse, - Checkbox, - Select, - Tooltip, - Icon, - Table, - Alert, - Upload, - Popconfirm, - Button, - Radio, -} from 'antd'; -import { withConfigContext } from '../../../../../../../../components/ConfigContext'; -import '../../../../styles.css'; -import moment from 'moment'; -const { Text, Title, Paragraph } = Typography; -const { TabPane } = Tabs; -const { Option } = Select; -const { TextArea } = Input; - -const subPanelpayloadAttributesforCheckboxes = {}; -const subPanelpayloadAttributesforSelect = {}; -let formContainers = {}; - -class ConfigureProfile extends React.Component { - constructor(props) { - super(props); - this.config = this.props.context; - this.state = { - loading: false, - isDisplayMain: 'none', - activePanelKeys: [], - activeSubPanelKeys: [], - subFormList: [], - subPanelpayloadAttributes: {}, - count: 0, - dataArray: [], - customInputDataArray: [], - inputTableDataSources: {}, - addPolicyForms: null, - }; - } - - // convert time from 24h format to 12h format - timeConverter = time => { - time = time - .toString() - .match(/^([01]\d|2[0-3])(:)([0-5]\d)(:[0-5]\d)?$/) || [time]; - if (time.length > 1) { - time = time.slice(1); - time[5] = +time[0] < 12 ? ' AM' : ' PM'; - time[0] = +time[0] % 12 || 12; - } - return time.join(''); - }; - - // get Option value from start Time, end Time and time difference between 2 values - getOptionForTimeSelectors = (startTimeValue, endTimeValue, timeIncrement) => { - let timeOptions = []; - let time = new Date( - moment() - .startOf('day') - .format('YYYY/MM/DD'), - ); - let tempValue = startTimeValue; - time.setMinutes(time.getMinutes() + tempValue); - let startOption = ( - - ); - timeOptions.push(startOption); - - while (tempValue !== endTimeValue) { - time = new Date( - moment() - .startOf('day') - .format('YYYY/MM/DD'), - ); - tempValue += timeIncrement; - if (tempValue > 1440) { - tempValue = 0; - continue; - } - time.setMinutes(time.getMinutes() + tempValue); - let option = ( - - ); - timeOptions.push(option); - } - return timeOptions; - }; - - // handle items which handle from radio buttons - handleRadioPanel = (e, subPanel) => { - { - subPanel.map((panel, i) => { - if (panel.value === e.target.value) { - document.getElementById(panel.value).style.display = 'block'; - } else { - document.getElementById(panel.value).style.display = 'none'; - } - }); - } - }; - - // handle items which handle from select options - handleSelectedPanel = (e, subPanel) => { - { - subPanel.map((panel, i) => { - if (panel.id === e) { - document.getElementById(panel.id).style.display = 'block'; - } else { - document.getElementById(panel.id).style.display = 'none'; - } - }); - } - }; - - // handle items which handle from checkbox - handleSubPanel = e => { - if (e.target.checked) { - let joined = this.state.activeSubPanelKeys.concat(e.target.id); - this.setState({ activeSubPanelKeys: joined }); - } else { - let index = this.state.activeSubPanelKeys.indexOf(e.target.id); - if (index !== -1) { - this.state.activeSubPanelKeys.splice(index, 1); - let removed = this.state.activeSubPanelKeys; - this.setState({ activeSubPanelKeys: removed }); - } - } - }; - - // handle Switch on off button - handleMainPanel = (e, ref) => { - if (e) { - let joined = this.state.activePanelKeys.concat(ref); - this.setState({ activePanelKeys: joined }); - } else { - let index = this.state.activePanelKeys.indexOf(ref); - if (index !== -1) { - this.state.activePanelKeys.splice(index, 1); - let removed = this.state.activePanelKeys; - this.setState({ activePanelKeys: removed }); - } - } - }; - - handleCustomInputTable = event => { - const { count, customInputDataArray } = this.state; - - const newData = [ - { - key: count, - CERT_NAME: `${event.file.name}`, - }, - ]; - this.setState({ - customInputDataArray: [...customInputDataArray, newData], - count: count + 1, - }); - }; - - handleAdd = array => { - const { count, inputTableDataSources } = this.state; - const newData = [ - { - key: count, - }, - ]; - inputTableDataSources[array].push(newData); - Object.defineProperty(inputTableDataSources, array, { - value: inputTableDataSources[array], - }); - this.setState({ - inputTableDataSources, - count: count + 1, - }); - }; - - getColumns = ({ getFieldDecorator }, arr) => { - const columnArray = []; - const actionColumn = [ - { - title: '', - dataIndex: 'operation', - render: (name, row) => ( - - - - - - - - - - ), - }, - ]; - Object.values(arr).map((columnData, c) => { - if (columnData.type === 'input') { - const column = { - title: `${columnData.name}`, - dataIndex: `${columnData.key}`, - key: `${columnData.key}`, - render: (name, row, i) => ( - - {getFieldDecorator(`${columnData.key}${i}`, {})( - , - )} - - ), - }; - columnArray.push(column); - } else if (columnData.type === 'upload') { - const column = { - title: `${columnData.name}`, - dataIndex: `${columnData.key}`, - key: `${columnData.key}`, - render: (name, row, i) => ( - - {getFieldDecorator(`${columnData.key}${i}`, {})( - - - , - )} - - ), - }; - columnArray.push(column); - } else if (columnData.type === 'select') { - const column = { - title: `${columnData.name}`, - dataIndex: `${columnData.key}`, - key: `${columnData.key}`, - render: (name, row, i) => ( - - {getFieldDecorator(`${columnData.key}${i}`, { - initialValue: columnData.others.initialDataIndex, - })( - , - )} - - ), - }; - columnArray.push(column); - } - }); - const columns = columnArray.concat(actionColumn); - return columns; - }; - - // generate payload by adding policy configurations - onHandleContinue = (e, formname) => { - const allFields = this.props.form.getFieldsValue(); - let activeFields = []; - let subContentsList = {}; - for (let i = 0; i < this.state.activePanelKeys.length; i++) { - Object.keys(allFields).map(key => { - if (key.includes(`${this.state.activePanelKeys[i]}-`)) { - if ( - subPanelpayloadAttributesforCheckboxes.hasOwnProperty( - `${this.state.activePanelKeys[i]}`, - ) - ) { - Object.entries( - subPanelpayloadAttributesforCheckboxes[ - this.state.activePanelKeys[i] - ], - ).map(([subPanel, subContent]) => { - subContentsList[subContent] = {}; - if ( - allFields[`${this.state.activePanelKeys[i]}-${subPanel}`] === - true - ) { - activeFields.push(key); - } else if (!key.includes(`-${subPanel}`)) { - activeFields.push(key); - } - }); - } else if ( - subPanelpayloadAttributesforSelect.hasOwnProperty( - `${this.state.activePanelKeys[i]}`, - ) - ) { - Object.entries( - subPanelpayloadAttributesforSelect[this.state.activePanelKeys[i]], - ).map(([subPanelSwitch, subPanels]) => { - if ( - subPanels.includes(allFields[subPanelSwitch]) && - key.includes(`${subPanelSwitch}-${allFields[subPanelSwitch]}-`) - ) { - activeFields.push(key); - } else { - for (let panel of subPanels) { - if (!key.includes(`${subPanelSwitch}-${panel}-`)) { - activeFields.push(key); - } - } - } - }); - } else { - activeFields.push(key); - } - } - }); - } - // validate fields and get profile features list - this.props.form.validateFields(activeFields, (err, values) => { - if (!err) { - let profileFeaturesList = []; - for (let i = 0; i < this.state.activePanelKeys.length; i++) { - let content = {}; - Object.entries(values).map(([key, value]) => { - if (key.includes(`${this.state.activePanelKeys[i]}-`)) { - if ( - subPanelpayloadAttributesforCheckboxes.hasOwnProperty( - `${this.state.activePanelKeys[i]}`, - ) - ) { - Object.entries( - subPanelpayloadAttributesforCheckboxes[ - this.state.activePanelKeys[i] - ], - ).map(([subPanel, contentKey]) => { - if (key.includes(`-${subPanel}-`)) { - subContentsList[contentKey][ - key.replace( - `${this.state.activePanelKeys[i]}-${subPanel}-`, - '', - ) - ] = value; - content = { ...content, ...subContentsList }; - } else { - content[ - key.replace(`${this.state.activePanelKeys[i]}-`, '') - ] = value; - } - }); - } - if (this.state.activePanelKeys[i] in formContainers) { - formContainers[this.state.activePanelKeys[i]].forEach( - subFeature => { - if ( - key.includes( - `${this.state.activePanelKeys[i]}-${subFeature}-`, - ) - ) { - let subFormContent = {}; - subFormContent[ - key.replace( - `${this.state.activePanelKeys[i]}-${subFeature}-`, - '', - ) - ] = value; - let feature = { - featureCode: subFeature, - deviceType: 'android', - content: subFormContent, - }; - profileFeaturesList.push(feature); - } - }, - ); - } - if ( - subPanelpayloadAttributesforSelect.hasOwnProperty( - `${this.state.activePanelKeys[i]}`, - ) - ) { - Object.keys( - subPanelpayloadAttributesforSelect[ - this.state.activePanelKeys[i] - ], - ).map(subPanelSwitch => { - if ( - key.includes(`${subPanelSwitch}-${values[subPanelSwitch]}-`) - ) { - content[ - key.replace( - `${subPanelSwitch}-${values[subPanelSwitch]}-`, - '', - ) - ] = value; - } else { - content[ - key.replace(`${this.state.activePanelKeys[i]}-`, '') - ] = value; - } - }); - } else { - content[ - key.replace(`${this.state.activePanelKeys[i]}-`, '') - ] = value; - } - } - }); - if (!(this.state.activePanelKeys[i] in formContainers)) { - let feature = { - featureCode: this.state.activePanelKeys[i], - deviceType: 'android', - content: content, - }; - profileFeaturesList.push(feature); - } - } - this.props.getPolicyPayloadData(formname, profileFeaturesList); - this.props.getNextStep(); - } - }); - }; - - // generate form items - getPanelItems = (panel, panelId) => { - const { getFieldDecorator } = this.props.form; - const subPanelListforCheckbox = {}; - const subPanelListforSelect = {}; - return panel.map((item, k) => { - switch (item.type) { - case 'select': - if (item.optional.hasOwnProperty('subPanel')) { - return ( -
- - {item.label}  - - - - - } - style={{ display: 'block' }} - > - {getFieldDecorator(`${item.id}`, { - initialValue: `${item.optional.option[0].name}`, - })( - , - )} - -
- {item.optional.subPanel.map((panel, i) => { - return ( -
- {this.getPanelItems(panel.panelItem)} -
- ); - })} -
-
- ); - } - return ( - - {item.label}  - - - - - } - style={{ display: 'block' }} - > - {getFieldDecorator(`${item.id}`, { - initialValue: `${item.optional.option[0].name}`, - })( - , - )} - - ); - case 'timeSelector': - return ( - - {item.label}  - - - - - } - style={{ display: 'block' }} - > - {getFieldDecorator(`${item.id}`, { - initialValue: item.optional.initialDataIndex, - })( - , - )} - - ); - case 'input': - return ( - - {item.label}  - - - - - } - style={{ display: 'block' }} - > - {getFieldDecorator(`${item.id}`, { - initialValue: null, - rules: [ - { - pattern: new RegExp(`${item.optional.rules.regex}`), - message: `${item.optional.rules.validationMsg}`, - }, - ], - })()} - - ); - case 'checkbox': - if (item.optional.hasOwnProperty('subPanel')) { - return ( -
- - - {getFieldDecorator(`${item.id}`, { - valuePropName: 'checked', - initialValue: item.optional.ischecked, - })( - - - {item.label}  - - - - - , - )} - - } - > -
-
- {item.optional.subPanel.map((panel, i) => { - subPanelListforCheckbox[panel.others.itemSwitch] = - panel.others.itemPayload; - if ( - subPanelpayloadAttributesforCheckboxes.hasOwnProperty( - panelId, - ) - ) { - Object.assign( - subPanelpayloadAttributesforCheckboxes[panelId], - subPanelListforCheckbox, - ); - } else { - subPanelpayloadAttributesforCheckboxes[ - panelId - ] = subPanelListforCheckbox; - } - return ( -
- {this.getPanelItems(panel.panelItem, panelId)} -
- ); - })} -
-
-
-
-
- ); - } - return ( - - {getFieldDecorator(`${item.id}`, { - valuePropName: 'checked', - initialValue: item.optional.ischecked, - })( - - - {item.label}  - - - - - , - )} - - ); - case 'textArea': - return ( - - {item.label}  - - - - - } - style={{ display: 'block' }} - > - {getFieldDecorator(`${item.id}`, { - initialValue: null, - })( -