From c720cc3a4ae43a8f951eec347fa8e640b62f4fe6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gina=20H=C3=A4u=C3=9Fge?= Date: Thu, 21 Jan 2016 10:58:00 +0100 Subject: [PATCH 1/2] Added note to not misuse (feature) requests for support questions --- CONTRIBUTING.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 68c09bcb..924bfa25 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -30,8 +30,12 @@ nothing but ticket management. - If you want to report a **bug**, [read "How to file a bug report" below](#how-to-file-a-bug-report) and *[use the provided template](#what-should-i-include-in-a-ticket)*. You do not need to do anything else with your ticket. -- If you want to post a **request** of any kind (feature request, documentation - request, ...), add `[Request]` to your issue's title (e.g. `[Request] Awesome new feature`). +- If you want to post a **feature request** or a **documentation request**, add `[Request]` + to your issue's title (e.g. `[Request] Awesome new feature`). A question on how to run/change/setup + something is **not** what qualifies as a request here, use the + [Mailinglist](https://groups.google.com/group/octoprint) or the + [Google+ Community](https://plus.google.com/communities/102771308349328485741) for + such support issues. - If you are a **developer** that wants to brainstorm a pull request or possible changes to the plugin system, add [Brainstorming] to your issue's title (e.g. `[Brainstorming] New plugin hook for doing some cool stuff`). From bcd7bb4d20e0ff48116d9f99c4f0fb5e691f3169 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gina=20H=C3=A4u=C3=9Fge?= Date: Mon, 25 Jan 2016 16:28:52 +0100 Subject: [PATCH 2/2] Don't enable Print button if no job is selected Fixes #1007 --- .../static/js/app/viewmodels/printerstate.js | 12 +++++++++++- src/octoprint/templates/sidebar/state.jinja2 | 6 +++--- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/src/octoprint/static/js/app/viewmodels/printerstate.js b/src/octoprint/static/js/app/viewmodels/printerstate.js index 00a7b67e..048578e1 100644 --- a/src/octoprint/static/js/app/viewmodels/printerstate.js +++ b/src/octoprint/static/js/app/viewmodels/printerstate.js @@ -14,6 +14,16 @@ $(function() { self.isLoading = ko.observable(undefined); self.isSdReady = ko.observable(undefined); + self.enablePrint = ko.computed(function() { + return self.isOperational() && self.isReady() && !self.isPrinting() && self.loginState.isUser() && self.filename() != undefined; + }); + self.enablePause = ko.computed(function() { + return self.isOperational() && (self.isPrinting() || self.isPaused()) && self.loginState.isUser(); + }); + self.enableCancel = ko.computed(function() { + return self.isOperational() && (self.isPrinting() || self.isPaused()) && self.loginState.isUser(); + }); + self.filename = ko.observable(undefined); self.progress = ko.observable(undefined); self.filesize = ko.observable(undefined); @@ -242,4 +252,4 @@ $(function() { ["loginStateViewModel"], ["#state_wrapper", "#drop_overlay"] ]); -}); \ No newline at end of file +}); diff --git a/src/octoprint/templates/sidebar/state.jinja2 b/src/octoprint/templates/sidebar/state.jinja2 index 7bcfdd25..972a2605 100644 --- a/src/octoprint/templates/sidebar/state.jinja2 +++ b/src/octoprint/templates/sidebar/state.jinja2 @@ -14,7 +14,7 @@