basically, everything but the row wrapper, the main label, and the errors template
generic/row.tt will handle those
brianfreud
ok, you will also need to be able to pass object, too, to row.tt
else you have no intelligence
so [%- INCLUDE 'forms/generic/row.tt' field=form.field('artist_$i')label=l('Artist') object="artist_$i" type='switchable' %]
aCiD2
that's no problem, that will cascade down just fine
doesn't need any changes
the_p has quit
brianfreud
ok, moved that bit to widget/switch.tt, and changed tracks.tt to ^^
how now does row.tt know to use switch.tt ?
aCiD2
pass type='switch'
but, as switch.tt includes some input.tt templates, those will also need a type given, or you'll end recursivly creating switch.tt's
you already do that on the checkbox, but line 13 needs type='text' on it
aCiD2 goes to make dinner
outsidecontext joined the channel
ruaok returns with brekky
brianfreud enjoys pre-work coffee
outsidecontext enjoys an after-work whyskey
ruaok
amazing how we're never on the same page, but still get shit done. :)
some of us are always drunk while the others are toiling at work. so odd.
brianfreud
ruaok: btw, having learned from our experiences in the past, btw, every single bit of js I write is getting documented as to exactly how to use / implement it :)
stubs was just to much a pita to make work :P
Muz
ruaok: always drunk you say? I'll get right on it!
luks: thanks. Even though it's called ArtistSelect(), does it also now do the label lookup?
luks
yeah
brianfreud
k
luks
it will need the server side to be written, too
brianfreud
the JSON server?
luks
this script uses a different format than the current one, but since it doesn't exist in TT yet it shouldn't be a problem
yeah, the script that gives you search results in json
brianfreud
k. We actually have another need for data to be fed out with JSON too. I don't really know anything about the server end for JSON, not sure if both can be fed out from the same server, or if "server" is even really the right terminology.
luks
it's just a regular page, but instead of html it will return json
brianfreud
ah, like the languages list page?
hmm, wonder if a JSON page can be templated then?
gettext for javascript uses JSON results to pass l() translations to js code
luks
no, there are modules to generate JSON for you from a perl object
you can use templates for that, but I don't see why
brianfreud
like I say, I know nothing (yet) about the server side for JSON - only that gettext and your lookup both need JSON results to be fed in for them towork
luks
hm, right, translating JS will be more fun
brianfreud
there's a JQuery plugin for it, made sure of that a week ago.
I need to find a GF like that. I'd be proud to be her BF.
luks
brianfreud: my code uses $.getJSON
I'll take a look what does the gettext plusin uses eval instead
brianfreud considers messing with the gettext plugin to de-eval it
brianfreud
too bad such a useful function has to be so dangerous, by nature
luks
I don't find it useful :)
in fact, I was never in a situation when I needed to use eval in any language
hm, actually that's a lie, I used it once in python:)
brianfreud
I've managed in a non-framework manner to avoid using it before, but you can end up doing cartwheels (I did, at least) trying to do what you need, and only what you need, for JSON feeds that tend to send WAY too much info back
ruaok
how about DB transactions in perl?
pretty much need to use eval for that...
luks
well, I mean different kind of eval
eval { } is the only way to catch errors in perl
ruaok
ok
luks
I meant eval with a string variable
ruaok nods
brianfreud specifically thinking of the early JSON implementation for FreeBase
brianfreud
oh fun, more snow coming down hard again
hmm, ok, a script file with a comment like this must be high on the list to port: /* TODO: remove this function */ :D
aCiD2
brianfreud: gonna merge now, that sound good?
luks
such TODO usually means the function can't be simply removed, because other code depends on it :)
brianfreud
sure - you merging pronik's patches from yesterday too?
aCiD2
brianfreud: somewhere in the perl it says "Delete this when we use a real database" that makes me chuckle
brianfreud: if you've merged them into your branch, then yes, probably :P
brianfreud
luks: yes... hence why, whenever possible, I'm throwing out old stuff, as a lot of it just fixed things other things broke.
in this particular case, movefocus.js fixed one thing... and broke Opera anyhow
chefkoch joined the channel
Kerensky97 joined the channel
YAY! :)
aCiD2
what's the yay about?
brianfreud
Been talking with Neil via email... he just did a quick code audit and relicensed Diff Match and Patch as LGPL 2.1 (as opposed to Diff_Match_Patch, which is identical, but remains Apache 2.0)
CatCat totally wants to see top contributors and cost per hit/ws hit type spot, that was really interesting
CatCat
brianfreud: huh?
neil who?
brianfreud
Fraser - the guy who now works for Google, and who wrote the js diff engine that's a ton better (and faster) than the one by John Resig which we were using
aCiD2
I don't think git is really working out how it should be because of git-svn :(
i just tried to merge your branch, and even bits where there's no conflict, git thinks are conflicts