  Ext.onReady(function(){
	 var parseParam = function(obj){
				var paramStr = "";
				for(var key in obj) {
					var val = obj[key];
					paramStr += '&' + key + '=' + val;
				}
			   return paramStr.substr(1);
	   };
	   var requestResourceScan = function(url){
		    var body = document.getElementsByTagName('body')[0];
		    var script = document.createElement('script');
		    script.src = url;
		    script.type = 'text/javascript';
		    body.appendChild(script);
	   };
	   
	   var parseObjectIds = function (attachments){
		   var objectIds = [];
		   for(var i = 0; i < attachments.length; i++){
			   var item = attachments[i];
			  var objectId =  item.property && item.property.objectid;
			  objectId &&  objectIds.push(objectId);
		   }
		   return objectIds;
	   };

	  try{
		  var logFid = [1467,1845,47988,2780,11182,4336,187,4274,1660,4237,6832,7838,2840,2021,11252,33485,16278,4335,31689];
		  var fid = resourceScanParam.fid;
		  var noterya = resourceScanParam.noterya;
		  if(!noterya){
			  return;
		  }
		  if(!fid || !Ext.Array.contains(logFid,parseInt(fid))){
			  return;
		  }
		  var uid = getCookie('UID');
		  resourceScanParam.uid = uid;
		  var data = parseObjectIds(attachments);
		  if(data.length == 0){
			  return;
		  }
		  var dataAray = [];
		  var dataLength = data.length;
		  var slicenNum = dataLength / 50;
		  if(slicenNum > 0){
			  for(var i = 0; i < slicenNum; i++ ){
				  var slice = data.slice(dataLength * i / slicenNum , dataLength * (i + 1) / slicenNum);
				  dataAray.push(slice);
			  }
		  }else{
			  dataAray.push(data);
		 }
		  //PM：383785 取消推送
/*		for(var i = 0;i < dataAray.length; i++ ){
		  resourceScanParam.data = dataAray[i].join(',');
		  var url  = location.protocol + '//fanyazyk2.chaoxing.com/resource/api/getDataLookNum';
		  url = url + '?_=' + Math.random()  + '&' + parseParam(resourceScanParam);
		  requestResourceScan(url);
		}*/
	 }catch(er){}
});