| | |
| | | |
| | | export const getGB28181CameraTree = (query: any) => { |
| | | return request({ |
| | | url: "/data/api-v/area/gb28181Tree", |
| | | url: "/data/api-v/gb28181/tree", |
| | | method: "get", |
| | | params: query |
| | | }); |
| | |
| | | |
| | | export const refreshGB28181Tree = () => { |
| | | return request({ |
| | | url: "/data/api-v/area/gb28181RefreshTree", |
| | | url: "/data/api-v/gb28181/treeRefresh", |
| | | method: "post", |
| | | }); |
| | | }; |
| | |
| | | |
| | | export const getCameraInfo = (id: string) => { |
| | | return request({ |
| | | url: "/data/api-v/camera/show/" + id, |
| | | method: "get" |
| | | url: "/data/api-v/camera/show", |
| | | method: "get", |
| | | params: { cid: id } |
| | | }); |
| | | }; |
| | | |
| | |
| | | }) |
| | | } |
| | | //删除(展区) |
| | | export const delArea = (data:any) => { |
| | | export const delArea = (data: any) => { |
| | | return request({ |
| | | url: "/data/api-v/acp/delete", |
| | | method: "post", |
| | |
| | | } |
| | | |
| | | //保存区域编辑 |
| | | export const saveAreaInfo = (data:any) => { |
| | | export const saveAreaInfo = (data: any) => { |
| | | return request({ |
| | | url: "/data/api-v/acp/save", |
| | | method: "post", |
| | |
| | | } |
| | | |
| | | //获取摄像机的坐标标定信息 |
| | | export const getCameraMarks = (query:any) => { |
| | | export const getCameraMarks = (query: any) => { |
| | | return request({ |
| | | url: '/data/api-v/camera/coord', |
| | | method: "get", |
| | |
| | | } |
| | | |
| | | //更新摄像机的坐标标定信息 |
| | | export const updateCameraMarks = (data:any) => { |
| | | export const updateCameraMarks = (data: any) => { |
| | | return request({ |
| | | url: '/data/api-v/camera/updateCoord', |
| | | method: 'post', |
| | |
| | | } |
| | | |
| | | //保存摄像机分组 |
| | | export const saveCameraGroupInfo = (data:any) => { |
| | | export const saveCameraGroupInfo = (data: any) => { |
| | | return request({ |
| | | url: '/data/api-v/camera/group/save', |
| | | method: 'post', |
| | |
| | | }) |
| | | } |
| | | |
| | | export const delCameraGroup = (groupId:string)=>{ |
| | | export const delCameraGroup = (groupId: string) => { |
| | | return request({ |
| | | url:'/data/api-v/camera/group/del?groupId='+groupId, |
| | | url: '/data/api-v/camera/group/del?groupId=' + groupId, |
| | | method: 'post' |
| | | }) |
| | | } |
| | |
| | | |
| | | export const getGB28181Config = () => { |
| | | return request({ |
| | | url: "/data/api-v/sysset/gb28181ConfigShow", |
| | | url: "/data/api-v/gb28181/configShow", |
| | | method: "get" |
| | | }); |
| | | }; |
| | |
| | | |
| | | export const saveGB28181Config = (query: any) => { |
| | | return request({ |
| | | url: "/data/api-v/sysset/gb28181ConfEdit", |
| | | url: "/data/api-v/gb28181/configEdit", |
| | | method: "post", |
| | | data: query |
| | | }); |
| | |
| | | childrenFieldName: { type: String, default: "children" }, |
| | | itemEvents: { |
| | | type: Object, |
| | | default: function() { |
| | | default: function () { |
| | | return {}; |
| | | } |
| | | }, |
| | |
| | | item |
| | | ); |
| | | let self = this; |
| | | node.addBefore = function(data, selectedNode) { |
| | | node.addBefore = function (data, selectedNode) { |
| | | let newItem = self.initializeDataItem(data); |
| | | let index = selectedNode.parentItem.findIndex(t => t.id === node.id); |
| | | selectedNode.parentItem.splice(index, 0, newItem); |
| | | }; |
| | | node.addAfter = function(data, selectedNode) { |
| | | node.addAfter = function (data, selectedNode) { |
| | | let newItem = self.initializeDataItem(data); |
| | | let index = |
| | | selectedNode.parentItem.findIndex(t => t.id === node.id) + 1; |
| | | selectedNode.parentItem.splice(index, 0, newItem); |
| | | }; |
| | | node.addChild = function(data) { |
| | | node.addChild = function (data) { |
| | | let newItem = self.initializeDataItem(data); |
| | | node.opened = true; |
| | | node[self.childrenFieldName].push(newItem); |
| | | }; |
| | | node.openChildren = function() { |
| | | node.openChildren = function () { |
| | | node.opened = true; |
| | | self.handleRecursionNodeChildren(node, node => { |
| | | node.opened = true; |
| | | }); |
| | | }; |
| | | node.closeChildren = function() { |
| | | node.closeChildren = function () { |
| | | node.opened = false; |
| | | self.handleRecursionNodeChildren(node, node => { |
| | | node.opened = false; |
| | |
| | | oriNode.model.selected = true; |
| | | }, |
| | | handleBatchSelectItems(oriNode, oriItem) { |
| | | console.log('oriNode, oriItem',oriNode, oriItem) |
| | | console.log('oriNode, oriItem', oriNode, oriItem) |
| | | this.handleRecursionNodeChilds(oriNode, node => { |
| | | if (!!node.model) { |
| | | if (!!node.model.disabled) return; |
| | |
| | | this.initializeData(this.data); |
| | | }, |
| | | mounted() { |
| | | debugger |
| | | if (this.async) { |
| | | this.$set(this.data, 0, this.initializeLoading()); |
| | | this.handleAsyncLoad(this.data, this); |
| | |
| | | document.addEventListener("visibilitychange", () => { |
| | | this.visibilitychange(); |
| | | }); |
| | | debugger |
| | | this.getSounds(); |
| | | |
| | | this.eventAudio.addEventListener("ended", () => { |
| | |
| | | /> |
| | | </div> |
| | | </div> |
| | | </div> --> |
| | | <div class="top" > |
| | | </div>--> |
| | | <div class="top"> |
| | | <p class="task-css"> |
| | | <b style="font-size: 14px; line-height: 18px;">场景</b> |
| | | </p> |
| | |
| | | :ShowLocalVedio="cameraType === 'dataStack'" |
| | | v-if="showSysInfo" |
| | | style="margin-top:-10px" |
| | | /> --> |
| | | />--> |
| | | </div> |
| | | </div> |
| | | </div> |
| | |
| | | } |
| | | this.swipercanvasData = swipers; |
| | | }, |
| | | refresh(url,id) { |
| | | this.swipercanvasData.forEach(data=>{ |
| | | if(data.cameraId == id){ |
| | | refresh(url, id) { |
| | | this.swipercanvasData.forEach(data => { |
| | | if (data.cameraId == id) { |
| | | data.baseImg = url; |
| | | } |
| | | }) |
| | |
| | | //height: 100%; |
| | | //padding: 13px 0 20px; |
| | | position: relative; |
| | | .devide{ |
| | | .devide { |
| | | height: 10px; |
| | | background: #E9EBF2; |
| | | background: #e9ebf2; |
| | | } |
| | | .top { |
| | | width: 100%; |
| | |
| | | float: right; |
| | | width: 54%; |
| | | height: 144px; |
| | | .card-box{ |
| | | width: 54%!important; |
| | | .card-box { |
| | | width: 54% !important; |
| | | } |
| | | .eCharts-box{ |
| | | .eCharts-box { |
| | | width: 45%; |
| | | canvas{ |
| | | width: 98%!important; |
| | | } |
| | | canvas { |
| | | width: 98% !important; |
| | | } |
| | | } |
| | | } |
| | | .task-css { |
| | |
| | | .add-btn:hover { |
| | | color: #2249b4; |
| | | } |
| | | |
| | | } |
| | | </style> |
| | | <style lang="scss" scoped> |
| | |
| | | } |
| | | }, |
| | | methods: { |
| | | getSoundById(id){ |
| | | if(id){ |
| | | let sound = this.soundList.find(item=>item.id == id); |
| | | getSoundById(id) { |
| | | if (id) { |
| | | let sound = this.soundList.find(item => item.id == id); |
| | | return sound.name |
| | | }else{ |
| | | } else { |
| | | return '' |
| | | } |
| | | }, |
| | |
| | | .catch(() => { }); |
| | | }, |
| | | cellStyle(obj) { |
| | | if (obj.column.label == '策略'||obj.column.label == '事件声音') { |
| | | if (obj.column.label == '策略' || obj.column.label == '事件声音') { |
| | | return 'text-align:left;padding-left:8px;' |
| | | } |
| | | } |
| | |
| | | RightSide |
| | | }, |
| | | computed: { |
| | | app () { |
| | | app() { |
| | | return this.getUrlKey() !== null ? "DataStack" : "Camera" |
| | | } |
| | | }, |
| | | data () { |
| | | data() { |
| | | return { |
| | | leftWith: 0, |
| | | screenHeight: 0 |
| | | } |
| | | }, |
| | | mounted () { |
| | | mounted() { |
| | | this.screenHeight = document.documentElement.clientHeight; |
| | | window.onresize = () => { |
| | | return (() => { |
| | |
| | | this.TreeDataPool.readonly = false; |
| | | this.TreeDataPool.gbReadonly = false; |
| | | this.DataStackPool.readonly = false; |
| | | |
| | | debugger |
| | | }, |
| | | methods: { |
| | | getUrlKey () { |
| | | getUrlKey() { |
| | | let name = "dataStack" |
| | | return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.href) || [, ""])[1].replace(/\+/g, '%20')) || null |
| | | } |
| | |
| | | } |
| | | .resize-bar:hover ~ .resize-line::after, |
| | | .resize-bar:active ~ .resize-line::after { |
| | | content: ''; |
| | | content: ""; |
| | | position: absolute; |
| | | width: 16px; |
| | | height: 16px; |
| | |
| | | DataStackInfo, |
| | | SeparateRules, |
| | | LinkageRule }, |
| | | data () { |
| | | data() { |
| | | return { |
| | | activeName: "camera-info", |
| | | buttonAuthority: sessionStorage.getItem("buttonAuthoritys") || [], |
| | |
| | | }; |
| | | }, |
| | | computed: { |
| | | isAdmin () { |
| | | isAdmin() { |
| | | if ( |
| | | sessionStorage.getItem("userInfo") && |
| | | sessionStorage.getItem("userInfo") !== "" |
| | |
| | | |
| | | return false; |
| | | }, |
| | | firstLabeName () { |
| | | firstLabeName() { |
| | | return this.TreeDataPool.treeActiveName === "camera" ? "摄像机信息" : "数据栈信息" |
| | | } |
| | | }, |
| | |
| | | } |
| | | }, |
| | | "TreeDataPool.selectedNodes": { |
| | | handler (nodes) { |
| | | handler(nodes) { |
| | | if (this.activeName == "linkage-rule") { |
| | | this.$refs.linkRule.initCameraData(); |
| | | } |
| | |
| | | deep: true |
| | | }, |
| | | "DataStackPool.selectedDir": { |
| | | handler (node, oldNode) { |
| | | handler(node, oldNode) { |
| | | if (this.TreeDataPool.treeActiveName !== 'dataStack') { |
| | | return |
| | | } |
| | |
| | | }, |
| | | |
| | | }, |
| | | created () { |
| | | created() { |
| | | if (this.TreeDataPool.treeActiveName == 'camera') { |
| | | if (this.isShow('cameraAccess:cameraInfo')) { |
| | | this.activeName = "camera-info" |
| | |
| | | this.selectedNodes = []; |
| | | this.VideoManageData.init(); |
| | | }, |
| | | beforeDestroy () { |
| | | beforeDestroy() { |
| | | clearInterval(this.intervalTimer); |
| | | //this.TreeDataPool.treeActiveName = "camera"; |
| | | }, |
| | | mounted () { |
| | | mounted() { |
| | | this.$nextTick(() => { |
| | | bus.$on("addCameraOnTree", node => { |
| | | this.handAddDevice(node); |
| | |
| | | }, 10000) |
| | | }, |
| | | methods: { |
| | | isShow (authority) { |
| | | isShow(authority) { |
| | | return this.isAdmin || this.buttonAuthority.indexOf("," + authority + ",") > -1 |
| | | }, |
| | | handAddDevice (node) { |
| | | handAddDevice(node) { |
| | | let _this = this; |
| | | setTimeout(() => { |
| | | _this.$refs.cameraInfo.addDevice(node); |
| | | _this.activeName = "camera-info"; |
| | | }, 100); |
| | | }, |
| | | handAddDIr (node) { |
| | | handAddDIr(node) { |
| | | let _this = this; |
| | | setTimeout(() => { |
| | | _this.$refs.dataStackInfo.addDir(node); |
| | | _this.activeName = "camera-info"; |
| | | }, 100); |
| | | }, |
| | | handleClick (tab, event) { |
| | | handleClick(tab, event) { |
| | | this.TreeDataPool.multiple = tab.name === "linkage-rule"; |
| | | if (tab.name === "camera-info") { |
| | | if (this.TreeDataPool.treeActiveName == 'camera') { |
| | |
| | | |
| | | export const getGB28181Config = () => { |
| | | return request({ |
| | | url: "/data/api-v/sysset/gb28181ConfigShow", |
| | | url: "/data/api-v/gb28181/configShow", |
| | | method: "get" |
| | | }); |
| | | }; |
| | |
| | | |
| | | export const saveGB28181Config = (query: any) => { |
| | | return request({ |
| | | url: "/data/api-v/sysset/gb28181ConfEdit", |
| | | url: "/data/api-v/gb28181/configEdit", |
| | | method: "post", |
| | | data: query |
| | | }); |