1
1
mirror of https://github.com/Fabio286/antares.git synced 2025-06-05 21:59:22 +02:00

Datetime fields precision

This commit is contained in:
2020-07-05 16:06:56 +02:00
parent 262a476f50
commit 187b4f50f9
6 changed files with 53 additions and 19 deletions

View File

@ -39,6 +39,7 @@
:key="cKey"
:content="col"
:field="cKey"
:precision="fieldPrecision(cKey)"
:type="fieldType(cKey)"
@updateField="updateField($event, row[primaryField.name])"
/>
@ -105,6 +106,14 @@ export default {
return type;
},
fieldPrecision (cKey) {
let length = 0;
const field = this.fields.filter(field => field.name === cKey)[0];
if (field)
length = field.precision;
return length;
},
keyName (key) {
switch (key) {
case 'pri':