$package("itsm.request")
/**  
 * @fileOverview 请求任务主函数
 * @author tan
 * @version 1.0  
 */  
 /**  
 * @author tan  
 * @constructor 请求任务主函数
 * @description 请求任务主函数
 * @date 2011-05-09
 * @since version 1.0 
 */
$import("itsm.security.userUtil");

itsm.request.requestTask = function() 
{
	return {
//		requestEventTask = new eventTask();
//		requestEventTask.selectEventTask(function(eventTypeId, taskId, title){
//			$('#'+eventTypeId+'_costTaskId').val(taskId);
//			$('#'+eventTypeId+'_costEventTaskTitle').val(title);
//			$('#'+eventTypeId+'_relatedEventTaskGrid_win').window('close');
//		})
		/**
		 * @description 保存
		 */
		saveEventTask:function(){
			var et=new eventTask($('#requestDetails_requestNo').val(),'request');
			et.saveEventTask_opt();
		},
		
		/**
		 * @description 新增
		 */
		addEventTask:function(){
			
			var et=new eventTask($('#requestDetails_requestNo').val(),'request');
			et.addEventTask_win();
		},
		
		/**
		 * @description 编辑
		 */
		editEventTask:function(){
			var et=new eventTask($('#requestDetails_requestNo').val(),'request');
			et.editEventTask_aff();
		},
		/**
		 * @description 删除
		 */
		deleteEventTask:function(){
			var et=new eventTask($('#requestDetails_requestNo').val(),'request');
			et.deleteEventTask_aff();
		},
		/**
		 * 任务负责人.
		 */
		initSelect_addRequestTask:function(){
						
			itsm.security.userUtil.selectUser('#requestEdit_addTask_assigneeName','#requestEdit_addTask_assigneeNo','','loginName');		
		
		},
		
		
		init: function() 
		{
			
		}
	}
}();

$(document).ready(itsm.request.requestTask.init);




