commit
75308e6eb9
|
@ -1078,24 +1078,13 @@ class account_move(osv.osv):
|
|||
'partner_id': fields.related('line_id', 'partner_id', type="many2one", relation="res.partner", string="Partner"),
|
||||
'amount': fields.function(_amount_compute, method=True, string='Amount', digits_compute=dp.get_precision('Account'), type='float', fnct_search=_search_amount),
|
||||
'date': fields.date('Date', required=True, states={'posted':[('readonly',True)]}),
|
||||
'type': fields.selection([
|
||||
('pay_voucher','Cash Payment'),
|
||||
('bank_pay_voucher','Bank Payment'),
|
||||
('rec_voucher','Cash Receipt'),
|
||||
('bank_rec_voucher','Bank Receipt'),
|
||||
('cont_voucher','Contra'),
|
||||
('journal_sale_vou','Journal Sale'),
|
||||
('journal_pur_voucher','Journal Purchase'),
|
||||
('journal_voucher','Journal Voucher'),
|
||||
],'Entry Type', select=True , size=128, readonly=True, states={'draft':[('readonly',False)]}),
|
||||
'narration':fields.text('Narration', readonly=True, select=True, states={'draft':[('readonly',False)]}),
|
||||
'narration':fields.text('Narration', select=True),
|
||||
'company_id': fields.related('journal_id','company_id',type='many2one',relation='res.company',string='Company',store=True),
|
||||
}
|
||||
_defaults = {
|
||||
'name': lambda *a: '/',
|
||||
'state': lambda *a: 'draft',
|
||||
'period_id': _get_period,
|
||||
'type' : lambda *a : 'journal_voucher',
|
||||
'date': lambda *a:time.strftime('%Y-%m-%d'),
|
||||
'company_id': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id,
|
||||
}
|
||||
|
@ -1174,8 +1163,20 @@ class account_move(osv.osv):
|
|||
# TODO: Check if period is closed !
|
||||
#
|
||||
def create(self, cr, uid, vals, context={}):
|
||||
if 'line_id' in vals:
|
||||
if 'journal_id' in vals:
|
||||
if 'line_id' in vals and context.get('copy'):
|
||||
for l in vals['line_id']:
|
||||
if not l[0]:
|
||||
l[2].update({
|
||||
'reconcile_id':False,
|
||||
'reconcil_partial_id':False,
|
||||
'analytic_lines':False,
|
||||
'invoice':False,
|
||||
'ref':False,
|
||||
'balance':False,
|
||||
'account_tax_id':False,
|
||||
})
|
||||
|
||||
if 'journal_id' in vals and vals.get('journal_id', False):
|
||||
for l in vals['line_id']:
|
||||
if not l[0]:
|
||||
l[2]['journal_id'] = vals['journal_id']
|
||||
|
@ -1201,11 +1202,14 @@ class account_move(osv.osv):
|
|||
result = super(account_move, self).create(cr, uid, vals, context)
|
||||
return result
|
||||
|
||||
def copy(self, cr, uid, id, default=None, context=None):
|
||||
if default is None:
|
||||
default = {}
|
||||
default = default.copy()
|
||||
default.update({'state':'draft', 'name':'/',})
|
||||
def copy(self, cr, uid, id, default={}, context={}):
|
||||
default.update({
|
||||
'state':'draft',
|
||||
'name':'/',
|
||||
})
|
||||
context.update({
|
||||
'copy':True
|
||||
})
|
||||
return super(account_move, self).copy(cr, uid, id, default, context)
|
||||
|
||||
def unlink(self, cr, uid, ids, context={}, check=True):
|
||||
|
|
|
@ -424,7 +424,7 @@
|
|||
<field name="domain">[('type','=','out_invoice')]</field>
|
||||
<field name="context">{'type':'out_invoice'}</field>
|
||||
<field name="search_view_id" ref="view_account_invoice_filter"/>
|
||||
<field name="help">Most of customer invoices are automatically generate in draft mode by OpenERP flows, following a purchase order for instance. Review, confirm or cancel, pay or refund yours customers invoices here. A manual invoice can be created here.</field>
|
||||
<field name="help">Most of customer invoices are automatically generated in draft mode by OpenERP flows, following a purchase order for instance. Review, confirm or cancel, pay or refund your customers' invoices here. A manual invoice can be created here.</field>
|
||||
</record>
|
||||
|
||||
<record id="action_invoice_tree1_view1" model="ir.actions.act_window.view">
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
##############################################################################
|
||||
import time
|
||||
from datetime import datetime
|
||||
|
||||
import netsvc
|
||||
from osv import fields, osv
|
||||
from tools.translate import _
|
||||
|
@ -454,6 +453,7 @@ class account_move_line(osv.osv):
|
|||
context=context)
|
||||
dt = period.date_start
|
||||
return dt
|
||||
|
||||
def _get_currency(self, cr, uid, context={}):
|
||||
if not context.get('journal_id', False):
|
||||
return False
|
||||
|
@ -926,6 +926,7 @@ class account_move_line(osv.osv):
|
|||
def _check_date(self, cr, uid, vals, context=None, check=True):
|
||||
if context is None:
|
||||
context = {}
|
||||
journal_id = False
|
||||
if 'date' in vals.keys():
|
||||
if 'journal_id' in vals and 'journal_id' not in context:
|
||||
journal_id = vals['journal_id']
|
||||
|
@ -1110,10 +1111,10 @@ class account_move_line(osv.osv):
|
|||
|
||||
#if not 'currency_id' in vals:
|
||||
# vals['currency_id'] = account.company_id.currency_id.id
|
||||
|
||||
|
||||
result = super(osv.osv, self).create(cr, uid, vals, context)
|
||||
# CREATE Taxes
|
||||
if vals.get('account_tax_id',False):
|
||||
if vals.get('account_tax_id', False):
|
||||
tax_id = tax_obj.browse(cr, uid, vals['account_tax_id'])
|
||||
total = vals['debit'] - vals['credit']
|
||||
if journal.refund_journal:
|
||||
|
@ -1186,7 +1187,7 @@ class account_move_line(osv.osv):
|
|||
if check and ((not context.get('no_store_function')) or journal.entry_posted):
|
||||
tmp = self.pool.get('account.move').validate(cr, uid, [vals['move_id']], context)
|
||||
if journal.entry_posted and tmp:
|
||||
self.pool.get('account.move').button_validate(cr,uid, [vals['move_id']],context)
|
||||
rs = self.pool.get('account.move').button_validate(cr,uid, [vals['move_id']],context)
|
||||
return result
|
||||
account_move_line()
|
||||
|
||||
|
|
|
@ -670,7 +670,7 @@
|
|||
<field name="period_id"/>
|
||||
<field name="journal_id"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="amount"/>
|
||||
<field name="amount" sum="Total Amount"/>
|
||||
<field name="state"/>
|
||||
</tree>
|
||||
</field>
|
||||
|
@ -906,43 +906,69 @@
|
|||
<field eval="2" name="priority"/>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Account Entry Line">
|
||||
<notebook>
|
||||
<group col="6" colspan="4">
|
||||
<field name="name" select="1"/>
|
||||
<field name="ref"/>
|
||||
<field name="partner_id" select="1" on_change="onchange_partner_id(False,partner_id,account_id,debit,credit,date)"/>
|
||||
|
||||
<field name="journal_id"/>
|
||||
<field name="period_id"/>
|
||||
<field name="company_id" required="1" groups="base.group_multi_company"/>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Information">
|
||||
<separator colspan="4" string="General Information"/>
|
||||
<field name="name" select="1"/>
|
||||
<field name="date" select="1"/>
|
||||
<field name="ref"/>
|
||||
<field name="invoice"/>
|
||||
<field name="account_id" select="1" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="partner_id" select="1" on_change="onchange_partner_id(False,partner_id,account_id,debit,credit,date)"/>
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Amount"/>
|
||||
<field name="account_id" select="1" domain="[('type','<>','view'),('type','<>','consolidation')]"/>
|
||||
<field name="debit"/>
|
||||
<field name="credit"/>
|
||||
<field name="quantity"/>
|
||||
</group>
|
||||
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Accounting Documents"/>
|
||||
<field name="invoice"/>
|
||||
<field name="move_id" required="False"/>
|
||||
<field name="statement_id"/>
|
||||
</group>
|
||||
|
||||
<field name="debit"/>
|
||||
<field name="credit"/>
|
||||
<field name="company_id" required="1" groups="base.group_multi_company"/>
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Dates"/>
|
||||
<field name="date" select="1"/>
|
||||
<field name="date_maturity"/>
|
||||
<field name="date_created"/>
|
||||
</group>
|
||||
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Taxes"/>
|
||||
<field name="tax_code_id"/>
|
||||
<field name="tax_amount"/>
|
||||
<field name="account_tax_id" domain="[('parent_id','=',False)]"/>
|
||||
</group>
|
||||
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Currency"/>
|
||||
<field name="currency_id"/>
|
||||
<field name="amount_currency"/>
|
||||
</group>
|
||||
|
||||
<separator colspan="4" string="Optional Information"/>
|
||||
<field name="currency_id"/>
|
||||
<field name="amount_currency"/>
|
||||
<field name="quantity"/>
|
||||
<field name="move_id" required="False"/>
|
||||
<newline/>
|
||||
<field name="statement_id"/>
|
||||
<field name="blocked"/>
|
||||
<field name="date_maturity"/>
|
||||
<field name="date_created"/>
|
||||
<newline/>
|
||||
<field name="tax_code_id"/>
|
||||
<field name="tax_amount"/>
|
||||
<newline/>
|
||||
<field name="account_tax_id" domain="[('parent_id','=',False)]"/>
|
||||
<field name="analytic_account_id"/>
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Reconciliation"/>
|
||||
<field name="reconcile_id"/>
|
||||
<field name="reconcile_partial_id"/>
|
||||
</group>
|
||||
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="States"/>
|
||||
<field name="state"/>
|
||||
<field name="blocked"/>
|
||||
</group>
|
||||
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Analytic"/>
|
||||
<field name="analytic_account_id"/>
|
||||
</group>
|
||||
|
||||
<separator colspan="4" string="State"/>
|
||||
<field name="journal_id"/>
|
||||
<field name="period_id"/>
|
||||
<field name="reconcile_id"/>
|
||||
<field name="reconcile_partial_id"/>
|
||||
<field name="state"/>
|
||||
</page>
|
||||
<page string="Analytic Lines">
|
||||
<field colspan="4" name="analytic_lines" nolabel="1" context="{'default_general_account_id':account_id, 'default_name': name, 'default_date':date, 'amount': (debit or 0.0)-(credit or 0.0)}"/>
|
||||
|
@ -952,7 +978,6 @@
|
|||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="view_move_line_form2" model="ir.ui.view">
|
||||
<field name="name">account.move.line.form2</field>
|
||||
<field name="model">account.move.line</field>
|
||||
|
@ -1000,6 +1025,19 @@
|
|||
</field>
|
||||
</record>
|
||||
|
||||
<record id="account_move_line_graph" model="ir.ui.view">
|
||||
<field name="name">account.move.line.graph</field>
|
||||
<field name="model">account.move.line</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Account Statistics" type="bar">
|
||||
<field name="account_id"/>
|
||||
<field name="debit" operator="+"/>
|
||||
<field name="credit" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_account_move_line_filter" model="ir.ui.view">
|
||||
<field name="name">Entry Lines</field>
|
||||
<field name="model">account.move.line</field>
|
||||
|
@ -1053,6 +1091,17 @@
|
|||
Account.Entry Edition
|
||||
-->
|
||||
|
||||
<record id="account_move_graph" model="ir.ui.view">
|
||||
<field name="name">account.move.graph</field>
|
||||
<field name="model">account.move</field>
|
||||
<field name="type">graph</field>
|
||||
<field name="arch" type="xml">
|
||||
<graph string="Account Statistics" type="bar">
|
||||
<field name="period_id"/>
|
||||
<field name="amount" operator="+"/>
|
||||
</graph>
|
||||
</field>
|
||||
</record>
|
||||
<record id="view_move_tree" model="ir.ui.view">
|
||||
<field name="name">account.move.tree</field>
|
||||
<field name="model">account.move</field>
|
||||
|
@ -1064,11 +1113,10 @@
|
|||
<field name="ref"/>
|
||||
<field name="journal_id"/>
|
||||
<field name="period_id"/>
|
||||
<field name="type" invisible=" not context.get('set_visible',True)"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="line_id"/>
|
||||
<field name="to_check" groups="base.group_extended"/>
|
||||
<field name="amount"/>
|
||||
<field name="amount" sum="Total Amount"/>
|
||||
<field name="state"/>
|
||||
<button name="button_validate" states="draft" string="Approve" type="object" icon="terp-camera_test"/>
|
||||
</tree>
|
||||
|
@ -1082,15 +1130,18 @@
|
|||
<form string="Journal Entries">
|
||||
<group colspan="4" col="6">
|
||||
<field name="name" select="1" readonly="True"/>
|
||||
<field name="ref" select="1"/>
|
||||
<field name="to_check" groups="base.group_extended"/>
|
||||
<field name="journal_id" select="1"/>
|
||||
<field name="period_id"/>
|
||||
<field name="type"/>
|
||||
<field name="ref" select="1"/>
|
||||
<field name="date" select="1"/>
|
||||
<field name="company_id" required="1" groups="base.group_multi_company"/>
|
||||
<field name="partner_id" invisible="1" select="1"/>
|
||||
<field name="amount" invisible="1" select="1"/>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Journal Entries Lines">
|
||||
<field colspan="4" height="200" name="line_id" nolabel="1" widget="one2many_list" default_get="{'lines':line_id ,'journal':journal_id }">
|
||||
<field colspan="4" name="line_id" nolabel="1" height="250" widget="one2many_list" default_get="{'lines':line_id ,'journal':journal_id }">
|
||||
<form string="Account Entry Line">
|
||||
<separator colspan="4" string="General Information"/>
|
||||
<field name="name" select="1"/>
|
||||
|
@ -1135,20 +1186,13 @@
|
|||
</tree>
|
||||
</field>
|
||||
<separator colspan="4" string="Narration"/>
|
||||
<field name="narration" colspan="4" nolabel="1"/>
|
||||
<field name="state" select="1"/>
|
||||
<group col="2" colspan="2">
|
||||
<field name="narration" colspan="4" nolabel="1" height="50"/>
|
||||
<group col="4" colspan="4">
|
||||
<field name="state" select="1"/>
|
||||
<button name="button_validate" states="draft" string="Approve" type="object" icon="terp-camera_test"/>
|
||||
<button name="button_cancel" states="posted" string="Cancel" type="object" icon="terp-gtk-stop"/>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Other Information">
|
||||
<field name="company_id" required="1" groups="base.group_multi_company"/>
|
||||
<field name="date" select="1" groups="base.group_extended"/>
|
||||
<field name="to_check" groups="base.group_extended"/>
|
||||
<field name="partner_id" invisible="1" select="1"/>
|
||||
<field name="amount" invisible="1" select="1"/>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
|
@ -1165,28 +1209,34 @@
|
|||
<filter icon="terp-camera_test" string="Posted" domain="[('state','=','posted')]" help="Posted Entries"/>
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="terp-camera_test" string="To Review" domain="[('to_check','=',True)]" groups="base.group_extended" help="To Review"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="date" select='1'/>
|
||||
<field name="name" select='1'/>
|
||||
<field name="journal_id" select='1'/>
|
||||
<field name="partner_id" select='1'/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group col='8' colspan='4'>
|
||||
<field name="journal_id" widget="selection" select='1'/>
|
||||
<field name="period_id" select='1'/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By..." colspan="12" col="10">
|
||||
<filter string="Journal" icon="terp-folder-orange" domain="[]" context="{'group_by':'journal_id'}"/>
|
||||
<filter string="Period" icon="terp-go-month" domain="[]" context="{'group_by':'period_id'}"/>
|
||||
<filter string="Type" icon="terp-stock_symbol-selection" domain="[]" context="{'group_by':'type', 'set_visible':True}"/>
|
||||
<filter string="States" icon="terp-stock_effects-object-colorize" domain="[]" context="{'group_by':'state'}"/>
|
||||
|
||||
<filter string="Partner" icon="terp-personal" domain="[]" context="{'group_by':'partner_id'}"/>
|
||||
<filter string="Date" icon="terp-go-month" domain="[]" context="{'group_by':'date'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="action_move_journal_line" model="ir.actions.act_window">
|
||||
<record id="action_move_journal_line" model="ir.actions.act_window">
|
||||
<field name="name">Journal Entries</field>
|
||||
<field name="res_model">account.move</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_mode">tree,form,graph</field>
|
||||
<field name="view_id" ref="view_move_tree"/>
|
||||
<field name="search_view_id" ref="view_account_move_filter"/>
|
||||
</record>
|
||||
|
@ -1215,21 +1265,20 @@
|
|||
res_model="account.move.line"
|
||||
src_model="account.move"/>
|
||||
|
||||
<record id="action_move_to_review" model="ir.actions.act_window">
|
||||
<field name="name">Journal Entries</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">account.move</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="view_move_tree"/>
|
||||
<field name="search_view_id" ref="view_account_move_filter"/>
|
||||
<field name="domain">[('to_check','=',True), ('state','=','draft')]</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
action="action_move_to_review"
|
||||
id="menu_action_move_to_review"
|
||||
parent="periodical_processing_journal_entries_validation"
|
||||
/>
|
||||
<!-- <record id="action_move_to_review" model="ir.actions.act_window">-->
|
||||
<!-- <field name="name">Journal Entries</field>-->
|
||||
<!-- <field name="type">ir.actions.act_window</field>-->
|
||||
<!-- <field name="res_model">account.move</field>-->
|
||||
<!-- <field name="view_type">form</field>-->
|
||||
<!-- <field name="view_id" ref="view_move_tree"/>-->
|
||||
<!-- <field name="search_view_id" ref="view_account_move_filter"/>-->
|
||||
<!-- <field name="domain">[('to_check','=',True), ('state','=','draft')]</field>-->
|
||||
<!-- </record>-->
|
||||
<!-- <menuitem-->
|
||||
<!-- action="action_move_to_review"-->
|
||||
<!-- id="menu_action_move_to_review"-->
|
||||
<!-- parent="periodical_processing_journal_entries_validation"-->
|
||||
<!-- />-->
|
||||
|
||||
<!-- <menuitem id="next_id_29" name="Search Entries" parent="account.menu_finance_entries" sequence="40"/>-->
|
||||
<!-- <menuitem action="action_move_line_form" id="menu_action_move_line_form" parent="next_id_29"/>-->
|
||||
|
@ -1249,7 +1298,7 @@
|
|||
<field name="name">Journal Items</field>
|
||||
<field name="res_model">account.move.line</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_mode">tree,form,graph</field>
|
||||
<field name="view_id" ref="view_move_line_tree"/>
|
||||
<field name="search_view_id" ref="view_account_move_line_filter"/>
|
||||
<field name="domain">[('journal_id.type', 'in', ['sale', 'purchase_refund'])]</field>
|
||||
|
@ -1261,7 +1310,7 @@
|
|||
<field name="name">Journal Items</field>
|
||||
<field name="res_model">account.move.line</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_mode">tree,form,graph</field>
|
||||
<field name="view_id" ref="view_move_line_tree"/>
|
||||
<field name="search_view_id" ref="view_account_move_line_filter"/>
|
||||
<field name="domain">[('journal_id.type', 'in', ['purchase', 'sale_refund'])]</field>
|
||||
|
@ -2281,7 +2330,7 @@
|
|||
<field name="name">Journal Items</field>
|
||||
<field name="res_model">account.move.line</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_mode">tree,form,graph</field>
|
||||
<field name="view_id" ref="view_move_line_tree"/>
|
||||
<field name="search_view_id" ref="view_account_move_line_filter"/>
|
||||
</record>
|
||||
|
|
|
@ -29,15 +29,15 @@ class account_automatic_reconcile(osv.osv_memory):
|
|||
_description = 'Automatic Reconcile'
|
||||
|
||||
_columns = {
|
||||
'account_ids': fields.many2many('account.account', 'reconcile_account_rel', 'reconcile_id', 'account_id', 'Account to reconcile', domain = [('reconcile','=',1)], \
|
||||
'account_ids': fields.many2many('account.account', 'reconcile_account_rel', 'reconcile_id', 'account_id', 'Accounts to Reconcile', domain = [('reconcile','=',1)], \
|
||||
help = 'If no account is specified, the reconciliation will be made using every accounts that can be reconcilied'),
|
||||
'writeoff_acc_id': fields.many2one('account.account', 'Account'),
|
||||
'journal_id': fields.many2one('account.journal', 'Journal'),
|
||||
'period_id': fields.many2one('account.period', 'Period'),
|
||||
'max_amount': fields.float('Maximum write-off amount'),
|
||||
'power': fields.selection([(p, str(p)) for p in range(2, 10)], 'Power', required=True, help='Number of partial amounts that can be combined to find a balance point can be chosen as the power of the automatic reconciliation'),
|
||||
'date1': fields.date('Start of period', required=True),
|
||||
'date2': fields.date('End of period', required=True),
|
||||
'date1': fields.date('Starting Date', required=True),
|
||||
'date2': fields.date('Ending Date', required=True),
|
||||
'reconciled': fields.integer('Reconciled transactions', readonly=True),
|
||||
'unreconciled': fields.integer('Not reconciled transactions', readonly=True),
|
||||
'allow_write_off': fields.boolean('Allow write off')
|
||||
|
@ -54,6 +54,7 @@ class account_automatic_reconcile(osv.osv_memory):
|
|||
'date2': time.strftime('%Y-%m-%d'),
|
||||
'reconciled': _get_reconciled,
|
||||
'unreconciled': _get_unreconciled,
|
||||
'power':2
|
||||
}
|
||||
|
||||
#TODO: cleanup and comment this code... For now, it is awfulllll
|
||||
|
@ -245,4 +246,4 @@ class account_automatic_reconcile(osv.osv_memory):
|
|||
|
||||
account_automatic_reconcile()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
|
|
@ -7,33 +7,33 @@
|
|||
<field name="model">account.automatic.reconcile</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Reconciliation">
|
||||
<group width="660" height="430">
|
||||
<separator string="Options" colspan="4"/>
|
||||
<group>
|
||||
<field name="account_ids" colspan="4" domain="[('reconcile','=',1)]"/>
|
||||
<field name="date1"/>
|
||||
<field name="date2"/>
|
||||
<field name="power"/>
|
||||
<field name="allow_write_off"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group attrs="{'readonly':[('allow_write_off', '!=', True)]}">
|
||||
<separator string="Write-Off Move" colspan="4"/>
|
||||
<field name="max_amount"/>
|
||||
<field name="writeoff_acc_id" attrs="{ 'required':[('allow_write_off', '=', True)]}"/>
|
||||
<field name="journal_id" attrs="{ 'required':[('allow_write_off', '=', True)]}"/>
|
||||
<field name="period_id" attrs="{ 'required':[('allow_write_off', '=', True)]}"/>
|
||||
</group>
|
||||
<separator string ="" colspan="4"/>
|
||||
<group colspan="2" col="4">
|
||||
<button special="cancel" string="Cancel" icon="gtk-cancel"/>
|
||||
<button name="reconcile" string="Reconcile" type="object" icon="terp-stock_effects-object-colorize"/>
|
||||
</group>
|
||||
</group>
|
||||
</form>
|
||||
<form string="Reconciliation">
|
||||
<group width="660" height="430">
|
||||
<separator string="Options" colspan="4"/>
|
||||
<group>
|
||||
<field name="account_ids" colspan="4" domain="[('reconcile','=',1)]"/>
|
||||
<field name="date1"/>
|
||||
<field name="date2"/>
|
||||
<field name="power"/>
|
||||
<field name="allow_write_off"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group attrs="{'readonly':[('allow_write_off', '!=', True)]}">
|
||||
<separator string="Write-Off Move" colspan="4"/>
|
||||
<field name="max_amount"/>
|
||||
<field name="writeoff_acc_id" attrs="{ 'required':[('allow_write_off', '=', True)]}"/>
|
||||
<field name="journal_id" attrs="{ 'required':[('allow_write_off', '=', True)]}"/>
|
||||
<field name="period_id" attrs="{ 'required':[('allow_write_off', '=', True)]}"/>
|
||||
</group>
|
||||
<separator string ="" colspan="4"/>
|
||||
<group colspan="2" col="4">
|
||||
<button special="cancel" string="Cancel" icon="gtk-cancel"/>
|
||||
<button name="reconcile" string="Reconcile" type="object" icon="terp-stock_effects-object-colorize"/>
|
||||
</group>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
<record id="action_account_automatic_reconcile" model="ir.actions.act_window">
|
||||
<field name="name">Account Automatic Reconcile</field>
|
||||
|
@ -47,29 +47,29 @@
|
|||
<field name="help">For an invoice to be considered as paid, the invoice entries must be reconciled with counterparts, usually payments. With the automatic reconciliation functionality, OpenERP make its own search for entries to reconcile in a series of accounts. It tries to find entries for each partner where the amounts correspond.</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
icon="STOCK_EXECUTE"
|
||||
name="Automatic Reconciliation"
|
||||
action="action_account_automatic_reconcile"
|
||||
id="menu_automatic_reconcile"
|
||||
parent="periodical_processing_reconciliation"/>
|
||||
<menuitem
|
||||
icon="STOCK_EXECUTE"
|
||||
name="Automatic Reconciliation"
|
||||
action="action_account_automatic_reconcile"
|
||||
id="menu_automatic_reconcile"
|
||||
parent="periodical_processing_reconciliation"/>
|
||||
|
||||
<record id="account_automatic_reconcile_view1" model="ir.ui.view">
|
||||
<field name="name">Automatic reconcile unreconcile</field>
|
||||
<field name="model">account.automatic.reconcile</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Reconciliation result">
|
||||
<field name="reconciled"/>
|
||||
<newline/>
|
||||
<field name="unreconciled"/>
|
||||
<group colspan="4" col="6">
|
||||
<separator colspan="6"/>
|
||||
<button special="cancel" string="Ok" icon="terp-dialog-close" default_focus="1"/>
|
||||
</group>
|
||||
</form>
|
||||
<form string="Reconciliation result">
|
||||
<field name="reconciled"/>
|
||||
<newline/>
|
||||
<field name="unreconciled"/>
|
||||
<group colspan="4" col="6">
|
||||
<separator colspan="6"/>
|
||||
<button special="cancel" string="Ok" icon="terp-dialog-close" default_focus="1"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
|
@ -8,13 +8,14 @@ msgstr ""
|
|||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-11-25 12:18+0000\n"
|
||||
"PO-Revision-Date: 2010-06-29 22:34+0000\n"
|
||||
"Last-Translator: Borja López Soilán (Pexego) <borjals@pexego.es>\n"
|
||||
"PO-Revision-Date: 2010-07-23 19:03+0000\n"
|
||||
"Last-Translator: Jordi Esteve (www.zikzakmedia.com) "
|
||||
"<jesteve@zikzakmedia.com>\n"
|
||||
"Language-Team: Spanish <es@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-07-01 03:45+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-07-24 03:58+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: hr_evaluation
|
||||
|
@ -84,7 +85,7 @@ msgstr "Datos informales"
|
|||
#. module: hr_evaluation
|
||||
#: constraint:ir.actions.act_window:0
|
||||
msgid "Invalid model name in the action definition."
|
||||
msgstr "Nombre de modelo inválido en la definición de acción."
|
||||
msgstr "Nombre de modelo no válido en la definición de la acción."
|
||||
|
||||
#. module: hr_evaluation
|
||||
#: field:hr_evaluation.evaluation,employee_id:0
|
||||
|
|
|
@ -7,13 +7,14 @@ msgstr ""
|
|||
"Project-Id-Version: OpenERP Server 5.0.0_rc3\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2009-11-17 07:12+0000\n"
|
||||
"Last-Translator: Raimon Esteve (Zikzakmedia) <resteve@zikzakmedia.com>\n"
|
||||
"PO-Revision-Date: 2010-07-24 10:06+0000\n"
|
||||
"Last-Translator: Jordi Esteve (www.zikzakmedia.com) "
|
||||
"<jesteve@zikzakmedia.com>\n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-22 04:09+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-07-25 04:07+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: hr_timesheet
|
||||
|
@ -112,7 +113,7 @@ msgstr "Producte"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "août"
|
||||
msgstr ""
|
||||
msgstr "Agost"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: field:hr.employee,journal_id:0
|
||||
|
@ -157,11 +158,9 @@ msgstr "Temps total"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "juillet"
|
||||
msgstr ""
|
||||
msgstr "Juliol"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: xsl:hr.analytical.timesheet:0
|
||||
#: xsl:hr.analytical.timesheet_users:0
|
||||
#: model:ir.ui.menu,name:hr_timesheet.next_id_48
|
||||
msgid "Timesheet"
|
||||
msgstr "Full d'assistència"
|
||||
|
@ -171,14 +170,14 @@ msgstr "Full d'assistència"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "janvier"
|
||||
msgstr ""
|
||||
msgstr "Gener"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: selection:hr.analytical.timesheet,init,month:0
|
||||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "juin"
|
||||
msgstr ""
|
||||
msgstr "Juny"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: model:ir.actions.wizard,name:hr_timesheet.wizard_hr_timesheet_my
|
||||
|
@ -233,7 +232,7 @@ msgstr "XML invàlid per a la definició de la vista!"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "avril"
|
||||
msgstr ""
|
||||
msgstr "Abril"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: field:hr.analytic.timesheet,line_id:0
|
||||
|
@ -255,7 +254,7 @@ msgstr "Selecciona usuaris"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "novembre"
|
||||
msgstr ""
|
||||
msgstr "Novembre"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: wizard_view:hr_timesheet.si_so,sign_out:0
|
||||
|
@ -283,7 +282,7 @@ msgstr "Estat actual"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "octobre"
|
||||
msgstr ""
|
||||
msgstr "Octubre"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: view:account.analytic.account:0
|
||||
|
@ -295,7 +294,7 @@ msgstr "Estadístiques d'anàlisis"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "décembre"
|
||||
msgstr ""
|
||||
msgstr "Desembre"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: wizard_field:hr_timesheet.si_so,sign_in,info:0
|
||||
|
@ -345,7 +344,7 @@ msgstr "Recursos humans (codificació d'horaris)"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "mars"
|
||||
msgstr ""
|
||||
msgstr "Març"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: xsl:hr.analytical.timesheet:0
|
||||
|
@ -358,7 +357,7 @@ msgstr "Total"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "mai"
|
||||
msgstr ""
|
||||
msgstr "Maig"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: wizard_button:hr_timesheet.si_so,sign_out,si_result:0
|
||||
|
@ -375,7 +374,7 @@ msgstr "Canvia treball"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "février"
|
||||
msgstr ""
|
||||
msgstr "Febrer"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: view:account.analytic.account:0
|
||||
|
@ -469,9 +468,105 @@ msgstr "Horari d'empleats"
|
|||
#: selection:hr.analytical.timesheet.my,init,month:0
|
||||
#: selection:hr.analytical.timesheet_users,init,month:0
|
||||
msgid "septembre"
|
||||
msgstr ""
|
||||
msgstr "Setembre"
|
||||
|
||||
#. module: hr_timesheet
|
||||
#: view:hr.employee:0
|
||||
msgid "Timesheets"
|
||||
msgstr "Horaris"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Wed"
|
||||
#~ msgstr "Dc"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "No employee defined for your user !"
|
||||
#~ msgstr "No s'ha definit un empleat pel vostre usuari!"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Mon"
|
||||
#~ msgstr "Dl"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "UserError"
|
||||
#~ msgstr "Error d'usuari"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "No cost unit defined for this employee !"
|
||||
#~ msgstr "No s'ha definit una unitat de cost per aquest empleat!"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "ValidateError"
|
||||
#~ msgstr "Error de validació"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Sat"
|
||||
#~ msgstr "Ds"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Sun"
|
||||
#~ msgstr "Dg"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "July"
|
||||
#~ msgstr "Juliol"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Tue"
|
||||
#~ msgstr "Dt"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "March"
|
||||
#~ msgstr "Març"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "September"
|
||||
#~ msgstr "Setembre"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "December"
|
||||
#~ msgstr "Desembre"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Fri"
|
||||
#~ msgstr "Dv"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "August"
|
||||
#~ msgstr "Agost"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "June"
|
||||
#~ msgstr "Juny"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "November"
|
||||
#~ msgstr "Novembre"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "October"
|
||||
#~ msgstr "Octubre"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "January"
|
||||
#~ msgstr "Gener"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "May"
|
||||
#~ msgstr "Maig"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "February"
|
||||
#~ msgstr "Febrer"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "Thu"
|
||||
#~ msgstr "Dj"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "April"
|
||||
#~ msgstr "Abril"
|
||||
|
||||
#, python-format
|
||||
#~ msgid "UnknownError"
|
||||
#~ msgstr "Error desconegut"
|
||||
|
|
|
@ -2,8 +2,6 @@
|
|||
<openerp>
|
||||
<data>
|
||||
|
||||
|
||||
|
||||
<act_window domain="[('state','<>','close'),('partner_id','<>',False),('to_invoice', '<>', False)]" id="act_my_account" name="Accounts to invoice" res_model="account.analytic.account" src_model="res.users" view_mode="tree,form" view_type="form"/>
|
||||
|
||||
<record id="action_account_analytic_line_to_invoice" model="ir.actions.act_window">
|
||||
|
@ -16,26 +14,26 @@
|
|||
<record id="board_hr_timesheet_invoice_form" model="ir.ui.view">
|
||||
<field name="name">board.hr.timesheet.invoice</field>
|
||||
<field name="model">board.board</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="account.board_account_form"/>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="account.board_account_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/hpaned/child1/action[@string='Draft Customer Invoices']" position="before">
|
||||
<action colspan="4" height="160" name="%(hr_timesheet_invoice.action_analytic_account_tree)d" string="Analytic accounts to close" width="510"/>
|
||||
<action colspan="4" height="160" name="%(act_my_account)d" string="Accounts to invoice" width="510"/>
|
||||
</xpath>
|
||||
<xpath expr="/form/hpaned/child1/action[@string='Draft Customer Invoices']" position="before">
|
||||
<action colspan="4" height="160" name="%(hr_timesheet_invoice.action_analytic_account_tree)d" string="Analytic accounts to close" width="510"/>
|
||||
<action colspan="4" height="160" name="%(act_my_account)d" string="Accounts to invoice" width="510"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Need to merge in above view -->
|
||||
<record id="board_hr_timesheet_invoice_report_form1" model="ir.ui.view">
|
||||
<!-- Need to merge in above view -->
|
||||
<record id="board_hr_timesheet_invoice_report_form1" model="ir.ui.view">
|
||||
<field name="name">board.hr.timesheet.invoice</field>
|
||||
<field name="model">board.board</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="account.board_account_form"/>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="account.board_account_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/hpaned/child2/action[@string='Aged receivables']" position="before">
|
||||
<action colspan="4" height="220" name="%(action_account_analytic_line_to_invoice)d" string="Costs to invoice"/>
|
||||
</xpath>
|
||||
<xpath expr="/form/hpaned/child2/action[@string='Aged receivables']" position="before">
|
||||
<action colspan="4" height="220" name="%(action_account_analytic_line_to_invoice)d" string="Costs to invoice"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
</data>
|
||||
|
|
|
@ -84,7 +84,6 @@
|
|||
</record>
|
||||
|
||||
<!-- Inherits for account analytic lines -->
|
||||
|
||||
<record id="view_account_analytic_line_tree_inherit" model="ir.ui.view">
|
||||
<field name="name">account.analytic.line.tree.to_invoice</field>
|
||||
<field name="model">account.analytic.line</field>
|
||||
|
@ -118,7 +117,6 @@
|
|||
<field name="domain">[('to_invoice','<>',False)]</field>
|
||||
<field name="context">{"search_default_user_id":uid}</field>
|
||||
<field name="help">OpenERP automatically group the entries to be invoiced so you can keep an eye on them on real time in one glance.</field>
|
||||
<!-- <field name="search_view_id" ref="account.view_account_analytic_account_search"/> -->
|
||||
</record>
|
||||
<menuitem
|
||||
action="action_hr_analytic_timesheet_open_tree"
|
||||
|
|
|
@ -1,30 +1,30 @@
|
|||
# Translation of OpenERP Server.
|
||||
# This file contains the translation of the following modules:
|
||||
# * hr_timesheet_invoice
|
||||
# * hr_timesheet_invoice
|
||||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: OpenERP Server 5.0.0\n"
|
||||
"Report-Msgid-Bugs-To: support@openerp.com\n"
|
||||
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
|
||||
"PO-Revision-Date: 2009-09-08 14:49+0000\n"
|
||||
"Last-Translator: filsys <office@filsystem.ro>\n"
|
||||
"PO-Revision-Date: 2010-07-23 20:20+0000\n"
|
||||
"Last-Translator: Desen <Unknown>\n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-22 04:11+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-07-24 03:58+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: view:hr_timesheet_invoice.factor:0
|
||||
msgid "Type of invoicing"
|
||||
msgstr ""
|
||||
msgstr "Tip de facturare"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: rml:account.analytic.profit:0
|
||||
msgid "Profit"
|
||||
msgstr ""
|
||||
msgstr "Profit"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: wizard_view:hr.timesheet.invoice.create,init:0
|
||||
|
@ -39,17 +39,17 @@ msgstr ""
|
|||
#. module: hr_timesheet_invoice
|
||||
#: rml:account.analytic.profit:0
|
||||
msgid "Income"
|
||||
msgstr ""
|
||||
msgstr "Venituri"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: field:hr_timesheet_invoice.factor,customer_name:0
|
||||
msgid "Visible name"
|
||||
msgstr ""
|
||||
msgstr "Nume vizibil"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: wizard_field:hr.timesheet.invoice.account.analytic.account.cost_ledger.report,init,date1:0
|
||||
msgid "Start of period"
|
||||
msgstr ""
|
||||
msgstr "Începutul perioadei"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: help:hr.timesheet.invoice.create,init,price:0
|
||||
|
@ -57,11 +57,13 @@ msgid ""
|
|||
"The cost of each work done will be displayed on the invoice. You probably "
|
||||
"don't want to check this."
|
||||
msgstr ""
|
||||
"Costul fiecărei activități efectuate va fi tipărit pe factura. Probabil că "
|
||||
"nu doriți să bifați această opțiune."
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: model:ir.actions.wizard,name:hr_timesheet_invoice.hr_timesheet_invoice_create
|
||||
msgid "Invoice analytic lines"
|
||||
msgstr ""
|
||||
msgstr "Detalii factură"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: help:hr.timesheet.final.invoice.create,init,time:0
|
||||
|
@ -72,18 +74,18 @@ msgstr ""
|
|||
#: model:ir.actions.act_window,name:hr_timesheet_invoice.action_draft_analytic_accounts
|
||||
#: model:ir.ui.menu,name:hr_timesheet_invoice.menu_action_draft_analytic_accounts
|
||||
msgid "Draft Analytic Accounts"
|
||||
msgstr ""
|
||||
msgstr "Conturi analitice în schiță"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: wizard_field:hr.timesheet.final.invoice.create,init,time:0
|
||||
#: wizard_field:hr.timesheet.invoice.create,init,time:0
|
||||
msgid "Time spent"
|
||||
msgstr ""
|
||||
msgstr "Timp consumat"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: field:account.analytic.account,amount_invoiced:0
|
||||
msgid "Invoiced Amount"
|
||||
msgstr ""
|
||||
msgstr "Valoarea Facturată"
|
||||
|
||||
#. module: hr_timesheet_invoice
|
||||
#: help:account.analytic.account,to_invoice:0
|
||||
|
|
|
@ -209,7 +209,7 @@ class mrp_bom(osv.osv):
|
|||
'active': lambda *a: 1,
|
||||
'product_efficiency': lambda *a: 1.0,
|
||||
'product_qty': lambda *a: 1.0,
|
||||
'product_rounding': lambda *a: 1.0,
|
||||
'product_rounding': lambda *a: 0.0,
|
||||
'type': lambda *a: 'normal',
|
||||
'company_id': lambda self,cr,uid,c: self.pool.get('res.company')._company_default_get(cr, uid, 'mrp.bom', context=c),
|
||||
}
|
||||
|
@ -270,11 +270,11 @@ class mrp_bom(osv.osv):
|
|||
max_prop = prop
|
||||
return result
|
||||
|
||||
def _bom_explode(self, cr, uid, bom, factor, properties, addthis=False, level=0):
|
||||
def _bom_explode(self, cr, uid, bom, factor, properties=[], addthis=False, level=0):
|
||||
""" Finds Products and Workcenters for related BoM for manufacturing order.
|
||||
@param bom: BoM of particular product.
|
||||
@param factor: Factor of product UoM.
|
||||
@param properties: A dictionary for contextual values.
|
||||
@param properties: A List of properties Ids.
|
||||
@param addthis: If BoM found then True else False.
|
||||
@param level: Depth level to find BoM lines starts from 10.
|
||||
@return: result: List of dictionaries containing product details.
|
||||
|
|
|
@ -155,10 +155,10 @@
|
|||
<group col="4" colspan="4">
|
||||
<field name="capacity_per_cycle"/>
|
||||
<newline/>
|
||||
<field name="time_cycle"/>
|
||||
<field name="time_cycle" widget="float_time"/>
|
||||
<field name="time_efficiency"/>
|
||||
<field name="time_start"/>
|
||||
<field name="time_stop"/>
|
||||
<field name="time_start" widget="float_time"/>
|
||||
<field name="time_stop" widget="float_time"/>
|
||||
</group>
|
||||
</page>
|
||||
<page string="Analytic Accounting" groups="base.group_extended">
|
||||
|
@ -236,7 +236,7 @@
|
|||
<field name="sequence" select="1"/>
|
||||
<field name="workcenter_id" select="1"/>
|
||||
<field name="cycle_nbr"/>
|
||||
<field name="hour_nbr"/>
|
||||
<field name="hour_nbr" widget="float_time"/>
|
||||
<separator colspan="4" string="Description"/>
|
||||
<field colspan="4" name="note" nolabel="1"/>
|
||||
</form>
|
||||
|
@ -301,8 +301,8 @@
|
|||
<field name="name" select="1"/>
|
||||
<field name="code" select="1" string="Reference" groups="base.group_extended"/>
|
||||
<newline/>
|
||||
<field name="product_uom"/>
|
||||
<field name="product_qty"/>
|
||||
<field name="product_uom"/>
|
||||
<field name="routing_id" groups="base.group_extended"/>
|
||||
<newline/>
|
||||
<field name="product_uos" groups="product.group_uos"/>
|
||||
|
@ -316,8 +316,8 @@
|
|||
<field colspan="4" name="bom_lines" nolabel="1" widget="one2many_list">
|
||||
<tree string="Components" editable="bottom">
|
||||
<field name="product_id" on_change="onchange_product_id(product_id, name)" select="1"/>
|
||||
<field name="product_uom"/>
|
||||
<field name="product_qty"/>
|
||||
<field name="product_uom"/>
|
||||
<field name="name" invisible="1"/>
|
||||
<field name="date_start"/>
|
||||
<field name="date_stop"/>
|
||||
|
|
|
@ -55,7 +55,7 @@ class report_custom(report_rml):
|
|||
main_sp_name = "<b>%s</b>\r\n" %(prod.seller_id.name)
|
||||
price = supplier_info_pool.price_get(cr, uid, prod.seller_id.id, prod.id, number*prod_qtty)[prod.seller_id.id]
|
||||
price = product_uom_pool._compute_price(cr, uid, prod.uom_id.id, price, to_uom_id=product_uom.id)
|
||||
main_sp_price = '%s\r\n' %(str(price))
|
||||
main_sp_price = '<b>%s</b>\r\n' %(str(price))
|
||||
sum += prod_qtty*price
|
||||
std_price = product_uom_pool._compute_price(cr, uid, prod.uom_id.id, prod.standard_price, to_uom_id=product_uom.id)
|
||||
main_strd_price = str(std_price) + '\r\n'
|
||||
|
@ -65,34 +65,34 @@ class report_custom(report_rml):
|
|||
sellers += '- <i>'+ seller_id.name.name +'</i>\r\n'
|
||||
price = supplier_info_pool.price_get(cr, uid, seller_id.name.id, prod.id, number*prod_qtty)[seller_id.name.id]
|
||||
price = product_uom_pool._compute_price(cr, uid, prod.uom_id.id, price, to_uom_id=product_uom.id)
|
||||
sellers_price += str(price) + '\r\n'
|
||||
sellers_price += '<i>' + str(price) + '</i>\r\n'
|
||||
|
||||
xml += "<col para='yes'>" + prod_name + '</col>'
|
||||
xml += "<col para='no'>" + main_sp_name + sellers + '</col>'
|
||||
xml += "<col para='yes'>" + main_sp_name + sellers + '</col>'
|
||||
xml += "<col para='yes'>" + str(prod_qtty) + '</col>'
|
||||
xml += "<col para='yes'>" + product_uom.name + '</col>'
|
||||
xml += "<col para='yes'>" + main_strd_price + '</col>'
|
||||
xml += "<col para='no'>" + main_sp_price + sellers_price + '</col>'
|
||||
xml += "<col para='yes'>" + main_sp_price + sellers_price + '</col>'
|
||||
|
||||
|
||||
xml += '</row>'
|
||||
return xml, sum, sum_strd
|
||||
|
||||
def process_workcenter(wrk):
|
||||
xml = '<row>'
|
||||
|
||||
workcenter = workcenter_pool.browse(cr, uid, wrk['workcenter_id'])
|
||||
|
||||
cost_cycle = wrk['cycle']*workcenter.costs_cycle
|
||||
cost_hour = wrk['hour']*workcenter.costs_hour
|
||||
total = cost_cycle + cost_hour
|
||||
xml = '<row>'
|
||||
xml += "<col para='yes'>" + workcenter.name + '</col>'
|
||||
xml += "<col para='yes'>" + '</col>'
|
||||
xml += "<col para='no'>" + '</col>'
|
||||
xml += "<col/>"
|
||||
xml += "<col para='no'>" + str(wrk['cycle']*workcenter.costs_cycle) + '</col>'
|
||||
xml += "<col para='yes'>" + str(wrk['hour']*workcenter.costs_hour) + '</col>'
|
||||
|
||||
|
||||
xml += "<col/>"
|
||||
xml += "<col para='yes'>" + str(cost_cycle) + '</col>'
|
||||
xml += "<col para='yes'>" + str(cost_hour) + '</col>'
|
||||
xml += "<col para='yes'>" + str(cost_hour + cost_cycle) + '</col>'
|
||||
xml += '</row>'
|
||||
return xml, wrk['cycle']*workcenter.costs_cycle+wrk['hour']*workcenter.costs_hour
|
||||
|
||||
return xml, total
|
||||
|
||||
|
||||
xml = ''
|
||||
|
@ -108,30 +108,20 @@ class report_custom(report_rml):
|
|||
<report-footer>Generated by Open ERP</report-footer>
|
||||
</config>
|
||||
"""
|
||||
header = """
|
||||
<header>
|
||||
<field>%s</field>
|
||||
<field>%s</field>
|
||||
<field>%s</field>
|
||||
<field>%s</field>
|
||||
<field>%s</field>
|
||||
<field>%s</field>
|
||||
</header>
|
||||
""" % (_('Product name'), _('Product supplier'), _('Product quantity'), _('Product uom'), _('Product Standard Price'), _('Unit Product Price'))
|
||||
|
||||
workcenter_header = """
|
||||
<lines style='header'>
|
||||
<row>
|
||||
<col>%s</col>
|
||||
<col/>
|
||||
<col/>
|
||||
<col/>
|
||||
<col>%s</col>
|
||||
<col>%s</col>
|
||||
<col>%s</col>
|
||||
</row>
|
||||
</lines>
|
||||
""" % (_('Work Center name'), _('Cycles Cost'), _('Total hourly costs'))
|
||||
""" % (_('Work Center name'), _('Cycles Cost'), _('Hourly Cost'),_('Work Cost'))
|
||||
prod_header = """
|
||||
<lines style='header'>
|
||||
<row>
|
||||
<col para='yes'>%s</col>
|
||||
<col para='yes'>%s</col>
|
||||
|
@ -140,15 +130,37 @@ class report_custom(report_rml):
|
|||
<col para='yes'>%s</col>
|
||||
<col para='yes'>%s</col>
|
||||
</row>
|
||||
</lines>
|
||||
""" % (_('Product name'), _('Product supplier'), _('Product Quantity'), _('Product uom'), _('Product Standard Price'), _('Unit Product Price'))
|
||||
""" % (_('Componet'), _('Componet suppliers'), _('Quantity'), _('Uom'), _('Cost Unit Price per Uom'), _('Supplier Unit Price per Uom'))
|
||||
|
||||
company_currency = user_pool.browse(cr, uid, uid).company_id.currency_id.id
|
||||
first = True
|
||||
for product in product_pool.browse(cr, uid, ids, context=context):
|
||||
bom_ids = bom_pool.search(cr, uid, [('product_id','=',product.id)])
|
||||
for bom in bom_pool.browse(cr, uid, bom_ids, context=context):
|
||||
sub_boms = bom_pool._bom_explode(cr, uid, bom, number, [])
|
||||
bom_id = bom_pool._bom_find(cr, uid, product.id, product.uom_id.id)
|
||||
title = "<title>%s</title>" %(_("Cost Structure"))
|
||||
title += "<title>%s</title>" %product.name
|
||||
xml += "<lines style='header'>" + title + prod_header + "</lines>"
|
||||
if not bom_id:
|
||||
total_strd = number * product.standard_price
|
||||
total = number * product_pool.price_get(cr, uid, [product.id], 'standard_price')[product.id]
|
||||
xml += """<lines style='lines'><row>
|
||||
<col para='yes'>-</col>
|
||||
<col para='yes'>-</col>
|
||||
<col para='yes'>-</col>
|
||||
<col para='yes'>-</col>
|
||||
<col para='yes'>-</col>
|
||||
<col para='yes'>-</col>
|
||||
</row></lines>"""
|
||||
xml += """<lines style='total'> <row>
|
||||
<col>%s %s %s %s : </col>
|
||||
<col/>
|
||||
<col/>
|
||||
<col/>
|
||||
<col>%s</col>
|
||||
<col>%s</col>
|
||||
</row></lines>'"""%(_('Total Cost'), _('of'), str(number), product.uom_id.name, str(total_strd), str(total))
|
||||
else:
|
||||
bom = bom_pool.browse(cr, uid, bom_id, context=context)
|
||||
factor = number * product.uom_id.factor / bom.product_uom.factor
|
||||
sub_boms = bom_pool._bom_explode(cr, uid, bom, factor / bom.product_qty)
|
||||
total = 0
|
||||
total_strd = 0
|
||||
parent_bom = {
|
||||
|
@ -159,14 +171,21 @@ class report_custom(report_rml):
|
|||
}
|
||||
xml_tmp = ''
|
||||
for sub_bom in (sub_boms and sub_boms[0]) or [parent_bom]:
|
||||
txt, sum, sum_strd = process_bom(sub_bom, company_currency, factor=1/bom.product_qty)
|
||||
txt, sum, sum_strd = process_bom(sub_bom, company_currency)
|
||||
xml_tmp += txt
|
||||
total += sum
|
||||
total_strd += sum_strd
|
||||
if not first:
|
||||
xml += prod_header
|
||||
|
||||
xml += "<lines style='lines'>" + xml_tmp + '</lines>'
|
||||
xml += "<lines style='sub_total'><row><col>%s : </col><col>(" % (_('SUBTOTAL')) + str(number) + " %s)</col><col/><col/><col>" % (_('products')) + '%.2f' % total_strd + '</col><col>' + '%.2f' % total + '</col></row></lines>'
|
||||
xml += """<lines style='sub_total'> <row>
|
||||
<col>%s %s %s %s : </col>
|
||||
<col/>
|
||||
<col/>
|
||||
<col/>
|
||||
<col>%s</col>
|
||||
<col>%s</col>
|
||||
</row></lines>'"""%(_('Cost'), _('of'), str(number), product.uom_id.name, str(total_strd), str(total))
|
||||
|
||||
total2 = 0
|
||||
xml_tmp = ''
|
||||
for wrk in (sub_boms and sub_boms[1]):
|
||||
|
@ -176,13 +195,24 @@ class report_custom(report_rml):
|
|||
if xml_tmp:
|
||||
xml += workcenter_header
|
||||
xml += "<lines style='lines'>" + xml_tmp + '</lines>'
|
||||
xml += "<lines style='sub_total'><row><col>%s : </col><col>(" % (_('SUBTOTAL')) + str(number) + " %s)</col><col/><col/><col/><col>" % (_('products')) + '%.2f' % total2 + '</col></row></lines>'
|
||||
xml += "<lines style='total'><row><col>%s : </col><col>(" % (_('TOTAL')) + str(number) + " %s)</col><col/><col/><col>" % (_('products')) + '%.2f' % (total_strd+total2) + "</col><col>" + '%.2f' % (total+total2) + '</col></row></lines>'
|
||||
|
||||
first = False
|
||||
|
||||
xml = '<?xml version="1.0" ?><report>' + config_start + '<report-header>%s\n\r' % (_('Product Cost Structure')) + product.name + '</report-header>'+ config_stop + header + xml + '</report>'
|
||||
xml += """<lines style='sub_total'> <row>
|
||||
<col>%s %s %s %s : </col>
|
||||
<col/>
|
||||
<col/>
|
||||
<col/>
|
||||
<col/>
|
||||
<col>%s</col>
|
||||
</row></lines>'"""%(_('Work Cost'), _('of'), str(number), product.uom_id.name, str(total2))
|
||||
xml += """<lines style='total'> <row>
|
||||
<col>%s %s %s %s : </col>
|
||||
<col/>
|
||||
<col/>
|
||||
<col/>
|
||||
<col>%s</col>
|
||||
<col>%s</col>
|
||||
</row></lines>'"""%(_('Total Cost'), _('of'), str(number), product.uom_id.name, str(total_strd+total2), str(total+total2))
|
||||
|
||||
xml = '<?xml version="1.0" ?><report>' + config_start + config_stop + xml + '</report>'
|
||||
return xml
|
||||
|
||||
report_custom('report.product.price', 'product.product', '', 'addons/mrp/report/price.xsl')
|
||||
|
|
|
@ -43,13 +43,6 @@
|
|||
|
||||
<xsl:template match="report">
|
||||
<xsl:apply-templates select="config"/>
|
||||
<blockTable style="header">
|
||||
<xsl:attribute name="colWidths">
|
||||
<xsl:value-of select="./config/tableSize"/>
|
||||
</xsl:attribute>
|
||||
|
||||
<xsl:apply-templates select="header"/>
|
||||
</blockTable>
|
||||
<xsl:apply-templates select="title"/>
|
||||
<xsl:apply-templates select="lines"/>
|
||||
</xsl:template>
|
||||
|
@ -82,6 +75,7 @@
|
|||
</xsl:template>
|
||||
|
||||
<xsl:template match="lines">
|
||||
<xsl:apply-templates select="title"/>
|
||||
<blockTable>
|
||||
<xsl:attribute name="style"><xsl:value-of select="@style"/></xsl:attribute>
|
||||
<xsl:attribute name="colWidths">
|
||||
|
|
|
@ -33,7 +33,8 @@
|
|||
seller_ids:
|
||||
- delay: 1
|
||||
name: base.res_partner_asus
|
||||
qty: 1.0
|
||||
min_qty: 1.0
|
||||
product_uom: product_uom_litre0
|
||||
supply_method: buy
|
||||
type: product
|
||||
uom_id: product.product_uom_kgm
|
||||
|
@ -51,7 +52,8 @@
|
|||
seller_ids:
|
||||
- delay: 1
|
||||
name: base.res_partner_desertic_hispafuentes
|
||||
qty: 2.0
|
||||
min_qty: 2.0
|
||||
product_uom: product.product_uom_kgm
|
||||
supply_method: buy
|
||||
type: product
|
||||
uom_id: product.product_uom_kgm
|
||||
|
|
|
@ -25,7 +25,7 @@ class mrp_price(osv.osv_memory):
|
|||
_name = 'mrp.product_price'
|
||||
_description = 'Product Price'
|
||||
_columns = {
|
||||
'number': fields.integer('Quantity', required=True, help="Specify quantity of products to produce. Report of Cost structure will be displayed base on this qunatity."),
|
||||
'number': fields.integer('Quantity', required=True, help="Specify quantity of products to produce or buy. Report of Cost structure will be displayed base on this qunatity."),
|
||||
}
|
||||
_defaults = {
|
||||
'number': 1,
|
||||
|
|
|
@ -8,13 +8,14 @@ msgstr ""
|
|||
"Project-Id-Version: openobject-addons\n"
|
||||
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"POT-Creation-Date: 2009-12-08 11:46+0000\n"
|
||||
"PO-Revision-Date: 2010-03-07 17:36+0000\n"
|
||||
"Last-Translator: Edgardo Ramos Roque <Unknown>\n"
|
||||
"PO-Revision-Date: 2010-07-23 19:00+0000\n"
|
||||
"Last-Translator: Jordi Esteve (www.zikzakmedia.com) "
|
||||
"<jesteve@zikzakmedia.com>\n"
|
||||
"Language-Team: Spanish <es@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-22 04:20+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-07-24 03:58+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: multi_company
|
||||
|
@ -46,7 +47,7 @@ msgstr "El IVA no parece ser correcto"
|
|||
#. module: multi_company
|
||||
#: constraint:ir.actions.act_window:0
|
||||
msgid "Invalid model name in the action definition."
|
||||
msgstr "Nombre de modelo inválido en la definición de la acción"
|
||||
msgstr "Nombre de modelo no válido en la definición de la acción."
|
||||
|
||||
#. module: multi_company
|
||||
#: model:res.company,overdue_msg:multi_company.res_company_odoo
|
||||
|
|
|
@ -257,7 +257,7 @@
|
|||
|
||||
<act_window
|
||||
context="{'product_uom': locals().has_key('uom_id') and uom_id}"
|
||||
domain="[('product_id', '=', active_id)]"
|
||||
domain="[('procurement_id', '=', active_id)]"
|
||||
id="act_procurement_2_stock_warehouse_orderpoint"
|
||||
name="Minimum Stock Rules"
|
||||
res_model="stock.warehouse.orderpoint"
|
||||
|
|
|
@ -622,12 +622,32 @@ product_packaging()
|
|||
class product_supplierinfo(osv.osv):
|
||||
_name = "product.supplierinfo"
|
||||
_description = "Information about a product supplier"
|
||||
def _calc_qty(self, cr, uid, ids, fields, arg, context={}):
|
||||
result = {}
|
||||
product_uom_pool = self.pool.get('product.uom')
|
||||
for supplier_info in self.browse(cr, uid, ids, context):
|
||||
for field in fields:
|
||||
result[supplier_info.id] = {field:False}
|
||||
if supplier_info.product_uom.id:
|
||||
qty = product_uom_pool._compute_qty(cr, uid, supplier_info.product_uom.id, supplier_info.min_qty, to_uom_id=supplier_info.product_id.uom_id.id)
|
||||
else:
|
||||
qty = supplier_info.min_qty
|
||||
result[supplier_info.id]['qty'] = qty
|
||||
return result
|
||||
|
||||
def _get_uom_id(self, cr, uid, *args):
|
||||
cr.execute('select id from product_uom order by id limit 1')
|
||||
res = cr.fetchone()
|
||||
return res and res[0] or False
|
||||
|
||||
_columns = {
|
||||
'name' : fields.many2one('res.partner', 'Supplier', required=True, ondelete='cascade', help="Supplier of this product"),
|
||||
'product_name': fields.char('Supplier Product Name', size=128, help="This supplier's product name will be used when printing a request for quotation. Keep empty to use the internal one."),
|
||||
'product_code': fields.char('Supplier Product Code', size=64, help="This supplier's product code will be used when printing a request for quotation. Keep empty to use the internal one."),
|
||||
'sequence' : fields.integer('Sequence', help="Assigns the priority to the list of product supplier."),
|
||||
'qty' : fields.float('Minimal Quantity', required=True, help="The minimal quantity to purchase to this supplier, expressed in the default unit of measure."),
|
||||
'product_uom': fields.many2one('product.uom', string="UOM", help="Supplier Product UoM."),
|
||||
'min_qty': fields.float('Minimal Quantity', required=True, help="The minimal quantity to purchase to this supplier, expressed in the default unit of measure."),
|
||||
'qty': fields.function(_calc_qty, method=True, store=True, type='float', string='Quantity', multi="qty", help="This is a quantity which is converted into Default Uom."),
|
||||
'product_id' : fields.many2one('product.template', 'Product', required=True, ondelete='cascade', select=True),
|
||||
'delay' : fields.integer('Delivery Lead Time', required=True, help="Lead time in days between the confirmation of the purchase order and the reception of the products in your warehouse. Used by the scheduler for automatic computation of the purchase order planning."),
|
||||
'pricelist_ids': fields.one2many('pricelist.partnerinfo', 'suppinfo_id', 'Supplier Pricelist'),
|
||||
|
@ -639,6 +659,15 @@ class product_supplierinfo(osv.osv):
|
|||
'delay': lambda *a: 1,
|
||||
'company_id': lambda self,cr,uid,c: self.pool.get('res.company')._company_default_get(cr, uid, 'product.supplierinfo', context=c)
|
||||
}
|
||||
def _check_uom(self, cr, uid, ids):
|
||||
for supplier_info in self.browse(cr, uid, ids):
|
||||
if supplier_info.product_uom and supplier_info.product_uom.category_id.id <> supplier_info.product_id.uom_id.category_id.id:
|
||||
return False
|
||||
return True
|
||||
|
||||
_constraints = [
|
||||
(_check_uom, 'Error: The default UOM and the Supplier Product UOM must be in the same category.', ['product_uom']),
|
||||
]
|
||||
def price_get(self, cr, uid, supplier_ids, product_id, product_qty=1, context=None):
|
||||
"""
|
||||
Calculate price from supplier pricelist.
|
||||
|
@ -659,13 +688,13 @@ class product_supplierinfo(osv.osv):
|
|||
for supplier in partner_pool.browse(cr, uid, supplier_ids, context=context):
|
||||
# Compute price from standard price of product
|
||||
price = product_pool.price_get(cr, uid, [product_id], 'standard_price')[product_id]
|
||||
|
||||
|
||||
# Compute price from Purchase pricelist of supplier
|
||||
pricelist_id = supplier.property_product_pricelist_purchase.id
|
||||
if pricelist_id:
|
||||
price = pricelist_pool.price_get(cr, uid, [pricelist_id], product_id, product_qty).setdefault(pricelist_id, 0)
|
||||
price = currency_pool.compute(cr, uid, pricelist_pool.browse(cr, uid, pricelist_id).currency_id.id, currency_id, price)
|
||||
|
||||
|
||||
# Compute price from supplier pricelist which are in Supplier Information
|
||||
supplier_info_ids = self.search(cr, uid, [('name','=',supplier.id),('product_id','=',product_id)])
|
||||
if supplier_info_ids:
|
||||
|
|
|
@ -356,114 +356,133 @@
|
|||
<record id="supplierinfo1" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_asus"/>
|
||||
<field name="qty">10</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_mb1"/>
|
||||
<field name="delay">5</field>
|
||||
</record>
|
||||
<record id="supplierinfo2" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_asus"/>
|
||||
<field name="qty">10</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_mb2"/>
|
||||
<field name="delay">5</field>
|
||||
</record>
|
||||
<record id="supplierinfo3" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_mb1"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo4" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_mb2"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo5" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_pc1"/>
|
||||
<field name="delay">2</field>
|
||||
</record>
|
||||
<record id="supplierinfo6" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_pc2"/>
|
||||
<field name="delay">2</field>
|
||||
</record>
|
||||
<record id="supplierinfo7" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_pc3"/>
|
||||
<field name="delay">2</field>
|
||||
</record>
|
||||
<record id="supplierinfo8" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_pc4"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo9" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_cpu1"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo10" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_cpu3"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo11" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_hdd1"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo12" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_hdd2"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo13" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_hdd3"/>
|
||||
<field name="delay">1</field>
|
||||
</record>
|
||||
<record id="supplierinfo14" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_20"/>
|
||||
<field name="delay">10</field>
|
||||
</record>
|
||||
<record id="supplierinfo15" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_21"/>
|
||||
<field name="delay">10</field>
|
||||
</record>
|
||||
<record id="supplierinfo16" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">1</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_22"/>
|
||||
<field name="delay">10</field>
|
||||
</record>
|
||||
<record id="supplierinfo17" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_seagate"/>
|
||||
<field name="qty">10</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_hdd1"/>
|
||||
<field name="delay">10</field>
|
||||
</record>
|
||||
<record id="supplierinfo18" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_seagate"/>
|
||||
<field name="qty">10</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_hdd2"/>
|
||||
<field name="delay">10</field>
|
||||
</record>
|
||||
<record id="supplierinfo19" model="product.supplierinfo">
|
||||
<field name="name" ref="base.res_partner_4"/>
|
||||
<field name="qty">10</field>
|
||||
<field name="min_qty">1</field>
|
||||
<field name="product_id" ref="product_product_hdd3"/>
|
||||
<field name="delay">10</field>
|
||||
</record>
|
||||
|
|
|
@ -455,8 +455,10 @@
|
|||
<field name="sequence"/>
|
||||
<field name="product_name" groups="base.group_extended"/>
|
||||
<field name="product_code" groups="base.group_extended"/>
|
||||
<field name="delay"/>
|
||||
<field name="min_qty"/>
|
||||
<field name="product_uom" widget="selection"/>
|
||||
<field name="qty"/>
|
||||
<field name="delay"/>
|
||||
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
|
||||
<field colspan="4" groups="base.group_extended" name="pricelist_ids" nolabel="1" widget="one2many_list">
|
||||
<tree editable="bottom" string="Pricelist">
|
||||
|
|
Loading…
Reference in New Issue