[Kimchi-devel] [PATCH V2] Bugfix: Multiple progress indicator during debug report generating

Hongliang Wang hlwang at linux.vnet.ibm.com
Thu Jun 12 08:24:32 UTC 2014


On 06/12/2014 04:22 PM, Wen Wang wrote:
> From: Wen Wang <wenwang at linux.vnet.ibm.com>
>
> V1 -> V2:
> Added "Signed-off-by" label
>
> Progress indicators appear in multiple grids including "Software
> Updates" and "Repositories" during debug report's generating. This patch
> removes all indicators but one that in "Debug Reports" grid.
>
> Signed-off-by: Wen Wang <wenwang at linux.vnet.ibm.com>
Reviewed-by: Hongliang Wang <hlwang at linux.vnet.ibm.com>
> ---
>   ui/js/src/kimchi.report_add_main.js |    9 ++++-----
>   1 files changed, 4 insertions(+), 5 deletions(-)
>
> diff --git a/ui/js/src/kimchi.report_add_main.js b/ui/js/src/kimchi.report_add_main.js
> index 45b7e57..ad2bb39 100644
> --- a/ui/js/src/kimchi.report_add_main.js
> +++ b/ui/js/src/kimchi.report_add_main.js
> @@ -15,7 +15,6 @@ kimchi.report_add_main = function() {
>           }
>           var formData = addReportForm.serializeObject();
>           kimchi.window.close();
> -        var reportGrid = null;
>           $('#' + reportGridID + '-generate-button').prop('disabled',true);
>           $('#' + reportGridID + '-remove-button').prop('disabled',true);
>           $('#' + reportGridID + '-download-button').prop('disabled',true);
> @@ -27,7 +26,7 @@ kimchi.report_add_main = function() {
>           });
>           var textboxValue = $('#report-name-textbox').val();
>           if (textboxValue != "") {
> -            $('.grid-body-view table', reportGrid).prepend(
> +            $('.grid-body-view table', '#' + reportGridID).prepend(
>                   '<tr>' +
>                       '<td>' +
>                           '<div class="cell-text-wrapper">' + textboxValue + '</div>' +
> @@ -39,7 +38,7 @@ kimchi.report_add_main = function() {
>               );
>           }
>           else {
> -            $('.grid-body-view table', reportGrid).prepend(
> +            $('.grid-body-view table', '#' + reportGridID).prepend(
>                   '<tr>' +
>                       '<td>' +
>                           '<div class="cell-text-wrapper">' + i18n['KCHDR6012M'] + '</div>' +
> @@ -51,7 +50,7 @@ kimchi.report_add_main = function() {
>               );
>           }
>           kimchi.createReport(formData, function(result) {
> -            $('.grid-body-view table tr:first-child', reportGrid).remove();
> +            $('.grid-body-view table tr:first-child', '#' + reportGridID).remove();
>               $('#' + reportGridID + '-generate-button').prop('disabled',false);
>               kimchi.topic('kimchi/debugReportAdded').publish({
>                   result: result
> @@ -66,7 +65,7 @@ kimchi.report_add_main = function() {
>                   var errText = result['responseJSON']['reason'];
>               }
>               result && kimchi.message.error(errText)
> -            $('.grid-body-view table tr:first-child', reportGrid).remove();
> +            $('.grid-body-view table tr:first-child', '#' + reportGridID).remove();
>           });
>
>           event.preventDefault();




More information about the Kimchi-devel mailing list