This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI().use( | |
"console", | |
"file1", | |
"file2", | |
function (Y) { | |
// I'm a callback that runs as soon as all dependencies are loaded | |
} | |
); | |
YUI.add( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI().use( | |
"console", | |
"ep-ui-builder", | |
function (Y) { | |
Y.on( | |
"domready", | |
function () { | |
Y.log("index - building UI"); | |
try { | |
Y.EP.UI.Build (); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_uiSetSuppliers: function (value, src) { | |
Y.log(Clazz.NAME + "::_uiSetSuppliers"); | |
if (this._supplierSelectNode) { | |
this._supplierSelectNode.empty(); | |
this._supplierSelectNode.append('<option value="">' + this.get("strings").choose_one_option_label + '</option>'); | |
if (this.get("suppliers")) { | |
this.get("suppliers").each( | |
function (supplier) { | |
this.append('<option value="' + supplier.get("id") + '">' + supplier.get("display_label") + '</option>'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var selected_date = e.newSelection[0]; | |
var selected_month = selected_date.getMonth(); | |
this._calendarNavGoToDateMonthSelectNode.set("selectedIndex", selected_month); | |
var selected_day = selected_date.getDate(); | |
this._calendarNavGoToDateDaySelectNode.set("selectedIndex", selected_day - 1); | |
var selected_year = String(selected_date.getFullYear()); | |
this._calendarNavGoToDateYearSelectNode.all("option").each( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use Data::Dumper; | |
use DBI; | |
use HTML::DOM; | |
my $dbh = DBI->connect( | |
'dbi:mysql:dbname=...;host=localhost;sslmode=disable', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI.add( | |
"ep-w-work_entry-base", | |
function (Y) { | |
var UI = Y.Widget.UI_SRC; | |
var MODE = "Mode"; | |
var STATUS = "Status"; | |
var WC_AC_SOURCE = "WorkChart/ac?"; | |
var Clazz = Y.namespace("EP.W.WorkEntry").Base = Y.Base.create( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
YUI.add( | |
"ep-w-work_entry-duration-base", | |
function (Y) { | |
var Clazz = Y.namespace("EP.W.WorkEntry.Duration").Base = Y.Base.create( | |
"ep-w-work_entry-duration-base", | |
Y.Widget, | |
[ Y.MakeNode, Y.IC.ModelConsumer ], | |
{ | |
BOUNDING_TEMPLATE: '<tr></tr>', | |
CONTENT_TEMPLATE: null, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sub get_subtree { | |
my ($self, %opt) = @_; | |
my (@load, %referents, @top_nodes, @tree, %map, $db, $nodes); | |
$nodes = delete $opt{work_chart_nodes}; | |
$db = $opt{db} || $self->init_db; | |
%map = map { | |
$_->db( undef ); | |
$_->children( [] ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{? {n @ model @ id} {n @ model @ id} "<select class={c supplierSelect}><option value=>{s choose_one_option_label}</option></select>"} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// use as follows (can be combined) | |
{ | |
ATTRS: { | |
total: { value: 0, toJSON: false }, | |
lines: { value: null, setter: '_setML', mlClass: Y.App.Manage.ML.Lines } | |
} | |
} | |
// base class definition |