mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange.git
synced 2026-08-19 04:14:04 +00:00
fixed the marking bug
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
<div class="form-group row">
|
||||
<label class="col-md-3 col-form-label text-md-right">{{ $t('Marking') }}</label>
|
||||
<div class="col-md-7">
|
||||
<input v-model="form.marking" :class="{ 'is-invalid': form.errors.has('marking') }" class="form-control" type="text" name="marking">
|
||||
<input style="text-transform: uppercase;" v-model="form.marking" :class="{ 'is-invalid': form.errors.has('marking') }" class="form-control" @input="forceUppercase($event, form, 'marking')" type="text" name="marking">
|
||||
<has-error :form="form" field="marking"/>
|
||||
</div>
|
||||
</div>
|
||||
@@ -108,6 +108,12 @@ export default {
|
||||
|
||||
|
||||
methods: {
|
||||
forceUppercase(e, o, prop) {
|
||||
const start = e.target.selectionStart;
|
||||
e.target.value = e.target.value.toUpperCase();
|
||||
this.$set(o, prop, e.target.value);
|
||||
e.target.setSelectionRange(start, start);
|
||||
},
|
||||
async register () {
|
||||
var token
|
||||
var data
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
<el-form ref="markingForm" :model="markingForm" :rules="rules">
|
||||
<div align="right">
|
||||
<el-form-item label="Marking" prop="marking">
|
||||
<el-input v-model="markingForm.marking" type="text" style="width: 80%" />
|
||||
<input style="width: 80%; text-transform: uppercase;" v-model="markingForm.marking" class="form-control" @input="forceUppercase($event, markingForm, 'marking')" type="text" />
|
||||
</el-form-item>
|
||||
<el-form-item label="Email" prop="email">
|
||||
<el-input v-model="markingForm.email" type="text" style="width: 80%" />
|
||||
@@ -109,6 +109,12 @@
|
||||
this.UpdateTableData();
|
||||
},
|
||||
methods: {
|
||||
forceUppercase(e, o, prop) {
|
||||
const start = e.target.selectionStart;
|
||||
e.target.value = e.target.value.toUpperCase();
|
||||
this.$set(o, prop, e.target.value);
|
||||
e.target.setSelectionRange(start, start);
|
||||
},
|
||||
CreateMarking : function(formName){
|
||||
this.loading_btn = true
|
||||
this.AddDatadialogVisible = false;
|
||||
|
||||
Reference in New Issue
Block a user