From 0d5b5288aa4e0d089b4eeda7904814c2d2c54e54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E5=89=8D=E6=98=8E?= <909355014@qq.com> Date: Mon, 12 Sep 2022 17:12:07 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=AA=E5=9B=BE=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/third/dahua.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/third/dahua.py b/apps/third/dahua.py index 137fe6ac..efbe86ef 100644 --- a/apps/third/dahua.py +++ b/apps/third/dahua.py @@ -149,7 +149,8 @@ class DhClient: d_code = code.split('$')[0] json_data['deviceCode'] = d_code json_data['params'] = '{\"method\":\"dev.snap\",\"id\":123,\"params\":{\"DevID\":\"' + \ - str(d_code) + '\",\"DevChannel\":0,\"PicNum\":1,\"SnapType\":1,\"CmdSrc\":0}}' + str(d_code) + '\",\"DevChannel\":\"' + \ + str(code) + '\",\"PicNum\":1,\"SnapType\":1,\"CmdSrc\":0}}' _, res = self.request(**dhapis['dev_snap'], json=json_data) res = json.loads(res) return self.get_full_pic(res['params']['PicInfo'])