mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Add credentialSecret to clone pane
This commit is contained in:
parent
d6fc258485
commit
ec5d7c2e5c
@ -654,6 +654,7 @@ RED.projects = (function() {
|
||||
var projectSecretSelect;
|
||||
var copyProject;
|
||||
var projectRepoInput;
|
||||
var projectCloneSecret;
|
||||
var emptyProjectCredentialInput;
|
||||
var projectRepoUserInput;
|
||||
var projectRepoPasswordInput;
|
||||
@ -1019,10 +1020,12 @@ RED.projects = (function() {
|
||||
// -----------------------------------------------------
|
||||
|
||||
|
||||
// // Secret - clone
|
||||
// row = $('<div class="hide form-row projects-dialog-screen-create-row projects-dialog-screen-create-row-clone"></div>').appendTo(container);
|
||||
// $('<label>Credentials encryption key</label>').appendTo(row);
|
||||
// projectSecretInput = $('<input type="text"></input>').appendTo(row);
|
||||
// Secret - clone
|
||||
row = $('<div class="hide form-row projects-dialog-screen-create-row projects-dialog-screen-create-row-clone"></div>').appendTo(container);
|
||||
$('<label>Credentials encryption key</label>').appendTo(row);
|
||||
projectSecretInput = $('<input type="password"></input>').appendTo(row);
|
||||
|
||||
|
||||
switch(options.screen||"empty") {
|
||||
case "empty": createAsEmpty.click(); break;
|
||||
case "open": openProject.click(); break;
|
||||
@ -1080,7 +1083,7 @@ RED.projects = (function() {
|
||||
} else if (projectType === 'copy') {
|
||||
projectData.copy = copyProject.name;
|
||||
} else if (projectType === 'clone') {
|
||||
// projectData.credentialSecret = projectSecretInput.val();
|
||||
projectData.credentialSecret = projectSecretInput.val();
|
||||
var repoUrl = projectRepoInput.val();
|
||||
var metaData = {};
|
||||
if (/^(?:ssh|[\d\w\.\-_]+@[\w\.]+):(?:\/\/)?/.test(repoUrl)) {
|
||||
@ -1130,7 +1133,6 @@ RED.projects = (function() {
|
||||
projectRepoSSHKeySelect.removeClass("input-error");
|
||||
projectRepoPassphrase.removeClass("input-error");
|
||||
|
||||
|
||||
RED.deploy.setDeployInflight(true);
|
||||
RED.projects.settings.switchProject(projectData.name);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user