
shr.defineClass("shr.empContract.ContractSignBizBillEditExt", shr.empContract.ContractSignBizBillEdit, {
	
	initalizeDOM : function () {
		var _self = this;
		shr.empContract.ContractSignBizBillEditExt.superClass.initalizeDOM.call(this);
		if(this.getOperateState() == 'ADDNEW'){
			_self.defaultInitalize();
		}
	},
	
	//页面初始化默认值
	defaultInitalize:function(){
		var _self = this;
		// //甲方劳动合同主体
		// $("#labContractFirstParty").shrPromptBox("setValue", {id:"bHdk2ak5RIyQIAgXzXz/wo6rEMM=", name:"Guangdong Technion Israel Institute of Technology"});
		// //合同协议
		// $("#entrys_contractType").shrPromptBox("setValue", {id:"7+QjmiuXSxuwbKgpeF9PhAUpjB4=", name:"Contract"});
		// var contractType = this.getFieldValue('entrys_contractType');
		// $("#entrys_contractTemplet").shrPromptBox("setFilter","contractType.id in ('" + contractType + "')");
		// $("#entrys_contractTemplet").shrPromptBox("setValue", {id:"ofhR22QdTR2yHfI15gz+oZukBmM=", name:"Labor Contract"});

        _self.remoteCall({
            method: "getDefaultContractParty",
            param: {}, 
            async: false,
            success: function(response) {
                if(response.contractPartyId){
                    var responseObejct = {id: response.contractPartyId,name: response.contractPartyName};
                    $("#labContractFirstParty").shrPromptBox("setValue", responseObejct);
                }
            },
            error : function(){
                
            }
        });

     //    _self.remoteCall({
     //        method: "getDefaultContractType",
     //        param: {}, 
     //        async: false,
     //        success: function(response) {
     //            if(response.contractTypeId){
     //                var responseObejct = {id: response.contractTypeId,name: response.contractTypeName};
     //                $("#entrys_contractType").shrPromptBox("setValue", responseObejct);
					// $("#entrys_contractTemplet").shrPromptBox("setFilter","contractType.id = '" + response.contractTypeId + "'");
     //            }
     //        },
     //        error : function(){
                
     //        }
     //    });

	}
	
	
});