define(function(require){
	var $ = require('jquery');
	require('uriTemplate')($);
	require('dialog')($);
	require('validation')($);

	var IFA = require('util');
	require('../../../styles/cim/jquery-ui-1.8.14.custom.css');
	require('../../../styles/cim/cim-grid.css');
	$(function(){
		
		$("#import").bind("click",importData);
		$("#bimport").bind("click",bimportData);
		
		var templateInfo=$("#templateInfo").val();
		if(templateInfo!=null &&templateInfo!=""){
			$.msg.alert(i18ns("RateSheet.productPrice.noTemplate"));
		}
		
	});
	

	
	
	
	//导入数据
	function importData(){
		var fileName = $("#selectPath").val().trim();
			if(fileName=="" ||fileName==null){
				$.msg.alert(i18n["RateSheet.productPrice.meage1"]);
				return ;
			}
		
			$("#fileName").val = fileName;
		$("#importFrom").submit();
	}
	
	//导入数据
	function bimportData(){
		$("#importFrom2").submit();
	}
	

	
	

});