You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: csp/gitprojectsettings.csp
+27-1Lines changed: 27 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -119,6 +119,7 @@ body {
119
119
}
120
120
121
121
if ('settings.settingsUIReadOnly) {
122
+
do ##class(SourceControl.Git.Utils).Locked($get(%request.Data("lockNamespace",1)))
122
123
for param="gitBinPath","namespaceTemp","privateKeyFile","pullEventClass","percentClassReplace", "defaultMergeBranch","environmentName","mappingsToken" {
123
124
set $Property(settings,param) = $Get(%request.Data(param,1))
124
125
}
@@ -215,7 +216,7 @@ body {
215
216
<strong>Success!</strong> Your changes have been saved.
<label for="mappingsToken" class="offset-sm-1 col-sm-3 col-form-label" data-toggle="tooltip" data-placement="top" title="(Optional) A namespace-specific string that may be included in mapping configurations as <token> to support multi-namespace repositories">Mappings Token</label>
520
533
<div class="col-sm-7">
@@ -806,6 +819,19 @@ function showOutput(target) {
806
819
}
807
820
}
808
821
822
+
function validateForm() {
823
+
var confirmText = "";
824
+
var lockNamespaceInitValue = #(''##class(SourceControl.Git.Utils).Locked())#;
825
+
var cbLockNamespace = document.getElementById("lockNamespace");
826
+
if (!cbLockNamespace) return true;
827
+
if (cbLockNamespace.checked && (lockNamespaceInitValue !== 1)) {
828
+
confirmText = "Are you sure? This will lock any source-controlled items from being edited in this namespace.";
829
+
} else if (!cbLockNamespace.checked && (lockNamespaceInitValue == 1)) {
830
+
confirmText = "Are you sure? This will allow edits of source-controlled items in this namespace.";
0 commit comments