[AI Generated]: feat(*): 完善数据页切换成员、首页接口对接及我的页缓存信息展示
This commit is contained in:
@@ -63,7 +63,7 @@ const EMPTY_RECORD: WeightRecord = {
|
||||
}
|
||||
|
||||
/** 将体重数字拆成整数 + 小数字符串 */
|
||||
function splitWeight(weight: number): { int: number; decimal: string } {
|
||||
const splitWeight = (weight: number): { int: number; decimal: string } => {
|
||||
const str = weight.toFixed(2)
|
||||
const [intPart, decPart] = str.split('.')
|
||||
return { int: Number(intPart), decimal: `.${decPart}` }
|
||||
|
||||
Reference in New Issue
Block a user