/** * patrolpoint.js * 巡检点位管理界面 * emial: yaoqiang@chinausky.com * create: 2018-12-08 */ Ext.Loader.setConfig({ enabled: true }); Ext.Loader.setPath('Ext.ux', '../../res/extjs/examples/ux'); Ext.require([ 'Ext.grid.*', 'Ext.data.*', 'Ext.ux.RowExpander', 'Ext.selection.CheckboxModel' ]); var company_code; var myStore = null; var myStore1 = null; var V_LOGINNAME = '', V_PASSWORD = ''; var menuidx = ''; var mouseon; var mouseoff; var menu_click; var baseUrl = ''; var modifywin1; var MaintenanceCheckPanel1; //var MaintenanceCheckPanel2; var AllSelectedRecords = []; var AllSelectedRecords1 = []; var sm1; var sm2; var initflag = false; var initflag1 = false; var sm = Ext.create('Ext.selection.CheckboxModel'); Ext.define('Maintenance', { extend: 'Ext.data.Model', fields: [ { name: 'id', type: 'string' }, { name: 'xh', type: 'int' }, { name: 'spot_name', type: 'string' }, { name: 'company_code', type: 'string' }, { name: 'spot_address', type: 'string' }, { name: 'spot_type', type: 'string' }, { name: 'type_name', type: 'string' }, { name: 'latest_change_time', type: 'string' }, { name: 'building_name', type: 'string' }, { name: 'equipment_code', type: 'string' }, { name: 'remarks', type: 'string' }, { name: 'picture_route', type: 'string' }, ] }); Ext.define('CheckRecord3', { extend: 'Ext.data.Model', fields: [ { name: 'id', type: 'string' }, { name: 'spot_id', type: 'string' }, { name: 'xh', type: 'int' }, { name: 'equipment_code', type: 'string' }, { name: 'device_name', type: 'string' }, { name: 'unitinfo', type: 'string' }, ] }); Ext.define('patrolpoint1', { extend: 'Ext.data.Model', fields: [ { name: 'device_id', type: 'string' }, { name: 'device_name', type: 'string' }, { name: 'xh', type: 'int' }, { name: 'unitinfo', type: 'string' }, ] }); Ext.define('patrolpoint2', { extend: 'Ext.data.Model', fields: [ { name: 'device_id', type: 'string' }, { name: 'device_name', type: 'string' }, { name: 'xh', type: 'int' }, { name: 'unitinfo', type: 'string' }, { name: 'pd', type: 'string' }, ] }); function checkfilename() { var subwin = window.frames['file_uploader'].contentWindow; subwin.setpic(); // add_pic(); } function checkfilename2() { var subwin = window.frames['file_uploader2'].contentWindow; subwin.setpic2(); // add_pic(); } var add_pic = function () { Ext.create('Ext.window.Window', { id: 'patrol_point_pic_win', title: '图片上传', height: 200, width: 300, layout: 'fit', modal: true, buttons: [ { text: '上传', handler: function () { var subwin = window.frames['file_uploader'].contentWindow; subwin.uploadpic(); Ext.getCmp('patrol_point_pic_win').destroy(); } } , { text: '关闭', handler: function () { Ext.getCmp('patrol_point_pic_win').destroy(); } } ], closeAction: 'destroy', html: '
'
var unchkIcon = '
'
// company_code = document.getElementById('company_code').value;
$("#V_LOGINNAME").val(sessionStorage.getItem('V_LOGINNAME'));
$("#V_PASSWORD").val(sessionStorage.getItem('V_PASSWORD'));
V_LOGINNAME = $("#V_LOGINNAME").val();
V_PASSWORD = $("#V_PASSWORD").val();
var countPerPage = 15;
var maxHeight = 10000;
var chkBoolean = function (flag) {
if (flag)
return chkIcon;
return unchkIcon;
}
var queryJson = new Object();
queryJson.V_LOGINNAME = V_LOGINNAME;
// queryJson.V_PASSWORD = V_PASSWORD;
if ((company_code != null) && (company_code != 'null') && (company_code.length > 0))
queryJson.company_code = company_code;
Ext.define('QrcodeAnalysis2', {
extend: 'Ext.data.Model',
fields: [
{ name: 'building_name', type: 'string' },
{ name: 'building_id', type: 'string' }
]
});
var getManufacturerId2 = Ext.create('Ext.data.Store', {
model: 'QrcodeAnalysis2',
proxy: {
type: 'ajax',
actionMethods: {
create: 'POST',
read: 'POST', // by default GET
update: 'POST',
destroy: 'POST'
},
url: baseUrl + 'iot/company/view/getBuildingNameList',
reader: {
type: 'json',
root: 'RESULT',
totalProperty: 'totalCount'
},
extraParams: {
queryJson: Ext.JSON.encode(queryJson)
}
}
});
var clear_append_form = function () {
Ext.getCmp('fa_patrol_spot_name').setValue("");
Ext.getCmp('fa_patrol_company_code').setValue("");
Ext.getCmp('fa_patrol_spot_address').setValue("");
// Ext.getCmp('fa_patrol_equipment_code').setValue("");
Ext.getCmp('fa_patrol_spot_type').setValue(false);
Ext.getCmp('fa_patrol_point_message').setValue("");
// Ext.getCmp('fa_id').setValue("");
Ext.getCmp('PatrolpointListPageToolbar').moveFirst();
}
var deselect_fun = function (record) {
var index = AllSelectedRecords.indexOf(record.get("device_id"));
if (index > -1) {
AllSelectedRecords.splice(index, 1);
return AllSelectedRecords;
}
}
sm1 = Ext.create('Ext.selection.CheckboxModel', {
mode: "MULTI",
listeners: {
deselect: function (me, record, index, opts) {
if (initflag) {
// alert("初始化");
} else {
deselect_fun(record);
}
},
select: function (me, record, index, opts) {
var index = AllSelectedRecords.indexOf(record.get("device_id"));
if (index > -1) {
return AllSelectedRecords;
} else {
AllSelectedRecords.push(record.get("device_id"));
return AllSelectedRecords;
}
}
}
});
var deselect_fun1 = function (record) {
var index = AllSelectedRecords1.indexOf(record.get("device_id"));
if (index > -1) {
AllSelectedRecords1.splice(index, 1);
return AllSelectedRecords1;
}
}
sm2 = Ext.create('Ext.selection.CheckboxModel', {
mode: "MULTI",
listeners: {
deselect: function (me, record, index, opts) {
if (initflag1) {
} else {
deselect_fun1(record);
}
},
select: function (me, record, index, opts) {
var index = AllSelectedRecords1.indexOf(record.get("device_id"));
if (index > -1) {
return AllSelectedRecords1;
} else {
AllSelectedRecords1.push(record.get("device_id"));
return AllSelectedRecords1;
}
}
}
});
myStore = Ext.create('Ext.data.Store', {
model: 'Maintenance',
pageSize: countPerPage,
proxy: {
type: 'ajax',
actionMethods: {
create: 'POST',
read: 'POST', // by default GET
update: 'POST',
destroy: 'POST'
},
url: baseUrl + 'iot/inspectionpoints/getList1',
reader: {
type: 'json',
root: 'RESULT',
totalProperty: 'totalCount'
},
extraParams: {
queryJson: Ext.JSON.encode(queryJson)
}
},
// sorters:[{
// property:'data_time',
// direction:'DESC'
// }],
remoteSort: true
});
myStore1 = Ext.create('Ext.data.Store', {
model: 'CheckRecord3',
pageSize: 10,
proxy: {
type: 'ajax',
url: baseUrl + 'iot/inspectionpoints/getXzsbList',
reader: {
type: 'json',
root: 'RESULT',
totalProperty: 'totalCount'
},
extraParams: {
queryJson: Ext.JSON.encode(queryJson)
}
},
remoteSort: true
});
var myStore2 = Ext.create('Ext.data.Store', {
model: 'patrolpoint1',
pageSize: 5,
listeners: {
beforeload: function (me, store, operation, eOpts) {
initflag = true;
},
load: function (me, records, success, opts) {
if (!success || !records || records.length == 0)
return;
//根据全局的选择,初始化选中的列
var selModel = Ext.getCmp('PatrolCheckListPanel2').getSelectionModel();
Ext.Array.forEach(AllSelectedRecords, function (item) {
for (var i = 0; i < records.length; i++) {
var record = records[i];
if (record.get("device_id") == item) {
selModel.select(record, true, true); //选中record,并且保持现有的选择,不触发选中事件
}
}
});
// sm1.addListener('deselect',deselect_fun);
initflag = false;
}
},
proxy: {
type: 'ajax',
url: baseUrl + 'iot/inspectionpoints/getSbList',
reader: {
type: 'json',
root: 'RESULT',
totalProperty: 'totalCount'
},
extraParams: {
queryJson: Ext.JSON.encode(queryJson)
}
},
remoteSort: true
});
myStore2.on('load', function (myStore2, record) {
for (var i = 0; i < record.length; i++) {
var records = record[i];
if (records.get('pd') == 1) {
Ext.getCmp('PatrolCheckListPanel2').getSelectionModel().select(records, true);
}
};
});
var myStore3 = Ext.create('Ext.data.Store', {
model: 'patrolpoint2',
pageSize: 5,
listeners: {
beforeload: function (me, store, operation, eOpts) {
initflag1 = true;
},
load: function (me, records, success, opts) {
if (!success || !records || records.length == 0)
return;
//根据全局的选择,初始化选中的列
var selModel = Ext.getCmp('PatrolCheckListPanel3').getSelectionModel();
Ext.Array.forEach(AllSelectedRecords1, function (item) {
for (var i = 0; i < records.length; i++) {
var record = records[i];
if (record.get("device_id") == item && record.get('pd') != 1) {
selModel.select(record, true, true); //选中record,并且保持现有的选择,不触发选中事件
}
}
});
initflag1 = false;
}
},
proxy: {
type: 'ajax',
url: baseUrl + 'iot/inspectionpoints/getSbList',
reader: {
type: 'json',
root: 'RESULT',
totalProperty: 'totalCount'
},
extraParams: {
queryJson: Ext.JSON.encode(queryJson)
}
},
remoteSort: true
});
myStore3.on('load', function (myStore3, record) {
for (var i = 0; i < record.length; i++) {
var records = record[i];
var len = AllSelectedRecords1.length;
for (var j = 0; j < len; j++) {
if (AllSelectedRecords1[j] == records.get('device_id')) {
Ext.getCmp('PatrolCheckListPanel3').getSelectionModel().select(records, true);
}
}
};
});
var clear_modify_form = function () {
Ext.getCmp('fm_patrol_spot_name').setValue("");
Ext.getCmp('fm_patrol_company_code').setValue("");
Ext.getCmp('fm_patrol_spot_address').setValue("");
Ext.getCmp('fm_patrol_spot_type').setValue(false);
Ext.getCmp('fm_patrol_point_message').setValue("");
Ext.getCmp('fm_patrol_point_id').setValue("");
Ext.getCmp('PatrolpointListPanel').getStore().reload();
}
var patrolUploadForm = Ext.create('Ext.form.Panel', {
id: 'patrolUploadForm',
labelWidth: 55,
url: baseUrl + 'iot/inspectionpoints/update1',
bodyPadding: 15,
frame: true,
labelAlign: 'left',
region: 'north',
enableDrop: true,
ddGroup: 'treeID',
height: 200,
items: [{
autoHeight: true,
layout: 'column',
border: false,
items: [{
columnWidth: .45,
xtype: 'fieldset',
layout: 'form',
// defaults: {anchor: '95%'},
style: 'margin-left: 5px;padding-left: 5px;border:0px solid #B5B8C8!important;',
items: [
{
xtype: 'textfield',
fieldLabel: '点位名称',
id: 'fm_patrol_spot_name',
name: 'spot_name',
maxLength: 20,
maxLengthText: '长度不得超出{0}',
anchor: '50%'
}, {
fieldLabel: '所属建筑/项目',
id: 'fm_patrol_company_code',
name: 'company_code',
xtype: 'combo',
store: getManufacturerId2,
displayField: 'building_name',
valueField: 'building_id',
editable: false,
anchor: '50%'
}, {
xtype: 'textfield',
fieldLabel: '点位地址',
id: 'fm_patrol_spot_address',
name: 'spot_address',
maxLength: 30,
maxLengthText: '长度不得超出{0}',
anchor: '50%'
}]
}, {
columnWidth: .55,
xtype: 'fieldset',
layout: 'form',
// defaults: {anchor: '95%'},
style: 'margin-left: 5px;padding-left: 5px;border:0px solid #B5B8C8!important;',
items: [
{
xtype: 'textareafield',
grow: true,
height: 60,
id: 'fm_patrol_point_message',
name: 'message',
fieldLabel: '备注',
anchor: '50%'
}, {
xtype: 'checkboxgroup',
fieldLabel: '设备类型',
// defaultType:'radiofield',
columns: 3,
id: "fm_patrol_spot_type",
// defaults:{
// flex:1
// },
// layout:'hbox',
items: [
{ boxLabel: '水系统', name: 'fm_patrol_water_type', inputValue: "1", id: 'radio81' },
{ boxLabel: '火系统', name: 'fm_patrol_fire_type', inputValue: "2", id: 'radio82' },
{ boxLabel: '电气火灾', name: 'fm_patrol_efire_type', inputValue: "3", id: 'radio83' },
{ boxLabel: '气体灭火', name: 'fm_patrol_extinguishing_type', inputValue: "4", id: 'radio84' },
{ boxLabel: 'RTU', name: 'fm_patrol_rtu_type', inputValue: "5", id: 'radio85' },
{ boxLabel: '视频监控', name: 'fm_patrol_view_type', inputValue: "6", id: 'radio86' },
{ boxLabel: '其他', name: 'fm_patrol_other_type', inputValue: "7", id: 'radio87' },
]
}, {
xtype: 'textfield',
id: 'fm_patrol_point_queryJson',
name: 'queryJson',
hidden: true
}, {
xtype: 'textfield',
name: 'uploadURL',
id: 'patrol_point_uploadURL',
hidden: true
}, {
xtype: 'textfield',
id: 'fm_patrol_point_id',
name: 'id',
hidden: true
}
]
}
]
}]
});
var patroladdForm = Ext.create('Ext.form.Panel', {
id: 'patroladdForm',
labelWidth: 55,
url: baseUrl + 'iot/inspectionpoints/append1',
bodyPadding: 15,
frame: true,
labelAlign: 'left',
region: 'north',
enableDrop: true,
ddGroup: 'treeID',
height: 200,
items: [{
autoHeight: true,
layout: 'column',
border: false,
items: [{
columnWidth: .45,
xtype: 'fieldset',
layout: 'form',
// defaults: {anchor: '95%'},
style: 'margin-left: 5px;padding-left: 5px;border:0px solid #B5B8C8!important;',
items: [
{
xtype: 'textfield',
fieldLabel: '点位名称',
id: 'fa_patrol_spot_name',
name: 'spot_name',
maxLength: 20,
maxLengthText: '长度不得超出{0}',
anchor: '50%',
listeners: {
change: function (o, e) {
if (e.length > 20) {
Ext.getCmp('fa_patrol_spot_name').setValue(e.substring(0, 20));
}
}
}
}, {
fieldLabel: '所属建筑/项目',
id: 'fa_patrol_company_code',
name: 'company_code',
xtype: 'combo',
store: getManufacturerId2,
displayField: 'building_name',
valueField: 'building_id',
editable: false,
anchor: '50%',
listeners: {
select: function (combo, record, index) {
try {
var label = this.value;
var query = new Object();
query.building_id = label;
query.V_LOGINNAME = V_LOGINNAME;
// query.V_PASSWORD = V_PASSWORD;
var jsonstr = Ext.JSON.encode(query);
myStore2.getProxy().extraParams = {
queryJson: jsonstr
};
Ext.getCmp('PatrolCheckListPageToolbar2').moveFirst();
}
catch (ex) {
Ext.MessageBox.alert("错误", "数据加载失败。");
}
}
}
}, {
xtype: 'textfield',
fieldLabel: '点位地址',
id: 'fa_patrol_spot_address',
name: 'spot_address',
maxLength: 30,
maxLengthText: '长度不得超出{0}',
anchor: '50%',
listeners: {
change: function (o, e) {
if (e.length > 30) {
Ext.getCmp('fa_patrol_spot_address').setValue(e.substring(0, 30));
}
}
}
}]
}, {
columnWidth: .55,
xtype: 'fieldset',
layout: 'form',
// defaults: {anchor: '95%'},
style: 'margin-left: 5px;padding-left: 5px;border:0px solid #B5B8C8!important;',
items: [
{
xtype: 'textareafield',
grow: true,
height: 60,
id: 'fa_patrol_point_message',
name: 'message',
fieldLabel: '备注',
anchor: '50%'
}, {
xtype: 'checkboxgroup',
fieldLabel: '设备类型',
// defaultType:'radiofield',
columns: 3,
id: "fa_patrol_spot_type",
// defaults:{
// flex:1
// },
// layout:'hbox',
items: [
{ boxLabel: '水系统', name: 'fa_patrol_water_type', inputValue: "1", id: 'radio88' },
{ boxLabel: '火系统', name: 'fa_patrol_fire_type', inputValue: "2", id: 'radio89' },
{ boxLabel: '电气火灾', name: 'fa_patrol_efire_type', inputValue: "3", id: 'radio90' },
{ boxLabel: '气体灭火', name: 'fa_patrol_extinguishing_type', inputValue: "4", id: 'radio91' },
{ boxLabel: 'RTU', name: 'fa_patrol_rtu_type', inputValue: "5", id: 'radio92' },
{ boxLabel: '视频监控', name: 'fa_patrol_view_type', inputValue: "6", id: 'radio93' },
{ boxLabel: '其他', name: 'fa_patrol_other_type', inputValue: "7", id: 'radio94' },
]
}, {
xtype: 'textfield',
id: 'fa_patrol_point_queryJson',
name: 'queryJson',
hidden: true
}, {
xtype: 'textfield',
name: 'addURL',
id: 'patrol_point_addURL',
hidden: true
}
]
}
]
}]
});
var upload_pic = function () {
Ext.create('Ext.window.Window', {
id: 'patrol_point_pic_win1',
title: '图片上传',
height: 200,
width: 300,
layout: 'fit',
modal: true,
buttons: [
{
text: '关闭',
handler: function () {
Ext.getCmp('patrol_point_pic_win1').destroy();
}
}
],
closeAction: 'destroy',
html: ''
}).show();
}
var patroladUploadForm = Ext.create('Ext.form.Panel', {
id: 'patroladUploadForm',
layout: 'form',
// title:'设备图片:',
items: [{
layout: 'hbox',
items: [{
xtype: 'box',//或者xtype: 'component',
title: '点位图片',
id: 'patrol_upload_picture',
width: 110,//图片宽度
height: 110,//图片高度
margin: '0 0 30 150',
autoEl: {
tag: 'img',//指定为img标签
src: '../../res/img/common/shangchaun.png',
style: 'filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=scale);width:110px;height:110px;text-align:center;'
},
listeners: {
render: function () {
Ext.fly(this.el).on("click", function () {
// upload_pic();
checkfilename2();
});
}
}
}
]
}]
});
var patroladaddForm = Ext.create('Ext.form.Panel', {
id: 'patroladaddForm',
layout: 'form',
// title:'设备图片:',
items: [{
layout: 'hbox',
items: [{
xtype: 'box',//或者xtype: 'component',
title: '点位图片',
id: 'patrol_add_picture',
width: 110,//图片宽度
height: 110,//图片高度
margin: '0 0 30 150',
autoEl: {
tag: 'img',//指定为img标签
src: '../../res/img/common/shangchaun.png',
style: 'filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(sizingMethod=scale);width:110px;height:110px;text-align:center;'
},
listeners: {
render: function () {
Ext.fly(this.el).on("click", function () {
// add_pic();
checkfilename();
});
}
}
}
]
}]
});
var MaintenanceCheckPanel2 = Ext.create('Ext.grid.Panel', {
header: {
height: 0,
border: '0px solid #000000'
},
id: 'PatrolCheckListPanel2',
store: myStore2,
selModel: sm1,
columns: [
{ header: '设备编号', dataIndex: 'device_id', hidden: true, menuDisabled: true },
{ header: '序号', dataIndex: 'xh', width: 58, align: 'center', menuDisabled: true },
{ header: '设备名称', dataIndex: 'device_name', width: 247, align: 'center', menuDisabled: true },
{ header: '设备地址', dataIndex: 'unitinfo', width: 246, align: 'center', menuDisabled: true },
{
text: '设备详情',
xtype: 'actioncolumn',
width: 210,
sortable: false,
align: 'center',
menuDisabled: true,
items: [{
icon: '../../res/img/common/tupianbtn.png',
tooltip: '设备详情',
handler: function (grid, rowIndex, colIndex) {
var rec = grid.getStore().getAt(rowIndex);
// alert(rec.get("dwid"));
editMaintenance(rec.get("dwid"));
}
}]
}
],
columnLines: true,
height: 195,
width: 785,
bbar: new Ext.PagingToolbar({
store: myStore2,
id: 'PatrolCheckListPageToolbar2',
displayInfo: true,
pageSize: 5,
prependButtons: true,
displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
emptyMsg: "没有记录",
firstText: '第一页',
prevText: '前一页',
nextText: '后一页',
lastText: '最后一页',
refreshText: '刷新',
}),
// frame: true,
border: false,
iconCls: 'icon-grid'
});
var MaintenanceCheckPanel3 = Ext.create('Ext.grid.Panel', {
header: {
height: 0,
border: '0px solid #000000'
},
id: 'PatrolCheckListPanel3',
store: myStore3,
selModel: sm2,
columns: [
{ header: '判断', dataIndex: 'pd', hidden: true, menuDisabled: true },
{ header: '设备编号', dataIndex: 'device_id', hidden: true, menuDisabled: true },
{ header: '序号', dataIndex: 'xh', width: 58, align: 'center', menuDisabled: true },
{ header: '设备名称', dataIndex: 'device_name', width: 247, align: 'center', menuDisabled: true },
{ header: '设备地址', dataIndex: 'unitinfo', width: 246, align: 'center', menuDisabled: true },
{
text: '设备详情',
xtype: 'actioncolumn',
width: 210,
sortable: false,
align: 'center',
menuDisabled: true,
items: [{
icon: '../../res/img/common/tupianbtn.png',
tooltip: '设备详情',
handler: function (grid, rowIndex, colIndex) {
var rec = grid.getStore().getAt(rowIndex);
// alert(rec.get("dwid"));
editMaintenance(rec.get("dwid"));
}
}]
}
],
columnLines: true,
height: 195,
width: 785,
bbar: new Ext.PagingToolbar({
store: myStore3,
id: 'PatrolCheckListPageToolbar3',
displayInfo: true,
pageSize: 5,
prependButtons: true,
displayMsg: '显示第 {0}条到 {1}条记录,总共 {2}条',
emptyMsg: "没有记录",
firstText: '第一页',
prevText: '前一页',
nextText: '后一页',
lastText: '最后一页',
refreshText: '刷新',
}),
// frame: true,
border: false,
iconCls: 'icon-grid'
});
function public_update() {
var patrol_point_uploadURL = Ext.getCmp('patrol_point_uploadURL').getValue();
var fm_patrol_spot_name = Ext.getCmp('fm_patrol_spot_name').getValue();
var fm_patrol_company_code = Ext.getCmp('fm_patrol_company_code').getValue();
var fm_patrol_spot_address = Ext.getCmp('fm_patrol_spot_address').getValue();
var fm_patrol_spot_type = Ext.getCmp('fm_patrol_spot_type').getChecked();
var spot_type = '';
Ext.Array.each(fm_patrol_spot_type, function (item) {
spot_type += item.inputValue + ',';
});
var fm_patrol_point_message = Ext.getCmp('fm_patrol_point_message').getValue();
var fm_patrol_point_id = Ext.getCmp('fm_patrol_point_id').getValue();
var query = new Object();
if (AllSelectedRecords1.length == 1) {
query.equipment_code = AllSelectedRecords1[0];
} else {
if (AllSelectedRecords1.length > 1) {
var spot_id = null;
// var selected = sm1.getSelection( );
for (var i = 0; i < AllSelectedRecords1.length; i++) {
if (i == 0)
spot_id = AllSelectedRecords1[i];
else
spot_id += "," + AllSelectedRecords1[i];
}
query.equipment_code = spot_id;
}
}
query.id = fm_patrol_point_id;
query.spot_name = fm_patrol_spot_name;
query.company_code = fm_patrol_company_code;
query.spot_address = fm_patrol_spot_address;
// query.equipment_code = fm_patrol_equipment_code;
query.spot_type = spot_type;
query.remarks = fm_patrol_point_message;
query.picture_route = patrol_point_uploadURL;
query.V_LOGINNAME = V_LOGINNAME;
// query.V_PASSWORD = V_PASSWORD;
var jsonstr = Ext.JSON.encode(query);
Ext.getCmp('fm_patrol_point_queryJson').setValue(jsonstr);
Ext.getCmp('patrolUploadForm').submit({
success: function (form, action) {
// uploadPop.hide();
Ext.getCmp('patrol_upload_picture').getEl().dom.src = '../../res/img/common/shangchaun.png';
Ext.getCmp('patrolUploadForm').getForm().reset();
Ext.getCmp('patroladUploadForm').getForm().reset();
// uploadPanel.getStore().reload();
Ext.Msg.alert('系统提示', '保存成功!');
clear_modify_form();
},
failure: function (form, action) {
Ext.Msg.alert('系统提示', '保存失败!');
clear_modify_form();
}
});
this.up('window').hide();
}
var patroluploadWin = Ext.create('Ext.window.Window', {
id: 'patroluploadWin',
title: '