存客宝 - 修复添加设备二维码有时会错误的问题
This commit is contained in:
@@ -134,13 +134,9 @@ export default function DeviceDetailPage() {
|
||||
} else if (serverData.taskConfig) {
|
||||
try {
|
||||
// 解析taskConfig字段
|
||||
let taskConfig = serverData.taskConfig
|
||||
if (typeof taskConfig === 'string') {
|
||||
taskConfig = JSON.parse(taskConfig)
|
||||
}
|
||||
const taskConfig = JSON.parse(serverData.taskConfig || '{}');
|
||||
|
||||
if (taskConfig) {
|
||||
console.log('解析的taskConfig:', taskConfig);
|
||||
formattedDevice.features = {
|
||||
autoAddFriend: Boolean(taskConfig.autoAddFriend),
|
||||
autoReply: Boolean(taskConfig.autoReply),
|
||||
|
||||
Reference in New Issue
Block a user