This commit is contained in:
anlicheng 2023-06-19 11:48:52 +08:00
parent 37248fc2e3
commit e5944eea95

View File

@ -302,7 +302,10 @@ handle_event(cast, {handle_message, #{<<"method">> := <<"inform">>, <<"params">>
#{<<"at">> := At, <<"services">> := ServiceInforms} ->
lists:foreach(fun(#{<<"props">> := Props, <<"name">> := Name, <<"version">> := Version, <<"version_copy">> := VersionCopy, <<"status">> := Status}) ->
%% props id:id:id
[_, SceneId, MicroId] = binary:split(Props, <<":">>, [global]),
[_, SceneId0, MicroId0] = binary:split(Props, <<":">>, [global]),
SceneId = binary_to_integer(SceneId0),
MicroId = binary_to_integer(MicroId0),
micro_inform_log:insert(#{
<<"host_id">> => HostId,
<<"scene_id">> => SceneId,