directive with templateUrl with function