[IMP+FIX] improvements patches from xrg
bzr revid: fp@tinyerp.com-20101017173000-m208j7b6kges3zlc
This commit is contained in:
parent
255eea5655
commit
ea969153db
|
@ -1215,7 +1215,8 @@ class account_move(osv.osv):
|
|||
#
|
||||
# TODO: Check if period is closed !
|
||||
#
|
||||
def create(self, cr, uid, vals, context={}):
|
||||
def create(self, cr, uid, vals, context=None):
|
||||
context = context or {}
|
||||
if 'line_id' in vals and context.get('copy'):
|
||||
for l in vals['line_id']:
|
||||
if not l[0]:
|
||||
|
@ -1256,6 +1257,7 @@ class account_move(osv.osv):
|
|||
return result
|
||||
|
||||
def copy(self, cr, uid, id, default={}, context={}):
|
||||
context = context or {}
|
||||
default.update({
|
||||
'state':'draft',
|
||||
'name':'/',
|
||||
|
@ -1265,7 +1267,8 @@ class account_move(osv.osv):
|
|||
})
|
||||
return super(account_move, self).copy(cr, uid, id, default, context)
|
||||
|
||||
def unlink(self, cr, uid, ids, context={}, check=True):
|
||||
def unlink(self, cr, uid, ids, context=None, check=True):
|
||||
context = context or {}
|
||||
toremove = []
|
||||
obj_move_line = self.pool.get('account.move.line')
|
||||
for move in self.browse(cr, uid, ids, context):
|
||||
|
|
|
@ -24,8 +24,6 @@ import time
|
|||
from osv import fields
|
||||
from osv import osv
|
||||
from tools.translate import _
|
||||
import tools
|
||||
from tools import config
|
||||
|
||||
class account_analytic_line(osv.osv):
|
||||
_inherit = 'account.analytic.line'
|
||||
|
@ -82,12 +80,13 @@ class account_analytic_line(osv.osv):
|
|||
return {}
|
||||
product_obj = self.pool.get('product.product')
|
||||
analytic_journal_obj =self.pool.get('account.analytic.journal')
|
||||
company_obj = self.pool.get('res.company')
|
||||
product_price_type_obj = self.pool.get('product.price.type')
|
||||
j_id = analytic_journal_obj.browse(cr, uid, journal_id, context=context)
|
||||
prod = product_obj.browse(cr, uid, prod_id)
|
||||
if not company_id:
|
||||
company_id = j_id.company_id.id
|
||||
result = 0.0
|
||||
is_purchase = False
|
||||
|
||||
if j_id.type <> 'sale':
|
||||
a = prod.product_tmpl_id.property_account_expense.id
|
||||
|
@ -99,8 +98,6 @@ class account_analytic_line(osv.osv):
|
|||
'for this product: "%s" (id:%d)') % \
|
||||
(prod.name, prod.id,))
|
||||
amount_unit = prod.price_get('standard_price', context)[prod.id]
|
||||
is_purchase = True
|
||||
|
||||
else:
|
||||
a = prod.product_tmpl_id.property_account_income.id
|
||||
if not a:
|
||||
|
@ -128,9 +125,8 @@ class account_analytic_line(osv.osv):
|
|||
if pricetype.field == 'list_price':
|
||||
flag = True
|
||||
amount_unit = prod.price_get(pricetype.field, context)[prod.id]
|
||||
amount = amount_unit*unit_amount or 1.0
|
||||
prec = self.pool.get('decimal.precision').precision_get(cr, uid, 'Account')
|
||||
amount = amount_unit*unit_amount or 1.0
|
||||
amount = amount_unit*unit or 1.0
|
||||
result = round(amount, prec)
|
||||
if not flag:
|
||||
result *= -1
|
||||
|
|
|
@ -351,7 +351,7 @@ class account_invoice(osv.osv):
|
|||
if view_type == 'tree':
|
||||
doc = etree.XML(res['arch'])
|
||||
nodes = doc.xpath("//field[@name='partner_id']")
|
||||
partner_string = 'Customer'
|
||||
partner_string = _('Customer')
|
||||
if context.get('type', 'out_invoice') in ('in_invoice', 'in_refund'):
|
||||
partner_string = _('Supplier')
|
||||
for node in nodes:
|
||||
|
@ -363,7 +363,7 @@ class account_invoice(osv.osv):
|
|||
try:
|
||||
res = super(account_invoice, self).create(cr, uid, vals, context)
|
||||
for inv_id, name in self.name_get(cr, uid, [res], context=context):
|
||||
message = _('Invoice ') + " '" + name + "' "+ _("is waiting for validation.")
|
||||
message = _("Invoice '%s' is waiting for validation.") % name
|
||||
self.log(cr, uid, inv_id, message)
|
||||
return res
|
||||
except Exception, e:
|
||||
|
@ -376,7 +376,7 @@ class account_invoice(osv.osv):
|
|||
def confirm_paid(self, cr, uid, ids, context=None):
|
||||
self.write(cr, uid, ids, {'state':'paid'}, context=context)
|
||||
for inv_id, name in self.name_get(cr, uid, ids, context=context):
|
||||
message = _('Invoice ') + " '" + name + "' "+ _("is paid.")
|
||||
message = _("Invoice '%s' is paid.") % name
|
||||
self.log(cr, uid, inv_id, message)
|
||||
return True
|
||||
|
||||
|
@ -1226,8 +1226,10 @@ class account_invoice(osv.osv):
|
|||
self.pool.get('account.move.line').reconcile(cr, uid, line_ids, 'manual', writeoff_acc_id, writeoff_period_id, writeoff_journal_id, context)
|
||||
else:
|
||||
code = invoice.currency_id.code
|
||||
amt = str(pay_amount) + code + ' on ' + str(invoice.amount_total) + code + ' (' + str(total) + code + ' remaining)'
|
||||
self.log(cr, uid, inv_id, _('Invoice ') + " '" + name + "' "+ _("is paid partially: ") + amt)
|
||||
# TODO: use currency's formatting function
|
||||
msg = _("Invoice '%s' is paid partially: %s%s of %s%s (%s%s remaining)") % \
|
||||
(name, pay_amount, code, invoice.amount_total, code, total, code)
|
||||
self.log(cr, uid, inv_id, msg)
|
||||
self.pool.get('account.move.line').reconcile_partial(cr, uid, line_ids, 'manual', context)
|
||||
|
||||
# Update the stored value (fields.function), so we write to trigger recompute
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
"access_account_chart_template","account.chart.template","model_account_chart_template","account.group_account_manager",1,1,1,1
|
||||
"access_account_tax_template","account.tax.template","model_account_tax_template","account.group_account_manager",1,1,1,1
|
||||
"access_account_bank_statement","account.bank.statement","model_account_bank_statement","account.group_account_user",1,0,0,0
|
||||
"access_account_bank_statement_line","account.bank.statement.line","model_account_bank_statement_line","account.group_account_user",1,0,0,0
|
||||
"access_account_bank_statement_line","account.bank.statement.line","model_account_bank_statement_line","account.group_account_user",1,1,1,1
|
||||
"access_account_analytic_line","account.analytic.line","model_account_analytic_line","account.group_account_user",1,1,1,1
|
||||
"access_account_analytic_line_manager","account.analytic.line manager","model_account_analytic_line","account.group_account_manager",1,0,0,0
|
||||
"access_account_analytic_account","account.analytic.account","analytic.model_account_analytic_account","base.group_user",1,0,0,0
|
||||
|
@ -94,11 +94,11 @@
|
|||
"access_account_move_line_manager","account.move.line manager","model_account_move_line","account.group_account_manager",1,0,0,0
|
||||
"access_account_move_manager","account.move manager","model_account_move","account.group_account_manager",1,0,0,0
|
||||
"access_account_invoice_manager","account.invoice manager","model_account_invoice","account.group_account_manager",1,0,0,0
|
||||
"access_account_bank_statement_manager","account.bank.statement manager","model_account_bank_statement","account.group_account_manager",1,0,0,0
|
||||
"access_account_bank_statement_manager","account.bank.statement manager","model_account_bank_statement","account.group_account_manager",1,1,1,1
|
||||
"access_account_entries_report_manager","account.entries.report","model_account_entries_report","account.group_account_manager",1,1,1,1
|
||||
"access_analytic_entries_report_manager","analytic.entries.report","model_analytic_entries_report","account.group_account_manager",1,0,0,0
|
||||
"access_account_cashbox_line","account.cashbox.line","model_account_cashbox_line","account.group_account_manager",1,0,0,0
|
||||
"access_account_cashbox_line","account.cashbox.line","model_account_cashbox_line","account.group_account_user",1,0,0,0
|
||||
"access_account_cashbox_line","account.cashbox.line","model_account_cashbox_line","account.group_account_manager",1,1,1,1
|
||||
"access_account_cashbox_line","account.cashbox.line","model_account_cashbox_line","account.group_account_user",1,1,1,1
|
||||
"access_account_journal_view_invoice","account.journal.view invoice","model_account_journal_view","account.group_account_invoice",1,1,1,1
|
||||
"access_account_journal_column_invoice","account.journal.column invoice","model_account_journal_column","account.group_account_invoice",1,1,1,1
|
||||
"access_account_invoice_tax_manager","account.invoice.tax manager","model_account_invoice_tax","account.group_account_manager",1,0,0,0
|
||||
|
|
|
|
@ -456,7 +456,7 @@ class audittrail_objects_proxy(osv_pool):
|
|||
"""
|
||||
Overrides Object Proxy execute method
|
||||
@param db: the current database
|
||||
@param uid: the current user’s ID for security checks,
|
||||
@param uid: the current user's ID for security checks,
|
||||
@param object: Object who's values are being changed
|
||||
@param method: get any method and create log
|
||||
|
||||
|
@ -500,35 +500,34 @@ class audittrail_objects_proxy(osv_pool):
|
|||
return self.log_fct(db, uid, model, method, fct_src, *args)
|
||||
|
||||
return fct_src(db, uid, model, method, *args)
|
||||
try:
|
||||
res = my_fct(db, uid, model, method, *args)
|
||||
cr.close()
|
||||
return res
|
||||
|
||||
finally:
|
||||
cr.close()
|
||||
|
||||
def exec_workflow(self, db, uid, model, method, *args, **argv):
|
||||
pool = pooler.get_pool(db)
|
||||
cr = pooler.get_db(db).cursor()
|
||||
cr.autocommit(True)
|
||||
logged_uids = []
|
||||
fct_src = super(audittrail_objects_proxy, self).exec_workflow
|
||||
field = method
|
||||
rule = False
|
||||
model_pool = pool.get('ir.model')
|
||||
rule_pool = pool.get('audittrail.rule')
|
||||
cr = pooler.get_db(db).cursor()
|
||||
cr.autocommit(True)
|
||||
try:
|
||||
model_ids = model_pool.search(cr, uid, [('model', '=', model)])
|
||||
for obj_name in pool.obj_list():
|
||||
if obj_name == 'audittrail.rule':
|
||||
rule = True
|
||||
if not rule:
|
||||
cr.close()
|
||||
return super(audittrail_objects_proxy, self).exec_workflow(db, uid, model, method, *args, **argv)
|
||||
if not model_ids:
|
||||
cr.close()
|
||||
return super(audittrail_objects_proxy, self).exec_workflow(db, uid, model, method, *args, **argv)
|
||||
|
||||
rule_ids = rule_pool.search(cr, uid, [('object_id', 'in', model_ids), ('state', '=', 'subscribed')])
|
||||
if not rule_ids:
|
||||
cr.close()
|
||||
return super(audittrail_objects_proxy, self).exec_workflow(db, uid, model, method, *args, **argv)
|
||||
|
||||
for thisrule in rule_pool.browse(cr, uid, rule_ids):
|
||||
|
@ -536,13 +535,12 @@ class audittrail_objects_proxy(osv_pool):
|
|||
logged_uids.append(user.id)
|
||||
if not logged_uids or uid in logged_uids:
|
||||
if thisrule.log_workflow:
|
||||
cr.close()
|
||||
return self.log_fct(db, uid, model, method, fct_src, *args)
|
||||
cr.close()
|
||||
return super(audittrail_objects_proxy, self).exec_workflow(db, uid, model, method, *args, **argv)
|
||||
|
||||
cr.close()
|
||||
return True
|
||||
finally:
|
||||
cr.close()
|
||||
|
||||
audittrail_objects_proxy()
|
||||
|
||||
|
|
|
@ -198,11 +198,12 @@ class crm_lead(crm_case, osv.osv):
|
|||
self.write(cr, uid, ids, value)
|
||||
|
||||
for case in self.browse(cr, uid, ids):
|
||||
n = {
|
||||
'lead': _('The lead'),
|
||||
'opportunity': _('The opportunity')
|
||||
}.get(case.type, _('The case'))
|
||||
message = n +" '" + case.name + "' "+ _("has been opened.")
|
||||
if case.type == 'lead':
|
||||
message = _("The lead '%s' has been opened.") % name
|
||||
elif case.type == 'opportunity':
|
||||
message = _("The opportunity '%s' has been opened.") % name
|
||||
else:
|
||||
message = _("The case '%s' has been opened.") % name
|
||||
self.log(cr, uid, case.id, message)
|
||||
return res
|
||||
|
||||
|
@ -217,11 +218,12 @@ class crm_lead(crm_case, osv.osv):
|
|||
res = super(crm_lead, self).case_close(cr, uid, ids, args)
|
||||
self.write(cr, uid, ids, {'date_closed': time.strftime('%Y-%m-%d %H:%M:%S')})
|
||||
for case in self.browse(cr, uid, ids):
|
||||
n = {
|
||||
'lead': _('The lead'),
|
||||
'opportunity': _('The opportunity')
|
||||
}.get(case.type, _('The case'))
|
||||
message = n +" '" + case.name + "' "+ _("has been closed.")
|
||||
if case.type == 'lead':
|
||||
message = _("The lead '%s' has been closed.") % name
|
||||
elif case.type == 'opportunity':
|
||||
message = _("The opportunity '%s' has been closed.") % name
|
||||
else:
|
||||
message = _("The case '%s' has been closed.") % name
|
||||
self.log(cr, uid, case.id, message)
|
||||
return res
|
||||
|
||||
|
|
|
@ -134,7 +134,7 @@ class crm_meeting(crm_case, osv.osv):
|
|||
"""
|
||||
res = super(crm_meeting, self).case_open(cr, uid, ids, args)
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('The meeting') + " '" + name + "' "+ _("has been confirmed.")
|
||||
message = _("The meeting '%s' has been confirmed.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
|
|
@ -70,7 +70,7 @@ class crm_opportunity(osv.osv):
|
|||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
opp = self.browse(cr, uid, id)
|
||||
if opp.type == 'opportunity':
|
||||
message = _('The opportunity') + " '" + name + "' "+ _("has been won.")
|
||||
message = _("The opportunity '%s' has been won.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
@ -94,7 +94,7 @@ class crm_opportunity(osv.osv):
|
|||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
opp = self.browse(cr, uid, id)
|
||||
if opp.type == 'opportunity':
|
||||
message = _('The opportunity') + " '" + name + "' "+ _("has been marked as lost.")
|
||||
message = _("The opportunity '%s' has been marked as lost.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
|
|
@ -71,8 +71,9 @@ class email_server(osv.osv):
|
|||
}
|
||||
|
||||
def check_duplicate(self, cr, uid, ids):
|
||||
# RFC *-* Why this limitation? why not in SQL constraint?
|
||||
vals = self.read(cr, uid, ids, ['user', 'password'])[0]
|
||||
cr.execute("select count(id) from email_server where user='%s' and password='%s'" % (vals['user'], vals['password']))
|
||||
cr.execute("select count(id) from email_server where user='%s' and password='%s'", (vals['user'], vals['password']))
|
||||
res = cr.fetchone()
|
||||
if res:
|
||||
if res[0] > 1:
|
||||
|
|
|
@ -407,7 +407,7 @@ class hr_applicant(crm.crm_case, osv.osv):
|
|||
if not date['date_open']:
|
||||
self.write(cr, uid, ids, {'date_open': time.strftime('%Y-%m-%d %H:%M:%S'),})
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('The job request ') + " '" + name + "' "+ _("has been set 'in progress'.")
|
||||
message = _("The job request '%s' has been set 'in progress'.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
@ -423,7 +423,7 @@ class hr_applicant(crm.crm_case, osv.osv):
|
|||
job_obj = self.pool.get('hr.job')
|
||||
res = super(hr_applicant, self).case_close(cr, uid, ids, *args)
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('Applicant ') + " '" + name + "' "+ _("is being hired.")
|
||||
message = _("Applicant '%s' is being hired.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
|
||||
applicant = self.browse(cr, uid, ids)[0]
|
||||
|
|
|
@ -45,7 +45,10 @@ class account_analytic_account(osv.osv):
|
|||
context = {}
|
||||
res = {}
|
||||
|
||||
cr.execute('select account_id as account_id, l.invoice_id from hr_analytic_timesheet h left join account_analytic_line l on (h.line_id=l.id)')
|
||||
cr.execute('SELECT account_id as account_id, l.invoice_id '
|
||||
'FROM hr_analytic_timesheet h LEFT JOIN account_analytic_line l '
|
||||
'ON (h.line_id=l.id) '
|
||||
'WHERE l.account_id = ANY(%s)', (ids,))
|
||||
account_to_invoice_map = {}
|
||||
for rec in cr.dictfetchall():
|
||||
account_to_invoice_map.setdefault(rec['account_id'], []).append(rec['invoice_id'])
|
||||
|
@ -163,6 +166,7 @@ class account_invoice(osv.osv):
|
|||
obj_analytic_account = self.pool.get('account.analytic.account')
|
||||
for il in iml:
|
||||
if il['account_analytic_id']:
|
||||
# *-* browse (or refactor to avoid read inside the loop)
|
||||
to_invoice = obj_analytic_account.read(cr, uid, [il['account_analytic_id']], ['to_invoice'])[0]['to_invoice']
|
||||
if to_invoice:
|
||||
il['analytic_lines'][0][2]['to_invoice'] = to_invoice[0]
|
||||
|
|
|
@ -43,7 +43,7 @@ class procurement_order(osv.osv):
|
|||
if not bom_id:
|
||||
cr.execute('update procurement_order set message=%s where id=%s', (_('No BoM defined for this product !'), procurement.id))
|
||||
for (id, name) in self.name_get(cr, uid, procurement.id):
|
||||
message = _('Procurement ') + " '" + name + "' "+ _("has an exception: 'No BoM defined for this product !'")
|
||||
message = _("Procurement '%s' has an exception: 'No BoM defined for this product !'") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return False
|
||||
return True
|
||||
|
|
|
@ -248,7 +248,7 @@ class project(osv.osv):
|
|||
task_obj.write(cr, uid, task_ids, {'state': 'done', 'date_end':time.strftime('%Y-%m-%d %H:%M:%S'), 'remaining_hours': 0.0})
|
||||
self.write(cr, uid, ids, {'state':'close'}, context=context)
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('The project ') + " '" + name + "' "+ _("has been closed.")
|
||||
message = _("The project '%s' has been closed.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return True
|
||||
|
||||
|
@ -270,7 +270,7 @@ class project(osv.osv):
|
|||
def reset_project(self, cr, uid, ids, context=None):
|
||||
res = self.setActive(cr, uid, ids, value=True, context=context)
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('The project ') + " '" + name + "' "+ _("has been opened.")
|
||||
message = _("The project '%s' has been opened.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
@ -732,7 +732,7 @@ class task(osv.osv):
|
|||
def do_pending(self, cr, uid, ids, *args):
|
||||
self.write(cr, uid, ids, {'state': 'pending'})
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('The task ') + " '" + name + "' "+ _("is pending.")
|
||||
message = _("The task '%s' is pending.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return True
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ class project_issue(crm.crm_case, osv.osv):
|
|||
res = super(project_issue, self).case_open(cr, uid, ids, *args)
|
||||
self.write(cr, uid, ids, {'date_open': time.strftime('%Y-%m-%d %H:%M:%S')})
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('Issue ') + " '" + name + "' "+ _("has been opened.")
|
||||
message = _("Issue '%s' has been opened.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
@ -73,7 +73,7 @@ class project_issue(crm.crm_case, osv.osv):
|
|||
|
||||
res = super(project_issue, self).case_close(cr, uid, ids, *args)
|
||||
for (id, name) in self.name_get(cr, uid, ids):
|
||||
message = _('Issue ') + " '" + name + "' "+ _("has been closed.")
|
||||
message = _("Issue '%s' has been closed.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return res
|
||||
|
||||
|
|
|
@ -330,7 +330,7 @@ class purchase_order(osv.osv):
|
|||
wf_service.trg_delete(uid, 'purchase.order', p_id, cr)
|
||||
wf_service.trg_create(uid, 'purchase.order', p_id, cr)
|
||||
for (id,name) in self.name_get(cr, uid, ids):
|
||||
message = _('Purchase order') + " '" + name + "' "+ _("has been set in draft state.")
|
||||
message = _("Purchase order '%s' has been set in draft state.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return True
|
||||
|
||||
|
@ -412,7 +412,7 @@ class purchase_order(osv.osv):
|
|||
wf_service.trg_validate(uid, 'account.invoice', inv.id, 'invoice_cancel', cr)
|
||||
self.write(cr,uid,ids,{'state':'cancel'})
|
||||
for (id,name) in self.name_get(cr, uid, ids):
|
||||
message = _('Purchase order ') + " '" + purchase.name + "' "+ _("is cancelled.")
|
||||
message = _("Purchase order '%s' is cancelled.") % name
|
||||
self.log(cr, uid, id, message)
|
||||
return True
|
||||
|
||||
|
|
|
@ -188,6 +188,7 @@ class product_product(osv.osv):
|
|||
if not ids:
|
||||
return res
|
||||
|
||||
# TODO: write in more ORM way, less queries, more pg84 magic
|
||||
if context.get('shop', False):
|
||||
cr.execute('select warehouse_id from sale_shop where id=%s', (int(context['shop']),))
|
||||
res2 = cr.fetchone()
|
||||
|
@ -246,6 +247,7 @@ class product_product(osv.osv):
|
|||
date_values = [to_date]
|
||||
|
||||
|
||||
# TODO: perhaps merge in one query.
|
||||
if date_values:
|
||||
where.append(tuple(date_values))
|
||||
if 'in' in what:
|
||||
|
|
|
@ -632,7 +632,7 @@ class stock_picking(osv.osv):
|
|||
'move_lines': fields.one2many('stock.move', 'picking_id', 'Internal Moves', states={'done': [('readonly', True)], 'cancel': [('readonly', True)]}),
|
||||
'auto_picking': fields.boolean('Auto-Picking'),
|
||||
'address_id': fields.many2one('res.partner.address', 'Address', help="Address of partner"),
|
||||
'partner_id': fields.related('address_id','partner_id',type='many2one',relation='res.partner',string='Partner',store=True),
|
||||
'partner_id': fields.related('address_id','partner_id',type='many2one',relation='res.partner',string='Partner'),
|
||||
'invoice_state': fields.selection([
|
||||
("invoiced", "Invoiced"),
|
||||
("2binvoiced", "To Be Invoiced"),
|
||||
|
|
|
@ -244,7 +244,7 @@
|
|||
</record>
|
||||
<record id="stock_warehouse_shop1" model="stock.warehouse">
|
||||
<field name="lot_output_id" ref="stock.stock_location_output"/>
|
||||
<field eval=""""Shop 2"""" name="name"/>
|
||||
<field name="name">Shop 2</field>
|
||||
<field name="lot_stock_id" ref="stock_location_shop1"/>
|
||||
<field name="partner_address_id" ref="res_partner_address_eric0"/>
|
||||
<field name="company_id" ref="res_company_tinyshop0"/>
|
||||
|
@ -262,9 +262,8 @@
|
|||
<field name="type">out</field>
|
||||
<field name="move_type">direct</field>
|
||||
<field name="invoice_state">2binvoiced</field>
|
||||
<field name="address_id" ref="base.main_address"/>
|
||||
<field name="address_id" ref="res_partner_address_fabien0"/>
|
||||
<field name="company_id" ref="base.main_company"/>
|
||||
<field name="partner_id" ref="base.main_partner"/>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
|
@ -204,6 +204,7 @@ class survey_browse_response(report_rml):
|
|||
rml += """<blockTable colWidths='""" + colwidth + """' style="Table_heading">
|
||||
<tr>
|
||||
<td><para style="terp_tblheader_General_Centre">Answer Create Date:- </para></td>
|
||||
# *-* formatting hard coded, breaks with utf8
|
||||
<td><para style="terp_tblheader_General_Centre_simple">""" + to_xml(time.strftime('%d-%m-%Y %I:%M:%S %p', time.strptime(response.date_create.split('.')[0], '%Y-%m-%d %H:%M:%S'))) + """</para></td>
|
||||
<td><para style="terp_tblheader_General_Centre"></para></td>
|
||||
<td><para style="terp_tblheader_General_right">Answer By:- </para></td>
|
||||
|
|
Loading…
Reference in New Issue