Closed BECATRUE closed 1 year ago
I wonder when the sum calculation is operated? Only setting a dataset, adding a calculation button, or polling whether datas are updated?
@kangz12345
I wonder when the sum calculation is operated? Only setting a dataset, adding a calculation button, or polling whether datas are updated?
For simplicity, let's add a calculation button.
Suggestion:
dbBoxes["A"]
.Suggestion:
- How about using a dict-like structure for the comboboxes? For example,
dbBoxes["A"]
.
It looks good!
For simplicity, can I assume that the selected database has a table named A
(or B
), and the table has only one column.
If not, we should add two QLineEdit
s for typing a table name and a column name.
@kangz12345
Adding line edits looks tiresome indeed.
Then, how about taking the table names as constructor arguments? Which implies that it should be given in "setup.json".
If you force the table names to "A" and "B", numgen
and poller
should use the table name "A" or "B", and it does not look intuitive.
Using "setup.json" looks good! I'll do it like this.
Feature you want to implement
'Data calculator (hereafter referred to as datacalc)' is an app for showing the sum of two values from selected databases.
Viewer frame
dbBoxes
: A dictionary containing two comboboxes for selecting the database from which the value ofA
andB
is fetchedcalculateButton
: A button for calculating the sum of recently fetched 'A' and 'B'numberLabel
: A label showing the sum, or an error message if something goes wrongHow the feature is implemented
Frame
andApp
will be implemented inapps.datacalc
.Additional context