summaryrefslogtreecommitdiffstats
path: root/extensions/BugModal/web
diff options
context:
space:
mode:
authorSebastin Santy <sebastinssanty@gmail.com>2017-07-28 22:34:41 +0200
committerDylan William Hardison <dylan@hardison.net>2017-07-28 22:34:41 +0200
commite74d21eaeb3bc4ba3a5521882815b6a6c6d45bcc (patch)
treed46e54a47afdbc205cef58697de51da67b2687ca /extensions/BugModal/web
parentdc378846874cca43be0a187d7c38d787395a6538 (diff)
downloadbugzilla-e74d21eaeb3bc4ba3a5521882815b6a6c6d45bcc.tar.gz
bugzilla-e74d21eaeb3bc4ba3a5521882815b6a6c6d45bcc.tar.xz
Bug 1383268 - Add attachments to new-bug
Diffstat (limited to 'extensions/BugModal/web')
-rw-r--r--extensions/BugModal/web/new_bug.css9
-rw-r--r--extensions/BugModal/web/new_bug.js16
2 files changed, 23 insertions, 2 deletions
diff --git a/extensions/BugModal/web/new_bug.css b/extensions/BugModal/web/new_bug.css
index a96083d81..8a161bb9a 100644
--- a/extensions/BugModal/web/new_bug.css
+++ b/extensions/BugModal/web/new_bug.css
@@ -10,6 +10,10 @@
padding: 8px;
}
+#reset {
+ padding: 1.5px 8px;
+}
+
.new-bug-container {
display: flex;
display: -webkit-flex;
@@ -41,6 +45,7 @@
flex: 6 1 30px;
margin:5px;
}
-input, label {
- display: block; !important
+
+.file-container {
+ padding: 8px;
}
diff --git a/extensions/BugModal/web/new_bug.js b/extensions/BugModal/web/new_bug.js
index 9da5abce9..32dbe4783 100644
--- a/extensions/BugModal/web/new_bug.js
+++ b/extensions/BugModal/web/new_bug.js
@@ -105,5 +105,21 @@ $(document).ready(function() {
this.form.submit()
}
});
+
+ $('#data').on("change", function () {
+ if (!$('#data').val()) {
+ return
+ } else {
+ document.getElementById('reset').style.display = "inline-block";
+ $("#description").prop('required',true);
+ }
+ });
+ $('#reset')
+ .click(function(event) {
+ event.preventDefault();
+ document.getElementById('data').value = "";
+ document.getElementById('reset').style.display = "none";
+ $("#description").prop('required',false);
+ });
});