Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 'node_id' attribute to core modules #691

Merged
merged 6 commits into from
Aug 7, 2024
Merged

Add 'node_id' attribute to core modules #691

merged 6 commits into from
Aug 7, 2024

Conversation

stephdl
Copy link
Contributor

@stephdl stephdl commented Aug 5, 2024

This pull request adds the 'node_id' attribute to the core modules in the codebase. The 'node_id' attribute is used to identify the node where the module is installed. This change ensures that the 'node_id' is included in the core module list and is displayed in the software center UI.

NethServer/dev#6989

image
image
image
image

github-actions bot pushed a commit that referenced this pull request Aug 5, 2024
github-actions bot pushed a commit that referenced this pull request Aug 5, 2024
Copy link
Contributor

@andre8244 andre8244 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to add node label, if present? In NS8 UI, a node is usually named:

  • "My first node (Node 1)" if node label is present
  • "Node 1" if node label is not present

If this change makes sense, I also suggest to rename "Node ID" column to to "Node"

@stephdl
Copy link
Contributor Author

stephdl commented Aug 5, 2024

do you mean to display in the column instead of 1 rename to Node 1 @andre8244 ?

@andre8244
Copy link
Contributor

do you mean to display in the column instead of 1 rename to Node 1 @andre8244 ?

Yes, or display "My node (Node 1)" if the node has a label "My node" set

@andre8244
Copy link
Contributor

do you mean to display in the column instead of 1 rename to Node 1 @andre8244 ?

Yes, or display "My node (Node 1)" if the node has a label "My node" set

You can use getNodeLabel() function from ns8-ui-lib

@stephdl
Copy link
Contributor Author

stephdl commented Aug 5, 2024

I need to share with @DavidePrincipi, I am not sure it is in the scope, the goal is to sort by node ID, and any verbose label could break it
What do you think davidep

@andre8244
Copy link
Contributor

I need to share with @DavidePrincipi, I am not sure it is in the scope, the goal is to sort by node ID, and any verbose label could break it What do you think davidep

NsDataTable component supports custom sorting with customSortTable prop, you can find an example here: https://github.com/NethServer/ns8-mail/blob/main/ui/src/components/mailboxes/UserMailboxes.vue#L15

github-actions bot pushed a commit that referenced this pull request Aug 5, 2024
@DavidePrincipi
Copy link
Member

I need to share with @DavidePrincipi, I am not sure it is in the scope, the goal is to sort by node ID, and any verbose label could break it What do you think davidep

Not really. The important thing is to sort by the Node column, so that components on the same node are grouped together. An alphabetical sort should work too!

github-actions bot pushed a commit that referenced this pull request Aug 6, 2024
Copy link
Contributor

@andre8244 andre8244 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some minor fixes. Reminder: let's ensure UI code is formatted

core/ui/src/components/software-center/CoreAppModal.vue Outdated Show resolved Hide resolved
core/ui/src/components/software-center/CoreAppModal.vue Outdated Show resolved Hide resolved
@stephdl stephdl requested a review from andre8244 August 6, 2024 10:08
github-actions bot pushed a commit that referenced this pull request Aug 6, 2024
Copy link
Member

@DavidePrincipi DavidePrincipi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The library change LGTM

@stephdl stephdl merged commit 9e2d7a7 into feat-sci Aug 7, 2024
3 checks passed
@stephdl stephdl deleted the sdl-6989 branch August 7, 2024 14:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants