Bug 278379 - Save button is disabled when going from SQL view to Data and back to SQL
Summary: Save button is disabled when going from SQL view to Data and back to SQL
Status: CLOSED FIXED
Alias: None
Product: KEXI
Classification: Applications
Component: Queries (show other bugs)
Version: 2.4 alpha3 (Calligra 2.4 alpha3)
Platform: Compiled Sources Linux
: NOR normal
Target Milestone: 2.9.11
Assignee: Jarosław Staniek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-24 10:16 UTC by Dimitrios T Tanis
Modified: 2016-03-03 22:49 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 2.9.11
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dimitrios T Tanis 2011-07-24 10:16:46 UTC
Version:           2.4 alpha3 (Calligra 2.4 alpha3) (using KDE 4.6.0) 
OS:                Linux

As the summary above says.

Reproducible: Always

Steps to Reproduce:
Open Query designer > go to SQL view > write a select statement (DON'T save the query) > Go to data view > Go to SQL view again


Actual Results:  
Save button is disabled (although the * indicating unsaved changes is still there)
Typing any letter and deleting it will reenable the button.

Expected Results:  
Save button should be enabled dispite going to Data view and back since changes where not saved.

This issue is no big deal when firstly designing a query, as the user knows that it is not saved and can type some letter just to reenable the buttton. However if the user is editing an already existing query it can be confusing as he has contradicting indications (* and save disabled) whether the query is saved.
Comment 1 Dimitrios T Tanis 2011-07-24 10:19:41 UTC
Additional info:
If you go straight to SQL view and add the statement without doing anything on the design view, the * does not appear at all when switching back and forth (Data > SQL)
Comment 2 Jarosław Staniek 2016-01-30 00:11:00 UTC
Git commit e8262276d8888e9058b19e16a9f6d495a15d600e by Jaroslaw Staniek.
Committed on 29/01/2016 at 22:08.
Pushed by staniek into branch 'calligra/2.9'.

Kexi: Fix state of 'modification' flag while switching from SQL view to Query Data view and back

Summary:
A general change in the logic of the Query Designer is that now we remember the view mode that was in use while the modification to design happened, not just the fact that the modification happened previously (since the last saving changes).
Related: bug 358413

Also fixes this:
Changes in query design not retained after changes in SQL view and switching to Data view

FIXED-IN:2.9.11

Test Plan: Follow the scenarios of the both bugs for any simple query such as "SELECT * FROM T ORDER BY F".

Reviewers: piggz, wicik

Projects: #kexi, #calligra:_3.0

Differential Revision: https://phabricator.kde.org/D856

M  +16   -16   kexi/plugins/queries/kexiquerydesignerguieditor.cpp
M  +1    -1    kexi/plugins/queries/kexiquerydesignerguieditor.h
M  +24   -17   kexi/plugins/queries/kexiquerydesignersql.cpp
M  +1    -1    kexi/plugins/queries/kexiquerydesignersql.h
M  +7    -6    kexi/plugins/queries/kexiquerypart.cpp
M  +10   -7    kexi/plugins/queries/kexiquerypart.h

http://commits.kde.org/calligra/e8262276d8888e9058b19e16a9f6d495a15d600e
Comment 3 Jarosław Staniek 2016-02-29 23:34:58 UTC
Git commit bc54bad228e89548a929a30b5b1a54515e6a07d1 by Jaroslaw Staniek.
Committed on 29/02/2016 at 23:07.
Pushed by staniek into branch 'master'.

Fix state of 'modification' flag while switching from SQL view to Query Data view and back

Summary:
A general change in the logic of the Query Designer is that now we remember the view mode that was in use while the modification to design happened, not just the fact that the modification happened previously (since the last saving changes).
Related: bug 358413

Also fixes this:
Changes in query design not retained after changes in SQL view and switching to Data view

FIXED-IN:2.9.11

Test Plan: Follow the scenarios of the both bugs for any simple query such as "SELECT * FROM T ORDER BY F".

Reviewers: piggz, wicik

Projects: #kexi, #calligra:_3.0

Differential Revision: https://phabricator.kde.org/D856

ported from calligra.git e8262276d8888e9

M  +16   -16   src/plugins/queries/kexiquerydesignerguieditor.cpp
M  +19   -10   src/plugins/queries/kexiquerydesignersql.cpp
M  +1    -1    src/plugins/queries/kexiquerydesignersql.h
M  +7    -6    src/plugins/queries/kexiquerypart.cpp
M  +10   -7    src/plugins/queries/kexiquerypart.h

http://commits.kde.org/kexi/bc54bad228e89548a929a30b5b1a54515e6a07d1