Difference between revisions of "MediaWiki:PatientCalculators/common.js"
From WikiAnesthesia
Chris Rishel (talk | contribs) (Created page with "( function ( $, mw ) { mw.patientCalculators.addCalculationData( { age: { type: "number", defaultValue: "40", units: [...") |
Chris Rishel (talk | contribs) |
||
| (2 intermediate revisions by the same user not shown) | |||
| Line 3: | Line 3: | ||
age: { | age: { | ||
type: "number", | type: "number", | ||
default: { | |||
value: 40, | |||
units: "yr" | |||
}, | |||
units: [ | units: [ | ||
"yr", | "yr", | ||
| Line 9: | Line 12: | ||
"wk" | "wk" | ||
] | ] | ||
}, | }, | ||
gender: { | gender: { | ||
type: "string", | type: "string", | ||
default: "F", | |||
options: [ | options: [ | ||
"F", | "F", | ||
| Line 19: | Line 22: | ||
}, | }, | ||
height: { | height: { | ||
type: "number" | type: "number", | ||
default: { | |||
value: 175, | |||
units: "cm" | |||
}, | |||
units: [ | units: [ | ||
"cm", | "cm", | ||
| Line 26: | Line 32: | ||
"in", | "in", | ||
"ft" | "ft" | ||
] | ] | ||
}, | }, | ||
weight: { | weight: { | ||
type: "number", | type: "number", | ||
default: { | |||
value: 75, | |||
units: "kgwt" | |||
}, | |||
units: [ | units: [ | ||
"kgwt", | "kgwt", | ||
"lbwt", | "lbwt", | ||
"gwt" | "gwt" | ||
] | ] | ||
} | } | ||
} ); | } ); | ||
}( jQuery, mediaWiki ) ); | }( jQuery, mediaWiki ) ); | ||
Latest revision as of 14:19, 1 July 2021
( function ( $, mw ) {
mw.patientCalculators.addCalculationData( {
age: {
type: "number",
default: {
value: 40,
units: "yr"
},
units: [
"yr",
"mo",
"wk"
]
},
gender: {
type: "string",
default: "F",
options: [
"F",
"M"
]
},
height: {
type: "number",
default: {
value: 175,
units: "cm"
},
units: [
"cm",
"m",
"in",
"ft"
]
},
weight: {
type: "number",
default: {
value: 75,
units: "kgwt"
},
units: [
"kgwt",
"lbwt",
"gwt"
]
}
} );
}( jQuery, mediaWiki ) );