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

Added special UUID string field that resolves #11 #13

Closed
wants to merge 1 commit into from
Closed
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
9 changes: 9 additions & 0 deletions src/views/Entry.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@
<v-layout wrap>
<v-flex :class="field.size ? `xs${field.size}` : 'xs12 sm6 xl4'" v-for="field in group.fields" :key="field.name">

<!-- Special ID field to give a different disabled property and maybe show shortened form -->
<v-text-field :color="field.color ? field.color :'white'" v-if="field.type=='uuid_string'" v-model="item[field.name]" :label="field.displayName" :disabled="mostlyDisabled"></v-text-field>
Copy link
Owner

Choose a reason for hiding this comment

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

Why? the disabled property is already field specific. What does URL encoding it do?


<!-- String -->
<v-text-field :color="field.color ? field.color :'white'" v-if="field.type=='string'" v-model="item[field.name]" :label="field.displayName" :disabled="field.disabled"></v-text-field>

Expand Down Expand Up @@ -144,6 +147,12 @@ export default {
return
}
return this.config.dataDefinition
},
mostlyDisabled: function () {
if (!this.$route.params.id) {
Copy link
Owner

Choose a reason for hiding this comment

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

Why not just enable it? If you leave it blank it will generate one. If you specify it, that will be used. If there is a conflict, the working branch version #12 will display an error.

return false
}
return true
}
},
mounted () {
Expand Down