You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
202 lines
5.0 KiB
202 lines
5.0 KiB
<?php
|
|
require_once('../ajax_asm.php');
|
|
|
|
if( $CUser->Data['id'] > 1 ){
|
|
$Data['status'] = 'error';
|
|
if( $CUser->Data['access'] > 5 ){
|
|
$QS = "SELECT * FROM `system_props` WHERE `id`=1";
|
|
$Result = $DATABASE->Query( $QS );
|
|
$CS = $Result[0];
|
|
$SKEL=<<<DATABOUNDARY
|
|
{
|
|
xtype: 'panel',
|
|
border: false,
|
|
frame: false,
|
|
items:[{
|
|
xtype: 'form',
|
|
labelAlign: 'right',
|
|
labelWidth: 180,
|
|
//height: PanelH - 30,
|
|
items:[{
|
|
xtype:'panel',
|
|
border: false,
|
|
frame: false,
|
|
html: '<table width="100%" border=0 class="setEd_infoPanel" id="LIBAV_LOGO"><tr><td width="200px"><div class="appis_logo_img"></div></td><td valign="middle">Application Settings</td></tr><tr><td colspan=2></td></tr></table><br/>'
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
},{
|
|
xtype: 'combo',
|
|
id: 'db_loging',
|
|
fieldLabel: '{$Labels->GetLabel('_DB_LOGGING_')}',
|
|
editable: false,
|
|
typeAhead: true,
|
|
triggerAction: 'all',
|
|
width: '100%',
|
|
lazyRender:true,
|
|
mode: 'local',
|
|
store: new Ext.data.ArrayStore({
|
|
fields: ['cid', 'cnam'],
|
|
data: [['0',"Disabled"], ['1',"Enabled"]]
|
|
}),
|
|
valueField: 'cid',
|
|
displayField: 'cnam',
|
|
listeners:{
|
|
focus: function( t ){
|
|
loadHelpTopic( 'application_op_small', 32 );
|
|
},
|
|
select: function( t, r, i ){
|
|
//alert('buba');
|
|
doApplicationOperation( 41, r.data.cid );
|
|
}
|
|
},
|
|
value: '{$CS['use_db_logging']}'
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
},{
|
|
xtype: 'combo',
|
|
id: 'ses_window',
|
|
fieldLabel: '{$Labels->GetLabel('_APP_SESS_WND_')}',
|
|
editable: false,
|
|
typeAhead: true,
|
|
triggerAction: 'all',
|
|
width: '100%',
|
|
lazyRender:true,
|
|
mode: 'local',
|
|
store: new Ext.data.ArrayStore({
|
|
fields: ['cid', 'cnam'],
|
|
data: [['1',"1 Minute"], ['2',"2 Minutes"], ['3',"3 Minutes"], ['4',"4 Minutes"],['5',"5 Minutes"]]
|
|
}),
|
|
valueField: 'cid',
|
|
displayField: 'cnam',
|
|
listeners:{
|
|
focus: function( t ){
|
|
loadHelpTopic( 'application_op_small', 33 );
|
|
},
|
|
select: function( t, r, i ){
|
|
//alert('buba');
|
|
//doApplicationOperation( 1, i );
|
|
}
|
|
},
|
|
value: 1//'{$CS['menc_container']}'
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
},{
|
|
xtype: 'combo',
|
|
id: 'menc_cnt',
|
|
fieldLabel: '{$Labels->GetLabel('_APP_MENC_COUNT_')}',
|
|
editable: false,
|
|
typeAhead: true,
|
|
triggerAction: 'all',
|
|
width: '100%',
|
|
lazyRender:true,
|
|
mode: 'local',
|
|
store: new Ext.data.ArrayStore({
|
|
fields: ['cid', 'cnam'],
|
|
data: [['1',"1"], ['2',"2"], ['3',"3"], ['4',"4"],['5',"5"],['6',"6"],['7',"7"],['8',"8"]]
|
|
}),
|
|
valueField: 'cid',
|
|
displayField: 'cnam',
|
|
listeners:{
|
|
focus: function( t ){
|
|
loadHelpTopic( 'application_op_small', 34 );
|
|
},
|
|
select: function( t, r, i ){
|
|
//alert('buba');
|
|
//doApplicationOperation( 1, i );
|
|
}
|
|
},
|
|
value: '{$CS['encoder_limit']}'
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
},{
|
|
xtype: 'numberfield',
|
|
fieldLabel: 'SCADA Auto Time',
|
|
editable: true,
|
|
width: 250,
|
|
value: '{$CS['modbus_auto_rise']}',
|
|
listeners:{
|
|
focus: function( t ){
|
|
loadHelpTopic( 'application_op_small', 35 );
|
|
},
|
|
change: function( t, r, i ){
|
|
//alert('buba');
|
|
doApplicationOperation( 43, r );
|
|
}
|
|
}
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
},{
|
|
xtype: 'combo',
|
|
fieldLabel: 'SCADA Manual Activation',
|
|
editable: false,
|
|
typeAhead: true,
|
|
triggerAction: 'all',
|
|
width: '100%',
|
|
lazyRender:true,
|
|
mode: 'local',
|
|
store: new Ext.data.ArrayStore({
|
|
fields: ['cid', 'cnam'],
|
|
data: [['0',"Disabled"], ['3',"Alert"], ['4',"Hazard"]]
|
|
}),
|
|
valueField: 'cid',
|
|
displayField: 'cnam',
|
|
listeners:{
|
|
focus: function( t ){
|
|
loadHelpTopic( 'application_op_small', 36 );
|
|
},
|
|
select: function( t, r, i ){
|
|
//alert('buba');
|
|
doApplicationOperation( 44, r.data.cid, true );
|
|
}
|
|
},
|
|
value: '{$CS['modbus_hazard_level']}'
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
},{
|
|
xtype: 'combo',
|
|
fieldLabel: 'SCADA Health Level',
|
|
editable: false,
|
|
typeAhead: true,
|
|
triggerAction: 'all',
|
|
width: '100%',
|
|
lazyRender:true,
|
|
mode: 'local',
|
|
store: new Ext.data.ArrayStore({
|
|
fields: ['cid', 'cnam'],
|
|
data: [['0',"Disabled"],['1',"Camera Failure"],['2',"LRF Failure"],['3',"Sensor Communication"],['4',"Module SW Failure"],['5',"Module Network Failure"]]
|
|
}),
|
|
valueField: 'cid',
|
|
displayField: 'cnam',
|
|
listeners:{
|
|
focus: function( t ){
|
|
loadHelpTopic( 'application_op_small', 37 );
|
|
},
|
|
select: function( t, r, i ){
|
|
//alert('buba');
|
|
doApplicationOperation( 45, r.data.cid, true );
|
|
}
|
|
},
|
|
value: '{$CS['modbus_health_level']}'
|
|
},{
|
|
xtype: 'spacer',
|
|
height: 10
|
|
}]
|
|
}]
|
|
}
|
|
DATABOUNDARY;
|
|
$Data['status']= 'ok';
|
|
$Data['content']=$SKEL;
|
|
} else {
|
|
$Data['msg']='Access Denied!';
|
|
};
|
|
echo json_encode( $Data );
|
|
} else {
|
|
header('location: /');
|
|
};
|
|
?>
|