function WriteSidePanel()
{
	var strHTML='';
	
	strHTML+=m_objMqButton.GetTextButtonHTML("MassUpdate", g_MqRef.RESX['SL.CHECKOUT_MULTIPLE'], "OpenScanMultipleAssets()", "", 65, "", "", 150);

	strHTML+=m_objMqButton.GetTextButtonHTML("ExchangeAssets", g_MqRef.RESX['SL.EXCHANGE_ASSETS'], "OpenExchangeAssets()", "", 65, "padding-bottom:50px;", "", 150);

	if(parent.UserHasAccessToView(85, parent.m_strValidViewIDs)){
		strHTML+=m_objMqButton.GetTextButtonHTML("EmployeeAssets", g_MqRef.RESX['BUTTON_MANAGE_EMPLOYEE_ASSETS'], "parent.LoadView('View=Users%26Contacts%2FEmployeeAssets')", "", 65, "", "", 150, "HTMLTextButtonNavLink", "TextButtonNavLink");
	}
	document.write(strHTML);
}


function EditResInfo(lngID)
{
	var strTrackAs=GetGridValue("Track_As_", lngID);

	if(strTrackAs==g_MqRef.RESX['CV.TRACK_AS_BULK']){
		//bulk
		var strTrackAs=GetGridValue("Track_As_", lngID);
		var strAssetClass=GetGridValue("Asset_Class_", lngID);
		var strAssetType=GetGridValue("Asset_Type_", lngID);
		var strAssetName=GetGridValue("Asset_Name_", lngID);
		var strAllocationUnits=GetGridValue("Allocation_Units_", lngID);
		var strVals="1092=" + g_MqRef.MqStr.MqEncodeURIComponent(strAssetClass) + 
					"&1093=" + g_MqRef.MqStr.MqEncodeURIComponent(strAssetType) + 
					"&30=" + g_MqRef.MqStr.MqEncodeURIComponent(strAssetName + " " + g_MqRef.RESX['BULK_ASSET_INSTANCE_POSTFIX']) +
					"&1111=" + g_MqRef.MqStr.MqEncodeURIComponent(strAllocationUnits) + "&993=1&1110=" + lngID;
		var strType="&txtPostData=" + g_MqRef.MqStr.MqEncodeURIComponent(strVals);
		parent.OpenModalWindow(parent.GetVDURL(parent.g_VWS.URL().BaseVDName(), "View=Resources%2FConsumable" + strType), 1440, 900, true);
	}else{
		parent.LoadRecord(lngID, -1, false);
	}
}

function GetGridValue(strTag, lngID)
{
	var strValue="";
	var objCell=document.getElementById(strTag+lngID);
	if(objCell){
		strValue=objCell.innerHTML;
	}
	return strValue;
}

function OpenScanMultipleAssets()
{
	parent.OpenModalWindow("TmplCheckoutMultiple.htm", 1000, 700, false);
}

function OpenExchangeAssets()
{
	parent.OpenModalWindow("tmplExchangeAssets.htm", 600, 350, false);
}