[MERGE] Merge with main branch

bzr revid: pso@tinyerp.com-20120719073136-a7a5t43y2nm51zji
This commit is contained in:
pso (OpenERP) 2012-07-19 13:01:36 +05:30
commit 8048661b01
231 changed files with 15875 additions and 5929 deletions

View File

@ -99,6 +99,7 @@ module named account_voucher.
'wizard/account_reconcile_partner_process_view.xml',
'wizard/account_automatic_reconcile_view.xml',
'wizard/account_financial_report_view.xml',
'wizard/pos_box.xml',
'project/wizard/project_account_analytic_line_view.xml',
'account_end_fy.xml',
'account_invoice_view.xml',
@ -145,8 +146,8 @@ module named account_voucher.
'test/account_use_model.yml',
'test/account_validate_account_move.yml',
'test/account_fiscalyear_close.yml',
'test/account_bank_statement.yml',
'test/account_cash_statement.yml',
#'test/account_bank_statement.yml',
#'test/account_cash_statement.yml',
'test/test_edi_invoice.yml',
'test/account_report.yml',
'test/account_fiscalyear_close_state.yml', #last test, as it will definitively close the demo fiscalyear

View File

@ -474,7 +474,7 @@ class account_account(osv.osv):
'shortcut': fields.char('Shortcut', size=12),
'tax_ids': fields.many2many('account.tax', 'account_account_tax_default_rel',
'account_id', 'tax_id', 'Default Taxes'),
'note': fields.text('Note'),
'note': fields.text('Internal Notes'),
'company_currency_id': fields.function(_get_company_currency, type='many2one', relation='res.currency', string='Company Currency'),
'company_id': fields.many2one('res.company', 'Company', required=True),
'active': fields.boolean('Active', select=2, help="If the active field is set to False, it will allow you to hide the account without removing it."),
@ -714,6 +714,7 @@ class account_journal(osv.osv):
_name = "account.journal"
_description = "Journal"
_columns = {
'with_last_closing_balance' : fields.boolean('Opening With Last Closing Balance'),
'name': fields.char('Journal Name', size=64, required=True),
'code': fields.char('Code', size=5, required=True, help="The code will be displayed on reports."),
'type': fields.selection([('sale', 'Sale'),('sale_refund','Sale Refund'), ('purchase', 'Purchase'), ('purchase_refund','Purchase Refund'), ('cash', 'Cash'), ('bank', 'Bank and Cheques'), ('general', 'General'), ('situation', 'Opening/Closing Situation')], 'Type', size=32, required=True,
@ -737,9 +738,14 @@ class account_journal(osv.osv):
'entry_posted': fields.boolean('Skip \'Draft\' State for Manual Entries', help='Check this box if you don\'t want new journal entries to pass through the \'draft\' state and instead goes directly to the \'posted state\' without any manual validation. \nNote that journal entries that are automatically created by the system are always skipping that state.'),
'company_id': fields.many2one('res.company', 'Company', required=True, select=1, help="Company related to this journal"),
'allow_date':fields.boolean('Check Date in Period', help= 'If set to True then do not accept the entry if the entry date is not into the period dates'),
'profit_account_id' : fields.many2one('account.account', 'Profit Account'),
'loss_account_id' : fields.many2one('account.account', 'Loss Account'),
'internal_account_id' : fields.many2one('account.account', 'Internal Transfers Account', select=1),
}
_defaults = {
'with_last_closing_balance' : False,
'user_id': lambda self, cr, uid, context: uid,
'company_id': lambda self, cr, uid, c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id,
}
@ -3345,15 +3351,7 @@ class wizard_multi_charts_accounts(osv.osv_memory):
# Create Bank journals
self._create_bank_journals_from_o2m(cr, uid, obj_wizard, company_id, acc_template_ref, context=context)
action = {
'type': 'ir.actions.act_window',
'view_type': 'form',
'view_mode': 'form',
'res_model': 'board.board',
'view_id': self.pool.get('ir.model.data').get_object_reference(cr, uid, 'account', 'board_account_form')[1],
'menu_id': self.pool.get('ir.model.data').get_object_reference(cr, uid, 'account', 'menu_finance')[1]
}
return action
return {}
def _prepare_bank_journal(self, cr, uid, line, current_num, default_account_id, company_id, context=None):
'''

View File

@ -26,24 +26,18 @@ from tools.translate import _
import decimal_precision as dp
class account_bank_statement(osv.osv):
def create(self, cr, uid, vals, context=None):
seq = 0
if 'line_ids' in vals:
new_line_ids = []
for line in vals['line_ids']:
seq += 1
line[2]['sequence'] = seq
for idx, line in enumerate(vals['line_ids']):
line[2]['sequence'] = idx + 1
return super(account_bank_statement, self).create(cr, uid, vals, context=context)
def write(self, cr, uid, ids, vals, context=None):
res = super(account_bank_statement, self).write(cr, uid, ids, vals, context=context)
account_bank_statement_line_obj = self.pool.get('account.bank.statement.line')
for statement in self.browse(cr, uid, ids, context):
seq = 0
for line in statement.line_ids:
seq += 1
account_bank_statement_line_obj.write(cr, uid, [line.id], {'sequence': seq}, context=context)
for idx, line in enumerate(statement.line_ids):
account_bank_statement_line_obj.write(cr, uid, [line.id], {'sequence': idx + 1}, context=context)
return res
def _default_journal_id(self, cr, uid, context=None):
@ -51,45 +45,19 @@ class account_bank_statement(osv.osv):
context = {}
journal_pool = self.pool.get('account.journal')
journal_type = context.get('journal_type', False)
journal_id = False
company_id = self.pool.get('res.company')._company_default_get(cr, uid, 'account.bank.statement',context=context)
if journal_type:
ids = journal_pool.search(cr, uid, [('type', '=', journal_type),('company_id','=',company_id)])
if ids:
journal_id = ids[0]
return journal_id
return ids[0]
return False
def _end_balance(self, cursor, user, ids, name, attr, context=None):
res_currency_obj = self.pool.get('res.currency')
res_users_obj = self.pool.get('res.users')
res = {}
company_currency_id = res_users_obj.browse(cursor, user, user,
context=context).company_id.currency_id.id
statements = self.browse(cursor, user, ids, context=context)
for statement in statements:
for statement in self.browse(cursor, user, ids, context=context):
res[statement.id] = statement.balance_start
currency_id = statement.currency.id
for line in statement.move_line_ids:
if line.debit > 0:
if line.account_id.id == \
statement.journal_id.default_debit_account_id.id:
res[statement.id] += res_currency_obj.compute(cursor,
user, company_currency_id, currency_id,
line.debit, context=context)
else:
if line.account_id.id == \
statement.journal_id.default_credit_account_id.id:
res[statement.id] -= res_currency_obj.compute(cursor,
user, company_currency_id, currency_id,
line.credit, context=context)
if statement.state in ('draft', 'open'):
for line in statement.line_ids:
res[statement.id] += line.amount
for r in res:
res[r] = round(res[r], 2)
for line in statement.line_ids:
res[statement.id] += line.amount
return res
def _get_period(self, cr, uid, context=None):
@ -129,7 +97,7 @@ class account_bank_statement(osv.osv):
_description = "Bank Statement"
_inherit = ['mail.thread']
_columns = {
'name': fields.char('Name', size=64, required=True, states={'draft': [('readonly', False)]}, readonly=True, help='if you give the Name other then /, its created Accounting Entries Move will be with same name as statement name. This allows the statement entries to have the same references than the statement itself'), # readonly for account_cash_statement
'name': fields.char('Reference', size=64, required=True, states={'draft': [('readonly', False)]}, readonly=True, help='if you give the Name other then /, its created Accounting Entries Move will be with same name as statement name. This allows the statement entries to have the same references than the statement itself'), # readonly for account_cash_statement
'date': fields.date('Date', required=True, states={'confirm': [('readonly', True)]}, select=True),
'journal_id': fields.many2one('account.journal', 'Journal', required=True,
readonly=True, states={'draft':[('readonly',False)]}),
@ -141,7 +109,7 @@ class account_bank_statement(osv.osv):
states={'confirm': [('readonly', True)]}),
'balance_end': fields.function(_end_balance,
store = {
'account.bank.statement': (lambda self, cr, uid, ids, c={}: ids, ['line_ids','move_line_ids'], 10),
'account.bank.statement': (lambda self, cr, uid, ids, c={}: ids, ['line_ids','move_line_ids','balance_start'], 10),
'account.bank.statement.line': (_get_statement, ['amount'], 10),
},
string="Computed Balance", help='Balance as calculated based on Starting Balance and transaction lines'),
@ -311,7 +279,7 @@ class account_bank_statement(osv.osv):
def balance_check(self, cr, uid, st_id, journal_type='bank', context=None):
st = self.browse(cr, uid, st_id, context=context)
if not ((abs((st.balance_end or 0.0) - st.balance_end_real) < 0.0001) or (abs((st.balance_end or 0.0) - st.balance_end_cash) < 0.0001)):
if not ((abs((st.balance_end or 0.0) - st.balance_end_real) < 0.0001) or (abs((st.balance_end or 0.0) - st.balance_end_real) < 0.0001)):
raise osv.except_osv(_('Error !'),
_('The statement balance is incorrect !\nThe expected balance (%.2f) is different than the computed one. (%.2f)') % (st.balance_end_real, st.balance_end))
return True
@ -380,14 +348,18 @@ class account_bank_statement(osv.osv):
account_move_obj.unlink(cr, uid, ids, context)
done.append(st.id)
return self.write(cr, uid, done, {'state':'draft'}, context=context)
def onchange_journal_id(self, cr, uid, statement_id, journal_id, context=None):
def _compute_balance_end_real(self, cr, uid, journal_id, context=None):
cr.execute('SELECT balance_end_real \
FROM account_bank_statement \
WHERE journal_id = %s AND NOT state = %s \
ORDER BY date DESC,id DESC LIMIT 1', (journal_id, 'draft'))
res = cr.fetchone()
balance_start = res and res[0] or 0.0
return res and res[0] or 0.0
def onchange_journal_id(self, cr, uid, statement_id, journal_id, context=None):
balance_start = self._compute_balance_end_real(cr, uid, journal_id, context=context)
journal_data = self.pool.get('account.journal').read(cr, uid, journal_id, ['default_debit_account_id', 'company_id'], context=context)
account_id = journal_data['default_debit_account_id']
company_id = journal_data['company_id']

View File

@ -43,24 +43,27 @@ class account_cashbox_line(osv.osv):
"""
res = {}
for obj in self.browse(cr, uid, ids, context=context):
res[obj.id] = obj.pieces * obj.number
res[obj.id] = {
'subtotal_opening' : obj.pieces * obj.number_opening,
'subtotal_closing' : obj.pieces * obj.number_closing,
}
return res
def on_change_sub(self, cr, uid, ids, pieces, number, *a):
def on_change_sub_opening(self, cr, uid, ids, pieces, number, *a):
""" Compute the subtotal for the opening """
return {'value' : {'subtotal_opening' : (pieces * number) or 0.0 }}
""" Calculates Sub total on change of number
@param pieces: Names of fields.
@param number:
"""
sub = pieces * number
return {'value': {'subtotal': sub or 0.0}}
def on_change_sub_closing(self, cr, uid, ids, pieces, number, *a):
""" Compute the subtotal for the closing """
return {'value' : {'subtotal_closing' : (pieces * number) or 0.0 }}
_columns = {
'pieces': fields.float('Values', digits_compute=dp.get_precision('Account')),
'number': fields.integer('Number'),
'subtotal': fields.function(_sub_total, string='Sub Total', type='float', digits_compute=dp.get_precision('Account')),
'starting_id': fields.many2one('account.bank.statement', ondelete='cascade'),
'ending_id': fields.many2one('account.bank.statement', ondelete='cascade'),
'pieces': fields.float('Unit of Currency', digits_compute=dp.get_precision('Account')),
'number_opening' : fields.integer('Number of Units', help='Opening Unit Numbers'),
'number_closing' : fields.integer('Number of Units', help='Closing Unit Numbers'),
'subtotal_opening': fields.function(_sub_total, string='Opening Subtotal', type='float', digits_compute=dp.get_precision('Account'), multi='subtotal'),
'subtotal_closing': fields.function(_sub_total, string='Closing Subtotal', type='float', digits_compute=dp.get_precision('Account'), multi='subtotal'),
'bank_statement_id' : fields.many2one('account.bank.statement', ondelete='cascade'),
}
account_cashbox_line()
@ -69,39 +72,24 @@ class account_cash_statement(osv.osv):
_inherit = 'account.bank.statement'
def _get_starting_balance(self, cr, uid, ids, context=None):
""" Find starting balance
@param name: Names of fields.
@param arg: User defined arguments
@return: Dictionary of values.
def _update_balances(self, cr, uid, ids, context=None):
"""
Set starting and ending balances according to pieces count
"""
res = {}
for statement in self.browse(cr, uid, ids, context=context):
amount_total = 0.0
if statement.journal_id.type not in('cash'):
if statement.journal_id.type not in ('cash',):
continue
for line in statement.starting_details_ids:
amount_total+= line.pieces * line.number
res[statement.id] = {
'balance_start': amount_total
start = end = 0
for line in statement.details_ids:
start += line.subtotal_opening
end += line.subtotal_closing
data = {
'balance_start': start,
'balance_end_real': end,
}
return res
def _balance_end_cash(self, cr, uid, ids, name, arg, context=None):
""" Find ending balance "
@param name: Names of fields.
@param arg: User defined arguments
@return: Dictionary of values.
"""
res = {}
for statement in self.browse(cr, uid, ids, context=context):
amount_total = 0.0
for line in statement.ending_details_ids:
amount_total += line.pieces * line.number
res[statement.id] = amount_total
res[statement.id] = data
super(account_cash_statement, self).write(cr, uid, [statement.id], data, context=context)
return res
def _get_sum_entry_encoding(self, cr, uid, ids, name, arg, context=None):
@ -111,13 +99,10 @@ class account_cash_statement(osv.osv):
@param arg: User defined arguments
@return: Dictionary of values.
"""
res2 = {}
res = {}
for statement in self.browse(cr, uid, ids, context=context):
encoding_total=0.0
for line in statement.line_ids:
encoding_total += line.amount
res2[statement.id] = encoding_total
return res2
res[statement.id] = sum((line.amount for line in statement.line_ids), 0.0)
return res
def _get_company(self, cr, uid, context=None):
user_pool = self.pool.get('res.users')
@ -128,96 +113,98 @@ class account_cash_statement(osv.osv):
company_id = company_pool.search(cr, uid, [])
return company_id and company_id[0] or False
def _get_cash_open_box_lines(self, cr, uid, context=None):
res = []
curr = [1, 2, 5, 10, 20, 50, 100, 500]
for rs in curr:
dct = {
'pieces': rs,
'number': 0
}
res.append(dct)
journal_ids = self.pool.get('account.journal').search(cr, uid, [('type', '=', 'cash')], context=context)
if journal_ids:
results = self.search(cr, uid, [('journal_id', 'in', journal_ids),('state', '=', 'confirm')], context=context)
if results:
cash_st = self.browse(cr, uid, results, context=context)[0]
for cash_line in cash_st.ending_details_ids:
for r in res:
if cash_line.pieces == r['pieces']:
r['number'] = cash_line.number
return res
def _get_default_cash_close_box_lines(self, cr, uid, context=None):
res = []
curr = [1, 2, 5, 10, 20, 50, 100, 500]
for rs in curr:
dct = {
'pieces': rs,
'number': 0
}
res.append(dct)
return res
def _get_cash_close_box_lines(self, cr, uid, context=None):
res = []
curr = [1, 2, 5, 10, 20, 50, 100, 500]
for rs in curr:
dct = {
'pieces': rs,
'number': 0
}
res.append((0, 0, dct))
return res
def _get_cash_open_close_box_lines(self, cr, uid, context=None):
res = {}
start_l = []
end_l = []
starting_details = self._get_cash_open_box_lines(cr, uid, context=context)
ending_details = self._get_default_cash_close_box_lines(cr, uid, context)
for start in starting_details:
start_l.append((0, 0, start))
for end in ending_details:
end_l.append((0, 0, end))
res['start'] = start_l
res['end'] = end_l
return res
def _get_statement(self, cr, uid, ids, context=None):
def _get_statement_from_line(self, cr, uid, ids, context=None):
result = {}
for line in self.pool.get('account.bank.statement.line').browse(cr, uid, ids, context=context):
result[line.statement_id.id] = True
return result.keys()
def _compute_difference(self, cr, uid, ids, fieldnames, args, context=None):
result = dict.fromkeys(ids, 0.0)
for obj in self.browse(cr, uid, ids, context=context):
result[obj.id] = obj.balance_end_real - obj.balance_end
return result
def _compute_last_closing_balance(self, cr, uid, ids, fieldnames, args, context=None):
result = dict.fromkeys(ids, 0.0)
for obj in self.browse(cr, uid, ids, context=context):
if obj.state == 'draft':
statement_ids = self.search(cr, uid,
[('journal_id', '=', obj.journal_id.id),('state', '=', 'confirm')],
order='create_date desc',
limit=1,
context=context
)
if not statement_ids:
continue
else:
st = self.browse(cr, uid, statement_ids[0], context=context)
result[obj.id] = st.balance_end_real
return result
def onchange_journal_id(self, cr, uid, ids, journal_id, context=None):
result = super(account_cash_statement, self).onchange_journal_id(cr, uid, ids, journal_id)
if not journal_id:
return result
statement_ids = self.search(cr, uid,
[('journal_id', '=', journal_id),('state', '=', 'confirm')],
order='create_date desc',
limit=1,
context=context
)
if not statement_ids:
return result
st = self.browse(cr, uid, statement_ids[0], context=context)
result.setdefault('value', {}).update({'last_closing_balance' : st.balance_end_real})
return result
_columns = {
'total_entry_encoding': fields.function(_get_sum_entry_encoding, string="Cash Transaction", help="Total cash transactions",
'total_entry_encoding': fields.function(_get_sum_entry_encoding, string="Total Cash Transactions",
store = {
'account.bank.statement': (lambda self, cr, uid, ids, c={}: ids, ['line_ids','move_line_ids'], 10),
'account.bank.statement.line': (_get_statement, ['amount'], 10),
'account.bank.statement': (lambda self, cr, uid, ids, context=None: ids, ['line_ids','move_line_ids'], 10),
'account.bank.statement.line': (_get_statement_from_line, ['amount'], 10),
}),
'closing_date': fields.datetime("Closed On"),
'balance_end_cash': fields.function(_balance_end_cash, store=True, string='Closing Balance', help="Closing balance based on cashBox"),
'starting_details_ids': fields.one2many('account.cashbox.line', 'starting_id', string='Opening Cashbox'),
'ending_details_ids': fields.one2many('account.cashbox.line', 'ending_id', string='Closing Cashbox'),
'details_ids' : fields.one2many('account.cashbox.line', 'bank_statement_id', string='CashBox Lines'),
'opening_details_ids' : fields.one2many('account.cashbox.line', 'bank_statement_id', string='Opening Cashbox Lines'),
'closing_details_ids' : fields.one2many('account.cashbox.line', 'bank_statement_id', string='Closing Cashbox Lines'),
'user_id': fields.many2one('res.users', 'Responsible', required=False),
'difference' : fields.function(_compute_difference, method=True, string="Difference", type="float"),
'last_closing_balance' : fields.function(_compute_last_closing_balance, method=True, string='Last Closing Balance', type='float'),
}
_defaults = {
'state': 'draft',
'date': lambda self,cr,uid,context={}: context.get('date', time.strftime("%Y-%m-%d %H:%M:%S")),
'date': lambda self, cr, uid, context={}: context.get('date', time.strftime("%Y-%m-%d %H:%M:%S")),
'user_id': lambda self, cr, uid, context=None: uid,
'starting_details_ids': _get_cash_open_box_lines,
'ending_details_ids': _get_default_cash_close_box_lines
}
}
def create(self, cr, uid, vals, context=None):
if self.pool.get('account.journal').browse(cr, uid, vals['journal_id'], context=context).type == 'cash':
amount_total = 0.0
for line in vals.get('starting_details_ids',[]):
if line and len(line)==3 and line[2]:
amount_total+= line[2]['pieces'] * line[2]['number']
vals.update(balance_start= amount_total)
return super(account_cash_statement, self).create(cr, uid, vals, context=context)
journal = False
if vals.get('journal_id'):
journal = self.pool.get('account.journal').browse(cr, uid, vals['journal_id'], context=context)
if journal and (journal.type == 'cash') and not vals.get('details_ids'):
vals['details_ids'] = []
for value in journal.cashbox_line_ids:
nested_values = {
'number_closing' : 0,
'number_opening' : 0,
'pieces' : value.pieces
}
vals['details_ids'].append([0, False, nested_values])
res_id = super(account_cash_statement, self).create(cr, uid, vals, context=context)
self._update_balances(cr, uid, [res_id], context)
return res_id
def write(self, cr, uid, ids, vals, context=None):
"""
@ -233,34 +220,9 @@ class account_cash_statement(osv.osv):
@return: True on success, False otherwise
"""
super(account_cash_statement, self).write(cr, uid, ids, vals, context=context)
res = self._get_starting_balance(cr, uid, ids)
for rs in res:
super(account_cash_statement, self).write(cr, uid, [rs], res.get(rs))
return True
def onchange_journal_id(self, cr, uid, statement_id, journal_id, context=None):
""" Changes balance start and starting details if journal_id changes"
@param statement_id: Changed statement_id
@param journal_id: Changed journal_id
@return: Dictionary of changed values
"""
res = {}
balance_start = 0.0
if not journal_id:
res.update({
'balance_start': balance_start
})
return res
return super(account_cash_statement, self).onchange_journal_id(cr, uid, statement_id, journal_id, context=context)
def _equal_balance(self, cr, uid, cash_id, context=None):
statement = self.browse(cr, uid, cash_id, context=context)
self.write(cr, uid, [cash_id], {'balance_end_real': statement.balance_end})
statement.balance_end_real = statement.balance_end
if statement.balance_end != statement.balance_end_cash:
return False
return True
res = super(account_cash_statement, self).write(cr, uid, ids, vals, context=context)
self._update_balances(cr, uid, ids, context)
return res
def _user_allow(self, cr, uid, statement_id, context=None):
return True
@ -276,7 +238,7 @@ class account_cash_statement(osv.osv):
for statement in statement_pool.browse(cr, uid, ids, context=context):
vals = {}
if not self._user_allow(cr, uid, statement.id, context=context):
raise osv.except_osv(_('Error !'), (_('User %s does not have rights to access %s journal !') % (statement.user_id.name, statement.journal_id.name)))
raise osv.except_osv(_('Error !'), (_('You do not have rights to open this %s journal !') % (statement.journal_id.name, )))
if statement.name and statement.name == '/':
c = {'fiscalyear_id': statement.period_id.fiscalyear_id.id}
@ -294,13 +256,6 @@ class account_cash_statement(osv.osv):
self.write(cr, uid, [statement.id], vals, context=context)
return True
def balance_check(self, cr, uid, cash_id, journal_type='bank', context=None):
if journal_type == 'bank':
return super(account_cash_statement, self).balance_check(cr, uid, cash_id, journal_type, context)
if not self._equal_balance(cr, uid, cash_id, context):
raise osv.except_osv(_('Error !'), _('The closing balance should be the same than the computed balance!'))
return True
def statement_close(self, cr, uid, ids, journal_type='bank', context=None):
if journal_type == 'bank':
return super(account_cash_statement, self).statement_close(cr, uid, ids, journal_type, context)
@ -317,16 +272,67 @@ class account_cash_statement(osv.osv):
def button_confirm_cash(self, cr, uid, ids, context=None):
super(account_cash_statement, self).button_confirm_bank(cr, uid, ids, context=context)
return self.write(cr, uid, ids, {'closing_date': time.strftime("%Y-%m-%d %H:%M:%S")}, context=context)
absl_proxy = self.pool.get('account.bank.statement.line')
def button_cancel(self, cr, uid, ids, context=None):
cash_box_line_pool = self.pool.get('account.cashbox.line')
super(account_cash_statement, self).button_cancel(cr, uid, ids, context=context)
for st in self.browse(cr, uid, ids, context):
for end in st.ending_details_ids:
cash_box_line_pool.write(cr, uid, [end.id], {'number': 0})
return True
TABLES = (('Profit', 'profit_account_id'), ('Loss', 'loss_account_id'),)
for obj in self.browse(cr, uid, ids, context=context):
if obj.difference == 0.0:
continue
for item_label, item_account in TALBES:
if getattr(obj.journal_id, item_account):
raise osv.except_osv(_('Error !'),
_('There is no %s Account on the Journal %s') % (item_label, obj.journal_id.name,))
is_profit = obj.difference < 0.0
account = getattr(obj.journal_id, TABLES[is_profit][1])
values = {
'statement_id' : obj.id,
'journal_id' : obj.journal_id.id,
'account_id' : account.id,
'amount' : obj.difference,
'name' : 'Exceptional %s' % TABLES[is_profit][0],
}
absl_proxy.create(cr, uid, values, context=context)
return self.write(cr, uid, ids, {'closing_date': time.strftime("%Y-%m-%d %H:%M:%S")}, context=context)
account_cash_statement()
class account_journal(osv.osv):
_inherit = 'account.journal'
def _default_cashbox_line_ids(self, cr, uid, context=None):
# Return a list of coins in Euros.
result = [
dict(pieces=value) for value in [0.01, 0.02, 0.05, 0.1, 0.2, 0.5, 1, 2, 5, 10, 20, 50, 100, 200, 500]
]
return result
_columns = {
'cashbox_line_ids' : fields.one2many('account.journal.cashbox.line', 'journal_id', 'CashBox'),
}
_defaults = {
'cashbox_line_ids' : _default_cashbox_line_ids,
}
account_journal()
class account_journal_cashbox_line(osv.osv):
_name = 'account.journal.cashbox.line'
_rec_name = 'value'
_columns = {
'pieces': fields.float('Values', digits_compute=dp.get_precision('Account')),
'journal_id' : fields.many2one('account.journal', 'Journal', required=True, select=1),
}
_order = 'pieces asc'
account_journal_cashbox_line()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -177,11 +177,11 @@
domain="[('supplier', '=', True)]"/>
<field name="fiscal_position" widget="selection"/>
<field name="origin"/>
<label for="reference_type"/>
<div>
<label for="reference_type"/>
<div>
<field name="reference_type" class="oe_inline oe_edit_only"/>
<field name="reference" class="oe_inline"/>
</div>
</div>
</group>
<group>
<field name="date_invoice"/>
@ -322,11 +322,9 @@
<field name="fiscal_position" widget="selection" />
</group>
<group>
<field name="date_invoice"/>
<field name="journal_id" groups="account.group_account_user"
on_change="onchange_journal_id(journal_id, context)" widget="selection"/>
<field domain="[('company_id', '=', company_id),('type','=', 'receivable')]"
name="account_id" groups="account.group_account_user"/>
@ -342,7 +340,6 @@
</group>
</group>
<field name="sent" invisible="1"/>
<notebook colspan="4">
<page string="Invoice Lines">
<field name="invoice_line" nolabel="1" widget="one2many_list" context="{'type': type}"/>

View File

@ -19,6 +19,7 @@
#
##############################################################################
import sys
import time
from datetime import datetime
from operator import itemgetter
@ -985,37 +986,32 @@ class account_move_line(osv.osv):
if context.get('view_mode', False):
return result
fld = []
fields = {}
flds = []
title = _("Accounting Entries") #self.view_header_get(cr, uid, view_id, view_type, context)
title = _("Accounting Entries") # self.view_header_get(cr, uid, view_id, view_type, context)
ids = journal_pool.search(cr, uid, [])
ids = journal_pool.search(cr, uid, [], context=context)
journals = journal_pool.browse(cr, uid, ids, context=context)
all_journal = [None]
common_fields = {}
total = len(journals)
for journal in journals:
all_journal.append(journal.id)
for field in journal.view_id.columns_id:
# sometimes, it's possible that a defined column is not loaded (the module containing
# sometimes, it's possible that a defined column is not loaded (the module containing
# this field is not loaded) when we make an update.
if field.name not in self._columns:
if field.field not in self._columns:
continue
if not field.field in fields:
fields[field.field] = [journal.id]
if not field.field in flds:
fld.append((field.field, field.sequence))
flds.append(field.field)
common_fields[field.field] = 1
else:
fields.get(field.field).append(journal.id)
common_fields[field.field] = common_fields[field.field] + 1
fld.append(('period_id', 3))
fld.append(('journal_id', 10))
flds.append('period_id')
flds.append('journal_id')
fields['period_id'] = all_journal
fields['journal_id'] = all_journal
default_columns = {
'period_id': 3,
'journal_id': 10,
'state': sys.maxint,
}
for d in default_columns:
if d not in flds:
fld.append((d, default_columns[d]))
flds.append(d)
fld = sorted(fld, key=itemgetter(1))
widths = {
'statement_id': 50,
@ -1029,10 +1025,7 @@ class account_move_line(osv.osv):
colors="red:state=='draft';black:state=='valid'")
fields_get = self.fields_get(cr, uid, flds, context)
for field, _seq in fld:
if common_fields.get(field) == total:
fields.get(field).append(None)
# if field=='state':
# state = 'colors="red:state==\'draft\'"'
# TODO add string to element
f = etree.SubElement(document, 'field', name=field)
if field == 'debit':

View File

@ -17,7 +17,6 @@
<button name="create_period3" states="draft" string="Create 3 Months Periods" type="object" class="oe_highlight"/>
<field name="state" widget="statusbar" nolabel="1" />
</header>
<sheet string="Fiscalyear" >
<group>
<group>
<field name="name"/>
@ -38,10 +37,10 @@
<field name="date_start"/>
<field name="date_stop"/>
<field name="special"/>
<field name="state" invisible="1"/>
</group>
</form>
</field>
</sheet>
</form>
</field>
</record>
@ -99,21 +98,28 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form version="7.0">
<header>
<button name="action_draft" states="done" string="Set to Draft" type="object" groups="account.group_account_manager"/>
<field name="state" widget="statusbar" nolabel="1"/>
</header>
<sheet>
<group col="4">
<field name="name"/>
<field name="code"/>
<field name="date_start"/>
<field name="date_stop"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<field name="fiscalyear_id" widget="selection"/>
<field name="special"/>
</group>
</sheet>
<header>
<button name="action_draft" states="done" string="Set to Draft" type="object" groups="account.group_account_manager"/>
<field name="state" widget="statusbar" nolabel="1"/>
</header>
<sheet>
<group>
<group>
<field name="name"/>
<field name="fiscalyear_id" widget="selection"/>
<label for="date_start" string="Duration"/>
<div>
<field name="date_start" class="oe_inline" nolabel="1"/> -
<field name="date_stop" nolabel="1" class="oe_inline"/>
</div>
</group>
<group>
<field name="code"/>
<field name="special"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
</group>
</sheet>
</form>
</field>
</record>
@ -169,41 +175,37 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Account" version="7.0">
<label for="name" class="oe_edit_only" string="Account Name and Code:"/>
<label for="code" class="oe_edit_only" string="Account Code and Name"/>
<h1>
<field name="name"/> -
<field name="code"/>
<field name="code" class="oe_inline" placeholder="Account code" style="width: 6em"/> -
<field name="name" class="oe_inline" placeholder="Account name"/>
</h1>
<label for="company_id"/>
<h2>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</h2>
<group>
<group>
<field name="parent_id"/>
<field name="type"/>
<field name="user_type"/>
<field name="active"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
<group>
<field name="debit" invisible="context.get('config_invisible', True)" attrs="{'readonly':[('type','=','view')]}"/>
<field name="credit" invisible="context.get('config_invisible', True)" attrs="{'readonly':[('type','=','view')]}"/>
<field name="balance" invisible="context.get('config_invisible', True)"/>
<field name="debit" attrs="{'readonly':[('type','=','view')]}"/>
<field name="credit" attrs="{'readonly':[('type','=','view')]}"/>
<field name="balance"/>
</group>
<group>
<field name="tax_ids" domain="[('parent_id','=',False)]" widget="many2many_tags"/>
<field name="reconcile"/>
<field name="child_consol_ids"
attrs="{'readonly':[('type','!=','consolidation')]}"
attrs="{'invisible':[('type','!=','consolidation')]}"
widget="many2many_tags"/>
</group>
<group string="Currency">
<group>
<field name="currency_id"/>
<field name="currency_mode" attrs="{'readonly': [('currency_id','=',False)]}"/>
</group>
<group string="Reconcile">
<field name="reconcile"/>
</group>
</group>
<label for="note"/>
<field name="note"/>
</form>
</field>
@ -467,38 +469,59 @@
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1><field name="name"/></h1>
<label for="type" class="oe_edit_only"/>
<h2><field name="type" on_change="onchange_type(type, currency, context)"/></h2>
</div>
<notebook>
<page string="Journal Configuration">
<group>
<group>
<group>
<field name="code"/>
<field name="currency"/>
</group>
<group>
<field name="company_id" groups="base.group_multi_company"/>
<field name="user_id"/>
</group>
<group>
<field name="default_debit_account_id" attrs="{'required':[('type','in', ('cash', 'bank'))]}" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="default_credit_account_id" attrs="{'required':[('type','in',('cash', 'bank'))]}" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="view_id" widget="selection"/>
<field name="sequence_id" required="0"/>
</group>
<group>
<field name="centralisation"/>
<field name="entry_posted"/>
<field name="allow_date"/>
<field name="group_invoice_lines"/>
</group>
<group>
<field name="type_control_ids" widget="many2many_tags"/>
<field name="account_control_ids" widget="many2many_tags"/>
</group>
<field name="code"/>
<field name="type" on_change="onchange_type(type, currency, context)"/>
</group>
</page>
<group>
<field name="default_debit_account_id" attrs="{'required':[('type','in', ('cash', 'bank'))]}" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="default_credit_account_id" attrs="{'required':[('type','in',('cash', 'bank'))]}" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="currency"/>
<field name="company_id" groups="base.group_multi_company"/>
</group>
</group>
<notebook>
<page string="Advanced Settings">
<group>
<group>
<field name="user_id"/>
<field name="view_id" widget="selection"/>
<field name="sequence_id" required="0"/>
</group>
<group>
<field name="centralisation"/>
<field name="entry_posted"/>
<field name="allow_date"/>
<field name="group_invoice_lines"/>
</group>
</group>
</page>
<page string="Entry Controls">
<separator colspan="4" string="Accounts Type Allowed (empty for no control)"/>
<field colspan="4" name="type_control_ids" nolabel="1"/>
<separator colspan="4" string="Accounts Allowed (empty for no control)"/>
<field colspan="4" name="account_control_ids" nolabel="1"/>
</page>
<page string="Cash Registers" attrs="{'invisible':[('type', '!=', 'cash')]}">
<group>
<group string="Accounts">
<field name="profit_account_id"/>
<field name="loss_account_id"/>
<field name="internal_account_id"/>
</group>
<group string="Miscellaneous">
<field name="with_last_closing_balance"/>
</group>
</group>
<separator string="Available Coins" colspan="4" />
<field name="cashbox_line_ids" nolabel="1" string="Unit Of Currency Definition" colspan="4">
<tree string="CashBox Lines" editable="bottom">
<field name="pieces" />
</tree>
</field>
</page>
</notebook>
</form>
</field>
@ -598,17 +621,29 @@
<field name="state" widget="statusbar" statusbar_visible="draft,confirm"/>
</header>
<sheet>
<div class="oe_right oe_button_box" name="import_buttons">
<!-- Put here related buttons -->
</div>
<label for="name" class="oe_edit_only" attrs="{'invisible':[('name','=','/')]}"/>
<h1>
<field name="name" attrs="{'invisible':[('name','=','/')]}"/>
</h1>
<group>
<group>
<field name="name"/>
<field name="date" on_change="onchange_date(date, company_id)"/>
<field name="journal_id" domain="[('type', '=', 'bank')]" on_change="onchange_journal_id(journal_id)" widget="selection"/>
<field name="period_id"/>
<label for="date" string="Date / Period"/>
<div>
<field name="date" on_change="onchange_date(date, company_id)" class="oe_inline"/>
<field name="period_id" class="oe_inline"/>
</div>
<field name='company_id' widget="selection" groups="base.group_multi_company" />
</group><group>
<field name="balance_start"/>
<label for="balance_start"/>
<div>
<field name="balance_start" class="oe_inline"/>
<field name="currency" class="oe_inline"/>
</div>
<field name="balance_end_real"/>
<field name="currency" invisible="1"/>
</group>
</group>
@ -894,47 +929,68 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Account Tax" version="7.0">
<group col="4">
<field name="name"/>
<field name="description"/>
<field name="type_tax_use"/>
<field name="price_include"/>
<field name="active"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<group>
<group>
<field name="name"/>
<field name="description"/>
</group>
<group>
<field name="type_tax_use"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<field name="active"/>
</group>
</group>
<notebook>
<page string="Tax Definition">
<group col="4">
<field name="type"/>
<field name="amount" attrs="{'readonly':[('type','in',('none', 'code', 'balance'))]}"/>
<separator colspan="4" string="Accounting Information"/>
<group>
<group string="Tax Computation">
<label for="type"/>
<div>
<field name="type"/>
<field name="amount" class="oe_inline"
attrs="{'invisible':[('type','in',('none', 'code', 'balance'))]}"/>
<label string="%%" attrs="{'invisible':[('type','&lt;&gt;','percent')]}"/>
</div>
<field name="python_compute" attrs="{'invisible':[('type','!=','code')],'required':[('type','=','code')]}"/>
<field name="python_compute_inv" attrs="{'invisible':[('type','!=','code')],'required':[('type','=','code')]}"/>
<field name="price_include"/>
</group>
<group string="Misc">
<field name="sequence"/>
<field name="include_base_amount"/>
<field name="child_depend"/>
</group>
<group string="Invoices">
<field name="account_collected_id" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="account_analytic_collected_id" domain="[('type','&lt;&gt;','view'), ('company_id', '=', company_id), ('parent_id', '&lt;&gt;', False)]" groups="analytic.group_analytic_accounting"/>
<field name="account_paid_id" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="account_analytic_paid_id" domain="[('type','&lt;&gt;','view'), ('company_id', '=', company_id), ('parent_id', '&lt;&gt;', False)]" groups="analytic.group_analytic_accounting"/>
<separator colspan="4" string="Tax Declaration: Invoices"/>
<field name="base_code_id"/>
<field name="base_sign"/>
<field name="tax_code_id"/>
<field name="tax_sign"/>
<separator colspan="4" string="Tax Declaration: Credit Notes"/>
</group>
<group string="Refunds">
<field name="account_paid_id" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="account_analytic_paid_id" domain="[('type','&lt;&gt;','view'), ('company_id', '=', company_id), ('parent_id', '&lt;&gt;', False)]" groups="analytic.group_analytic_accounting"/>
<field name="ref_base_code_id"/>
<field name="ref_base_sign"/>
<field name="ref_tax_code_id"/>
<field name="ref_tax_sign"/>
<separator colspan="4" string="Children Definition"/>
<field name="child_depend"/>
<field name="sequence"/>
<field name="include_base_amount"/>
<field colspan="4" name="child_ids">
</group>
<group string="Children/Sub Taxes" colspan="2">
<field name="child_depend" class="oe_inline"/>
<field name="child_ids" nolabel="1" colspan="2">
<tree string="Account Tax">
<field name="sequence"/>
<field name="name"/>
<field name="price_include"/>
<field name="description"/>
</tree>
</field>
</field>
</group>
</group>
</page>
<page string="Special Computation">
<group col="4">
@ -943,10 +999,6 @@
<field name="domain"/>
<separator colspan="4" string="Applicable Code (if type=code)"/>
<field colspan="4" name="python_applicable" nolabel="1" attrs="{'readonly':[('applicable_type','=','true')], 'required':[('applicable_type','=','code')]}"/>
<separator colspan="2" string="Compute Code"/>
<separator colspan="2" string="Reverse Compute Code"/>
<field colspan="2" name="python_compute" nolabel="1" attrs="{'readonly':[('type','!=','code')],'required':[('type','=','code')]}"/>
<field colspan="2" name="python_compute_inv" nolabel="1" attrs="{'readonly':[('type','!=','code')],'required':[('type','=','code')]}"/>
</group>
</page>
</notebook>
@ -1011,69 +1063,66 @@
<field eval="2" name="priority"/>
<field name="arch" type="xml">
<form string="Journal Item" version="7.0">
<group col="6">
<field name="name"/>
<field name="ref"/>
<field name="partner_id" 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">
<group>
<group string="Amount">
<field name="account_id" domain="[('company_id', '=', company_id), ('type','&lt;&gt;','view'), ('type','&lt;&gt;','consolidation')]"/>
<field name="debit"/>
<field name="credit"/>
<field name="quantity"/>
</group>
<group string="Accounting Documents">
<field name="invoice" readonly="True"/>
<field name="move_id" required="False"/>
<field name="statement_id" readonly="True"/>
</group>
<group string="Dates">
<field name="date"/>
<field name="date_maturity"/>
<field name="date_created" readonly="True"/>
</group>
<group string="Taxes">
<field name="tax_code_id"/>
<field name="tax_amount"/>
<field name="account_tax_id" domain="[('parent_id','=',False)]"/>
</group>
<group attrs="{'readonly':[('state','=','valid')]}" string="Currency">
<field name="currency_id"/>
<field name="amount_currency"/>
</group>
<group string="Reconciliation">
<field name="reconcile_id"/>
<field name="reconcile_partial_id"/>
</group>
<group string="States">
<field name="state"/>
<field name="blocked"/>
</group>
<group groups="analytic.group_analytic_accounting" string="Analytic">
<field name="analytic_account_id" domain="[('parent_id','!=',False)]"/>
</group>
</group>
<separator string="Internal Note" colspan="4"/>
<field name="narration" colspan="4" nolabel="1"/>
</page>
<page string="Analytic Lines" groups="analytic.group_analytic_accounting">
<field name="analytic_lines" context="{'default_general_account_id':account_id, 'default_name': name, 'default_date':date, 'amount': (debit or 0.0)-(credit or 0.0)}"/>
</page>
</notebook>
<sheet>
<group>
<group>
<field name="name"/>
<field name="ref"/>
<field name="partner_id" on_change="onchange_partner_id(False,partner_id,account_id,debit,credit,date)"/>
</group>
<group>
<field name="journal_id"/>
<field name="period_id"/>
<field name="company_id" required="1" groups="base.group_multi_company"/>
</group>
</group>
<notebook colspan="4">
<page string="Information">
<group>
<group string="Amount">
<field name="account_id" domain="[('company_id', '=', company_id), ('type','&lt;&gt;','view'), ('type','&lt;&gt;','consolidation')]"/>
<field name="debit"/>
<field name="credit"/>
<field name="quantity"/>
</group>
<group string="Accounting Documents">
<field name="invoice" readonly="True"/>
<field name="move_id" required="False"/>
<field name="statement_id" readonly="True"/>
</group>
<group string="Dates">
<field name="date"/>
<field name="date_maturity"/>
<field name="date_created" readonly="True"/>
</group>
<group string="Taxes">
<field name="tax_code_id"/>
<field name="tax_amount"/>
<field name="account_tax_id" domain="[('parent_id','=',False)]"/>
</group>
<group attrs="{'readonly':[('state','=','valid')]}" string="Currency">
<field name="currency_id"/>
<field name="amount_currency"/>
</group>
<group string="Reconciliation">
<field name="reconcile_id"/>
<field name="reconcile_partial_id"/>
</group>
<group string="States">
<field name="state"/>
<field name="blocked"/>
</group>
<group groups="analytic.group_analytic_accounting" string="Analytic">
<field name="analytic_account_id" domain="[('parent_id','!=',False)]"/>
</group>
</group>
<field name="narration" colspan="4" nolabel="1" placeholder="Add an internal note..."/>
</page>
<page string="Analytic Lines" groups="analytic.group_analytic_accounting">
<field name="analytic_lines" context="{'default_general_account_id':account_id, 'default_name': name, 'default_date':date, 'amount': (debit or 0.0)-(credit or 0.0)}"/>
</page>
</notebook>
</sheet>
</form>
</field>
</record>
@ -1273,16 +1322,23 @@
<field name="state" widget="statusbar"/>
</header>
<sheet string="Journal Entries" >
<group col="4">
<field name="name" readonly="True"/>
<field name="ref"/>
<field name="journal_id"/>
<field name="period_id"/>
<field name="to_check"/>
<field name="date"/>
<field name="company_id" required="1" groups="base.group_multi_company"/>
<field name="partner_id" invisible="1"/>
<field name="amount" invisible="1"/>
<label for="name" class="oe_edit_only" attrs="{'invisible':[('name','=','/')]}"/>
<h1>
<field name="name" readonly="True" attrs="{'invisible':[('name','=','/')]}"/>
</h1>
<group>
<group>
<field name="journal_id"/>
<field name="period_id"/>
<field name="company_id" required="1" groups="base.group_multi_company"/>
<field name="partner_id" invisible="1"/>
</group>
<group>
<field name="ref"/>
<field name="date"/>
<field name="to_check"/>
<field name="amount" invisible="1"/>
</group>
</group>
<notebook>
<page string="Journal Items">
@ -1374,8 +1430,7 @@
<field name="reconcile_partial_id"/>
</tree>
</field>
<separator string="Internal Note"/>
<field name="narration" colspan="4" nolabel="1" height="50"/>
<field name="narration" colspan="4" placeholder="Add an internal note..." nolabel="1" height="50"/>
</page>
</notebook>
</sheet>
@ -1835,16 +1890,11 @@
<field name="model_id"/>
<field name="ref"/>
</group>
<newline/>
<group string="Starts on">
<group>
<field name="date_start"/>
<field name="period_total"/>
</group>
<group string="Valid Up to">
<field name="period_nbr"/>
<field name="period_type"/>
<field name="period_nbr"/>
<field name="period_total"/>
</group>
</group>
<separator string="Subscription Lines"/>
@ -2528,7 +2578,7 @@ action = pool.get('res.config').next(cr, uid, [], context)
<field name="journal_id"/>
<field name="balance_start"/>
<field name="balance_end_real"/>
<field name="balance_end"/>
<field name="balance_end" invisible="1" />
<field name="state"/>
</tree>
</field>
@ -2547,15 +2597,22 @@ action = pool.get('res.config').next(cr, uid, [], context)
<field name="state" widget="statusbar" nolabel="1" statusbar_visible="draft,confirm"/>
</header>
<sheet string="Statement">
<group col="4">
<field name="name"/>
<field name='company_id' widget="selection" groups="base.group_multi_company" />
<field name="journal_id" on_change="onchange_journal_id(journal_id)" widget="selection"/>
<field name="user_id" readonly="1"/>
<field name="period_id"/>
<field name="currency" invisible="1"/>
<label for="name" class="oe_edit_only" attrs="{'invisible':[('name','=','/')]}"/>
<h1><field name="name" class="oe_inline" attrs="{'invisible':[('name','=','/')]}"/></h1>
<group>
<group>
<field name="journal_id" on_change="onchange_journal_id(journal_id)" widget="selection"/>
<field name="user_id" readonly="1" string="Responsible"/>
<field name="total_entry_encoding"/>
<field name='company_id' widget="selection" groups="base.group_multi_company" />
</group>
<group>
<field name="date" attrs="{'readonly':[('state','!=','draft')]}" on_change="onchange_date(date, company_id)"/>
<field name="closing_date" readonly="1"/>
<field name="period_id" class="oe_inline"/>
<field name="currency" invisible="1"/>
</group>
</group>
<notebook>
<page string="Cash Transactions" attrs="{'invisible': [('state','=','draft')]}">
<field name="line_ids" context="{'date':date}">
@ -2587,31 +2644,24 @@ action = pool.get('res.config').next(cr, uid, [], context)
</form>
</field>
</page>
<page string="CashBox">
<group>
<field name="starting_details_ids" attrs="{'readonly':[('state','!=','draft')]}" nolabel="1">
<tree string = "Opening Balance" editable="bottom">
<page string="Cash Control">
<group col="2" expand="1">
<field name="opening_details_ids" nolabel="1" colspan="4" attrs="{'invisible' : [('state', '!=', 'draft')]}">
<tree string="Opening Cashbox Lines" editable="bottom">
<field name="pieces"/>
<field name="number" on_change="on_change_sub(pieces,number, parent.balance_end)"/>
<field name="subtotal" sum="Total"/>
<field name="number_opening" string="Opening Unit Numbers" on_change="on_change_sub_opening(pieces, number_opening, parent.balance_end)"/>
<field name="subtotal_opening" string="Opening Subtotal"/>
</tree>
<form string = "Opening Balance" version="7.0">
<field name="pieces"/>
<field name="number" on_change="on_change_sub(pieces,number, parent.balance_end)"/>
<field name="subtotal"/>
</form>
</field>
<field name="ending_details_ids" attrs="{'readonly':[('state','!=','open')]}" nolabel="1">
<tree string = "Closing Balance" editable="bottom">
<field name="pieces"/>
<field name="number" on_change="on_change_sub(pieces,number, parent.balance_end)"/>
<field name="subtotal" sum="Total"/>
<field name="closing_details_ids" nolabel="1" colspan="4" attrs="{'invisible' : [('state', '=', 'draft')]}">
<tree string="Closing Cashbox Lines" editable="bottom">
<field name="pieces" readonly="1" />
<field name="number_opening" string="Opening Unit Numbers" readonly="1" />
<field name="subtotal_opening" string="Opening Subtotal" readonly="1" />
<field name="number_closing" string="Closing Unit Numbers" on_change="on_change_sub_closing(pieces, number_closing, parent.balance_end)"/>
<field name="subtotal_closing" string="Closing Subtotal"/>
</tree>
<form string = "Closing Balance" version="7.0">
<field name="pieces"/>
<field name="number" on_change="on_change_sub(pieces,number, parent.balance_end)"/>
<field name="subtotal"/>
</form>
</field>
</group>
</page>
@ -2619,18 +2669,15 @@ action = pool.get('res.config').next(cr, uid, [], context)
<field name="move_line_ids" string="Journal Entries"/>
</page>
</notebook>
<group col="3">
<group string="Dates">
<field name="date" attrs="{'readonly':[('state','!=','draft')]}" on_change="onchange_date(date, company_id)"/>
<field name="closing_date" readonly="1"/>
</group>
<group string="Opening Balance">
<field name="balance_start" readonly="1" string="Opening Balance"/>
<field name="total_entry_encoding"/>
<group col="6" colspan="4">
<group col="2" colspan="2">
<separator string="Opening Balance" colspan="4"/>
<field name="balance_start" readonly="1" string="Opening Cash Control"/>
<field name="last_closing_balance" readonly="1" string="Last Closing Balance" />
<field name="total_entry_encoding" />
</group>
<group string="Closing Balance">
<field name="balance_end"/>
<field name="balance_end_cash"/>
</group>
</group>
</sheet>

View File

@ -22,11 +22,11 @@
<field name="model">res.company</field>
<field name="type">form</field>
<field name="arch" type="xml">
<field name="currency_id" position="after">
<field name="property_reserve_and_surplus_account" colspan="2"/>
<field name="tax_calculation_rounding_method"/>
<field name="paypal_account" placeholder="sales@openerp.com"/>
</field>
<xpath expr="//group[@name='account_grp']" position="inside">
<field name="property_reserve_and_surplus_account"/>
<field name="tax_calculation_rounding_method"/>
<field name="paypal_account" placeholder="sales@openerp.com"/>
</xpath>
</field>
</record>

View File

@ -385,7 +385,7 @@
<field name="inherit_id" ref="account.view_account_journal_form"/>
<field name="type">form</field>
<field name="arch" type="xml">
<field name="currency" position="after">
<field name="type" position="after">
<field name="analytic_journal_id"/>
</field>
</field>

View File

@ -21,7 +21,6 @@
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<field name="has_default_company" invisible="1" />
<field name="has_chart_of_accounts" invisible="1"/>
<field name="complete_tax_set" invisible="1"/>
@ -34,7 +33,6 @@
<field name="expects_chart_of_accounts"/>
</group>
<div class="oe_form_button_save_dirty">
<group string="Select a Chart of Accounts to Install"
attrs="{'invisible': ['|', ('expects_chart_of_accounts','=',False), ('has_chart_of_accounts','=',True)]}">
<group>
@ -51,9 +49,7 @@
<button string="Install More Chart Templates" icon="gtk-go-forward"
name="%(open_account_charts_modules)d" type="action"/>
</group>
</div>
<div class="oe_form_button_save_dirty">
<group string="No Fiscal Year Defined for This Company"
attrs="{'invisible': ['|', ('expects_chart_of_accounts','=',False), ('has_fiscal_year','=',True)]}">
<label for="date_start" string="Date Range"/>
@ -63,78 +59,67 @@
</div>
<field name="period"/>
</group>
</div>
<group string="Accounting Configuration">
<group>
<group>
<group name="account_config">
<separator string="Accounting Configuration" colspan="2"/>
<field name="default_sale_tax" domain="[('type_tax_use','=','sale'), ('company_id','=',company_id)]"
attrs="{'invisible': [('has_chart_of_accounts','=',False)]}"/>
<field name="module_account_accountant"/>
<field name="currency_id"/>
<field name="decimal_precision"/>
</group>
<group>
<field name="default_purchase_tax" domain="[('type_tax_use','=','purchase'), ('company_id','=',company_id)]"
attrs="{'invisible': [('has_chart_of_accounts','=',False)]}"/>
<field name="tax_calculation_rounding_method"/>
<field name="module_account_asset"/>
<field name="module_account_budget"/>
</group>
</group>
<field name="sale_journal_id" invisible="1"/>
<field name="sale_refund_journal_id" invisible="1"/>
<field name="purchase_journal_id" invisible="1"/>
<field name="purchase_refund_journal_id" invisible="1"/>
<group>
<group string="Customer Invoices">
<separator string="Customer Invoices" colspan="2"/>
<label for="sale_sequence_next"/>
<group>
<field name="sale_sequence_prefix" class="oe_inline" nolabel="1"
help='If you put "%%(year)s" in the prefix, it will be replaced by the current year.'/>
<field name="sale_sequence_next" class="oe_inline" nolabel="1" attrs="{'readonly': [('sale_journal_id','=',False)]}"/>
<field name="sale_sequence_next" class="oe_inline" nolabel="1" attrs="{'readonly': [('sale_journal_id','=',False)]}"/>
</group>
<label for="sale_refund_sequence_next"/>
<group>
<field name="sale_refund_sequence_prefix" class="oe_inline" nolabel="1"
<field name="sale_refund_sequence_prefix" class="oe_inline" nolabel="1"
help='If you put "%%(year)s" in the prefix, it will be replaced by the current year.'/>
<field name="sale_refund_sequence_next" class="oe_inline" nolabel="1" attrs="{'readonly': [('sale_refund_journal_id','=',False)]}"/>
<field name="sale_refund_sequence_next" nolabel="1" class="oe_inline" attrs="{'readonly': [('sale_refund_journal_id','=',False)]}"/>
</group>
<field name="module_account_voucher"/>
<field name="module_account_followup"/>
<field name="group_proforma_invoices"/>
<separator name="analytic_accounting" invisible="1" string="Analytic Accounting"/>
</group>
<group string="Supplier Invoices">
<group name="other_cofing">
<separator string="Supplier Invoices" colspan="2"/>
<label for="purchase_sequence_next"/>
<group>
<field name="purchase_sequence_prefix" class="oe_inline" nolabel="1"
help='If you put "%%(year)s" in the prefix, it will be replaced by the current year.'/>
<field name="purchase_sequence_next" class="oe_inline" nolabel="1" attrs="{'readonly': [('purchase_journal_id','=',False)]}"/>
<field name="purchase_sequence_next" nolabel="1" class="oe_inline" attrs="{'readonly': [('purchase_journal_id','=',False)]}"/>
</group>
<label for="purchase_refund_sequence_next"/>
<group>
<field name="purchase_refund_sequence_prefix" class="oe_inline" nolabel="1"
<field name="purchase_refund_sequence_prefix" class="oe_inline" nolabel="1"
help='If you put "%%(year)s" in the prefix, it will be replaced by the current year.'/>
<field name="purchase_refund_sequence_next" class="oe_inline" nolabel="1"
attrs="{'readonly': [('purchase_refund_journal_id','=',False)]}"/>
<field name="purchase_refund_sequence_next" class="oe_inline"
attrs="{'readonly': [('purchase_refund_journal_id','=',False)]}" nolabel="1"/>
</group>
<field name="module_account_payment"/>
</group>
<group string="Electronic Payments">
<separator string="Electronic Payments" colspan="2"/>
<field name="paypal_account" placeholder="sales@openerp.com"/>
</group>
<group string="Bank &amp; Cash">
<separator string="Bank &amp; Cash" colspan="2"/>
<label for="id" string="Configure Bank Accounts"/>
<button name="%(action_bank_tree)d" string="Configure Bank Accounts" icon="gtk-go-forward" type="action"/>
<field name="company_footer"/>
<field name="module_account_check_writing"/>
</group>
<group name="analytic_accounting" invisible="1" string="Analytic Accounting"/>
</group>
<field name="sale_journal_id" invisible="1"/>
<field name="sale_refund_journal_id" invisible="1"/>
<field name="purchase_journal_id" invisible="1"/>
<field name="purchase_refund_journal_id" invisible="1"/>
</form>
</field>
</record>

View File

@ -44,4 +44,5 @@ class res_currency_account(osv.osv):
res_currency_account()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -1,5 +1,5 @@
-
In order to test Cash statement I create a Cash statement and confirm it and check it's move created
In order to test Cash statement I create a Cash statement and confirm it and check its move created
-
!record {model: account.bank.statement, id: account_bank_statement_1}:
date: !eval time.strftime('%Y-%m-%d')
@ -57,7 +57,6 @@
- pieces: 500.0
number: 2
subtotal: 1000.0
balance_end_cash: 1120.0
-
I clicked on Close CashBox button to close the cashbox

View File

@ -64,6 +64,8 @@ import account_report_account_balance
import account_change_currency
import pos_box;
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -7,13 +7,18 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Account charts" version="7.0">
<group colspan="4">
<field name="fiscalyear" on_change="onchange_fiscalyear(fiscalyear)"/>
<group>
<label for="fiscalyear"/>
<div>
<field name="fiscalyear" on_change="onchange_fiscalyear(fiscalyear)" class="oe_inline"/>
<label align="0.7" string="(If you do not select Fiscal year it will take all open fiscal years)" class="oe_inline"/>
</div>
<field name="target_move"/>
<label align="0.7" colspan="4" string="(If you do not select Fiscal year it will take all open fiscal years)"/>
<separator string="Periods" colspan="4"/>
<field name="period_from"/>
<field name="period_to"/>
<label for="period_from" string="Periods"/>
<div>
<field name="period_from" class="oe_inline"/> -
<field name="period_to" class="oe_inline"/>
</div>
</group>
<footer>
<button string="Open Charts" name="account_chart_open_window" type="object" class="oe_highlight"/>

View File

@ -30,7 +30,7 @@ class account_fiscalyear_close_state(osv.osv_memory):
_description = "Fiscalyear Close state"
_columns = {
'fy_id': fields.many2one('account.fiscalyear', \
'Fiscal Year to close', required=True, help="Select a fiscal year to close"),
'Fiscal Year to Close', required=True, help="Select a fiscal year to close"),
}
def data_save(self, cr, uid, ids, context=None):

View File

@ -7,15 +7,15 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Close states of Fiscal year and periods" version="7.0">
<header>
<button icon="terp-locked" string="Close Fiscalyear" name="data_save" type="object" class="oe_highlight" />
</header>
<separator string="Close states of Fiscal year and periods"/>
<label string ="If no additional entries should be recorded on a fiscal year, you can close it from here. It will close all opened periods in this year that will make impossible any new entry record. Close a fiscal year when you need to finalize your end of year results definitive "/>
<group>
<field name="fy_id" domain="[('state','=','draft')]"/>
</group>
</form>
<footer>
<button icon="terp-locked" string="Close Fiscal Year" name="data_save" type="object" class="oe_highlight"/>
or
<button string="Cancel" class="oe_link" special="cancel"/>
</footer>
</form>
</field>
</record>

View File

@ -102,22 +102,20 @@ class account_move_journal(osv.osv_memory):
period = period_pool.browse(cr, uid, [period_id], ['name'])[0]['name']
period_string = _("Period: %s") % tools.ustr(period)
separator_string = _("Open Journal Items !")
open_string = _("Open")
view = """<?xml version="1.0" encoding="utf-8"?>
<form string="Standard entries" version="7.0">
<header>
<group>
<field name="target_move"/>
</group>
%s: <label string="%s"/>
%s: <label string="%s"/>
<footer>
<button string="%s" name="action_open_window" default_focus="1" type="object" class="oe_highlight"/>
or
<button string="Cancel" class="oe_link" special="cancel"/>
</header>
<group string="%s">
<field name="target_move" />
</group>
<label width="300" string="%s"/>
<newline/>
<label width="300" string="%s"/>
</form>""" % (open_string, separator_string, journal_string, period_string)
</footer>
</form>""" % (_('Journal'), journal_string, _('Period'), period_string, open_string)
view = etree.fromstring(view.encode('utf8'))
xarch, xfields = self._view_look_dom_arch(cr, uid, view, view_id, context=context)

View File

@ -13,10 +13,6 @@
<xpath expr="//field[@name='journal_ids']" position="replace">
<field name="journal_ids" colspan="4" nolabel="1" required="0" readonly="1"/>
</xpath>
<xpath expr="/form/label[@string='']" position="replace">
<separator string="Trial Balance" colspan="4"/>
<label nolabel="1" colspan="4" string="This report allows you to print or generate a pdf of your trial balance allowing you to quickly check the balance of each of your accounts in a single report"/>
</xpath>
<xpath expr="//field[@name='target_move']" position="after">
<field name="display_account"/>
<newline/>

View File

@ -17,16 +17,16 @@
</group>
<notebook tabpos="up" colspan="4">
<page string="Filters" name="filters">
<group col="4">
<group>
<field name="filter" on_change="onchange_filter(filter, fiscalyear_id)"/>
</group>
<group string="Dates" col="4">
<field name="date_from" attrs="{'readonly':[('filter', '!=', 'filter_date')], 'required':[('filter', '=', 'filter_date')]}" colspan="4"/>
<field name="date_to" attrs="{'readonly':[('filter', '!=', 'filter_date')], 'required':[('filter', '=', 'filter_date')]}" colspan="4"/>
<group string="Dates" attrs="{'invisible':[('filter', '!=', 'filter_date')], 'required':[('filter', '=', 'filter_date')]}">
<field name="date_from" />
<field name="date_to" />
</group>
<group string="Periods" col="4">
<field name="period_from" domain="[('fiscalyear_id', '=', fiscalyear_id)]" attrs="{'readonly':[('filter','!=','filter_period')], 'required':[('filter', '=', 'filter_period')]}" colspan="4"/>
<field name="period_to" domain="[('fiscalyear_id', '=', fiscalyear_id)]" attrs="{'readonly':[('filter','!=','filter_period')], 'required':[('filter', '=', 'filter_period')]}" colspan="4"/>
<group string="Periods" attrs="{'invisible':[('filter','!=','filter_period')], 'required':[('filter', '=', 'filter_period')]}">
<field name="period_from" domain="[('fiscalyear_id', '=', fiscalyear_id)]"/>
<field name="period_to" domain="[('fiscalyear_id', '=', fiscalyear_id)]"/>
</group>
</page>
<page string="Journals" name="journal_ids">

View File

@ -9,10 +9,6 @@
<field name="inherit_id" ref="account_common_report_view" />
<field name="arch" type="xml">
<data>
<xpath expr="/form/label[@string='']" position="replace">
<separator string="General Journals" colspan="4"/>
<label nolabel="1" colspan="4" string="This report gives you an overview of the situation of your general journals"/>
</xpath>
<xpath expr="//field[@name='target_move']" position="after">
<field name="amount_currency"/>
<newline/>

View File

@ -9,10 +9,6 @@
<field name="inherit_id" ref="account_common_report_view" />
<field name="arch" type="xml">
<data>
<xpath expr="/form/label[@string='']" position="replace">
<separator string="General Ledger" colspan="4"/>
<label nolabel="1" colspan="4" string="This report allows you to print or generate a pdf of your general ledger with details of all your account journals"/>
</xpath>
<xpath expr="//field[@name='target_move']" position="after">
<field name="display_account"/>
<field name="sortby"/>

View File

@ -9,10 +9,6 @@
<field name="inherit_id" ref="account_common_report_view" />
<field name="arch" type="xml">
<data>
<xpath expr="/form/label[@string='']" position="replace">
<separator string="Partner Balance" colspan="4"/>
<label nolabel="1" colspan="4" string="This report is an analysis done by a partner. It is a PDF report containing one line per partner representing the cumulative credit balance"/>
</xpath>
<xpath expr="//field[@name='target_move']" position="after">
<field name="result_selection"/>
<field name="display_partner"/>

View File

@ -9,10 +9,6 @@
<field name="inherit_id" ref="account_common_report_view" />
<field name="arch" type="xml">
<data>
<xpath expr="/form/label[@string='']" position="replace">
<separator string="Partner Ledger" colspan="4"/>
<label nolabel="1" colspan="4" string="This report is an analysis done by a partner. It is a PDF report containing one line per partner representing the cumulative credit balance"/>
</xpath>
<xpath expr="//field[@name='target_move']" position="after">
<field name="result_selection"/>
<field name="amount_currency"/>

View File

@ -9,10 +9,6 @@
<field name="inherit_id" ref="account_common_report_view" />
<field name="arch" type="xml">
<data>
<xpath expr="/form/label[@string='']" position="replace">
<separator string="Journals" colspan="4"/>
<label nolabel="1" colspan="4" string="This report gives you an overview of the situation of a specific journal"/>
</xpath>
<xpath expr="//field[@name='target_move']" position="after">
<field name="sort_selection"/>
<field name="amount_currency"/>

View File

@ -28,7 +28,7 @@ class account_subscription_generate(osv.osv_memory):
_name = "account.subscription.generate"
_description = "Subscription Compute"
_columns = {
'date': fields.date('Date', required=True),
'date': fields.date('Generate Entries Before', required=True),
}
_defaults = {
'date': lambda *a: time.strftime('%Y-%m-%d'),

View File

@ -8,8 +8,6 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Subscription Compute" version="7.0">
<separator string="Generate Entries before:"/>
<label string ="Automatically generate entries based on what has been entered in the system before a specific date."/>
<group>
<field name="date"/>
</group>

View File

@ -9,10 +9,13 @@
<field name="arch" type="xml">
<form string="Account tax charts" version="7.0">
<group>
<field name="period_id"/>
<label colspan="4" string="(If you do not select period it will take all open periods)"/>
<label for="period_id"/>
<div>
<field name="period_id" class="oe_inline"/>
<label string="(If you do not select period it will take all open periods)" class="oe_inline"/>
</div>
<field name="target_move"/>
</group>
</group>
<footer>
<button string="Open Charts" name="account_tax_chart_open_window" type="object" class="oe_highlight"/>
or

View File

@ -8,8 +8,6 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Create Entries From Models" version="7.0">
<separator string="This wizard will create recurring accounting entries"/>
<label string="Create manual recurring entries in a chosen journal."/>
<group>
<field name="model"/>
</group>

View File

@ -9,8 +9,6 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Post Journal Entries" version="7.0">
<separator string="Post Journal Entries of a Journal"/>
<label string="All draft account entries in this journal and period will be validated. It means you won't be able to modify their accounting fields anymore."/>
<group>
<field name="journal_id"/>
<field name="period_id"/>
@ -25,7 +23,7 @@
</record>
<record id="action_validate_account_move" model="ir.actions.act_window">
<field name="name">Open Journal</field>
<field name="name">Post Journal Entries</field>
<field name="res_model">validate.account.move</field>
<field name="view_type">form</field>
<field name="view_mode">form</field>

View File

@ -0,0 +1,85 @@
#!/usr/bin/env python
from osv import osv, fields
import decimal_precision as dp
from tools.translate import _
class CashBox(osv.osv_memory):
_register = False
_columns = {
'name' : fields.char('Reason', size=64, required=True),
# Attention, we don't set a domain, because there is a journal_type key
# in the context of the action
'amount' : fields.float('Amount',
digits_compute = dp.get_precision('Account'),
required=True),
}
def run(self, cr, uid, ids, context=None):
if not context:
context = dict()
active_model = context.get('active_model', False) or False
active_ids = context.get('active_ids', []) or []
records = self.pool.get(active_model).browse(cr, uid, active_ids, context=context)
return self._run(cr, uid, ids, records, context=None)
def _run(self, cr, uid, ids, records, context=None):
for box in self.browse(cr, uid, ids, context=context):
for record in records:
if not record.journal_id:
raise osv.except_osv(_('Error !'),
_("Please check that the field 'Journal' is set on the Bank Statement"))
if not record.journal_id.internal_account_id:
raise osv.except_osv(_('Error !'),
_("Please check that the field 'Internal Transfers Account' is set on the payment method '%s'.") % (record.journal_id.name,))
self._create_bank_statement_line(cr, uid, box, record, context=context)
return {}
class CashBoxIn(CashBox):
_name = 'cash.box.in'
_columns = CashBox._columns.copy()
_columns.update({
'ref' : fields.char('Reference', size=32),
})
def _create_bank_statement_line(self, cr, uid, box, record, context=None):
absl_proxy = self.pool.get('account.bank.statement.line')
values = {
'statement_id' : record.id,
'journal_id' : record.journal_id.id,
'account_id' : record.journal_id.internal_account_id.id,
'amount' : box.amount or 0.0,
'ref' : "%s" % (box.ref or ''),
'name' : box.name,
}
return absl_proxy.create(cr, uid, values, context=context)
CashBoxIn()
class CashBoxOut(CashBox):
_name = 'cash.box.out'
def _create_bank_statement_line(self, cr, uid, box, record, context=None):
absl_proxy = self.pool.get('account.bank.statement.line')
amount = box.amount or 0.0
values = {
'statement_id' : record.id,
'journal_id' : record.journal_id.id,
'account_id' : record.journal_id.internal_account_id.id,
'amount' : -amount if amount > 0.0 else amount,
'name' : box.name,
}
return absl_proxy.create(cr, uid, values, context=context)
CashBoxOut()

View File

@ -0,0 +1,62 @@
<?xml version="1.0" encoding="UTF-8"?>
<openerp>
<data>
<record model="ir.ui.view" id="cash_box_in_form">
<field name="name">cash_box_in</field>
<field name="model">cash.box.in</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Put Money In">
<separator string="Fill in this form if you put money in the cash register:" colspan="4" />
<field name="name" />
<field name="amount" />
<separator colspan="4" />
<group colspan="4" col="4">
<group col="2" colspan="2" />
<button icon="gtk-stop" special="cancel" string="Cancel" />
<button name="run" string="Put Money In" colspan="1" type="object" icon="gtk-apply" />
</group>
</form>
</field>
</record>
<act_window
name="Put Money In"
res_model="cash.box.in"
src_model="account.bank.statement"
view_mode="form"
target="new"
key2="client_action_multi"
id="action_cash_box_in" />
<record model="ir.ui.view" id="cash_box_out_form">
<field name="name">cash_box_out</field>
<field name="model">cash.box.out</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Take Money Out">
<separator string="Describe why you take money from the cash register:" colspan="4" />
<field name="name" />
<field name="amount" />
<separator colspan="4" />
<group colspan="4" col="4">
<group col="2" colspan="2" />
<button icon="gtk-stop" special="cancel" string="Cancel" />
<button name="run" string="Take Money Out" colspan="1" type="object" icon="gtk-apply" />
</group>
</form>
</field>
</record>
<act_window
name="Take Money Out"
res_model="cash.box.out"
src_model="account.bank.statement"
view_mode="form"
target="new"
key2="client_action_multi"
id="action_cash_box_out" />
</data>
</openerp>

View File

@ -213,13 +213,13 @@ class account_asset_asset(osv.osv):
_columns = {
'account_move_line_ids': fields.one2many('account.move.line', 'asset_id', 'Entries', readonly=True, states={'draft':[('readonly',False)]}),
'name': fields.char('Asset', size=64, required=True, readonly=True, states={'draft':[('readonly',False)]}),
'name': fields.char('Asset Name', size=64, required=True, readonly=True, states={'draft':[('readonly',False)]}),
'code': fields.char('Reference', size=32, readonly=True, states={'draft':[('readonly',False)]}),
'purchase_value': fields.float('Gross value ', required=True, readonly=True, states={'draft':[('readonly',False)]}),
'purchase_value': fields.float('Gross Value', required=True, readonly=True, states={'draft':[('readonly',False)]}),
'currency_id': fields.many2one('res.currency','Currency',required=True, readonly=True, states={'draft':[('readonly',False)]}),
'company_id': fields.many2one('res.company', 'Company', required=True, readonly=True, states={'draft':[('readonly',False)]}),
'note': fields.text('Note'),
'category_id': fields.many2one('account.asset.category', 'Asset category', required=True, change_default=True, readonly=True, states={'draft':[('readonly',False)]}),
'category_id': fields.many2one('account.asset.category', 'Asset Category', required=True, change_default=True, readonly=True, states={'draft':[('readonly',False)]}),
'parent_id': fields.many2one('account.asset.asset', 'Parent Asset', readonly=True, states={'draft':[('readonly',False)]}),
'child_ids': fields.one2many('account.asset.asset', 'parent_id', 'Children Assets'),
'purchase_date': fields.date('Purchase Date', required=True, readonly=True, states={'draft':[('readonly',False)]}),
@ -233,7 +233,7 @@ class account_asset_asset(osv.osv):
" * Linear: Calculated on basis of: Gross Value / Number of Depreciations\n" \
" * Degressive: Calculated on basis of: Remaining Value * Degressive Factor"),
'method_number': fields.integer('Number of Depreciations', readonly=True, states={'draft':[('readonly',False)]}, help="Calculates Depreciation within specified interval"),
'method_period': fields.integer('Period Length', required=True, readonly=True, states={'draft':[('readonly',False)]}, help="State here the time during 2 depreciations, in months"),
'method_period': fields.integer('Number of Months in a Period', required=True, readonly=True, states={'draft':[('readonly',False)]}, help="State here the time during 2 depreciations, in months"),
'method_end': fields.date('Ending Date', readonly=True, states={'draft':[('readonly',False)]}),
'method_progress_factor': fields.float('Degressive Factor', readonly=True, states={'draft':[('readonly',False)]}),
'value_residual': fields.function(_amount_residual, method=True, digits_compute=dp.get_precision('Account'), string='Residual Value'),
@ -316,6 +316,19 @@ class account_asset_asset(osv.osv):
asset_id = super(account_asset_asset, self).create(cr, uid, vals, context=context)
self.compute_depreciation_board(cr, uid, [asset_id], context=context)
return asset_id
def open_entries(self, cr, uid, ids, context=None):
if context is None:
context = {}
context.update({'search_default_asset_id': ids, 'default_asset_id': ids})
return {
'view_type': 'form',
'view_mode': 'tree,form',
'res_model': 'account.move.line',
'view_id': False,
'type': 'ir.actions.act_window',
'context': context,
}
account_asset_asset()
@ -331,7 +344,7 @@ class account_asset_depreciation_line(osv.osv):
_columns = {
'name': fields.char('Depreciation Name', size=64, required=True, select=1),
'sequence': fields.integer('Sequence of the depreciation', required=True),
'sequence': fields.integer('Sequence', required=True),
'asset_id': fields.many2one('account.asset.asset', 'Asset', required=True),
'parent_state': fields.related('asset_id', 'state', type='char', string='State of Asset'),
'amount': fields.float('Depreciation Amount', required=True),

View File

@ -88,60 +88,87 @@
<field name="state" widget="statusbar" statusbar_visible="draft,open"/>
</header>
<sheet>
<label for="name"/>
<h1><field name="name"/></h1>
<label for="category_id"/>
<h2><field name="category_id" on_change="onchange_category_id(category_id)"/></h2>
<div class="oe_button_box oe_right">
<button name="open_entries" string="Entries" type="object" class="oe_inline"/>
</div>
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1>
<field name="name" class="oe_inline"/>
</h1>
</div>
<group>
<group>
<field name="category_id" on_change="onchange_category_id(category_id)"/>
<field name="code"/>
<field name="parent_id"/>
</group>
<group>
<field name="purchase_date"/>
<field name="currency_id"/>
<field name="company_id" widget="selection" groups="base.group_multi_company" on_change="onchange_company_id(company_id)"/>
</group>
</group>
<notebook colspan="4">
<page string="General">
<group>
<group>
<field name="code"/>
<field name="company_id" widget="selection"
groups="base.group_multi_company" on_change="onchange_company_id(company_id)"/>
</group>
<group>
<field name="purchase_value"/>
<field name="salvage_value"/>
<field name="value_residual"/>
<field name="currency_id"/>
</group>
<group>
<field name="partner_id"/>
<field name="purchase_date"/>
<field name="parent_id"/>
</group>
<group>
<field name="method_time" on_change="onchange_method_time(method_time)"/>
<field name="method_number" attrs="{'invisible':[('method_time','=','end')], 'required':[('method_time','=','number')]}"/>
<field name="method_period"/>
<field name="method_end" attrs="{'required': [('method_time','=','end')], 'invisible':[('method_time','=','number')]}"/>
<button name="%(action_asset_modify)d" states="open" string="Change Duration" type="action" icon="terp-stock_effects-object-colorize" colspan="2"/>
</group>
<group>
<field name="method"/>
<field name="method_progress_factor" attrs="{'invisible':[('method','=','linear')], 'required':[('method','=','degressive')]}"/>
<field name="prorata" attrs="{'invisible': [('method_time','=','end')]}"/>
</group>
</group>
<group>
<group>
<field name="purchase_value"/>
<field name="salvage_value"/>
<field name="value_residual"/>
<field name="partner_id"/>
</group>
<group>
<field name="method"/>
<field name="method_progress_factor" attrs="{'invisible':[('method','=','linear')], 'required':[('method','=','degressive')]}"/>
<label for="method_time"/>
<div>
<field name="method_time" on_change="onchange_method_time(method_time)" class="oe_inline"/>
<button name="%(action_asset_modify)d" states="open" string="Change Duration" type="action" icon="terp-stock_effects-object-colorize" class="oe_inline" colspan="1"/>
</div>
<field name="prorata" attrs="{'invisible': [('method_time','=','end')]}"/>
<field name="method_number" attrs="{'invisible':[('method_time','=','end')], 'required':[('method_time','=','number')]}"/>
<field name="method_period"/>
<field name="method_end" attrs="{'required': [('method_time','=','end')], 'invisible':[('method_time','=','number')]}"/>
</group>
</group>
</page>
<page string="Depreciation Board">
<field name="depreciation_line_ids" mode="tree,graph">
<tree string="Depreciation Lines" colors="blue:(move_check == False);black:(move_check == True)">
<field name="depreciation_date"/>
<field name="sequence" invisible="1"/>
<field name="depreciated_value" readonly="1"/>
<field name="amount"/>
<field name="remaining_value" readonly="1"/>
<field name="move_check"/>
<field name="parent_state" invisible="1"/>
<button name="create_move" attrs="{'invisible':['|',('move_check','!=',False),('parent_state','!=','open')]}" icon="gtk-execute" string="Create Move" type="object"/>
</tree>
<graph type="bar">
<field name="name"/>
<field name="amount"/>
<field name="depreciated_value"/>
</graph>
<tree string="Depreciation Lines" colors="blue:(move_check == False);black:(move_check == True)">
<field name="depreciation_date"/>
<field name="sequence" invisible="1"/>
<field name="depreciated_value" readonly="1"/>
<field name="amount"/>
<field name="remaining_value" readonly="1"/>
<field name="move_check"/>
<field name="parent_state" invisible="1"/>
<button name="create_move" attrs="{'invisible':['|',('move_check','!=',False),('parent_state','!=','open')]}" icon="gtk-execute" string="Create Move" type="object"/>
</tree>
<form string="Depreciation Lines">
<group>
<group>
<field name="asset_id" invisible="1"/>
<field name="parent_state" invisible="1"/>
<field name="name"/>
<field name="amount"/>
<field name="move_id"/>
<field name="move_check"/>
<field name="parent_state" invisible="1"/>
</group>
<group>
<field name="sequence"/>
<field name="depreciation_date"/>
<field name="depreciated_value" readonly="1"/>
<field name="remaining_value" readonly="1"/>
</group>
</group>
</form>
<graph type="bar">
<field name="name"/>
<field name="amount"/>
<field name="depreciated_value"/>
</graph>
</field>
<button type="object" name="compute_depreciation_board" string="Compute" icon="terp-stock_format-scientific" colspan="2" attrs="{'invisible':[('state','=','close')]}"/>
</page>
@ -150,12 +177,12 @@
<field name="history_ids" readonly="1"/>
</page>
<page string="Notes">
<field name="note"/>
<field name="note" placeholder="Add an internal note here..."/>
</page>
</notebook>
</sheet>
</form>
</field>
</sheet>
</form>
</field>
</record>
<record model="ir.ui.view" id="view_account_asset_asset_tree">

View File

@ -7,8 +7,6 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Compute Asset" version="7.0">
<separator string="Post Depreciation Lines"/>
<label string="This wizard will post the depreciation lines of running assets that belong to the selected period."/>
<group>
<field name="period_id"/>
</group>

View File

@ -41,9 +41,10 @@ class account_bank_statement(osv.osv):
def button_confirm_bank(self, cr, uid, ids, context=None):
super(account_bank_statement, self).button_confirm_bank(cr, uid, ids, context=context)
for st in self.browse(cr, uid, ids, context=context):
cr.execute("UPDATE account_bank_statement_line \
SET state='confirm' WHERE id in %s ",
(tuple([x.id for x in st.line_ids]),))
if st.line_ids:
cr.execute("UPDATE account_bank_statement_line \
SET state='confirm' WHERE id in %s ",
(tuple([x.id for x in st.line_ids]),))
return True
def button_cancel(self, cr, uid, ids, context=None):

View File

@ -0,0 +1,374 @@
# Mongolian translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:35+0000\n"
"PO-Revision-Date: 2012-07-16 07:16+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Mongolian <mn@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: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Search Bank Transactions"
msgstr "Банкны гүйлгээгээр хайх"
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
#: selection:account.bank.statement.line,state:0
msgid "Confirmed"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement:0
#: view:account.bank.statement.line:0
msgid "Glob. Id"
msgstr ""
#. module: account_bank_statement_extensions
#: selection:account.bank.statement.line.global,type:0
msgid "CODA"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,parent_id:0
msgid "Parent Code"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Debit"
msgstr ""
#. module: account_bank_statement_extensions
#: view:cancel.statement.line:0
#: model:ir.actions.act_window,name:account_bank_statement_extensions.action_cancel_statement_line
#: model:ir.model,name:account_bank_statement_extensions.model_cancel_statement_line
msgid "Cancel selected statement lines"
msgstr ""
#. module: account_bank_statement_extensions
#: constraint:res.partner.bank:0
msgid "The RIB and/or IBAN is not valid"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Group By..."
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,state:0
msgid "State"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
#: selection:account.bank.statement.line,state:0
msgid "Draft"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Statement"
msgstr ""
#. module: account_bank_statement_extensions
#: view:confirm.statement.line:0
#: model:ir.actions.act_window,name:account_bank_statement_extensions.action_confirm_statement_line
#: model:ir.model,name:account_bank_statement_extensions.model_confirm_statement_line
msgid "Confirm selected statement lines"
msgstr ""
#. module: account_bank_statement_extensions
#: report:bank.statement.balance.report:0
#: model:ir.actions.report.xml,name:account_bank_statement_extensions.bank_statement_balance_report
msgid "Bank Statement Balances Report"
msgstr ""
#. module: account_bank_statement_extensions
#: view:cancel.statement.line:0
msgid "Cancel Lines"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line.global:0
#: model:ir.model,name:account_bank_statement_extensions.model_account_bank_statement_line_global
msgid "Batch Payment Info"
msgstr "Багц төлбөрийн мэдээлэл"
#. module: account_bank_statement_extensions
#: view:confirm.statement.line:0
msgid "Confirm Lines"
msgstr ""
#. module: account_bank_statement_extensions
#: code:addons/account_bank_statement_extensions/account_bank_statement.py:130
#, python-format
msgid ""
"Delete operation not allowed ! Please go to the associated bank "
"statement in order to delete and/or modify this bank statement line"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,type:0
msgid "Type"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
#: field:account.bank.statement.line,journal_id:0
#: report:bank.statement.balance.report:0
msgid "Journal"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Confirmed Statement Lines."
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Credit Transactions."
msgstr "Кредитын гүйлгээ"
#. module: account_bank_statement_extensions
#: model:ir.actions.act_window,help:account_bank_statement_extensions.action_cancel_statement_line
msgid "cancel selected statement lines."
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,counterparty_number:0
msgid "Counterparty Number"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line.global:0
msgid "Transactions"
msgstr "Гүйлгээ"
#. module: account_bank_statement_extensions
#: code:addons/account_bank_statement_extensions/account_bank_statement.py:130
#, python-format
msgid "Warning"
msgstr ""
#. module: account_bank_statement_extensions
#: report:bank.statement.balance.report:0
msgid "Closing Balance"
msgstr ""
#. module: account_bank_statement_extensions
#: report:bank.statement.balance.report:0
msgid "Date"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
#: field:account.bank.statement.line,globalisation_amount:0
msgid "Glob. Amount"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Debit Transactions."
msgstr "Дебитын гүйлгээ"
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Extended Filters..."
msgstr ""
#. module: account_bank_statement_extensions
#: view:confirm.statement.line:0
msgid "Confirmed lines cannot be changed anymore."
msgstr ""
#. module: account_bank_statement_extensions
#: constraint:res.partner.bank:0
msgid ""
"\n"
"Please define BIC/Swift code on bank for bank type IBAN Account to make "
"valid payments"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,val_date:0
msgid "Valuta Date"
msgstr "Мөнгөн тэмдэгтийн огноо"
#. module: account_bank_statement_extensions
#: model:ir.actions.act_window,help:account_bank_statement_extensions.action_confirm_statement_line
msgid "Confirm selected statement lines."
msgstr ""
#. module: account_bank_statement_extensions
#: view:cancel.statement.line:0
msgid "Are you sure you want to cancel the selected Bank Statement lines ?"
msgstr ""
#. module: account_bank_statement_extensions
#: report:bank.statement.balance.report:0
msgid "Name"
msgstr ""
#. module: account_bank_statement_extensions
#: selection:account.bank.statement.line.global,type:0
msgid "ISO 20022"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Notes"
msgstr ""
#. module: account_bank_statement_extensions
#: selection:account.bank.statement.line.global,type:0
msgid "Manual"
msgstr "Гарын авлага"
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Credit"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,amount:0
msgid "Amount"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Fin.Account"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,counterparty_currency:0
msgid "Counterparty Currency"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,counterparty_bic:0
msgid "Counterparty BIC"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,child_ids:0
msgid "Child Codes"
msgstr ""
#. module: account_bank_statement_extensions
#: view:confirm.statement.line:0
msgid "Are you sure you want to confirm the selected Bank Statement lines ?"
msgstr ""
#. module: account_bank_statement_extensions
#: constraint:account.bank.statement.line:0
msgid ""
"The amount of the voucher must be the same amount as the one on the "
"statement line"
msgstr ""
#. module: account_bank_statement_extensions
#: help:account.bank.statement.line,globalisation_id:0
msgid ""
"Code to identify transactions belonging to the same globalisation level "
"within a batch payment"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Draft Statement Lines."
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Glob. Am."
msgstr ""
#. module: account_bank_statement_extensions
#: model:ir.model,name:account_bank_statement_extensions.model_account_bank_statement_line
msgid "Bank Statement Line"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,code:0
msgid "Code"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,counterparty_name:0
msgid "Counterparty Name"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,name:0
msgid "Communication"
msgstr ""
#. module: account_bank_statement_extensions
#: model:ir.model,name:account_bank_statement_extensions.model_res_partner_bank
msgid "Bank Accounts"
msgstr ""
#. module: account_bank_statement_extensions
#: constraint:account.bank.statement:0
msgid "The journal and period chosen have to belong to the same company."
msgstr ""
#. module: account_bank_statement_extensions
#: model:ir.model,name:account_bank_statement_extensions.model_account_bank_statement
msgid "Bank Statement"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Statement Line"
msgstr "Тайлангийн мөр"
#. module: account_bank_statement_extensions
#: sql_constraint:account.bank.statement.line.global:0
msgid "The code must be unique !"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line.global,bank_statement_line_ids:0
#: model:ir.actions.act_window,name:account_bank_statement_extensions.action_bank_statement_line
#: model:ir.ui.menu,name:account_bank_statement_extensions.bank_statement_line
msgid "Bank Statement Lines"
msgstr "Банкны тайлангийн мөр"
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line.global:0
msgid "Child Batch Payments"
msgstr "Хүү багцын төлбөр"
#. module: account_bank_statement_extensions
#: view:cancel.statement.line:0
#: view:confirm.statement.line:0
msgid "Cancel"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Statement Lines"
msgstr ""
#. module: account_bank_statement_extensions
#: view:account.bank.statement.line:0
msgid "Total Amount"
msgstr ""
#. module: account_bank_statement_extensions
#: field:account.bank.statement.line,globalisation_id:0
msgid "Globalisation ID"
msgstr ""

View File

@ -108,48 +108,71 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form version="7.0">
<header>
<button string="Confirm" name="confirm" states="draft" type="workflow" class="oe_highlight"/>
<button string="Approve" name="validate" states="confirm" type="workflow" class="oe_highlight"/>
<button string="Done" name="done" states="validate" type="workflow" class="oe_highlight"/>
<button name="draft" states="cancel" string="Reset to Draft" type="workflow" />
<button string="Cancel" name="cancel" states="confirm,validate" type="workflow"/>
<field name="state" widget="statusbar" statusbar_visible="draft,confirm"/>
</header>
<sheet string="Budget">
<group col="4">
<field name="name" colspan="1" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="code" colspan="1" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="creating_user_id" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="validating_user_id" readonly="True" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="date_from" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="date_to" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="crossovered_budget_line" colspan="4" nolabel="1" attrs="{'readonly':[('state','!=','draft')]}">
<tree string="Budget Lines">
<field name="analytic_account_id" groups="analytic.group_analytic_accounting"/>
<field name="general_budget_id"/>
<field name="date_from"/>
<field name="date_to"/>
<field name="paid_date"/>
<field name="planned_amount" sum="Planned Amount"/>
<field name="practical_amount" sum="Practical Amount"/>
<field name="theoritical_amount" sum="Theoretical Amount"/>
<field name="percentage"/>
</tree>
<form string="Budget Lines" version="7.0">
<group col="4">
<header>
<button string="Confirm" name="confirm" states="draft" type="workflow" class="oe_highlight"/>
<button string="Approve" name="validate" states="confirm" type="workflow" class="oe_highlight"/>
<button string="Done" name="done" states="validate" type="workflow" class="oe_highlight"/>
<button name="draft" states="cancel" string="Reset to Draft" type="workflow" />
<button string="Cancel" name="cancel" states="confirm,validate" type="workflow"/>
<field name="state" widget="statusbar" statusbar_visible="draft,confirm"/>
</header>
<sheet string="Budget">
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1>
<field name="name" attrs="{'readonly':[('state','!=','draft')]}"/>
</h1>
</div>
<group>
<group>
<field name="creating_user_id" attrs="{'readonly':[('state','!=','draft')]}"/>
<field name="validating_user_id" readonly="True" attrs="{'readonly':[('state','!=','draft')]}"/>
</group>
<group>
<field name="code" attrs="{'readonly':[('state','!=','draft')]}"/>
<label for="date_from" string="Duration"/>
<div>
<field name="date_from" class="oe_inline" attrs="{'readonly':[('state','!=','draft')]}"/> -
<field name="date_to" class="oe_inline" attrs="{'readonly':[('state','!=','draft')]}" nolabel="1"/>
</div>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
</group>
</group>
<notebook>
<page string="Budget Lines">
<field name="crossovered_budget_line" colspan="4" nolabel="1" attrs="{'readonly':[('state','!=','draft')]}">
<tree string="Budget Lines">
<field name="analytic_account_id" groups="analytic.group_analytic_accounting"/>
<field name="general_budget_id"/>
<field name="date_from"/>
<field name="date_to"/>
<field name="paid_date"/>
<field name="planned_amount"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
</form>
</field>
</group>
<field name="planned_amount" sum="Planned Amount"/>
<field name="practical_amount" sum="Practical Amount"/>
<field name="theoritical_amount" sum="Theoretical Amount"/>
<field name="percentage"/>
</tree>
<form string="Budget Lines" version="7.0">
<group>
<group>
<field name="analytic_account_id" groups="analytic.group_analytic_accounting"/>
<field name="general_budget_id"/>
<field name="planned_amount"/>
</group>
<group>
<label for="date_from" string="Duration"/>
<div>
<field name="date_from" class="oe_inline"/> -
<field name="date_to" class="oe_inline"/>
</div>
<field name="paid_date"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
</group>
</form>
</field>
</page>
</notebook>
</sheet>
</form>
</field>

View File

@ -31,11 +31,9 @@
<field name="priority">17</field>
<field name="inherit_id" ref="base.view_company_form"/>
<field name="arch" type="xml">
<page string="Configuration" position="inside">
<separator string="Default Check Layout" colspan="4"/>
<xpath expr="//group[@name='account_grp']" position="inside">
<field name="check_layout"/>
<newline/>
</page>
</xpath>
</field>
</record>
</data>

View File

@ -2,7 +2,7 @@
<openerp>
<data>
<!-- Supplier voucher view -->
<!-- Supplier write check view -->
<record model="ir.ui.view" id="view_vendor_payment_check_form">
<field name="name">account.voucher.payment.check.form</field>

View File

@ -0,0 +1,199 @@
# Mongolian translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:35+0000\n"
"PO-Revision-Date: 2012-07-16 07:40+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Mongolian <mn@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: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: account_check_writing
#: selection:res.company,check_layout:0
msgid "Check on Top"
msgstr "Чекийн дээд хэсэг"
#. module: account_check_writing
#: model:ir.actions.act_window,help:account_check_writing.action_write_check
msgid ""
"The check payment form allows you to track the payment you do to your "
"suppliers specially by check. When you select a supplier, the payment method "
"and an amount for the payment, OpenERP will propose to reconcile your "
"payment with the open supplier invoices or bills.You can print the check"
msgstr ""
#. module: account_check_writing
#: view:account.voucher:0
#: model:ir.actions.report.xml,name:account_check_writing.account_print_check_bottom
#: model:ir.actions.report.xml,name:account_check_writing.account_print_check_middle
#: model:ir.actions.report.xml,name:account_check_writing.account_print_check_top
msgid "Print Check"
msgstr "Чек хэвлэх"
#. module: account_check_writing
#: selection:res.company,check_layout:0
msgid "Check in middle"
msgstr "Чекийн төв хэсэг"
#. module: account_check_writing
#: help:res.company,check_layout:0
msgid ""
"Check on top is compatible with Quicken, QuickBooks and Microsoft Money. "
"Check in middle is compatible with Peachtree, ACCPAC and DacEasy. Check on "
"bottom is compatible with Peachtree, ACCPAC and DacEasy only"
msgstr ""
#. module: account_check_writing
#: selection:res.company,check_layout:0
msgid "Check on bottom"
msgstr "Чекийн доод хэсэг"
#. module: account_check_writing
#: constraint:res.company:0
msgid "Error! You can not create recursive companies."
msgstr ""
#. module: account_check_writing
#: help:account.journal,allow_check_writing:0
msgid "Check this if the journal is to be used for writing checks."
msgstr ""
#. module: account_check_writing
#: field:account.journal,allow_check_writing:0
msgid "Allow Check writing"
msgstr "Бичсэн чекийг зөвшөөрөх"
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
#: report:account.print.check.top:0
msgid "Description"
msgstr ""
#. module: account_check_writing
#: model:ir.model,name:account_check_writing.model_account_journal
msgid "Journal"
msgstr ""
#. module: account_check_writing
#: model:ir.actions.act_window,name:account_check_writing.action_write_check
#: model:ir.ui.menu,name:account_check_writing.menu_action_write_check
msgid "Write Checks"
msgstr "Чек бичих"
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
#: report:account.print.check.top:0
msgid "Discount"
msgstr ""
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
#: report:account.print.check.top:0
msgid "Original Amount"
msgstr ""
#. module: account_check_writing
#: view:res.company:0
msgid "Configuration"
msgstr ""
#. module: account_check_writing
#: field:account.voucher,allow_check:0
msgid "Allow Check Writing"
msgstr ""
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
#: report:account.print.check.top:0
msgid "Payment"
msgstr ""
#. module: account_check_writing
#: field:account.journal,use_preprint_check:0
msgid "Use Preprinted Check"
msgstr ""
#. module: account_check_writing
#: sql_constraint:res.company:0
msgid "The company name must be unique !"
msgstr ""
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
#: report:account.print.check.top:0
msgid "Due Date"
msgstr ""
#. module: account_check_writing
#: model:ir.model,name:account_check_writing.model_res_company
msgid "Companies"
msgstr ""
#. module: account_check_writing
#: view:res.company:0
msgid "Default Check Layout"
msgstr ""
#. module: account_check_writing
#: constraint:account.journal:0
msgid ""
"Configuration error! The currency chosen should be shared by the default "
"accounts too."
msgstr ""
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
msgid "Balance Due"
msgstr ""
#. module: account_check_writing
#: report:account.print.check.bottom:0
#: report:account.print.check.middle:0
#: report:account.print.check.top:0
msgid "Check Amount"
msgstr "Чекийн дүн"
#. module: account_check_writing
#: model:ir.model,name:account_check_writing.model_account_voucher
msgid "Accounting Voucher"
msgstr ""
#. module: account_check_writing
#: sql_constraint:account.journal:0
msgid "The name of the journal must be unique per company !"
msgstr ""
#. module: account_check_writing
#: sql_constraint:account.journal:0
msgid "The code of the journal must be unique per company !"
msgstr ""
#. module: account_check_writing
#: field:account.voucher,amount_in_word:0
msgid "Amount in Word"
msgstr ""
#. module: account_check_writing
#: report:account.print.check.top:0
msgid "Open Balance"
msgstr ""
#. module: account_check_writing
#: field:res.company,check_layout:0
msgid "Choose Check layout"
msgstr ""

View File

@ -14,7 +14,7 @@
or
<button string="Cancel" class="oe_link" special="cancel"/>
</header>
<group col="2" string="Select Your File :">
<group col="2">
<field name="coda_data" filename="coda_fname"/>
<field name="coda_fname"/>
</group>

View File

@ -31,7 +31,7 @@ class account_followup_print(osv.osv_memory):
_description = 'Print Follow-up & Send Mail to Customers'
_columns = {
'date': fields.date('Follow-up Sending Date', required=True, help="This field allow you to select a forecast date to plan your follow-ups"),
'followup_id': fields.many2one('account_followup.followup', 'Follow-up', required=True),
'followup_id': fields.many2one('account_followup.followup', 'Follow-Up', required=True),
}
def _get_followup(self, cr, uid, context=None):
@ -121,10 +121,10 @@ class account_followup_print_all(osv.osv_memory):
_description = 'Print Follow-up & Send Mail to Customers'
_columns = {
'partner_ids': fields.many2many('account_followup.stat.by.partner', 'partner_stat_rel', 'osv_memory_id', 'partner_id', 'Partners', required=True),
'email_conf': fields.boolean('Send email confirmation'),
'email_conf': fields.boolean('Send Email Confirmation'),
'email_subject': fields.char('Email Subject', size=64),
'partner_lang': fields.boolean('Send Email in Partner Language', help='Do not change message text, if you want to send email in partner language, or configure from company'),
'email_body': fields.text('Email body'),
'email_body': fields.text('Email Body'),
'summary': fields.text('Summary', required=True, readonly=True),
'test_print': fields.boolean('Test Print', help='Check if you want to print follow-ups without changing follow-ups level.')
}

View File

@ -8,8 +8,6 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Send follow-ups" version="7.0">
<separator string="Send Follow-ups"/>
<label string ="This feature allows you to send reminders to partners with pending invoices. You can send them the default message for unpaid invoices or manually enter a message should you need to remind them of a specific information."/>
<group col="4">
<field name="followup_id"/>
<field name="date"/>
@ -24,7 +22,7 @@
</record>
<record id="action_account_followup_print" model="ir.actions.act_window">
<field name="name">Send follow-ups</field>
<field name="name">Send Follow-Ups</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">account.followup.print</field>
<field name="view_type">form</field>
@ -76,7 +74,7 @@
<field name="model">account.followup.print.all</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Send follow-ups" version="7.0">
<form string="Send Follow-Ups" version="7.0">
<header>
<button name="do_mail" string="Send Mails" type="object" class="oe_highlight"/>
<button name="do_print" string="Print Follow Ups" type="object" class="oe_highlight"/>
@ -93,7 +91,6 @@
<field name="partner_lang" colspan="4"/>
<field name="test_print" colspan="4"/>
<field name="email_subject" colspan="4"/>
<separator string="Email Body" colspan="4" />
<field name="email_body" colspan="4" nolabel="1"/>
</group>
<group string="Legend">
@ -125,7 +122,7 @@
</record>
<record id="action_account_followup_print_all" model="ir.actions.act_window">
<field name="name">Send follow-ups</field>
<field name="name">Send Follow-Ups</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">account.followup.print.all</field>
<field name="view_type">form</field>

View File

@ -87,9 +87,9 @@ class payment_order(osv.osv):
return res
_columns = {
'date_scheduled': fields.date('Scheduled date if fixed', states={'done':[('readonly', True)]}, help='Select a date if you have chosen Preferred Date to be fixed.'),
'date_scheduled': fields.date('Scheduled Date', states={'done':[('readonly', True)]}, help='Select a date if you have chosen Preferred Date to be fixed.'),
'reference': fields.char('Reference', size=128, required=1, states={'done': [('readonly', True)]}),
'mode': fields.many2one('payment.mode', 'Payment mode', select=True, required=1, states={'done': [('readonly', True)]}, help='Select the Payment Mode to be applied.'),
'mode': fields.many2one('payment.mode', 'Payment Mode', select=True, required=1, states={'done': [('readonly', True)]}, help='Select the Payment Mode to be applied.'),
'state': fields.selection([
('draft', 'Draft'),
('cancel', 'Cancelled'),
@ -98,14 +98,14 @@ class payment_order(osv.osv):
help='When an order is placed the state is \'Draft\'.\n Once the bank is confirmed the state is set to \'Confirmed\'.\n Then the order is paid the state is \'Done\'.'),
'line_ids': fields.one2many('payment.line', 'order_id', 'Payment lines', states={'done': [('readonly', True)]}),
'total': fields.function(_total, string="Total", type='float'),
'user_id': fields.many2one('res.users', 'User', required=True, states={'done': [('readonly', True)]}),
'user_id': fields.many2one('res.users', 'Responsible', required=True, states={'done': [('readonly', True)]}),
'date_prefered': fields.selection([
('now', 'Directly'),
('due', 'Due date'),
('fixed', 'Fixed date')
], "Preferred date", change_default=True, required=True, states={'done': [('readonly', True)]}, help="Choose an option for the Payment Order:'Fixed' stands for a date specified by you.'Directly' stands for the direct execution.'Due date' stands for the scheduled date of execution."),
'date_created': fields.date('Creation date', readonly=True),
'date_done': fields.date('Execution date', readonly=True),
], "Preferred Date", change_default=True, required=True, states={'done': [('readonly', True)]}, help="Choose an option for the Payment Order:'Fixed' stands for a date specified by you.'Directly' stands for the direct execution.'Due date' stands for the scheduled date of execution."),
'date_created': fields.date('Creation Date', readonly=True),
'date_done': fields.date('Execution Date', readonly=True),
'company_id': fields.related('mode', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True),
}

View File

@ -112,16 +112,25 @@
<button name="cancel" states="draft,open" string="Cancel"/>
<field name="state" widget="statusbar" statusbar_visible="draft,open"/>
</header>
<sheet string="Payment order" >
<group col="4">
<field name="reference"/>
<field name="mode" widget='selection'/>
<field name="user_id"/>
<field name="date_prefered"/>
<field name="date_scheduled" attrs="{'readonly':[('date_prefered','!=','fixed')]}" />
<field name="company_id" widget='selection' groups="base.group_multi_company"/>
<button name="%(action_create_payment_order)d" string="Select Invoices to Pay"
type="action" attrs="{'invisible':[('state','=','done')]}" icon="gtk-find"/>
<sheet string="Payment order">
<div class="oe_button_box">
<button name="%(action_create_payment_order)d" string="Select Invoices to Pay"
type="action" attrs="{'invisible':[('state','=','done')]}" icon="gtk-find"/>
</div>
<div class="oe_title">
<label for="reference" class="oe_edit_only"/>
<h1><field name="reference"/></h1>
</div>
<group>
<group>
<field name="user_id"/>
<field name="mode"/>
</group>
<group>
<field name="date_prefered"/>
<field name="date_scheduled" attrs="{'readonly':[('date_prefered','!=','fixed')]}"/>
<field name="company_id" widget='selection' groups="base.group_multi_company"/>
</group>
</group>
<field name="line_ids" context="{'order_id': active_id or False}" >
<form string="Payment Line" version="7.0">
@ -177,8 +186,6 @@
<field name="amount" sum="Total in Company Currency" invisible="1"/>
</tree>
</field>
<field name="date_created"/>
<field name="date_done"/>
</sheet>
</form>
</field>
@ -330,9 +337,9 @@
<field name="type">form</field>
<field name="inherit_id" ref="account.view_bank_statement_form"/>
<field name="arch" type="xml">
<field name="journal_id" position="after">
<button name="%(action_account_populate_statement_confirm)d" attrs="{'invisible':[('state','=','confirm')]}" string="Import payment lines" type="action" icon="gtk-execute"/>
</field>
<xpath expr="//div[@name='import_buttons']" position="inside">
<button name="%(action_account_populate_statement_confirm)d" attrs="{'invisible':[('state','=','confirm')]}" string="Import Payment Lines" type="action" icon="gtk-execute"/>
</xpath>
</field>
</record>

View File

@ -8,7 +8,7 @@
<field name="type">form</field>
<field name="inherit_id" ref="account.view_move_form"/>
<field name="arch" type="xml">
<field name="to_check" position="after">
<field name="period_id" position="after">
<field name="internal_sequence_number"/>
</field>
</field>
@ -44,7 +44,7 @@
<field name="inherit_id" ref="account.view_account_move_filter"/>
<field name="arch" type="xml">
<data>
<xpath expr="//field[@name='ref']" position="before">
<xpath expr="//field[@name='name']" position="after">
<field name="internal_sequence_number"/>
</xpath>
</data>

View File

@ -15,7 +15,7 @@
<field name="period_id" invisible="context.get('visible', True)"/>
<field name="type" invisible="context.get('visible', True)"/>
<field name="amount" sum="Total Amount"/>
<field name="audit"/>
<field name="audit" invisible="1"/>
<field name="state"/>
</tree>
</field>
@ -52,6 +52,7 @@
<sheet string="Accounting Voucher">
<group col="6" colspan="4">
<field name="partner_id" required="1" on_change="onchange_journal_voucher(line_ids, tax_id, amount, partner_id, journal_id, type)"/>
<field name="payment_rate_currency_id" invisible="1"/>
<field name="date" on_change="onchange_date(date, currency_id, payment_rate_currency_id, amount, company_id)"/>
<field name="journal_id" widget="selection" on_change="onchange_journal_voucher(line_ids, tax_id, amount, partner_id, journal_id, type)"/>
<field name="type" required="1"/>
@ -209,11 +210,11 @@
<field name="type">form</field>
<field name="inherit_id" ref="account.view_bank_statement_form"/>
<field name="arch" type="xml">
<field name="currency" invisible="1" position="after">
<button name="%(action_view_account_statement_from_invoice_lines)d"
<xpath expr="//div[@name='import_buttons']" position="inside">
<button name="%(action_view_account_statement_from_invoice_lines)d"
string="Import Invoices" type="action" icon="gtk-execute"
attrs="{'invisible':[('state','=','confirm')]}"/>
</field>
</xpath>
</field>
</record>
@ -272,8 +273,8 @@
<field name="type">form</field>
<field name="arch" type="xml">
<field name="currency_id" position="after">
<field name="income_currency_exchange_account_id" colspan="2"/>
<field name="expense_currency_exchange_account_id" colspan="2"/>
<field name="income_currency_exchange_account_id"/>
<field name="expense_currency_exchange_account_id"/>
</field>
</field>
</record>

View File

@ -149,26 +149,31 @@
<button name="action_cancel_draft" type="object" states="cancel" string="Set to Draft" invisible="context.get('line_type', False)"/>
<field name="state" widget="statusbar" statusbar_visible="draft,posted" statusbar_colors='{"proforma":"blue"}'/>
</header>
<sheet string="Bill Payment">
<group col="6">
<field name="partner_id" required="1" invisible="context.get('line_type', False)" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date, context)" context="{'invoice_currency':currency_id, 'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" string="Supplier"/>
<field name="amount" invisible="context.get('line_type', False)" on_change="onchange_amount(amount, payment_rate, partner_id, journal_id, currency_id, type, date, payment_rate_currency_id, company_id, context)"/>
<field name="journal_id"
domain="[('type','in',['bank', 'cash'])]"
invisible="context.get('line_type', False)"
widget="selection"
on_change="onchange_journal(journal_id, line_dr_ids, False, partner_id, date, amount, type, company_id, context)"
string="Payment Method"/>
<field name="date" invisible="context.get('line_type', False)" on_change="onchange_date(date, currency_id, payment_rate_currency_id, amount, company_id, context)"/>
<field name="reference" invisible="context.get('line_type', False)" string="Payment Ref" placeholder="003/10"/>
<field name="name" colspan="2" invisible="context.get('line_type', False)" placeholder="Invoice SAJ/0042"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<field name="account_id"
widget="selection"
invisible="True"/>
<field name="pre_line" invisible="1"/>
<field name="type" invisible="True"/>
<field name="currency_id" invisible="1" colspan="4"/>
<sheet>
<field name="account_id" invisible="True"/>
<field name="pre_line" invisible="1"/>
<field name="type" invisible="True"/>
<group>
<group>
<field name="partner_id" required="1" invisible="context.get('line_type', False)" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date, context)" context="{'invoice_currency':currency_id, 'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" string="Supplier"/>
<label for="amount" string="Amount"/>
<div>
<field name="amount" invisible="context.get('line_type', False)" on_change="onchange_amount(amount, payment_rate, partner_id, journal_id, currency_id, type, date, payment_rate_currency_id, company_id, context)" class="oe_inline"/>
<field name="currency_id" class="oe_inline"/>
</div>
<field name="journal_id"
domain="[('type','in',['bank', 'cash'])]"
invisible="context.get('line_type', False)"
widget="selection"
on_change="onchange_journal(journal_id, line_dr_ids, False, partner_id, date, amount, type, company_id, context)"
string="Payment Method"/>
</group>
<group>
<field name="date" invisible="context.get('line_type', False)" on_change="onchange_date(date, currency_id, payment_rate_currency_id, amount, company_id, context)"/>
<field name="reference" invisible="context.get('line_type', False)" string="Payment Ref" placeholder="003/10"/>
<field name="name" colspan="2" invisible="context.get('line_type', False)" placeholder="Invoice SAJ/0042"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
</group>
<notebook>
<page string="Payment Information">
@ -311,10 +316,15 @@
<group>
<group>
<field name="partner_id" domain="[('customer','=',True)]" required="1" invisible="context.get('line_type', False)" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date, context)" string="Customer" context="{'search_default_customer': 1}"/>
<field name="amount"
invisible="context.get('line_type', False)"
string="Paid Amount"
on_change="onchange_amount(amount, payment_rate, partner_id, journal_id, currency_id, type, date, payment_rate_currency_id, company_id, context)"/>
<label for="amount"
string="Paid Amount"/>
<div>
<field name="amount" class="oe_inline"
invisible="context.get('line_type', False)"
on_change="onchange_amount(amount, payment_rate, partner_id, journal_id, currency_id, type, date, payment_rate_currency_id, company_id, context)"/>
<field name="currency_id" class="oe_inline"/>
</div>
<field name="journal_id"
domain="[('type','in',['bank', 'cash'])]"
invisible="context.get('line_type', False)"
@ -323,7 +333,6 @@
string="Payment Method"/>
</group>
<group>
<field name="currency_id" invisible="1"/>
<field name="date" invisible="context.get('line_type', False)" on_change="onchange_date(date, currency_id, payment_rate_currency_id, amount, company_id, context)"/>
<field name="reference" invisible="context.get('line_type', False)" string="Payment Ref" placeholder="003/10"/>
<field name="name" colspan="2" invisible="context.get('line_type', False)" placeholder="Invoice SAJ/0042"/>

View File

@ -88,18 +88,18 @@
<field name="state" widget="statusbar" statusbar_visible="draft,posted" statusbar_colors='{"proforma":"blue"}'/>
</header>
<sheet string="Sales Receipt" >
<h1><label for="number" string="Sales Receipt "/><field name="number" class="oe_inline"/></h1>
<h1><label for="number" string="Sale Receipt"/> <field name="number" class="oe_inline" readonly="1"/></h1>
<group>
<group>
<field name="partner_id" domain="[('customer','=',True)]" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date, context)" string="Customer" context="{'search_default_customer':1, 'show_address': 1}" options='{"always_reload": true}'/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
<group>
<field name="currency_id" invisible="1"/>
<field name="journal_id" domain="[('type','in',['sale','sale_refund'])]" widget="selection" on_change="onchange_journal(journal_id, line_cr_ids, tax_id, partner_id, date, amount, type, company_id, context)"/>
<field name="date" on_change="onchange_date(date, currency_id, currency_id, amount, company_id, context)"/>
<field name="name"/>
<field name="paid" invisible="1"/>
<field name="currency_id" invisible="1"/>
</group>
<field name="type" invisible="True"/>
</group>
@ -113,23 +113,24 @@
<field name="account_analytic_id" groups="analytic.group_analytic_accounting"/>
</tree>
</field>
<group>
<group>
<field name="narration" placeholder="Internal Notes" nolabel="1"/>
<group class="oe_subtotal_footer oe_right">
<field name="tax_id"
on_change="onchange_price(line_cr_ids, tax_id, partner_id)"
widget="selection"
widget="selection" nolabel="1"
placeholder="select tax..."
domain="[('type_tax_use','in',('sale','all')), ('parent_id', '=', False)]"/>
<div>
<label for="tax_amount"/>
<field name="tax_amount" nolabel="1"/>
<div class="oe_subtotal_footer_separator">
<label for="amount"/>
<button type="object" class="oe_link oe_edit_only"
name="compute_tax" string="(update)"
attrs="{'invisible': [('state','!=','draft')]}"/>
</div>
<field name="tax_amount" nolabel="1"/>
<field name="amount" class="oe_subtotal_footer_separator" />
</div>
<field name="amount" class="oe_subtotal_footer_separator" nolabel="1"/>
</group>
<group>
<group>
<field name="pay_now" on_change="onchange_payment(pay_now, journal_id, partner_id)" required="1"/>
<field name="date_due" attrs="{'invisible':[('pay_now','=','pay_now')]}"/>
<field name="account_id"
@ -138,7 +139,7 @@
<field name="reference"
attrs="{'invisible':[('pay_now','!=','pay_now')]}"/>
</group>
</group>
</group>
</page>
<page string="Journal Items" attrs="{'invisible': [('state','!=','posted')]}">
<group col="4">
@ -228,37 +229,30 @@
<field name="state" widget="statusbar" statusbar_visible="draft,posted" statusbar_colors='{"proforma":"blue"}'/>
</header>
<sheet string="Supplier Voucher">
<div class="oe_title">
<label for="number" class="oe_edit_only"/>
<h1><field name="number" readonly="0" /></h1>
</div>
<h1><label for="number" string="Purchase Receipt"/> <field name="number" class="oe_inline" readonly="1"/></h1>
<field name="pay_now" invisible="1"/>
<field name="account_id" domain="[('type','=','other')]" invisible="True"/>
<field name="type" invisible="True"/>
<group>
<group>
<field name="partner_id" domain="[('supplier','=',True)]" required="1" string="Supplier" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date, context)" context="{'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" />
<field name="date" string="Bill Date" on_change="onchange_date(date, currency_id, currency_id, amount, company_id, context)"/>
<field name="date_due"/>
<field name="partner_id" domain="[('supplier','=',True)]" string="Supplier" on_change="onchange_partner_id(partner_id, journal_id, amount, currency_id, type, date, context)" context="{'default_customer': 0, 'search_default_supplier': 1, 'default_supplier': 1}" />
<field name="name" colspan="2"/>
<field name="reference"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
<group>
<field name="date" string="Bill Date" on_change="onchange_date(date, currency_id, currency_id, amount, company_id, context)"/>
<field name="date_due"/>
<field name="paid" invisible="1"/>
<field name="currency_id"/>
<field name="currency_id" invisible="1"/>
<field name="journal_id"
domain="[('type','in',['purchase','purchase_refund'])]"
widget="selection"
on_change="onchange_journal(journal_id, line_dr_ids, tax_id, partner_id, date, amount, type, company_id, context)"/>
<field name="reference"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
</group>
</group>
<group col="6">
<field name="account_id" domain="[('type','=','other')]" invisible="True"/>
<field name="type" invisible="True"/>
</group>
<notebook colspan="4">
<notebook>
<page string="Bill Information">
<field name="line_dr_ids" on_change="onchange_price(line_dr_ids, tax_id, partner_id)" context="{'journal_id':journal_id,'partner_id':partner_id}">
<tree string="Expense Lines" editable="bottom">
@ -269,10 +263,8 @@
</tree>
</field>
<group>
<group>
<field name="narration" placeholder="Internal Notes" nolabel="1" />
</group>
<group class="oe_subtotal_footer">
<field name="narration" placeholder="Internal Notes" nolabel="1"/>
<group class="oe_subtotal_footer oe_right">
<!--
<div>
<label for="tax_id" />
@ -284,13 +276,20 @@
-->
<field name="tax_id"
on_change="onchange_price(line_dr_ids, tax_id, partner_id)"
widget="selection"
widget="selection" nolabel="1"
placeholder="select tax..."
domain="[('type_tax_use','in',('purchase','all')), ('parent_id', '=', False)]"
/>
<field name="tax_amount" />
<field name="amount" string="Total" class="oe_subtotal_footer_separator"/>
</group>
<field name="tax_amount" nolabel="1"/>
<div class="oe_subtotal_footer_separator">
<label for="amount"/>
<button type="object" class="oe_link oe_edit_only"
name="compute_tax" string="(update)"
attrs="{'invisible': [('state','!=','draft')]}"/>
</div>
<field name="amount" class="oe_subtotal_footer_separator" nolabel="1"/>
</group>
</group>
</page>
<page string="Journal Items" attrs="{'invisible': [('state','!=','posted')]}">

View File

@ -1,12 +1,22 @@
<?xml version="1.0" encoding="utf-8"?>
<openerp>
<data>
<record model="res.users" id="user">
<record id="anonymous_user" model="res.users">
<field name="name">Anonymous</field>
<field name="login">anonymous</field>
<field name="password">anonymous</field>
<!-- Avoid auto-including this demo user in any default group -->
<field name="groups_id" eval="[(5,)]"/>
<field name="avatar">iVBORw0KGgoAAAANSUhEUgAAAJYAAACWCAAAAAAZai4+AAAMQElEQVR4nO2ce4wV1R3Hv7/fmbvrPliQZWEXWFgWEFgQBRNI0dZW7euPxliTRhNbW5NatammoaaPNKmpKRYiUunDFzEU28YYkRaiaX0hYhUELApaKG90l2VZdmVl2WXvnPPrH/c1M3d2uWdmePzB75+9d+7Mmc/8zjm/+T3OWRJciMLnGyBcLmLZyEUsG7mIZSNOAm2IQAAQQAAEAhBRrCYprjkVI6GPpkXFIIuHJYYJ6D/Wsb+97fiJk339A0ZVDa8bP3lG4xhAjDofWGIUcOifW3ceOFr026Q5V980CSbq2I2B5To49dILL/YAQE4tkhlf0ABG3Pzta+FG7EqJKEZL1/IZANgJuzMrBpxvvCuio7QeFcsVWTsLUEMogxSh7IEBcc8dVlrabyeoM40cRfjS3ihc0bC0bJoOp5R5lkLT1ghckbC0WV1bqiF20PCB/fiKpq30VUiVRgUozOgUY3mDaHaFKkmXeq5O/XehsTVDEc2dzX3Szqp1XPJTZCRRD4KYw+yFyBJtaVSTxGIxRkKmp6ZNG9nYNZUQEgAyo66ZnQrTizLPw250JYfF+OmHG7ZsukWKuQzeH1B2XJEMhHt10fM4+HHGDPwQRf1IqD1oZ7uS0hbpkfcYDWj51VgT1Jeo4+12vZhYJ8qoOlaAkrqWsGdtt2stMW3lfC6RyWG/n7ZrLvnIh04mcJ+ksYzqWE8hNmqYXTMRAzJWAXvOxABgDN/XporeNEL1sLLzEbF6deDWGr0AtOKFzxa//8g01Nq1HxFrfmUq0FO6UYmb6r37GcctOptkyuhzoS1+NGibBMSU2nTfu1xMBZYpZdoqZoyGRcVevGF1YvGy/lQ65HQj11m+EyMHZH4xrpi/zRpkYhPVHbH0T5PBckVeuQYYJDpTuM82ykgEKy2d38Wg4RnzsI+MZZCRBJaWVy4DDzqkU1hsHZIlgOXKCmeIQMjBl11jG/nEx3JllaJB32GUwhWt1lTxsbS8VD44FQM3tEbIjsTFMuZkS7E7moNycMnP+qPkbOJiubJ8MJNMCvjKZrGOqBPAMiZ9HYUqixygeZVIOgpVeDq2dBFufR9hIaDSbt1d99RDR7tBXCx0HA+LTJUu+8G9U+CWlGxKHivcSSfS1y5aAM2RWz8rVQymn7+6QJsYifkkqhhBYf3gL030nDxwVrSlzNd/4cZs+CxgGbqbB7f7pUn8TuQAAUnVVbGfNjaWMUX2IV0et9H4WJWTHT8X6ZpYoz3TSNzCnT5VbAaq4hUTkQDW2ZH4Qz77XCIioEwKILayktJWvqKpQ3PN1pIMllY4/f7h42r8lfUwiZjCeP5WRlxp/3VLJQA0LjwWrYAYkCSwXHm1GQA7DgPTdyfBlUhAtiYFJzvYHUw7oiM5pAljabO7xjOhU7gtUr3VL/HHp9BDPZ6clque26zsKikhEhtL+MA6b7JUaGBN3DYTwDK0q0vEd2BT/D5IwMik/VUekb2nbJNsRZIAVlFWpNeyNhAiCah7Qk1ANzWXxG00PhaZGXN9LjLTnIqQ4p2dJGAg+E4fBcnXwsoYdhL/VS3QX329YLhS6VnvVMV3bWIbZDFycAJSTABIpVD/XgIvxWRe1R/NBaAUA5gfYY1IsSTk2PQsagaAinlP9SXi2CTjBhpG95ZuU9Ewj5JxAxNzmjOOjZELyWkGIEZAcWP8vFygAdkFukr3IpaNXMSykeg5CI/bEMgk5X/QkVeCRzMQIia8duE/iwDRFMXAWmPliU6o6uwhs9eT6qZ09dgsVNdT82aOBgAtbKk1m04UgYCZobt27HhLLctm14w8s2RYbkkGG17dIAyAzMhh1zW3tMyb05gCRJO3e0u4V0lidDoTK3e/ufLez9cqVG7PuwpGfwsOcsH+s/mg2pUHAaBq7veffKNLRETSbol5gBKwjE6ntYhI/4F/PXzjpDIAoIo3CyG9lr4FcEBE5GCRJ9R35TsoZwBINd+8fENbBi1dQo5iaCxjXNcVETndvfH3d3wus1BGOaqMVspA4TQthyeDATDu9FbqjHtyPhSxykyP8Tfc/+yeUyIi2nWH9soGxzI6nbnDwO7V919bT1kiJoLCbyTtPdeVrWNAYHzTrwotB5vAAIiVwwBQOev2Fe/1ioiYoXo0FMtoN3PJwKH1S2+9fExmMDu5ma5wh0n7r0jLYjhEFfsCvqkr/x6WNxCUXV0/fPpNi9d/rEVE9CBsRTNRRDKrP/p2bv5o5+4OAHBgRPJlAaVv/ENw1SuZk4DA9AXsjXIXPHkrZa2QaIDA9NmJXWtQP+PK2dc0OQxooMi0ebEERkgRYPbv2rHzncMaABPE+BYZsZ73VEVwQRLTAQiQPjozwOW4t+x5wJOSkCyFtLevR/nsBbNmT68BoIXYG8XlsTSYoKAPtW3btr31GAAwS3HlBISb69ygkknvgoDNkaKkCJvvLT4VMNoGADHM6S1bUFl/+fx5k8aVAzCeCqSnQ/v3vHD/9fWZxkL3fWR+QsuJ4JIZIx0jQFBYKoFBJ2n50aA2mzhbNK79wsJ/7Pdemcd6+6HbWioZAKngur+AKPwlmIbU8hYDcPCTIJY2H1YPadyJM/Glqp57558O5NaXZLCMkesBwEmVUMhlXNUXmD6urAABDm4JArty16CrNzxsynEA4Jnc5Rl/iwyanXKGm9ZnfnUbtW1dYHOBoBUMCHrAvgYM/++vJSRKRLsuOFU5MzfsOdfuBNctPc/yWGAmEvaDAMGJgYC26dHPuEQnRdIVjQEswujSE4uaNmz0reIUdg9CAEHHp75mDO9YWXJWiTBlZO5zHmt86OKPcFHmCb+jRt1tGZyj/pXDgiWnSlUWCNNY/NoCGpzSk1Ka1273rhURnGiDAMI9x73aMvzBmtJ3OxCmIu+25Q6Nqyn1ckCod6nvOw71cmZD52H/eb/rLdn9JYOW/Jc8Vk1d6VgwtHa3Tw37cqr+xKMtrXY8V7y+efBGKxrznZf7a6jWIrMo3LPSd/a+3IdDvvMW9ZbcJAijJuYR8lhlE2wSnoZWdhbGMmFPFheefZ1GbX3eKrnbWCdBLNBEGyxR7U/nx6ewuy/Td4SufCsCLHNLnoYAoblgpAtRdVPpUAA0Huss7JHp+iyDJWjPJwPtpiEAzCh8zDVCaLQq1Ig6uDrXQ4JPjufU8ml3buqR/LbPQlkQzCn0VwGrPlgjOUMr9ETOjTI42MPZpk92ZZ/O8NvP22xoI6meWowFNIwo2p8zlBj+z4v5PtqdP9zTmf/4SNoqZJfLxoRpa/gltrWHx3N1Q9mVGwA0kH0pat60tvQ9jAAY44aJ51u2PakaaYel6fUXM6OLB/ZksYTRkZuTj7hWSSrCJOjiTjSYYNMKAMbjGXWw25bXFg6DAGje+He7rZLiefX40m7jLLE0vbyNDWDQ6jGinRmdm0VpuyGhaaoHxoM10RILnP4jAAj29ecXAOEoGNDqjdfsbBbBOxG9WPW2WIbX7WUD4KDHtB/JeBKPpG3r1RO99/dgNdpWJ4W7l8NAsN/TzLEBiOENL1uuhWBMTZkQbRHGVNvWcjX9+bAjjD0ebbX3ADLwYNi+mqGEMM2rXg9WlY1rk4GgnhXQ3F+IpQV9ndDq9ddsdywLZoRiATWWG6oAgFZ1KnS1FuIAlm6QWWLdjuZxXpaCtkzFKNvGYPjQGsLRo4W3DA+0Qb1su18ZhNomr1IKhELjI1S+aWk3DnntuXyC9MMh+8jOJOObJBwLY+3XoGjevUYO+B7nY7xgabMAMGb6pm4BizAqwtIYweO0y3fkY3dZlNLFXN837+u00SKCzYmhLRtafWk1943NVq5D9rLJ/hHkSQZtt4hg86Loi/63xuXFW8HPKISyHb6sawHLSJela5OcMCZ3+DbeeB+sujESVvCaKJUnNF7qO+Ad8qmmSFjBeRKh5kZodnz/GsGjLYNo2kpADFr8T+M1hLDcZZycCKb4NeLDsvVPkxKS8mmDYgHjYBWTJSgN4/0kni+EusrYy9QiCaGp3G+BfVijLVJvSQqhJeWfvz6s2gRWz0URwhWBI14sqR5zTmnyImWBEe8baOfLcJEe0zwEFjD2XNLkhTC8PgDi/2Yb7ycjhCnBf+PgxxoXe410NGkJ3teLRZhwnrCmBw/4tXVpVezVyBHE8LTgIb+2Kkach6lIMnps0KH1YZnhDecBizFhZHDs/B9R17D2kvkawAAAAABJRU5ErkJggg==</field>
</record>
<!--
A group dedicated to the anonymous user only, making groups
restrictions more convenient.
-->
<record id="group_anonymous" model="res.groups">
<field name="name">Anonymous Group</field>
<field name="users" eval="[(4,ref('anonymous_user'))]"/>
</record>
</data>
</openerp>

View File

@ -0,0 +1,135 @@
# Mongolian translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2011-01-11 11:14+0000\n"
"PO-Revision-Date: 2012-07-16 07:43+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Mongolian <mn@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: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: association
#: field:profile.association.config.install_modules_wizard,wiki:0
msgid "Wiki"
msgstr ""
#. module: association
#: view:profile.association.config.install_modules_wizard:0
msgid "Event Management"
msgstr ""
#. module: association
#: field:profile.association.config.install_modules_wizard,project_gtd:0
msgid "Getting Things Done"
msgstr ""
#. module: association
#: model:ir.module.module,description:association.module_meta_information
msgid "This module is to create Profile for Associates"
msgstr ""
#. module: association
#: field:profile.association.config.install_modules_wizard,progress:0
msgid "Configuration Progress"
msgstr ""
#. module: association
#: view:profile.association.config.install_modules_wizard:0
msgid ""
"Here are specific applications related to the Association Profile you "
"selected."
msgstr ""
#. module: association
#: view:profile.association.config.install_modules_wizard:0
msgid "title"
msgstr ""
#. module: association
#: help:profile.association.config.install_modules_wizard,event_project:0
msgid "Helps you to manage and organize your events."
msgstr ""
#. module: association
#: field:profile.association.config.install_modules_wizard,config_logo:0
msgid "Image"
msgstr ""
#. module: association
#: help:profile.association.config.install_modules_wizard,hr_expense:0
msgid ""
"Tracks and manages employee expenses, and can automatically re-invoice "
"clients if the expenses are project-related."
msgstr ""
#. module: association
#: help:profile.association.config.install_modules_wizard,project_gtd:0
msgid ""
"GTD is a methodology to efficiently organise yourself and your tasks. This "
"module fully integrates GTD principle with OpenERP's project management."
msgstr ""
#. module: association
#: view:profile.association.config.install_modules_wizard:0
msgid "Resources Management"
msgstr "Нөөцийн менежмент"
#. module: association
#: model:ir.module.module,shortdesc:association.module_meta_information
msgid "Association profile"
msgstr ""
#. module: association
#: field:profile.association.config.install_modules_wizard,hr_expense:0
msgid "Expenses Tracking"
msgstr "Зарпал хянах"
#. module: association
#: model:ir.actions.act_window,name:association.action_config_install_module
#: view:profile.association.config.install_modules_wizard:0
msgid "Association Application Configuration"
msgstr ""
#. module: association
#: help:profile.association.config.install_modules_wizard,wiki:0
msgid ""
"Lets you create wiki pages and page groups in order to keep track of "
"business knowledge and share it with and between your employees."
msgstr ""
#. module: association
#: help:profile.association.config.install_modules_wizard,project:0
msgid ""
"Helps you manage your projects and tasks by tracking them, generating "
"plannings, etc..."
msgstr ""
#. module: association
#: model:ir.model,name:association.model_profile_association_config_install_modules_wizard
msgid "profile.association.config.install_modules_wizard"
msgstr ""
#. module: association
#: field:profile.association.config.install_modules_wizard,event_project:0
msgid "Events"
msgstr ""
#. module: association
#: view:profile.association.config.install_modules_wizard:0
#: field:profile.association.config.install_modules_wizard,project:0
msgid "Project Management"
msgstr ""
#. module: association
#: view:profile.association.config.install_modules_wizard:0
msgid "Configure"
msgstr ""

View File

@ -9,8 +9,10 @@
<field name="arch" type="xml">
<notebook colspan="4" position="inside">
<page string="OpenID">
<field name="openid_url"/>
<field name="openid_email"/>
<group>
<field name="openid_url"/>
<field name="openid_email"/>
</group>
</page>
</notebook>
</field>

View File

@ -8,14 +8,14 @@ msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:36+0000\n"
"PO-Revision-Date: 2012-07-13 14:20+0000\n"
"Last-Translator: Magnus Brandt (mba), Aspirix AB <Unknown>\n"
"PO-Revision-Date: 2012-07-16 15:31+0000\n"
"Last-Translator: Anders Wallenquist <anders.wallenquist@vertel.se>\n"
"Language-Team: Swedish <sv@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: 2012-07-14 06:23+0000\n"
"X-Generator: Launchpad (build 15614)\n"
"X-Launchpad-Export-Date: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: base_action_rule
#: help:base.action.rule,act_mail_to_user:0
@ -51,7 +51,7 @@ msgstr "Objekt"
#. module: base_action_rule
#: field:base.action.rule,act_mail_to_email:0
msgid "Mail to these Emails"
msgstr ""
msgstr "Skicka till dessa e-postadresser"
#. module: base_action_rule
#: field:base.action.rule,act_state:0
@ -209,7 +209,7 @@ msgstr "Ogiltiga argument"
#. module: base_action_rule
#: field:base.action.rule,act_user_id:0
msgid "Set Responsible to"
msgstr ""
msgstr "Sätt ansvarig till"
#. module: base_action_rule
#: selection:base.action.rule,trg_date_type:0

View File

@ -12,9 +12,12 @@
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<group string="Company Settings">
<group>
<group>
<group string="Company Settings">
<field name="module_multi_company"/>
<separator string="External Accesses" colspan="2"/>
<field name="module_share"/>
<field name="module_portal"/>
</group>
<group>
<div>
@ -22,16 +25,12 @@
address for the header and footer, overdue payments texts, etc.
</div>
<button type="object" name="open_company" string="Configure Your Company Data" icon="gtk-execute"/>
</group>
</group>
<group string="External Accesses">
<field name="module_share"/>
<field name="module_portal"/>
</group>
<group string="Others">
<label for="id" string="Outgoing Mail Servers"/>
<button type="action" name="%(base.action_ir_mail_server_list)d"
<separator string="Others" colspan="2"/>
<label for="id" string="Outgoing Mail Servers"/>
<button type="action" name="%(base.action_ir_mail_server_list)d"
string="Configure" icon="gtk-execute"/>
</group>
</group>
</form>
</field>
@ -58,13 +57,16 @@
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<field name="module_crm" invisible="1"/>
<group name="config_sale"/>
<group name="config_fetchmail" string="Emails" attrs="{'invisible': [('module_crm','=',False)]}">
<field name="module_plugin_thunderbird"/>
<field name="module_plugin_outlook"/>
</group>
<group name="config_crm"/>
<group>
<group name="config_sale">
<field name="module_crm" invisible="1"/>
<separator string="Emails" colspan="2" attrs="{'invisible': [('module_crm','=',False)]}"/>
<field name="module_plugin_thunderbird" attrs="{'invisible': [('module_crm','=',False)]}"/>
<field name="module_plugin_outlook" attrs="{'invisible': [('module_crm','=',False)]}"/>
</group>
<group name="config_other">
</group>
</group>
</form>
</field>
</record>

View File

@ -140,9 +140,10 @@
name="%(act_crm_opportunity_crm_phonecall_new)d"
string="Phone Calls" />
</div>
<label for="name" class="oe_edit_only" string="Lead Description"/>
<h1><field name="name" placeholder="Describe the lead..."/></h1>
<div class="oe_title">
<label for="name" class="oe_edit_only" string="Lead Description"/>
<h1><field name="name" placeholder="Describe the lead..."/></h1>
</div>
<group>
<group>
<field name="user_id" />

View File

@ -8,29 +8,25 @@
<field name="type">form</field>
<field name="inherit_id" ref="base_setup.view_sale_config_settings"/>
<field name="arch" type="xml">
<group name="config_fetchmail" version="7.0" position="inside">
<separator string="Emails" version="7.0" position="after">
<label for="fetchmail_lead"/>
<div>
<field name="fetchmail_lead"/>
<button name="configure_fetchmail_lead" type="object" string="Configure" icon="gtk-go-forward"
attrs="{'invisible': [('fetchmail_lead','=',False)]}"/>
</div>
</separator>
<group name="config_other" version="7.0" position="inside">
<separator string="Import and Synchronize Data from an Other Application" colspan="2"/>
<field name="module_import_sugarcrm"/>
<field name="module_crm_caldav"/>
<field name="module_import_google"/>
<separator string="Customer Form" colspan="2"/>
<field name="module_google_map"/>
</group>
<group name="config_crm" position="after">
<group string="Import and Synchronize Data from an Other Application">
<field name="module_import_sugarcrm"/>
<field name="module_crm_caldav"/>
<field name="module_import_google"/>
</group>
<group string="Documents and Wiki">
<group name="config_sale" position="inside">
<separator string="Documents and Wiki" colspan="2"/>
<field name="module_wiki_sale_faq"/>
</group>
<group string="Customer Form">
<field name="module_google_map"/>
</group>
</group>
</field>
</record>

View File

@ -123,6 +123,7 @@
<field name="model">res.partner</field>
<field name="type">form</field>
<field name="inherit_id" ref="base.view_partner_form" />
<field name="priority" eval="10"/>
<field name="arch" type="xml">
<xpath expr="//div[@name='buttons']" position="inside">
<button type="action"

View File

@ -9,14 +9,14 @@
<field name="inherit_id" ref="base_setup.view_sale_config_settings"/>
<field name="priority" eval="20"/> <!-- to put fetchmail_lead before fetchmail_claim -->
<field name="arch" type="xml">
<group name="config_fetchmail" version="7.0" position="inside">
<separator string="Emails" version="7.0" position="after">
<label for="fetchmail_claim"/>
<div>
<field name="fetchmail_claim"/>
<button type="object" name="configure_fetchmail_claim" string="Configure" icon="gtk-go-forward"
attrs="{'invisible': [('fetchmail_claim','=',False)]}"/>
</div>
</group>
</separator>
</field>
</record>

View File

@ -0,0 +1,95 @@
# English (United Kingdom) translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:36+0000\n"
"PO-Revision-Date: 2012-07-18 16:31+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: English (United Kingdom) <en_GB@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: 2012-07-19 04:46+0000\n"
"X-Generator: Launchpad (build 15637)\n"
#. module: crm_todo
#: model:ir.model,name:crm_todo.model_project_task
msgid "Task"
msgstr "Task"
#. module: crm_todo
#: view:crm.lead:0
msgid "Timebox"
msgstr "Timebox"
#. module: crm_todo
#: view:crm.lead:0
msgid "For cancelling the task"
msgstr "For cancelling the task"
#. module: crm_todo
#: constraint:project.task:0
msgid "Error ! Task end-date must be greater then task start-date"
msgstr "Error ! Task end-date must be greater then task start-date"
#. module: crm_todo
#: model:ir.model,name:crm_todo.model_crm_lead
msgid "crm.lead"
msgstr "crm.lead"
#. module: crm_todo
#: view:crm.lead:0
msgid "Next"
msgstr "Next"
#. module: crm_todo
#: model:ir.actions.act_window,name:crm_todo.crm_todo_action
#: model:ir.ui.menu,name:crm_todo.menu_crm_todo
msgid "My Tasks"
msgstr "My Tasks"
#. module: crm_todo
#: view:crm.lead:0
#: field:crm.lead,task_ids:0
msgid "Tasks"
msgstr "Tasks"
#. module: crm_todo
#: view:crm.lead:0
msgid "Done"
msgstr "Done"
#. module: crm_todo
#: constraint:project.task:0
msgid "Error ! You cannot create recursive tasks."
msgstr "Error ! You cannot create recursive tasks."
#. module: crm_todo
#: view:crm.lead:0
msgid "Cancel"
msgstr "Cancel"
#. module: crm_todo
#: view:crm.lead:0
msgid "Extra Info"
msgstr "Extra Info"
#. module: crm_todo
#: field:project.task,lead_id:0
msgid "Lead / Opportunity"
msgstr "Lead / Opportunity"
#. module: crm_todo
#: view:crm.lead:0
msgid "For changing to done state"
msgstr "For changing to done state"
#. module: crm_todo
#: view:crm.lead:0
msgid "Previous"
msgstr "Previous"

View File

@ -15,60 +15,82 @@
</tree>
</field>
</record>
<record id="view_delivery_carrier_form" model="ir.ui.view">
<field name="name">delivery.carrier.form</field>
<field name="model">delivery.carrier</field>
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Carrier" version="7.0">
<group col="4" name="general">
<field name="name"/>
<field name="partner_id"/>
<field name="product_id"/>
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1>
<field name="name"/>
</h1>
</div>
<group>
<group name="general">
<field name="partner_id"/>
<field name="product_id"/>
</group>
<group>
<field name="active"/>
<separator string="Pricing Information" colspan="4"/>
<group colspan="4" col="4">
</group>
</group>
<group col="4">
<group string="Pricing Information">
<field name="normal_price" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
<newline/>
<field name="free_if_more_than" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
<field name="amount" attrs="{'required':[('free_if_more_than','&lt;&gt;',False)], 'invisible':[('free_if_more_than','=',False)]}"/>
<label for="free_if_more_than"/>
<div>
<field name="free_if_more_than" attrs="{'readonly':[('use_detailed_pricelist', '=', True)]}"/>
<field name="amount" attrs="{'required':[('free_if_more_than','&lt;&gt;',False)], 'invisible':[('free_if_more_than','=',False)]}"/>
</div>
</group>
<newline/>
<field name="use_detailed_pricelist"/>
</group>
<field name="pricelist_ids" attrs="{'invisible':[('use_detailed_pricelist','=',False)]}" mode="tree,form">
<tree string="Delivery grids">
<field name="pricelist_ids" attrs="{'invisible':[('use_detailed_pricelist','=',False)]}" mode="tree">
<tree string="Delivery grids">
<field name="sequence"/>
<field name="name"/>
</tree>
</tree>
<form string="Delivery grids" version="7.0">
<group col="4">
<field name="name"/>
<field name="active"/>
<field name="sequence"/>
<group>
<group>
<field name="name"/>
</group>
<group>
<field name="active"/>
<field name="sequence"/>
</group>
</group>
<notebook>
<page string="Grid definition">
<field name="line_ids"/>
</page>
<page string="Destination">
<group string="Countries">
<field colspan="2" name="country_ids" nolabel="1"/>
</group>
<group string="States">
<field colspan="2" name="state_ids" nolabel="1"/>
</group>
<group col="4">
<field name="zip_from"/>
<field name="zip_to"/>
</group>
</page>
</notebook>
</form>
<page string="Grid definition">
<field name="line_ids"/>
</page>
<page string="Destination">
<group>
<group>
<field name="country_ids" widget="many2many_tags"/>
<field name="state_ids" widget="many2many_tags"/>
</group>
<group>
<label for="zip_from" string="Zip"/>
<div>
<field name="zip_from" class="oe_inline"/>
-
<field name="zip_to" class="oe_inline"/>
</div>
</group>
</group>
</page>
</notebook>
</form>
</field>
</form>
</field>
</record>
<record id="action_delivery_carrier_form" model="ir.actions.act_window">
<field name="name">Delivery Method</field>
<field name="type">ir.actions.act_window</field>
@ -140,18 +162,28 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Grid Lines" version="7.0">
<field colspan="4" name="name"/>
<div>
<label string="condition" for="type"/>
<field name="type" class="oe_inline"/>
<field name="operator" class="oe_inline"/>
<field name="max_value" class="oe_inline"/>
</div>
<group col="4">
<field name="list_price"/>
<field name="standard_price"/>
<field name="price_type"/>
<field name="variable_factor" attrs="{'invisible':[('price_type','=','fixed')]}"/>
<group>
<field name="name"/>
</group>
<group>
<group>
<label for="type" string="Condition"/>
<div>
<field name="type" class="oe_inline"/>
<field name="operator" class="oe_inline"/>
<field name="max_value" class="oe_inline"/>
</div>
<label for="price_type"/>
<div>
<field name="price_type" class="oe_inline"/>
<label string=" in Function of " class="oe_inline" attrs="{'invisible':[('price_type','=','fixed')]}"/>
<field name="variable_factor" attrs="{'invisible':[('price_type','=','fixed')]}" class="oe_inline"/>
</div>
</group>
<group>
<field name="list_price"/>
<field name="standard_price"/>
</group>
</group>
</form>
</field>
@ -178,7 +210,7 @@
<field name="model">stock.picking.out</field>
<field name="inherit_id" ref="stock.view_picking_form"/>
<field name="arch" type="xml">
<field name="partner_id" position="after">
<field name="min_date" position="after">
<field name="carrier_id"/>
<field name="carrier_tracking_ref"/>
<field name="number_of_packages"/>
@ -230,23 +262,10 @@
<field name="model">stock.move</field>
<field name="inherit_id" ref="stock.view_move_form"/>
<field name="arch" type="xml">
<field name="picking_id" position="after">
<xpath expr="//group[@name='main_grp']" position="inside">
<field name="weight"/>
<field name="weight_net"/>
</field>
</field>
</record>
<record id="view_move_reception_picking_withweight_form" model="ir.ui.view">
<field name="name">stock.move.reception.packing.form.weight</field>
<field name="type">form</field>
<field name="model">stock.move</field>
<field name="inherit_id" ref="stock.view_move_form_reception_picking"/>
<field name="arch" type="xml">
<field name="picking_id">
<field name="weight"/>
<field name="weight_net"/>
</field>
</xpath>
</field>
</record>
@ -264,7 +283,7 @@
<button name="delivery_set" string="Add in Quote" type="object"
class="oe_edit_only"
attrs="{'invisible':['|',('carrier_id','=',False),('state','not in',('draft','sent'))]}"/>
<br/>
<br/>
<label string="If you don't 'Add in Quote', the exact price will be computed when invoicing based on delivery order(s)."
class="oe_edit_only"
attrs="{'invisible':['|',('carrier_id','=',False),('state','not in',('draft','sent'))]}"/>

View File

@ -368,7 +368,7 @@
<field name="priority" eval="1"/>
<field name="arch" type="xml">
<field name="subflow_id" position="after">
<field name="directory_id" domain="[('ressource_type_id','=',model_id),('ressource_parent_type_id','=',False)]"/>
<field name="directory_id" string="Document Directory" domain="[('ressource_type_id','=',model_id),('ressource_parent_type_id','=',False)]"/>
<newline/>
</field>
</field>

View File

@ -17,20 +17,13 @@
<notebook>
<page string="Email Details">
<group>
<group string="Addresses">
<field name="email_from" required="1"/>
<field name="email_to" required="1"/>
<field name="email_cc"/>
<field name="email_bcc"/>
<field name="reply_to"/>
</group>
<group string="Options">
<field name="lang"/>
<field name="user_signature"/>
</group>
<group string="Email Content">
<field name="subject" required="1"/>
<notebook colspan="2">
<notebook colspan="4">
<page string="Body (Text)">
<field name="body_text" colspan="4" width="250" height="250" nolabel="1"/>
</page>
@ -39,22 +32,21 @@
<label string="Note: This is Raw HTML." colspan="4"/>
</page>
</notebook>
</group>
<field name="user_signature"/>
<notebook colspan="4">
<page string="Dynamic Values Builder">
<field name="model_object_field"
domain="[('model_id','=',model_id),('ttype','!=','one2many'),('ttype','!=','many2many')]"
on_change="onchange_sub_model_object_value_field(model_object_field)"
colspan="4"/>
<field name="sub_object" readonly="1" colspan="4"/>
<field name="sub_model_object_field"
domain="[('model_id','=',sub_object),('ttype','!=','one2many'),('ttype','!=','many2many')]"
colspan="4"
attrs="{'readonly':[('sub_object','=',False)],'required':[('sub_object','!=',False)]}"
on_change="onchange_sub_model_object_value_field(model_object_field,sub_model_object_field)"/>
<field name="null_value" colspan="4"
on_change="onchange_sub_model_object_value_field(model_object_field,sub_model_object_field,null_value)" />
<field name="copyvalue" colspan="4"/>
<group>
<field name="model_object_field"
domain="[('model_id','=',model_id),('ttype','!=','one2many'),('ttype','!=','many2many')]"
on_change="onchange_sub_model_object_value_field(model_object_field)"/>
<field name="sub_object" readonly="1"/>
<field name="sub_model_object_field"
domain="[('model_id','=',sub_object),('ttype','!=','one2many'),('ttype','!=','many2many')]"
attrs="{'readonly':[('sub_object','=',False)],'required':[('sub_object','!=',False)]}"
on_change="onchange_sub_model_object_value_field(model_object_field,sub_model_object_field)"/>
<field name="null_value" on_change="onchange_sub_model_object_value_field(model_object_field,sub_model_object_field,null_value)"/>
<field name="copyvalue"/>
</group>
</page>
</notebook>
<button name="%(wizard_email_template_preview)d" string="Preview Template"
@ -82,15 +74,18 @@
<field name="track_campaign_item"/>
<field name="message_id"/>
<field name="auto_delete"/>
<field name="lang"/>
</group>
</group>
<group colspan="2" col="2">
<separator string="Attachments" colspan="2"/>
<notebook colspan="2">
<page string="Attach Report">
<field name="report_template" colspan="4"
domain="[('model','=',model)]"/>
<field name="report_name" colspan="4" />
<group>
<field name="report_template" colspan="4"
domain="[('model','=',model)]"/>
<field name="report_name" colspan="4" />
</group>
</page>
<page string="Attach existing files">
<field name="attachment_ids" colspan="4" nolabel="1" height="350"/>

1263
addons/event/i18n/mn.po Normal file

File diff suppressed because it is too large Load Diff

View File

@ -9,9 +9,10 @@
<field name="arch" type="xml">
<xpath expr="//notebook" position="inside">
<page string="Synchronization">
<separator string="Google Account" colspan="4"/>
<field name="gmail_user"/>
<field name="gmail_password" password="True"/>
<group string="Google Account" colspan="4">
<field name="gmail_user"/>
<field name="gmail_password" password="True"/>
</group>
</page>
</xpath>
</field>

View File

@ -250,13 +250,13 @@ class hr_employee(osv.osv):
work_email = self.pool.get('res.users').browse(cr, uid, user_id, context=context).user_email
return {'value': {'work_email' : work_email}}
def _get_photo(self, cr, uid, context=None):
def _default_get_photo(self, cr, uid, context=None):
photo_path = addons.get_module_resource('hr','images','photo.png')
return self._photo_resize(cr, uid, open(photo_path, 'rb').read().encode('base64'), context=context)
_defaults = {
'active': 1,
'photo': _get_photo,
'photo': _default_get_photo,
'marital': 'single',
'color': 0,
}

View File

@ -21,9 +21,6 @@
<form string="Employee" version="7.0">
<sheet>
<field name="photo" widget='image' class="oe_right" on_change="onchange_photo(photo)"/>
<div class="oe_right oe_button_box" name="button_box">
<!-- Put here related buttons -->
</div>
<div class="oe_title">
<label for="name" class="oe_edit_only"/>
<h1>
@ -38,6 +35,9 @@
<label for="category_ids" class="oe_edit_only"/>
<h3><field name="category_ids" widget="many2many_tags"/></h3>
</div>
<div class="oe_right oe_button_box" name="button_box">
<!-- Put here related buttons -->
</div>
<group colspan="4" col="4">
<field name="work_email" widget="email" />
<field name="work_phone"/>

View File

@ -20,13 +20,11 @@
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<group string="Additional Features">
<group>
<group>
<group string="Additional Features" name="left_column">
<field name="module_hr_expense"/>
<field name="module_hr_evaluation"/>
<field name="module_hr_holidays"/>
</group>
<group>
<field name="module_hr_recruitment"/>
<field name="module_hr_contract"/>
<label for="module_hr_payroll"/>
@ -37,14 +35,11 @@
attrs="{'invisible': [('module_hr_payroll','=',False)]}"/>
</div>
</group>
</group>
<group>
<group string="Timesheets">
<group string="Timesheets" name="right_column">
<field name="module_hr_attendance" on_change="onchange_hr_attendance(module_hr_attendance)"/>
<field name="module_hr_timesheet" on_change="onchange_hr_timesheet(module_hr_timesheet)"/>
<field name="module_hr_timesheet_sheet"/>
</group>
<group name="config_recruitment"/>
</group>
</form>
</field>

View File

@ -7,14 +7,14 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.14\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2012-02-08 00:36+0000\n"
"PO-Revision-Date: 2012-05-10 17:58+0000\n"
"Last-Translator: Raphael Collet (OpenERP) <Unknown>\n"
"PO-Revision-Date: 2012-07-16 15:25+0000\n"
"Last-Translator: Anders Wallenquist <anders.wallenquist@vertel.se>\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: 2012-07-14 06:10+0000\n"
"X-Generator: Launchpad (build 15614)\n"
"X-Launchpad-Export-Date: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: hr_attendance
#: model:ir.ui.menu,name:hr_attendance.menu_hr_time_tracking
@ -225,7 +225,7 @@ msgstr "Startdatum"
#. module: hr_attendance
#: report:report.hr.timesheet.attendance.error:0
msgid "Min Delay"
msgstr "Min Delay"
msgstr "Minsta fördröjning"
#. module: hr_attendance
#: selection:hr.attendance,action:0

View File

@ -8,7 +8,7 @@
<field name="inherit_id" ref="hr.view_human_resources_configuration"/>
<field name="arch" type="xml">
<!-- put after the element <div><field name="module_hr_payroll" class="oe_inline"/> ...</div> -->
<xpath expr="//field[@name='module_hr_payroll']/.." position="after">
<xpath expr="//group[@name='left_column']" position="inside">
<field name="module_hr_payroll_account"/>
</xpath>
</field>

View File

@ -7,16 +7,15 @@
<field name="type">form</field>
<field name="inherit_id" ref="hr.view_human_resources_configuration"/>
<field name="arch" type="xml">
<group name="config_recruitment" position="replace">
<group name="config_recruitment" string="Recruitment">
<field name="module_document_ftp"/>
<label for="fetchmail_applicants"/>
<div>
<field name="fetchmail_applicants"/>
<button name="configure_fetchmail_applicants" type="object" string="Configure" icon="gtk-go-forward"
attrs="{'invisible': [('fetchmail_applicants','=',False)]}"/>
</div>
</group>
<group name="right_column" position="inside">
<separator string="Recruitment" colspan="2"/>
<field name="module_document_ftp"/>
<label for="fetchmail_applicants"/>
<div>
<field name="fetchmail_applicants"/>
<button name="configure_fetchmail_applicants" type="object" string="Configure" icon="gtk-go-forward"
attrs="{'invisible': [('fetchmail_applicants','=',False)]}"/>
</div>
</group>
</field>
</record>

View File

@ -200,12 +200,12 @@
<field name="type">form</field>
<field name="inherit_id" ref="base.view_company_form"/>
<field name="arch" type="xml">
<page string="Configuration" position="inside">
<separator string="Timesheets" colspan="4"/>
<field name="timesheet_range"/>
<field name="timesheet_max_difference"/>
<newline/>
</page>
<xpath expr="//group[@name='account_grp']" position="after">
<group name="timesheets_grp" string="Timesheets">
<field name="timesheet_range"/>
<field name="timesheet_max_difference"/>
</group>
</xpath>
</field>
</record>

View File

@ -7,14 +7,14 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.14\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2012-02-08 01:37+0100\n"
"PO-Revision-Date: 2010-11-22 21:07+0000\n"
"Last-Translator: Olivier Dony (OpenERP) <Unknown>\n"
"PO-Revision-Date: 2012-07-16 15:49+0000\n"
"Last-Translator: Anders Wallenquist <anders.wallenquist@vertel.se>\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: 2012-07-14 06:05+0000\n"
"X-Generator: Launchpad (build 15614)\n"
"X-Launchpad-Export-Date: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: hr_timesheet_sheet
#: field:hr.analytic.timesheet,sheet_id:0 field:hr.attendance,sheet_id:0
@ -66,7 +66,7 @@ msgstr ""
#. module: hr_timesheet_sheet
#: view:hr_timesheet_sheet.sheet:0
msgid "Today"
msgstr "Today"
msgstr "Idag"
#. module: hr_timesheet_sheet
#: code:addons/hr_timesheet_sheet/hr_timesheet_sheet.py:274
@ -74,7 +74,8 @@ msgstr "Today"
msgid ""
"Please verify that the total difference of the sheet is lower than %.2f !"
msgstr ""
"Please verify that the total difference of the sheet is lower than %.2f !"
"Vänligen kontrollera att den totala skillnaden mellan rapporterna är mindre "
"än %.2f!"
#. module: hr_timesheet_sheet
#: selection:hr.timesheet.report,month:0 selection:timesheet.report,month:0
@ -89,7 +90,7 @@ msgstr "# Kostnad"
#. module: hr_timesheet_sheet
#: view:hr.timesheet.report:0 view:timesheet.report:0
msgid "Timesheet of last month"
msgstr ""
msgstr "Tidrapport från förra månaden"
#. module: hr_timesheet_sheet
#: view:hr.timesheet.report:0 field:hr.timesheet.report,company_id:0

View File

@ -0,0 +1,217 @@
# Brazilian Portuguese translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-08 00:36+0000\n"
"PO-Revision-Date: 2012-07-16 20:10+0000\n"
"Last-Translator: Rafael <Unknown>\n"
"Language-Team: Brazilian Portuguese <pt_BR@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: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: import_google
#: help:synchronize.google.import,group_name:0
msgid "Choose which group to import, By default it takes all."
msgstr ""
#. module: import_google
#: view:synchronize.google.import:0
msgid "Import Google Calendar Events"
msgstr "Importar o Calendário de Eventos da Google"
#. module: import_google
#: view:synchronize.google.import:0
msgid "_Import Events"
msgstr ""
#. module: import_google
#: code:addons/import_google/wizard/import_google_data.py:71
#, python-format
msgid ""
"No Google Username or password Defined for user.\n"
"Please define in user view"
msgstr ""
#. module: import_google
#: code:addons/import_google/wizard/import_google_data.py:127
#, python-format
msgid ""
"Invalid login detail !\n"
" Specify Username/Password."
msgstr ""
#. module: import_google
#: field:synchronize.google.import,supplier:0
msgid "Supplier"
msgstr "Fornecedor"
#. module: import_google
#: view:synchronize.google.import:0
msgid "Import Options"
msgstr "Opções de importação"
#. module: import_google
#: field:synchronize.google.import,group_name:0
msgid "Group Name"
msgstr "Nome do Grupo"
#. module: import_google
#: model:ir.model,name:import_google.model_crm_case_categ
msgid "Category of Case"
msgstr ""
#. module: import_google
#: model:ir.actions.act_window,name:import_google.act_google_login_contact_form
#: model:ir.ui.menu,name:import_google.menu_sync_contact
msgid "Import Google Contacts"
msgstr "Importar Contatos do Google"
#. module: import_google
#: view:google.import.message:0
msgid "Import Google Data"
msgstr ""
#. module: import_google
#: view:crm.meeting:0
msgid "Meeting Type"
msgstr ""
#. module: import_google
#: code:addons/import_google/wizard/import_google.py:38
#: code:addons/import_google/wizard/import_google_data.py:28
#, python-format
msgid ""
"Please install gdata-python-client from http://code.google.com/p/gdata-"
"python-client/downloads/list"
msgstr ""
#. module: import_google
#: model:ir.model,name:import_google.model_google_login
msgid "Google Contact"
msgstr ""
#. module: import_google
#: view:synchronize.google.import:0
msgid "Import contacts from a google account"
msgstr ""
#. module: import_google
#: code:addons/import_google/wizard/import_google_data.py:133
#, python-format
msgid "Please specify correct user and password !"
msgstr ""
#. module: import_google
#: field:synchronize.google.import,customer:0
msgid "Customer"
msgstr "Cliente"
#. module: import_google
#: view:synchronize.google.import:0
msgid "_Cancel"
msgstr ""
#. module: import_google
#: model:ir.model,name:import_google.model_synchronize_google_import
msgid "synchronize.google.import"
msgstr "sincronizar.importação.google"
#. module: import_google
#: view:synchronize.google.import:0
msgid "_Import Contacts"
msgstr ""
#. module: import_google
#: model:ir.actions.act_window,name:import_google.act_google_login_form
#: model:ir.ui.menu,name:import_google.menu_sync_calendar
msgid "Import Google Calendar"
msgstr "Importar Calendário do Google"
#. module: import_google
#: code:addons/import_google/wizard/import_google_data.py:50
#, python-format
msgid "Import google"
msgstr ""
#. module: import_google
#: code:addons/import_google/wizard/import_google_data.py:127
#: code:addons/import_google/wizard/import_google_data.py:133
#, python-format
msgid "Error"
msgstr "Erro"
#. module: import_google
#: code:addons/import_google/wizard/import_google_data.py:71
#, python-format
msgid "Warning !"
msgstr "Aviso !"
#. module: import_google
#: field:synchronize.google.import,create_partner:0
msgid "Options"
msgstr "Opções"
#. module: import_google
#: view:google.import.message:0
msgid "_Ok"
msgstr "_Ok"
#. module: import_google
#: code:addons/import_google/wizard/import_google.py:38
#: code:addons/import_google/wizard/import_google_data.py:28
#, python-format
msgid "Google Contacts Import Error!"
msgstr ""
#. module: import_google
#: model:ir.model,name:import_google.model_google_import_message
msgid "Import Message"
msgstr ""
#. module: import_google
#: field:synchronize.google.import,calendar_name:0
msgid "Calendar Name"
msgstr "Nome do Calendário"
#. module: import_google
#: help:synchronize.google.import,supplier:0
msgid "Check this box to set newly created partner as Supplier."
msgstr ""
#. module: import_google
#: selection:synchronize.google.import,create_partner:0
msgid "Import only address"
msgstr ""
#. module: import_google
#: field:crm.case.categ,user_id:0
msgid "User"
msgstr "Usuário"
#. module: import_google
#: view:synchronize.google.import:0
msgid "Partner Status for this Group:"
msgstr ""
#. module: import_google
#: field:google.import.message,name:0
msgid "Message"
msgstr "Mensagem"
#. module: import_google
#: selection:synchronize.google.import,create_partner:0
msgid "Create partner for each contact"
msgstr ""
#. module: import_google
#: help:synchronize.google.import,customer:0
msgid "Check this box to set newly created partner as Customer."
msgstr ""

View File

@ -11,7 +11,6 @@
<button string="Apply" type="object" name="execute" class="oe_highlight"/>
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<group>
<group string="Wiki">

View File

@ -12,7 +12,7 @@
<field name="payment_term" position="after">
<group col="4" colspan="2">
<field name="reference_type" nolabel="1" size="0" attrs="{'readonly':[('state','!=','draft')]}"
on_change="generate_bbacomm(type,reference_type,algorithm,partner_id,reference)" colspan="1"/>
on_change="generate_bbacomm(type,reference_type, partner_id,reference, context)" colspan="1"/>
<field name="reference" nolabel="1" colspan="3" attrs="{'readonly':[('state','!=','draft')]}"/>
</group>
</field>

View File

@ -44,7 +44,7 @@ class account_invoice(osv.osv):
#l_logger.warning('reference_type = %s' %res )
return res
def check_bbacomm(self, val):
def check_bbacomm(self, val):
supported_chars = '0-9+*/ '
pattern = re.compile('[^' + supported_chars + ']')
if pattern.findall(val or ''):
@ -75,10 +75,7 @@ class account_invoice(osv.osv):
if (type == 'out_invoice'):
reference_type = self.pool.get('res.partner').browse(cr, uid, partner_id).out_inv_comm_type
if reference_type:
algorithm = self.pool.get('res.partner').browse(cr, uid, partner_id).out_inv_comm_algorithm
if not algorithm:
algorithm = 'random'
reference = self.generate_bbacomm(cr, uid, ids, type, reference_type, algorithm, partner_id, '')['value']['reference']
reference = self.generate_bbacomm(cr, uid, ids, type, reference_type, partner_id, '', context={})['value']['reference']
res_update = {
'reference_type': reference_type or 'none',
'reference': reference,
@ -86,17 +83,15 @@ class account_invoice(osv.osv):
result['value'].update(res_update)
return result
def generate_bbacomm(self, cr, uid, ids, type, reference_type, algorithm, partner_id, reference):
def generate_bbacomm(self, cr, uid, ids, type, reference_type, partner_id, reference, context=None):
partner_obj = self.pool.get('res.partner')
reference = reference or ''
reference = reference or ''
algorithm = False
if partner_id:
algorithm = partner_obj.browse(cr, uid, partner_id, context=context).out_inv_comm_algorithm
algorithm = algorithm or 'random'
if (type == 'out_invoice'):
if reference_type == 'bba':
if not algorithm:
if partner_id:
algorithm = partner_obj.browse(cr, uid, partner_id).out_inv_comm_algorithm
if not algorithm:
if not algorithm:
algorithm = 'random'
if algorithm == 'date':
if not self.check_bbacomm(reference):
doy = time.strftime('%j')

View File

@ -7,22 +7,22 @@
<field name="type">form</field>
<field name="inherit_id" ref="base.view_company_form"/>
<field name="arch" type="xml">
<field name="rml_footer2" position="after">
<newline/>
<group string="BVR data" colspan="4">
<field name="bvr_delta_horz"/>
<field name="bvr_delta_vert"/>
<field name="bvr_scan_line_vert"/>
<field name="bvr_scan_line_horz"/>
<field name="bvr_scan_line_font_size"/>
<field name="bvr_scan_line_letter_spacing"/>
<field name="bvr_background"/>
<field name="bvr_only"/>
<field name="invoice_only"/>
</group>
<newline/>
</field>
<xpath expr="//notebook" position="inside">
<page string="BVR Data">
<group colspan="4">
<field name="bvr_delta_horz"/>
<field name="bvr_delta_vert"/>
<field name="bvr_scan_line_vert"/>
<field name="bvr_scan_line_horz"/>
<field name="bvr_scan_line_font_size"/>
<field name="bvr_scan_line_letter_spacing"/>
<field name="bvr_background"/>
<field name="bvr_only"/>
<field name="invoice_only"/>
</group>
</page>
</xpath>
</field>
</record>
</data>
</openerp>
</openerp>

View File

@ -30,15 +30,15 @@
<field name="target">new</field>
</record>
<record model="ir.ui.view" id="view_bank_statement_form">
<record model="ir.ui.view" id="view_bank_statement_form_bvr">
<field name="name">account.bank.statement.form.inherit</field>
<field name="model">account.bank.statement</field>
<field name="type">form</field>
<field name="inherit_id" ref="account.view_bank_statement_form"/>
<field name="arch" type="xml">
<field name="balance_end_real" position="after">
<button name="%(wizard_bvr_import)d" icon="gtk-execute" string="Import BVR" type="action" colspan="2"/>
</field>
<xpath expr="//div[@name='import_buttons']" position="inside">
<button name="%(wizard_bvr_import)d" icon="gtk-execute" string="Import BVR" type="action"/>
</xpath>
</field>
</record>
</data>

View File

@ -11,15 +11,15 @@
<field name="inherit_id" ref="base.view_company_form"/>
<field name="arch" type="xml">
<data>
<xpath expr="//notebook" position="inside">
<page string="Paie">
<xpath expr="//group[@name='account_grp']" position="after">
<group string="Paie">
<field name="plafond_secu"/>
<field name="nombre_employes"/>
<newline/>
<field name="org_ss"/>
<newline/>
<field name="conv_coll"/>
</page>
</group>
</xpath>
</data>
</field>

View File

@ -9,7 +9,7 @@
<field name="inherit_id" ref="base.view_users_form_simple_modif"/>
<field name="arch" type="xml">
<data>
<field name="context_tz" position="after">
<field name="user_email" position="before">
<field name="notification_email_pref" readonly="0"/>
</field>
</data>
@ -23,7 +23,7 @@
<field name="inherit_id" ref="base.view_users_form"/>
<field name="arch" type="xml">
<data>
<field name="context_tz" position="after">
<field name="user_email" position="before">
<field name="notification_email_pref"/>
</field>
<xpath expr="/form/sheet" position="after">

View File

@ -7,14 +7,14 @@ msgstr ""
"Project-Id-Version: OpenERP Server 6.0dev\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2012-02-08 00:36+0000\n"
"PO-Revision-Date: 2011-07-18 17:46+0000\n"
"Last-Translator: Fernando Casseano <Unknown>\n"
"PO-Revision-Date: 2012-07-16 19:47+0000\n"
"Last-Translator: Rafael <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: 2012-07-14 05:44+0000\n"
"X-Generator: Launchpad (build 15614)\n"
"X-Launchpad-Export-Date: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: membership
#: model:process.transition,name:membership.process_transition_invoicetoassociate0
@ -37,27 +37,27 @@ msgstr "Estado pago"
#: view:report.membership:0
#: view:res.partner:0
msgid "Group By..."
msgstr ""
msgstr "Agrupar Por..."
#. module: membership
#: field:report.membership,num_paid:0
msgid "# Paid"
msgstr ""
msgstr "# Pago"
#. module: membership
#: field:report.membership,tot_earned:0
msgid "Earned Amount"
msgstr ""
msgstr "Valor Agregado"
#. module: membership
#: model:ir.model,name:membership.model_report_membership
msgid "Membership Analysis"
msgstr ""
msgstr "Análises de Composição"
#. module: membership
#: selection:report.membership,month:0
msgid "March"
msgstr ""
msgstr "Março"
#. module: membership
#: model:process.node,note:membership.process_node_setassociation0
@ -74,12 +74,12 @@ msgstr "Fatura a ser paga"
#: view:report.membership:0
#: field:report.membership,company_id:0
msgid "Company"
msgstr ""
msgstr "Empresa"
#. module: membership
#: view:res.partner:0
msgid "Ending Date Of Membership"
msgstr ""
msgstr "Data Final de Composição"
#. module: membership
#: field:product.product,membership_date_to:0
@ -94,12 +94,12 @@ msgstr "Esperando pela fatura"
#. module: membership
#: view:report.membership:0
msgid "This will display paid, old and total earned columns"
msgstr ""
msgstr "Isto irá exibir colunas pago, antigo e total recebido"
#. module: membership
#: view:res.partner:0
msgid "Suppliers"
msgstr ""
msgstr "Fornecedores"
#. module: membership
#: selection:membership.membership_line,state:0
@ -111,12 +111,12 @@ msgstr "Não Membros"
#. module: membership
#: model:product.template,name:membership.membership_2_product_template
msgid "Basic Membership"
msgstr ""
msgstr "Composição Básica"
#. module: membership
#: view:res.partner:0
msgid "All Members"
msgstr ""
msgstr "Todos Membros"
#. module: membership
#: field:res.partner,membership_stop:0
@ -131,7 +131,7 @@ msgstr "Produto para membro"
#. module: membership
#: view:res.partner:0
msgid "Join Membership"
msgstr ""
msgstr "Inscrever-se como membro"
#. module: membership
#: field:res.partner,associate_member:0
@ -146,12 +146,12 @@ msgstr "Membro está associado."
#. module: membership
#: view:report.membership:0
msgid " Month "
msgstr ""
msgstr " Mês "
#. module: membership
#: field:report.membership,tot_pending:0
msgid "Pending Amount"
msgstr ""
msgstr "Valor Pendente"
#. module: membership
#: model:process.transition,note:membership.process_transition_associationpartner0
@ -161,28 +161,28 @@ msgstr "Parceiro associado."
#. module: membership
#: view:res.partner:0
msgid "Supplier Partners"
msgstr ""
msgstr "Parceiros do fornecedor"
#. module: membership
#: field:report.membership,num_invoiced:0
msgid "# Invoiced"
msgstr ""
msgstr "# Faturado"
#. module: membership
#: constraint:account.invoice:0
msgid "Invalid BBA Structured Communication !"
msgstr ""
msgstr "Comunicação estruturada BBA inválida !"
#. module: membership
#: model:ir.actions.act_window,name:membership.action_report_membership_tree
#: model:ir.ui.menu,name:membership.menu_report_membership
msgid "Members Analysis"
msgstr ""
msgstr "Análise dos Membros"
#. module: membership
#: view:res.partner:0
msgid "End Membership Date"
msgstr ""
msgstr "Finalizar Data do Grupo"
#. module: membership
#: field:product.product,membership_date_from:0
@ -193,7 +193,7 @@ msgstr "Data de"
#: code:addons/membership/membership.py:414
#, python-format
msgid "Partner doesn't have an address to make the invoice."
msgstr ""
msgstr "Parceiro não possui um endereço para realizar a fatura."
#. module: membership
#: model:ir.model,name:membership.model_res_partner
@ -209,7 +209,7 @@ msgstr "Fatura a pagar"
#. module: membership
#: view:res.partner:0
msgid "Customer Partners"
msgstr ""
msgstr "Parceiros do Cliente"
#. module: membership
#: view:res.partner:0
@ -219,7 +219,7 @@ msgstr "Parceiros"
#. module: membership
#: field:membership.membership_line,date_from:0
msgid "From"
msgstr "A partir de"
msgstr "De"
#. module: membership
#: constraint:membership.membership_line:0
@ -243,6 +243,18 @@ msgid ""
" -Paid Member: A member who has paid the membership "
"amount."
msgstr ""
"Isto indica o estado do grupo.\n"
" -Não Membro: Um membro que não foi vinculado a nenhum "
"grupo.\n"
" -Membro Cancelado: Um membro que foi cancelado de seu "
"grupo.\n"
" -Membro Antigo: Um membro cujo data do grupo foi "
"expirada.\n"
" -Membro em Espera: Um membro que foi vinculado a um "
"grupo e cuja fatura está sendo criada.\n"
" -Membro Faturado: Um membro cujo fatura já foi criada.\n"
" -Membro Pago: Um membro que tenha pago uma quantia de "
"associação."
#. module: membership
#: model:process.transition.action,name:membership.process_transition_action_create0
@ -268,12 +280,12 @@ msgstr "Data de início da associação"
#. module: membership
#: view:report.membership:0
msgid "Events created in current month"
msgstr ""
msgstr "Eventos criados no mês atual."
#. module: membership
#: view:report.membership:0
msgid "This will display waiting, invoiced and total pending columns"
msgstr ""
msgstr "Isto irá exibir colunas aguardando, faturados e total pendente."
#. module: membership
#: code:addons/membership/membership.py:410
@ -290,22 +302,22 @@ msgstr "Membro Pago"
#. module: membership
#: view:report.membership:0
msgid " Month-1 "
msgstr ""
msgstr " Mês-1 "
#. module: membership
#: view:report.membership:0
msgid "Events created in last month"
msgstr ""
msgstr "Eventos criados no ultimo mês"
#. module: membership
#: field:report.membership,num_waiting:0
msgid "# Waiting"
msgstr ""
msgstr "# Aguardando"
#. module: membership
#: view:report.membership:0
msgid "Events created in current year"
msgstr ""
msgstr "Eventos criados no ano atual"
#. module: membership
#: model:ir.actions.act_window,name:membership.action_membership_members
@ -317,22 +329,22 @@ msgstr "Membros"
#. module: membership
#: view:res.partner:0
msgid "Invoiced/Paid/Free"
msgstr ""
msgstr "Faturado/Pago/Livre"
#. module: membership
#: model:process.node,note:membership.process_node_invoicedmember0
msgid "Open invoice."
msgstr "Abrir Fatura"
msgstr "Abrir Fatura."
#. module: membership
#: selection:report.membership,month:0
msgid "July"
msgstr ""
msgstr "Julho"
#. module: membership
#: model:product.template,name:membership.membership_0_product_template
msgid "Golden Membership"
msgstr ""
msgstr "Membro Golden"
#. module: membership
#: help:res.partner,associate_member:0
@ -340,49 +352,51 @@ msgid ""
"A member with whom you want to associate your membership.It will consider "
"the membership state of the associated member."
msgstr ""
"Um membro com que você queira associar seu grupo. Isso vai considerar o "
"estado do grupo do membro associado."
#. module: membership
#: field:membership.membership_line,membership_id:0
#: view:report.membership:0
#: field:report.membership,membership_id:0
msgid "Membership Product"
msgstr ""
msgstr "Produtos do Grupo de Membros"
#. module: membership
#: model:process.transition,note:membership.process_transition_producttomember0
msgid "Define product for membership."
msgstr "Defina o produto para a adesão."
msgstr "Definir produto para grupo de membros."
#. module: membership
#: model:process.transition,note:membership.process_transition_invoicetoassociate0
msgid "Invoiced member may be Associated member."
msgstr "Membro faturado pode ser membro Associado."
msgstr "Membro faturado pode ser um membro associado."
#. module: membership
#: view:membership.invoice:0
msgid "Join"
msgstr ""
msgstr "Entrar"
#. module: membership
#: help:product.product,membership_date_to:0
#: help:res.partner,membership_stop:0
msgid "Date until which membership remains active."
msgstr ""
msgstr "Data de até quando o grupo de membros permanece ativo."
#. module: membership
#: field:res.partner,membership_cancel:0
msgid "Cancel membership date"
msgstr "Data de cancelamento de adesão"
msgstr "Cancelar data do grupo de mebros."
#. module: membership
#: field:membership.membership_line,date:0
msgid "Join Date"
msgstr ""
msgstr "Data de Entrada"
#. module: membership
#: help:res.partner,free_member:0
msgid "Select if you want to give membership free of cost."
msgstr ""
msgstr "Selecione se você quiser deixar o grupo de membros livre de custo."
#. module: membership
#: model:process.node,name:membership.process_node_setassociation0
@ -392,37 +406,37 @@ msgstr "Definir associação"
#. module: membership
#: view:res.partner:0
msgid " Membership State"
msgstr ""
msgstr " Estado do grupo de membros"
#. module: membership
#: view:res.partner:0
msgid "Memberships"
msgstr ""
msgstr "Grupo de Membros"
#. module: membership
#: model:process.node,note:membership.process_node_paidmember0
msgid "Membership invoice paid."
msgstr "Fatura de associação paga"
msgstr "Fatura do grupo paga."
#. module: membership
#: model:ir.model,name:membership.model_product_template
msgid "Product Template"
msgstr ""
msgstr "Modelo de Produto"
#. module: membership
#: selection:report.membership,month:0
msgid "September"
msgstr ""
msgstr "Setembro"
#. module: membership
#: selection:report.membership,month:0
msgid "December"
msgstr ""
msgstr "Dezembro"
#. module: membership
#: model:ir.model,name:membership.model_account_invoice_line
msgid "Invoice Line"
msgstr ""
msgstr "Linha de Fatura"
#. module: membership
#: help:membership.membership_line,state:0
@ -441,58 +455,70 @@ msgid ""
" -Paid Member: A member who has paid the membership "
"amount."
msgstr ""
"Isto indica o estado do grupo.\n"
" -Não Membro: Um membro que não foi vinculado a nenhum "
"grupo.\n"
" -Membro Cancelado: Um membro que foi cancelado de seu "
"grupo.\n"
" -Membro Antigo: Um membro cujo data do grupo foi "
"expirada.\n"
" -Membro em Espera: Um membro que foi vinculado a um "
"grupo e cuja fatura está sendo criada.\n"
" -Membro Faturado: Um membro cujo fatura já foi criada.\n"
" -Membro Pago: Um membro que tenha pago uma quantia de "
"associação."
#. module: membership
#: view:report.membership:0
#: field:report.membership,month:0
msgid "Month"
msgstr ""
msgstr "Mês"
#. module: membership
#: view:product.product:0
msgid "Group by..."
msgstr ""
msgstr "Agrupar por..."
#. module: membership
#: code:addons/membership/membership.py:411
#, python-format
msgid "Partner is a free Member."
msgstr ""
msgstr "Parceiro é um membro livre."
#. module: membership
#: model:product.pricelist,name:membership.list1m
msgid "Member Sale Pricelist"
msgstr "Lista de preços para venda a membro"
msgstr "Lista de preço de venda do membro"
#. module: membership
#: field:report.membership,associate_member_id:0
#: view:res.partner:0
msgid "Associate Member"
msgstr ""
msgstr "Associar Membro"
#. module: membership
#: help:product.product,membership_date_from:0
#: help:res.partner,membership_start:0
msgid "Date from which membership becomes active."
msgstr ""
msgstr "Data que o grupo de membros se tornou ativo."
#. module: membership
#: view:report.membership:0
msgid "Associated Partner"
msgstr ""
msgstr "Parceiro Associado"
#. module: membership
#: model:ir.model,name:membership.model_membership_invoice
#: view:membership.invoice:0
msgid "Membership Invoice"
msgstr ""
msgstr "Fatura do grupo de membros"
#. module: membership
#: view:report.membership:0
#: field:report.membership,user_id:0
#: view:res.partner:0
msgid "Salesman"
msgstr ""
msgstr "Vendedor"
#. module: membership
#: model:process.node,note:membership.process_node_membershipproduct0
@ -502,7 +528,7 @@ msgstr "Defina o produto de adesão."
#. module: membership
#: view:product.product:0
msgid "Category"
msgstr ""
msgstr "Categoria"
#. module: membership
#: selection:membership.membership_line,state:0
@ -514,7 +540,7 @@ msgstr "Membro Gratuito"
#. module: membership
#: model:product.pricelist.version,name:membership.ver1m
msgid "Member Sale Pricelist Version"
msgstr "Versão da lista de preço para venda a membro"
msgstr "Versão da lista de preço do membro."
#. module: membership
#: constraint:product.template:0
@ -526,17 +552,17 @@ msgstr ""
#. module: membership
#: view:report.membership:0
msgid "Forecast"
msgstr ""
msgstr "Previsão"
#. module: membership
#: field:report.membership,partner_id:0
msgid "Member"
msgstr ""
msgstr "Membro"
#. module: membership
#: view:product.product:0
msgid "Date From"
msgstr ""
msgstr "Data de"
#. module: membership
#: model:process.node,name:membership.process_node_associatedmember0
@ -546,7 +572,7 @@ msgstr "Membro associado"
#. module: membership
#: view:product.product:0
msgid "Accounting Info"
msgstr ""
msgstr "Informações da Conta"
#. module: membership
#: help:report.membership,date_to:0
@ -556,12 +582,12 @@ msgstr ""
#. module: membership
#: view:res.partner:0
msgid "Customers"
msgstr ""
msgstr "Clientes"
#. module: membership
#: selection:report.membership,month:0
msgid "August"
msgstr ""
msgstr "Agosto"
#. module: membership
#: model:ir.actions.act_window,name:membership.action_membership_products
@ -573,7 +599,7 @@ msgstr "Produtos de Adesão"
#. module: membership
#: selection:report.membership,month:0
msgid "June"
msgstr ""
msgstr "Junho"
#. module: membership
#: model:ir.ui.menu,name:membership.menu_membership
@ -584,7 +610,7 @@ msgstr ""
#: view:res.partner:0
#: field:res.partner,member_lines:0
msgid "Membership"
msgstr "Adesão"
msgstr "Associação"
#. module: membership
#: selection:membership.membership_line,state:0
@ -614,12 +640,12 @@ msgstr "Associação Parceiro"
#: field:report.membership,date_from:0
#: view:res.partner:0
msgid "Start Date"
msgstr ""
msgstr "Data de Início"
#. module: membership
#: selection:report.membership,month:0
msgid "November"
msgstr ""
msgstr "Novembro"
#. module: membership
#: help:product.product,membership:0
@ -634,17 +660,17 @@ msgstr ""
#. module: membership
#: selection:report.membership,month:0
msgid "October"
msgstr ""
msgstr "Outubro"
#. module: membership
#: view:product.product:0
msgid "Sale Description"
msgstr ""
msgstr "Descrição da venda"
#. module: membership
#: selection:report.membership,month:0
msgid "January"
msgstr ""
msgstr "Janeiro"
#. module: membership
#: view:res.partner:0
@ -686,14 +712,14 @@ msgstr "Membro Antigo"
#. module: membership
#: field:membership.membership_line,date_to:0
msgid "To"
msgstr "Até"
msgstr "Para"
#. module: membership
#: view:report.membership:0
#: field:report.membership,membership_state:0
#: field:res.partner,membership_state:0
msgid "Current Membership State"
msgstr ""
msgstr "Estado atual da Associação"
#. module: membership
#: view:product.product:0
@ -708,18 +734,18 @@ msgstr "A Fatura provisória agora está aberta."
#. module: membership
#: view:product.product:0
msgid "Inactive"
msgstr ""
msgstr "Inativo"
#. module: membership
#: model:ir.model,name:membership.model_account_invoice
#: field:membership.membership_line,account_invoice_id:0
msgid "Invoice"
msgstr ""
msgstr "Fatura"
#. module: membership
#: view:membership.invoice:0
msgid "Close"
msgstr ""
msgstr "Fechar"
#. module: membership
#: view:res.partner:0
@ -739,7 +765,7 @@ msgstr "Linha da conta na fatura"
#. module: membership
#: view:product.product:0
msgid "Categorization"
msgstr ""
msgstr "Categorização"
#. module: membership
#: model:process.node,note:membership.process_node_waitingmember0
@ -757,7 +783,7 @@ msgstr "Preço para membro"
#. module: membership
#: view:product.product:0
msgid "Purchase Description"
msgstr ""
msgstr "Descrição da compra"
#. module: membership
#: model:ir.model,name:membership.model_product_product
@ -777,7 +803,7 @@ msgstr "Membro gratuito"
#. module: membership
#: selection:report.membership,month:0
msgid "May"
msgstr ""
msgstr "Maio"
#. module: membership
#: model:product.template,name:membership.membership_1_product_template
@ -793,12 +819,12 @@ msgstr ""
#: field:report.membership,date_to:0
#: view:res.partner:0
msgid "End Date"
msgstr ""
msgstr "Data final"
#. module: membership
#: selection:report.membership,month:0
msgid "February"
msgstr ""
msgstr "Fevereiro"
#. module: membership
#: model:process.node,name:membership.process_node_invoicedmember0

View File

@ -9,11 +9,9 @@
<field name="priority">22</field>
<field name="inherit_id" ref="base.view_company_form"/>
<field name="arch" type="xml">
<page string="Configuration" position="inside">
<group>
<field name="manufacturing_lead"/>
</group>
</page>
<xpath expr="//group[@name='logistics_grp']" position="inside">
<field name="manufacturing_lead"/>
</xpath>
</field>
</record>

View File

@ -206,7 +206,7 @@ class mrp_bom(osv.osv):
'product_id': fields.many2one('product.product', 'Product', required=True),
'product_uos_qty': fields.float('Product UOS Qty'),
'product_uos': fields.many2one('product.uom', 'Product UOS', help="Product UOS (Unit of Sale) is the unit of measurement for the invoicing and promotion of stock."),
'product_qty': fields.float('Product Qty', required=True, digits_compute=dp.get_precision('Product Unit of Measure')),
'product_qty': fields.float('Product Quantity', required=True, digits_compute=dp.get_precision('Product Unit of Measure')),
'product_uom': fields.many2one('product.uom', 'Product Unit of Measure', required=True, help="Unit of Measure (Unit of Measure) is the unit of measurement for the inventory control"),
'product_rounding': fields.float('Product Rounding', help="Rounding applied on the product quantity."),
'product_efficiency': fields.float('Manufacturing Efficiency', required=True, help="A factor of 0.9 means a loss of 10% within the production process."),
@ -456,7 +456,7 @@ class mrp_production(osv.osv):
'product_id': fields.many2one('product.product', 'Product', required=True, readonly=True, states={'draft':[('readonly',False)]}),
'product_qty': fields.float('Product Quantity', digits_compute=dp.get_precision('Product Unit of Measure'), required=True, states={'draft':[('readonly',False)]}, readonly=True),
'product_uom': fields.many2one('product.uom', 'Product Unit of Measure', required=True, states={'draft':[('readonly',False)]}, readonly=True),
'product_uos_qty': fields.float('Product UoS Qty', states={'draft':[('readonly',False)]}, readonly=True),
'product_uos_qty': fields.float('Product UoS Quantity', states={'draft':[('readonly',False)]}, readonly=True),
'product_uos': fields.many2one('product.uom', 'Product UoS', states={'draft':[('readonly',False)]}, readonly=True),
'location_src_id': fields.many2one('stock.location', 'Raw Materials Location', required=True,
@ -474,7 +474,7 @@ class mrp_production(osv.osv):
'routing_id': fields.many2one('mrp.routing', string='Routing', on_delete='set null', readonly=True, states={'draft':[('readonly',False)]}, help="The list of operations (list of work centers) to produce the finished product. The routing is mainly used to compute work center costs during operations and to plan future loads on work centers based on production plannification."),
'picking_id': fields.many2one('stock.picking', 'Picking List', readonly=True, ondelete="restrict",
help="This is the Internal Picking List that brings the finished product to the production plan"),
'move_prod_id': fields.many2one('stock.move', 'Move product', readonly=True),
'move_prod_id': fields.many2one('stock.move', 'Product Move', readonly=True),
'move_lines': fields.many2many('stock.move', 'mrp_production_move_ids', 'production_id', 'move_id', 'Products to Consume', domain=[('state','not in', ('done', 'cancel'))], states={'done':[('readonly',True)]}),
'move_lines2': fields.many2many('stock.move', 'mrp_production_move_ids', 'production_id', 'move_id', 'Consumed Products', domain=[('state','in', ('done', 'cancel'))]),
'move_created_ids': fields.one2many('stock.move', 'production_id', 'Products to Produce', domain=[('state','not in', ('done', 'cancel'))], states={'done':[('readonly',True)]}),
@ -1108,7 +1108,7 @@ class mrp_production_product_line(osv.osv):
'product_id': fields.many2one('product.product', 'Product', required=True),
'product_qty': fields.float('Product Quantity', digits_compute=dp.get_precision('Product Unit of Measure'), required=True),
'product_uom': fields.many2one('product.uom', 'Product Unit of Measure', required=True),
'product_uos_qty': fields.float('Product UOS Qty'),
'product_uos_qty': fields.float('Product UOS Quantity'),
'product_uos': fields.many2one('product.uom', 'Product UOS'),
'production_id': fields.many2one('mrp.production', 'Production Order', select=True),
}

View File

@ -122,12 +122,14 @@
action="mrp_property_action"
id="menu_mrp_property_action"
groups="product.group_mrp_properties"
parent="menu_mrp_property"/>
parent="menu_mrp_configuration"
sequence="30" />
<menuitem
action="mrp_property_group_action"
parent="menu_mrp_property"
groups="product.group_mrp_properties"
id="menu_mrp_property_group_action"/>
parent="menu_mrp_configuration"
groups="base.group_no_one,product.group_mrp_properties"
id="menu_mrp_property_group_action"
sequence="35" />
<!--
Work Centers
@ -153,12 +155,16 @@
<field name="arch" type="xml">
<form string="Work Center" version="7.0">
<group col="4">
<field name="name"/>
<field name="code"/>
<field name="active"/>
<field name="resource_type"/>
<field name="calendar_id" widget="selection"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<group>
<field name="name"/>
<field name="resource_type"/>
<field name="calendar_id" widget="selection"/>
</group>
<group>
<field name="code"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="active"/>
</group>
</group>
<notebook>
<page string="General Information">
@ -260,18 +266,22 @@
<field name="arch" type="xml">
<form string="Routing" version="7.0">
<group col="4">
<field name="name"/>
<field name="code"/>
<field name="active"/>
<field name="location_id"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<group>
<field name="name"/>
<field name="code"/>
</group>
<group>
<field name="location_id"/>
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
<field name="active"/>
</group>
</group>
<notebook>
<page string="Work Center Operations">
<field name="workcenter_lines"/>
<field name="workcenter_lines"/>
</page>
<page string="Notes">
<field name="note"/>
<field name="note"/>
</page>
</notebook>
</form>
@ -333,66 +343,68 @@
<field name="type">form</field>
<field name="arch" type="xml">
<form string="Bill of Material" version="7.0">
<sheet>
<label for="product_id" string="Product and Quantity" class="oe_edit_only"/>
<h1>
<field name="product_id" on_change="onchange_product_id(product_id, name, context)" class="oe_inline"/>:
<field name="product_qty" class="oe_inline"/>
<field name="product_uom" class="oe_inline" groups="product.group_uom"/>
</h1>
<div groups="mrp.group_mrp_routings">
<label for="routing_id" class="oe_edit_only"/>
<h2><field name="routing_id" class="oe_inline"/></h2>
</div>
<label for="product_id" string="Product and Quantity" class="oe_edit_only"/>
<h1>
<field name="product_id" on_change="onchange_product_id(product_id, name, context)" class="oe_inline"/>:
<field name="product_qty" class="oe_inline"/>
<field name="product_uom" class="oe_inline" groups="product.group_uom"/>
</h1>
<div groups="mrp.group_mrp_routings">
<label for="routing_id" class="oe_edit_only"/>
<h2><field name="routing_id" class="oe_inline"/></h2>
</div>
<group>
<group>
<group>
<field name="name"/>
<field name="code" string="Reference"/>
</group>
<group>
<field name="type"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="product_uos_qty" groups="product.group_uos" />
<field name="product_uos" groups="product.group_uos"/>
</group>
<field name="name"/>
<field name="code" string="Reference"/>
</group>
<notebook>
<page string="Components">
<field name="bom_lines" widget="one2many_list">
<tree string="Components" editable="bottom">
<field name="product_id" on_change="onchange_product_id(product_id, name)"/>
<field name="product_qty"/>
<field name="product_uom" groups="product.group_uom"/>
<field name="name" invisible="1"/>
<field name="date_start"/>
<field name="date_stop"/>
</tree>
</field>
</page>
<page string="Revisions" attrs="{'invisible': [('bom_id','!=',False)]}">
<field name="revision_ids"/>
</page>
<page string="Properties" groups="product.group_mrp_properties">
<group>
<field name="type"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<label for="product_uos_qty" groups="product.group_uos"/>
<div groups="product.group_uos" >
<field name="product_uos_qty"
class="oe_inline"/>
<label string="-" attrs="{'invisible':[('product_uos','=',False)]}" class="oe_inline"/>
<field name="product_uos" class="oe_inline"/>
</div>
</group>
</group>
<notebook>
<page string="Components">
<field name="bom_lines" widget="one2many_list">
<tree string="Components" editable="bottom">
<field name="product_id" on_change="onchange_product_id(product_id, name)"/>
<field name="product_qty"/>
<field name="product_uom" groups="product.group_uom"/>
<field name="name" invisible="1"/>
<field name="date_start"/>
<field name="date_stop"/>
</tree>
</field>
</page>
<page string="Revisions" attrs="{'invisible': [('bom_id','!=',False)]}">
<field name="revision_ids"/>
</page>
<page string="Properties" groups="product.group_mrp_properties">
<group>
<group>
<group>
<field name="position"/>
<field name="bom_id"/>
<field name="sequence"/>
<field name="active"/>
</group>
<group>
<field name="date_start"/>
<field name="date_stop"/>
<field name="product_rounding"/>
<field name="product_efficiency"/>
</group>
<field name="position"/>
<field name="bom_id"/>
<field name="sequence"/>
<field name="active"/>
</group>
<separator string="Properties"/>
<field name="property_ids" widget="many2many_tags" />
</page>
</notebook>
<newline/>
</sheet>
<group>
<field name="date_start"/>
<field name="date_stop"/>
<field name="product_rounding"/>
<field name="product_efficiency"/>
</group>
</group>
<separator string="Properties"/>
<field name="property_ids" widget="many2many_tags" />
</page>
</notebook>
</form>
</field>
</record>
@ -504,7 +516,7 @@
<menuitem
action="mrp_bom_form_action2"
id="menu_mrp_bom_form_action2"
parent="menu_mrp_bom"
parent="menu_mrp_configuration"
sequence="20"/>
<record id="action2" model="ir.actions.act_window">
@ -562,7 +574,7 @@
<field name="model">mrp.production</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<tree fonts="bold:needaction_pending==True" colors="blue:state in ('draft','confirmed');red:date_planned&lt;current_date and state not in ('done','cancel');black:date_planned&gt;=current_date and state not in ('done','cancel');gray:state in ('done','cancel')" string="Manufacturing Orders">
<tree fonts="bold:needaction_pending==True" colors="blue:state in ('draft','confirmed');red:date_planned&lt;current_date and state not in ('done','cancel');black:date_planned&gt;=current_date;gray:state in ('done','cancel') " string="Manufacturing Orders">
<field name="needaction_pending" invisible="1"/>
<field name="name"/>
<field name="date_planned"/>
@ -635,21 +647,22 @@
<field name="state" widget="statusbar" statusbar_visible="draft,ready,in_production,done" statusbar_colors='{"picking_except":"red","confirmed":"blue"}'/>
</header>
<sheet>
<div class="oe_button_box oe_right">
<button name="%(mrp.action_change_production_qty)d" type="action" states="ready,confirmed"
string="Change Quantity" icon="terp-accessories-archiver+"/>
</div>
<div class="oe_title">
<label for="product_id" string="Product and Quantity" class="oe_edit_only"/>
<h1>
<field name="product_id" on_change="product_id_change(product_id)" domain="[('supply_method','=','produce')]" class="oe_inline"/>:
<field name="product_qty" class="oe_inline"/>
<field name="product_uom" class="oe_inline" groups="product.group_uom"/>
</h1>
<div groups="mrp.group_mrp_routings">
<label for="routing_id" class="oe_edit_only"/>
<h2><field name="routing_id" class="oe_inline"/></h2>
</div>
<label for="product_id" class="oe_edit_only"/>
<h1>
<field name="product_id" on_change="product_id_change(product_id)" domain="[('supply_method','=','produce')]" class="oe_inline"/>
</h1>
<label for="product_qty" class="oe_edit_only"/>
<h2>
<field name="product_qty" class="oe_inline"/>
<field name="product_uom" groups="product.group_uom" class="oe_inline"/>
<button type="action"
icon="terp-accessories-archiver+"
name="%(mrp.action_change_production_qty)d"
string="Change Qty" states="ready,confirmed" class="oe_inline"/>
</h2>
<div groups="mrp.group_mrp_routings">
<label for="routing_id" class="oe_edit_only"/>
<h2><field name="routing_id" class="oe_inline"/></h2>
</div>
<group>
<group>
@ -659,95 +672,107 @@
</group>
<group>
<field name="user_id"/>
<field name="product_uos_qty" groups="product.group_uos"/>
<field name="product_uos" groups="product.group_uos"/>
<label for="product_uos_qty" groups="product.group_uos"/>
<div groups="product.group_uos">
<field name="product_uos_qty" class="oe_inline"/>
<label string="-" attrs="{'invisible':[('product_uos','=',False)]}" class="oe_inline"/>
<field name="product_uos" class="oe_inline"/>
</div>
</group>
</group>
<notebook>
<page string="Consumed Products">
<group>
<group groups="stock.group_locations">
<field name="bom_id" domain="[('product_id','=',product_id)]" context="{'default_product_id': product_id}" on_change="bom_id_change(bom_id)"/>
</group>
<group>
<field name="location_src_id" domain="[('usage','=','internal')]" on_change="location_id_change(location_src_id,location_dest_id)"/>
<field name="location_dest_id" domain="[('usage','=','internal')]"/>
</group>
<group>
<field name="bom_id" domain="[('product_id','=',product_id)]" context="{'default_product_id': product_id}" on_change="bom_id_change(bom_id)"/>
</group>
</group>
<group>
<field name="move_lines" domain="[('state','&lt;&gt;', ('done', 'cancel'))]">
<tree colors="blue:state == 'draft';black:state in ('picking_except','confirmed','ready','in_production');gray:state in ('cancel','done') " string="Products to Consume">
<field name="product_id"/>
<field name="product_qty"/>
<field name="product_uom" string="Unit of Measure" groups="product.group_uom"/>
<field name="location_id" string="Source Loc." groups="stock.group_locations"/>
<field name="state" invisible="1"/>
<button name="%(stock.move_consume)d"
string="Consume Products" type="action"
icon="gtk-go-forward" context="{'consume': True}"
states="draft,waiting,confirmed,assigned" />
<button
name="%(stock.track_line)d"
string="Split in Serial Numbers"
type="action" icon="gtk-justify-fill"
states="draft,waiting,confirmed,assigned" />
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned"/>
</tree>
</field>
<field name="move_lines2" domain="[('state','in', ('done', 'cancel'))]">
<tree colors="red:scrapped==True;blue:state == 'draft';black:state in('picking_except','confirmed','ready','in_production');gray:state == 'cancel' " string="Consumed Products" editable="bottom">
<field name="product_id" readonly="1"/>
<field name="product_qty" readonly="1"/>
<field name="product_uom" readonly="1" string="Unit of Measure" groups="product.group_uom"/>
<field name="prodlot_id" context="{'product_id': product_id}"/>
<field name="state" invisible="1"/>
<field name="scrapped" invisible="1"/>
<button
name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert"
states="done,cancel"/>
</tree>
</field>
<group string="Products to Consume">
<field name="move_lines" domain="[('state','&lt;&gt;', ('done', 'cancel'))]" nolabel="1">
<tree colors="blue:state == 'draft';black:state in ('picking_except','confirmed','ready','in_production');gray:state in ('cancel','done') " string="Products to Consume">
<field name="product_id" />
<field name="product_qty" string="Quantity"/>
<field name="product_uom" string="Unit of Measure" groups="product.group_uom"/>
<field name="location_id" string="Source Loc." groups="stock.group_locations"/>
<field name="state" invisible="1"/>
<button name="%(stock.move_consume)d"
string="Consume Products" type="action"
icon="gtk-go-forward" context="{'consume': True}"
states="draft,waiting,confirmed,assigned" />
<button
name="%(stock.track_line)d"
string="Split in Serial Numbers"
type="action" icon="gtk-justify-fill"
states="draft,waiting,confirmed,assigned" />
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned"/>
</tree>
</field>
</group>
<group string="Consumed Product">
<field name="move_lines2" domain="[('state','in', ('done', 'cancel'))]" nolabel="1">
<tree colors="red:scrapped==True;blue:state == 'draft';black:state in('picking_except','confirmed','ready','in_production');gray:state == 'cancel' " string="Consumed Products" editable="bottom">
<field name="product_id" readonly="1"/>
<field name="product_qty" readonly="1"/>
<field name="product_uom" readonly="1" string="Unit of Measure" groups="product.group_uom"/>
<field name="prodlot_id" context="{'product_id': product_id}"/>
<field name="state" invisible="1"/>
<field name="scrapped" invisible="1"/>
<button
name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert"
states="done,cancel"/>
</tree>
</field>
</group>
</group>
</page>
<page string="Finished Products">
<group>
<field name="move_created_ids" domain="[('state','&lt;&gt;', ('done', 'cancel'))]">
<tree string="Products to Finish">
<field name="product_id"/>
<field name="product_qty"/>
<field name="product_uom" string="Unit of Measure" groups="product.group_uom"/>
<field name="state" invisible="1"/>
<button name="%(stock.action_partial_move_server)d"
string="Partial"
type="action" states="confirmed,assigned"
icon="gtk-justify-fill"/>
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
</tree>
</field>
<field name="move_created_ids2" domain="[('state','in', ('done', 'cancel'))]">
<tree colors="red:scrapped==True;blue:state == 'draft';black:state in('picking_except','confirmed','ready','in_production');gray:state in('cancel','done') " string="Finished Products">
<field name="product_id" readonly="1"/>
<field name="product_qty" readonly="1"/>
<field name="product_uom" readonly="1" string="Unit of Measure" groups="product.group_uom"/>
<field name="location_dest_id" readonly="1" string="Destination Loc." widget="selection" groups="stock.group_locations"/>
<field name="prodlot_id" context="{'product_id': product_id}"/>
<field name="scrapped" invisible="1"/>
<field name="state" invisible="1"/>
<button name="%(stock.track_line)d"
string="Split in Serial Numbers" type="action" icon="gtk-justify-fill" states="done,cancel"/>
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action" icon="gtk-convert"
states="done,cancel" />
</tree>
</field>
<group string="Products to Produce">
<field name="move_created_ids" domain="[('state','&lt;&gt;', ('done', 'cancel'))]" nolabel="1">
<tree string="Products to Finish">
<field name="product_id" />
<field name="product_qty"/>
<field name="product_uom" string="Unit of Measure" groups="product.group_uom"/>
<field name="state" invisible="1"/>
<button name="%(stock.action_partial_move_server)d"
string="Partial"
type="action" states="confirmed,assigned"
icon="gtk-justify-fill"/>
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
icon="gtk-convert" context="{'scrap': True}"
states="draft,waiting,confirmed,assigned" />
</tree>
</field>
</group>
<group string="Produced Products">
<field name="move_created_ids2" domain="[('state','in', ('done', 'cancel'))]" nolabel="1">
<tree colors="red:scrapped==True;blue:state == 'draft';black:state in('picking_except','confirmed','ready','in_production');gray:state in('cancel','done') " string="Finished Products">
<field name="product_id" readonly="1"/>
<field name="product_qty" readonly="1"/>
<field name="product_uom" readonly="1" string="Unit of Measure" groups="product.group_uom"/>
<field name="location_dest_id" readonly="1" string="Destination Loc." widget="selection" groups="stock.group_locations"/>
<field name="prodlot_id" context="{'product_id': product_id}"/>
<field name="scrapped" invisible="1"/>
<field name="state" invisible="1"/>
<button name="%(stock.track_line)d"
string="Split in Serial Numbers" type="action" icon="gtk-justify-fill" states="done,cancel"/>
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action" icon="gtk-convert"
states="done,cancel" />
</tree>
</field>
</group>
</group>
</page>
<page string="Work Orders">
@ -758,7 +783,7 @@
<form string="Production Work Centers" version="7.0">
<group col="4">
<field colspan="4" name="name"/>
<field name="workcenter_id" widget="selection"/>
<field name="workcenter_id"/>
<field name="sequence"/>
<field name="cycle"/>
<field name="hour"/>
@ -767,7 +792,7 @@
<tree string="Production Work Centers">
<field name="sequence"/>
<field name="name"/>
<field name="workcenter_id" widget="selection"/>
<field name="workcenter_id"/>
<field name="cycle"/>
<field name="hour"/>
</tree>
@ -782,15 +807,15 @@
<page string="Extra Information">
<group>
<group>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="priority"/>
<field name="picking_id"/>
<field name="move_prod_id" groups="stock.group_locations"/>
</group>
<group>
<field name="date_start"/>
<field name="date_finished"/>
</group>
<group>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="picking_id"/>
<field name="move_prod_id" groups="stock.group_locations"/>
</group>
</group>
</page>
</notebook>
@ -974,7 +999,7 @@
<separator string="Bill of Materials"/>
<field name="bom_ids" widget="one2many_list" mode="tree" context="{'default_product_id': active_id}">
<tree string="Bill of Materials">
<field name="name" string="Component Name"/>
<field name="name" string="Component Name"/>
<field name="bom_id"/>
<field name="product_qty" string="Quantity of Product"/>
<field name="type"/>
@ -1009,7 +1034,7 @@
<!-- Menu for Resource for MRP-->
<record id="mrp_workcenter_action" model="ir.actions.act_window">
<field name="name">Work Centers</field>
<field name="name">Work Center</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">mrp.workcenter</field>
<field name="view_type">form</field>
@ -1024,7 +1049,7 @@
</record>
<menuitem id="menu_pm_resources_config" name="Resources" parent="menu_mrp_configuration"/>
<menuitem action="mrp_workcenter_action" id="menu_view_resource_search_mrp" groups="mrp.group_mrp_routings" parent="mrp.menu_mrp_bom" sequence="25"/>
<menuitem action="mrp_workcenter_action" id="menu_view_resource_search_mrp" groups="mrp.group_mrp_routings" parent="mrp.menu_mrp_configuration" sequence="25"/>
<menuitem action="resource.action_resource_calendar_form" id="menu_view_resource_calendar_search_mrp" parent="menu_pm_resources_config" sequence="1" groups="base.group_no_one"/>
<menuitem action="resource.action_resource_calendar_leave_tree" id="menu_view_resource_calendar_leaves_search_mrp" parent="menu_pm_resources_config" sequence="1" groups="base.group_no_one"/>

View File

@ -12,22 +12,22 @@
or
<button string="Cancel" type="object" name="cancel" class="oe_link"/>
</header>
<group string="Manufacturing Order">
<field name="module_mrp_operations"/>
<field name="module_stock_planning"/>
<field name="module_mrp_subproduct"/>
<field name="module_mrp_repair"/>
</group>
<group string="Logistics">
<field name="module_mrp_jit"/>
<field name="module_stock_no_autopicking"/>
</group>
<group string="Bill Of Material">
<field name="group_mrp_routings"/>
<field name="group_mrp_properties"/>
</group>
<group string="Products">
<field name="module_product_manufacturer"/>
<group>
<group string="Manufacturing Order">
<field name="module_mrp_operations"/>
<field name="module_stock_planning"/>
<field name="module_mrp_subproduct"/>
<field name="module_mrp_repair"/>
<separator string="Logistics" colspan="2"/>
<field name="module_mrp_jit"/>
<field name="module_stock_no_autopicking"/>
</group>
<group string="Products">
<field name="module_product_manufacturer"/>
<separator string="Bill Of Material" colspan="2"/>
<field name="group_mrp_routings"/>
<field name="group_mrp_properties"/>
</group>
</group>
</form>
</field>

View File

@ -8,18 +8,17 @@
<field name="type">form</field>
<field name="inherit_id" ref="mrp.mrp_production_form_view"/>
<field name="arch" type="xml">
<xpath expr="//field[@name='workcenter_lines']/form//field[@name='hour']" position="after">
<group colspan="8" col="8">
<separator colspan="8"/>
<field name="state"/>
<button name="button_cancel" string="Cancel" states="draft,startworking" icon="gtk-stop" help="Cancel Order"/>
<button name="button_draft" string="Set Draft" states="cancel" icon="gtk-convert" help="Set to Draft"/>
<button name="button_start_working" string="Start" states="draft" icon="terp-gtk-jump-to-ltr" help="Start Working"/>
<button name="button_resume" string="Resume" states="pause" icon="gtk-media-pause" help="Resume Work Order"/>
<button name="button_pause" string="Pending" states="startworking" icon="gtk-media-pause" help="Pause Work Order"/>
<button name="button_done" string="Finished" states="startworking" icon="terp-check" help="Finish Order"/>
</group>
</xpath>
<xpath expr="//field[@name='workcenter_lines']/form//field[@name='name']" position="before">
<header colspan="8">
<button name="button_start_working" string="Start" states="draft" icon="terp-gtk-jump-to-ltr" help="Start Working"/>
<button name="button_cancel" string="Cancel" states="draft,startworking" icon="gtk-stop" help="Cancel Order"/>
<button name="button_draft" string="Set Draft" states="cancel" icon="gtk-convert" help="Set to Draft"/>
<button name="button_resume" string="Resume" states="pause" icon="gtk-media-pause" help="Resume Work Order"/>
<button name="button_pause" string="Pending" states="startworking" icon="gtk-media-pause" help="Pause Work Order"/>
<button name="button_done" string="Finished" states="startworking" icon="terp-check" help="Finish Order"/>
<field name="state" widget="statusbar"/>
</header>
</xpath>
</field>
</record>
@ -80,7 +79,7 @@
<sheet string="Work Orders">
<group col="4">
<field colspan="4" name="name"/>
<field name="workcenter_id" widget="selection"/>
<field name="workcenter_id"/>
<field name="production_id"/>
<field name="production_state"/>
<field name="sequence"/>
@ -351,7 +350,7 @@
<field name="model">mrp.production</field>
<field name="type">form</field>
<field name="arch" type="xml">
<field name="priority" position="after">
<field name="date_finished" position="after">
<field name="allow_reorder"/>
</field>
</field>

View File

@ -26,17 +26,18 @@
<field name="priority" eval="8"/>
<field name="arch" type="xml">
<form string="Multi Company">
<group col="6" colspan="4">
<field name="name" colspan="6"/>
<separator string="Matching" colspan="6"/>
<field name="company_id" groups="base.group_multi_company"/>
<field name="object_id"/>
<field name="field_id" domain="[('model_id','=',object_id)]"/>
<separator string="Condition" colspan="6"/>
<field name="expression" colspan="4"/>
<field name="sequence"/>
<separator string="Returning" colspan="6"/>
<field name="company_dest_id"/>
<group>
<group>
<field name="name"/>
<field name="company_id" groups="base.group_multi_company"/>
<field name="company_dest_id"/>
</group>
<group>
<field name="object_id"/>
<field name="field_id" domain="[('model_id','=',object_id)]"/>
<field name="expression"/>
<field name="sequence"/>
</group>
</group>
</form>
</field>
@ -71,7 +72,7 @@
parent="base.menu_custom"
sequence="50"/>
<menuitem id="menu_action_inventory_form"
<menuitem id="base.menu_action_inventory_form"
action="action_inventory_form"
parent="menu_custom_multicompany"/>
</data>

View File

@ -6,9 +6,10 @@
<field name="type">form</field>
<field name="inherit_id" ref="base.view_company_form"/>
<field name="arch" type="xml">
<xpath expr="//page[@string='Configuration']" position="inside">
<separator string="Pad" colspan="4"/>
<field name="pad_url_template"/>
<xpath expr="//group[@name='account_grp']" position="after">
<group string="Pads">
<field name="pad_url_template"/>
</group>
</xpath>
</field>
</record>

View File

@ -0,0 +1,74 @@
# Indonesian translation for openobject-addons
# Copyright (c) 2012 Rosetta Contributors and Canonical Ltd 2012
# This file is distributed under the same license as the openobject-addons package.
# FIRST AUTHOR <EMAIL@ADDRESS>, 2012.
#
msgid ""
msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2012-02-09 00:36+0000\n"
"PO-Revision-Date: 2012-07-16 09:40+0000\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: Indonesian <id@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: 2012-07-17 04:49+0000\n"
"X-Generator: Launchpad (build 15627)\n"
#. module: plugin_outlook
#: view:outlook.installer:0
msgid ""
"This plug-in allows you to create and link outlook emails with openerp "
"objects."
msgstr ""
#. module: plugin_outlook
#: field:outlook.installer,name:0
msgid "Outlook Plug-in"
msgstr ""
#. module: plugin_outlook
#: model:ir.actions.act_window,name:plugin_outlook.action_outlook_installer
#: model:ir.actions.act_window,name:plugin_outlook.action_outlook_wizard
#: model:ir.ui.menu,name:plugin_outlook.menu_base_config_plugins_outlook
#: view:outlook.installer:0
msgid "Install Outlook Plug-In"
msgstr ""
#. module: plugin_outlook
#: field:outlook.installer,config_logo:0
msgid "Image"
msgstr ""
#. module: plugin_outlook
#: view:outlook.installer:0
msgid "title"
msgstr ""
#. module: plugin_outlook
#: model:ir.model,name:plugin_outlook.model_outlook_installer
msgid "outlook.installer"
msgstr ""
#. module: plugin_outlook
#: view:outlook.installer:0
msgid "_Close"
msgstr ""
#. module: plugin_outlook
#: view:outlook.installer:0
msgid "Installation and Configuration Steps"
msgstr ""
#. module: plugin_outlook
#: help:outlook.installer,name:0
msgid ""
"outlook plug-in file. Save as this file and install this plug-in in outlook."
msgstr ""
#. module: plugin_outlook
#: field:outlook.installer,description:0
msgid "Description"
msgstr ""

View File

@ -14,7 +14,7 @@
<separator string="title" position="before">
<label string="This plug-in allows you to create and link outlook emails with openerp objects."/>
</separator>
<xpath expr="//header" position="replace"/>
<xpath expr="//footer" position="replace"/>
<xpath expr="//separator[@string='title']" position="after" version="7.0">
<group>
<field name="plugin32" widget="url"/>

View File

@ -14,7 +14,7 @@
<separator string="title" position="before">
<label string="This plug-in allows you to link your email to OpenERP's documents. You can attach it to any existing one in OpenERP or create a new one."/>
</separator>
<xpath expr="//header" position="replace"/>
<xpath expr="//footer" position="replace"/>
<xpath expr="//separator[@string='title']" position="after">
<group>
<field name="thunderbird" invisible="1"/>

View File

@ -21,8 +21,11 @@
import point_of_sale
import account_bank_statement
import res_users
import wizard
import report
import controllers
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -51,22 +51,23 @@ Main features :
'wizard/pos_discount.xml',
'wizard/pos_open_statement.xml',
'wizard/pos_close_statement.xml',
'wizard/pos_box_entries.xml',
'wizard/pos_payment_report_user_view.xml',
'wizard/pos_box_out.xml',
'wizard/pos_sales_user.xml',
'wizard/pos_receipt_view.xml',
'wizard/pos_payment_report_user.xml',
'wizard/pos_payment_report.xml',
'wizard/pos_payment.xml',
'wizard/pos_box.xml',
'wizard/pos_session_opening.xml',
'point_of_sale_report.xml',
'point_of_sale_view.xml',
'point_of_sale_data.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',
'account_statement_report.xml',
'res_users_view.xml',
],
'demo_xml': [
'point_of_sale_demo.xml',
@ -80,10 +81,24 @@ Main features :
],
'installable': True,
'application': True,
'certificate' : '001156338024966477869',
# Web client
'js': ['static/lib/backbone/backbone-0.5.3.js', 'static/src/js/pos.js'],
'css': ['static/src/css/pos.css'],
'js': [
'static/lib/backbone/backbone-0.9.2.js',
'static/lib/mousewheel/jquery.mousewheel-3.0.6.js',
'static/src/js/pos_models.js',
'static/src/js/pos_basewidget.js',
'static/src/js/pos_keyboard_widget.js',
'static/src/js/pos_scrollbar_widget.js',
'static/src/js/pos_widgets.js',
'static/src/js/pos_devices.js',
'static/src/js/pos_screens.js',
'static/src/js/pos_main.js'
],
'css': [
'static/src/css/pos.css',
'static/src/css/keyboard.css'
],
'qweb': ['static/src/xml/pos.xml'],
'auto_install': False,
}
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -25,53 +25,27 @@ from osv import fields, osv
class account_journal(osv.osv):
_inherit = 'account.journal'
_columns = {
'auto_cash': fields.boolean('Automatic Opening', help="This field authorize the automatic creation of the cashbox, without control of the initial balance."),
'check_dtls': fields.boolean('Control Balance Before Closing', help="This field authorize Validation of Cashbox without controlling the closing balance."),
'journal_user': fields.boolean('PoS Payment Method', help="Check this box if this journal define a payment method that can be used in point of sales."),
'opening_control': fields.boolean('Opening Control', help="If you want the journal should be control at opening, check this option"),
'closing_control': fields.boolean('Closing Control', help="If you want the journal should be control at closing, check this option"),
'amount_authorized_diff' : fields.float('Amount Authorized Difference'),
'self_checkout_payment_method' : fields.boolean('Self Checkout Payment Method'),
}
_defaults = {
'check_dtls': False,
'auto_cash': True,
'opening_control' : True,
'closing_control' : True,
'self_checkout_payment_method' : False,
}
account_journal()
class account_cash_statement(osv.osv):
_inherit = 'account.bank.statement'
def _equal_balance(self, cr, uid, cash_id, context=None):
statement = self.browse(cr, uid, cash_id, context=context)
if not statement.journal_id.check_dtls:
return True
if statement.journal_id.check_dtls and (statement.balance_end != statement.balance_end_cash):
return False
else:
return True
def _get_cash_open_box_lines(self, cr, uid, context=None):
res = super(account_cash_statement,self)._get_cash_open_box_lines(cr, uid, context)
curr = [0.01, 0.02, 0.05, 0.10, 0.20, 0.50]
for rs in curr:
dct = {
'pieces': rs,
'number': 0
}
res.append(dct)
res.sort()
return res
def _get_default_cash_close_box_lines(self, cr, uid, context=None):
res = super(account_cash_statement,self)._get_default_cash_close_box_lines(cr, uid, context=context)
curr = [0.01, 0.02, 0.05, 0.10, 0.20, 0.50]
for rs in curr:
dct = {
'pieces': rs,
'number': 0
}
res.append(dct)
res.sort()
return res
_columns = {
'pos_session_id' : fields.many2one('pos.session'),
}
account_cash_statement()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

View File

@ -9,11 +9,12 @@
<field name="arch" type="xml">
<xpath expr="//notebook[last()]" position="inside">
<page string="Point of Sale">
<group col="6" colspan="4">
<separator colspan="6" string="Extended Configuration"/>
<group col="4" colspan="4">
<field name="journal_user"/>
<field name="auto_cash"/>
<field name="check_dtls"/>
<field name="opening_control"/>
<field name="closing_control"/>
<field name="amount_authorized_diff"/>
<field name="self_checkout_payment_method" />
</group>
</page>
</xpath>
@ -105,7 +106,7 @@
<field name="inherit_id" ref="account.view_cash_statement_tree"/>
<field name="arch" type="xml">
<field name="journal_id" position="after">
<field name="user_id"/>
<field name="user_id" string="Responsible"/>
</field>
</field>
</record>
@ -133,6 +134,7 @@
<field name="act_window_id" ref="action_new_bank_statement_all_tree"/>
</record>
<!--
<menuitem name="Cash Register Management" parent="point_of_sale.menu_point_root"
id="menu_point_open_config" sequence="10"/>
<menuitem
@ -160,6 +162,7 @@
id="menu_all_menu_all_register"
sequence="4"
/>
-->
</data>

View File

@ -0,0 +1,111 @@
# -*- coding: utf-8 -*-
import logging
try:
import openerp.addons.web.common.http as openerpweb
except ImportError:
import web.common.http as openerpweb
class PointOfSaleController(openerpweb.Controller):
_cp_path = '/pos'
@openerpweb.jsonrequest
def dispatch(self, request, iface, **kwargs):
method = 'iface_%s' % iface
return getattr(self, method)(request, **kwargs)
@openerpweb.jsonrequest
def scan_item_success(self, request):
"""
A product has been scanned with success
"""
print 'scan_item_success'
return
@openerpweb.jsonrequest
def scan_item_error_unrecognized(self, request):
"""
A product has been scanned without success
"""
print 'scan_item_error_unrecognized'
return
@openerpweb.jsonrequest
def help_needed(self, request):
"""
The user wants an help (ex: light is on)
"""
print "help_needed"
return
@openerpweb.jsonrequest
def help_canceled(self, request):
"""
The user stops the help request
"""
print "help_canceled"
return
@openerpweb.jsonrequest
def weighting_start(self, request):
print "weighting_start"
return
@openerpweb.jsonrequest
def weighting_read_kg(self, request):
print "weighting_read_kg"
return 0.0
@openerpweb.jsonrequest
def weighting_end(self, request):
print "weighting_end"
return
@openerpweb.jsonrequest
def payment_request(self, request, price, method, info):
"""
The PoS will activate the method payment
"""
print "payment_request: price:"+str(price)+" method:"+str(method)+" info:"+str(info)
return
@openerpweb.jsonrequest
def is_payment_accepted(self, request):
print "is_payment_accepted"
return 'waiting_for_payment'
@openerpweb.jsonrequest
def payment_canceled(self, request):
print "payment_canceled"
return
@openerpweb.jsonrequest
def transaction_start(self, request):
print 'transaction_start'
return
@openerpweb.jsonrequest
def transaction_end(self, request):
print 'transaction_end'
return
@openerpweb.jsonrequest
def cashier_mode_activated(self, request):
print 'cashier_mode_activated'
return
@openerpweb.jsonrequest
def cashier_mode_deactivated(self, request):
print 'cashier_mode_deactivated'
return
@openerpweb.jsonrequest
def open_cashbox(self, request):
print 'open_cashbox'
return
@openerpweb.jsonrequest
def print_receipt(self, request, receipt):
print 'print_receipt' + str(receipt)
return

Binary file not shown.

View File

@ -0,0 +1,525 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="744.09448819"
height="1052.3622047"
id="svg2"
version="1.1"
inkscape:version="0.48.3.1 r9886"
sodipodi:docname="barcode_test_sheet.svg">
<defs
id="defs4" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="1"
inkscape:pageshadow="2"
inkscape:zoom="0.86706515"
inkscape:cx="381.55817"
inkscape:cy="505.31292"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
inkscape:window-width="1855"
inkscape:window-height="1176"
inkscape:window-x="65"
inkscape:window-y="24"
inkscape:window-maximized="1" />
<metadata
id="metadata7">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1">
<g
id="g4158"
transform="matrix(0.92675002,0,0,0.92675002,27.597551,38.360312)">
<text
sodipodi:linespacing="125%"
id="text2985"
y="72.12545"
x="140.86679"
style="font-size:46.51613998px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="72.12545"
x="140.86679"
id="tspan2987"
sodipodi:role="line">BARCODE TEST SHEET</tspan></text>
<g
transform="translate(0,-5.3405762e-5)"
id="g3347">
<image
y="124.14642"
x="388.17426"
id="image3083"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOYAAACYCAIAAAB/IAJdAAAAA3NCSVQICAjb4U/gAAADqUlEQVR4 nO3a226jMABFUYjy/7/MPCChDBfHARM4zVpP1dQY4u66JEw/DEO3S9/3XdeNh79+vRwz2hr5OmZr 5JH5t0YuX0X51W0dW3PNNa9xOWf5au8wsrxu9Ud95HHkYPg+yRJGsoSRLGEkSxjJEkayhJEsYSRL GMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJ EkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJG soSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKE kSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEs YSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEk SxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxh+mEY dh7Z913XjYe/fv3LrMlS8zWxyxJGsjuNGwbf91z911Z/1GY/18oJ689+cOTb7LZmPtJr/ZrcfOTu 1SucseaQlV221f6xnKdm5vqznzHy1Nn6vq9fk5SRrYzzry7RzHyXbd7r9HszXVP9b3bN/EdGlq/k 0y250uu0W2tSv3oXjvxo9d4ahmE6b/mP58ou2/BNbuUr3Hf2M0aOzthRVn8M5QurX71rR87sXr1h GGa/z6tT/Zds2y12+TpfP+nYOqp+/rYjZ4esXvzk0zkLlmtSv3rXjlx1/F3QMtzZgMfse1d9jvi1 t1zND2HScPUK2+2j+cl2uEmvl/Bh2Zat+4TH64gLruvzs599C3vSOqz+Yf1LvZ60estwn93ehdt9 ez5zk1vYJmrW5C9lWqNVJ5OnW4IjR31kudFWvqe5v/NWb/lE47n6jbOvo3xZhbOfMfLL7n97fRNb j9/WH9j+mgtTtsUW5hzNN6PVMx2/iMLO93ba798tfPp6d398tjyqfqFu+I9vv7XD1uY6Ofd/ci0/ o/5ZhR/2lvrVu3ZkK7PPX7ee2px1YzA9Mn77S/Nrlj/+1UdNlat37ciGCncCMyfuslsP/e7mazey y22j8Pi3fvWuHdlq9cYZap6H/wMqFm5yx9XfMwAAAABJRU5ErkJggg== "
height="107.96206"
width="163.36363" />
<rect
style="fill:none;stroke:#c3c3c3;stroke-width:1.07903957;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3086"
width="417.54495"
height="126.4052"
x="141.08452"
y="114.51707"
rx="2.0839903"
ry="2.0839903" />
<text
xml:space="preserve"
style="font-size:27.53050041px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="201.46712"
y="147.73848"
id="text3856"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3858"
x="201.46712"
y="147.73848"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">CASHIER</tspan></text>
<text
sodipodi:linespacing="125%"
id="text3860"
y="182.10147"
x="154.5717"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="182.10147"
x="154.5717"
id="tspan3862"
sodipodi:role="line">Prefix: 40</tspan></text>
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="200.85837"
id="text3149"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3151"
x="154.5717"
y="200.85837"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">ID: 4447190000</tspan></text>
</g>
<g
transform="translate(0,0.97855377)"
id="g3335">
<g
id="g3173"
transform="translate(0,-3.2620699)">
<text
sodipodi:linespacing="125%"
id="text3153"
y="341.12738"
x="154.5717"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="341.12738"
x="154.5717"
id="tspan3155"
sodipodi:role="line">Prefix: 42</tspan></text>
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="359.88428"
id="text3157"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3159"
x="154.5717"
y="359.88428"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">ID: 1182180000</tspan></text>
</g>
<g
id="g3954"
transform="translate(0,-18.756902)">
<rect
style="fill:none;stroke:#c3c3c3;stroke-width:1.07903957;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3876"
width="417.54495"
height="126.4052"
x="141.08452"
y="284.96024"
rx="2.0839903"
ry="2.0839903" />
<text
xml:space="preserve"
style="font-size:27.53050041px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="209.6223"
y="318.18164"
id="text3878"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3880"
x="209.6223"
y="318.18164"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">CLIENT</tspan></text>
<image
width="162.31204"
height="107.26709"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOYAAACYCAIAAAB/IAJdAAAAA3NCSVQICAjb4U/gAAADyUlEQVR4 nO3a3Y6qShSFUTC+/yvXuSAxbCgQsPiZp8e46mgJq/ETxe6+lNId0vd913XDw8c/z+8d3zIYP2p8 y9LKLbcvbXN8y5Zt/jLn0jHZcnzm29z+m961cmn+vY/a5fXLg+F6kiWMZAkjWcJIljCSJYxkCSNZ wkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJI ljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYw kiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIl jGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxk CSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkj WcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nC 9KWUg4/s+67rhoePf/7LHJO55sfEWZYwj0t2eCG2XXmGe/f+l72rt7Z6U5s8r1832LbX+ZqlAc6b 85qpbln59SDs7afvN31MrZxlm5w/+r6fb6d644H9Huu1euOpcx6eqnrj0n7vXdnKsP31Iz+YnmWb TzZ+3Wx/wqoOrJzvfeml3HDO36ear1wa/saV62fovafYUspnv+tv8pWzbMPPA5NNjS8bL1Dd+9gt c36dqnrX+pNy78qJw8etlDJ53VY39U+ybZ+kjb9nGWm1cpfmc/5o6RwzfyHdu3LX8NvNw50seE3u a/J8XPC8bjH5bavXPdfP+XWqXG0TGm92fJTezXf2BJ8PRtsvzy/wzKkea3Je/yT6mqw41e0vjI27 vnjO/0evJx20+eeEd3f0vWnXx/OlC52TVA/f8P6yPsCPc64fk8NTRTt8GbfkffYZ5eJYu9ULiJU+ zp7z2FQpzqtocj4tpbyrdzSZY7zNJz8fKXP+NfNYhx/qf7BtuL+HR5Ay55OdcYpdOY+8Ss1n6Y9z pHTwqDmXvgGdl3HvypNMvtKa7/GU/+S695uB7Qf9yjkPpDD/hn/JvStbmcdaPSxnfTDoVn/PK783 +GXZBdcTS/utfoO7dPV218qGtl9RPO7/ZZuovkBv/5vcrqmqK5c2e+PKVu9Uwxa2PEf/AXnknj+O sxSLAAAAAElFTkSuQmCC "
id="image3951"
x="388.17426"
y="294.58957" />
</g>
</g>
<g
transform="translate(0,0.3261795)"
id="g3322">
<rect
style="fill:none;stroke:#c3c3c3;stroke-width:1.07903957;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect3964"
width="417.54495"
height="126.4052"
x="141.08452"
y="419.52063"
rx="2.0839903"
ry="2.0839903" />
<text
xml:space="preserve"
style="font-size:27.53050041px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="209.6223"
y="452.74203"
id="text3966"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3968"
x="209.6223"
y="452.74203"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">WEIGHT</tspan></text>
<image
width="162.12962"
height="107.14654"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOYAAACYCAIAAAB/IAJdAAAAA3NCSVQICAjb4U/gAAAERElEQVR4 nO3a0ZKaQBRFUbX8/182D1QZInRzadDxTNZ6mjgNNrhBYHJ9PB6XIdfr9XK5TIvPf57/drJ8/ayR rVdaG9Wfc+Vd+vPc+3N/hv3XK68st2i5Xa09XNnS+sjKthfdjiwMnydZwkiWMJIljGQJI1nCSJYw kiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIl jGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxk CSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkj WcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nC SJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiW MJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCS Jcz18XgMLnm9Xi6XafH5z/8z+2Tp9H3iLEuYDyU7HV7njuT/dH/+9NLKid9o5/Zan+fYFnW+vFrT 27uv+hPb3AnLt1su0prSO/beWeVcr6XL1Ns0dLnNqy+OzeOskfV5Dm9RZ8BZe2N1YgfXWXlx11u/ Y2TftFTlM7rP/zFv/B378eDIp+I8V89enUO5MpMjXz7P9S/nP59V/3zWOiX317k6/9aw5TqPj9z0 eDyea+vfpd1Wt/ny7y3eN6jP88jX9wdu8Jfzn2wuWD84W1cOm8Navz1rZN/LfmidcW/H36nz9pUP oz7yUs6uuLa5dx+cB5/vvOmRWeuAb52ex0bunVL/W/Se8uDw+Dw3r1MHTnVjs5qvpP6m9QuG7/lu HNa5Trg3F/oVKrfSR05ge5dt3awMH5DPj7b+0KA/n+/xcrZ+7qhmsm/6JjpdfZ6dMZuLd+5yBuxa ydgHsbxsnS4N407Gy3BXkm3d6KyuqzLyTSrzXH5Cex+Cdt5ifoabBlT2SSWmutZGtVb4+UxP7+Sf v34979EGbl8+aWye9RuIuoMnv039Ge66AVruqy//lCcvzw3+XhjsvSH4Ke+YZ+dR/DfvijFBW9S6 071fylcCP644z19T2wc25GsvZzvnpnvrF1/rxHl2rvZWL3lbTxuK77V6ifmZaPpH+8vlZmeeYyPH ptqa8C3lnPTjj5OW6xz7dlr9Q93YrFoP7Vfz6s+kOM+DI/uWl63r095c0VnP8A8+M9/cF8XHN8Xn WfUT6nCvm2uo7Lf6lu6af32eu7aoo36X8jv/i/fqAXrwBrm1zr0rKa6heJzXt3TXE4P6PI/vk/lS lc/oD6RX6TSeNJuDAAAAAElFTkSuQmCC "
id="image4065"
x="387.35876"
y="429.14993" />
<g
transform="translate(0,140.26901)"
id="g3179">
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="341.12738"
id="text3181"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3183"
x="154.5717"
y="341.12738"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">Prefix: 21</tspan></text>
<text
sodipodi:linespacing="125%"
id="text3185"
y="359.88428"
x="154.5717"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="359.88428"
x="154.5717"
id="tspan3187"
sodipodi:role="line">ID: 12345</tspan></text>
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="379.4567"
id="text3189"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3191"
x="154.5717"
y="379.4567"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">Value: 67.89Kg</tspan></text>
</g>
</g>
<g
transform="translate(0,-1.9572678)"
id="g3308">
<rect
ry="2.0839903"
rx="2.0839903"
y="574.46893"
x="141.08452"
height="126.4052"
width="417.54495"
id="rect4081"
style="fill:none;stroke:#c3c3c3;stroke-width:1.07903957;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none" />
<g
id="g3296">
<text
xml:space="preserve"
style="font-size:27.53050041px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="195.7585"
y="607.69037"
id="text4083"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan4085"
x="195.7585"
y="607.69037"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">DISCOUNT</tspan></text>
<image
y="584.09827"
x="385.72772"
id="image4202"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOYAAACYCAIAAAB/IAJdAAAAA3NCSVQICAjb4U/gAAADsElEQVR4 nO3aXXOiMACGUej4//8ye+EMZYHECBF96zlXHTd8iE8jYTtO0zQcMo7jMAz3zUs/b8ffLUcuXymN bHn92ZHtR3l2ZOnnpfazOvauS3toP3rLyPr5tGx1wM+ZjeF6kiWMZAkjWcJIljCSJYxkCSNZwkiW MJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCS JYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWM ZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJ I1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZ wkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJI ljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCjNM0 HdxyHIdhuG++/PmbuSZb3a+JWZYwH5fs/RfxL42kr9vuq6/4UmvZZ0qFZ3pdbVu5II0jSyezO777 0XdP4Fg549h0m7ozy75i/mjZZ0qFHXst7W0cx92RjZufPPrJkc+e1XKT3fe4sp5lr+81pb/zV2be wzyXzJ9TaXZZvl45gZbJqf3oZ0ZWBtdN0zTvrf6FvDPLvmKRa+E8W16K+nf36l+Xi+7XHf3kyIeD 6/tZpb/7Zv+bZd9yS9A4kQSN3FWaOe6zy3ZOumYhsT36s+fZ3eo3c3vE32TfteRi5cDlal8qvcKq qi4TX+U+4bb7ahd6fZfLrvwcVq+HBts9bMO9rUb0pdeOtiFWVj/v1fFz34Z7G46+yfrt+SdcuOu1 L1meUl+Qbc/h2Jr98IltHyMsD939mvy4Jfhk86p5tZquu+bKVxZqQ785a/Xc4PfGoPJA+OTfzfTd 5/dYfU5vPJN3Ka0p9//Dlvcq3Ql8j8pv7K3yNPvMM+Hu+0xXeq5ZuSwPr1Vp2931e+PRD5xnXw8f 2H3cX3L9ecuPpMu902on9Rn64dHbR5buWQ/Hvb1t3d2JG4PrlJ5itvzJ1e74px6Lth/9qfOsn2q7 9nt3s+ylSuvrMzts32f3kaWjH3hT901atv0Hm+wpnHOLKX0AAAAASUVORK5CYII= "
height="108.34499"
width="163.94308"
inkscape:transform-center-x="-24.4145"
inkscape:transform-center-y="6.3942733" />
<g
transform="translate(0,296.03285)"
id="g3210">
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="341.12738"
id="text3212"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3214"
x="154.5717"
y="341.12738"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">Prefix: 44</tspan></text>
<text
sodipodi:linespacing="125%"
id="text3216"
y="359.88428"
x="154.5717"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="359.88428"
x="154.5717"
id="tspan3218"
sodipodi:role="line">ID: 11111</tspan></text>
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="379.4567"
id="text3220"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3222"
x="154.5717"
y="379.4567"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">Value: 25%</tspan></text>
</g>
</g>
</g>
<g
transform="translate(0,-0.97866058)"
id="g3283">
<rect
style="fill:none;stroke:#c3c3c3;stroke-width:1.07903957;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
id="rect4115"
width="417.54495"
height="126.4052"
x="141.08452"
y="726.15521"
rx="2.0839903"
ry="2.0839903" />
<text
xml:space="preserve"
style="font-size:27.53050041px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="212.88437"
y="759.37659"
id="text4117"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan4119"
x="212.88437"
y="759.37659"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">PRICE</tspan></text>
<image
width="163.36363"
height="107.96206"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOYAAACYCAIAAAB/IAJdAAAAA3NCSVQICAjb4U/gAAAD70lEQVR4 nO3Z3XKbOhiGUezJ/d8yPfBsbwaB+Phz/aZrHaWukDB+goE8xnEcDnk8HsMwvDaf/tz+7/SVl3bR drbEkWvHZG3O/gytyvxrq6yt265emWfvyMq7K3qe2Rg+T7KEkSxhJEsYyRJGsoSRLGEkSxjJEkay hJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSR LGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxh JEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRL GMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJ EkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJG soSRLGEkSxjJEkayhJEsYSRLGMkSRrKEkSxhJEsYyRJGsoSRLGEkSxjJEkayhJEsYSRLmMc4jge3 fDyGYXhtPv35X+aYtC4/Js6yhJHsX/M65bDXz/un2RG85ButPufvG9lX6fXYWp0v37VFK4M/c0wq 2z4XV118Ze/yi3PWX6zP+W0jN21uVT9Q9Zl37Wr9nV57TCrv8We6xrvx9/bnz7XTGTp70w5bWz1l ZGvvZzmbdnO5yvyVXa33cGE54zi+Z+vfpT2n2yz+fED7Tqb/nB7ZxZ3rfE99/8jzdn19HxhTVO/h qnLGcZydERYPxXOt6DavA3twctv6aeP7Rw7/fSSzD6YzrDLn21U3c/UebiqnDXc24Ge4gYeRd9i8 Tt31pf/ytZ9U5zrhlmTPq/+Opow8pp2/jaze69r83xnu7Gz93tWPPpdtD9Dil8hiBykj79O5Wths bnp3cezC429prxOOn2V3XXSv3ZC1AzZ988gLb2HbSRbPiPXL6MUXL3w0VFn6klVuP8u+7/vWfrPb 19NH3qR+A7R3zm82e24wjuON17KzlfqD68cuZeTHrP3hY/jKva1bu1O8K9nNK4Hi5r9mZN0vqO28 zvnu53VBs/aHjZMH7uQ17uLzuS8f+UmL63YuedeeNszmLPZwUzmbj+Gei0NPnjzqO9056KEjr9JO fv4ksvbEY/Pd9d/pVeW0l63LO7b4+Oa9zeG1+wMWT2Cbq6eMrOj31zmAxS+uk/t/x294X/3O5/+z +oV/F9mVbLvJxh6HjOyrnDKPfSK7fhk6c94xsq/4rO0Pc0/7XuEpWE8AAAAASUVORK5CYII= "
id="image4264"
x="386.54324"
y="734.96906" />
<g
transform="translate(0,442.82599)"
id="g3224">
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="341.12738"
id="text3226"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3228"
x="154.5717"
y="341.12738"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">Prefix: 02</tspan></text>
<text
sodipodi:linespacing="125%"
id="text3230"
y="359.88428"
x="154.5717"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="359.88428"
x="154.5717"
id="tspan3232"
sodipodi:role="line">ID: 99999</tspan></text>
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="379.4567"
id="text3234"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3236"
x="154.5717"
y="379.4567"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">Value: 134.50€</tspan></text>
</g>
</g>
<g
id="g3269">
<g
id="g3061"
transform="translate(0,284.6156)">
<g
id="g3063"
transform="translate(0,154.94832)">
<rect
ry="2.0839903"
rx="2.0839903"
y="438.27753"
x="141.08452"
height="126.4052"
width="417.54495"
id="rect3065"
style="fill:none;stroke:#c3c3c3;stroke-width:1.07903957;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none" />
<text
sodipodi:linespacing="125%"
id="text3067"
y="471.49893"
x="216.61778"
style="font-size:27.53050041px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
xml:space="preserve"><tspan
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
y="471.49893"
x="216.61778"
sodipodi:role="line"
id="tspan3083">UNIT</tspan></text>
<g
transform="translate(0,156.57936)"
id="g3071" />
</g>
</g>
<image
y="887.47076"
x="386.54324"
id="image3146"
xlink:href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOYAAACYCAIAAAB/IAJdAAAAA3NCSVQICAjb4U/gAAADz0lEQVR4
nO3Z0ZKaMACGUdnx/V+ZXjBjGWKyEQjyt+fcdIsBY/ZTgZ3meX7sMk3T4/FYdq/9XI5frB9db18/
Wh6nfJZyr/Yz9s+t/Yp65tw/22+N3Pe6asevhdQ/stPPkZ3hepIljGQJI1nCSJYwkiWMZAkjWcJI
ljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYw
kiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIl
jGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxk
CSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkj
WcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nC
SJYwkiWMZAkjWcJIljCSJYxkCSNZwkiWMJIljGQJI1nCSJYwkiWMZAkjWcJIljCSJYxkCSNZwkzz
PO/cc5oej8ey+/rn/5k1KZ2+Jj5lCSNZwjyXf5ZP7NKJ32v9XwrtkZupNg743ZH3nNWgV3p8WZaD
9Oz4Uz7fCP1P0Rg5TVP5aG38d0fWfHFW/av36TofX5bXLm+PtvF8/TTuQuGUXl/W83y9zs3kX8d5
bb9yZM0dZtWzev0jy2f/9bA18zy/jtb+mr3oXLZ/9u3zgc2j7cOuH71+5K1m1b96B9d5+e+isUvt
OJv0336EDU/23I/Y0vruyfo45ZJdM7LmnrM6MnLQXbwy3M2AZ+2xU6Zy1iUXN7eO55RfYuM84Vnb
53hD1/R6wbXjP+z4d2Dt2ut4uJvP9ddhf9Zn0LvPQtrPesrIt19heu3Uv3r71nlEPOsjr2fyrF0t
/nrd1z7lH3cKe+dMj1+cjTbi91Jefi1XTsv209ekevl1w1OC8k084m39r+pfvY/WefT6b+4bzPNc
PZc95clqGzevs3/k2y30O/FUbbTa/YCByV7jzucJ9zf6FuRujVsQb/56sdnnrHfbwbOF2nwag7+1
ccfrGr2xf/XOWudye6dfb7b+vB13eq/HvZ1J+61f3ve+cuStZtW/emet845yytPW95NZ37PdOLfX
49dkH83zst/cR6v0xVn1r96gdW7r/2PE33tYI/76Vc7p+G2ED15b9ysaMfKes9q3emetc1vjjura
Hwkp3Xa7HcbMAAAAAElFTkSuQmCC
"
height="108.34499"
width="163.94308" />
<g
id="g3255"
transform="translate(0,598.58983)">
<text
xml:space="preserve"
style="font-size:17.41555405px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="154.5717"
y="351.81107"
id="text3261"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3263"
x="154.5717"
y="351.81107"
style="font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium">ID: 5449000000996</tspan></text>
</g>
</g>
<g
transform="matrix(0,-1,1,0,261.82237,1622.2884)"
id="g4150">
<text
xml:space="preserve"
style="font-size:8px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans"
x="618.97778"
y="320.0275"
id="text3357"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3359"
x="618.97778"
y="320.0275">This is a test sheet intended to help you test the codebar aquisition in OpenERP's Point of Sale module. </tspan><tspan
sodipodi:role="line"
x="618.97778"
y="330.0275"
id="tspan3363">The codes provided in this list are randomly chosen and are encoded in the EAN13 format. Their codes</tspan><tspan
sodipodi:role="line"
x="618.97778"
y="340.0275"
id="tspan3367">and prefixes are not intended to match any specified standard. </tspan></text>
<text
sodipodi:linespacing="125%"
id="text3369"
y="349.54001"
x="618.99207"
style="font-size:6.53564215px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#b3b3b3;fill-opacity:1;stroke:none;font-family:Droid Sans;-inkscape-font-specification:Droid Sans"
xml:space="preserve"><tspan
id="tspan3375"
y="349.54001"
x="618.99207"
sodipodi:role="line"
style="fill:#b3b3b3;fill-opacity:1">This document is licensed by OpenERP S.A. under the Creative Commons CC BY 3.0 license htttp://www.creativecommons.org</tspan></text>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 31 KiB

View File

@ -18,6 +18,10 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
import pdb
import io
import openerp
import addons
import time
from datetime import datetime
@ -33,18 +37,395 @@ import decimal_precision as dp
_logger = logging.getLogger(__name__)
class pos_config_journal(osv.osv):
""" Point of Sale journal configuration"""
_name = 'pos.config.journal'
_description = "Journal Configuration"
class pos_config(osv.osv):
_name = 'pos.config'
POS_CONFIG_STATE = [
('active', 'Active'),
('inactive', 'Inactive'),
('deprecated', 'Deprecated')
]
_columns = {
'name': fields.char('Description', size=64),
'code': fields.char('Code', size=64),
'journal_id': fields.many2one('account.journal', "Journal")
'name' : fields.char('Point of Sale Name', size=32, select=1,
required=True, help="An internal identification of the point of sale"),
'journal_ids' : fields.many2many('account.journal', 'pos_config_journal_rel',
'pos_config_id', 'journal_id', 'Available Payment Methods',
domain="[('journal_user', '=', True )]",),
'shop_id' : fields.many2one('sale.shop', 'Shop',
required=True),
'journal_id' : fields.many2one('account.journal', 'Sale Journal',
required=True, domain=[('type', '=', 'sale')],
help="Accounting journal used to post sales entries."),
'iface_self_checkout' : fields.boolean('Self Checkout Mode',
help="Check this if this point of sale should open by default in a self checkout mode. If unchecked, OpenERP uses the normal cashier mode by default."),
'iface_websql' : fields.boolean('WebSQL (Faster but Chrome Only)',
help="If have more than 200 products, it's highly suggested to use WebSQL "\
"to store the data in the browser, instead of localStore mechanism. "\
"It's more efficient but works on the Chrome browser only."
),
'iface_led' : fields.boolean('Help Notification'),
'iface_cashdrawer' : fields.boolean('Cashdrawer Interface'),
'iface_payment_terminal' : fields.boolean('Payment Terminal Interface'),
'iface_electronic_scale' : fields.boolean('Electronic Scale Interface'),
'iface_barscan' : fields.boolean('BarScan Interface'),
'iface_vkeyboard' : fields.boolean('Virtual KeyBoard Interface'),
'iface_print_via_proxy' : fields.boolean('Print via Proxy'),
'state' : fields.selection(POS_CONFIG_STATE, 'State', required=True, readonly=True),
'sequence_id' : fields.many2one('ir.sequence', 'Order IDs Sequence', readonly=True,
help="This sequence is automatically created by OpenERP but you can change it "\
"to customize the reference numbers of your orders."),
'session_ids': fields.one2many('pos.session', 'config_id', 'Sessions'),
'group_by' : fields.boolean('Group By', help="Check this if you want to group the Journal Items by Product while closing a Session"),
}
pos_config_journal()
def name_get(self, cr, uid, ids, context=None):
result = []
states = {
'opening_control': _('Opening Control'),
'opened': _('In Progress'),
'closing_control': _('Closing Control'),
'closed': _('Closed & Posted'),
}
for record in self.browse(cr, uid, ids, context=context):
if (not record.session_ids) or (record.session_ids[0].state=='closed'):
result.append((record.id, record.name+' ('+_('not used')+')'))
continue
session = record.session_ids[0]
result.append((record.id, record.name + ' ('+session.user_id.name+', '+states[session.state]+')'))
return result
def _default_payment_journal(self, cr, uid, context=None):
res = self.pool.get('account.journal').search(cr, uid, [('type', 'in', ('bank','cash'))], limit=2)
return res or []
def _default_sale_journal(self, cr, uid, context=None):
res = self.pool.get('account.journal').search(cr, uid, [('type', '=', 'sale')], limit=1)
return res and res[0] or False
def _default_shop(self, cr, uid, context=None):
res = self.pool.get('sale.shop').search(cr, uid, [])
return res and res[0] or False
_defaults = {
'state' : POS_CONFIG_STATE[0][0],
'shop_id': _default_shop,
'journal_id': _default_sale_journal,
'journal_ids': _default_payment_journal,
'group_by' : True,
}
def set_active(self, cr, uid, ids, context=None):
return self.write(cr, uid, ids, {'state' : 'active'}, context=context)
def set_inactive(self, cr, uid, ids, context=None):
return self.write(cr, uid, ids, {'state' : 'inactive'}, context=context)
def set_deprecate(self, cr, uid, ids, context=None):
return self.write(cr, uid, ids, {'state' : 'deprecated'}, context=context)
def create(self, cr, uid, values, context=None):
proxy = self.pool.get('ir.sequence')
sequence_values = dict(
name='PoS %s' % values['name'],
padding=5,
prefix="%s/" % values['name'],
)
sequence_id = proxy.create(cr, uid, sequence_values, context=context)
values['sequence_id'] = sequence_id
return super(pos_config, self).create(cr, uid, values, context=context)
def unlink(self, cr, uid, ids, context=None):
for obj in self.browse(cr, uid, ids, context=context):
if obj.sequence_id:
obj.sequence_id.unlink()
return super(pos_config, self).unlink(cr, uid, ids, context=context)
pos_config()
class pos_session(osv.osv):
_name = 'pos.session'
_order = 'id desc'
POS_SESSION_STATE = [
('opening_control', 'Opening Control'), # Signal open
('opened', 'In Progress'), # Signal closing
('closing_control', 'Closing Control'), # Signal close
('closed', 'Closed & Posted'),
]
def _compute_cash_register_id(self, cr, uid, ids, fieldnames, args, context=None):
result = dict.fromkeys(ids, False)
for record in self.browse(cr, uid, ids, context=context):
for st in record.statement_ids:
if st.journal_id.type == 'cash':
result[record.id] = st.id
break
return result
def _compute_controls(self, cr, uid, ids, fieldnames, args, context=None):
result = {}
for record in self.browse(cr, uid, ids, context=context):
has_opening_control = False
has_closing_control = False
for journal in record.config_id.journal_ids:
if journal.opening_control == True:
has_opening_control = True
if journal.closing_control == True:
has_closing_control = True
if has_opening_control and has_closing_control:
break
values = {
'has_opening_control': has_opening_control,
'has_closing_control': has_closing_control,
}
result[record.id] = values
return result
_columns = {
'config_id' : fields.many2one('pos.config', 'Point of Sale',
help="The physical point of sale you will use.",
required=True,
select=1,
domain="[('state', '=', 'active')]",
# readonly=True,
# states={'draft' : [('readonly', False)]}
),
'name' : fields.char('Session ID', size=32,
required=True,
# readonly=True,
# states={'draft' : [('readonly', False)]}
),
'user_id' : fields.many2one('res.users', 'Responsible',
required=True,
select=1,
# readonly=True,
# states={'draft' : [('readonly', False)]}
),
'start_at' : fields.datetime('Opening Date'),
'stop_at' : fields.datetime('Closing Date'),
'state' : fields.selection(POS_SESSION_STATE, 'State',
required=True, readonly=True,
select=1),
'cash_register_id' : fields.function(_compute_cash_register_id, method=True,
type='many2one', relation='account.bank.statement',
string='Cash Register', store=True),
'opening_details_ids' : fields.related('cash_register_id', 'opening_details_ids',
type='one2many', relation='account.cashbox.line',
string='Opening Cash Control'),
'details_ids' : fields.related('cash_register_id', 'details_ids',
type='one2many', relation='account.cashbox.line',
string='Cash Control'),
'cash_register_balance_end_real' : fields.related('cash_register_id', 'balance_end_real',
type='float',
digits_compute=dp.get_precision('Account'),
string="Ending Balance",
help="Computed using the cash control lines",
readonly=True),
'cash_register_balance_start' : fields.related('cash_register_id', 'balance_start',
type='float',
digits_compute=dp.get_precision('Account'),
string="Starting Balance",
help="Computed using the cash control at the opening.",
readonly=True),
'cash_register_total_entry_encoding' : fields.related('cash_register_id', 'total_entry_encoding',
string='Total Cash Transaction',
readonly=True),
'cash_register_balance_end' : fields.related('cash_register_id', 'balance_end',
type='float',
digits_compute=dp.get_precision('Account'),
string="Computed Balance",
help="Computed with the initial cash control and the sum of all payments.",
readonly=True),
'cash_register_difference' : fields.related('cash_register_id', 'difference',
type='float',
string='Difference',
help="Difference between the counted cash control at the closing and the computed balance.",
readonly=True),
'journal_ids' : fields.related('config_id', 'journal_ids',
type='many2many',
readonly=True,
relation='account.journal',
string='Available Payment Methods'),
'order_ids' : fields.one2many('pos.order', 'session_id', 'Orders'),
'statement_ids' : fields.one2many('account.bank.statement', 'pos_session_id', 'Bank Statement', readonly=True),
'has_opening_control' : fields.function(_compute_controls, string='Has Opening Control', multi='control', type='boolean'),
'has_closing_control' : fields.function(_compute_controls, string='Has Closing Control', multi='control', type='boolean'),
}
_defaults = {
'name' : '/',
'user_id' : lambda obj, cr, uid, context: uid,
'state' : 'opening_control',
}
_sql_constraints = [
('uniq_name', 'unique(name)', "The name of this POS Session must be unique !"),
]
def _check_unicity(self, cr, uid, ids, context=None):
for session in self.browse(cr, uid, ids, context=None):
# open if there is no session in 'opening_control', 'opened', 'closing_control' for one user
domain = [
('state', '!=', 'closed'),
('user_id', '=', uid)
]
count = self.search_count(cr, uid, domain, context=context)
if count>1:
return False
return True
def _check_pos_config(self, cr, uid, ids, context=None):
for session in self.browse(cr, uid, ids, context=None):
domain = [
('state', '!=', 'closed'),
('config_id', '=', session.config_id.id)
]
count = self.search_count(cr, uid, domain, context=context)
if count>1:
return False
return True
_constraints = [
(_check_unicity, "You can not create two active sessions with the same responsible!", ['user_id', 'state']),
(_check_pos_config, "You can not create two active sessions related to the same point of sale!", ['config_id']),
]
def create(self, cr, uid, values, context=None):
config_id = values.get('config_id', False) or False
pos_config = None
if config_id:
pos_config = self.pool.get('pos.config').browse(cr, uid, config_id, context=context)
bank_statement_ids = []
for journal in pos_config.journal_ids:
bank_values = {
'journal_id' : journal.id,
'user_id' : uid,
}
statement_id = self.pool.get('account.bank.statement').create(cr, uid, bank_values, context=context)
bank_statement_ids.append(statement_id)
values.update({
'name' : pos_config.sequence_id._next(),
'statement_ids' : [(6, 0, bank_statement_ids)]
})
return super(pos_session, self).create(cr, uid, values, context=context)
def unlink(self, cr, uid, ids, context=None):
for obj in self.browse(cr, uid, ids, context=context):
for statement in obj.statement_ids:
statement.unlink(context=context)
return True
def wkf_action_open(self, cr, uid, ids, context=None):
# si pas de date start_at, je balance une date, sinon on utilise celle de l'utilisateur
for record in self.browse(cr, uid, ids, context=context):
values = {}
if not record.start_at:
values['start_at'] = time.strftime('%Y-%m-%d %H:%M:%S')
values['state'] = 'opened'
record.write(values, context=context)
for st in record.statement_ids:
st.button_open(context=context)
return True
def wkf_action_opening_control(self, cr, uid, ids, context=None):
return self.write(cr, uid, ids, {'state' : 'opening_control'}, context=context)
def wkf_action_closing_control(self, cr, uid, ids, context=None):
for session in self.browse(cr, uid, ids, context=context):
for statement in session.statement_ids:
if not statement.journal_id.closing_control:
if statement.balance_end<>statement.balance_end_real:
self.pool.get('account.bank.statement').write(cr, uid,
[statement.id], {'balance_end_real': statement.balance_end})
return self.write(cr, uid, ids, {'state' : 'closing_control', 'stop_at' : time.strftime('%Y-%m-%d %H:%M:%S')}, context=context)
def wkf_action_close(self, cr, uid, ids, context=None):
# Close CashBox
bsl = self.pool.get('account.bank.statement.line')
for record in self.browse(cr, uid, ids, context=context):
for st in record.statement_ids:
if abs(st.difference) > st.journal_id.amount_authorized_diff:
# The pos manager can close statements with maximums.
if not self.pool.get('ir.model.access').check_groups(cr, uid, "point_of_sale.group_pos_manager"):
raise osv.except_osv( _('Error !'),
_("Your ending balance is too different from the theorical cash closing (%.2f), the maximum allowed is: %.2f. You can contact your manager to force it.") % (st.difference, st.journal_id.amount_authorized_diff))
if st.difference:
if st.difference > 0.0:
name= _('Point of Sale Profit')
account_id = st.journal_id.profit_account_id.id
else:
account_id = st.journal_id.loss_account_id.id
name= _('Point of Sale Loss')
if not account_id:
raise osv.except_osv( _('Error !'),
_("Please set your profit and loss accounts on your payment method '%s'.") % (st.journal_id.name,))
bsl.create(cr, uid, {
'statement_id': st.id,
'amount': st.difference,
'ref': record.name,
'name': name,
'account_id': account_id
}, context=context)
getattr(st, 'button_confirm_%s' % st.journal_id.type)(context=context)
self._confirm_orders(cr, uid, ids, context=context)
return self.write(cr, uid, ids, {'state' : 'closed'}, context=context)
def _confirm_orders(self, cr, uid, ids, context=None):
wf_service = netsvc.LocalService("workflow")
for session in self.browse(cr, uid, ids, context=context):
order_ids = [order.id for order in session.order_ids if order.state == 'paid']
move_id = self.pool.get('account.move').create(cr, uid, {'ref' : session.name, 'journal_id' : session.config_id.journal_id.id, }, context=context)
self.pool.get('pos.order')._create_account_move_line(cr, uid, order_ids, session, move_id, context=context)
for order in session.order_ids:
if order.state != 'paid':
raise osv.except_osv(
_('Error !'),
_("You can not confirm all orders of this session, because they have not the 'paid' status"))
else:
wf_service.trg_validate(uid, 'pos.order', order.id, 'done', cr)
return True
def open_frontend_cb(self, cr, uid, ids, context=None):
if not context:
context = {}
if not ids:
return {}
context.update({'session_id' : ids[0]})
return {
'type' : 'ir.actions.client',
'name' : 'Start Point Of Sale',
'tag' : 'pos.ui',
'context' : context,
}
pos_session()
class pos_order(osv.osv):
_name = "pos.order"
@ -53,25 +434,30 @@ class pos_order(osv.osv):
def create_from_ui(self, cr, uid, orders, context=None):
#_logger.info("orders: %r", orders)
list = []
for order in orders:
order_ids = []
for tmp_order in orders:
order = tmp_order['data']
# order :: {'name': 'Order 1329148448062', 'amount_paid': 9.42, 'lines': [[0, 0, {'discount': 0, 'price_unit': 1.46, 'product_id': 124, 'qty': 5}], [0, 0, {'discount': 0, 'price_unit': 0.53, 'product_id': 62, 'qty': 4}]], 'statement_ids': [[0, 0, {'journal_id': 7, 'amount': 9.42, 'name': '2012-02-13 15:54:12', 'account_id': 12, 'statement_id': 21}]], 'amount_tax': 0, 'amount_return': 0, 'amount_total': 9.42}
order_obj = self.pool.get('pos.order')
# get statements out of order because they will be generated with add_payment to ensure
# the module behavior is the same when using the front-end or the back-end
statement_ids = order.pop('statement_ids')
statement_ids = order.get('statement_ids', [])
order_id = self.create(cr, uid, order, context)
list.append(order_id)
order_ids.append(order_id)
# call add_payment; refer to wizard/pos_payment for data structure
# add_payment launches the 'paid' signal to advance the workflow to the 'paid' state
data = {
'journal': statement_ids[0][2]['journal_id'],
'amount': order['amount_paid'],
'payment_name': order['name'],
'payment_date': statement_ids[0][2]['name'],
}
order_obj.add_payment(cr, uid, order_id, data, context=context)
return list
wf_service = netsvc.LocalService("workflow")
wf_service.trg_validate(uid, 'pos.order', order_id, 'paid', cr)
wf_service.trg_write(uid, 'pos.order', order_id, cr)
#self.add_payment(cr, uid, order_id, data, context=context)
return order_ids
def unlink(self, cr, uid, ids, context=None):
for rec in self.browse(cr, uid, ids, context=context):
@ -107,14 +493,6 @@ class pos_order(osv.osv):
res[order.id]['amount_total'] = cur_obj.round(cr, uid, cur, val1)
return res
def _default_sale_journal(self, cr, uid, context=None):
res = self.pool.get('account.journal').search(cr, uid, [('type', '=', 'sale')], limit=1)
return res and res[0] or False
def _default_shop(self, cr, uid, context=None):
res = self.pool.get('sale.shop').search(cr, uid, [])
return res and res[0] or False
def copy(self, cr, uid, id, default=None, context=None):
if not default:
default = {}
@ -131,13 +509,11 @@ class pos_order(osv.osv):
return super(pos_order, self).copy(cr, uid, id, d, context=context)
_columns = {
'name': fields.char('Order Ref', size=64, required=True,
states={'draft': [('readonly', False)]}, readonly=True),
'name': fields.char('Order Ref', size=64, required=True, readonly=True),
'company_id':fields.many2one('res.company', 'Company', required=True, readonly=True),
'shop_id': fields.many2one('sale.shop', 'Shop', required=True,
states={'draft': [('readonly', False)]}, readonly=True),
'date_order': fields.datetime('Date Ordered', readonly=True, select=True),
'user_id': fields.many2one('res.users', 'Connected Salesman', help="Person who uses the the cash register. It could be a reliever, a student or an interim employee."),
'shop_id': fields.related('session_id', 'config_id', 'shop_id', relation='sale.shop', type='many2one', string='Shop', store=True, readonly=True),
'date_order': fields.datetime('Order Date', readonly=True, select=True),
'user_id': fields.many2one('res.users', 'Salesman', help="Person who uses the the cash register. It could be a reliever, a student or an interim employee."),
'amount_tax': fields.function(_amount_all, string='Taxes', digits_compute=dp.get_precision('Point Of Sale'), multi='all'),
'amount_total': fields.function(_amount_all, string='Total', multi='all'),
'amount_paid': fields.function(_amount_all, string='Paid', states={'draft': [('readonly', False)]}, readonly=True, digits_compute=dp.get_precision('Point Of Sale'), multi='all'),
@ -147,6 +523,13 @@ class pos_order(osv.osv):
'pricelist_id': fields.many2one('product.pricelist', 'Pricelist', required=True, states={'draft': [('readonly', False)]}, readonly=True),
'partner_id': fields.many2one('res.partner', 'Customer', change_default=True, select=1, states={'draft': [('readonly', False)], 'paid': [('readonly', False)]}),
'session_id' : fields.many2one('pos.session', 'Session',
#required=True,
select=1,
domain="[('state', '=', 'opened')]",
states={'draft' : [('readonly', False)]},
readonly=True),
'state': fields.selection([('draft', 'New'),
('cancel', 'Cancelled'),
('paid', 'Paid'),
@ -159,9 +542,15 @@ class pos_order(osv.osv):
'picking_id': fields.many2one('stock.picking', 'Picking', readonly=True),
'note': fields.text('Internal Notes'),
'nb_print': fields.integer('Number of Print', readonly=True),
'sale_journal': fields.many2one('account.journal', 'Journal', required=True, states={'draft': [('readonly', False)]}, readonly=True),
'sale_journal': fields.related('session_id', 'config_id', 'journal_id', relation='account.journal', type='many2one', string='Sale Journal', store=True, readonly=True),
}
def _default_session(self, cr, uid, context=None):
so = self.pool.get('pos.session')
session_ids = so.search(cr, uid, [('state','=', 'opened'), ('user_id','=',uid)], context=context)
return session_ids and session_ids[0] or False
def _default_pricelist(self, cr, uid, context=None):
res = self.pool.get('sale.shop').search(cr, uid, [], context=context)
if res:
@ -172,15 +561,18 @@ class pos_order(osv.osv):
_defaults = {
'user_id': lambda self, cr, uid, context: uid,
'state': 'draft',
'name': lambda obj, cr, uid, context: obj.pool.get('ir.sequence').get(cr, uid, 'pos.order'),
'name': '/',
'date_order': lambda *a: time.strftime('%Y-%m-%d %H:%M:%S'),
'nb_print': 0,
'session_id': _default_session,
'company_id': lambda self,cr,uid,c: self.pool.get('res.users').browse(cr, uid, uid, c).company_id.id,
'sale_journal': _default_sale_journal,
'shop_id': _default_shop,
'pricelist_id': _default_pricelist,
}
def create(self, cr, uid, values, context=None):
values['name'] = self.pool.get('ir.sequence').get(cr, uid, 'pos.order')
return super(pos_order, self).create(cr, uid, values, context=context)
def test_paid(self, cr, uid, ids, context=None):
"""A Point of Sale is paid when the sum
@return: True
@ -244,18 +636,6 @@ class pos_order(osv.osv):
picking_obj.force_assign(cr, uid, [picking_id], context)
return True
def set_to_draft(self, cr, uid, ids, *args):
if not len(ids):
return False
for order in self.browse(cr, uid, ids, context=context):
if order.state<>'cancel':
raise osv.except_osv(_('Error!'), _('In order to set to draft a sale, it must be cancelled.'))
self.write(cr, uid, ids, {'state': 'draft'})
wf_service = netsvc.LocalService("workflow")
for i in ids:
wf_service.trg_create(uid, 'pos.order', i, cr)
return True
def cancel_order(self, cr, uid, ids, context=None):
""" Changes order state to cancel
@return: True
@ -270,6 +650,8 @@ class pos_order(osv.osv):
def add_payment(self, cr, uid, order_id, data, context=None):
"""Create a new payment for the order"""
if not context:
context = {}
statement_obj = self.pool.get('account.bank.statement')
statement_line_obj = self.pool.get('account.bank.statement.line')
prod_obj = self.pool.get('product.product')
@ -277,11 +659,10 @@ class pos_order(osv.osv):
curr_c = self.pool.get('res.users').browse(cr, uid, uid, context=context).company_id
curr_company = curr_c.id
order = self.browse(cr, uid, order_id, context=context)
ids_new = []
args = {
'amount': data['amount'],
}
if 'payment_date' in data.keys():
if 'payment_date' in data:
args['date'] = data['payment_date']
args['name'] = order.name
if data.get('payment_name', False):
@ -298,22 +679,31 @@ class pos_order(osv.osv):
msg = _('There is no receivable account defined to make payment for the partner: "%s" (id:%d)') % (order.partner_id.name, order.partner_id.id,)
raise osv.except_osv(_('Configuration Error !'), msg)
statement_id = statement_obj.search(cr,uid, [
('journal_id', '=', int(data['journal'])),
('company_id', '=', curr_company),
('user_id', '=', uid),
('state', '=', 'open')], context=context)
if len(statement_id) == 0:
context.pop('pos_session_id', False)
try:
journal_id = long(data['journal'])
except Exception:
journal_id = False
statement_id = False
for statement in order.session_id.statement_ids:
if statement.journal_id.id == journal_id:
statement_id = statement.id
break
if not statement_id:
raise osv.except_osv(_('Error !'), _('You have to open at least one cashbox'))
if statement_id:
statement_id = statement_id[0]
args['statement_id'] = statement_id
args['pos_statement_id'] = order_id
args['journal_id'] = int(data['journal'])
args['type'] = 'customer'
args['ref'] = order.name
args.update({
'statement_id' : statement_id,
'pos_statement_id' : order_id,
'journal_id' : journal_id,
'type' : 'customer',
'ref' : order.name,
})
statement_line_obj.create(cr, uid, args, context=context)
ids_new.append(statement_id)
wf_service = netsvc.LocalService("workflow")
wf_service.trg_validate(uid, 'pos.order', order_id, 'paid', cr)
@ -432,49 +822,120 @@ class pos_order(osv.osv):
}
def create_account_move(self, cr, uid, ids, context=None):
return self._create_account_move_line(cr, uid, ids, None, None, context=context)
def _create_account_move_line(self, cr, uid, ids, session=None, move_id=None, context=None):
# Tricky, via the workflow, we only have one id in the ids variable
"""Create a account move line of order grouped by products or not."""
account_move_obj = self.pool.get('account.move')
account_move_line_obj = self.pool.get('account.move.line')
account_period_obj = self.pool.get('account.period')
period = account_period_obj.find(cr, uid, context=context)[0]
account_tax_obj = self.pool.get('account.tax')
res_obj=self.pool.get('res.users')
property_obj=self.pool.get('ir.property')
user_proxy = self.pool.get('res.users')
property_obj = self.pool.get('ir.property')
period = account_period_obj.find(cr, uid, context=context)[0]
#session_ids = set(order.session_id for order in self.browse(cr, uid, ids, context=context))
if session and not all(session.id == order.session_id.id for order in self.browse(cr, uid, ids, context=context)):
raise osv.except_osv(_('Error!'), _('The selected orders do not have the same session !'))
current_company = user_proxy.browse(cr, uid, uid, context=context).company_id
grouped_data = {}
have_to_group_by = session and session.config_id.group_by or False
def compute_tax(amount, tax, line):
if amount > 0:
tax_code_id = tax['base_code_id']
tax_amount = line.price_subtotal * tax['base_sign']
else:
tax_code_id = tax['ref_base_code_id']
tax_amount = line.price_subtotal * tax['ref_base_sign']
return (tax_code_id, tax_amount,)
for order in self.browse(cr, uid, ids, context=context):
if order.state<>'paid': continue
if order.account_move:
continue
if order.state != 'paid':
continue
user_company = user_proxy.browse(cr, order.user_id.id, order.user_id.id).company_id
curr_c = res_obj.browse(cr, uid, uid).company_id
comp_id = res_obj.browse(cr, order.user_id.id, order.user_id.id).company_id
comp_id = comp_id and comp_id.id or False
to_reconcile = []
group_tax = {}
account_def = property_obj.get(cr, uid, 'property_account_receivable', 'res.partner', context=context).id
order_account = order.partner_id and order.partner_id.property_account_receivable and order.partner_id.property_account_receivable.id or account_def or curr_c.account_receivable.id
order_account = order.partner_id and \
order.partner_id.property_account_receivable and \
order.partner_id.property_account_receivable.id or account_def or current_company.account_receivable.id
# Create an entry for the sale
move_id = account_move_obj.create(cr, uid, {
'journal_id': order.sale_journal.id,
}, context=context)
if move_id is None:
# Create an entry for the sale
move_id = account_move_obj.create(cr, uid, {
'ref' : order.name,
'journal_id': order.sale_journal.id,
}, context=context)
def insert_data(data_type, values):
# if have_to_group_by:
sale_journal_id = order.sale_journal.id
# 'quantity': line.qty,
# 'product_id': line.product_id.id,
values.update({
'date': order.date_order[:10],
'ref': order.name,
'journal_id' : sale_journal_id,
'period_id' : period,
'move_id' : move_id,
'company_id': user_company and user_company.id or False,
})
if data_type == 'product':
key = ('product', values['product_id'],)
elif data_type == 'tax':
key = ('tax', values['tax_code_id'],)
elif data_type == 'counter_part':
key = ('counter_part', values['partner_id'], values['account_id'])
else:
return
grouped_data.setdefault(key, [])
# if not have_to_group_by or (not grouped_data[key]):
# grouped_data[key].append(values)
# else:
# pass
if have_to_group_by:
if not grouped_data[key]:
grouped_data[key].append(values)
else:
current_value = grouped_data[key][0]
current_value['quantity'] = current_value.get('quantity', 0.0) + values.get('quantity', 0.0)
current_value['credit'] = current_value.get('credit', 0.0) + values.get('credit', 0.0)
current_value['debit'] = current_value.get('debit', 0.0) + values.get('debit', 0.0)
current_value['tax_amount'] = current_value.get('tax_amount', 0.0) + values.get('tax_amount', 0.0)
else:
grouped_data[key].append(values)
# Create an move for each order line
for line in order.lines:
tax_amount = 0
taxes = [t for t in line.product_id.taxes_id]
computed = account_tax_obj.compute_all(cr, uid, taxes, line.price_unit * (100.0-line.discount) / 100.0, line.qty)
computed_taxes = computed['taxes']
computed_taxes = account_tax_obj.compute_all(cr, uid, taxes, line.price_unit * (100.0-line.discount) / 100.0, line.qty)['taxes']
for tax in computed_taxes:
tax_amount += round(tax['amount'], 2)
group_key = (tax['tax_code_id'],
tax['base_code_id'],
tax['account_collected_id'])
group_key = (tax['tax_code_id'], tax['base_code_id'], tax['account_collected_id'], tax['id'])
group_tax.setdefault(group_key, 0)
group_tax[group_key] += round(tax['amount'], 2)
if group_key in group_tax:
group_tax[group_key] += round(tax['amount'], 2)
else:
group_tax[group_key] = round(tax['amount'], 2)
amount = line.price_subtotal
# Search for the income account
@ -492,110 +953,80 @@ class pos_order(osv.osv):
tax_amount = 0
while computed_taxes:
tax = computed_taxes.pop(0)
if amount > 0:
tax_code_id = tax['base_code_id']
tax_amount = line.price_subtotal * tax['base_sign']
else:
tax_code_id = tax['ref_base_code_id']
tax_amount = line.price_subtotal * tax['ref_base_sign']
tax_code_id, tax_amount = compute_tax(amount, tax, line)
# If there is one we stop
if tax_code_id:
break
# Create a move for the line
account_move_line_obj.create(cr, uid, {
'name': line.name,
'date': order.date_order[:10],
'ref': order.name,
insert_data('product', {
'name': line.product_id.name,
'quantity': line.qty,
'product_id': line.product_id.id,
'move_id': move_id,
'account_id': income_account,
'company_id': comp_id,
'credit': ((amount>0) and amount) or 0.0,
'debit': ((amount<0) and -amount) or 0.0,
'journal_id': order.sale_journal.id,
'period_id': period,
'tax_code_id': tax_code_id,
'tax_amount': tax_amount,
'partner_id': order.partner_id and order.partner_id.id or False
}, context=context)
})
# For each remaining tax with a code, whe create a move line
for tax in computed_taxes:
if amount > 0:
tax_code_id = tax['base_code_id']
tax_amount = line.price_subtotal * tax['base_sign']
else:
tax_code_id = tax['ref_base_code_id']
tax_amount = line.price_subtotal * tax['ref_base_sign']
tax_code_id, tax_amount = compute_tax(amount, tax, line)
if not tax_code_id:
continue
account_move_line_obj.create(cr, uid, {
'name': "Tax" + line.name,
'date': order.date_order[:10],
'ref': order.name,
insert_data('tax', {
'name': _('Tax'),
'product_id':line.product_id.id,
'quantity': line.qty,
'move_id': move_id,
'account_id': income_account,
'company_id': comp_id,
'credit': 0.0,
'debit': 0.0,
'journal_id': order.sale_journal.id,
'period_id': period,
'tax_code_id': tax_code_id,
'tax_amount': tax_amount,
}, context=context)
})
# Create a move for each tax group
(tax_code_pos, base_code_pos, account_pos)= (0, 1, 2)
for key, amount in group_tax.items():
account_move_line_obj.create(cr, uid, {
'name': 'Tax',
'date': order.date_order[:10],
'ref': order.name,
'move_id': move_id,
'company_id': comp_id,
(tax_code_pos, base_code_pos, account_pos, tax_id)= (0, 1, 2, 3)
for key, tax_amount in group_tax.items():
tax = self.pool.get('account.tax').browse(cr, uid, key[tax_id], context=context)
insert_data('tax', {
'name': _('Tax') + ' ' + tax.name,
'quantity': line.qty,
'product_id': line.product_id.id,
'account_id': key[account_pos],
'credit': ((amount>0) and amount) or 0.0,
'debit': ((amount<0) and -amount) or 0.0,
'journal_id': order.sale_journal.id,
'period_id': period,
'credit': ((tax_amount>0) and tax_amount) or 0.0,
'debit': ((tax_amount<0) and -tax_amount) or 0.0,
'tax_code_id': key[tax_code_pos],
'tax_amount': amount,
}, context=context)
'tax_amount': tax_amount,
})
# counterpart
to_reconcile.append(account_move_line_obj.create(cr, uid, {
'name': order.name,
'date': order.date_order[:10],
'ref': order.name,
'move_id': move_id,
'company_id': comp_id,
insert_data('counter_part', {
'name': _("Trade Receivables"), #order.name,
'account_id': order_account,
'credit': ((order.amount_total < 0) and -order.amount_total)\
or 0.0,
'debit': ((order.amount_total > 0) and order.amount_total)\
or 0.0,
'journal_id': order.sale_journal.id,
'period_id': period,
'credit': ((order.amount_total < 0) and -order.amount_total) or 0.0,
'debit': ((order.amount_total > 0) and order.amount_total) or 0.0,
'partner_id': order.partner_id and order.partner_id.id or False
}, context=context))
self.write(cr, uid, order.id, {'state':'done', 'account_move': move_id}, context=context)
})
order.write({'state':'done', 'account_move': move_id})
for group_key, group_data in grouped_data.iteritems():
for value in group_data:
account_move_line_obj.create(cr, uid, value, context=context)
return True
def action_payment(self, cr, uid, ids, context=None):
return self.write(cr, uid, ids, {'state': 'payment'}, context=context)
def action_paid(self, cr, uid, ids, context=None):
context = context or {}
self.create_picking(cr, uid, ids, context=None)
self.create_picking(cr, uid, ids, context=context)
self.write(cr, uid, ids, {'state': 'paid'}, context=context)
return True
@ -711,7 +1142,7 @@ pos_order_line()
class pos_category(osv.osv):
_name = 'pos.category'
_description = "PoS Category"
_description = "Point of Sale Category"
_order = "sequence, name"
def _check_recursion(self, cr, uid, ids, context=None):
level = 100
@ -743,13 +1174,43 @@ class pos_category(osv.osv):
res = self.name_get(cr, uid, ids, context=context)
return dict(res)
def _get_small_image(self, cr, uid, ids, prop, unknow_none, context=None):
result = {}
for obj in self.browse(cr, uid, ids, context=context):
if not obj.category_image:
result[obj.id] = False
continue
image_stream = io.BytesIO(obj.category_image.decode('base64'))
img = Image.open(image_stream)
img.thumbnail((120, 100), Image.ANTIALIAS)
img_stream = StringIO.StringIO()
img.save(img_stream, "JPEG")
result[obj.id] = img_stream.getvalue().encode('base64')
return result
_columns = {
'name': fields.char('Name', size=64, required=True, translate=True),
'complete_name': fields.function(_name_get_fnc, type="char", string='Name'),
'parent_id': fields.many2one('pos.category','Parent Category', select=True),
'child_id': fields.one2many('pos.category', 'parent_id', string='Children Categories'),
'sequence': fields.integer('Sequence', help="Gives the sequence order when displaying a list of product categories."),
'category_image': fields.binary('Image'),
'category_image_small': fields.function(_get_small_image, string='Small Image', type="binary",
store = {
'pos.category': (lambda self, cr, uid, ids, c={}: ids, ['category_image'], 10),
}),
}
def _get_default_image(self, cr, uid, context=None):
image_path = openerp.modules.get_module_resource('point_of_sale', 'images', 'default_category_photo.png')
return open(image_path, 'rb').read().encode('base64')
_defaults = {
'category_image': _get_default_image,
}
pos_category()
import io, StringIO
@ -772,15 +1233,20 @@ class product_product(osv.osv):
return result
_columns = {
'income_pdt': fields.boolean('PoS Cash Input', help="This is a product you can use to put cash into a statement for the point of sale backend."),
'expense_pdt': fields.boolean('PoS Cash Output', help="This is a product you can use to take cash from a statement for the point of sale backend, exemple: money lost, transfer to bank, etc."),
'pos_categ_id': fields.many2one('pos.category','PoS Category',
'income_pdt': fields.boolean('Point of Sale Cash In', help="This is a product you can use to put cash into a statement for the point of sale backend."),
'expense_pdt': fields.boolean('Point of Sale Cash Out', help="This is a product you can use to take cash from a statement for the point of sale backend, exemple: money lost, transfer to bank, etc."),
'pos_categ_id': fields.many2one('pos.category','Point of Sale Category',
help="If you want to sell this product through the point of sale, select the category it belongs to."),
'product_image_small': fields.function(_get_small_image, string='Small Image', type="binary",
store = {
'product.product': (lambda self, cr, uid, ids, c={}: ids, ['product_image'], 10),
})
}),
'to_weight' : fields.boolean('To Weight', help="This category contains products that should be weighted, mainly used for the self-checkout interface"),
}
_defaults = {
'to_weight' : False,
}
product_product()

View File

@ -3,15 +3,9 @@
<data>
<menuitem
id="stock.next_id_61"
name="Reporting"
parent="stock.menu_stock_root" groups="base.group_user"/>
<menuitem action="stock.action_picking_tree" id="stock.menu_action_picking_tree"
parent="stock.menu_stock_root" sequence="19" groups="res_groups_posuser0"/>
<menuitem parent="stock.next_id_61" action="stock.action_stock_line_date"
id="stock.menu_report_stock_line_date" groups="base.group_user"/>
<record model="pos.config" id="pos_config_main">
<field name="name">Main PoS</field>
</record>
</data>
</openerp>

Some files were not shown because too many files have changed in this diff Show More