[Kmymoney-devel] [Bug 311481] It is possible to create a schedule with empty name

allan agander93 at gmail.com
Wed Dec 12 22:42:32 UTC 2012


allan <agander93 at gmail.com> changed:

           What    |Removed                     |Added
                 CC|                            |agander93 at gmail.com

--- Comment #2 from allan <agander93 at gmail.com> ---
(In reply to comment #1)
> The problem is with the two methods to control the enabled state of the OK
> button in this case. One is the kMandatoryFieldGroup created in the
> KEditScheduleDlg ctor and the other the line
>   connect(editor, SIGNAL(transactionDataSufficient(bool)), buttonOk,
> SLOT(setEnabled(bool)));
> in KEditScheduleDlg::startEdit. To fix the issue, the results of both
> methods need to be ANDed, but I currently have no idea how to solve this.
> Any takers? Reviewboard is waiting for your suggestions.

While not fully understanding what is going on in this area, I notice that on
creating a new schedule, without touching any other widgets, selecting a payee
immediately enables the OK button.  As against that, I also notice that if an
account and category are selected, the OK button is not enabled until a
schedule name is entered.

As the payee is not a 'mandatory field', this seemed strange, so I removed the
connect(payee, SIGNAL(textChanged(QString)), this,
SLOT(slotUpdateButtonState())); on line 753 of transactioneditor.cpp.

This seems to achieve the required result.

Too simplistic?

You are receiving this mail because:
You are the assignee for the bug.

More information about the KMyMoney-devel mailing list