解决登录显示、首页显示bug
This commit is contained in:
21
utils/deliveryRoute.uts
Normal file
21
utils/deliveryRoute.uts
Normal file
@@ -0,0 +1,21 @@
|
||||
export function getDeliveryRouteParam(options: UTSJSONObject | null, key: string): string {
|
||||
if (options == null || key == '') {
|
||||
return ''
|
||||
}
|
||||
|
||||
try {
|
||||
const value = options.getString(key)
|
||||
if (value != null && value != '') {
|
||||
return value
|
||||
}
|
||||
} catch (e) {}
|
||||
|
||||
try {
|
||||
const rawValue = options[key]
|
||||
if (rawValue != null) {
|
||||
return '' + rawValue
|
||||
}
|
||||
} catch (e) {}
|
||||
|
||||
return ''
|
||||
}
|
||||
Reference in New Issue
Block a user