Bug 397112 - Add editor for online quotes
Summary: Add editor for online quotes
Status: RESOLVED FIXED
Alias: None
Product: libalkimia
Classification: Frameworks and Libraries
Component: General (show other bugs)
Version: master
Platform: Other All
: NOR wishlist
Target Milestone: ---
Assignee: KMyMoney Devel Mailing List
URL:
Keywords:
Depends on: 397957 397958
Blocks:
  Show dependency treegraph
 
Reported: 2018-08-03 00:24 UTC by Ralf Habacker
Modified: 2020-01-05 14:38 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 8.0.0


Attachments
Main window of online quote editor (152.65 KB, image/png)
2018-08-03 00:25 UTC, Ralf Habacker
Details
Web inspector for the displayed web page (168.97 KB, image/png)
2018-08-03 00:27 UTC, Ralf Habacker
Details
locale specific combobox (32.50 KB, image/png)
2018-08-03 00:35 UTC, Ralf Habacker
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ralf Habacker 2018-08-03 00:24:51 UTC
Alkimia is a library intended for common financial function, as mentioned at https://community.kde.org/Alkimia/Usecases 

Especially functions for querying financial status, which is mentioned at https://community.kde.org/Alkimia/Usecases#Finance_Status, would increase the usability of alkimia.

When finding errors in KMyMoney in relation with price updates, it turned out that the current implementation of online price update settings does not offer any possibility to check updated regular expressions directly.

For this use case it would be helpful to have an editor in alkimia to simplify this.

Appended is a screenshot of the implementation of this editor. On the left side the online quote can be selected, changed and checked and on the right side, the fetched web page is shown.
Comment 1 Ralf Habacker 2018-08-03 00:25:43 UTC
Created attachment 114278 [details]
Main window of online quote editor
Comment 2 Ralf Habacker 2018-08-03 00:27:42 UTC
Created attachment 114279 [details]
Web inspector for the displayed web page

In the context menu of the web page there is an entry to open the web inspector, which helps to identify required regular expressions.
Comment 3 Ralf Habacker 2018-08-03 00:35:13 UTC
Created attachment 114280 [details]
locale specific combobox

In case there are locale specific issues on web sites providing online quotes (as mentioned at bug 396797) there is a language combo box with which the web page could be displayed in several locales.
Comment 4 Ralf Habacker 2018-08-03 01:08:04 UTC
For online quotes, which are not fetchable by the normal KIO download support (see bug 396003 comment 1), webkit support can be activated by choosing the '.webkit' suffix in the quote name.

Please not that using this suffix is preliminary and will be replaced by a dedicated check box in the online quote editing area later.
Comment 5 Ralf Habacker 2018-08-11 03:51:55 UTC
See https://cgit.kde.org/alkimia.git/log/?h=work/397112-alkonlinequotes for the related working branch. 

It contains a copy of class WebPriceQuote and friends splitted into files for each class and migrated to the 'Alk' namespace e.g. AlkOnlineQuote. The online quote editor is located in the tools subdirectory an uses a widget named AlkOnlineQuoteWidget, imported from kmymoney an extended with a profile view, which is required to be able to edit online quotes for different applications (Online quotes in kmymoneyrc or GNHS files for skrooge)

The new classes has been (partially) refactored to be usable as public api (no inline code, private stuff moved into Private class) 

To see how the current api is usable in QML applications a qml plugin (see qml subdir) a related test app (see test subdir) has been added.
Comment 6 Ralf Habacker 2018-12-13 10:07:26 UTC
Online quote editor has been moved to master branch, is usable now and will be released with alkimia version 8.0.0.