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

Filter by Public IPs in node finder #2167

Merged
merged 1 commit into from
Feb 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions packages/playground/src/views/nodes.vue
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,28 @@
</VTextField>
</template>
</TfFilter>
<TfFilter
query-route="free-public-ips"
:rules="[
validators.isNumeric('This field accepts numbers only.', { no_symbols: true }),
validators.min('The node id should be larger then zero.', 1),
validators.startsWith('The node id start with zero.', '0'),
validators.validateResourceMaxNumber('This value is out of range.'),
]"
v-model="filters.publicIPs"
>
<template #input="{ props }">
<VTextField label="Free Public IPs" variant="outlined" v-model="filters.publicIPs" v-bind="props">
<template #append-inner>
<VTooltip text="Filter by free Public IPs">
<template #activator="{ props }">
<VIcon icon="mdi-information-outline" v-bind="props" />
</template>
</VTooltip>
</template>
</VTextField>
</template>
</TfFilter>

<TfFilter query-route="node-status" v-model="filters.status">
<v-select
Expand Down Expand Up @@ -349,6 +371,7 @@ export default {
status: "",
gateway: false,
gpu: false,
publicIPs: "",
});

const loading = ref<boolean>(true);
Expand Down Expand Up @@ -382,6 +405,7 @@ export default {
totalSru: convertToBytes(filters.value.minSSD),
hasGpu: filters.value.gpu || undefined,
domain: filters.value.gateway || undefined,
freeIps: +filters.value.publicIPs || undefined,
},
{ loadFarm: true },
);
Expand Down
Loading