blob: e20ece3d10e85024741dcc5b7aff8ca79f7698e6 [file] [log] [blame]
Rushabh Mehta8fa3e6c2013-01-24 13:09:39 +05301# -*- coding: utf-8 -*-
2
Rushabh Mehta3966f1d2012-02-23 12:35:32 +05303# ERPNext - web based ERP (http://erpnext.com)
4# Copyright (C) 2012 Web Notes Technologies Pvt Ltd
5#
6# This program is free software: you can redistribute it and/or modify
7# it under the terms of the GNU General Public License as published by
8# the Free Software Foundation, either version 3 of the License, or
9# (at your option) any later version.
10#
11# This program is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14# GNU General Public License for more details.
15#
16# You should have received a copy of the GNU General Public License
17# along with this program. If not, see <http://www.gnu.org/licenses/>.
18
Rushabh Mehta7c932002014-03-11 16:15:05 +053019# default settings that can be made for a user.
Anand Doshi486f9df2012-07-19 13:40:31 +053020from __future__ import unicode_literals
Pratik Vyasc1e6e4c2011-06-08 14:37:15 +053021
Rushabh Mehta793ba6b2014-02-14 15:47:51 +053022import frappe
Anand Doshi19df1882013-02-17 00:26:59 +053023
Rushabh Mehta2eef40b2012-07-16 14:16:57 +053024product_name = "ERPNext"
Rushabh Mehta7c932002014-03-11 16:15:05 +053025user_defaults = {
Rushabh Mehta2eef40b2012-07-16 14:16:57 +053026 "Company": "company",
27 "Territory": "territory"
28}
Rushabh Mehta4b9827a2013-02-12 19:20:39 +053029
Pratik Vyasc1e6e4c2011-06-08 14:37:15 +053030# add startup propertes
Rushabh Mehtae5984872012-08-03 14:15:07 +053031mail_footer = """<div style="padding: 7px; text-align: right; color: #888"><small>Sent via
Anand Doshicb72e012013-10-31 19:06:34 +053032 <a style="color: #888" href="http://erpnext.org">ERPNext</a></div>"""
Rushabh Mehtae5984872012-08-03 14:15:07 +053033
34def get_monthly_bulk_mail_limit():
Rushabh Mehta793ba6b2014-02-14 15:47:51 +053035 import frappe
Rushabh Mehtae5984872012-08-03 14:15:07 +053036 # if global settings, then 500 or unlimited
Anand Doshie30511d2014-03-03 20:32:20 +053037 if frappe.db.get_value('Outgoing Email Settings', None, 'mail_server'):
Rushabh Mehtae5984872012-08-03 14:15:07 +053038 return 999999
39 else:
Rushabh Mehta49dc5da2012-08-03 16:02:24 +053040 return 500