Update copy for file upload failure
This commit is contained in:
parent
8d7c4672b0
commit
3ecb2cf84f
@ -68,7 +68,6 @@ export default {
|
|||||||
const response = await this.uploader.upload(file, this.objectName)
|
const response = await this.uploader.upload(file, this.objectName)
|
||||||
if (response.ok) {
|
if (response.ok) {
|
||||||
this.attachment = e.target.value
|
this.attachment = e.target.value
|
||||||
this.showErrors = false
|
|
||||||
this.$refs.attachmentFilename.value = file.name
|
this.$refs.attachmentFilename.value = file.name
|
||||||
this.$refs.attachmentObjectName.value = this.objectName
|
this.$refs.attachmentObjectName.value = this.objectName
|
||||||
} else {
|
} else {
|
||||||
|
@ -44,10 +44,10 @@
|
|||||||
<input type="hidden" name="{{ field.object_name.name }}" id="{{ field.object_name.name }}" ref="attachmentObjectName">
|
<input type="hidden" name="{{ field.object_name.name }}" id="{{ field.object_name.name }}" ref="attachmentObjectName">
|
||||||
</div>
|
</div>
|
||||||
<template v-if="uploadError">
|
<template v-if="uploadError">
|
||||||
<span v-show="showErrors" class="usa-input__message">!{uploadError}</span>
|
<span class="usa-input__message">There was an error uploading your file. Please try again. If you encounter repeated problems uploading this file, please contact CCPO.</span>
|
||||||
</template>
|
</template>
|
||||||
{% for error, error_messages in field.errors.items() %}
|
{% for error, error_messages in field.errors.items() %}
|
||||||
<span v-show="showErrors" class="usa-input__message">{{error_messages[0]}}.</span>
|
<span class="usa-input__message">{{error_messages[0]}}</span>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user