From 94c98bab2a1441719d6b1da7213f722b274e95cf Mon Sep 17 00:00:00 2001 From: Fabien Pinckaers Date: Sun, 13 May 2012 12:30:58 +0200 Subject: [PATCH] [IMP] Removed bad report bzr revid: fp@openerp.com-20120513103058-n0lusjarb4vxu7nh --- addons/point_of_sale/__openerp__.py | 1 - addons/point_of_sale/point_of_sale_view.xml | 13 +-- addons/point_of_sale/report/__init__.py | 1 - .../report/report_cash_register.py | 68 -------------- .../report/report_cash_register_view.xml | 89 ------------------- 5 files changed, 2 insertions(+), 170 deletions(-) delete mode 100644 addons/point_of_sale/report/report_cash_register.py delete mode 100644 addons/point_of_sale/report/report_cash_register_view.xml diff --git a/addons/point_of_sale/__openerp__.py b/addons/point_of_sale/__openerp__.py index b2d60cda290..3b5cbc007f1 100644 --- a/addons/point_of_sale/__openerp__.py +++ b/addons/point_of_sale/__openerp__.py @@ -62,7 +62,6 @@ Main features : 'point_of_sale_report.xml', 'point_of_sale_view.xml', 'report/pos_order_report_view.xml', - 'report/report_cash_register_view.xml', 'point_of_sale_sequence.xml', 'point_of_sale_workflow.xml', 'account_statement_view.xml', diff --git a/addons/point_of_sale/point_of_sale_view.xml b/addons/point_of_sale/point_of_sale_view.xml index 40a1ed138b1..c0e06a91784 100644 --- a/addons/point_of_sale/point_of_sale_view.xml +++ b/addons/point_of_sale/point_of_sale_view.xml @@ -719,16 +719,6 @@ - - All Sales Orders - ir.actions.act_window - pos.order - form - tree,form - [] - - - Invoices ir.actions.act_window @@ -986,7 +976,7 @@ - Point of Sale Sessions + All Sessions ir.actions.act_window pos.session form @@ -998,6 +988,7 @@ parent="menu_point_rep" action="action_pos_session" id="menu_pos_session" + sequence="0" groups="group_pos_manager"/> diff --git a/addons/point_of_sale/report/__init__.py b/addons/point_of_sale/report/__init__.py index bc85fb31084..3d8f93ae724 100644 --- a/addons/point_of_sale/report/__init__.py +++ b/addons/point_of_sale/report/__init__.py @@ -33,6 +33,5 @@ import pos_sales_user_today import pos_payment_report_user import pos_report import pos_order_report -import report_cash_register # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: diff --git a/addons/point_of_sale/report/report_cash_register.py b/addons/point_of_sale/report/report_cash_register.py deleted file mode 100644 index c86c40bb32f..00000000000 --- a/addons/point_of_sale/report/report_cash_register.py +++ /dev/null @@ -1,68 +0,0 @@ -# -*- coding: utf-8 -*- -############################################################################## -# -# OpenERP, Open Source Management Solution -# Copyright (C) 2004-2010 Tiny SPRL (). -# -# This program is free software: you can redistribute it and/or modify -# it under the terms of the GNU Affero 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 Affero General Public License for more details. -# -# You should have received a copy of the GNU Affero General Public License -# along with this program. If not, see . -# -############################################################################## - -import tools -from osv import fields,osv - -class report_cash_register(osv.osv): - _name = "report.cash.register" - _description = "Point of Sale Cash Register Analysis" - _auto = False - _columns = { - 'date': fields.date('Create Date', readonly=True), - 'year': fields.char('Year', size=4), - 'month':fields.selection([('01','January'), ('02','February'), ('03','March'), ('04','April'), - ('05','May'), ('06','June'), ('07','July'), ('08','August'), ('09','September'), - ('10','October'), ('11','November'), ('12','December')], 'Month',readonly=True), - 'day': fields.char('Day', size=128, readonly=True), - 'user_id':fields.many2one('res.users', 'User', readonly=True), - 'state': fields.selection([('draft', 'Quotation'),('open','Open'),('confirm', 'Confirmed')],'State'), - 'journal_id': fields.many2one('account.journal', 'Journal'), - 'balance_start': fields.float('Opening Balance'), - 'balance_end_real': fields.float('Closing Balance'), - } - _order = 'date desc' - - def init(self, cr): - tools.drop_view_if_exists(cr, 'report_cash_register') - cr.execute(""" - create or replace view report_cash_register as ( - select - min(s.id) as id, - to_date(to_char(s.create_date, 'dd-MM-YYYY'),'dd-MM-YYYY') as date, - s.user_id as user_id, - s.journal_id as journal_id, - s.state as state, - s.balance_start as balance_start, - s.balance_end_real as balance_end_real, - to_char(s.create_date, 'YYYY') as year, - to_char(s.create_date, 'MM') as month, - to_char(s.create_date, 'YYYY-MM-DD') as day - from account_bank_statement as s - group by - s.user_id,s.journal_id, s.balance_start, s.balance_end_real,s.state,to_char(s.create_date, 'dd-MM-YYYY'), - to_char(s.create_date, 'YYYY'), - to_char(s.create_date, 'MM'), - to_char(s.create_date, 'YYYY-MM-DD'))""") - -report_cash_register() - -# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file diff --git a/addons/point_of_sale/report/report_cash_register_view.xml b/addons/point_of_sale/report/report_cash_register_view.xml deleted file mode 100644 index 0fd17c9df4c..00000000000 --- a/addons/point_of_sale/report/report_cash_register_view.xml +++ /dev/null @@ -1,89 +0,0 @@ - - - - - report.cash.register.tree - report.cash.register - tree - - - - - - - - - - - - - - - - - report.cash.register.search - report.cash.register - search - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Register Analysis - report.cash.register - form - tree,form - - {'search_default_year':1,'search_default_This Month':1,'search_default_today':1,'search_default_User':1,'group_by_no_leaf':1,'group_by':[]} - - - - -