blob: 625a513cb1c39a79fa98f6dc328c3aaeab344f72 [file] [log] [blame]
Rushabh Mehtae67d1fb2013-08-05 14:59:54 +05301// Copyright (c) 2013, Web Notes Technologies Pvt. Ltd.
2// License: GNU General Public License v3. See license.txt
3
Anand Doshic9d1ac42012-04-17 13:54:53 +05304wn.provide('erpnext');
Rushabh Mehta8c309be2012-01-20 13:47:16 +05305
Rushabh Mehta865c00a2012-01-24 14:33:21 +05306wn.modules_path = 'erpnext';
Rushabh Mehta8c309be2012-01-20 13:47:16 +05307
Rushabh Mehtaa9209432012-05-07 18:00:57 +05308// add toolbar icon
Rushabh Mehta8c309be2012-01-20 13:47:16 +05309$(document).bind('toolbar_setup', function() {
Anand Doshi28d59a02013-07-19 17:50:25 +053010 var brand = ($("<div></div>").append(wn.boot.website_settings.brand_html).text() || 'erpnext');
11 $('.navbar-brand').html('<div style="display: inline-block;">\
Anand Doshi674765a2013-07-18 19:28:46 +053012 <object type="image/svg+xml" data="app/images/splash.svg" class="toolbar-splash"></object>\
Anand Doshi28d59a02013-07-19 17:50:25 +053013 </div>' + brand)
14 .attr("title", brand)
Anand Doshic8b2c0f2013-07-18 18:15:56 +053015 .addClass("navbar-icon-home")
Anand Doshi28d59a02013-07-19 17:50:25 +053016 .css({
17 "max-width": "200px",
18 "overflow": "hidden",
19 "text-overflow": "ellipsis",
20 "white-space": "nowrap"
21 });
Anand Doshi859cb722012-04-10 11:35:19 +053022});
Rushabh Mehta3ae25422013-08-07 11:45:39 +053023
24wn.provide('wn.ui.misc');
25wn.ui.misc.about = function() {
26 if(!wn.ui.misc.about_dialog) {
27 var d = new wn.ui.Dialog({title:'About ERPNext'})
28
29 $(d.body).html(repl("<div>\
30 <p>ERPNext is an open-source web based ERP made by Web Notes Technologies Pvt Ltd.\
31 to provide an integrated tool to manage most processes in a small organization.\
32 For more information about Web Notes, or to buy hosting servies, go to \
33 <a href='https://erpnext.com'>https://erpnext.com</a>.</p>\
34 <p>To report an issue, go to <a href='https://github.com/webnotes/erpnext/issues'>GitHub Issues</a></p>\
35 <hr>\
36 <p><a href='http://www.gnu.org/copyleft/gpl.html'>License: GNU General Public License Version 3</a></p>\
37 </div>", wn.app));
38
39 wn.ui.misc.about_dialog = d;
40 }
41
42 wn.ui.misc.about_dialog.show();
43}