Skip to content

Commit

Permalink
close #1453 Fixed: Style problem with date field after validation
Browse files Browse the repository at this point in the history
  • Loading branch information
cuneytsenturk committed Jun 5, 2020
1 parent c1fd4a3 commit 4d009e1
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 1 deletion.
4 changes: 4 additions & 0 deletions public/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -826,3 +826,7 @@ table .align-items-center td span.badge {
.navbar-vertical .navbar-nav .nav-link:not(.active) {
color: #fff !important;
}

.form-group.has-error .el-input__inner {
border-color: #ef3232 !important;
}
2 changes: 1 addition & 1 deletion resources/assets/js/components/AkauntingDate.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{'disabled': disabled},
formClasses
]"
:error="formError"
:footer-error="formError"
:prependIcon="icon"
:readonly="readonly"
:disabled="disabled"
Expand Down
9 changes: 9 additions & 0 deletions resources/assets/js/components/Inputs/BaseInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@
</div>
</slot>
</div>
<slot name="error">
<div v-if="footerError" class="invalid-feedback d-block"
v-html="footerError">
</div>
</slot>
</div>
</template>
<script>
Expand Down Expand Up @@ -84,6 +89,10 @@
type: String,
description: "Input error (below input)"
},
footerError: {
type: String,
description: "Input error (below input)"
},
successMessage: {
type: String,
description: "Input success message",
Expand Down
6 changes: 6 additions & 0 deletions resources/views/partials/form/date_group.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ class="{{ $col }}{{ isset($attributes['required']) ? ' required' : '' }}"
:form-classes="[{'has-error': form.errors.get('{{ $name }}') }]"
@endif

:group_class="'{{ $group_class }}'"

icon="fa fa-{{ $icon }}"
title="{{ $text }}"
placeholder="{{ trans('general.form.select.field', ['field' => $text]) }}"
Expand Down Expand Up @@ -47,6 +49,10 @@ class="{{ $col }}{{ isset($attributes['required']) ? ' required' : '' }}"
@interface="form.{{ $name }} = $event"
@endif

@if (isset($attributes['required']))
:required="{{ ($attributes['required']) ? 'true' : 'false' }}"
@endif

@if (isset($attributes['readonly']))
:readonly="{{ $attributes['readonly'] }}"
@endif
Expand Down

0 comments on commit 4d009e1

Please sign in to comment.