Commit 4005962c5ba25d1c34e4513d9b9ad27722de97a8
Committed by
GitHub
Merge pull request #30 from lawrencehj/master
与2.0同步修正部分错误
Showing
10 changed files
with
49 additions
and
60 deletions
pom.xml
| @@ -131,7 +131,7 @@ | @@ -131,7 +131,7 @@ | ||
| 131 | <artifactId>jain-sip-ri</artifactId> | 131 | <artifactId>jain-sip-ri</artifactId> |
| 132 | <version>1.3.0-92</version> | 132 | <version>1.3.0-92</version> |
| 133 | <scope>system</scope> | 133 | <scope>system</scope> |
| 134 | - <systemPath>${project.basedir}/libs/jain-sip-ri-1.3.0-92.jar</systemPath> | 134 | + <systemPath>${pom.basedir}/libs/jain-sip-ri-1.3.0-92.jar</systemPath> |
| 135 | </dependency> | 135 | </dependency> |
| 136 | <dependency> | 136 | <dependency> |
| 137 | <groupId>log4j</groupId> | 137 | <groupId>log4j</groupId> |
| @@ -141,7 +141,7 @@ | @@ -141,7 +141,7 @@ | ||
| 141 | 141 | ||
| 142 | <!-- xml解析库 --> | 142 | <!-- xml解析库 --> |
| 143 | <dependency> | 143 | <dependency> |
| 144 | - <groupId>org.dom4j</groupId> | 144 | + <groupId>org.dom4j</groupId> |
| 145 | <artifactId>dom4j</artifactId> | 145 | <artifactId>dom4j</artifactId> |
| 146 | <version>2.1.3</version> | 146 | <version>2.1.3</version> |
| 147 | </dependency> | 147 | </dependency> |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/cmd/impl/SIPCommander.java
| @@ -77,6 +77,9 @@ public class SIPCommander implements ISIPCommander { | @@ -77,6 +77,9 @@ public class SIPCommander implements ISIPCommander { | ||
| 77 | @Value("${media.seniorSdp}") | 77 | @Value("${media.seniorSdp}") |
| 78 | private boolean seniorSdp; | 78 | private boolean seniorSdp; |
| 79 | 79 | ||
| 80 | + @Value("${media.autoApplyPlay}") | ||
| 81 | + private boolean autoApplyPlay; | ||
| 82 | + | ||
| 80 | @Autowired | 83 | @Autowired |
| 81 | private ZLMHttpHookSubscribe subscribe; | 84 | private ZLMHttpHookSubscribe subscribe; |
| 82 | 85 | ||
| @@ -182,11 +185,11 @@ public class SIPCommander implements ISIPCommander { | @@ -182,11 +185,11 @@ public class SIPCommander implements ISIPCommander { | ||
| 182 | /** | 185 | /** |
| 183 | * 云台指令码计算 | 186 | * 云台指令码计算 |
| 184 | * | 187 | * |
| 185 | - * @param cmdCode 指令码 | ||
| 186 | - * @param parameter1 数据1 | ||
| 187 | - * @param parameter2 数据2 | ||
| 188 | - * @param combineCode2 组合码2 | ||
| 189 | - */ | 188 | + * @param cmdCode 指令码 |
| 189 | + * @param parameter1 数据1 | ||
| 190 | + * @param parameter2 数据2 | ||
| 191 | + * @param combineCode2 组合码2 | ||
| 192 | + */ | ||
| 190 | public static String frontEndCmdString(int cmdCode, int parameter1, int parameter2, int combineCode2) { | 193 | public static String frontEndCmdString(int cmdCode, int parameter1, int parameter2, int combineCode2) { |
| 191 | StringBuilder builder = new StringBuilder("A50F01"); | 194 | StringBuilder builder = new StringBuilder("A50F01"); |
| 192 | String strTmp; | 195 | String strTmp; |
| @@ -208,13 +211,13 @@ public class SIPCommander implements ISIPCommander { | @@ -208,13 +211,13 @@ public class SIPCommander implements ISIPCommander { | ||
| 208 | /** | 211 | /** |
| 209 | * 云台控制,支持方向与缩放控制 | 212 | * 云台控制,支持方向与缩放控制 |
| 210 | * | 213 | * |
| 211 | - * @param device 控制设备 | ||
| 212 | - * @param channelId 预览通道 | ||
| 213 | - * @param leftRight 镜头左移右移 0:停止 1:左移 2:右移 | ||
| 214 | - * @param upDown 镜头上移下移 0:停止 1:上移 2:下移 | ||
| 215 | - * @param inOut 镜头放大缩小 0:停止 1:缩小 2:放大 | ||
| 216 | - * @param moveSpeed 镜头移动速度 | ||
| 217 | - * @param zoomSpeed 镜头缩放速度 | 214 | + * @param device 控制设备 |
| 215 | + * @param channelId 预览通道 | ||
| 216 | + * @param leftRight 镜头左移右移 0:停止 1:左移 2:右移 | ||
| 217 | + * @param upDown 镜头上移下移 0:停止 1:上移 2:下移 | ||
| 218 | + * @param inOut 镜头放大缩小 0:停止 1:缩小 2:放大 | ||
| 219 | + * @param moveSpeed 镜头移动速度 | ||
| 220 | + * @param zoomSpeed 镜头缩放速度 | ||
| 218 | */ | 221 | */ |
| 219 | @Override | 222 | @Override |
| 220 | public boolean ptzCmd(Device device, String channelId, int leftRight, int upDown, int inOut, int moveSpeed, | 223 | public boolean ptzCmd(Device device, String channelId, int leftRight, int upDown, int inOut, int moveSpeed, |
| @@ -287,8 +290,12 @@ public class SIPCommander implements ISIPCommander { | @@ -287,8 +290,12 @@ public class SIPCommander implements ISIPCommander { | ||
| 287 | @Override | 290 | @Override |
| 288 | public void playStreamCmd(Device device, String channelId, ZLMHttpHookSubscribe.Event event, SipSubscribe.Event errorEvent) { | 291 | public void playStreamCmd(Device device, String channelId, ZLMHttpHookSubscribe.Event event, SipSubscribe.Event errorEvent) { |
| 289 | try { | 292 | try { |
| 290 | - | ||
| 291 | - String ssrc = streamSession.createPlaySsrc(); | 293 | + String ssrc = ""; |
| 294 | + if (rtpEnable) { | ||
| 295 | + ssrc = String.format("gb_play_%s_%s", device.getDeviceId(), channelId); | ||
| 296 | + }else { | ||
| 297 | + ssrc = streamSession.createPlaySsrc(); | ||
| 298 | + } | ||
| 292 | String streamId = null; | 299 | String streamId = null; |
| 293 | if (rtpEnable) { | 300 | if (rtpEnable) { |
| 294 | streamId = String.format("gb_play_%s_%s", device.getDeviceId(), channelId); | 301 | streamId = String.format("gb_play_%s_%s", device.getDeviceId(), channelId); |
| @@ -326,13 +333,14 @@ public class SIPCommander implements ISIPCommander { | @@ -326,13 +333,14 @@ public class SIPCommander implements ISIPCommander { | ||
| 326 | 333 | ||
| 327 | if (seniorSdp) { | 334 | if (seniorSdp) { |
| 328 | if("TCP-PASSIVE".equals(streamMode)) { | 335 | if("TCP-PASSIVE".equals(streamMode)) { |
| 329 | - content.append("m=video "+ mediaPort +" TCP/RTP/AVP 126 125 99 34 98 97 96\r\n"); | 336 | + content.append("m=video "+ mediaPort +" TCP/RTP/AVP 96 126 125 99 34 98 97\r\n"); |
| 330 | }else if ("TCP-ACTIVE".equals(streamMode)) { | 337 | }else if ("TCP-ACTIVE".equals(streamMode)) { |
| 331 | - content.append("m=video "+ mediaPort +" TCP/RTP/AVP 126 125 99 34 98 97 96\r\n"); | 338 | + content.append("m=video "+ mediaPort +" TCP/RTP/AVP 96 126 125 99 34 98 97\r\n"); |
| 332 | }else if("UDP".equals(streamMode)) { | 339 | }else if("UDP".equals(streamMode)) { |
| 333 | - content.append("m=video "+ mediaPort +" RTP/AVP 126 125 99 34 98 97 96\r\n"); | 340 | + content.append("m=video "+ mediaPort +" RTP/AVP 96 126 125 99 34 98 97\r\n"); |
| 334 | } | 341 | } |
| 335 | content.append("a=recvonly\r\n"); | 342 | content.append("a=recvonly\r\n"); |
| 343 | + content.append("a=rtpmap:96 PS/90000\r\n"); | ||
| 336 | content.append("a=fmtp:126 profile-level-id=42e01e\r\n"); | 344 | content.append("a=fmtp:126 profile-level-id=42e01e\r\n"); |
| 337 | content.append("a=rtpmap:126 H264/90000\r\n"); | 345 | content.append("a=rtpmap:126 H264/90000\r\n"); |
| 338 | content.append("a=rtpmap:125 H264S/90000\r\n"); | 346 | content.append("a=rtpmap:125 H264S/90000\r\n"); |
| @@ -341,7 +349,6 @@ public class SIPCommander implements ISIPCommander { | @@ -341,7 +349,6 @@ public class SIPCommander implements ISIPCommander { | ||
| 341 | content.append("a=fmtp:99 profile-level-id=3\r\n"); | 349 | content.append("a=fmtp:99 profile-level-id=3\r\n"); |
| 342 | content.append("a=rtpmap:98 H264/90000\r\n"); | 350 | content.append("a=rtpmap:98 H264/90000\r\n"); |
| 343 | content.append("a=rtpmap:97 MPEG4/90000\r\n"); | 351 | content.append("a=rtpmap:97 MPEG4/90000\r\n"); |
| 344 | - content.append("a=rtpmap:96 PS/90000\r\n"); | ||
| 345 | if("TCP-PASSIVE".equals(streamMode)){ // tcp被动模式 | 352 | if("TCP-PASSIVE".equals(streamMode)){ // tcp被动模式 |
| 346 | content.append("a=setup:passive\r\n"); | 353 | content.append("a=setup:passive\r\n"); |
| 347 | content.append("a=connection:new\r\n"); | 354 | content.append("a=connection:new\r\n"); |
| @@ -380,9 +387,6 @@ public class SIPCommander implements ISIPCommander { | @@ -380,9 +387,6 @@ public class SIPCommander implements ISIPCommander { | ||
| 380 | 387 | ||
| 381 | content.append("y="+ssrc+"\r\n");//ssrc | 388 | content.append("y="+ssrc+"\r\n");//ssrc |
| 382 | 389 | ||
| 383 | -// String fromTag = UUID.randomUUID().toString(); | ||
| 384 | -// Request request = headerProvider.createInviteRequest(device, channelId, content.toString(), null, fromTag, null, ssrc); | ||
| 385 | - | ||
| 386 | Request request = headerProvider.createInviteRequest(device, channelId, content.toString(), null, "live", null, ssrc); | 390 | Request request = headerProvider.createInviteRequest(device, channelId, content.toString(), null, "live", null, ssrc); |
| 387 | 391 | ||
| 388 | ClientTransaction transaction = transmitRequest(device, request, errorEvent); | 392 | ClientTransaction transaction = transmitRequest(device, request, errorEvent); |
| @@ -408,8 +412,16 @@ public class SIPCommander implements ISIPCommander { | @@ -408,8 +412,16 @@ public class SIPCommander implements ISIPCommander { | ||
| 408 | , SipSubscribe.Event errorEvent) { | 412 | , SipSubscribe.Event errorEvent) { |
| 409 | try { | 413 | try { |
| 410 | MediaServerConfig mediaInfo = redisCatchStorage.getMediaInfo(); | 414 | MediaServerConfig mediaInfo = redisCatchStorage.getMediaInfo(); |
| 411 | - String ssrc = streamSession.createPlayBackSsrc(); | ||
| 412 | - String streamId = String.format("%08x", Integer.parseInt(ssrc)).toUpperCase(); | 415 | + String ssrc = null; |
| 416 | + String streamId = null; | ||
| 417 | + if (rtpEnable) { | ||
| 418 | + ssrc = String.format("gb_playback_%s_%s", device.getDeviceId(), channelId); | ||
| 419 | + streamId = ssrc; | ||
| 420 | + }else { | ||
| 421 | + ssrc = streamSession.createPlayBackSsrc(); | ||
| 422 | + streamId = String.format("%08x", Integer.parseInt(ssrc)).toUpperCase(); | ||
| 423 | + } | ||
| 424 | + | ||
| 413 | // 添加订阅 | 425 | // 添加订阅 |
| 414 | JSONObject subscribeKey = new JSONObject(); | 426 | JSONObject subscribeKey = new JSONObject(); |
| 415 | subscribeKey.put("app", "rtp"); | 427 | subscribeKey.put("app", "rtp"); |
| @@ -417,7 +429,6 @@ public class SIPCommander implements ISIPCommander { | @@ -417,7 +429,6 @@ public class SIPCommander implements ISIPCommander { | ||
| 417 | 429 | ||
| 418 | subscribe.addSubscribe(ZLMHttpHookSubscribe.HookType.on_publish, subscribeKey, event); | 430 | subscribe.addSubscribe(ZLMHttpHookSubscribe.HookType.on_publish, subscribeKey, event); |
| 419 | 431 | ||
| 420 | - // | ||
| 421 | StringBuffer content = new StringBuffer(200); | 432 | StringBuffer content = new StringBuffer(200); |
| 422 | content.append("v=0\r\n"); | 433 | content.append("v=0\r\n"); |
| 423 | content.append("o="+sipConfig.getSipId()+" 0 0 IN IP4 "+sipConfig.getSipIp()+"\r\n"); | 434 | content.append("o="+sipConfig.getSipId()+" 0 0 IN IP4 "+sipConfig.getSipIp()+"\r\n"); |
| @@ -437,13 +448,14 @@ public class SIPCommander implements ISIPCommander { | @@ -437,13 +448,14 @@ public class SIPCommander implements ISIPCommander { | ||
| 437 | 448 | ||
| 438 | if (seniorSdp) { | 449 | if (seniorSdp) { |
| 439 | if("TCP-PASSIVE".equals(streamMode)) { | 450 | if("TCP-PASSIVE".equals(streamMode)) { |
| 440 | - content.append("m=video "+ mediaPort +" TCP/RTP/AVP 126 125 99 34 98 97 96\r\n"); | 451 | + content.append("m=video "+ mediaPort +" TCP/RTP/AVP 96 126 125 99 34 98 97\r\n"); |
| 441 | }else if ("TCP-ACTIVE".equals(streamMode)) { | 452 | }else if ("TCP-ACTIVE".equals(streamMode)) { |
| 442 | - content.append("m=video "+ mediaPort +" TCP/RTP/AVP 126 125 99 34 98 97 96\r\n"); | 453 | + content.append("m=video "+ mediaPort +" TCP/RTP/AVP 96 126 125 99 34 98 97\r\n"); |
| 443 | }else if("UDP".equals(streamMode)) { | 454 | }else if("UDP".equals(streamMode)) { |
| 444 | - content.append("m=video "+ mediaPort +" RTP/AVP 126 125 99 34 98 97 96\r\n"); | 455 | + content.append("m=video "+ mediaPort +" RTP/AVP 96 126 125 99 34 98 97\r\n"); |
| 445 | } | 456 | } |
| 446 | content.append("a=recvonly\r\n"); | 457 | content.append("a=recvonly\r\n"); |
| 458 | + content.append("a=rtpmap:96 PS/90000\r\n"); | ||
| 447 | content.append("a=fmtp:126 profile-level-id=42e01e\r\n"); | 459 | content.append("a=fmtp:126 profile-level-id=42e01e\r\n"); |
| 448 | content.append("a=rtpmap:126 H264/90000\r\n"); | 460 | content.append("a=rtpmap:126 H264/90000\r\n"); |
| 449 | content.append("a=rtpmap:125 H264S/90000\r\n"); | 461 | content.append("a=rtpmap:125 H264S/90000\r\n"); |
| @@ -452,7 +464,6 @@ public class SIPCommander implements ISIPCommander { | @@ -452,7 +464,6 @@ public class SIPCommander implements ISIPCommander { | ||
| 452 | content.append("a=fmtp:99 profile-level-id=3\r\n"); | 464 | content.append("a=fmtp:99 profile-level-id=3\r\n"); |
| 453 | content.append("a=rtpmap:98 H264/90000\r\n"); | 465 | content.append("a=rtpmap:98 H264/90000\r\n"); |
| 454 | content.append("a=rtpmap:97 MPEG4/90000\r\n"); | 466 | content.append("a=rtpmap:97 MPEG4/90000\r\n"); |
| 455 | - content.append("a=rtpmap:96 PS/90000\r\n"); | ||
| 456 | if("TCP-PASSIVE".equals(streamMode)){ // tcp被动模式 | 467 | if("TCP-PASSIVE".equals(streamMode)){ // tcp被动模式 |
| 457 | content.append("a=setup:passive\r\n"); | 468 | content.append("a=setup:passive\r\n"); |
| 458 | content.append("a=connection:new\r\n"); | 469 | content.append("a=connection:new\r\n"); |
| @@ -521,9 +532,6 @@ public class SIPCommander implements ISIPCommander { | @@ -521,9 +532,6 @@ public class SIPCommander implements ISIPCommander { | ||
| 521 | if (dialog == null) { | 532 | if (dialog == null) { |
| 522 | return; | 533 | return; |
| 523 | } | 534 | } |
| 524 | - | ||
| 525 | - | ||
| 526 | - | ||
| 527 | Request byeRequest = dialog.createRequest(Request.BYE); | 535 | Request byeRequest = dialog.createRequest(Request.BYE); |
| 528 | SipURI byeURI = (SipURI) byeRequest.getRequestURI(); | 536 | SipURI byeURI = (SipURI) byeRequest.getRequestURI(); |
| 529 | String vh = transaction.getRequest().getHeader(ViaHeader.NAME).toString(); | 537 | String vh = transaction.getRequest().getHeader(ViaHeader.NAME).toString(); |
src/main/java/com/genersoft/iot/vmp/gb28181/transmit/request/impl/MessageRequestProcessor.java
| @@ -297,7 +297,7 @@ public class MessageRequestProcessor extends SIPRequestAbstractProcessor { | @@ -297,7 +297,7 @@ public class MessageRequestProcessor extends SIPRequestAbstractProcessor { | ||
| 297 | device.setStreamMode("UDP"); | 297 | device.setStreamMode("UDP"); |
| 298 | } | 298 | } |
| 299 | storager.updateDevice(device); | 299 | storager.updateDevice(device); |
| 300 | - cmder.catalogQuery(device, null); | 300 | + //cmder.catalogQuery(device, null); |
| 301 | // 回复200 OK | 301 | // 回复200 OK |
| 302 | responseAck(evt); | 302 | responseAck(evt); |
| 303 | if (offLineDetector.isOnline(deviceId)) { | 303 | if (offLineDetector.isOnline(deviceId)) { |
src/main/java/com/genersoft/iot/vmp/storager/dao/DeviceChannelMapper.java
| @@ -19,15 +19,6 @@ public interface DeviceChannelMapper { | @@ -19,15 +19,6 @@ public interface DeviceChannelMapper { | ||
| 19 | "'${ipAddress}', ${port}, '${password}', ${PTZType}, ${status})") | 19 | "'${ipAddress}', ${port}, '${password}', ${PTZType}, ${status})") |
| 20 | int add(DeviceChannel channel); | 20 | int add(DeviceChannel channel); |
| 21 | 21 | ||
| 22 | -// @Update("UPDATE device_channel " + | ||
| 23 | -// "SET name=#{name}, manufacture=#{manufacture}, model=#{model}, owner=#{owner}, civilCode=#{civilCode}, " + | ||
| 24 | -// "block=#{block}, address=#{address}, parental=#{parental}, parentId=#{parentId}, safetyWay=#{safetyWay}, " + | ||
| 25 | -// "registerWay=#{registerWay}, certNum=#{certNum}, certifiable=#{certifiable}, errCode=#{errCode}, secrecy=#{secrecy}, " + | ||
| 26 | -// "ipAddress=#{ipAddress}, port=#{port}, password=#{password}, PTZType=#{PTZType}, status=#{status}, streamId=#{streamId}, " + | ||
| 27 | -// "hasAudio=#{hasAudio}" + | ||
| 28 | -// "WHERE deviceId=#{deviceId} AND channelId=#{channelId}") | ||
| 29 | - | ||
| 30 | - | ||
| 31 | @Update(value = {" <script>" + | 22 | @Update(value = {" <script>" + |
| 32 | "UPDATE device_channel " + | 23 | "UPDATE device_channel " + |
| 33 | "SET deviceId='${deviceId}'" + | 24 | "SET deviceId='${deviceId}'" + |
src/main/java/com/genersoft/iot/vmp/vmanager/device/DeviceController.java
| @@ -63,13 +63,6 @@ public class DeviceController { | @@ -63,13 +63,6 @@ public class DeviceController { | ||
| 63 | 63 | ||
| 64 | /** | 64 | /** |
| 65 | * 分页查询通道数 | 65 | * 分页查询通道数 |
| 66 | - * @param deviceId 设备id | ||
| 67 | - * @param page 当前页 | ||
| 68 | - * @param count 每页条数 | ||
| 69 | - * @return 通道列表 | ||
| 70 | - */ | ||
| 71 | - /** | ||
| 72 | - * 分页查询通道数 | ||
| 73 | * | 66 | * |
| 74 | * @param deviceId 设备id | 67 | * @param deviceId 设备id |
| 75 | * @param page 当前页 | 68 | * @param page 当前页 |
src/main/java/com/genersoft/iot/vmp/vmanager/play/PlayController.java
| @@ -169,7 +169,6 @@ public class PlayController { | @@ -169,7 +169,6 @@ public class PlayController { | ||
| 169 | // 超时处理 | 169 | // 超时处理 |
| 170 | result.onTimeout(()->{ | 170 | result.onTimeout(()->{ |
| 171 | logger.warn(String.format("设备预览/回放停止超时,streamId:%s ", streamId)); | 171 | logger.warn(String.format("设备预览/回放停止超时,streamId:%s ", streamId)); |
| 172 | - | ||
| 173 | RequestMessage msg = new RequestMessage(); | 172 | RequestMessage msg = new RequestMessage(); |
| 174 | msg.setId(DeferredResultHolder.CALLBACK_CMD_STOP + uuid); | 173 | msg.setId(DeferredResultHolder.CALLBACK_CMD_STOP + uuid); |
| 175 | msg.setData("Timeout"); | 174 | msg.setData("Timeout"); |
src/main/java/com/genersoft/iot/vmp/web/ApiStreamController.java
| @@ -39,8 +39,6 @@ public class ApiStreamController { | @@ -39,8 +39,6 @@ public class ApiStreamController { | ||
| 39 | @Autowired | 39 | @Autowired |
| 40 | private IRedisCatchStorage redisCatchStorage; | 40 | private IRedisCatchStorage redisCatchStorage; |
| 41 | 41 | ||
| 42 | - private boolean closeWaitRTPInfo = false; | ||
| 43 | - | ||
| 44 | 42 | ||
| 45 | @Autowired | 43 | @Autowired |
| 46 | private ZLMRESTfulUtils zlmresTfulUtils; | 44 | private ZLMRESTfulUtils zlmresTfulUtils; |
web_src/src/components/channelList.vue
| @@ -44,8 +44,8 @@ | @@ -44,8 +44,8 @@ | ||
| 44 | <el-table-column label="状态" width="180" align="center"> | 44 | <el-table-column label="状态" width="180" align="center"> |
| 45 | <template slot-scope="scope"> | 45 | <template slot-scope="scope"> |
| 46 | <div slot="reference" class="name-wrapper"> | 46 | <div slot="reference" class="name-wrapper"> |
| 47 | - <el-tag size="medium" v-if="scope.row.status == 1">在线</el-tag> | ||
| 48 | - <el-tag size="medium" type="info" v-if="scope.row.status == 0">离线</el-tag> | 47 | + <el-tag size="medium" v-if="scope.row.status == 1">开启</el-tag> |
| 48 | + <el-tag size="medium" type="info" v-if="scope.row.status == 0">关闭</el-tag> | ||
| 49 | </div> | 49 | </div> |
| 50 | </template> | 50 | </template> |
| 51 | </el-table-column> | 51 | </el-table-column> |
| @@ -99,14 +99,14 @@ export default { | @@ -99,14 +99,14 @@ export default { | ||
| 99 | total: 0, | 99 | total: 0, |
| 100 | beforeUrl: "/videoList", | 100 | beforeUrl: "/videoList", |
| 101 | isLoging: false, | 101 | isLoging: false, |
| 102 | - autoList: false | 102 | + autoList: true |
| 103 | }; | 103 | }; |
| 104 | }, | 104 | }, |
| 105 | 105 | ||
| 106 | mounted() { | 106 | mounted() { |
| 107 | this.initData(); | 107 | this.initData(); |
| 108 | if (this.autoList) { | 108 | if (this.autoList) { |
| 109 | - this.updateLooper = setInterval(this.initData, 1500); | 109 | + this.updateLooper = setInterval(this.initData, 5000); |
| 110 | } | 110 | } |
| 111 | 111 | ||
| 112 | }, | 112 | }, |
| @@ -179,7 +179,7 @@ export default { | @@ -179,7 +179,7 @@ export default { | ||
| 179 | 179 | ||
| 180 | //通知设备上传媒体流 | 180 | //通知设备上传媒体流 |
| 181 | sendDevicePush: function (itemData) { | 181 | sendDevicePush: function (itemData) { |
| 182 | - console.log(itemData) | 182 | + console.log(itemData); |
| 183 | let deviceId = this.deviceId; | 183 | let deviceId = this.deviceId; |
| 184 | this.isLoging = true; | 184 | this.isLoging = true; |
| 185 | let channelId = itemData.channelId; | 185 | let channelId = itemData.channelId; |
web_src/src/components/gb28181/devicePlayer.vue
| @@ -67,7 +67,7 @@ | @@ -67,7 +67,7 @@ | ||
| 67 | <div style="position: absolute; left: 7.25rem; top: 1.25rem" @mousedown="ptzCamera(0, 0, 1)" @mouseup="ptzCamera(0, 0, 0)"><i class="el-icon-zoom-in control-zoom-btn" style="font-size: 1.875rem;"></i></div> | 67 | <div style="position: absolute; left: 7.25rem; top: 1.25rem" @mousedown="ptzCamera(0, 0, 1)" @mouseup="ptzCamera(0, 0, 0)"><i class="el-icon-zoom-in control-zoom-btn" style="font-size: 1.875rem;"></i></div> |
| 68 | <div style="position: absolute; left: 7.25rem; top: 3.25rem; font-size: 1.875rem;" @mousedown="ptzCamera(0, 0, 2)" @mouseup="ptzCamera(0, 0, 0)"><i class="el-icon-zoom-out control-zoom-btn"></i></div> | 68 | <div style="position: absolute; left: 7.25rem; top: 3.25rem; font-size: 1.875rem;" @mousedown="ptzCamera(0, 0, 2)" @mouseup="ptzCamera(0, 0, 0)"><i class="el-icon-zoom-out control-zoom-btn"></i></div> |
| 69 | <div class="contro-speed" style="position: absolute; left: 4px; top: 7rem; width: 9rem;"> | 69 | <div class="contro-speed" style="position: absolute; left: 4px; top: 7rem; width: 9rem;"> |
| 70 | - <el-slider v-model="controSpeed"></el-slider> | 70 | + <el-slider v-model="controSpeed" :max="255"></el-slider> |
| 71 | </div> | 71 | </div> |
| 72 | </div> | 72 | </div> |
| 73 | 73 |
web_src/src/components/videoList.vue
| @@ -52,7 +52,7 @@ | @@ -52,7 +52,7 @@ | ||
| 52 | <el-table-column label="操作" width="240" align="center" fixed="right"> | 52 | <el-table-column label="操作" width="240" align="center" fixed="right"> |
| 53 | <template slot-scope="scope"> | 53 | <template slot-scope="scope"> |
| 54 | <el-button size="mini" :ref="scope.row.deviceId + 'refbtn' " icon="el-icon-refresh" @click="refDevice(scope.row)">刷新通道</el-button> | 54 | <el-button size="mini" :ref="scope.row.deviceId + 'refbtn' " icon="el-icon-refresh" @click="refDevice(scope.row)">刷新通道</el-button> |
| 55 | - <el-button size="mini" icon="el-icon-s-open" type="primary" @click="showChannelList(scope.row)">查看通道</el-button> | 55 | + <el-button size="mini" icon="el-icon-s-open" v-bind:disabled="scope.row.online==0" type="primary" @click="showChannelList(scope.row)">查看通道</el-button> |
| 56 | </template> | 56 | </template> |
| 57 | </el-table-column> | 57 | </el-table-column> |
| 58 | </el-table> | 58 | </el-table> |