diff --git a/README.md b/README.md index d2f0fe7..f2416a3 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ https://corifeus.com/redis-ui --- -# 💿 The p3x-redis-ui-material web interface that connects to the p3x-redis-ui-server via http and socket.io v2024.4.174 +# 💿 The p3x-redis-ui-material web interface that connects to the p3x-redis-ui-server via http and socket.io v2024.4.175 @@ -77,7 +77,7 @@ All my domains ([patrikx3.com](https://patrikx3.com) and [corifeus.com](https:// --- -[**P3X-REDIS-UI-MATERIAL**](https://corifeus.com/redis-ui-material) Build v2024.4.174 +[**P3X-REDIS-UI-MATERIAL**](https://corifeus.com/redis-ui-material) Build v2024.4.175 [![NPM](https://img.shields.io/npm/v/p3x-redis-ui-material.svg)](https://www.npmjs.com/package/p3x-redis-ui-material) [![Donate for Corifeus / P3X](https://img.shields.io/badge/Donate-Corifeus-003087.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=QZVM4V6HVZJW6) [![Contact Corifeus / P3X](https://img.shields.io/badge/Contact-P3X-ff9900.svg)](https://www.patrikx3.com/en/front/contact) [![Like Corifeus @ Facebook](https://img.shields.io/badge/LIKE-Corifeus-3b5998.svg)](https://www.facebook.com/corifeus.software) diff --git a/package.json b/package.json index 5239c1d..eccefdb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "p3x-redis-ui-material", - "version": "2024.4.174", + "version": "2024.4.175", "description": "💿 The p3x-redis-ui-material web interface that connects to the p3x-redis-ui-server via http and socket.io", "corifeus": { "icon": "fas fa-database", diff --git a/src/angular/dialog/p3xr-dialog-connection.html b/src/angular/dialog/p3xr-dialog-connection.html index 8b98d5b..b6d59ce 100644 --- a/src/angular/dialog/p3xr-dialog-connection.html +++ b/src/angular/dialog/p3xr-dialog-connection.html @@ -13,6 +13,8 @@

{{ $root.p3xr.state.cfg.readonlyConnections ?
+ + {{ $root.p3xr.state.cfg.readonlyConnections ? - - - - - - - - - -
-
- {{ $root.p3xr.strings.form.error.port }} + + + {{ model.ssh ? $root.p3xr.strings.label.ssh.on : $root.p3xr.strings.label.ssh.off }} + + +
+ + + +
+
{{ $root.p3xr.strings.form.error.required }}
+
+
+ + + + +
+
{{ $root.p3xr.strings.form.error.required }}
+
+
+ + + + +
+
{{ $root.p3xr.strings.form.error.required }}
+
+
+ + + + + +
+ {{ $root.p3xr.strings.label.passwordSecure }} +
+ + + + + +
+ {{ $root.p3xr.strings.label.secureFeature }}
-
- - - - {{ $root.p3xr.strings.label.askAuth }} - +
+ + +
- +
- - + + - - - - + + + + + +
+
+ {{ $root.p3xr.strings.form.error.port }} +
+
-
- {{ $root.p3xr.strings.label.passwordSecure }} -
-
- + + {{ $root.p3xr.strings.label.askAuth }} + + + + + + + + + + + + + +
+ {{ $root.p3xr.strings.label.passwordSecure }} +
+
+
+
{{ $root.p3xr.state.cfg.readonlyConnections ?
- - - - -
- {{ $root.p3xr.strings.label.tlsSecure }} -
-
- - - - - -
- {{ $root.p3xr.strings.label.tlsSecure }} -
-
+
+ + + + +
+ {{ $root.p3xr.strings.label.tlsSecure }} +
+
+ + + + + +
+ {{ $root.p3xr.strings.label.tlsSecure }} +
+
+ + + + + +
+ {{ $root.p3xr.strings.label.tlsSecure }} +
- - - - -
- {{ $root.p3xr.strings.label.tlsSecure }} -
- -
+
+
diff --git a/src/angular/dialog/p3xr-dialog-connection.js b/src/angular/dialog/p3xr-dialog-connection.js index fce3834..52fb190 100644 --- a/src/angular/dialog/p3xr-dialog-connection.js +++ b/src/angular/dialog/p3xr-dialog-connection.js @@ -18,12 +18,14 @@ p3xr.ng.factory('p3xrDialogConnection', function (p3xrCommon, $mdDialog, p3xrSoc $scope.model.tlsCrt = options.model.id $scope.model.tlsKey = options.model.id $scope.model.tlsCa = options.model.id + $scope.model.sshPassword = options.model.id + $scope.model.sshPrivateKey = options.model.id } else { $scope.model = { name: undefined, host: undefined, - port: undefined, + port: 6379, askAuth: false, password: undefined, username: undefined, @@ -36,6 +38,16 @@ p3xr.ng.factory('p3xrDialogConnection', function (p3xrCommon, $mdDialog, p3xrSoc tlsCa: undefined, } } + if (!$scope.model.hasOwnProperty('ssh')) { + $scope.model = { ...$scope.model, + ssh: false, + sshHost: undefined, + sshPort: 22, + sshUsername: undefined, + sshPassword: options.model?.id, + sshPrivateKey: options.model?.id, + } + } if (!$scope.model.hasOwnProperty('cluster')) { $scope.model.cluster = false } @@ -51,14 +63,22 @@ p3xr.ng.factory('p3xrDialogConnection', function (p3xrCommon, $mdDialog, p3xrSoc node.password = node.id } + $scope.$watch('model.ssh', function (newValue, oldValue) { + if (newValue === true) { + $scope.model.sentinel = false + $scope.model.cluster = false + } + }) $scope.$watch('model.cluster', function (newValue, oldValue) { if (newValue === true) { $scope.model.sentinel = false + $scope.model.ssh = false } }) $scope.$watch('model.sentinel', function (newValue, oldValue) { if (newValue === true) { $scope.model.cluster = false + $scope.model.ssh = false } }) diff --git a/src/angular/pages/p3xr-settings.js b/src/angular/pages/p3xr-settings.js index 66ae5ae..aa815dc 100644 --- a/src/angular/pages/p3xr-settings.js +++ b/src/angular/pages/p3xr-settings.js @@ -3,7 +3,6 @@ p3xr.ng.component('p3xrSettings', { controller: function (p3xrCommon, p3xrDialogConnection, $mdDialog, p3xrSocket, p3xrDialogTreecontrolSettings, $scope) { this.connectionForm = (options) => { - p3xrDialogConnection.show(options) } diff --git a/src/strings/en/strings.js b/src/strings/en/strings.js index bef32ba..94f77af 100644 --- a/src/strings/en/strings.js +++ b/src/strings/en/strings.js @@ -128,6 +128,17 @@ const strings = { quickConsole: "Quick Console", }, label: { + secureFeature: 'If you see a value that starts with a P3X an look like the same, it is a secure feature. To change the settings, just replace these settings with empty or something else and they will be saved. If you do not change the settings, the settings will be kept as they are on the server.', + ssh: { + on: 'SSH on', + off: 'SSH off', + sshHost: 'SSH Host', + sshPort: 'SSH port', + sshUsername: 'SSH username', + sshPassword: 'SSH password', + sshPrivateKey: 'SSH private key', + + }, isBuffer: "[object ArrayBuffer] means that the value is binary data or the value is bigger than 0.5MB", streamValue: `Stream field and value is a oneliner. Eg.: field1 value1 "field 2" "value 2"`, streamTimestampId: `'*' means auto generated or the specification as -`, diff --git a/src/strings/ru/strings.js b/src/strings/ru/strings.js index fea5c3f..0f34610 100644 --- a/src/strings/ru/strings.js +++ b/src/strings/ru/strings.js @@ -131,6 +131,16 @@ const strings = { quickConsole: "Быстрый", }, label: { + secureFeature: 'Если вы видите значение, которое начинается с P3X и выглядит похоже, это функция безопасности. Чтобы изменить настройки, просто замените эти настройки на пустые или что-то другое, и они будут сохранены. Если вы не измените настройки, настройки останутся такими, какие они есть на сервере.', + ssh: { + on: 'SSH включен', + off: 'SSH выключен', + sshHost: 'Хост SSH', + sshPort: 'Порт SSH', + sshUsername: 'Имя пользователя SSH', + sshPassword: 'Пароль SSH', + sshPrivateKey: 'Приватный ключ SSH', + }, isBuffer: "[object ArrayBuffer] означает, что значение представляет собой двоичный буфер или значение превышает 0.5 МБ.", streamValue: `Поле и значение потока это однополосник. Например: поле1 значение1 "поле 2" "значение 2"`, streamTimestampId: `'*' означает автогенерацию или определяется как -`, diff --git a/src/strings/zn/strings.js b/src/strings/zn/strings.js index a5e58f9..810c6a1 100644 --- a/src/strings/zn/strings.js +++ b/src/strings/zn/strings.js @@ -121,6 +121,16 @@ const strings = { quickConsole: "快的", }, label: { + secureFeature: '如果您看到以 P3X 开头的值并且看起来相似,则这是一项安全功能。 要更改设置,只需将这些设置替换为空或其他内容即可保存它们。 如果您不更改设置,这些设置将保留在服务器上的原样。', + ssh: { + on: 'SSH 开启', + off: 'SSH 关闭', + sshHost: 'SSH 主机', + sshPort: 'SSH端口', + sshUsername: 'SSH 用户名', + sshPassword: 'SSH密码', + sshPrivateKey: 'SSH 私钥', + }, isBuffer: "[object ArrayBuffer] 表示該值是二進位緩衝區或該值大於 0.5MB", streamValue: `流字段和值是唯一的。 例如:field1 value1 "field 2" "value 2"`, streamTimestampId: `'*'表示自动生成或指定为-`,