diff --git a/addons/account/wizard/account_financial_report_view.xml b/addons/account/wizard/account_financial_report_view.xml index f587141da1e..39c4fac83fd 100644 --- a/addons/account/wizard/account_financial_report_view.xml +++ b/addons/account/wizard/account_financial_report_view.xml @@ -53,7 +53,7 @@ form new - + {} diff --git a/addons/crm/crm.py b/addons/crm/crm.py index d3e19e81f02..ef3d66f05ce 100644 --- a/addons/crm/crm.py +++ b/addons/crm/crm.py @@ -227,10 +227,7 @@ class crm_base(object): return uid def _get_section(self, cr, uid, context=None): - """Gives section id for current User - """ - user = self.pool.get('res.users').browse(cr, uid, uid, context=context) - return user.context_section_id.id or False + return False def onchange_partner_address_id(self, cr, uid, ids, add, email=False): """This function returns value of partner email based on Partner Address @@ -608,20 +605,4 @@ def _links_get(self, cr, uid, context=None): res = obj.read(cr, uid, ids, ['object', 'name'], context) return [(r['object'], r['name']) for r in res] -class users(osv.osv): - _inherit = 'res.users' - _description = "Users" - _columns = { - 'context_section_id': fields.many2one('crm.case.section', 'Sales Team'), - } - - def create(self, cr, uid, vals, context=None): - res = super(users, self).create(cr, uid, vals, context=context) - section_obj=self.pool.get('crm.case.section') - if vals.get('context_section_id'): - section_obj.write(cr, uid, [vals['context_section_id']], {'member_ids':[(4, res)]}, context) - return res - -users() - # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/crm/crm_lead_menu.xml b/addons/crm/crm_lead_menu.xml index 5fc8891edb4..02fc3369041 100644 --- a/addons/crm/crm_lead_menu.xml +++ b/addons/crm/crm_lead_menu.xml @@ -9,7 +9,7 @@ ['|', ('type','=','lead'), ('type','=',False)] - {'default_type': 'lead', 'search_default_section_id': section_id, 'stage_type': 'lead', 'search_default_inbox': 1} + {'default_type':'lead', 'stage_type':'lead'} <img src="http://www.thaicrmsoftware.com/wp-content/uploads/2011/11/lead-conversion.jpg" align="right" style="padding: 6px" width="306" height="223"> <h2>Create your first OpenERP Lead </h2> @@ -66,7 +66,7 @@ crm.lead kanban,tree,form,graph,calendar [('type','=','opportunity')] - {'search_default_new':1, 'search_default_open':1, 'search_default_section_id':section_id, 'stage_type': 'opportunity', 'default_type': 'opportunity'} + {'search_default_new':1, 'search_default_open':1, 'stage_type': 'opportunity', 'default_type': 'opportunity'} With opportunities you can manage and keep track of your sales pipeline by creating specific customer- or prospect-related sales documents to follow up potential sales. Information such as expected revenue, opportunity stage, expected closing date, communication history and much more can be stored. Opportunities can be connected to the email gateway: new emails may create opportunities, each of them automatically gets the history of the conversation with the customer. diff --git a/addons/crm/crm_lead_view.xml b/addons/crm/crm_lead_view.xml index d5a0749649a..6b66e9e988d 100644 --- a/addons/crm/crm_lead_view.xml +++ b/addons/crm/crm_lead_view.xml @@ -137,7 +137,7 @@ -
+
@@ -341,7 +341,7 @@ context="{'invisible_section': False}"> -
+
@@ -589,7 +589,7 @@ context="{'invisible_section': False}" widget="selection"> form tree,calendar - {"search_default_user_id":uid, 'search_default_section_id': section_id} + {"search_default_user_id":uid} @@ -67,7 +67,7 @@ tree,calendar [] - + {} This tool allows you to log your inbound calls on the fly. Each call you get will appear on the partner form to trace every contact you have with a partner. From the phone call form, you can trigger a request for another call, a meeting or an opportunity. @@ -105,7 +105,7 @@ tree,calendar [('state','!=','done')] - + Scheduled calls list all the calls to be done by your sales team. A salesman can record the information about the call in the form view. This information will be stored in the partner form to trace every contact you have with a customer. You can also import a .CSV file with a list of calls to be done by your sales team. diff --git a/addons/crm/crm_phonecall_view.xml b/addons/crm/crm_phonecall_view.xml index af49956eda8..136af4cf51e 100644 --- a/addons/crm/crm_phonecall_view.xml +++ b/addons/crm/crm_phonecall_view.xml @@ -211,7 +211,7 @@ @@ -261,7 +261,7 @@ diff --git a/addons/crm/crm_view.xml b/addons/crm/crm_view.xml index c39c522a607..a11e6a4ecec 100644 --- a/addons/crm/crm_view.xml +++ b/addons/crm/crm_view.xml @@ -378,32 +378,6 @@ groups="base.group_no_one" sequence="15" parent="base.menu_base_config" /> - - view.users.form.crm.modif.inherited1 - res.users - - form - - - - - - - - - view.users.form.crm.modif.inherited2 - res.users - form - - - - - - - - - diff --git a/addons/crm_claim/crm_claim_menu.xml b/addons/crm_claim/crm_claim_menu.xml index 2f87da24b4c..734302fa7f9 100644 --- a/addons/crm_claim/crm_claim_menu.xml +++ b/addons/crm_claim/crm_claim_menu.xml @@ -20,7 +20,7 @@ form tree,calendar,form - {'search_default_section_id': section_id,"search_default_user_id":uid, "stage_type":'claim'} + {"search_default_user_id":uid, "stage_type":'claim'} Record and track your customers' claims. Claims may be linked to a sales order or a lot. You can send emails with attachments and keep the full history for a claim (emails sent, intervention type and so on). Claims may automatically be linked to an email address using the mail gateway module. diff --git a/addons/crm_fundraising/crm_fundraising_menu.xml b/addons/crm_fundraising/crm_fundraising_menu.xml index ae758a58392..38187ed1d4d 100644 --- a/addons/crm_fundraising/crm_fundraising_menu.xml +++ b/addons/crm_fundraising/crm_fundraising_menu.xml @@ -13,7 +13,7 @@ crm.fundraising tree,form,graph - {"search_default_user_id":uid, 'search_default_section_id': section_id} + {"search_default_user_id":uid} If you need to collect money for your organization or a campaign, Fund Raising allows you to track all your fund raising activities. In the search list, filter by funds description, email, history and probability of success. diff --git a/addons/crm_fundraising/crm_fundraising_view.xml b/addons/crm_fundraising/crm_fundraising_view.xml index 48eb1aa3072..41a4a4ed4fc 100644 --- a/addons/crm_fundraising/crm_fundraising_view.xml +++ b/addons/crm_fundraising/crm_fundraising_view.xml @@ -234,7 +234,7 @@ diff --git a/addons/crm_helpdesk/crm_helpdesk_menu.xml b/addons/crm_helpdesk/crm_helpdesk_menu.xml index b2c7337b7d3..f5c36eb1ab1 100644 --- a/addons/crm_helpdesk/crm_helpdesk_menu.xml +++ b/addons/crm_helpdesk/crm_helpdesk_menu.xml @@ -17,7 +17,7 @@ tree,calendar,form - {"search_default_user_id":uid, 'search_default_section_id': section_id} + {"search_default_user_id":uid} Helpdesk and Support allow you to track your interventions. Select a customer, add notes and categorize interventions with partners if necessary. You can also assign a priority level. Use the OpenERP Issues system to manage your support activities. Issues can be connected to the email gateway: new emails may create issues, each of them automatically gets the history of the conversation with the customer. diff --git a/addons/crm_helpdesk/crm_helpdesk_view.xml b/addons/crm_helpdesk/crm_helpdesk_view.xml index 48681357660..fb58c2dd058 100644 --- a/addons/crm_helpdesk/crm_helpdesk_view.xml +++ b/addons/crm_helpdesk/crm_helpdesk_view.xml @@ -232,7 +232,7 @@ diff --git a/addons/hr/hr_department.py b/addons/hr/hr_department.py index 3332207cb17..e0ad03721d6 100644 --- a/addons/hr/hr_department.py +++ b/addons/hr/hr_department.py @@ -105,14 +105,5 @@ class ir_action_window(osv.osv): ir_action_window() -class res_users(osv.osv): - _inherit = 'res.users' - _description = 'User' - - _columns = { - 'context_department_id': fields.many2one('hr.department', 'Departments'), - } - -res_users() # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/hr/hr_department_view.xml b/addons/hr/hr_department_view.xml index 0171b41e881..0a66fd478b9 100644 --- a/addons/hr/hr_department_view.xml +++ b/addons/hr/hr_department_view.xml @@ -57,27 +57,5 @@ - - res.users.form - form - res.users - - - - - - - - - view.department.form.hr.inherited1 - res.users - - form - - - - - - diff --git a/addons/hr/hr_view.xml b/addons/hr/hr_view.xml index 4147ebc30a9..a69be2e974a 100644 --- a/addons/hr/hr_view.xml +++ b/addons/hr/hr_view.xml @@ -106,7 +106,6 @@ - @@ -182,7 +181,7 @@ form kanban,tree,form [] - {"search_default_department_id": department_id} + {} Here you can manage your work force by creating employees and assigning them specific properties in the system. Maintain all employee related information and keep track of anything that needs to be recorded for them. The personal information tab will help you maintain their identity data. The Categories tab gives you the opportunity to assign them related employee categories depending on their position and activities within the company. A category can be a seniority level within the company or a department. The Timesheets tab allows to assign them a specific timesheet and analytic journal where they will be able to enter time through the system. In the note tab, you can enter text data that should be recorded for a specific employee. @@ -410,7 +409,6 @@ - @@ -428,7 +426,7 @@ form tree,form - {"search_default_Current":1,"search_default_department_id": department_id} + {"search_default_Current":1} Job Positions are used to define jobs and their requirements. You can keep track of the number of employees you have per job position and how many you expect in the future. You can also attach a survey to a job position that will be used in the recruitment process to evaluate the applicants for this job position. diff --git a/addons/hr_expense/hr_expense_view.xml b/addons/hr_expense/hr_expense_view.xml index a62a9026ecf..1d4a3162f42 100644 --- a/addons/hr_expense/hr_expense_view.xml +++ b/addons/hr_expense/hr_expense_view.xml @@ -148,12 +148,9 @@ - - diff --git a/addons/hr_holidays/hr_holidays_view.xml b/addons/hr_holidays/hr_holidays_view.xml index 9f8f998cbd9..a00deb5bcd4 100644 --- a/addons/hr_holidays/hr_holidays_view.xml +++ b/addons/hr_holidays/hr_holidays_view.xml @@ -262,7 +262,7 @@ hr.holidays form - {"search_default_department_id": department_id} + {} [('type','=','remove')] Leave requests can be recorded by employees and validated by their managers. Once a leave request is validated, it appears automatically in the agenda of the employee. You can define several allowance types (paid holidays, sickness, etc.) and manage allowances per type. @@ -295,7 +295,7 @@ Requests Approve hr.holidays form - {'default_type': 'add', 'search_default_approve':1,"search_default_department_id": department_id} + {'default_type': 'add', 'search_default_approve':1} [('type','=','remove')] @@ -321,7 +321,7 @@ Allocation Requests hr.holidays form - {'default_type':'add',"search_default_department_id": department_id} + {'default_type':'add'} [('type','=','add')] diff --git a/addons/hr_recruitment/hr_recruitment_menu.xml b/addons/hr_recruitment/hr_recruitment_menu.xml index a30d2ee7ac7..426185abf86 100644 --- a/addons/hr_recruitment/hr_recruitment_menu.xml +++ b/addons/hr_recruitment/hr_recruitment_menu.xml @@ -8,7 +8,7 @@ hr.applicant kanban,tree,form,graph,calendar - {'search_default_filter_inprogress':1, 'search_default_filter_new':1, "search_default_department_id": department_id, 'search_default_inbox': 1} + {'search_default_filter_inprogress':1,'search_default_filter_new':1} From this menu you can track applicants in the recruitment process and manage all operations: meetings, interviews, phone calls, etc. If you setup the email gateway, applicants and their attached CV are created automatically when an email is sent to jobs@yourcompany.com. If you install the document management modules, all documents (CV and motivation letters) are indexed automatically, so that you can easily search through their content. diff --git a/addons/hr_recruitment/hr_recruitment_view.xml b/addons/hr_recruitment/hr_recruitment_view.xml index 03b72d09f46..8d62c1f906f 100644 --- a/addons/hr_recruitment/hr_recruitment_view.xml +++ b/addons/hr_recruitment/hr_recruitment_view.xml @@ -152,7 +152,7 @@ -
+
diff --git a/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml b/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml index d822f10d944..f6323ffbc29 100644 --- a/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml +++ b/addons/hr_timesheet_sheet/hr_timesheet_sheet_view.xml @@ -165,11 +165,7 @@ - - - + diff --git a/addons/import_sugarcrm/import_sugarcrm.py b/addons/import_sugarcrm/import_sugarcrm.py index 3ff14bcf1c7..11d3c26a207 100644 --- a/addons/import_sugarcrm/import_sugarcrm.py +++ b/addons/import_sugarcrm/import_sugarcrm.py @@ -898,7 +898,6 @@ class sugar_import(import_framework): 'context_lang' : 'context_lang', 'password' : 'password', '.id' : '.id', - 'context_department_id/id': self.get_users_department, 'user_email' : 'email1', } } diff --git a/addons/l10n_be/account_financial_report.xml b/addons/l10n_be/account_financial_report.xml index 6f386b89184..ccc118d30ae 100644 --- a/addons/l10n_be/account_financial_report.xml +++ b/addons/l10n_be/account_financial_report.xml @@ -738,7 +738,7 @@ form new - + {} diff --git a/addons/mail/res_users_view.xml b/addons/mail/res_users_view.xml index 072f2fc3ba5..0411bd418dc 100644 --- a/addons/mail/res_users_view.xml +++ b/addons/mail/res_users_view.xml @@ -27,7 +27,7 @@ -
+
diff --git a/addons/project/project.py b/addons/project/project.py index 3bb5d96f0cc..b56177f4466 100644 --- a/addons/project/project.py +++ b/addons/project/project.py @@ -508,13 +508,6 @@ def Project(): project() -class users(osv.osv): - _inherit = 'res.users' - _columns = { - 'context_project_id': fields.many2one('project.project', 'Project') - } -users() - class task(osv.osv): _name = "project.task" _description = "Task" @@ -528,11 +521,11 @@ class task(osv.osv): context key, or None if it cannot be resolved to a single project. """ if context is None: context = {} - if type(context.get('project_id')) in (int, long): - project_id = context['project_id'] + if type(context.get('default_project_id')) in (int, long): + project_id = context['default_project_id'] return project_id - if isinstance(context.get('project_id'), basestring): - project_name = context['project_id'] + if isinstance(context.get('default_project_id'), basestring): + project_name = context['default_project_id'] project_ids = self.pool.get('project.project').name_search(cr, uid, name=project_name) if len(project_ids) == 1: return project_ids[0][0] @@ -1380,7 +1373,7 @@ class project_task_history_cumulative(osv.osv): id as history_id, date+generate_series(0, CAST((coalesce(end_date,DATE 'tomorrow')::date - date)AS integer)-1) as date, task_id, type_id, user_id, kanban_state, state, - remaining_hours, planned_hours + greatest(remaining_hours,1) as remaining_hours, greatest(planned_hours,1) as planned_hours FROM project_task_history ) as history diff --git a/addons/project/project_view.xml b/addons/project/project_view.xml index 69fcec75064..0e592c7b11a 100644 --- a/addons/project/project_view.xml +++ b/addons/project/project_view.xml @@ -100,7 +100,7 @@ -
+
@@ -406,7 +406,7 @@ -
+
@@ -626,7 +626,7 @@ kanban,tree,form,calendar,gantt,graph - {"search_default_project_id": project_id, 'search_default_inbox': 1} + {} A task represents a work that has to be done. Each user works in his own list of tasks where he can record his task work in hours. He can work and close the task itself or delegate it to another user. If you delegate a task to another user, you get a new task in pending state, which will be reopened when you have to review the work achieved. If you install the project_timesheet module, task work can be invoiced based on the project configuration. With the project_mrp module, sales orders can create tasks automatically when they are confirmed. @@ -749,31 +749,6 @@ - - res.users.project.form1 - res.users - form - - - - - - - - - - - view.users.form.project.modif.inherited1 - res.users - - form - - - - - - - - + diff --git a/addons/project/static/src/css/project.css b/addons/project/static/src/css/project.css index 93437c878ba..7a354d5a801 100644 --- a/addons/project/static/src/css/project.css +++ b/addons/project/static/src/css/project.css @@ -1,42 +1,50 @@ .project_fields { - margin-top: 1px; - margin-bottom: 1px; - font-size: 11px; - padding-left: 0px; - } + margin-top: 1px; + margin-bottom: 1px; + font-size: 11px; + padding-left: 0px; +} .project_fields td { border: none; - padding: 2px 0 2px 8px; } + padding: 2px 0 2px 8px; +} .project_fields th { padding: 0; border-right: 1px solid #dddddd; vertical-align: top; - margin-right: 8px; } + margin-right: 8px; +} .project_vignettes{ - padding: 4px !important } - .project_vignettes li { + padding: 4px !important; +} +.project_vignettes li { float: left; - } - .project_vignettes .project_avatar { +} +.project_vignettes .project_avatar { width: 30px; height: 30px; - padding-left: 0px; } - .project_vignettes .project_fields { - width: 100%; } - .project_vignettes .project_fields th { - width: 120px; - font-weight: normal; } - .project_vignettes .project_fields td { - color: #888888; } - .project_vignettes h4 a { - color: #4c4c4c; } - .project_vignettes > li h4 { + padding-left: 0px; +} +.project_vignettes .project_fields { + width: 100%; +} +.project_vignettes .project_fields th { + width: 120px; + font-weight: normal; +} +.project_vignettes .project_fields td { + color: #888888; +} +.project_vignettes h4 a { + color: #4c4c4c; +} +.project_vignettes > li h4 { margin-bottom: 2px; - padding-left: 2px; } - + padding-left: 2px; +} .oe_project_buttons { padding: 2px 2px !important; - background: none !important; + background: none !important; background-color: transparent !important; border: hidden !important; color: #8A89BA !important; @@ -51,8 +59,8 @@ border-radius: 4px; -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); - -box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); - } + -box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); +} .click_button { background: none !important; background-color: transparent !important; @@ -68,54 +76,60 @@ -webkit-box-align: baseline; } - .click_button:hover { cursor: default !important; } .dropdown-menu { - display: none; - position: absolute; } + display: none; + position: absolute; +} .dropdown { - position: relative; } + position: relative; +} .dropdown-toggle:after { - width: 0; - height: 0; - display: inline-block; - content: "&darr"; - text-indent: -99999px; - vertical-align: top; - margin-top: 8px; - margin-left: 4px; - border-left: 4px solid transparent; - border-right: 4px solid transparent; - border-top: 4px solid white; - filter: alpha(opacity=50); - -khtml-opacity: 0.5; - -moz-opacity: 0.5; - opacity: 0.5; } - .oe_project_kanban_vignette .dropdown-menu .color-chooser { - padding: 0 3px; } - .oe_project_kanban_vignette .dropdown-menu .color-chooser li { - float: left; } - .oe_project_kanban_vignette .dropdown-menu .color-chooser li a { - padding: 2px; } + width: 0; + height: 0; + display: inline-block; + content: "&darr"; + text-indent: -99999px; + vertical-align: top; + margin-top: 8px; + margin-left: 4px; + border-left: 4px solid transparent; + border-right: 4px solid transparent; + border-top: 4px solid white; + filter: alpha(opacity=50); + -khtml-opacity: 0.5; + -moz-opacity: 0.5; + opacity: 0.5; +} +.oe_project_kanban_vignette .dropdown-menu .color-chooser { + padding: 0 3px; +} +.oe_project_kanban_vignette .dropdown-menu .color-chooser li { + float: left; +} +.oe_project_kanban_vignette .dropdown-menu .color-chooser li a { + padding: 2px; +} a.oe_project_kanban_action { - position: absolute; - right: 0; - display: none; - } - a.oe_project_kanban_action:hover { - text-decoration: none; } - a.oe_project_kanban_action .oe_i { - color: #4c4c4c; } - -.square { - display: inline-block; - width: 18px; - height: 18px; - border:1px solid grey; - } + position: absolute; + right: 0; + display: none; +} +a.oe_project_kanban_action:hover { + text-decoration: none; +} +a.oe_project_kanban_action .oe_i { + color: #4c4c4c; +} +.square { + display: inline-block; + width: 18px; + height: 18px; + border:1px solid grey; +} .oe_kanban_color_0 { background: white; } @@ -136,85 +150,97 @@ a.oe_project_kanban_action { } .open { - display: block; - } - .open .dropdown-menu { - display: block; } + display: block; +} +.open .dropdown-menu { + display: block; +} a.oe_project_kanban_action { - position: absolute; - right: 0; - } - a.oe_project_kanban_action:hover { + position: absolute; + right: 0; +} +a.oe_project_kanban_action:hover { text-decoration: none; - } - a.oe_project_kanban_action .eo_i { - color: #4c4c4c; } +} +a.oe_project_kanban_action .eo_i { + color: #4c4c4c; +} .oe_project_kanban_vignette { - position: relative; - min-height: 50px; - /*background: white;*/ - border: 1px solid #d8d8d8; - border-bottom-color: #b9b9b9; - padding: 6px; - margin: 6px 0; - display: inline-block; - -moz-border-radius: 4px; - -webkit-border-radius: 4px; - border-radius: 4px; - + position: relative; + min-height: 50px; + /*background: white;*/ + border: 1px solid #d8d8d8; + border-bottom-color: #b9b9b9; + padding: 6px; + margin: 6px 0; + display: inline-block; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + border-radius: 4px; } - .oe_project_kanban_vignette:last-child { - margin-bottom: 0; } - .oe_project_kanban_vignette:hover { +.oe_project_kanban_vignette:last-child { + margin-bottom: 0; +} +.oe_project_kanban_vignette:hover { -moz-box-shadow: 0 0 3px rgba(0, 0, 0, 0.6); -webkit-box-shadow: 0 0 3px rgba(0, 0, 0, 0.6); - -box-shadow: 0 0 3px rgba(0, 0, 0, 0.6); } - .oe_project_kanban_vignette h4 { - margin: 0 0 2px; } + -box-shadow: 0 0 3px rgba(0, 0, 0, 0.6); +} +.oe_project_kanban_vignette h4 { + margin: 0 0 2px; +} .oe_project_kanban_vignette .dropdown-menu { - top: 30px; - right: -140px; - padding: 4px; - border: 1px solid #afafb6; - width: 160px; - overflow-x: hidden; - z-index: 900; - background: white; - -moz-border-radius: 3px; - -webkit-border-radius: 3px; - border-radius: 3px; - -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); - -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); - -box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); } - .oe_project_kanban_vignette .dropdown-menu p { - margin-left: 12px; } - .oe_project_kanban_vignette .dropdown-menu li { + top: 30px; + right: -140px; + padding: 4px; + border: 1px solid #afafb6; + width: 160px; + overflow-x: hidden; + z-index: 900; + background: white; + -moz-border-radius: 3px; + -webkit-border-radius: 3px; + border-radius: 3px; + -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); + -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); + -box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3); +} +.oe_project_kanban_vignette .dropdown-menu p { + margin-left: 12px; +} +.oe_project_kanban_vignette .dropdown-menu li { float: none; display: block; - background-color: none; } - .oe_project_kanban_vignette .dropdown-menu li a { - display: block; - padding: 3px 6px; - clear: both; - font-weight: normal; - line-height: 14px; - color: #4c4c4c; - text-decoration: none; } - .oe_project_kanban_vignette .dropdown-menu li a:hover { - background: #f0f0fa; - background: -moz-linear-gradient(#f0f0fa, #eeeef6); - background: -webkit-gradient(linear, left top, left bottom, from(#f0f0fa), to(#eeeef6)); - background: -webkit-linear-gradient(#f0f0fa, #eeeef6); - -moz-box-shadow: none; - -webkit-box-shadow: none; - -box-shadow: none; } + background-color: none; +} +.oe_project_kanban_vignette .dropdown-menu li a { + display: block; + padding: 3px 6px; + clear: both; + font-weight: normal; + line-height: 14px; + color: #4c4c4c; + text-decoration: none; +} +.oe_project_kanban_vignette .dropdown-menu li a:hover { + background: #f0f0fa; + background: -moz-linear-gradient(#f0f0fa, #eeeef6); + background: -webkit-gradient(linear, left top, left bottom, from(#f0f0fa), to(#eeeef6)); + background: -webkit-linear-gradient(#f0f0fa, #eeeef6); + -moz-box-shadow: none; + -webkit-box-shadow: none; + -box-shadow: none; +} .oe_project_kanban_vignette .dropdown-menu .color-chooser { - padding: 0 3px; } - .oe_project_kanban_vignette .dropdown-menu .color-chooser li { - float: left; } - .oe_project_kanban_vignette .dropdown-menu .color-chooser li a { - padding: 2px; } + padding: 0 3px; +} +.oe_project_kanban_vignette .dropdown-menu .color-chooser li { + float: left; +} +.oe_project_kanban_vignette .dropdown-menu .color-chooser li a { + padding: 2px; +} diff --git a/addons/project/static/src/js/project.js b/addons/project/static/src/js/project.js index 09a7c9eb256..8d806fb0605 100644 --- a/addons/project/static/src/js/project.js +++ b/addons/project/static/src/js/project.js @@ -3,31 +3,30 @@ openerp.project = function(openerp) { bind_events: function() { var self = this; self._super(); - if(this.view.dataset.model == 'project.project') { - + if (this.view.dataset.model == 'project.project') { /*set avatar title for members. In many2many fields, returns only list of ids. we can implement return value of m2m fields like [(1,"Adminstration"),...]. */ - _.each($(this.$element).find('.project_avatar'),function(avatar){ + _.each($(this.$element).find('.project_avatar'), function(avatar) { var dataset = new openerp.web.DataSetSearch(this, 'res.users', self.session.context, [['id','=',avatar.id]]); - dataset.read_slice(['name']).then(function(result){ - avatar.setAttribute("title",result[0].name) + dataset.read_slice(['name']).then(function(result) { + avatar.setAttribute("title",result[0].name); }); - }); - + }); + // set sequence like Tasks,Issues,Timesheets and Phases - var my_list = $("#list a") + var my_list = $("#list a"); my_list.sort(function (a, b) { - var aValue = parseInt(a.id); - var bValue = parseInt(b.id); + var aValue = parseInt(a.id, 10); + var bValue = parseInt(b.id, 10); return aValue == bValue ? 0 : aValue < bValue ? -1 : 1; - }); + }); $('#list').replaceWith(my_list); - + // when vignette is clicked, it opens the first action in sequence - if (my_list.length != 0) { - var click_button = $(this.$element).find('.click_button') + if (my_list.length !== 0) { + var click_button = $(this.$element).find('.click_button'); click_button.attr('data-name', my_list[0].getAttribute('data-name')); click_button.attr('data-type', "action"); } @@ -36,13 +35,13 @@ openerp.project = function(openerp) { we can do other way to implement new widget. because we need to rpc call for that. */ - this.$element.find('.bgcolor').click(function(){ - var color = parseInt($(this).find('span').attr('class').split(' ')[0].substring(16)) - var color_class = $(this).find('span').attr('class').split(' ')[0] + this.$element.find('.bgcolor').click(function() { + var color = parseInt($(this).find('span').attr('class').split(' ')[0].substring(16), 10); + var color_class = $(this).find('span').attr('class').split(' ')[0]; $(this).closest('#oe_project_kanban_vignette').removeClass().addClass(color_class + ' oe_project_kanban_vignette'); - self.view.dataset.write(parseInt(this.id), {color:color}); + self.view.dataset.write(parseInt(this.id, 10), {color:color}); }); } } }); -} +}; diff --git a/addons/project_issue/project_issue.py b/addons/project_issue/project_issue.py index 5f06b0679e2..169468a2976 100644 --- a/addons/project_issue/project_issue.py +++ b/addons/project_issue/project_issue.py @@ -142,12 +142,6 @@ class project_issue(crm.crm_case, osv.osv): res[issue.id] = {'progress' : progress} return res - def _get_project(self, cr, uid, context=None): - user = self.pool.get('res.users').browse(cr, uid, uid, context=context) - if user.context_project_id: - return user.context_project_id.id - return False - def on_change_project(self, cr, uid, ids, project_id, context=None): return {} @@ -263,7 +257,6 @@ class project_issue(crm.crm_case, osv.osv): 'section_id': crm.crm_case._get_section, 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.helpdesk', context=c), 'priority': crm.AVAILABLE_PRIORITIES[2][0], - 'project_id':_get_project, 'categ_id' : lambda *a: False, } diff --git a/addons/project_issue/project_issue_menu.xml b/addons/project_issue/project_issue_menu.xml index e78c113866e..4c3be9e1327 100644 --- a/addons/project_issue/project_issue_menu.xml +++ b/addons/project_issue/project_issue_menu.xml @@ -12,7 +12,7 @@ kanban,tree,calendar - {"search_default_user_id": uid, "search_default_draft": 1,"search_default_todo": 1,"search_default_project_id":project_id, 'search_default_inbox': 1} + {"search_default_user_id": uid, "search_default_draft": 1,"search_default_todo": 1} Issues such as system bugs, customer complaints, and material breakdowns are collected here. You can define the stages assigned when solving the project issue (analysis, development, done). With the mailgateway module, issues can be integrated through an email address (example: support@mycompany.com) diff --git a/addons/sale/sale_view.xml b/addons/sale/sale_view.xml index eef3713fcb4..0d466dd21fc 100644 --- a/addons/sale/sale_view.xml +++ b/addons/sale/sale_view.xml @@ -265,7 +265,7 @@ -
+
diff --git a/addons/stock/stock_view.xml b/addons/stock/stock_view.xml index 907d8146a7c..35baed85186 100644 --- a/addons/stock/stock_view.xml +++ b/addons/stock/stock_view.xml @@ -942,7 +942,7 @@ -
+
@@ -1058,7 +1058,7 @@ -
+