Sprint 9 (v1.2.0): Multiple profiles + bugfix indikator versi tray#10
Merged
Conversation
…tatif) Tray tak lagi mengandalkan flag active hasil parse listing (fnm list menandai * di setiap baris terpasang -> semua tampil aktif). Penanda ikut php_get_active/node_get_active, konsisten dgn frontend. devhardiyanto
…tif) Panggil refresh_version_submenus pasca php_switch/node_switch sukses, lewat window.app_handle(). Bullet aktif selalu sinkron apa pun pemicunya (tray atau UI), tak perlu restart app. devhardiyanto
Tambah Profile{id,name,serviceIds} + profiles/activeProfileId ke ConfigState.
selected_service_ids jadi proyeksi profil aktif (di-sinkron saat write) agar
tray & compose tak berubah. Migrasi backward-compat: config lama -> profil
Default berisi selection existing, version bump ke 2.
devhardiyanto
Perluas useConfig: interface Profile, profiles/activeProfileId, CRUD (create/rename/delete + guard min 1 profil & fallback), setActiveProfile. Selection selalu proyeksi profil aktif (syncSelection) agar konsisten dgn re-proyeksi backend. useServices.applyProfile set switch uiState + aktifkan. devhardiyanto
Dashboard: switcher profil (select) di header Services -> applyProfile. Settings tab Services: daftar profil + badge aktif + rename inline + hapus (guard min 1) + buat profil dari selection saat ini. Konsisten token dark. devhardiyanto
devhardiyanto
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Sprint 9 (v1.2.0): Multiple profiles per project (M9) + 2 bugfix indikator versi di tray (regresi M8).
Why
fnm listmenandai*di setiap baris; (2) ● tak pindah setelah switch versi sampai app restart.How
ConfigStatedapatprofiles: Vec<Profile>+activeProfileId.selectedServiceIdstetap ada sebagai proyeksi profil aktif (di-reproject saat write), jadi tray & compose generator tak berubah. Migrasi v1→v2: config lama → profil "Default" berisi selection existing.serviceIdsprofil aktif (bukan selection lepas), konsisten dengan re-proyeksi backend.php_get_active/node_get_active) — sama seperti frontend — dan di-rebuild setelahphp_switch/node_switchselesai.Changes
src-tauri/src/tray.rs— penanda aktif dari sumber otoritatif;refresh_version_submenusjadipub(crate).src-tauri/src/commands/{php,node}.rs— rebuild tray pasca-switch.src-tauri/src/commands/config.rs—Profile,profiles/activeProfileId,migrate()(v0→v1→v2), re-proyeksi saat write. +6 unit test.src/composables/useConfig.ts—Profile, CRUD profil (create/rename/delete + guard min 1 & fallback),syncSelection/applySelection,setActiveProfile.src/composables/useServices.ts—applyProfile(set switch uiState + aktifkan); toggle path ikut edit profil aktif.src/views/Dashboard.vue— switcher profil di header Services.src/views/Settings.vue— CRUD profil di tab Services.Testing
cargo test— 62 passed (termasuk 6 test migrasi/roundtrip/idempotent).vue-tsc --noEmitbersih,vite buildsukses.Catatan
applyProfilemengubah selection (desired state); tidak meng-start/stop container yang sedang running. Start/stop tetap manual via tombol. Bisa ditingkatkan bila diminta.devhardiyanto