|
|
@ -49,8 +49,8 @@ class AppConfig { |
|
|
|
|
|
|
|
|
//根据产品名称获取产品配置 |
|
|
//根据产品名称获取产品配置 |
|
|
static DBProduct? getproduct(String name) { |
|
|
static DBProduct? getproduct(String name) { |
|
|
final foundProduct = |
|
|
final foundProduct = config.products |
|
|
config.products.firstWhere((product) => product.devicename == name); |
|
|
.firstWhere((product) => product.devicename.contains(name)); |
|
|
return foundProduct; |
|
|
return foundProduct; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|