@@ -132,6 +132,7 @@ export const tools = {
|
||||
select: 32,
|
||||
number: 64,
|
||||
typeinrec: 128,
|
||||
multiselect: 256,
|
||||
},
|
||||
|
||||
FieldTypeArr: [
|
||||
@@ -2526,6 +2527,35 @@ export const tools = {
|
||||
return mythis.$q.screen.width
|
||||
},
|
||||
|
||||
getwidthscale(mythis, mywidth, maxwidth) {
|
||||
if (this.isMobile()) {
|
||||
return mywidth
|
||||
} else {
|
||||
let myw = mywidth + ((this.getwidth(mythis) - mywidth - 300) * 0.4)
|
||||
if (myw > maxwidth)
|
||||
myw = maxwidth
|
||||
|
||||
return myw
|
||||
}
|
||||
},
|
||||
|
||||
getheightbywidth(mythis, mywidth, myheight, maxwidth) {
|
||||
const myw = this.getwidthscale(mythis, mywidth, maxwidth)
|
||||
return myw * (myheight / mywidth)
|
||||
},
|
||||
|
||||
getheightscale(mythis, myheight, maxheight) {
|
||||
if (this.isMobile()) {
|
||||
return myheight
|
||||
} else {
|
||||
let myh = myheight + ((this.getheight(mythis) - myheight) * 0.3)
|
||||
if (myh > maxheight)
|
||||
myh = maxheight
|
||||
|
||||
return myh
|
||||
}
|
||||
},
|
||||
|
||||
isIsoDate(str) {
|
||||
if (!/\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z/.test(str)) return false
|
||||
const d = new Date(str)
|
||||
|
||||
Reference in New Issue
Block a user