"use strict";var project_allocation=new function(){this.initialized=false;this.FORMCONTAINERNAME="project_allocation";this.FORMNAME=this.FORMCONTAINERNAME+"_form"};project_allocation.init=function(){if(project_allocation.initialized===true){return}project_allocation.initialized=true};project_allocation.open=function(item){dialogMessage.viewBasic(project_allocation.FORMCONTAINERNAME,'<div id="'+project_allocation.FORMCONTAINERNAME+'"><span class="ui-dialog-load ui-corner-all"></span><div>',lang_projectadmin.project_allocation,700,280,"",true);usComm.loadShowWait();openx("projectadmin_project_allocation","get_values",item,project_allocation.FORMCONTAINERNAME)};project_allocation.init_popup=function(){basicForm.initAll();var valSettingsList={errorClass:"errorsmall",ignoreTitle:true};$("#"+project_allocation.FORMNAME).validate(valSettingsList)};project_allocation.save=function(){if($("#"+project_allocation.FORMNAME).valid()){var project_id=$("#project_allocation_project_id").val();var new_company_ids=$("#project_allocation_company_all").val();if(new_company_ids!==null){usComm.loadShowWait(new_company_ids);openx("projectadmin_project_allocation","add_company",project_id,new_company_ids,project_allocation.FORMCONTAINERNAME)}}};project_allocation.remove=function(){if($("#"+project_allocation.FORMNAME).valid()){var project_id=$("#project_allocation_project_id").val();var new_company_ids=$("#project_allocation_company_active").val();if(new_company_ids!==null){usComm.loadShowWait();openx("projectadmin_project_allocation","remove_company",project_id,new_company_ids,project_allocation.FORMCONTAINERNAME)}}};