40 changed files with 2679 additions and 228 deletions
-
2index.php
-
2lib/controller/addModule.php
-
33lib/controller/dash/node_10.js
-
108lib/controller/dash/node_13.js
-
BINlib/controller/data/factory.db
-
BINlib/controller/data/mysqlitedb.db
-
BINlib/controller/data/reports/094c688e5e8dc1f8ef21d6e2db1f6a5f.mp4
-
BINlib/controller/data/reports/3d795f358a9132dbfcd9893d1da802ce.mp4
-
BINlib/controller/data/reports/5867808c7150d49c86fd81abb3eeeafe.mp4
-
BINlib/controller/data/reports/69c511bc894dffaae421028dc1906ef7.mp4
-
BINlib/controller/data/reports/863cc02857069ff580c79e1cb1647f71.mp4
-
BINlib/controller/data/reports/99f3f89ac1dfe06dd18f8d18ce0ca8ab.mp4
-
BINlib/controller/data/reports/9eb1ee93cb0fc840c852676d78acb131.mp4
-
BINlib/controller/data/reports/a821bcaac7313ef47ef3a9fd48dc153b.mp4
-
BINlib/controller/data/reports/cf2ae8197f26e5e0be501e364237a6c2.mp4
-
51lib/controller/doCameraOperation.php
-
106lib/controller/doNodeOperation.php
-
49lib/controller/getCameraEditor.php
-
2lib/controller/getCameraPreview.php
-
182lib/controller/getDashBoardItems.php
-
59lib/controller/getDashBoardStatus.php
-
0lib/controller/getDeviceDraw.php
-
0lib/controller/getDeviceMask.php
-
0lib/controller/getGrabberEritor.php
-
220lib/controller/getResourceEditor.php
-
32lib/controller/getSensors.php
-
4lib/controller/getStatus.php
-
0lib/controller/setAnalogStreamCtrl.php
-
8lib/controller/updateDashBoardItems.php
-
1299lib/javascript/jsapi_dynamic/mojo_dashboard.js
-
95lib/javascript/jsapi_dynamic/mojo_monitoring.js
-
510lib/javascript/jsapi_dynamic/mojo_settings.js
-
15lib/javascript/jsapi_dynamic/rgoose_global_vars.js
-
125lib/javascript/jsapi_dynamic/rgoose_main.js
-
5lib/php/db/SQLite_Class.php
-
BINstyle/assets/ed-0.png
-
BINstyle/assets/ed-1.png
-
BINstyle/assets/ed-1.psd
-
BINstyle/assets/ed-2.png
-
BINstyle/assets/ed-3.png
@ -1,18 +1,39 @@ |
|||
{ |
|||
id: 'db_node_%%%NODEID%%%', |
|||
xtype: 'portlet', |
|||
width: 258, |
|||
height: %%%HEIGHT%%%+40, |
|||
//xtype: 'portlet',
|
|||
layout:'fit', |
|||
//width: 258,
|
|||
//height: %%%HEIGHT%%%+40,
|
|||
tools: [{ |
|||
id:'gear', |
|||
handler: function(){ |
|||
editAnalogStream( %%%STREAMID%%%, 1 ); |
|||
//editAnalogStream( %%%STREAMID%%%, 1 );
|
|||
} |
|||
}], |
|||
frame: true, |
|||
draggable: false, |
|||
bodyStyle: 'padding: 0px;', |
|||
title: '%%%NODENAME%%%', |
|||
items:[{ |
|||
html: '<img data-enlargeable000 ondblclick="fullScreen(\'img-%%%NODEID%%%\');" style="cursor: zoom-in" id="img-%%%NODEID%%%" src="%%%SELURL%%%" width="%%%WIDTH%%%" height="%%%HEIGHT%%%"/>', |
|||
}] |
|||
id: 'db_node_%%%NODEID%%%_pic', |
|||
html: '', |
|||
}], |
|||
sukaMineWidth: -1, |
|||
listeners:{ |
|||
resize: function( p, adjWidth, adjHeight, rawWidth, rawHeight ){ |
|||
if( rawWidth!= undefined ){ |
|||
if( p.sukaMineWidth != adjWidth ){ |
|||
p.sukaMineWidth = adjWidth; |
|||
var XX = 32 + p.sukaMineWidth * %%%HEIGHT%%% / %%%WIDTH%%%; |
|||
p.setHeight( XX ); |
|||
}; |
|||
}; |
|||
var z = Ext.getCmp('db_node_%%%NODEID%%%_pic'); |
|||
z.update('<img data-enlargeable000 ondblclick="fullScreen(\'img-%%%NODEID%%%\');" style="cursor: zoom-in" id="img-%%%NODEID%%%" src="%%%SELURL%%%" width="100%" />'); |
|||
}, |
|||
afterrender: function( p ){ |
|||
var xx = p.getWidth() * %%%HEIGHT%%% / %%%WIDTH%%%; |
|||
p.setHeight( xx+32 ); |
|||
} |
|||
} |
|||
} |
|||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -0,0 +1,182 @@ |
|||
<?php |
|||
require_once('../ajax_asm.php'); |
|||
$UID = intval( $CUser->Data['id'] ); |
|||
$Data = ''; |
|||
if( $UID > 1 ){ |
|||
$QS = "SELECT * FROM `system_props` LIMIT 1"; |
|||
$SPD = $DATABASE->Query( $QS ); |
|||
if( count( $SPD ) ){ |
|||
$SP = $SPD[0]; |
|||
|
|||
$DUMM = array(); |
|||
$DUMM['camera']="{xtype:'panel',html:'NO CAMERA'}"; |
|||
$DUMM['sensor']="{xtype:'panel',html:'NO SENSOR'}"; |
|||
$DUMM['map']="{xtype:'panel',html:'NO MAP'}"; |
|||
$DUMM['log']="{xtype:'panel',html:'NO LOG'}"; |
|||
$STA = array(); |
|||
$END="]}"; |
|||
$STA[0]="{ columnWidth: 1, style:'padding:10px 0 10px 10px', items:["; |
|||
$STA[1]="{ columnWidth: 0.5, style:'padding:10px 0 10px 10px', items:["; |
|||
$STA[2]="{ columnWidth: 0.5, style:'padding:10px 0 10px 10px', items:["; |
|||
$STA[3]="{ columnWidth: 0.25, style:'padding:10px 0 10px 10px', items:["; |
|||
$STA[4]="{ columnWidth: 0.25, style:'padding:10px 0 10px 10px', items:["; |
|||
$STA[5]="{ columnWidth: 0.25, style:'padding:10px 0 10px 10px', items:["; |
|||
$STA[6]="{ columnWidth: 0.25, style:'padding:10px 0 10px 10px', items:["; |
|||
$MCOL = 7; |
|||
$P1="{ columnWidth: .25, style:'padding:10px 0 10px 10px', items:["; |
|||
$P2="]}"; |
|||
$QS = "SELECT * FROM nodes WHERE `type`> 0 "; |
|||
$result = $DATABASE->Query( $QS, false ); |
|||
if( count( $result ) > 0 ){ |
|||
$QS = "SELECT * FROM users_dash_layout WHERE user_id={$UID} ORDER BY x,y"; |
|||
$Lay = $DATABASE->Query( $QS, false ); |
|||
$AL = array(); |
|||
foreach( $Lay as $L ){ |
|||
$AL[$L['node_id']]=$L; |
|||
}; |
|||
$COLS = array(); |
|||
$Z = array(); |
|||
foreach( $result as $R ){ |
|||
if( isset( $AL[$R['id']] ) ){ |
|||
$COLS[intval($AL[$R['id']]['x'])][intval($AL[$R['id']]['y'])] = $R; |
|||
} else { |
|||
$Z[] = $R; |
|||
}; |
|||
}; |
|||
if( count( $Z ) ) foreach( $Z as $z ) $COLS[$MCOL-1][]=$z; |
|||
$STOL = array(); |
|||
for( $i=0; $i < $MCOL; $i++ ){ |
|||
$index = 0; |
|||
$TPL = array(); |
|||
$STOL[] = array(); |
|||
if( isset( $COLS[$i] ) ){ |
|||
foreach( $COLS[$i] as $R ){ |
|||
$TFN = 'dash/node_' . $R['type'] . '.js'; |
|||
if(!file_exists( $TFN )) continue; |
|||
$TPL[$index] = file_get_contents( $TFN ); |
|||
$TPL[$index] = str_replace('%%%NODEID%%%', ''.$R['id'] , $TPL[$index] ); |
|||
$TPL[$index] = str_replace('%%%NODENAME%%%', ''.$R['name'] , $TPL[$index] ); |
|||
switch( $R['type'] ){ |
|||
case ARGUS_SERVER:{ |
|||
$TPL[$index] = str_replace('%%%SYSSERVERNAME%%%', $Labels->getLabel( 'SYS_SERVNAME' ), $TPL[$index] ); |
|||
if( $R['online']== 1 ){ |
|||
$TPL[$index] = str_replace('%%%SERVERSTATUS%%%', $Labels->getLabel('SRV_STATUS_ON') , $TPL[$index]); |
|||
$TPL[$index] = str_replace('%%%SERVERSTATUSIMG%%%', 'accept.png' , $TPL[$index]); |
|||
} else { |
|||
$TPL[$index] = str_replace('%%%SERVERSTATUS%%%', $Labels->getLabel('SRV_STATUS_OFF') , $TPL[$index]); |
|||
$TPL[$index] = str_replace('%%%SERVERSTATUSIMG%%%', 'stop.png' , $TPL[$index]); |
|||
}; |
|||
$QS="SELECT * FROM `server_modules` WHERE `server_id`={$R['aux_id']}"; |
|||
$Z=$DATABASE->Query($QS); |
|||
$MODULES = array(); |
|||
if(count($Z)){ |
|||
foreach( $Z as $mod ){ |
|||
$QS="SELECT * FROM server_module_types WHERE id={$mod['type']}"; |
|||
$mtt=$DATABASE->Query( $QS ); |
|||
$CM['xtype'] = 'panel'; |
|||
if( $mod['enabled'] == 1 ){ |
|||
$CM['html'] = '<table width="100%"><tr><td><p class="super_small">'.$Labels->getLabel( $mtt[0]['name'] ).'</p></td><td width="16px"><img title="'.$Labels->getLabel( '__ENABLED__' ).'" src="/style/icons/icons/plugin_add.png"></td></tr></table>'; |
|||
} else { |
|||
$CM['html'] = '<table width="100%"><tr><td><p class="super_small">'.$Labels->getLabel( $mtt[0]['name'] ).'</p></td><td width="16px"><img title="'.$Labels->getLabel( '__DISABLED__' ).'" src="/style/icons/icons/plugin_delete.png"></td></tr></table>'; |
|||
}; |
|||
$CM['height'] = 25; |
|||
$MODULES[] = $CM; |
|||
}; |
|||
$MODULES_CNT = json_encode( $MODULES ); |
|||
} else { |
|||
$MODULES_CNT = '[{ html: \'No Modules Defined\'}]'; |
|||
}; |
|||
$TPL[$index] = str_replace('%%%MODULES%%%', ''.$MODULES_CNT , $TPL[$index] ); |
|||
break; |
|||
}; |
|||
case ARGUS_LFS_SENSOR: |
|||
case ARGUS_PLS_200_SENSOR: |
|||
case ARGUS_PLS_360_SENSOR:{ |
|||
break; |
|||
}; |
|||
case ARGUS_3D_SENSOR:{ |
|||
break; |
|||
}; |
|||
case 10: |
|||
case 11: |
|||
case 12: |
|||
case ARGUS_IP_PTZ_CAMERA:{ |
|||
//$QS="SELECT * FROM cameras WHERE node_id={$R['id']}";
|
|||
$QS="SELECT * FROM `nodes` WHERE `id`={$R['id']}"; |
|||
$Z=$DATABASE->Query( $QS ); |
|||
$QS="SELECT * FROM `module_eve` WHERE `id`=1"; |
|||
$S=$DATABASE->Query( $QS ); |
|||
$MODULE_DATA = $S[0]; |
|||
$TPL[$index] = str_replace( '%%%NODENAME%%%', urldecode( $Z[0]['name'] ) , $TPL[$index] ); |
|||
$FU = 'http://' . $_SERVER['SERVER_ADDR'].':' . $MODULE_DATA['web_port'] .'/stream?id='. $Z[0]['aux_parameter']; |
|||
$CS[] = '[' . $Z[0]['aux_parameter'] . ',\'[ 120x120] Video\',\''. $FU .'\']'; |
|||
$TPL[$index] = str_replace( '%%%URLS%%%', '[' . implode( ',', $CS ) . ']' , $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%SELID%%%', 'value: '. $Z[0]['aux_parameter'] .',', $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%SELURL%%%', $FU, $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%STREAMID%%%', $R['aux_parameter'], $TPL[$index] ); |
|||
|
|||
$FK = $MODULE_DATA['height'] /$MODULE_DATA['width']; |
|||
$W = 244; |
|||
$H = $W * $FK; |
|||
|
|||
$TPL[$index] = str_replace( '%%%WIDTH%%%', $W, $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%HEIGHT%%%', $H, $TPL[$index] ); |
|||
/* |
|||
$QS="SELECT mss.*, ms.name, ms.img_width, ms.img_height FROM media_server_streams mss LEFT JOIN media_streams ms ON ( mss.media_stream_id = ms.id ) WHERE ms.source_id={$Z[0]['id']} AND mss.valid=1 AND mss.online=1"; |
|||
$S=$DATABASE->Query( $QS ); |
|||
|
|||
if( count( $S ) ){ |
|||
$CS = array(); |
|||
$FID = 0; |
|||
$FUL = ''; |
|||
foreach( $S as $sou ){ |
|||
$QS = "SELECT * FROM media_servers WHERE id = {$sou['media_server_id']}"; |
|||
$F = $DATABASE->Query( $QS ); |
|||
$FF=$F[0]; |
|||
if( $FF['ip']=='127.0.0.1'){ |
|||
//Localhost
|
|||
$FF['ip'] = $_SERVER['SERVER_ADDR']; |
|||
}; |
|||
$ACC_URL='http://' . $FF['ip'] . ':' . $FF['REST_port']; |
|||
$CU = str_replace( $FF['virtual_host'], $ACC_URL, $sou['key'] ) . '/hls.m3u8'; |
|||
if( $FID == 0 ){ |
|||
// First URL as default
|
|||
$FID = $sou['id']; |
|||
$FUL = $CU; |
|||
}; |
|||
$CS[] = '[' . $sou['id'] . ',\'[' . $sou['img_width'] . 'x' . $sou['img_height'] . '] '. $sou['name'].'\',\'' . $CU .'\']'; |
|||
}; |
|||
$TPL[$index] = str_replace( '%%%URLS%%%', '['. implode( ',', $CS ) . ']' , $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%SELID%%%', 'value: '. $FID .',', $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%SELURL%%%', $FUL, $TPL[$index] ); |
|||
} else { |
|||
// Handle No Video From Camera!
|
|||
$TPL[$index] = str_replace( '%%%URLS%%%', '[]' , $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%SELID%%%', 'value: \'No Video Sources\',', $TPL[$index] ); |
|||
$TPL[$index] = str_replace( '%%%SELURL%%%','', $TPL[$index] ); |
|||
}; |
|||
*/ |
|||
break; |
|||
}; |
|||
}; |
|||
$index++; |
|||
}; |
|||
}; |
|||
//if( $i == 0 ) $TPL[] = '{ id: \'db_node_22311232\', frame: false, colspan: 2, width: 516, height: 200, border: true, title: \'PIZDA\', items:[{ html: \'<p>Server</p>\'}]}';
|
|||
$STOL[$i] = $STA[$i] . implode( ',', $TPL ) . $END; |
|||
}; |
|||
//$STOL[] = "{ columnWidth: 0.5, style:'padding:10px 0 10px 10px', items:[]}";
|
|||
//$STOL[] = "{ columnWidth: 0.5, style:'padding:10px 0 10px 10px', items:[]}";
|
|||
//$STOL[] = "{ columnWidth: 1, style:'padding:10px 0 10px 10px', items:[]}";
|
|||
$Data = '[' . implode( ',' , $STOL ) . ']'; |
|||
}; |
|||
} else { |
|||
$Data = '[{columnWidth: 1, items:{html:"NO SYSTEM PROPS"}} ]'; |
|||
}; |
|||
}; |
|||
if( $Data != '' ) { |
|||
echo $Data; |
|||
} else { |
|||
echo '[]'; |
|||
}; |
|||
?>
|
|||
@ -0,0 +1,59 @@ |
|||
<?php |
|||
require_once('../ajax_asm.php'); |
|||
if( $CUser->Data['id'] > 1 ){ |
|||
$SiteID = intval( $_POST['SITE'] ); |
|||
$UID = intval( $CUser->Data['id'] ); |
|||
$Data = array(); |
|||
$Data['nodes'] = array(); |
|||
$QS = "SELECT * FROM nodes WHERE site_id = {$SiteID}"; |
|||
$result = $DATABASE->Query( $QS, false ); |
|||
if( count( $result ) > 0 ){ |
|||
foreach( $result as $R ){ |
|||
$CN = array(); |
|||
$CN['id'] = $R['id']; |
|||
$CN['status'] = intval($R['online']); |
|||
switch( $R['type'] ){ |
|||
case ARGUS_SERVER:{ |
|||
break; |
|||
}; |
|||
case ARGUS_ALS_SENSOR: |
|||
case ARGUS_LFS_SENSOR: |
|||
case ARGUS_PLS_200_SENSOR: |
|||
case ARGUS_PLS_360_SENSOR: |
|||
case ARGUS_NET_PLS_200:{ |
|||
if( $CN['status'] ){ |
|||
// check Targets
|
|||
$CN['targets'] = array(); |
|||
$QS="SELECT * FROM events_cloud WHERE node_id={$CN['id']} AND ( evt_type=13 OR evt_type=14) ORDER BY id DESC LIMIT 32"; |
|||
//$QS="SELECT * FROM events_cloud WHERE node_id={$CN['id']} AND ( evt_type=13 OR evt_type=14) AND (UNIX_TIMESTAMP(NOW())-ts)<60 ORDER BY id DESC LIMIT 32";
|
|||
//$QS="SELECT * FROM events_cloud WHERE node_id={$CN['id']} AND ( evt_type=13 OR evt_type=14) ORDER BY ts, ts_ms DESC LIMIT 32";
|
|||
//echo $QS . "\n\n";
|
|||
$zult = $DATABASE->Query( $QS ); |
|||
if( count( $zult ) ){ |
|||
$CN['status'] = 2; // Alarmed
|
|||
$CT = array(); |
|||
foreach( $zult as $Z ){ |
|||
$CT['digital'] = $Z['range_digital']; |
|||
$CT['az'] = $Z['azimuth']; |
|||
$CN['targets'][] = $CT; |
|||
}; |
|||
}; |
|||
}; |
|||
break; |
|||
}; |
|||
case ARGUS_3D_SENSOR:{ |
|||
break; |
|||
}; |
|||
case ARGUS_IP_PTZ_CAMERA:{ |
|||
break; |
|||
}; |
|||
}; |
|||
//$index++;
|
|||
$Data['nodes'][] = $CN; |
|||
}; |
|||
}; |
|||
echo json_encode( $Data ); |
|||
} else { |
|||
echo '[]'; |
|||
}; |
|||
?>
|
|||
@ -0,0 +1,32 @@ |
|||
<?php |
|||
require_once('../ajax_asm.php'); |
|||
ob_start(); |
|||
$UID = intval( $CUser->Data['id'] ); |
|||
$ACCESS = intval( $CUser->Data['access'] ); |
|||
if( $UID > 1 ){ |
|||
$QS = "SELECT `sen`.*, `no`.`enable`, `no`.`name` FROM `lrf_sensors` `sen` LEFT JOIN `nodes` `no` ON( `no`.`aux_id`=`sen`.`id` AND `no`.`type`=`sen`.`type`)"; |
|||
$Result = $DATABASE->Query( $QS, false ); |
|||
if( count( $Result ) ){ |
|||
$SenPart = array(); |
|||
foreach( $Result as $R ){ |
|||
switch( $R['type'] ){ |
|||
case 1: $HWT = 'ALS ' . $R['max_range'] . ' meters'; break; |
|||
case 2: $HWT = 'LFS ' . $R['max_range'] . ' meters'; break; |
|||
case 3: $HWT = 'PLS200 ' . $R['max_range'] . ' meters'; break; |
|||
case 4: $HWT = 'PLS360 ' . $R['max_range'] . ' meters'; break; |
|||
}; |
|||
$SenPart[] = '{ xtype: \'panel\', boder: false, frame: false, html: \'<a class="sideInfo_item" id="UART_'.(($R['enable']==0)?'N':'O').'" onclick="editSensorHW('.$R['id'].');">'.urldecode($R['name']).'['.$HWT.']</a>\'}'; |
|||
}; |
|||
$Data['status']='ok'; |
|||
$Data['sensors'] = '['.implode( ',', $SenPart ) .']'; |
|||
} else { |
|||
$Data['status']='na'; |
|||
}; |
|||
$Data['messages'] = ob_get_clean(); |
|||
echo json_encode( $Data ); |
|||
} else { |
|||
header('location: /'); |
|||
}; |
|||
|
|||
|
|||
?>
|
|||
1299
lib/javascript/jsapi_dynamic/mojo_dashboard.js
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -1,12 +1,101 @@ |
|||
//<?php require_once('../../js_asm.php'); ?>
|
|||
|
|||
function updateDashBoardItemLayout( id, x, y ){ |
|||
Ext.Ajax.request({ |
|||
url: '/lib/controller/updateDashBoardItems.php', |
|||
params: { |
|||
SITE: <?=$SiteID;?>, |
|||
UID: <?=$UserID;?>, |
|||
SID: '<?=$Session;?>', |
|||
PANEL: id, |
|||
X: x, |
|||
Y: y |
|||
}, |
|||
success: function( response, opts ){ |
|||
//var data = Ext.decode(response.responseText);
|
|||
//var tPanel = Ext.getCmp('main_portal');
|
|||
//tPanel.removeAll(true);
|
|||
//for( i=0; i < data.length; i++) tPanel.add( data[i] );
|
|||
//tPanel.doLayout();
|
|||
}, |
|||
failure: failureAJAXFunction |
|||
}); |
|||
}; |
|||
|
|||
function initMonitoring(){ |
|||
if( tlInterval!= null ){ |
|||
window.clearInterval( tlInterval ); |
|||
tlInterval = null; |
|||
timelineObj = null; |
|||
}; |
|||
var tPanel = Ext.getCmp('main_content'); |
|||
tPanel.removeAll( true ); |
|||
tPanel.doLayout(); |
|||
Ext.Ajax.request({ |
|||
url: '/lib/controller/getDashBoardItems.php', |
|||
params: { |
|||
SITE: <?=$SiteID;?>, |
|||
UID: <?=$UserID;?>, |
|||
SID: '<?=$Session;?>' |
|||
}, |
|||
success: function( response, opts ){ |
|||
var data = Ext.decode(response.responseText); |
|||
Ext.getCmp('main_content').setTitle( '<?=$Labels->GetLabel('_SYS_DASHBOARD_');?>' ); |
|||
Ext.getCmp('main_content').removeAll(true); |
|||
Ext.getCmp('main_content').add({ |
|||
xtype: 'portal', |
|||
id: 'main_portal', |
|||
frame: false, |
|||
border: false, |
|||
items:{ |
|||
html: '' |
|||
}, |
|||
listeners:{ |
|||
drop: function( a ){ |
|||
updateDashBoardItemLayout( a.panel.id, a.columnIndex, a.position ); |
|||
} |
|||
} |
|||
}); |
|||
Ext.getCmp('main_content').doLayout(); |
|||
var tPanel = Ext.getCmp('main_portal'); |
|||
tPanel.removeAll(true); |
|||
nodeDashboardStatuses = new Array(); |
|||
for( i=0; i < data.length; i++) tPanel.add( data[i] ); |
|||
tPanel.doLayout(); |
|||
$('img[data-enlargeable]').addClass('img-enlargeable').click(function() { |
|||
var src = $(this).attr('src'); |
|||
var modal; |
|||
|
|||
function removeModal() { |
|||
modal.remove(); |
|||
$('body').off('keyup.modal-close'); |
|||
} |
|||
modal = $('<div>').css({ |
|||
background: 'RGBA(0,0,0,.5) url(' + src + ') no-repeat center', |
|||
backgroundSize: 'contain', |
|||
width: '100%', |
|||
height: '100%', |
|||
position: 'fixed', |
|||
zIndex: '10000', |
|||
top: '0', |
|||
left: '0', |
|||
cursor: 'zoom-out' |
|||
}).click(function() { |
|||
removeModal(); |
|||
}).appendTo('body'); |
|||
//handling ESC
|
|||
$('body').on('keyup.modal-close', function(e) { |
|||
if (e.key === 'Escape') { |
|||
removeModal(); |
|||
} |
|||
}); |
|||
}); |
|||
tlInterval = window.setInterval( fetchSiteStatus, 333, selectedSite ); |
|||
}, |
|||
failure: failureAJAXFunction |
|||
}); |
|||
//var tPanel = Ext.getCmp('main_content');
|
|||
//tPanel.removeAll( true );
|
|||
//tPanel.add({
|
|||
// xtype: 'panel',
|
|||
// html: 'KOKO'
|
|||
//});
|
|||
//tPanel.doLayout();
|
|||
}; |
|||
Binary file not shown.
|
After Width: 128 | Height: 128 | Size: 3.0 KiB |
Binary file not shown.
|
After Width: 128 | Height: 128 | Size: 3.0 KiB |
Binary file not shown.
Binary file not shown.
|
After Width: 128 | Height: 128 | Size: 3.0 KiB |
Binary file not shown.
|
After Width: 128 | Height: 128 | Size: 3.0 KiB |
Write
Preview
Loading…
Cancel
Save
Reference in new issue