Commit Graph

23 Commits

Author SHA1 Message Date
Thomas Lamprecht
58b7186065 node: repos: fix reversed validation on configured
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-01 10:49:25 +02:00
Fabian Ebner
d7aeb02f3e apt repos: use correct URL
so there is a 'result' property, which the window expects.

Suggested-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-07-01 10:46:22 +02:00
Thomas Lamprecht
824f997749 node: repos: fix add repo validator
isValid is a boolean not a callback, so won't really work and just
set the state once.

Use the `validator` and first call into the parents helper, then do
our logic and return a string  with an explanation in the expected
invalid case.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-07-01 10:43:12 +02:00
Thomas Lamprecht
f0966f2930 node: repos: fallback to "Other" for unknown origin
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-30 21:58:29 +02:00
Thomas Lamprecht
5a1fddb622 node: repos: use warning, not critical for suite-errors if disabled
As in that case it's actually safe, so rather show as warning, albeit
even info/notice like would probably be enough, but still, it is not
a configuration that is wanted permanently.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-30 21:47:57 +02:00
Thomas Lamprecht
205d2751f4 node: repos: fade text of disabled rows
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-30 21:47:20 +02:00
Thomas Lamprecht
5e9eb2456c node: repos: increase width of add-repo window + style cleanup
We have some longer descriptions so the default width looks crammed.

Also, avoid a intermediate variable which is only used once without
any change.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-30 21:46:12 +02:00
Dominik Csapak
7f671fee58 APTRepositories: remove unecessary selection model
this is the default anyway, no reason to explicitely create it

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2021-06-30 21:27:04 +02:00
Dominik Csapak
e71fc6e438 APTRepositories: make the Suites warnings inline errors
by iterating only once over the info array and adding them directly
to the records this way we can avoid iterating over the records
again

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2021-06-30 21:27:04 +02:00
Dominik Csapak
003c49829d APTRepositories: change updating button text/state to viewcontroller
we already have a viewmodel we can use, and so the handler does
not have to navigate the component tree up/down

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2021-06-30 21:27:04 +02:00
Dominik Csapak
82071150f7 APTRepositories: make panel scrollable
so that it is still usable with many errors and/or repositories

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2021-06-30 21:27:04 +02:00
Dominik Csapak
d8b5cd80c8 APTRepositories: change separation style between panels
having double borders does not look so nice, separate them with a bit
of padding

also change the warning panel to a simple header

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
2021-06-30 21:27:04 +02:00
Thomas Lamprecht
036f48c14d node: repos: render Origin logo for Debian & Proxmox
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-30 21:26:45 +02:00
Fabian Ebner
21860ea45c node: apt: spawn a window for adding repository
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-06-30 21:26:45 +02:00
Fabian Ebner
d91987a558 apt repositories: replace OfficialHost with Origin
to adapt to the new backend behavior.

Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-06-30 13:41:21 +02:00
Thomas Lamprecht
03c4c65bab apt repos: move Official to the right & use checkbox to render enabled
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-23 19:57:33 +02:00
Thomas Lamprecht
3fc020f417 apt repos: add product config-option and rework warning renderer
product defaults to PVE. It is added in the warnings and should be
set by any instance correctly.

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-23 19:42:14 +02:00
Thomas Lamprecht
0e79ce21c1 apt repos: make add-repo a checked command
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-23 19:40:54 +02:00
Thomas Lamprecht
994fe897b7 apt repos: style grouping headers a bit different
else the repo/header difference is not that big, and it gets a bit
hard to read as it feels a bit monotonic

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-23 19:39:48 +02:00
Thomas Lamprecht
bb64cd0341 apt repos: make enable/disable text selection dependent
the size hack is copied over from pve-manager's qemu/HardwareView

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-23 19:38:34 +02:00
Thomas Lamprecht
af48de6bf8 apt repos: code/format cleanups
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
2021-06-23 19:01:24 +02:00
Fabian Ebner
d76eedb46f add buttons for add/enable/disable
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-06-23 16:01:06 +02:00
Fabian Ebner
24313a9d80 add UI for APT repositories
Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
2021-06-23 16:01:06 +02:00