Skip to content

Commit

Permalink
117 task Merge status and disabled into one functionality (#122)
Browse files Browse the repository at this point in the history
* Update config.ng.functions.sh

* status to preview

* change preview > Preview

* fix typo

---------

Co-authored-by: Tearran <[email protected]>
  • Loading branch information
Tearran and Tearran authored Sep 30, 2024
1 parent f6ec2ca commit 3c3acab
Show file tree
Hide file tree
Showing 3 changed files with 72 additions and 73 deletions.
2 changes: 1 addition & 1 deletion lib/armbian-configng/config.ng.functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,7 @@ parse_menu_items() {
# If the condition field is empty or null, add the menu item to the menu
options+=("$id" " - $description ")
fi
done < <(echo "$json_data" | jq -r '.menu[] | '${parent_id:+".. | objects | select(.id==\"$parent_id\") | .sub[]? |"}' select(.disabled|not) | "\(.id)\n\(.description)\n\(.condition)"' || exit 1)
done < <(echo "$json_data" | jq -r '.menu[] | '${parent_id:+".. | objects | select(.id==\"$parent_id\") | .sub[]? |"}' select(.status != "disabled") | "\(.id)\n\(.description)\n\(.condition)"' || exit 1)
}

module_options+=(
Expand Down
Loading

0 comments on commit 3c3acab

Please sign in to comment.