fixed conflict in version
diff --git a/build.json b/build.json
index 95a38d6..17d38b3 100644
--- a/build.json
+++ b/build.json
@@ -9,6 +9,7 @@
 			"lib/js/wn/require.js",
 			"lib/js/wn/dom.js",
 			"lib/js/wn/page.js",
+			"lib/js/wn/misc/user.js",
 			"lib/js/lib/json2.js",
 			"lib/js/core.js"
 		]
@@ -78,6 +79,7 @@
 			"lib/js/lib/jquery.min.js:concat",
 			"lib/js/lib/history/history.min.js:concat",
 			"lib/js/lib/bootstrap.min.js:concat",
+			"lib/js/lib/sprintf.js",
 			"lib/js/core.min.js:concat",
 			"lib/js/legacy/globals.js",
 			"lib/js/legacy/utils/datatype.js",
@@ -121,6 +123,7 @@
 			"lib/js/legacy/jquery/jquery-ui.min.js:concat",
 			"lib/js/legacy/tiny_mce_33/jquery.tinymce.js:concat",
 			"lib/js/lib/bootstrap.min.js:concat",
+			"lib/js/lib/sprintf.js",
 			"lib/js/core.min.js:concat",
 			"lib/js/legacy/globals.js",
 			"lib/js/legacy/utils/datatype.js",
@@ -175,9 +178,9 @@
 			"lib/js/legacy/app.js",
 			"js/app.js",
 			"erpnext/startup/startup.js",
-			"erpnext/startup/modules.js",
-			"erpnext/startup/toolbar.js",
-			"erpnext/startup/feature_setup.js"
+			"erpnext/startup/js/modules.js",
+			"erpnext/startup/js/toolbar.js",
+			"erpnext/startup/js/feature_setup.js"
 		]
 	}
 	
diff --git a/erpnext/home/page/activity/__init__.py b/erpnext/home/page/activity/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/erpnext/home/page/activity/__init__.py
diff --git a/erpnext/home/page/activity/activity.css b/erpnext/home/page/activity/activity.css
new file mode 100644
index 0000000..f3988b2
--- /dev/null
+++ b/erpnext/home/page/activity/activity.css
@@ -0,0 +1,23 @@
+#activity-list .label {
+	display: inline-block;
+	width: 100px;
+	margin-right: 7px;
+}
+
+#activity-list .label-info {
+	cursor: pointer;
+}
+
+#activity-list .user-info {
+	float: right;
+	color: #777;
+	font-size: 10px;
+}
+
+#activity-list .date-sep {
+	margin-bottom: 11px;
+	padding: 5px 0px;
+	border-bottom: 1px solid #aaa;
+	color: #555;
+	font-size: 10px;
+}
\ No newline at end of file
diff --git a/erpnext/home/page/activity/activity.html b/erpnext/home/page/activity/activity.html
new file mode 100644
index 0000000..b348d95
--- /dev/null
+++ b/erpnext/home/page/activity/activity.html
@@ -0,0 +1,6 @@
+<div class="layout-wrapper">
+	<a class="close" onclick="window.history.back();">&times;</a>
+	<h1>Activity</h1>
+	<div id="activity-list">
+	</div>
+</div>
\ No newline at end of file
diff --git a/erpnext/home/page/activity/activity.js b/erpnext/home/page/activity/activity.js
new file mode 100644
index 0000000..7dbf476
--- /dev/null
+++ b/erpnext/home/page/activity/activity.js
@@ -0,0 +1,61 @@
+wn.pages['activity'].onload = function(wrapper) {
+	var list = new wn.widgets.Listing({
+		method: 'home.page.activity.activity.get_feed',
+		parent: $('#activity-list'),
+		render_row: function(row, data) {
+			new erpnext.ActivityFeed(row, data);
+		}
+	});
+	list.run();
+}
+
+erpnext.last_feed_date = false;
+erpnext.ActivityFeed = Class.extend({
+	init: function(row, data) {
+		this.scrub_data(data);
+		this.add_date_separator(row, data);
+		$(row).append(sprintf('<span %(onclick)s\
+			class="label %(add_class)s">%(feed_type)s</span>\
+			%(link)s %(subject)s <span class="user-info">%(by)s</span>', data));
+	},
+	scrub_data: function(data) {
+		data.by = wn.user_info(data.owner).fullname;
+		
+		// feedtype
+		if(!data.feed_type) {
+			data.feed_type = get_doctype_label(data.doc_type);
+			data.add_class = "label-info";
+			data.onclick = repl('onclick="window.location.href=\'#!List/%(feed_type)s\';"', data)
+		}
+		
+		// color for comment
+		if(data.feed_type=='Comment') {
+			data.add_class = "label-important";
+		}
+		
+		if(data.feed_type=='Assignment') {
+			data.add_class = "label-warning";
+		}
+		
+		// link
+		if(data.doc_name && data.feed_type!='Login') {
+			data.link = repl('<a href="#!Form/%(doc_type)s/%(doc_name)s">%(doc_name)s</a>', data)
+		}
+	},
+	add_date_separator: function(row, data) {
+		var date = dateutil.str_to_obj(data.modified);
+		var last = erpnext.last_feed_date;
+		
+		if((last && dateutil.get_diff(last, date)>1) || (!last)) {
+			var pdate = dateutil.comment_when(date);
+			var diff = dateutil.get_diff(new Date(), date);
+			if(diff < 1) {
+				pdate = 'Today';
+			} else if(diff > 6) {
+				pdate = dateutil.global_date_format(date);
+			}
+			$(row).html(repl('<div class="date-sep">%(date)s</div>', {date: pdate}));
+		}
+		erpnext.last_feed_date = date;
+	}
+})
\ No newline at end of file
diff --git a/erpnext/home/page/activity/activity.py b/erpnext/home/page/activity/activity.py
new file mode 100644
index 0000000..8b8faf3
--- /dev/null
+++ b/erpnext/home/page/activity/activity.py
@@ -0,0 +1,16 @@
+import webnotes
+
+@webnotes.whitelist()
+def get_feed(arg=None):
+	"""get feed"""	
+	return webnotes.conn.sql("""select
+		distinct t1.name, t1.feed_type, t1.doc_type, t1.doc_name, t1.subject, t1.owner,
+		t1.modified
+		from tabFeed t1, tabDocPerm t2
+		where t1.doc_type = t2.parent
+		and t2.role in ('%s')
+		and ifnull(t2.`read`,0) = 1
+		order by t1.modified desc
+		limit %s, %s""" % ("','".join(webnotes.get_roles()), 
+			webnotes.form_dict['limit_start'], webnotes.form_dict['limit_page_length']), 
+			as_dict=1)
\ No newline at end of file
diff --git a/erpnext/home/page/activity/activity.txt b/erpnext/home/page/activity/activity.txt
new file mode 100644
index 0000000..e7f3963
--- /dev/null
+++ b/erpnext/home/page/activity/activity.txt
@@ -0,0 +1,28 @@
+# Page, activity
+[
+
+	# These values are common in all dictionaries
+	{
+		'creation': '2012-02-29 11:59:13',
+		'docstatus': 0,
+		'modified': '2012-02-29 12:11:46',
+		'modified_by': u'Administrator',
+		'owner': u'Administrator'
+	},
+
+	# These values are common for all Page
+	{
+		'doctype': 'Page',
+		'module': u'Home',
+		'name': '__common__',
+		'page_name': u'activity',
+		'standard': u'Yes',
+		'title': u'Activity'
+	},
+
+	# Page, activity
+	{
+		'doctype': 'Page',
+		'name': u'activity'
+	}
+]
\ No newline at end of file
diff --git a/erpnext/home/page/desktop/desktop.js b/erpnext/home/page/desktop/desktop.js
index 63a075c..3aa9049 100644
--- a/erpnext/home/page/desktop/desktop.js
+++ b/erpnext/home/page/desktop/desktop.js
@@ -3,12 +3,12 @@
 erpnext.desktop.gradient = "<style>\
 	.case-%(name)s {\
 		background: %(start)s; /* Old browsers */\
-		background: -moz-radial-gradient(center, ellipse cover,  %(start)s 0%, %(middle)s 44%, %(end)s 100%); /* FF3.6+ */\
-		background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%,%(start)s), color-stop(44%,%(middle)s), color-stop(100%,%(end)s)); /* Chrome,Safari4+ */\
-		background: -webkit-radial-gradient(center, ellipse cover,  %(start)s 0%,%(middle)s 44%,%(end)s 100%); /* Chrome10+,Safari5.1+ */\
-		background: -o-radial-gradient(center, ellipse cover,  %(start)s 0%,%(middle)s 44%,%(end)s 100%); /* Opera 12+ */\
-		background: -ms-radial-gradient(center, ellipse cover,  %(start)s 0%,%(middle)s 44%,%(end)s 100%); /* IE10+ */\
-		background: radial-gradient(center, ellipse cover,  %(start)s 0%,%(middle)s 44%,%(end)s 100%); /* W3C */\
+		background: -moz-radial-gradient(center, ellipse cover,  %(start)s 0%%, %(middle)s 44%%, %(end)s 100%%); /* FF3.6+ */\
+		background: -webkit-gradient(radial, center center, 0px, center center, 100%%, color-stop(0%%,%(start)s), color-stop(44%%,%(middle)s), color-stop(100%%,%(end)s)); /* Chrome,Safari4+ */\
+		background: -webkit-radial-gradient(center, ellipse cover,  %(start)s 0%%,%(middle)s 44%%,%(end)s 100%%); /* Chrome10+,Safari5.1+ */\
+		background: -o-radial-gradient(center, ellipse cover,  %(start)s 0%%,%(middle)s 44%%,%(end)s 100%%); /* Opera 12+ */\
+		background: -ms-radial-gradient(center, ellipse cover,  %(start)s 0%%,%(middle)s 44%%,%(end)s 100%%); /* IE10+ */\
+		background: radial-gradient(center, ellipse cover,  %(start)s 0%%,%(middle)s 44%%,%(end)s 100%%); /* W3C */\
 	}\
 	</style>"
 
@@ -79,7 +79,7 @@
 
 	for(var i in wn.boot.modules_list) {
 		var m = wn.boot.modules_list[i];
-		if(m!='Setup');
+		if(m!='Setup')
 			add_icon(m);
 	}
 
diff --git a/erpnext/home/page/event_updates/complete_registration.js b/erpnext/home/page/event_updates/complete_registration.js
deleted file mode 100644
index 8f7eed3..0000000
--- a/erpnext/home/page/event_updates/complete_registration.js
+++ /dev/null
@@ -1,124 +0,0 @@
-// ERPNext - web based ERP (http://erpnext.com)
-// Copyright (C) 2012 Web Notes Technologies Pvt Ltd
-// 
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation, either version 3 of the License, or
-// (at your option) any later version.
-// 
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-// GNU General Public License for more details.
-// 
-// You should have received a copy of the GNU General Public License
-// along with this program.  If not, see <http://www.gnu.org/licenses/>.
-
-// complete my company registration
-// --------------------------------
-pscript.complete_registration = function(is_complete, profile) {
-	if(is_complete == 'No'){
-		var d = new Dialog(400, 200, "Setup your Account");
-		if(user != 'Administrator'){
-			d.no_cancel(); // Hide close image
-			$('header').toggle(false);
-		}
-
-		d.make_body([
-			['HTML', 'Your Profile Details', '<h4>Your Profile Details</h4>'],
-			['Data', 'First Name'],
-			['Data', 'Last Name'],
-			['HTML', 'Company Details', '<h4>Create your first company</h4>'],
-			['Data','Company Name','Example: Your Company LLC'],
-	  		['Data','Company Abbreviation', 'Example: YC (all your acconts will have this as a suffix)'],
-	  		['Select','Fiscal Year Start Date'],
-	  		['Select','Default Currency'],
-	  		['Button','Save'],
-		]);
-
-		// if company name is set, set the input value
-		// and disable it
-		if(wn.control_panel.company_name) {
-			d.widgets['Company Name'].value = wn.control_panel.company_name;
-			d.widgets['Company Name'].disabled = 1;
-		}
-		
-		if(profile && profile.length>0) {
-			if(profile[0].first_name && profile[0].first_name!='None') {
-				d.widgets['First Name'].value = profile[0].first_name;
-			}
-
-			if(profile[0].last_name && profile[0].last_name!='None') {
-				d.widgets['Last Name'].value = profile[0].last_name;
-			}
-		}
-
-
-		//d.widgets['Save'].disabled = true;	  // disable Save button
-		pscript.make_dialog_field(d);
-
-		// submit details
-		d.widgets['Save'].onclick = function()
-		{
-			d.widgets['Save'].set_working();
-			
-			flag = pscript.validate_fields(d);
-			if(flag)
-			{
-				var args = [
-					d.widgets['Company Name'].value,
-					d.widgets['Company Abbreviation'].value,
-					d.widgets['Fiscal Year Start Date'].value,
-					d.widgets['Default Currency'].value,
-					d.widgets['First Name'].value,
-					d.widgets['Last Name'].value
-				];
-				
-				$c_obj('Setup Control','setup_account',JSON.stringify(args),function(r, rt){
-					sys_defaults = r.message;
-					user_fullname = r.message.user_fullname;
-					d.hide();
-					$('header').toggle(true);
-					page_body.wntoolbar.set_user_name();
-				});
-			} else {
-				d.widgets['Save'].done_working();
-			}
-		}
-		d.show();
-	}
-}
-
-// make dialog fields
-// ------------------
-pscript.make_dialog_field = function(d)
-{
-	// fiscal year format 
-	fisc_format = d.widgets['Fiscal Year Start Date'];
-	add_sel_options(fisc_format, ['', '1st Jan', '1st Apr', '1st Jul', '1st Oct']);
-  
-	// default currency
-	currency_list = ['', 'AED', 'AFN', 'ALL', 'AMD', 'ANG', 'AOA', 'ARS', 'AUD', 'AZN', 'BAM', 'BBD', 'BDT', 'BGN', 'BHD', 'BIF', 'BMD', 'BND', 'BOB', 'BRL', 'BSD', 'BTN', 'BYR', 'BZD', 'CAD', 'CDF', 'CFA', 'CFP', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CUC', 'CZK', 'DJF', 'DKK', 'DOP', 'DZD', 'EEK', 'EGP', 'ERN', 'ETB', 'EUR', 'EURO', 'FJD', 'FKP', 'FMG', 'GBP', 'GEL', 'GHS', 'GIP', 'GMD', 'GNF', 'GQE', 'GTQ', 'GYD', 'HKD', 'HNL', 'HRK', 'HTG', 'HUF', 'IDR', 'ILS', 'INR', 'IQD', 'IRR', 'ISK', 'JMD', 'JOD', 'JPY', 'KES', 'KGS', 'KHR', 'KMF', 'KPW', 'KRW', 'KWD', 'KYD', 'KZT', 'LAK', 'LBP', 'LKR', 'LRD', 'LSL', 'LTL', 'LVL', 'LYD', 'MAD', 'MDL', 'MGA', 'MKD', 'MMK', 'MNT', 'MOP', 'MRO', 'MUR', 'MVR', 'MWK', 'MXN', 'MYR', 'MZM', 'NAD', 'NGN', 'NIO', 'NOK', 'NPR', 'NRs', 'NZD', 'OMR', 'PAB', 'PEN', 'PGK', 'PHP', 'PKR', 'PLN', 'PYG', 'QAR', 'RMB', 'RON', 'RSD', 'RUB', 'RWF', 'SAR', 'SCR', 'SDG', 'SDR', 'SEK', 'SGD', 'SHP', 'SOS', 'SRD', 'STD', 'SYP', 'SZL', 'THB', 'TJS', 'TMT', 'TND', 'TRY', 'TTD', 'TWD', 'TZS', 'UAE', 'UAH', 'UGX', 'USD', 'USh', 'UYU', 'UZS', 'VEB', 'VND', 'VUV', 'WST', 'XAF', 'XCD', 'XDR', 'XOF', 'XPF', 'YEN', 'YER', 'YTL', 'ZAR', 'ZMK', 'ZWR'];
-	currency = d.widgets['Default Currency'];
-	add_sel_options(currency, currency_list);
-}
-
-
-// validate fields
-// ---------------
-pscript.validate_fields = function(d)
-{
-	var lst = ['First Name', 'Company Name', 'Company Abbreviation', 'Fiscal Year Start Date', 'Default Currency'];
-	var msg = 'Please enter the following fields';
-	var flag = 1;
-	for(var i=0; i<lst.length; i++)
-	{
-		if(!d.widgets[lst[i]].value || d.widgets[lst[i]].value=='None'){
-			flag = 0;
-			msg = msg + NEWLINE + lst[i];
-		}
-	}
-
-	if(!flag)  alert(msg);
-	return flag;
-}
diff --git a/erpnext/home/page/profile_settings/profile_settings.js b/erpnext/home/page/profile_settings/profile_settings.js
index 9dac7f6..8ce94f8 100644
--- a/erpnext/home/page/profile_settings/profile_settings.js
+++ b/erpnext/home/page/profile_settings/profile_settings.js
@@ -26,13 +26,15 @@
 	
 	this.make = function() {
 		this.head = new PageHeader(this.wrapper, 'My Profile Settings');
-		this.head.add_button('Change Password', this.change_password)
+		this.head.add_button('Change Password', this.change_password);
+		this.head.add_button('Change Background', this.change_background);
+		
 		this.tab = make_table($a(this.wrapper, 'div', '', {marginTop:'19px'}), 
 			1, 2, '90%', ['50%', '50%'], {padding:'11px'})
 		this.img = $a($td(this.tab, 0, 0), 'img');
 		set_user_img(this.img, user);
 
-		$btn($a($td(this.tab, 0, 0), 'div', '', {marginTop:'11px'}), 'Change Image', this.change_image)
+		$btn($a($td(this.tab, 0, 0), 'div', '', {marginTop:'11px'}), 'Change Image', this.change_image);
 
 		this.make_form();
 		this.load_details();
@@ -105,32 +107,42 @@
 	//
 	
 	this.change_image = function() {
-		if(!me.change_dialog) {
-
-			var d = new Dialog(400,200,'Set Your Profile Image');
-			d.make_body([
-				['HTML','wrapper']
-			]);	
-
-			var w = d.widgets['wrapper'];
-			me.uploader = new Uploader(w, 
-				{
-					modulename:'home.page.profile_settings.profile_settings',
-					method: 'set_user_image'
-				}, 
-				pscript.user_image_upload, 1)
-			me.change_dialog = d;
-		}
-		me.change_dialog.show();
+		var d = new wn.widgets.Dialog({
+			title: 'Set your Profile'
+		})
+		me.uploader = new Uploader(d.body, {
+				modulename:'home.page.profile_settings.profile_settings',
+				method: 'set_user_image'
+			}, 
+			pscript.user_image_upload, 1)
+		d.show();
+		pscript.open_dialog = d;
+	}
+	
+	this.change_background = function() {
+		var d = new wn.widgets.Dialog({
+			title: 'Set Background Image'
+		})
+		me.uploader = new Uploader(d.body, {
+				modulename:'home.page.profile_settings.profile_settings',
+				method: 'set_user_background'
+			}, 
+			pscript.background_change, 1)
+		d.show();
+		pscript.open_dialog = d;
 	}
 	this.make();
 }
 
+pscript.background_change = function(fid) {
+	//erpnext.set_background_image(fid);
+	pscript.open_dialog.hide();
+}
+
 pscript.user_image_upload = function(fid) {
 	msgprint('File Uploaded');
-	
 	if(fid) {
-		pscript.myprofile.change_dialog.hide();
+		pscript.open_dialog.hide();
 		set_user_img(pscript.myprofile.img, user, null, fid);
 	}
 }
diff --git a/erpnext/home/page/profile_settings/profile_settings.py b/erpnext/home/page/profile_settings/profile_settings.py
index f614c75..fb633fd 100644
--- a/erpnext/home/page/profile_settings/profile_settings.py
+++ b/erpnext/home/page/profile_settings/profile_settings.py
@@ -63,6 +63,31 @@
 	"""
 		Set uploaded image as user image
 	"""
-	from webnotes.utils.file_manager import add_file_list, remove_all
-	remove_all('Profile', webnotes.session['user'])
-	add_file_list('Profile', webnotes.session['user'], fname, fid)
+	from webnotes.utils.file_manager import add_file_list, remove_file
+	user = webnotes.session['user']
+	
+	# remove old file
+	old_image = webnotes.conn.get_value('Profile', user, 'user_image')
+	if old_image:
+		remove_file('Profile', user, old_image)
+		
+	# add new file
+	add_file_list('Profile', user, fname, fid)
+	webnotes.conn.set_value('Profile', user, 'user_image', fid)
+
+@webnotes.whitelist()	
+def set_user_background(fid, fname):
+	"""
+		Set uploaded image as user image
+	"""
+	from webnotes.utils.file_manager import add_file_list, remove_file
+	user = webnotes.session['user']
+	
+	# remove old file
+	old_image = webnotes.conn.get_value('Profile', user, 'background_image')
+	if old_image:
+		remove_file('Profile', user, old_image)
+		
+	# add new file
+	add_file_list('Profile', user, fname, fid)
+	webnotes.conn.set_value('Profile', user, 'background_image', fid)
diff --git a/erpnext/patches/jan_mar_2012/navupdate.py b/erpnext/patches/jan_mar_2012/navupdate.py
index d29a2cf..29939e5 100644
--- a/erpnext/patches/jan_mar_2012/navupdate.py
+++ b/erpnext/patches/jan_mar_2012/navupdate.py
@@ -32,6 +32,10 @@
 	reload_doc('utilities', 'page', 'todo')
 	reload_doc('utilities', 'page', 'calendar')
 	reload_doc('utilities', 'page', 'messages')
+	reload_doc('setup', 'page', 'modules_setup')
+	reload_doc('utilities', 'page', 'users')
+	reload_doc('home', 'page', 'activity')
+	reload_doc('core', 'doctype', 'profile')
 	
 	webnotes.conn.set_value('Control Panel', 'Control Panel', 'home_page',
 			'desktop')
diff --git a/erpnext/patches/patch_list.py b/erpnext/patches/patch_list.py
index dc9f1dd..6c66f75 100644
--- a/erpnext/patches/patch_list.py
+++ b/erpnext/patches/patch_list.py
@@ -121,4 +121,40 @@
 		'patch_file': 'fix_packing_slip',
 		'description': 'Update Mapper Delivery Note-Packing Slip'
 	},
+	{
+		'patch_module': 'patches.jan_mar_2012.apps',
+		'patch_file': 'todo_item',
+		'description': 'Reloads todo item'
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'convert_tables_to_utf8',
+		'description': 'Convert tables to UTF-8'
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'pending_patches',
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'pos_setting_patch',
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'reload_doctype',
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'reload_po_pr_mapper',
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'delete_pur_of_service',
+		'description': 'Deletes purpose of service'
+	},
+	{
+		'patch_module': 'patches.jan_mar_2012',
+		'patch_file': 'navupdate',
+		'description': 'New Navigation Pages'
+	},
 ]
diff --git a/erpnext/setup/doctype/setup_control/setup_control.py b/erpnext/setup/doctype/setup_control/setup_control.py
index beb3cc6..6b8b37c 100644
--- a/erpnext/setup/doctype/setup_control/setup_control.py
+++ b/erpnext/setup/doctype/setup_control/setup_control.py
@@ -14,24 +14,14 @@
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-# Please edit this list and import only required elements
 import webnotes
 
-from webnotes.utils import add_days, add_months, add_years, cint, cstr, date_diff, default_fields, flt, fmt_money, formatdate, generate_hash, getTraceback, get_defaults, get_first_day, get_last_day, getdate, has_common, month_name, now, nowdate, replace_newlines, sendmail, set_default, str_esc_quote, user_format, validate_email_add
-from webnotes.model import db_exists
-from webnotes.model.doc import Document, addchild, removechild, getchildren, make_autoname, SuperDocType
-from webnotes.model.doclist import getlist, copy_doclist
-from webnotes.model.code import get_obj, get_server_obj, run_server_obj, updatedb, check_syntax
-from webnotes import session, form, is_testing, msgprint, errprint
+from webnotes.utils import cint, cstr, flt, getdate, now, nowdate
+from webnotes.model.doc import Document, addchild
+from webnotes.model.code import get_obj
+from webnotes import session, form, msgprint
 
-set = webnotes.conn.set
 sql = webnotes.conn.sql
-get_value = webnotes.conn.get_value
-in_transaction = webnotes.conn.in_transaction
-convert_to_lists = webnotes.conn.convert_to_lists
-	
-# -----------------------------------------------------------------------------------------
-
 
 class DocType:
 	def __init__(self, d, dl):
@@ -58,8 +48,8 @@
 		args = json.loads(args)
 
 		self.set_cp_defaults(args['company'], args['industry'], args['time_zone'], args['country'], args['account_name'])
-		self.create_profile(args['user'], args['first_name'], args['last_name'], args.get('pwd'))	
-	
+		self.create_profile(args['user'], args['first_name'], args['last_name'], args.get('pwd'))
+
 		# Domain related updates
 		try:
 			from server_tools.gateway_utils import add_domain_map
@@ -68,22 +58,27 @@
 			pass
 
 		# add record in domain_list of Website Settings
-		webnotes.conn.set_value('Website Settings', 'Website Settings', 'subdomain', args['url_name'] + ".erpnext.com")
+		account_url = args['url_name'] + '.erpnext.com'
+		webnotes.conn.set_value('Website Settings', 'Website Settings',
+				'subdomain', account_url)
 		
 	
 	# Account Setup
 	# ---------------
 	def setup_account(self, args):
-		import webnotes
-		company_name, comp_abbr, fy_start, currency, first_name, last_name = eval(args)
-		curr_fiscal_year,fy_start_date = self.get_fy_details(fy_start)
-		self.currency = currency
+		import webnotes, json
+		args = json.loads(args)
+
+		curr_fiscal_year, fy_start_date = self.get_fy_details(args.get('fy_start'))
+
+		args['name'] = webnotes.session.get('user')
 
 		# Update Profile
-		if last_name=='None': last_name = None
+		if not args.get('last_name') or args.get('last_name')=='None': args['last_name'] = None
 		webnotes.conn.sql("""\
-			UPDATE `tabProfile` SET first_name=%s, last_name=%s
-			WHERE name=%s AND docstatus<2""", (first_name, last_name, webnotes.user.name))
+			UPDATE `tabProfile` SET first_name=%(first_name)s,
+			last_name=%(last_name)s
+			WHERE name=%(name)s AND docstatus<2""", args)
 			
 		
 		# Fiscal Year
@@ -91,15 +86,15 @@
 		self.create_records(master_dict)
 		
 		# Company
-		master_dict = {'Company':{'company_name':company_name,
-								  'abbr':comp_abbr,
-								  'default_currency':currency
-															}}
+		master_dict = {'Company':{'company_name':args.get('company_name'),
+								  'abbr':args.get('company_abbr'),
+								  'default_currency':args.get('currency')
+								}}
 		self.create_records(master_dict)
 		
 		def_args = {'current_fiscal_year':curr_fiscal_year,
-								'default_currency': currency,
-								'default_company':company_name,
+								'default_currency': args.get('currency'),
+								'default_company':args.get('company_name'),
 								'default_valuation_method':'FIFO',
 								'default_stock_uom':'Nos',
 								'date_format':'dd-mm-yyyy',
@@ -111,21 +106,51 @@
 								'emp_created_by':'Naming Series',
 								'cust_master_name':'Customer Name', 
 								'supp_master_name':'Supplier Name',
-								'default_currency_format': (currency=='INR') and 'Lacs' or 'Millions'
+								'default_currency_format': \
+										(args.get('currency')=='INR') and 'Lacs' or 'Millions'
 					}
 
 		# Set 
 		self.set_defaults(def_args)
 
-		# Set Registration Complete
-		set_default('registration_complete','1')
+		self.create_feed_and_todo()
 
-		msgprint("Great! Your company has now been created")
+		webnotes.clear_cache()
+		msgprint("Company setup is complete")
 		
 		import webnotes.utils
-		user_fullname = (first_name or '') + (last_name and (" " + last_name) or '')
+		user_fullname = (args.get('first_name') or '') + (args.get('last_name')
+				and (" " + args.get('last_name')) or '')
 		return {'sys_defaults': webnotes.utils.get_defaults(), 'user_fullname': user_fullname}
 
+	def create_feed_and_todo(self):
+		"""update activty feed and create todo for creation of item, customer, vendor"""
+		import home
+		home.make_feed('Comment', 'ToDo Item', '', webnotes.session['user'],
+			'<i>"' + 'Setup Complete. Please check your <a href="#!todo">\
+			To Do List</a>' + '"</i>', '#6B24B3')
+
+		d = Document('ToDo Item')
+		d.description = 'Create your first Customer'
+		d.priority = 'High'
+		d.date = nowdate()
+		d.reference_type = 'Customer'
+		d.save(1)
+
+		d = Document('ToDo Item')
+		d.description = 'Create your first Item'
+		d.priority = 'High'
+		d.date = nowdate()
+		d.reference_type = 'Item'
+		d.save(1)
+
+		d = Document('ToDo Item')
+		d.description = 'Create your first Supplier'
+		d.priority = 'High'
+		d.date = nowdate()
+		d.reference_type = 'Supplier'
+		d.save(1)
+
 		
 	# Get Fiscal year Details
 	# ------------------------
@@ -207,14 +232,6 @@
 			d = addchild(pr,'userroles', 'UserRole', 1)
 			d.role = r
 			d.save(1)
-			
-
-	# Sync DB
-	# -------
-	def sync_db(arg=''):
-		import webnotes.model.db_schema
-		sql("delete from `tabDocType Update Register`")
-		webnotes.model.db_schema.sync_all()
 		
 	
 	def is_setup_okay(self, args):
@@ -224,21 +241,14 @@
 
 		from server_tools.gateway_utils import get_total_users
 		
-		args = eval(args)
-		#webnotes.logger.error("args in set_account_details of setup_control: " + str(args))
-		
+		args = eval(args)		
 		cp_defaults = webnotes.conn.get_value('Control Panel', None, 'account_id')
-		
 		user_profile = webnotes.conn.get_value('Profile', args['user'], 'name')
 		
 		from webnotes.utils import cint
 		
 		total_users = get_total_users()
-		
-		#webnotes.logger.error("setup_control.is_setup_okay: " + cp_defaults + " " + user_profile + " " + str(total_users))
-		
-		#webnotes.logger.error("setup_control.is_setup_okay: Passed Values:" + args['account_name'] + " " + args['user'] + " " + str(args['total_users']))
-		
+						
 		if (cp_defaults==args['account_name']) and user_profile and \
 		   (total_users==cint(args['total_users'])):
 		   return 'True'
diff --git a/erpnext/setup/page/import_data/import_data.html b/erpnext/setup/page/import_data/import_data.html
index 5f9556b..29f0cc3 100644
--- a/erpnext/setup/page/import_data/import_data.html
+++ b/erpnext/setup/page/import_data/import_data.html
@@ -41,6 +41,7 @@
 		<li>Select the saved CSV file, identify the date format if any</li>
 		<li>Click on "Import"</li>
 	</ol>
+	<br />
 	<h4>Over-writing Guide</h4>
 	<ol>
 		<li>To over-write data, click on "Do you want to over-write records?" and then download template</li>
@@ -48,6 +49,30 @@
 		<li>Over-writing of child table data will delete all previous data of child table and re-import. so before over-writing child tables, export all data from system, modify them and then re-import</li>
 		<li>Over-write checkbox will be checked while importing</li>
 	</ol>
+	<br />
+	<h4>Do you have Non-English data?</h4>
+	You may need to save the file with UTF-8 encoding for data to be imported correctly.
+	<br /><br />
+	Microsoft Excel Users:<br />
+	There is no obvious way of saving a CSV file with UTF-8 encoding.<br />
+	You will need to follow these steps:
+	<ol>
+		<li>In Excel, save the file in CSV (Comma Delimited) format</li>
+		<li>Open this saved file in Notepad</li>
+		<li>Click on File -&gt; Save As</li>
+		<li>File Name: &lt;your filename&gt;.csv<br />
+			Save as type: Text Documents (*.txt)<br />
+			Encoding: UTF-8
+		</li>
+		<li>Click on Save</li>
+	</ol>
+	<br />
+	OpenOffice or LibreOffice Users:<br />
+	<ol>
+		<li>While saving as CSV, check "Edit Filter Settings".</li>
+		<li>You will be prompted for Encoding.</li>
+		<li>Make sure it is "UTF-8" and click on OK.</li>
+	</ol>
 </div>
 </td>
 <td style="border: 1px solid #AAA; padding: 4px;">
diff --git a/erpnext/startup/event_handlers.py b/erpnext/startup/event_handlers.py
index a1d805e..dca9e0c 100644
--- a/erpnext/startup/event_handlers.py
+++ b/erpnext/startup/event_handlers.py
@@ -89,6 +89,12 @@
 		bootinfo['docs'] += webnotes.model.doctype.get('Event')
 		
 		bootinfo['modules_list'] = webnotes.conn.get_global('modules_list')
+		
+		# if no company, show a dialog box to create a new company
+		bootinfo['setup_complete'] = webnotes.conn.sql("""select name from 
+			tabCompany limit 1""") and 'Yes' or 'No'
+			
+		bootinfo['user_background'] = webnotes.conn.get_value("Profile", webnotes.session['user'], 'background_image') or ''
 
 def get_letter_heads():
 	"""load letter heads with startup"""
diff --git a/erpnext/startup/js/complete_setup.js b/erpnext/startup/js/complete_setup.js
new file mode 100644
index 0000000..ac89aff
--- /dev/null
+++ b/erpnext/startup/js/complete_setup.js
@@ -0,0 +1,93 @@
+// ERPNext - web based ERP (http://erpnext.com)
+// Copyright (C) 2012 Web Notes Technologies Pvt Ltd
+// 
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 3 of the License, or
+// (at your option) any later version.
+// 
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+// GNU General Public License for more details.
+// 
+// You should have received a copy of the GNU General Public License
+// along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+// complete my company registration
+// --------------------------------
+
+erpnext.complete_setup = function() {
+	var currency_list = ['', 'AED', 'AFN', 'ALL', 'AMD', 'ANG', 'AOA', 'ARS', 'AUD', 'AZN', 
+	'BAM', 'BBD', 'BDT', 'BGN', 'BHD', 'BIF', 'BMD', 'BND', 'BOB', 'BRL', 'BSD', 'BTN', 'BYR', 
+	'BZD', 'CAD', 'CDF', 'CFA', 'CFP', 'CHF', 'CLP', 'CNY', 'COP', 'CRC', 'CUC', 'CZK', 'DJF', 
+	'DKK', 'DOP', 'DZD', 'EEK', 'EGP', 'ERN', 'ETB', 'EUR', 'EURO', 'FJD', 'FKP', 'FMG', 'GBP', 
+	'GEL', 'GHS', 'GIP', 'GMD', 'GNF', 'GQE', 'GTQ', 'GYD', 'HKD', 'HNL', 'HRK', 'HTG', 'HUF', 
+	'IDR', 'ILS', 'INR', 'IQD', 'IRR', 'ISK', 'JMD', 'JOD', 'JPY', 'KES', 'KGS', 'KHR', 'KMF', 
+	'KPW', 'KRW', 'KWD', 'KYD', 'KZT', 'LAK', 'LBP', 'LKR', 'LRD', 'LSL', 'LTL', 'LVL', 'LYD', 
+	'MAD', 'MDL', 'MGA', 'MKD', 'MMK', 'MNT', 'MOP', 'MRO', 'MUR', 'MVR', 'MWK', 'MXN', 'MYR', 
+	'MZM', 'NAD', 'NGN', 'NIO', 'NOK', 'NPR', 'NRs', 'NZD', 'OMR', 'PAB', 'PEN', 'PGK', 'PHP', 
+	'PKR', 'PLN', 'PYG', 'QAR', 'RMB', 'RON', 'RSD', 'RUB', 'RWF', 'SAR', 'SCR', 'SDG', 'SDR', 
+	'SEK', 'SGD', 'SHP', 'SOS', 'SRD', 'STD', 'SYP', 'SZL', 'THB', 'TJS', 'TMT', 'TND', 'TRY', 
+	'TTD', 'TWD', 'TZS', 'UAE', 'UAH', 'UGX', 'USD', 'USh', 'UYU', 'UZS', 'VEB', 'VND', 'VUV', 
+	'WST', 'XAF', 'XCD', 'XDR', 'XOF', 'XPF', 'YEN', 'YER', 'YTL', 'ZAR', 'ZMK', 'ZWR'];
+	
+	var d = new wn.widgets.Dialog({
+		title: "Setup",
+		fields: [
+			{fieldname:'first_name', label:'Your First Name', fieldtype:'Data', reqd: 1},
+			{fieldname:'last_name', label:'Your Last Name', fieldtype:'Data'},
+			{fieldname:'company_name', label:'Company Name', fieldtype:'Data', reqd:1,
+				description: 'e.g. "My Company LLC"'},
+			{fieldname:'company_abbr', label:'Company Abbreviation', fieldtype:'Data',
+				description:'e.g. "MC"',reqd:1},
+			{fieldname:'fy_start', label:'Financial Year Start Date', fieldtype:'Select',
+				description:'Your financial year begins on"', reqd:1,
+				options: ['', '1st Jan', '1st Apr', '1st Jul', '1st Oct'].join('\n')},
+			{fieldname:'currency', label: 'Default Currency', reqd:1,
+				options: currency_list.join('\n'), fieldtype: 'Select'},
+			{fieldname:'update', label:'Setup',fieldtype:'Button'}
+		]
+	})
+	
+	// prepare
+	if(user != 'Administrator'){
+		d.no_cancel(); // Hide close image
+		$('header').toggle(false); // hide toolbar
+	}
+	
+	// company name already set
+	if(wn.control_panel.company_name) {
+		var inp = d.fields_dict.company_name.input;
+		inp.value = wn.control_panel.company_name;
+		inp.disabled = true;
+	}
+	
+	// set first name, last name
+	if(user_fullname) {
+		u = user_fullname.split(' ');
+		if(u[0]) {
+			d.fields_dict.first_name.input.value = u[0];
+		}
+		if(u[1]) {
+			d.fields_dict.last_name.input.value = u[1];			
+		}
+	}
+	
+	// setup
+	d.fields_dict.update.input.onclick = function() {
+		var data = d.get_values();
+		if(!data) return;
+		$(this).set_working();
+		$c_obj('Setup Control','setup_account',data,function(r, rt){
+			sys_defaults = r.message;
+			user_fullname = r.message.user_fullname;
+			wn.boot.user_info[user].fullname = user_fullname;
+			d.hide();
+			$('header').toggle(true);
+			page_body.wntoolbar.set_user_name();
+		});
+	}
+	
+	d.show();
+}
diff --git a/erpnext/startup/feature_setup.js b/erpnext/startup/js/feature_setup.js
similarity index 100%
rename from erpnext/startup/feature_setup.js
rename to erpnext/startup/js/feature_setup.js
diff --git a/erpnext/startup/modules.js b/erpnext/startup/js/modules.js
similarity index 96%
rename from erpnext/startup/modules.js
rename to erpnext/startup/js/modules.js
index dbd11b0..add068c 100644
--- a/erpnext/startup/modules.js
+++ b/erpnext/startup/js/modules.js
@@ -73,7 +73,10 @@
 		args: {
 			module: module
 		},
-		no_refresh: true
+		no_refresh: true,
+		callback: function(r) {
+			erpnext.module_page.hide_links(wrapper)
+		}
 	});
 	wrapper.list.run();	
 }
\ No newline at end of file
diff --git a/erpnext/startup/toolbar.js b/erpnext/startup/js/toolbar.js
similarity index 100%
rename from erpnext/startup/toolbar.js
rename to erpnext/startup/js/toolbar.js
diff --git a/erpnext/startup/startup.js b/erpnext/startup/startup.js
index 30ab28d..ad8289e 100644
--- a/erpnext/startup/startup.js
+++ b/erpnext/startup/startup.js
@@ -30,7 +30,7 @@
 	'Website': 'website-home',
 	'HR': 'hr-home',
 	'Setup': 'Setup',
-	'Activity': 'Event Updates',
+	'Activity': 'activity',
 	'To Do': 'todo',
 	'Calendar': 'calendar',
 	'Messages': 'messages',
@@ -50,6 +50,9 @@
 	if(wn.boot.custom_css) {
 		set_style(wn.boot.custom_css);
 	}
+	if(wn.boot.user_background) {
+		erpnext.set_user_background(wn.boot.user_background);
+	}
 		
 	if(user == 'Guest'){
 		if(wn.boot.website_settings.title_prefix) {
@@ -58,7 +61,7 @@
 	} else {
 		// setup toolbar
 		erpnext.toolbar.setup();
-		
+				
 		// set interval for updates
 		erpnext.startup.set_periodic_updates();
 
@@ -66,6 +69,13 @@
 		// ------------------
 		$('footer').html('<div class="web-footer erpnext-footer">\
 			Powered by <a href="https://erpnext.com">ERPNext</a></div>');
+
+		// complete registration
+		if(in_list(user_roles,'System Manager') && (wn.boot.setup_complete=='No')) { 
+			wn.require("erpnext/startup/js/complete_setup.js");
+			erpnext.complete_setup(); 
+		}
+
 	}
 
 	$('#startup_div').toggle(false);
@@ -87,28 +97,6 @@
 }
 
 
-// Module Page
-// ====================================================================
-
-ModulePage = function(parent, module_name, module_label, help_page, callback) {
-	this.parent = parent;
-
-	// add to current page
-	page_body.cur_page.module_page = this;
-
-	this.wrapper = $a(parent,'div');
-	this.module_name = module_name;
-	this.transactions = [];
-	this.page_head = new PageHeader(this.wrapper, module_label);
-
-	if(help_page) {
-		var btn = this.page_head.add_button('Help', function() { loadpage(this.help_page) }, 1, 'ui-icon-help')
-		btn.help_page = help_page;
-	}
-
-	if(callback) this.callback = function(){ callback(); }
-}
-
 // ========== Update Messages ============
 var update_messages = function() {
 	// Updates Team Messages
@@ -147,6 +135,10 @@
 	wn.updates.id = setInterval(update_messages, 60000);
 }
 
+erpnext.set_user_background = function(src) {
+	set_style(repl('body { background: url("files/%(src)s") repeat !important;}', {src:src}))
+}
+
 // =======================================
 
 // start
diff --git a/erpnext/stock/DocType Mapper/Purchase Order-Purchase Receipt/Purchase Order-Purchase Receipt.txt b/erpnext/stock/DocType Mapper/Purchase Order-Purchase Receipt/Purchase Order-Purchase Receipt.txt
index 3c50836..73dfd4b 100644
--- a/erpnext/stock/DocType Mapper/Purchase Order-Purchase Receipt/Purchase Order-Purchase Receipt.txt
+++ b/erpnext/stock/DocType Mapper/Purchase Order-Purchase Receipt/Purchase Order-Purchase Receipt.txt
@@ -5,7 +5,7 @@
 	{
 		'creation': '2010-08-08 17:09:35',
 		'docstatus': 0,
-		'modified': '2012-02-07 13:28:20',
+		'modified': '2012-02-29 17:55:13',
 		'modified_by': u'Administrator',
 		'owner': u'Administrator'
 	},
@@ -22,7 +22,6 @@
 	# These values are common for all Field Mapper Detail
 	{
 		'doctype': u'Field Mapper Detail',
-		'map': u'Yes',
 		'name': '__common__',
 		'parent': u'Purchase Order-Purchase Receipt',
 		'parentfield': u'field_mapper_details',
@@ -50,6 +49,7 @@
 		'checking_operator': u'=',
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'supplier',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'supplier'
 	},
@@ -59,6 +59,7 @@
 		'checking_operator': u'=',
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'company',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'company'
 	},
@@ -68,6 +69,7 @@
 		'checking_operator': u'=',
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'currency',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'currency'
 	},
@@ -76,6 +78,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'name',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'prevdoc_detail_docname'
 	},
@@ -84,6 +87,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'parent',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'prevdoc_docname'
 	},
@@ -92,6 +96,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'parenttype',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'prevdoc_doctype'
 	},
@@ -101,6 +106,7 @@
 		'checking_operator': u'=',
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'item_code',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'item_code'
 	},
@@ -109,6 +115,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'eval:(flt(obj.qty) - flt(obj.received_qty)) ',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'received_qty'
 	},
@@ -117,6 +124,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'eval:(flt(obj.qty) - flt(obj.received_qty)) ',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'qty'
 	},
@@ -125,6 +133,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'eval:(flt(obj.qty) - flt(obj.received_qty)) * flt(obj.conversion_factor)',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'stock_qty'
 	},
@@ -133,6 +142,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'eval:(flt(obj.qty) - flt(obj.received_qty)) * flt(obj.import_rate)',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'import_amount'
 	},
@@ -141,6 +151,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'eval:(flt(obj.qty) - flt(obj.received_qty)) * flt(obj.purchase_rate)',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'amount'
 	},
@@ -149,6 +160,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'schedule_date',
+		'map': u'Yes',
 		'match_id': 1,
 		'to_field': u'schedule_date'
 	},
@@ -157,6 +169,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'net_total',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'net_total'
 	},
@@ -165,6 +178,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'grand_total',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'grand_total'
 	},
@@ -173,6 +187,7 @@
 	{
 		'doctype': u'Field Mapper Detail',
 		'from_field': u'total_tax',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'total_tax'
 	},
@@ -180,7 +195,17 @@
 	# Field Mapper Detail
 	{
 		'doctype': u'Field Mapper Detail',
+		'from_field': u'transaction_date',
+		'map': u'No',
+		'match_id': 0,
+		'to_field': u'transaction_date'
+	},
+
+	# Field Mapper Detail
+	{
+		'doctype': u'Field Mapper Detail',
 		'from_field': u'conversion_rate',
+		'map': u'Yes',
 		'match_id': 0,
 		'to_field': u'conversion_rate'
 	},
diff --git a/erpnext/stock/page/stock_home/stock_home.html b/erpnext/stock/page/stock_home/stock_home.html
index 9ba21a4..bab93dc 100644
--- a/erpnext/stock/page/stock_home/stock_home.html
+++ b/erpnext/stock/page/stock_home/stock_home.html
@@ -4,7 +4,7 @@
 		<h1>Stock</h1>
 		<hr>
 		<div style="width: 48%; float: left;">
-			<h4><a ahref="#!List/Stock Entry">Stock Entry</a></h4>
+			<h4><a href="#!List/Stock Entry">Stock Entry</a></h4>
 			<p class="help">Transfer stock from one warehouse to another</p>
 			<h4><a href="#!List/Delivery Note">Delivery Note</a></h4>
 			<p class="help">Delivery (shipment) to customers</p>
diff --git a/erpnext/utilities/__init__.py b/erpnext/utilities/__init__.py
index 28eacce..d57f0de 100644
--- a/erpnext/utilities/__init__.py
+++ b/erpnext/utilities/__init__.py
@@ -23,6 +23,7 @@
 		distinct criteria_name, doc_type, parent_doc_type
 		from `tabSearch Criteria` 
 		where module='%(module)s' 
-		and docstatus in (0, NULL) 
+		and docstatus in (0, NULL)
+		and ifnull(disabled, 0) = 0 
 		order by criteria_name 
 		limit %(limit_start)s, %(limit_page_length)s""" % webnotes.form_dict, as_dict=True)
\ No newline at end of file
diff --git a/erpnext/utilities/page/messages/messages.js b/erpnext/utilities/page/messages/messages.js
index 43adce4..f33c47b 100644
--- a/erpnext/utilities/page/messages/messages.js
+++ b/erpnext/utilities/page/messages/messages.js
@@ -65,7 +65,7 @@
 		$(wn.pages.messages).find('.well').toggle(contact==user ? false : true);
 
 		$(wn.pages.messages).find('h1:first').html('Messages: ' 
-			+ (user==contact ? 'From everyone' : wn.boot.user_fullnames[contact]))
+			+ (user==contact ? 'From everyone' : wn.user_info(contact).fullname));
 
 		erpnext.messages.contact = contact;
 		erpnext.messages.list.opts.args.contact = contact;
@@ -98,7 +98,7 @@
 			},
 			render_row: function(wrapper, data) {
 				data.creation = dateutil.comment_when(data.creation);
-				data.comment_by_fullname = wn.boot.user_fullnames[data.owner];
+				data.comment_by_fullname = wn.user_info(data.owner).fullname;
 
 				data.reply_html = '';
 				if(data.owner==user) {
@@ -143,7 +143,7 @@
 				var $body = $(wn.pages.messages).find('.section-body');
 				for(var i in r.message) {
 					var p = r.message[i];
-					p.fullname = wn.boot.user_fullnames[p.name];
+					p.fullname = wn.user_info(p.name).fullname;
 					p.name = p.name.replace('@', '__at__');
 					$body.append(repl('<div class="section-item">\
 						<a href="#!messages/%(name)s">%(fullname)s</a></div>', p))
diff --git a/erpnext/utilities/page/todo/todo.js b/erpnext/utilities/page/todo/todo.js
index 4350023..dfaa7cd 100644
--- a/erpnext/utilities/page/todo/todo.js
+++ b/erpnext/utilities/page/todo/todo.js
@@ -46,14 +46,22 @@
 		}
 		todo.labelclass = label_map[todo.priority];
 		todo.userdate = dateutil.str_to_user(todo.date);
+		if(todo.reference_name && todo.reference_type) {
+			todo.link = repl('<a href="#!Form/%(reference_type)s/%(reference_name)s">\
+						%(reference_name)s</a>', todo);
+		} else if(todo.reference_type) {
+			todo.link = repl('<a href="#!List/%(reference_type)s">\
+						%(reference_type)s</a>', todo);
+		} else {
+			todo.link = '';
+		}
 		$('#todo-list').append(repl('<div class="todoitem">\
 				<span class="description">\
 					<span class="label %(labelclass)s">%(priority)s</span>\
 					<span class="help" style="margin-right: 7px">%(userdate)s</span>\
 					%(description)s</span>\
 					<span class="ref_link">&rarr;\
-					<a href="#!Form/%(reference_type)s/%(reference_name)s">\
-						[%(reference_name)s]</a></span>\
+					%(link)s</span>\
 					<a href="#" class="close">&times;</a>\
 		</div>', todo));
 		$todo = $('div.todoitem:last');
@@ -62,7 +70,7 @@
 			$todo.find('.description').css('text-decoration', 'line-through');
 		}
 		
-		if(!todo.reference_name)
+		if(!todo.reference_type)
 			$todo.find('.ref_link').toggle(false);
 		
 		$todo.find('.description')
@@ -145,4 +153,4 @@
 wn.pages.todo.onload = function() {
 	// load todos
 	erpnext.todo.refresh();
-}
\ No newline at end of file
+}
diff --git a/erpnext/utilities/page/users/users.js b/erpnext/utilities/page/users/users.js
index 21519b8..d1c916c 100644
--- a/erpnext/utilities/page/users/users.js
+++ b/erpnext/utilities/page/users/users.js
@@ -66,11 +66,11 @@
 	},
 	render: function(data) {
 		if(data.file_list) {
-			data.imgsrc = 'files/' + data.files_list.split('\n')[0].split(',')[1];
+			data.imgsrc = 'files/' + data.file_list.split('\n')[0].split(',')[1];
 		} else {
-			data.imgsrc = 'lib/images/ui/no_img_' + (data.gender=='Female' ? 'f' : 'm');
+			data.imgsrc = 'lib/images/ui/no_img_' + (data.gender=='Female' ? 'f' : 'm') + '.gif';
 		}
-		data.fullname = wn.boot.user_fullnames[data.name];
+		data.fullname = wn.user_info(data.name).fullname;
 		data.delete_html = '';
 		if(!data.enabled) 
 			data.delete_html = '<a class="close" title="delete">&times;</a>';
@@ -232,6 +232,7 @@
 				$c_page('utilities', 'users', 'add_user', v, function(r,rt) {
 					if(r.exc) { msgprint(r.exc); return; }
 					else {
+						wn.boot.user_info[v.user] = {fullname:v.first_name + ' ' + v.last_name};
 						d.hide();
 						me.refresh();
 					}
diff --git a/erpnext/utilities/page/users/users.py b/erpnext/utilities/page/users/users.py
index 44e2fb2..ca48213 100644
--- a/erpnext/utilities/page/users/users.py
+++ b/erpnext/utilities/page/users/users.py
@@ -154,7 +154,8 @@
 	args.update({
 		'company': webnotes.conn.get_default('company'),
 		'password': args.get('password'),
-		'account_url': webnotes.conn.get_default('account_url')
+		'account_url': webnotes.conn.get_value('Website Settings',
+			'Website Settings', 'subdomain') or ""
 	})
 	if not args.get('last_name'): args['last_name'] = ''
 	sendmail_md(pr.email, subject="Welcome to ERPNext", msg=welcome_txt % args, from_defs=1)
@@ -189,4 +190,4 @@
 To login to your new ERPNext account, please go to:
 
 %(account_url)s
-"""
\ No newline at end of file
+"""
diff --git a/erpnext/website/doctype/style_settings/custom_template.css b/erpnext/website/doctype/style_settings/custom_template.css
index e6eeeb3..8eb3d63 100644
--- a/erpnext/website/doctype/style_settings/custom_template.css
+++ b/erpnext/website/doctype/style_settings/custom_template.css
@@ -1,6 +1,6 @@
 body {
 {% if doc.background_image %}
-	background: url("files/{{ doc.background_image }}") repeat !important;
+	background: url("files/{{ doc.background_image }}") repeat;
 {% elif doc.background_color %}
 	background-color: #{{ doc.background_color }};
 {% endif %}	
diff --git a/erpnext/website/page/website_home/website_home.html b/erpnext/website/page/website_home/website_home.html
index 747ca5a..4c3c9c6 100644
--- a/erpnext/website/page/website_home/website_home.html
+++ b/erpnext/website/page/website_home/website_home.html
@@ -4,7 +4,7 @@
 		<h1>Support</h1>
 		<hr>
 		<div style="width: 48%; float: left;">
-			<h4><a ahref="#!List/Web Page">Web Page</a></h4>
+			<h4><a href="#!List/Web Page">Web Page</a></h4>
 			<p class="help">Static (content) web page</p>
 			<h4><a href="#!List/Product">Product</a></h4>
 			<p class="help">Product listed in catolog</p>
diff --git a/js/all-app.js b/js/all-app.js
index 9bd715c..26b1c01 100644
--- a/js/all-app.js
+++ b/js/all-app.js
Binary files differ
diff --git a/js/all-web.js b/js/all-web.js
index 07fae99..cad3c77 100644
--- a/js/all-web.js
+++ b/js/all-web.js
@@ -38,6 +38,33 @@
  *	lib/js/lib/bootstrap.min.js
  */!function(a){a(function(){"use strict",a.support.transition=function(){var b=document.body||document.documentElement,c=b.style,d=c.transition!==undefined||c.WebkitTransition!==undefined||c.MozTransition!==undefined||c.MsTransition!==undefined||c.OTransition!==undefined;return d&&{end:function(){var b="TransitionEnd";return a.browser.webkit?b="webkitTransitionEnd":a.browser.mozilla?b="transitionend":a.browser.opera&&(b="oTransitionEnd"),b}()}}()})}(window.jQuery),!function(a){"use strict";var b='[data-dismiss="alert"]',c=function(c){a(c).on("click",b,this.close)};c.prototype={constructor:c,close:function(b){function f(){e.remove(),e.trigger("closed")}var c=a(this),d=c.attr("data-target"),e;d||(d=c.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),e=a(d),e.trigger("close"),b&&b.preventDefault(),e.length||(e=c.hasClass("alert")?c:c.parent()),e.removeClass("in"),a.support.transition&&e.hasClass("fade")?e.on(a.support.transition.end,f):f()}},a.fn.alert=function(b){return this.each(function(){var d=a(this),e=d.data("alert");e||d.data("alert",e=new c(this)),typeof b=="string"&&e[b].call(d)})},a.fn.alert.Constructor=c,a(function(){a("body").on("click.alert.data-api",b,c.prototype.close)})}(window.jQuery),!function(a){"use strict";var b=function(b,c){this.$element=a(b),this.options=a.extend({},a.fn.button.defaults,c)};b.prototype={constructor:b,setState:function(a){var b="disabled",c=this.$element,d=c.data(),e=c.is("input")?"val":"html";a+="Text",d.resetText||c.data("resetText",c[e]()),c[e](d[a]||this.options[a]),setTimeout(function(){a=="loadingText"?c.addClass(b).attr(b,b):c.removeClass(b).removeAttr(b)},0)},toggle:function(){var a=this.$element.parent('[data-toggle="buttons-radio"]');a&&a.find(".active").removeClass("active"),this.$element.toggleClass("active")}},a.fn.button=function(c){return this.each(function(){var d=a(this),e=d.data("button"),f=typeof c=="object"&&c;e||d.data("button",e=new b(this,f)),c=="toggle"?e.toggle():c&&e.setState(c)})},a.fn.button.defaults={loadingText:"loading..."},a.fn.button.Constructor=b,a(function(){a("body").on("click.button.data-api","[data-toggle^=button]",function(b){a(b.target).button("toggle")})})}(window.jQuery),!function(a){"use strict";var b=function(b,c){this.$element=a(b),this.options=a.extend({},a.fn.carousel.defaults,c),this.options.slide&&this.slide(this.options.slide)};b.prototype={cycle:function(){return this.interval=setInterval(a.proxy(this.next,this),this.options.interval),this},to:function(b){var c=this.$element.find(".active"),d=c.parent().children(),e=d.index(c),f=this;if(b>d.length-1||b<0)return;return this.sliding?this.$element.one("slid",function(){f.to(b)}):e==b?this.pause().cycle():this.slide(b>e?"next":"prev",a(d[b]))},pause:function(){return clearInterval(this.interval),this},next:function(){if(this.sliding)return;return this.slide("next")},prev:function(){if(this.sliding)return;return this.slide("prev")},slide:function(b,c){var d=this.$element.find(".active"),e=c||d[b](),f=this.interval,g=b=="next"?"left":"right",h=b=="next"?"first":"last",i=this;return this.sliding=!0,f&&this.pause(),e=e.length?e:this.$element.find(".item")[h](),!a.support.transition&&this.$element.hasClass("slide")?(this.$element.trigger("slide"),d.removeClass("active"),e.addClass("active"),this.sliding=!1,this.$element.trigger("slid")):(e.addClass(b),e[0].offsetWidth,d.addClass(g),e.addClass(g),this.$element.trigger("slide"),this.$element.one(a.support.transition.end,function(){e.removeClass([b,g].join(" ")).addClass("active"),d.removeClass(["active",g].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger("slid")},0)})),f&&this.cycle(),this}},a.fn.carousel=function(c){return this.each(function(){var d=a(this),e=d.data("carousel"),f=typeof c=="object"&&c;e||d.data("carousel",e=new b(this,f)),typeof c=="number"?e.to(c):typeof c=="string"||(c=f.slide)?e[c]():e.cycle()})},a.fn.carousel.defaults={interval:5e3},a.fn.carousel.Constructor=b,a(function(){a("body").on("click.carousel.data-api","[data-slide]",function(b){var c=a(this),d,e=a(c.attr("data-target")||(d=c.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,"")),f=!e.data("modal")&&a.extend({},e.data(),c.data());e.carousel(f),b.preventDefault()})})}(window.jQuery),!function(a){"use strict";var b=function(b,c){this.$element=a(b),this.options=a.extend({},a.fn.collapse.defaults,c),this.options.parent&&(this.$parent=a(this.options.parent)),this.options.toggle&&this.toggle()};b.prototype={constructor:b,dimension:function(){var a=this.$element.hasClass("width");return a?"width":"height"},show:function(){var b=this.dimension(),c=a.camelCase(["scroll",b].join("-")),d=this.$parent&&this.$parent.find(".in"),e;d&&d.length&&(e=d.data("collapse"),d.collapse("hide"),e||d.data("collapse",null)),this.$element[b](0),this.transition("addClass","show","shown"),this.$element[b](this.$element[0][c])},hide:function(){var a=this.dimension();this.reset(this.$element[a]()),this.transition("removeClass","hide","hidden"),this.$element[a](0)},reset:function(a){var b=this.dimension();this.$element.removeClass("collapse")[b](a||"auto")[0].offsetWidth,this.$element.addClass("collapse")},transition:function(b,c,d){var e=this,f=function(){c=="show"&&e.reset(),e.$element.trigger(d)};this.$element.trigger(c)[b]("in"),a.support.transition&&this.$element.hasClass("collapse")?this.$element.one(a.support.transition.end,f):f()},toggle:function(){this[this.$element.hasClass("in")?"hide":"show"]()}},a.fn.collapse=function(c){return this.each(function(){var d=a(this),e=d.data("collapse"),f=typeof c=="object"&&c;e||d.data("collapse",e=new b(this,f)),typeof c=="string"&&e[c]()})},a.fn.collapse.defaults={toggle:!0},a.fn.collapse.Constructor=b,a(function(){a("body").on("click.collapse.data-api","[data-toggle=collapse]",function(b){var c=a(this),d,e=c.attr("data-target")||b.preventDefault()||(d=c.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,""),f=a(e).data("collapse")?"toggle":c.data();a(e).collapse(f)})})}(window.jQuery),!function(a){function d(){a(b).parent().removeClass("open")}"use strict";var b='[data-toggle="dropdown"]',c=function(b){var c=a(b).on("click.dropdown.data-api",this.toggle);a("html").on("click.dropdown.data-api",function(){c.parent().removeClass("open")})};c.prototype={constructor:c,toggle:function(b){var c=a(this),e=c.attr("data-target"),f,g;return e||(e=c.attr("href"),e=e&&e.replace(/.*(?=#[^\s]*$)/,"")),f=a(e),f.length||(f=c.parent()),g=f.hasClass("open"),d(),!g&&f.toggleClass("open"),!1}},a.fn.dropdown=function(b){return this.each(function(){var d=a(this),e=d.data("dropdown");e||d.data("dropdown",e=new c(this)),typeof b=="string"&&e[b].call(d)})},a.fn.dropdown.Constructor=c,a(function(){a("html").on("click.dropdown.data-api",d),a("body").on("click.dropdown.data-api",b,c.prototype.toggle)})}(window.jQuery),!function(a){function c(){var b=this,c=setTimeout(function(){b.$element.off(a.support.transition.end),d.call(b)},500);this.$element.one(a.support.transition.end,function(){clearTimeout(c),d.call(b)})}function d(a){this.$element.hide().trigger("hidden"),e.call(this)}function e(b){var c=this,d=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var e=a.support.transition&&d;this.$backdrop=a('<div class="modal-backdrop '+d+'" />').appendTo(document.body),this.options.backdrop!="static"&&this.$backdrop.click(a.proxy(this.hide,this)),e&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),e?this.$backdrop.one(a.support.transition.end,b):b()}else!this.isShown&&this.$backdrop?(this.$backdrop.removeClass("in"),a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one(a.support.transition.end,a.proxy(f,this)):f.call(this)):b&&b()}function f(){this.$backdrop.remove(),this.$backdrop=null}function g(){var b=this;this.isShown&&this.options.keyboard?a(document).on("keyup.dismiss.modal",function(a){a.which==27&&b.hide()}):this.isShown||a(document).off("keyup.dismiss.modal")}"use strict";var b=function(b,c){this.options=a.extend({},a.fn.modal.defaults,c),this.$element=a(b).delegate('[data-dismiss="modal"]',"click.dismiss.modal",a.proxy(this.hide,this))};b.prototype={constructor:b,toggle:function(){return this[this.isShown?"hide":"show"]()},show:function(){var b=this;if(this.isShown)return;a("body").addClass("modal-open"),this.isShown=!0,this.$element.trigger("show"),g.call(this),e.call(this,function(){var c=a.support.transition&&b.$element.hasClass("fade");!b.$element.parent().length&&b.$element.appendTo(document.body),b.$element.show(),c&&b.$element[0].offsetWidth,b.$element.addClass("in"),c?b.$element.one(a.support.transition.end,function(){b.$element.trigger("shown")}):b.$element.trigger("shown")})},hide:function(b){b&&b.preventDefault();if(!this.isShown)return;var e=this;this.isShown=!1,a("body").removeClass("modal-open"),g.call(this),this.$element.trigger("hide").removeClass("in"),a.support.transition&&this.$element.hasClass("fade")?c.call(this):d.call(this)}},a.fn.modal=function(c){return this.each(function(){var d=a(this),e=d.data("modal"),f=typeof c=="object"&&c;e||d.data("modal",e=new b(this,f)),typeof c=="string"?e[c]():e.show()})},a.fn.modal.defaults={backdrop:!0,keyboard:!0},a.fn.modal.Constructor=b,a(function(){a("body").on("click.modal.data-api",'[data-toggle="modal"]',function(b){var c=a(this),d,e=a(c.attr("data-target")||(d=c.attr("href"))&&d.replace(/.*(?=#[^\s]+$)/,"")),f=e.data("modal")?"toggle":a.extend({},e.data(),c.data());b.preventDefault(),e.modal(f)})})}(window.jQuery),!function(a){"use strict";var b=function(a,b){this.init("tooltip",a,b)};b.prototype={constructor:b,init:function(b,c,d){var e,f;this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.enabled=!0,this.options.trigger!="manual"&&(e=this.options.trigger=="hover"?"mouseenter":"focus",f=this.options.trigger=="hover"?"mouseleave":"blur",this.$element.on(e,this.options.selector,a.proxy(this.enter,this)),this.$element.on(f,this.options.selector,a.proxy(this.leave,this))),this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(b){return b=a.extend({},a.fn[this.type].defaults,b,this.$element.data()),b.delay&&typeof b.delay=="number"&&(b.delay={show:b.delay,hide:b.delay}),b},enter:function(b){var c=a(b.currentTarget)[this.type](this._options).data(this.type);!c.options.delay||!c.options.delay.show?c.show():(c.hoverState="in",setTimeout(function(){c.hoverState=="in"&&c.show()},c.options.delay.show))},leave:function(b){var c=a(b.currentTarget)[this.type](this._options).data(this.type);!c.options.delay||!c.options.delay.hide?c.hide():(c.hoverState="out",setTimeout(function(){c.hoverState=="out"&&c.hide()},c.options.delay.hide))},show:function(){var a,b,c,d,e,f,g;if(this.hasContent()&&this.enabled){a=this.tip(),this.setContent(),this.options.animation&&a.addClass("fade"),f=typeof this.options.placement=="function"?this.options.placement.call(this,a[0],this.$element[0]):this.options.placement,b=/in/.test(f),a.remove().css({top:0,left:0,display:"block"}).appendTo(b?this.$element:document.body),c=this.getPosition(b),d=a[0].offsetWidth,e=a[0].offsetHeight;switch(b?f.split(" ")[1]:f){case"bottom":g={top:c.top+c.height,left:c.left+c.width/2-d/2};break;case"top":g={top:c.top-e,left:c.left+c.width/2-d/2};break;case"left":g={top:c.top+c.height/2-e/2,left:c.left-d};break;case"right":g={top:c.top+c.height/2-e/2,left:c.left+c.width}}a.css(g).addClass(f).addClass("in")}},setContent:function(){var a=this.tip();a.find(".tooltip-inner").html(this.getTitle()),a.removeClass("fade in top bottom left right")},hide:function(){function d(){var b=setTimeout(function(){c.off(a.support.transition.end).remove()},500);c.one(a.support.transition.end,function(){clearTimeout(b),c.remove()})}var b=this,c=this.tip();c.removeClass("in"),a.support.transition&&this.$tip.hasClass("fade")?d():c.remove()},fixTitle:function(){var a=this.$element;(a.attr("title")||typeof a.attr("data-original-title")!="string")&&a.attr("data-original-title",a.attr("title")||"").removeAttr("title")},hasContent:function(){return this.getTitle()},getPosition:function(b){return a.extend({},b?{top:0,left:0}:this.$element.offset(),{width:this.$element[0].offsetWidth,height:this.$element[0].offsetHeight})},getTitle:function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||(typeof c.title=="function"?c.title.call(b[0]):c.title),a=a.toString().replace(/(^\s*|\s*$)/,""),a},tip:function(){return this.$tip=this.$tip||a(this.options.template)},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(){this[this.tip().hasClass("in")?"hide":"show"]()}},a.fn.tooltip=function(c){return this.each(function(){var d=a(this),e=d.data("tooltip"),f=typeof c=="object"&&c;e||d.data("tooltip",e=new b(this,f)),typeof c=="string"&&e[c]()})},a.fn.tooltip.Constructor=b,a.fn.tooltip.defaults={animation:!0,delay:0,selector:!1,placement:"top",trigger:"hover",title:"",template:'<div class="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>'}}(window.jQuery),!function(a){"use strict";var b=function(a,b){this.init("popover",a,b)};b.prototype=a.extend({},a.fn.tooltip.Constructor.prototype,{constructor:b,setContent:function(){var b=this.tip(),c=this.getTitle(),d=this.getContent();b.find(".popover-title")[a.type(c)=="object"?"append":"html"](c),b.find(".popover-content > *")[a.type(d)=="object"?"append":"html"](d),b.removeClass("fade top bottom left right in")},hasContent:function(){return this.getTitle()||this.getContent()},getContent:function(){var a,b=this.$element,c=this.options;return a=b.attr("data-content")||(typeof c.content=="function"?c.content.call(b[0]):c.content),a=a.toString().replace(/(^\s*|\s*$)/,""),a},tip:function(){return this.$tip||(this.$tip=a(this.options.template)),this.$tip}}),a.fn.popover=function(c){return this.each(function(){var d=a(this),e=d.data("popover"),f=typeof c=="object"&&c;e||d.data("popover",e=new b(this,f)),typeof c=="string"&&e[c]()})},a.fn.popover.Constructor=b,a.fn.popover.defaults=a.extend({},a.fn.tooltip.defaults,{placement:"right",content:"",template:'<div class="popover"><div class="arrow"></div><div class="popover-inner"><h3 class="popover-title"></h3><div class="popover-content"><p></p></div></div></div>'})}(window.jQuery),!function(a){function b(b,c){var d=a.proxy(this.process,this),e=a(b).is("body")?a(window):a(b),f;this.options=a.extend({},a.fn.scrollspy.defaults,c),this.$scrollElement=e.on("scroll.scroll.data-api",d),this.selector=(this.options.target||(f=a(b).attr("href"))&&f.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.$body=a("body").on("click.scroll.data-api",this.selector,d),this.refresh(),this.process()}"use strict",b.prototype={constructor:b,refresh:function(){this.targets=this.$body.find(this.selector).map(function(){var b=a(this).attr("href");return/^#\w/.test(b)&&a(b).length?b:null}),this.offsets=a.map(this.targets,function(b){return a(b).position().top})},process:function(){var a=this.$scrollElement.scrollTop()+this.options.offset,b=this.offsets,c=this.targets,d=this.activeTarget,e;for(e=b.length;e--;)d!=c[e]&&a>=b[e]&&(!b[e+1]||a<=b[e+1])&&this.activate(c[e])},activate:function(a){var b;this.activeTarget=a,this.$body.find(this.selector).parent(".active").removeClass("active"),b=this.$body.find(this.selector+'[href="'+a+'"]').parent("li").addClass("active"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active")}},a.fn.scrollspy=function(c){return this.each(function(){var d=a(this),e=d.data("scrollspy"),f=typeof c=="object"&&c;e||d.data("scrollspy",e=new b(this,f)),typeof c=="string"&&e[c]()})},a.fn.scrollspy.Constructor=b,a.fn.scrollspy.defaults={offset:10},a(function(){a('[data-spy="scroll"]').each(function(){var b=a(this);b.scrollspy(b.data())})})}(window.jQuery),!function(a){"use strict";var b=function(b){this.element=a(b)};b.prototype={constructor:b,show:function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.attr("data-target"),e,f;d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,""));if(b.parent("li").hasClass("active"))return;e=c.find(".active a").last()[0],b.trigger({type:"show",relatedTarget:e}),f=a(d),this.activate(b.parent("li"),c),this.activate(f,f.parent(),function(){b.trigger({type:"shown",relatedTarget:e})})},activate:function(b,c,d){function g(){e.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),b.addClass("active"),f?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active"),d&&d()}var e=c.find("> .active"),f=d&&a.support.transition&&e.hasClass("fade");f?e.one(a.support.transition.end,g):g(),e.removeClass("in")}},a.fn.tab=function(c){return this.each(function(){var d=a(this),e=d.data("tab");e||d.data("tab",e=new b(this)),typeof c=="string"&&e[c]()})},a.fn.tab.Constructor=b,a(function(){a("body").on("click.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(b){b.preventDefault(),a(this).tab("show")})})}(window.jQuery),!function(a){"use strict";var b=function(b,c){this.$element=a(b),this.options=a.extend({},a.fn.typeahead.defaults,c),this.matcher=this.options.matcher||this.matcher,this.sorter=this.options.sorter||this.sorter,this.highlighter=this.options.highlighter||this.highlighter,this.$menu=a(this.options.menu).appendTo("body"),this.source=this.options.source,this.shown=!1,this.listen()};b.prototype={constructor:b,select:function(){var a=this.$menu.find(".active").attr("data-value");return this.$element.val(a),this.hide()},show:function(){var b=a.extend({},this.$element.offset(),{height:this.$element[0].offsetHeight});return this.$menu.css({top:b.top+b.height,left:b.left}),this.$menu.show(),this.shown=!0,this},hide:function(){return this.$menu.hide(),this.shown=!1,this},lookup:function(b){var c=this,d,e;return this.query=this.$element.val(),this.query?(d=a.grep(this.source,function(a){if(c.matcher(a))return a}),d=this.sorter(d),d.length?this.render(d.slice(0,this.options.items)).show():this.shown?this.hide():this):this.shown?this.hide():this},matcher:function(a){return~a.toLowerCase().indexOf(this.query.toLowerCase())},sorter:function(a){var b=[],c=[],d=[],e;while(e=a.shift())e.toLowerCase().indexOf(this.query.toLowerCase())?~e.indexOf(this.query)?c.push(e):d.push(e):b.push(e);return b.concat(c,d)},highlighter:function(a){return a.replace(new RegExp("("+this.query+")","ig"),function(a,b){return"<strong>"+b+"</strong>"})},render:function(b){var c=this;return b=a(b).map(function(b,d){return b=a(c.options.item).attr("data-value",d),b.find("a").html(c.highlighter(d)),b[0]}),b.first().addClass("active"),this.$menu.html(b),this},next:function(b){var c=this.$menu.find(".active").removeClass("active"),d=c.next();d.length||(d=a(this.$menu.find("li")[0])),d.addClass("active")},prev:function(a){var b=this.$menu.find(".active").removeClass("active"),c=b.prev();c.length||(c=this.$menu.find("li").last()),c.addClass("active")},listen:function(){this.$element.on("blur",a.proxy(this.blur,this)).on("keypress",a.proxy(this.keypress,this)).on("keyup",a.proxy(this.keyup,this)),(a.browser.webkit||a.browser.msie)&&this.$element.on("keydown",a.proxy(this.keypress,this)),this.$menu.on("click",a.proxy(this.click,this)).on("mouseenter","li",a.proxy(this.mouseenter,this))},keyup:function(a){a.stopPropagation(),a.preventDefault();switch(a.keyCode){case 40:case 38:break;case 9:case 13:if(!this.shown)return;this.select();break;case 27:this.hide();break;default:this.lookup()}},keypress:function(a){a.stopPropagation();if(!this.shown)return;switch(a.keyCode){case 9:case 13:case 27:a.preventDefault();break;case 38:a.preventDefault(),this.prev();break;case 40:a.preventDefault(),this.next()}},blur:function(a){var b=this;a.stopPropagation(),a.preventDefault(),setTimeout(function(){b.hide()},150)},click:function(a){a.stopPropagation(),a.preventDefault(),this.select()},mouseenter:function(b){this.$menu.find(".active").removeClass("active"),a(b.currentTarget).addClass("active")}},a.fn.typeahead=function(c){return this.each(function(){var d=a(this),e=d.data("typeahead"),f=typeof c=="object"&&c;e||d.data("typeahead",e=new b(this,f)),typeof c=="string"&&e[c]()})},a.fn.typeahead.defaults={source:[],items:8,menu:'<ul class="typeahead dropdown-menu"></ul>',item:'<li><a href="#"></a></li>'},a.fn.typeahead.Constructor=b,a(function(){a("body").on("focus.typeahead.data-api",'[data-provide="typeahead"]',function(b){var c=a(this);if(c.data("typeahead"))return;b.preventDefault(),c.typeahead(c.data())})})}(window.jQuery);
 /*
+ *	lib/js/lib/sprintf.js
+ */
+var sprintf=(function(){function get_type(variable){return Object.prototype.toString.call(variable).slice(8,-1).toLowerCase();}
+function str_repeat(input,multiplier){for(var output=[];multiplier>0;output[--multiplier]=input){}
+return output.join('');}
+var str_format=function(){if(!str_format.cache.hasOwnProperty(arguments[0])){str_format.cache[arguments[0]]=str_format.parse(arguments[0]);}
+return str_format.format.call(null,str_format.cache[arguments[0]],arguments);};str_format.format=function(parse_tree,argv){var cursor=1,tree_length=parse_tree.length,node_type='',arg,output=[],i,k,match,pad,pad_character,pad_length;for(i=0;i<tree_length;i++){node_type=get_type(parse_tree[i]);if(node_type==='string'){output.push(parse_tree[i]);}
+else if(node_type==='array'){match=parse_tree[i];if(match[2]){arg=argv[cursor];for(k=0;k<match[2].length;k++){if(!arg.hasOwnProperty(match[2][k])){arg='';}else{arg=arg[match[2][k]];}}}
+else if(match[1]){arg=argv[match[1]];}
+else{arg=argv[cursor++];}
+if(/[^s]/.test(match[8])&&(get_type(arg)!='number')){throw(sprintf('[sprintf] expecting number but found %s',get_type(arg)));}
+switch(match[8]){case'b':arg=arg.toString(2);break;case'c':arg=String.fromCharCode(arg);break;case'd':arg=parseInt(arg,10);break;case'e':arg=match[7]?arg.toExponential(match[7]):arg.toExponential();break;case'f':arg=match[7]?parseFloat(arg).toFixed(match[7]):parseFloat(arg);break;case'o':arg=arg.toString(8);break;case's':arg=((arg=String(arg))&&match[7]?arg.substring(0,match[7]):arg);break;case'u':arg=Math.abs(arg);break;case'x':arg=arg.toString(16);break;case'X':arg=arg.toString(16).toUpperCase();break;}
+arg=(/[def]/.test(match[8])&&match[3]&&arg>=0?'+'+arg:arg);pad_character=match[4]?match[4]=='0'?'0':match[4].charAt(1):' ';pad_length=match[6]-String(arg).length;pad=match[6]?str_repeat(pad_character,pad_length):'';output.push(match[5]?arg+pad:pad+arg);}}
+return output.join('');};str_format.cache={};str_format.parse=function(fmt){var _fmt=fmt,match=[],parse_tree=[],arg_names=0;while(_fmt){if((match=/^[^\x25]+/.exec(_fmt))!==null){parse_tree.push(match[0]);}
+else if((match=/^\x25{2}/.exec(_fmt))!==null){parse_tree.push('%');}
+else if((match=/^\x25(?:([1-9]\d*)\$|\(([^\)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-fosuxX])/.exec(_fmt))!==null){if(match[2]){arg_names|=1;var field_list=[],replacement_field=match[2],field_match=[];if((field_match=/^([a-z_][a-z_\d]*)/i.exec(replacement_field))!==null){field_list.push(field_match[1]);while((replacement_field=replacement_field.substring(field_match[0].length))!==''){if((field_match=/^\.([a-z_][a-z_\d]*)/i.exec(replacement_field))!==null){field_list.push(field_match[1]);}
+else if((field_match=/^\[(\d+)\]/.exec(replacement_field))!==null){field_list.push(field_match[1]);}
+else{throw('[sprintf] huh?');}}}
+else{throw('[sprintf] huh?');}
+match[2]=field_list;}
+else{arg_names|=2;}
+if(arg_names===3){throw('[sprintf] mixing positional and named placeholders is not (yet) supported');}
+parse_tree.push(match);}
+else{throw('[sprintf] huh?');}
+_fmt=_fmt.substring(match[0].length);}
+return parse_tree;};return str_format;})();var vsprintf=function(fmt,argv){argv.unshift(fmt);return sprintf.apply(null,argv);};
+/*
  *	lib/js/core.min.js
  */
 /*
@@ -101,6 +128,15 @@
 state=window.location.hash;if(state!=src){window.location.hash=state;}
 else{document.title=title;}}}
 /*
+ *	lib/js/wn/misc/user.js
+ */
+wn.user_info=function(uid){var def={'fullname':uid,'image':'lib/images/ui/no_img_m.gif'}
+if(!wn.boot.user_info)return def
+if(!wn.boot.user_info[uid])return def
+if(!wn.boot.user_info[uid].fullname)
+wn.boot.user_info[uid].fullname=uid;if(!wn.boot.user_info[uid].image)
+wn.boot.user_info[uid].image=def.image;return wn.boot.user_info[uid];}
+/*
  *	lib/js/lib/json2.js
  */
 var JSON;if(!JSON){JSON={};}
@@ -165,6 +201,7 @@
 function $p(ele,top,left){ele.style.position='absolute';ele.style.top=top+'px';ele.style.left=left+'px';}
 function replace_newlines(t){return t?t.replace(/\n/g,'<br>'):'';}
 function cstr(s){if(s==null)return'';return s+'';}
+function nth(number){number=cint(number);var s='th';if((number+'').substr(-1)=='1')s='st';if((number+'').substr(-1)=='2')s='nd';if((number+'').substr(-1)=='3')s='rd';return number+s;}
 function flt(v,decimals){if(v==null||v=='')return 0;v=(v+'').replace(/,/g,'');v=parseFloat(v);if(isNaN(v))
 v=0;if(decimals!=null)
 return v.toFixed(decimals);return v;}
@@ -188,8 +225,7 @@
 function has_common(list1,list2){if(!list1||!list2)return false;for(var i=0;i<list1.length;i++){if(in_list(list2,list1[i]))return true;}
 return false;}
 var inList=in_list;function add_lists(l1,l2){var l=[];for(var k in l1)l.push(l1[k]);for(var k in l2)l.push(l2[k]);return l;}
-function docstring(obj){var l=[];for(key in obj){var v=obj[key];if(v!=null){if(typeof(v)==typeof(1)){l[l.length]="'"+key+"':"+(v+'');}else{v=v+'';l[l.length]="'"+key+"':'"+v.replace(/'/g,"\\'").replace(/\n/g,"\\n")+"'";}}}
-return"{"+l.join(',')+'}';}
+function docstring(obj){return JSON.stringify(obj);}
 function DocLink(p,doctype,name,onload){var a=$a(p,'span','link_type');a.innerHTML=a.dn=name;a.dt=doctype;a.onclick=function(){loaddoc(this.dt,this.dn,onload)};return a;}
 var doc_link=DocLink;var known_numbers={0:'zero',1:'one',2:'two',3:'three',4:'four',5:'five',6:'six',7:'seven',8:'eight',9:'nine',10:'ten',11:'eleven',12:'twelve',13:'thirteen',14:'fourteen',15:'fifteen',16:'sixteen',17:'seventeen',18:'eighteen',19:'nineteen',20:'twenty',30:'thirty',40:'forty',50:'fifty',60:'sixty',70:'seventy',80:'eighty',90:'ninety'}
 function in_words(n){var is_million=wn.control_panel.currency_format=='Millions'?1:0;n=cint(n)
@@ -234,7 +270,7 @@
 else if(user_fmt=='dd/mm/yyyy'){var d=d.split('/');return d[2]+'-'+d[1]+'-'+d[0];}
 else if(user_fmt=='yyyy-mm-dd'){return d;}
 else if(user_fmt=='mm/dd/yyyy'){var d=d.split('/');return d[2]+'-'+d[0]+'-'+d[1];}
-else if(user_fmt=='mm-dd-yyyy'){var d=d.split('-');return d[2]+'-'+d[0]+'-'+d[1];}},global_date_format:function(d){if(d.substr)d=this.str_to_obj(d);return d.getDate()+' '+month_list_full[d.getMonth()]+' '+d.getFullYear();},get_today:function(){var today=new Date();var m=(today.getMonth()+1)+'';if(m.length==1)m='0'+m;var d=today.getDate()+'';if(d.length==1)d='0'+d;return today.getFullYear()+'-'+m+'-'+d;},get_cur_time:function(){var d=new Date();var hh=d.getHours()+''
+else if(user_fmt=='mm-dd-yyyy'){var d=d.split('-');return d[2]+'-'+d[0]+'-'+d[1];}},global_date_format:function(d){if(d.substr)d=this.str_to_obj(d);return nth(d.getDate())+' '+month_list_full[d.getMonth()]+' '+d.getFullYear();},get_today:function(){var today=new Date();var m=(today.getMonth()+1)+'';if(m.length==1)m='0'+m;var d=today.getDate()+'';if(d.length==1)d='0'+d;return today.getFullYear()+'-'+m+'-'+d;},get_cur_time:function(){var d=new Date();var hh=d.getHours()+''
 var mm=cint(d.getMinutes()/5)*5+''
 return(hh.length==1?'0'+hh:hh)+':'+(mm.length==1?'0'+mm:mm);}}
 wn.datetime.only_date=function(val){if(val==null||val=='')return null;if(val.search(':')!=-1){var tmp=val.split(' ');var d=tmp[0].split('-');}else{var d=val.split('-');}
@@ -246,7 +282,8 @@
 wn.datetime.time_to_hhmm=function(hh,mm,am){if(am=='AM'&&hh=='12'){hh='00';}else if(am=='PM'&&hh!='12'){hh=cint(hh)+12;}
 return hh+':'+mm;}
 function prettyDate(time){if(!time)return''
-var date=new Date((time||"").replace(/-/g,"/").replace(/[TZ]/g," ").replace(/\.[0-9]*/,"")),diff=(((new Date()).getTime()-date.getTime())/1000),day_diff=Math.floor(diff/86400);if(isNaN(day_diff)||day_diff<0)
+var date=time;if(typeof(time)=="string")
+date=new Date((time||"").replace(/-/g,"/").replace(/[TZ]/g," ").replace(/\.[0-9]*/,""));var diff=(((new Date()).getTime()-date.getTime())/1000),day_diff=Math.floor(diff/86400);if(isNaN(day_diff)||day_diff<0)
 return'';return day_diff==0&&(diff<60&&"just now"||diff<120&&"1 minute ago"||diff<3600&&Math.floor(diff/60)+" minutes ago"||diff<7200&&"1 hour ago"||diff<86400&&Math.floor(diff/3600)+" hours ago")||day_diff==1&&"Yesterday"||day_diff<7&&day_diff+" days ago"||day_diff<31&&Math.ceil(day_diff/7)+" weeks ago"||day_diff<365&&Math.ceil(day_diff/30)+" months ago"||"more than "+Math.floor(day_diff/365)+" year(s) ago";}
 if(typeof jQuery!="undefined")
 jQuery.fn.prettyDate=function(){return this.each(function(){var date=prettyDate(this.title);if(date)
@@ -678,8 +715,8 @@
 this.clear=function(){this.results_area.innerHTML='';this.table=null;$ds(this.results_area);$dh(this.no_results_area);}
 this.make_results=function(r,rt){if(this.start==0)this.clear();$dh(this.more_button_area);if(this.loading_img)$dh(this.loading_img)
 if(r.message)r.values=r.message;if(r.values&&r.values.length){this.values=r.values;var m=Math.min(r.values.length,this.page_length);for(var i=0;i<m;i++){var row=this.add_row();this.opts.render_row(row,r.values[i],this,i);}
-this.start+=m;if(r.values.length>this.page_length)$ds(this.more_button_area);}else{if(this.start==0){$dh(this.results_area);$ds(this.no_results_area);}}
-if(this.onrun)this.onrun();if(this.opts.onrun)this.opts.onrun();}
+this.start+=m;if(r.values.length>=this.page_length)$ds(this.more_button_area);}else{if(this.start==0){$dh(this.results_area);$ds(this.no_results_area);}}
+if(this.onrun)this.onrun();if(this.opts.onrun)this.opts.onrun();if(this.opts.callback)this.opts.callback(r);}
 this.add_row=function(){return $a(this.results_area,'div','',(opts.cell_style?opts.cell_style:{padding:'3px 0px'}));}
 this.run=function(callback,append){if(callback)
 this.onrun=callback;if(!append)
@@ -1000,7 +1037,7 @@
 /*
  *	lib/js/legacy/app.js
  */
-var popup_cont;var session={};var start_sid=null;if(!wn)var wn={};function startup(){start_sid=get_cookie('sid');popup_cont=$a(document.getElementsByTagName('body')[0],'div');var setup_globals=function(r){wn.boot=r;profile=r.profile;user=r.profile.name;user_fullname=wn.boot.user_fullnames?wn.boot.user_fullnames[user]:'Guest';user_defaults=profile.defaults;user_roles=profile.roles;user_email=profile.email;home_page=r.home_page;_p.letter_heads=r.letter_heads;sys_defaults=r.sysdefaults;session.rt=profile.can_read;if(r.ipinfo)session.ipinfo=r.ipinfo;session.dt_labels=r.dt_labels;session.rev_dt_labels={}
+var popup_cont;var session={};var start_sid=null;if(!wn)var wn={};function startup(){start_sid=get_cookie('sid');popup_cont=$a(document.getElementsByTagName('body')[0],'div');var setup_globals=function(r){wn.boot=r;profile=r.profile;user=r.profile.name;user_fullname=wn.user_info(user).fullname;user_defaults=profile.defaults;user_roles=profile.roles;user_email=profile.email;home_page=r.home_page;_p.letter_heads=r.letter_heads;sys_defaults=r.sysdefaults;session.rt=profile.can_read;if(r.ipinfo)session.ipinfo=r.ipinfo;session.dt_labels=r.dt_labels;session.rev_dt_labels={}
 if(r.dt_labels){for(key in r.dt_labels)session.rev_dt_labels[r.dt_labels[key]]=key;}
 wn.control_panel=r.control_panel;}
 var setup_history=function(r){rename_observers.push(nav_obj);}
@@ -1040,25 +1077,24 @@
 /*
  *	erpnext/startup/startup.js
  */
-var current_module;var is_system_manager=0;wn.provide('erpnext.startup');erpnext.modules={'Selling':'selling-home','Accounts':'accounts-home','Stock':'stock-home','Buying':'buying-home','Support':'support-home','Projects':'projects-home','Production':'production-home','Website':'website-home','HR':'hr-home','Setup':'Setup','Activity':'Event Updates','To Do':'todo','Calendar':'calendar','Messages':'messages','Knowledge Base':'questions'}
+var current_module;var is_system_manager=0;wn.provide('erpnext.startup');erpnext.modules={'Selling':'selling-home','Accounts':'accounts-home','Stock':'stock-home','Buying':'buying-home','Support':'support-home','Projects':'projects-home','Production':'production-home','Website':'website-home','HR':'hr-home','Setup':'Setup','Activity':'activity','To Do':'todo','Calendar':'calendar','Messages':'messages','Knowledge Base':'questions'}
 erpnext.startup.set_globals=function(){pscript.is_erpnext_saas=cint(wn.control_panel.sync_with_gateway)
 if(inList(user_roles,'System Manager'))is_system_manager=1;}
 erpnext.startup.start=function(){$('#startup_div').html('Starting up...').toggle(true);erpnext.startup.set_globals();if(wn.boot.custom_css){set_style(wn.boot.custom_css);}
+if(wn.boot.user_background){erpnext.set_user_background(wn.boot.user_background);}
 if(user=='Guest'){if(wn.boot.website_settings.title_prefix){wn.title_prefix=wn.boot.website_settings.title_prefix;}}else{erpnext.toolbar.setup();erpnext.startup.set_periodic_updates();$('footer').html('<div class="web-footer erpnext-footer">\
-   Powered by <a href="https://erpnext.com">ERPNext</a></div>');}
+   Powered by <a href="https://erpnext.com">ERPNext</a></div>');if(in_list(user_roles,'System Manager')&&(wn.boot.setup_complete=='No')){wn.require("erpnext/startup/js/complete_setup.js");erpnext.complete_setup();}}
 $('#startup_div').toggle(false);}
 show_chart_browser=function(nm,chart_type){var call_back=function(){if(nm=='Sales Browser'){var sb_obj=new SalesBrowser();sb_obj.set_val(chart_type);}
 else if(nm=='Accounts Browser')
 pscript.make_chart(chart_type);}
 loadpage(nm,call_back);}
-ModulePage=function(parent,module_name,module_label,help_page,callback){this.parent=parent;page_body.cur_page.module_page=this;this.wrapper=$a(parent,'div');this.module_name=module_name;this.transactions=[];this.page_head=new PageHeader(this.wrapper,module_label);if(help_page){var btn=this.page_head.add_button('Help',function(){loadpage(this.help_page)},1,'ui-icon-help')
-btn.help_page=help_page;}
-if(callback)this.callback=function(){callback();}}
 var update_messages=function(){if(inList(['Guest'],user)){return;}
 $c_page('home','event_updates','get_unread_messages',null,function(r,rt){if(!r.exc){page_body.wntoolbar.set_new_comments(r.message);var circle=$('#msg_count')
 if(circle){if(r.message.length){circle.find('span:first').text(r.message.length);circle.toggle(true);}else{circle.toggle(false);}}}else{clearInterval(wn.updates.id);}});}
 erpnext.startup.set_periodic_updates=function(){wn.updates={};if(wn.updates.id){clearInterval(wn.updates.id);}
 wn.updates.id=setInterval(update_messages,60000);}
+erpnext.set_user_background=function(src){set_style(repl('body { background: url("files/%(src)s") repeat !important;}',{src:src}))}
 $(document).bind('startup',function(){erpnext.startup.start();});
 /*
  *	erpnext/website/js/topbar.js
diff --git a/version.num b/version.num
index 5d1d1b1..571c437 100644
--- a/version.num
+++ b/version.num
@@ -1 +1 @@
-755
\ No newline at end of file
+774