use strict;return sub{my $this = shift;my $C = $this->{C};$this->out("<script language=\"JavaScript\">\n	$C->{PGatesAddonFieldsJsArray}\n	function jinOnChangePGateSel()\n	{\n		var pgateSel = document.getElementById(\'pgate\');\n		var pgate_id = pgateSel.options[pgateSel.selectedIndex].value;\n		\n		var DivPgateAddon = document.getElementById(\'DivPgateAddon\');\n		if (PGatesAddonFields[\"pg\" + pgate_id])\n		{\n			DivPgateAddon.innerHTML = PGatesAddonFields[\"pg\" + pgate_id];\n			DivPgateAddon.display = \'\';\n		}\n		else\n		{\n			DivPgateAddon.innerHTML = \'\';\n			DivPgateAddon.display = \'none\';\n		}\n		\n		return;\n	}\n</script>\n");}