Skip to content

Commit

Permalink
feat(north group): the topic param is modified to be required
Browse files Browse the repository at this point in the history
  • Loading branch information
orangegzx authored and ysfscream committed Jul 21, 2023
1 parent d9249b5 commit 465de41
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/composables/config/useSubscription.ts
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,8 @@ export const useAddSubscription = (props: AddSubscriptionProps) => {
const rules = computed(() => {
return {
driver: [{ required: true, message: t('config.southDeviceRequired') }],
group: [{ required: true, message: createCommonErrorMessage('select', ' group') }],
group: [{ required: true, message: createCommonErrorMessage('select', t('config.group')) }],
topic: [{ required: true, message: createCommonErrorMessage('input', t('config.topic')) }],
}
})
const subscriptionForm: Ref<SubscriptionDataForm> = ref(createRawSubscriptionForm())
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
</emqx-select>
</emqx-form-item>

<emqx-form-item v-if="isMQTTPugin(nodePlugin(currentNode))" :label="$t('config.topic')">
<emqx-form-item v-if="isMQTTPugin(nodePlugin(currentNode))" prop="topic" :label="$t('config.topic')">
<emqx-input v-model="subscriptionForm.topic" />
</emqx-form-item>
</emqx-form>
Expand Down

0 comments on commit 465de41

Please sign in to comment.