Fabien Pinckaers 2010-04-15 10:55:49 +02:00
commit d3286d8bad
32 changed files with 367 additions and 242 deletions

View File

@ -13,7 +13,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:49+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: account

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2010-02-20 16:07+0000\n"
"PO-Revision-Date: 2010-04-10 14:34+0000\n"
"Last-Translator: Grzegorz Grzelak (Cirrus.pl) <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 04:03+0000\n"
"X-Launchpad-Export-Date: 2010-04-11 04:14+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: account
@ -187,7 +187,7 @@ msgstr "Plan kont"
#. module: account
#: model:ir.actions.wizard,name:account.wizard_move_line_select
msgid "Move line select"
msgstr ""
msgstr "Wybór pozycji zapisów"
#. module: account
#: rml:account.journal.period.print:0
@ -533,7 +533,7 @@ msgstr "Uzgodnij zapłacone"
#. module: account
#: wizard_field:account.chart,init,target_move:0
msgid "Target Moves"
msgstr ""
msgstr "Zapisy docelowe"
#. module: account
#: model:ir.actions.act_window,name:account.action_account_tax_template_form
@ -776,7 +776,7 @@ msgstr "Płatność częściowa"
#. module: account
#: wizard_view:account_use_models,create:0
msgid "Move Lines Created."
msgstr "Utworzono pozycje zmian."
msgstr "Utworzono pozycje zapisów."
#. module: account
#: field:account.fiscalyear,state:0
@ -823,7 +823,7 @@ msgstr "(Pozostaw puste dla wszystkich otwartych lat podatkowych)"
#. module: account
#: field:account.invoice,move_lines:0
msgid "Move Lines"
msgstr "Pozycje zmian"
msgstr "Pozycje zapisów"
#. module: account
#: model:ir.model,name:account.model_account_config_wizard
@ -1562,7 +1562,7 @@ msgstr "Szablony planu kont"
#. module: account
#: field:account.invoice,move_id:0
msgid "Invoice Movement"
msgstr ""
msgstr "Zapisy faktury"
#. module: account
#: model:ir.actions.act_window,name:account.action_wizard_multi_chart
@ -1808,7 +1808,7 @@ msgstr "Procentowo"
#. module: account
#: model:ir.ui.menu,name:account.menu_finance_charts
msgid "Charts"
msgstr "Wykresy"
msgstr "Plany kont"
#. module: account
#: selection:account.analytic.journal,type:0
@ -2051,9 +2051,9 @@ msgid ""
"'draft' state and instead goes directly to the 'posted state' without any "
"manual validation."
msgstr ""
"Zaznacz to pole, jeśli nie chcesz aby nowe zmiany stanu konta przechodziły "
"przez stan 'projekt' i zamiast tego od razu wchodziły w stan 'zaksięgowane' "
"bez żadnego ręcznego zatwierdzania."
"Zaznacz to pole, jeśli nie chcesz aby nowe zapisy konta przechodziły przez "
"stan 'projekt' i zamiast tego od razu wchodziły w stan 'zaksięgowane' bez "
"żadnego ręcznego zatwierdzania."
#. module: account
#: field:account.bank.statement.line,partner_id:0
@ -2114,7 +2114,7 @@ msgstr ""
#: model:ir.actions.wizard,name:account.wizard_validate_account_moves_line
#: model:ir.ui.menu,name:account.menu_validate_account_moves
msgid "Validate Account Moves"
msgstr "Zatwierdź zmiany konta"
msgstr "Zatwierdź zapisy konta"
#. module: account
#: selection:account.subscription,period_type:0
@ -2415,7 +2415,7 @@ msgstr "Konto podatkowe"
#. module: account
#: field:account.analytic.line,move_id:0
msgid "Move Line"
msgstr "Przesuń pozycję"
msgstr "Pozycja zapisu"
#. module: account
#: field:account.bank.accounts.wizard,acc_no:0
@ -2868,7 +2868,7 @@ msgstr "ID partnera"
#: wizard_view:account.invoice.pay,addendum:0
#: wizard_view:account.move.line.reconcile,addendum:0
msgid "Write-Off Move"
msgstr "Zmiana odpisu"
msgstr "Zapis odpisu"
#. module: account
#: view:account.move.line:0
@ -3072,7 +3072,7 @@ msgstr "Dokument"
#. module: account
#: help:account.move.line,move_id:0
msgid "The move of this entry line."
msgstr "Zmiana tej pozycji zapisu"
msgstr "Zapis dla tej pozycji."
#. module: account
#: field:account.invoice.line,uos_id:0
@ -3240,8 +3240,7 @@ msgstr "Uwagi"
msgid ""
"The account moves of the invoice have been reconciled with account moves of "
"the payment(s)."
msgstr ""
"Zmiany konta dla faktury zostały uzgodnione ze zmianami konta płatności."
msgstr "Zapisy konta dla faktury zostały uzgodnione ze zapisami płatności."
#. module: account
#: rml:account.invoice:0
@ -3357,7 +3356,7 @@ msgstr "Nie drukowane na fakturze"
#. module: account
#: field:account.move.line,move_id:0
msgid "Move"
msgstr "Zmiana stanu"
msgstr "Zapis"
#. module: account
#: field:account.fiscal.position.tax,tax_src_id:0
@ -4080,7 +4079,7 @@ msgstr "Kody podrzędne"
#. module: account
#: field:account.invoice,move_name:0
msgid "Account Move"
msgstr "Zmiana stanu konta"
msgstr "Zapis konta"
#. module: account
#: view:account.bank.statement:0
@ -4650,7 +4649,7 @@ msgstr "Wyciąg"
#: model:ir.actions.act_window,name:account.action_move_line_form_encode_by_move
#: model:ir.ui.menu,name:account.menu_encode_entries_by_move
msgid "Entries Encoding by Move"
msgstr "Wprowadzanie zapisów przez zmianę stanu"
msgstr "Zapisy"
#. module: account
#: wizard_view:account.analytic.account.chart,init:0
@ -5042,7 +5041,7 @@ msgstr "Opis podatku"
#. module: account
#: help:account.invoice,move_id:0
msgid "Link to the automatically generated account moves."
msgstr "Łącznik do automatycznie wygenerowanych zmian stanu konta."
msgstr "Łącznik do automatycznie wygenerowanych zapisów konta."
#. module: account
#: wizard_field:account.automatic.reconcile,reconcile,reconciled:0
@ -5111,7 +5110,7 @@ msgstr "Konto dochodu w szablonie produktu"
#: help:account.account,currency_id:0
#: help:account.account.template,currency_id:0
msgid "Force all moves for this account to have this secondary currency."
msgstr "Wymuś, aby wszystkie zmiany tego konta miały tę dodatkową walutę."
msgstr "Wymuś, aby wszystkie zapisy tego konta miały tę dodatkową walutę."
#. module: account
#: wizard_button:populate_statement_from_inv,go,end:0
@ -5605,7 +5604,7 @@ msgstr "Zamknięte"
#. module: account
#: field:account.bank.statement.line,move_ids:0
msgid "Moves"
msgstr "Zmiany stanu"
msgstr "Zapisy"
#. module: account
#: selection:account.invoice,state:0

View File

@ -9,10 +9,10 @@
<field name="arch" type="xml">
<notebook position="inside">
<page string="Accounting">
<separator string="Sales Properties" colspan="2"/>
<separator string="Purchase Properties" colspan="2"/>
<field name="property_account_income" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" attrs="{'readonly':[('sale_ok','=',0)]}" />
<field name="property_account_expense" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" attrs="{'readonly':[('purchase_ok','=',0)]}" />
<separator string="Sales Properties" colspan="2" groups="base.group_extended"/>
<separator string="Purchase Properties" colspan="2" groups="base.group_extended"/>
<field name="property_account_income" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" attrs="{'readonly':[('sale_ok','=',0)]}" groups="base.group_extended"/>
<field name="property_account_expense" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" attrs="{'readonly':[('purchase_ok','=',0)]}" groups="base.group_extended"/>
<separator string="Sale Taxes" colspan="2"/>
<separator string="Purchase Taxes" colspan="2"/>

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.6\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2010-03-19 10:22+0000\n"
"Last-Translator: Black Jack <onetimespeed@hotmail.com>\n"
"PO-Revision-Date: 2010-04-10 04:39+0000\n"
"Last-Translator: digitalsatori <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 04:07+0000\n"
"X-Launchpad-Export-Date: 2010-04-11 04:14+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: account_analytic_analysis
@ -52,12 +52,12 @@ msgstr "所有辅助核算项目"
#: model:ir.actions.act_window,name:account_analytic_analysis.action_account_analytic_managed_open
#: model:ir.ui.menu,name:account_analytic_analysis.menu_analytic_account_to_valid_open
msgid "My Current Accounts"
msgstr "我当前的项目"
msgstr "我的当前科目"
#. module: account_analytic_analysis
#: constraint:ir.ui.view:0
msgid "Invalid XML for View Architecture!"
msgstr "无效XML视图结构!"
msgstr "描述视图结构的XML文件无效"
#. module: account_analytic_analysis
#: help:account.analytic.account,last_invoice_date:0
@ -72,12 +72,12 @@ msgstr "理论收入"
#. module: account_analytic_analysis
#: constraint:ir.actions.act_window:0
msgid "Invalid model name in the action definition."
msgstr "在这动作定义中有无效的模块名"
msgstr "在动作定义中输入的对象名称错误"
#. module: account_analytic_analysis
#: help:account.analytic.account,theorical_margin:0
msgid "Computed using the formula: Theorial Revenue - Total Costs"
msgstr "计算公式为:收入 - 总成本"
msgstr "计算公式:理论收入 - 总费用"
#. module: account_analytic_analysis
#: constraint:ir.model:0
@ -89,7 +89,7 @@ msgstr "对象名必须要以X_开头并且不能含有特殊字符!"
#: model:ir.actions.act_window,name:account_analytic_analysis.action_account_analytic_new
#: model:ir.ui.menu,name:account_analytic_analysis.menu_action_account_analytic_new
msgid "New Analytic Account"
msgstr "新的辅助核算项目"
msgstr "新的分析科目"
#. module: account_analytic_analysis
#: field:account.analytic.account,theorical_margin:0
@ -105,7 +105,7 @@ msgstr "实际利润(%)"
#: model:ir.actions.act_window,name:account_analytic_analysis.action_account_analytic_all_open
#: model:ir.ui.menu,name:account_analytic_analysis.menu_action_account_analytic_all_open
msgid "Current Analytic Accounts"
msgstr "当前辅助核算项目"
msgstr "当前分析科目"
#. module: account_analytic_analysis
#: help:account.analytic.account,last_worked_date:0

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2009-11-17 09:23+0000\n"
"Last-Translator: Ferdinand-chricar <Unknown>\n"
"PO-Revision-Date: 2010-04-09 13:20+0000\n"
"Last-Translator: Ferdinand @ ChriCar <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 04:01+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:48+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: account_tax_include
@ -49,4 +49,4 @@ msgstr "Berechnungsgrundlage (inkl. Steuer)"
#. module: account_tax_include
#: field:account.invoice.line,price_subtotal_incl:0
msgid "Subtotal"
msgstr "Zwischenbetrag"
msgstr "Zwischensumme"

View File

@ -8,19 +8,19 @@ msgstr ""
"Project-Id-Version: openobject-addons\n"
"Report-Msgid-Bugs-To: FULL NAME <EMAIL@ADDRESS>\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2009-11-09 16:43+0000\n"
"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
"PO-Revision-Date: 2010-04-09 18:42+0000\n"
"Last-Translator: Frankenstein <Unknown>\n"
"Language-Team: Italian <it@li.org>\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 04:15+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:49+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: base_module_quality
#: field:module.quality.check,final_score:0
msgid "Final Score (%)"
msgstr ""
msgstr "Punteggio Finale (%)"
#. module: base_module_quality
#: constraint:ir.model:0
@ -71,6 +71,8 @@ msgid ""
"Some tests are more critical than others, so they have a bigger weight in "
"the computation of final rating"
msgstr ""
"Alcuni test sono più cruciali di altri, quindi avranno un peso maggiore nel "
"calcolo del punteggio finale"
#. module: base_module_quality
#: view:module.quality.check:0

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:48+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: base_setup

0
addons/crm/crm_claim.py Executable file → Normal file
View File

0
addons/crm/crm_claims_data.xml Executable file → Normal file
View File

0
addons/crm/crm_claims_demo.xml Executable file → Normal file
View File

0
addons/crm/crm_claims_menu.xml Executable file → Normal file
View File

0
addons/crm/crm_claims_view.xml Executable file → Normal file
View File

0
addons/crm/crm_meeting_view.xml Executable file → Normal file
View File

View File

@ -71,7 +71,7 @@ def html2plaintext(html, body_id=None, encoding='utf-8'):
for url in [x[1] for x in link.attrs if x[0]=='href']:
urls.append(dict(url=url, tag=str(link), title=title))
html = soup.__str__()
html = unicode(soup)
url_index = []
i = 0

View File

@ -300,6 +300,24 @@ class hr_evaluation_interview(osv.osv):
self.write(cr, uid, ids, { 'state' : 'cancel'}, context=context)
return True
def action_print_survey(self, cr, uid, ids, context=None):
"""
If response is available then print this response otherwise print survey form(print template of the survey).
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Survey IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for print survey form.
"""
if not context:
context = {}
record = self.browse(cr, uid, ids, context)
record = record and record[0]
context.update({'survey_id': record.survey_id.id, 'response_id' : [record.response.id], 'response_no':0,})
value = self.pool.get("survey").action_print_survey(cr, uid, ids, context)
return value
hr_evaluation_interview()
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:1

View File

@ -261,8 +261,8 @@
<group colspan="1">
<button name="%(survey.action_view_survey_question_message)d" string="Interview Question" type="action" states="waiting_answer,done,cancel"
icon="gtk-execute" context="{'survey_id': survey_id, 'response_id': [response], 'response_no':0, 'active' : response,'request' : True, 'object' : 'hr.evaluation.interview', 'cur_id' : active_id}" attrs="{'readonly':[('survey_id','=',False)]}"/>
<button name="%(survey.survey_browse_response)d" string="Print Interview" type="action" states="done"
icon="gtk-print" context="{'survey_id': survey_id, 'response_id' : [response], 'response_no':0,}" attrs="{'readonly':[('response','=',False)]}" />
<button name="action_print_survey" string="Print Interview" type="object" states="waiting_answer,done,cancel"
icon="gtk-print" attrs="{'readonly':[('survey_id','=',False)]}" />
</group>
</group>
<group col="4" colspan="4">
@ -297,8 +297,8 @@
<field name="response" readonly="1" invisible="True"/>
<button name="%(survey.action_view_survey_question_message)d" string="Interview Question" type="action" states="waiting_answer,done,cancel"
icon="gtk-execute" context="{'survey_id': survey_id, 'response_id': [response], 'response_no':0, 'active' : response, 'request' : True, 'object' : 'hr.evaluation.interview', 'cur_id' : active_id}" attrs="{'readonly':[('survey_id','=',False)]}"/>
<button name="%(survey.survey_browse_response)d" string="Print Interview" type="action" states="done"
icon="gtk-print" context="{'survey_id': survey_id, 'response_id' : [response], 'response_no':0}" attrs="{'readonly':[('response','=',False)]}" />
<button name="action_print_survey" string="Print Interview" type="object" states="waiting_answer,done,cancel"
icon="gtk-print" attrs="{'readonly':[('survey_id','=',False)]}"/>
<field name="state"/>
</tree>
</field>
@ -311,9 +311,9 @@
<field name="arch" type="xml">
<search string="Search Evaluation">
<group col='10' colspan='4'>
<filter icon="terp-crm" string="To Do" domain="[('state','=','waiting_answer')]" default="1"/>
<filter icon="terp-crm" string="To Do" name="todo" domain="[('state','=','waiting_answer')]"/>
<separator orientation="vertical"/>
<filter string="My" icon="terp-partner" domain="[('user_id','=',uid)]" default="1"/>
<filter string="My" icon="terp-partner" name="my" domain="[('user_id','=',uid)]"/>
<separator orientation="vertical"/>
<filter icon="terp-stock" string="Late" domain="[('date_deadline','&lt;',current_date)]"/>
<separator orientation="vertical"/>
@ -329,6 +329,7 @@
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="domain">[('is_evaluation' ,'=', True)]</field>
<field name="context">{"search_default_todo":1,"search_default_my":1}</field>
<field name="search_view_id" ref="view_hr_evaluation_interview_search"/>
</record>

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2009-11-22 19:07+0000\n"
"PO-Revision-Date: 2010-04-09 12:59+0000\n"
"Last-Translator: Ferdinand @ ChriCar <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 04:10+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:49+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: hr_expense
@ -508,7 +508,7 @@ msgstr "Der Vorgesetzte akzeptiert die Ausgabenliste"
#. module: hr_expense
#: field:hr.expense.line,sequence:0
msgid "Sequence"
msgstr "Sequenzer"
msgstr "Sequenz"
#. module: hr_expense
#: model:process.transition,note:hr_expense.process_transition_confirmexpense0
@ -524,7 +524,7 @@ msgstr "Spesenerfassung"
#. module: hr_expense
#: field:hr.expense.line,total_amount:0
msgid "Total"
msgstr "Betrag gesammt"
msgstr "Betrag gesamt"
#. module: hr_expense
#: model:process.node,name:hr_expense.process_node_reinvoicing0

View File

@ -20,6 +20,7 @@
##############################################################################
from osv import fields,osv,orm
from tools.translate import _
AVAILABLE_STATES = [
('draft','New'),
@ -54,13 +55,121 @@ class hr_applicant(osv.osv):
'partner_name': fields.char("Applicant's Name", size=64),
'partner_phone': fields.char('Phone', size=32),
'partner_mobile': fields.char('Mobile', size=32),
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('section_id','=',section_id),('object_id.model', '=', 'hr.applicant')]"),
'type_id': fields.many2one('crm.case.resource.type', 'Degree', domain="[('section_id','=',section_id),('object_id.model', '=', 'hr.applicant')]"),
'stage_id': fields.many2one ('crm.case.stage', 'Stage', domain="[('object_id.model', '=', 'hr.applicant')]"),
'type_id': fields.many2one('crm.case.resource.type', 'Degree', domain="[('object_id.model', '=', 'hr.applicant')]"),
'department_id':fields.many2one('hr.department','Department'),
'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True),
'survey' : fields.related('job_id', 'survey_id', type='many2one', relation='survey', string='Survey'),
'response' : fields.integer("Response"),
}
def stage_previous(self, cr, uid, ids, context=None):
"""This function computes previous stage for case from its current stage
using available stage for that case type
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of case IDs
@param context: A standard dictionary for contextual values"""
if not context:
context = {}
for case in self.browse(cr, uid, ids, context):
section = (case.section_id.id or False)
st = case.stage_id.id or False
stage_ids = self.pool.get('crm.case.stage').search(cr, uid, [])
if st and stage_ids.index(st):
self.write(cr, uid, [case.id], {'stage_id': stage_ids[stage_ids.index(st)-1]})
return True
def stage_next(self, cr, uid, ids, context=None):
"""This function computes next stage for case from its current stage
using available stage for that case type
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of case IDs
@param context: A standard dictionary for contextual values"""
if not context:
context = {}
for case in self.browse(cr, uid, ids, context):
section = (case.section_id.id or False)
st = case.stage_id.id or False
stage_ids = self.pool.get('crm.case.stage').search(cr, uid, [])
if st and len(stage_ids) != stage_ids.index(st)+1:
self.write(cr, uid, [case.id], {'stage_id': stage_ids[stage_ids.index(st)+1]})
return True
def action_makeMeeting(self, cr, uid, ids, context=None):
"""
This opens Meeting's calendar view to schedule meeting on current Opportunity
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Opportunity to Meeting IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for created Meeting view
"""
value = {}
for opp in self.browse(cr, uid, ids):
data_obj = self.pool.get('ir.model.data')
# Get meeting views
result = data_obj._get_id(cr, uid, 'crm', 'view_crm_case_meetings_filter')
res = data_obj.read(cr, uid, result, ['res_id'])
id1 = data_obj._get_id(cr, uid, 'crm', 'crm_case_calendar_view_meet')
id2 = data_obj._get_id(cr, uid, 'crm', 'crm_case_form_view_meet')
id3 = data_obj._get_id(cr, uid, 'crm', 'crm_case_tree_view_meet')
if id1:
id1 = data_obj.browse(cr, uid, id1, context=context).res_id
if id2:
id2 = data_obj.browse(cr, uid, id2, context=context).res_id
if id3:
id3 = data_obj.browse(cr, uid, id3, context=context).res_id
context = {
'default_opportunity_id': opp.id,
'default_partner_id': opp.partner_id and opp.partner_id.id or False,
'default_section_id': opp.section_id and opp.section_id.id or False,
'default_email_from': opp.email_from,
'default_state': 'open',
'default_name': opp.name
}
value = {
'name': _('Meetings'),
'domain': "[('user_id','=',%s)]" % (uid),
'context': context,
'view_type': 'form',
'view_mode': 'calendar,form,tree',
'res_model': 'crm.meeting',
'view_id': False,
'views': [(id1, 'calendar'), (id2, 'form'), (id3, 'tree')],
'type': 'ir.actions.act_window',
'search_view_id': res['res_id'],
'nodestroy': True
}
return value
def action_print_survey(self, cr, uid, ids, context=None):
"""
If response is available then print this response otherwise print survey form(print template of the survey).
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Survey IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for print survey form.
"""
if not context:
context = {}
record = self.browse(cr, uid, ids, context)
record = record and record[0]
context.update({'survey_id': record.survey.id, 'response_id' : [record.response], 'response_no':0,})
value = self.pool.get("survey").action_print_survey(cr, uid, ids, context)
return value
hr_applicant()
class hr_job(osv.osv):
@ -70,4 +179,4 @@ class hr_job(osv.osv):
'survey_id': fields.many2one('survey', 'Survey'),
}
hr_job()
hr_job()

View File

@ -43,8 +43,8 @@
<field name="partner_phone"/>
<field name="job_id"/>
<field name="stage_id"/>
<button name="stage_previous" string="Previous" states="open,pending" type="object" icon="gtk-go-back"/>
<button name="stage_next" string="Next" states="open,pending" type="object" icon="gtk-go-forward"/>
<button name="stage_previous" string="Previous" states="draft,open,cancel,done,pending" type="object" icon="gtk-go-back"/>
<button name="stage_next" string="Next" states="draft,open,cancel,done,pending" type="object" icon="gtk-go-forward"/>
<field name="survey" invisible="1"/>
<field name="response" invisible="1"/>
<field name="priority"/>
@ -71,8 +71,9 @@
<group colspan="4" col="8">
<field name="name" string="Subject"/>
<label string="Stage: " align="1.0"/>
<group colspan="1" col="2">
<group colspan="1" col="3">
<field name="stage_id" nolabel="1"/>
<button name="stage_previous" string="" type="object" icon="gtk-go-back"/>
<button icon="gtk-go-forward" string="" name="stage_next" type="object"/>
</group>
<field name="user_id"/>
@ -84,10 +85,11 @@
<field name="partner_name"/>
<field name="job_id"/>
<field name="department_id" widget="selection"/>
<button name="%(wizard_hr_job_meeting_set)d" string="Schedule Meeting" icon="terp-hr" type="action"/>
<button name="%(survey.survey_browse_response)d" string="Print Interview" type="action"
icon="gtk-print" context="{'survey_id': survey, 'response_id' : [response], 'response_no':0,}" attrs="{'readonly':[('response','=',False)]}" />
</group>
<button name="action_makeMeeting" type="object"
string="Schedule Meeting" icon="terp-hr" />
<button name="action_print_survey" string="Print Interview" type="object"
icon="gtk-print" attrs="{'readonly':[('survey','=',False)]}"/>
</group>
<notebook colspan="4">
<page string="Job Info">
<group col="2" colspan="2">

View File

@ -9,14 +9,6 @@
multi="True"
string="Schedule Phone Call" />
<wizard
id="wizard_hr_job_meeting_set"
keyword="client_action_multi"
model="hr.applicant"
name="hr.applicant.meeting_set"
multi="True"
string="Schedule Meeting"/>
<wizard
id="wizard_hr_job_partner_create"
keyword="client_action_multi"

View File

@ -132,61 +132,6 @@ class job2phonecall(wizard.interface):
job2phonecall('hr.applicant.reschedule_phone_call')
class job2meeting(wizard.interface):
def _makeMeeting(self, cr, uid, data, context):
pool = pooler.get_pool(cr.dbname)
job_case_obj = pool.get('hr.applicant')
meeting_case_obj = pool.get('hr.meeting')
for job in job_case_obj.browse(cr, uid, data['ids']):
new_meeting_id = meeting_case_obj.create(cr, uid, {
'name': job.name,
'date': job.date,
'duration': job.duration,
})
new_meeting = meeting_case_obj.browse(cr, uid, new_meeting_id)
vals = {}
job_case_obj.write(cr, uid, [job.id], vals)
job_case_obj.case_cancel(cr, uid, [job.id])
meeting_case_obj.case_open(cr, uid, [new_meeting_id])
data_obj = pool.get('ir.model.data')
result = data_obj._get_id(cr, uid, 'hr', 'view_hr_case_meetings_filter')
id = data_obj.read(cr, uid, result, ['res_id'])
id1 = data_obj._get_id(cr, uid, 'hr', 'hr_case_calendar_view_meet')
id2 = data_obj._get_id(cr, uid, 'hr', 'hr_case_form_view_meet')
id3 = data_obj._get_id(cr, uid, 'hr', 'hr_case_tree_view_meet')
if id1:
id1 = data_obj.browse(cr, uid, id1, context=context).res_id
if id2:
id2 = data_obj.browse(cr, uid, id2, context=context).res_id
if id3:
id3 = data_obj.browse(cr, uid, id3, context=context).res_id
return {
'name': _('Meetings'),
'view_type': 'form',
'view_mode': 'calendar,form,tree',
'res_model': 'hr.meeting',
'view_id': False,
'views': [(id1,'calendar'),(id2,'form'),(id3,'tree'),(False,'graph')],
'type': 'ir.actions.act_window',
'search_view_id': id['res_id']
}
states = {
'init': {
'actions': [],
'result': {'type': 'action', 'action': _makeMeeting, 'state': 'order'}
},
'order': {
'actions': [],
'result': {'type': 'state', 'state': 'end'}
}
}
job2meeting('hr.applicant.meeting_set')
class partner_create(wizard.interface):
case_form = """<?xml version="1.0"?>

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:49+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: olap_extract

View File

@ -144,8 +144,8 @@
<field name="standard_price" attrs="{'readonly':[('cost_method','=','average')]}"/>
<field name="list_price"/>
<newline/>
<field name="price_margin" select="1"/>
<field name="price_extra" select="1"/>
<field name="price_margin" groups="base.group_extended"/>
<field name="price_extra" groups="base.group_extended"/>
<newline/>
<field groups="base.group_extended" name="cost_method"/>
<newline/>
@ -428,8 +428,8 @@
<form string="Supplier Information">
<field name="name"/>
<field name="sequence"/>
<field name="product_name"/>
<field name="product_code"/>
<field name="product_name" groups="base.group_extended"/>
<field name="product_code" groups="base.group_extended"/>
<field name="delay"/>
<field name="qty"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
@ -456,7 +456,6 @@
<field name="name"/>
<field name="delay"/>
<field name="qty"/>
<field name="product_code"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
</tree>
</field>
@ -562,7 +561,7 @@
</group>
</page>
<page string="Procurement &amp; Locations">
<page string="Procurement &amp; Locations" groups="base.group_extended">
<group colspan="2" col="2" name="delay">
<separator string="Delays" colspan="2"/>
<field name="sale_delay" attrs="{'readonly':[('sale_ok','=',0)]}"/>
@ -575,7 +574,6 @@
<field name="loc_row"/>
<field name="loc_case"/>
</group>
<group colspan="2" col="2" name="misc">
<separator string="Miscelleanous" colspan="2"/>
</group>

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2009-11-22 19:25+0000\n"
"PO-Revision-Date: 2010-04-09 11:29+0000\n"
"Last-Translator: Ferdinand @ ChriCar <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 03:55+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:48+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: purchase
@ -178,7 +178,7 @@ msgstr "Freundliche Gruesse."
#. module: purchase
#: rml:purchase.order:0
msgid "Net Total :"
msgstr "Gesamtsumme Netto:"
msgstr "Gesamt Netto:"
#. module: purchase
#: selection:purchase.order,state:0
@ -664,7 +664,7 @@ msgstr "Auftragsstatus"
#. module: purchase
#: field:purchase.order.line,price_subtotal:0
msgid "Subtotal"
msgstr "Zwischenbetrag"
msgstr "Zwischensumme"
#. module: purchase
#: model:product.pricelist.version,name:purchase.ver0
@ -883,7 +883,7 @@ msgstr "Erzeuge Rechnung aus Packauftrag"
#. module: purchase
#: field:purchase.order,amount_total:0
msgid "Total"
msgstr "Betrag gesammt"
msgstr "Betrag gesamt"
#. module: purchase
#: wizard_view:purchase.order.merge,init:0

View File

@ -7,13 +7,13 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0_rc3\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
"PO-Revision-Date: 2009-11-22 19:41+0000\n"
"PO-Revision-Date: 2010-04-09 08:08+0000\n"
"Last-Translator: Ferdinand @ ChriCar <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-03-30 04:05+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:49+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: sale
@ -130,7 +130,7 @@ msgstr "Erzeuge Rechnung"
#. module: sale
#: field:sale.order.line,price_subtotal:0
msgid "Subtotal"
msgstr "Zwischenbetrag"
msgstr "Zwischensumme"
#. module: sale
#: model:process.transition,note:sale.process_transition_confirmquotation0
@ -180,7 +180,7 @@ msgstr "Umsatzsteuer"
#. module: sale
#: rml:sale.order:0
msgid "Net Total :"
msgstr "Gesamtsumme Netto:"
msgstr "Gesamt Netto:"
#. module: sale
#: field:sale.order,order_policy:0
@ -200,7 +200,7 @@ msgstr "Versand Fehlerliste"
#. module: sale
#: field:sale.order,amount_total:0
msgid "Total"
msgstr "Betrag gesammt"
msgstr "Betrag gesamt"
#. module: sale
#: field:sale.order,origin:0

View File

@ -98,11 +98,11 @@
<form string="Sales order">
<group col="6" colspan="4">
<field name="name" select="1"/>
<field name="client_order_ref" select="2"/>
<field name="shipped" select="2"/>
<field name="shop_id" on_change="onchange_shop_id(shop_id)" select="2" widget="selection"/>
<field name="client_order_ref"/>
<field name="shipped"/>
<field name="shop_id" on_change="onchange_shop_id(shop_id)" widget="selection"/>
<field name="date_order" select="1" string="Order date" />
<field name="invoiced" select="2"/>
<field name="invoiced"/>
</group>
<notebook colspan="4">
<page string="Sale Order">
@ -111,8 +111,9 @@
<field domain="[('partner_id','=',partner_id)]" name="partner_invoice_id"/>
<field domain="[('partner_id','=',partner_id)]" name="partner_shipping_id"/>
<field domain="[('type','=','sale')]" name="pricelist_id" groups="base.group_extended"/>
<field name="project_id" select="2"
context="{'partner_id':partner_id, 'contact_id':partner_order_id, 'pricelist_id':pricelist_id, 'default_name':name}"/>
<field name="project_id"
context="{'partner_id':partner_id, 'contact_id':partner_order_id, 'pricelist_id':pricelist_id, 'default_name':name}"
groups="base.group_extended"/>
<newline/>
<field colspan="4" mode="tree,form,graph" name="order_line" nolabel="1" widget="one2many_list">
<form string="Sale Order Lines">
@ -140,17 +141,17 @@
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<separator colspan="4" string="Manual Description"/>
<field colspan="4" name="name" select="2"/>
<field name="price_unit" select="2"/>
<field colspan="4" name="name"/>
<field name="price_unit"/>
<field name="discount"/>
<field name="type"/>
<field name="delay" select="2"/>
<field name="type" groups="base.group_extended"/>
<field name="delay" groups="base.group_extended"/>
<newline/>
<field colspan="4" name="tax_id" domain="[('parent_id','=',False),('type_tax_use','&lt;&gt;','purchase')]"/>
<separator colspan="4" string="States"/>
<field name="state" select="2"/>
<field name="state"/>
<group col="3" colspan="2">
<field name="invoiced" select="2"/>
<field name="invoiced"/>
<button colspan="1"
name="%(action_view_sale_order_line_make_invoice)d"
states="confirmed"
@ -163,7 +164,7 @@
<field groups="product.group_uos" name="product_uos_qty" on_change="uos_change(product_uos, product_uos_qty, product_id)"/>
<field groups="product.group_uos" name="product_uos"/>
<field name="th_weight"/>
<field name="address_allotment_id" select="2"/>
<field name="address_allotment_id"/>
<separator colspan="4" string="Properties"/>
<field colspan="4" name="property_ids" nolabel="1"/>
</page>
@ -196,7 +197,7 @@
<button name="button_dummy" states="draft" string="Compute" type="object" icon="gtk-execute"/>
</group>
<group col="13" colspan="4">
<field name="state" select="2"/>
<field name="state"/>
<button name="order_confirm" states="draft" string="Confirm Order" icon="gtk-apply"/>
<button name="invoice_recreate" states="invoice_except" string="Recreate Invoice" icon="gtk-print"/>
<button name="invoice_corrected" states="invoice_except" string="Invoice Corrected" icon="gtk-apply"/>
@ -223,13 +224,13 @@
<field name="user_id"/>
<field groups="base.group_extended" name="origin"/>
</group>
<group colspan="2" col="2">
<group colspan="2" col="2" groups="base.group_extended">
<separator string="Conditions" colspan="2"/>
<field name="payment_term" widget="selection"/>
<field name="fiscal_position" groups="base.group_extended" widget="selection"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="fiscal_position" widget="selection"/>
<field name="company_id" widget="selection"/>
</group>
<group colspan="2" col="2">
<group colspan="2" col="2" groups="base.group_extended">
<separator string="Dates" colspan="2"/>
<field name="create_date" widget="datetime"/>
<field name="date_confirm"/>
@ -237,7 +238,7 @@
<separator colspan="4" string="Notes"/>
<field colspan="4" name="note" nolabel="1"/>
</page>
<page string="History">
<page string="History" groups="base.group_extended">
<separator colspan="4" string="Related invoices"/>
<field colspan="4" name="invoice_ids" nolabel="1"/>
<field colspan="4" name="picking_ids" nolabel="1"/>
@ -368,43 +369,43 @@
<form string="Sales Order Lines">
<notebook>
<page string="Order Lines">
<separator colspan="4" string="Automatic Declaration"/>
<separator colspan="4" string="General Information"/>
<field name="order_id" select="1"/>
<field name="order_partner_id" readonly="1" select="1" invisible="1"/>
<field name="product_uom_qty" readonly="1" select="2"/>
<field name="product_uom_qty" readonly="1"/>
<field name="product_uom"/>
<field name="product_id" readonly="1" select="1"/>
<field name="invoiced" select="2"/>
<field name="invoiced"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<separator colspan="4" string="Manual Designation"/>
<field colspan="4" name="name" select="2"/>
<field name="price_unit" select="2"/>
<field colspan="4" name="name"/>
<field name="price_unit"/>
<field name="discount"/>
<field name="type"/>
<field name="delay" select="2"/>
<field name="type" groups="base.group_extended"/>
<field name="delay" groups="base.group_extended"/>
<field name="price_subtotal"/>
<field name="th_weight"/>
<field colspan="4" name="tax_id" domain="[('parent_id','=',False),('type_tax_use','&lt;&gt;','purchase')]"/>
<separator colspan="4" string="States"/>
<field name="state" select="2"/>
<field name="state"/>
<group col="2" colspan="2">
<button name="button_done"
states="confirmed,exception"
string="Done" type="object"
icon="gtk-jump-to" />
states="confirmed,exception"
string="Done" type="object"
icon="gtk-jump-to" />
<button name="button_cancel"
states="confirmed,exception"
string="Cancel" type="object"
icon="gtk-cancel" />
states="confirmed,exception"
string="Cancel" type="object"
icon="gtk-cancel" />
</group>
</page>
<page string="Properties">
<page string="Properties" groups="base.group_extended">
<field name="property_ids" nolabel="1"/>
</page>
<page string="Notes">
<field colspan="4" name="notes" nolabel="1"/>
</page>
<page string="Invoice Lines">
<page string="Invoice Lines" groups="base.group_extended">
<field colspan="4" name="invoice_lines" nolabel="1"/>
</page>
</notebook>

View File

@ -2,19 +2,19 @@
<openerp>
<data>
<record id="product_search_form_view_stock" model="ir.ui.view">
<record id="product_search_form_view_stock" model="ir.ui.view">
<field name="name">product.search.stock.form</field>
<field name="model">product.product</field>
<field name="type">search</field>
<field name="inherit_id" ref="product.product_search_form_view"/>
<field name="arch" type="xml">
<field name="pricelist_id" select="1" widget="selection" position="before">
<field name="location_id" select="1" widget="selection" context="{'location': self}" />
<separator orientation="vertical"/>
</field>
<field name="pricelist_id" select="1" widget="selection" position="before">
<field name="location_id" select="1" widget="selection" context="{'location': self}" />
<separator orientation="vertical"/>
</field>
</field>
</record>
<record id="view_category_property_form" model="ir.ui.view">
<field name="name">product.category.stock.property.form.inherit</field>
<field name="model">product.category</field>
@ -54,20 +54,21 @@
</field>
</record>
<record id="view_product_standard_price_form" model="ir.ui.view">
<record id="view_product_standard_price_form" model="ir.ui.view">
<field name="name">product.product.standard.price.form.inherit</field>
<field name="model">product.product</field>
<field name="type">form</field>
<field name="inherit_id" ref="product.product_normal_form_view"/>
<field name="arch" type="xml">
<field name="standard_price" position="replace">
<group col="4" colspan="2">
<field name="standard_price" readonly="True"/>
<button name="%(action_view_change_standard_price)d" string="Change Price" type="action" icon="gtk-execute"/>
</group>
</field>
</field>
</record>
<field name="standard_price" position="replace">
<label string="Cost Price" align="1.0"/>
<group col="2" colspan="1">
<field name="standard_price" readonly="True" nolabel="1"/>
<button name="%(action_view_change_standard_price)d" string="Change Price" type="action" icon="gtk-execute"/>
</group>
</field>
</field>
</record>
<record id="view_normal_property_acc_form" model="ir.ui.view">
<field name="name">product.normal.stock.acc.property.form.inherit</field>
@ -77,8 +78,8 @@
<field name="priority">26</field>
<field name="arch" type="xml">
<field name="property_account_expense" position="after">
<field name="property_stock_account_output" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="property_stock_account_input" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]"/>
<field name="property_stock_account_output" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" groups="base.group_extended"/>
<field name="property_stock_account_input" domain="[('type','&lt;&gt;','view'),('type','&lt;&gt;','consolidation')]" groups="base.group_extended"/>
</field>
</field>
</record>
@ -112,7 +113,7 @@
<field name="inherit_id" ref="product.product_normal_form_view"/>
<field name="arch" type="xml">
<group name="store" position="after">
<group col="2" colspan="2" name="store">
<group col="2" colspan="2" name="store" groups="base.group_extended">
<separator string="Counter-Part Locations Properties" colspan="2"/>
<field name="property_stock_procurement" widget="selection" domain="[('usage','=','procurement')]"/>
<field name="property_stock_production" widget="selection"/>

View File

@ -9,13 +9,13 @@
<field name="arch" type="xml">
<search string="Search Location">
<group col="10" colspan="4">
<filter icon="terp-stock" name="in_location" string="Internal Locations" domain="[('location_id.usage', '=', 'internal')]" help="Internal Locations" />
<filter icon="terp-stock" string="Customer Locations" domain="[('location_id.usage', '=', 'customer')]" help="Customer Locations" />
<filter icon="terp-stock" string="Supplier Locations" domain="[('location_id.usage', '=', 'supplier')]" help="Supplier Locations" />
<filter icon="terp-stock" name="in_location" string="Internal" domain="[('location_id.usage', '=', 'internal')]" help="Internal Locations" />
<filter icon="terp-stock" string="Customer" domain="[('location_id.usage', '=', 'customer')]" help="Customer Locations" />
<filter icon="terp-stock" string="Supplier" domain="[('location_id.usage', '=', 'supplier')]" help="Supplier Locations" />
<separator orientation="vertical"/>
<field name="location_id" select="1" />
<field name="product_id" select="1" />
<field name="location_id" select="1"/>
<field name="product_id" select="1" default="1"/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="10">
@ -35,7 +35,7 @@
<form string="Stock by Lots">
<field name="location_id"/>
<field name="product_id"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="name"/>
</form>
</field>
@ -49,18 +49,31 @@
<tree string="Stock by Lots">
<field name="location_id"/>
<field name="product_id"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="name"/>
</tree>
</field>
</record>
<record id="stock_report_prodlots_graph" model="ir.ui.view">
<field name="name">stock.report.prodlots.view</field>
<field name="model">stock.report.prodlots</field>
<field name="type">graph</field>
<field name="arch" type="xml">
<graph string="Stock by Lots" type="bar">
<field name="product_id"/>
<field name="name"/>
</graph>
</field>
</record>
<record id="action_stock_report_prodlots_form" model="ir.actions.act_window">
<field name="name">Inventory by Location</field>
<field name="type">ir.actions.act_window</field>
<field name="res_model">stock.report.prodlots</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_mode">tree,graph</field>
<field name="context">{'full':'1',"search_default_in_location":1}</field>
<field name="search_view_id" ref="view_stock_report_prodlots_filter" />
</record>

View File

@ -108,7 +108,7 @@
</group>
</form>
</field>
</page><page string="Posted Inventory">
</page><page string="Posted Inventory" groups="base.group_extended">
<field colspan="4" name="move_ids" nolabel="1"/>
</page>
</notebook>
@ -304,7 +304,7 @@
<field name="product_id" select="1"/>
<field name="product_qty" select="1"/>
<field name="product_uom" select="1" string="UOM"/>
<field name="prodlot_id" select="1"/>
<field name="prodlot_id" select="1" groups="base.group_extended"/>
<field name="product_packaging" domain="[('product_id','=',product_id)]"/>
<field name="picking_id"/>
<field name="location_id" select="1"/>
@ -326,7 +326,7 @@
<field name="product_id" select="1"/>
<field name="product_qty" select="1"/>
<field name="product_uom" select="1" string="UOM"/>
<field name="prodlot_id" select="1"/>
<field name="prodlot_id" select="1" groups="base.group_extended"/>
<field name="product_packaging" domain="[('product_id','=',product_id)]"/>
<field name="picking_id"/>
<field name="location_id" select="1"/>
@ -607,7 +607,7 @@
<field name="product_qty" on_change="onchange_quantity(product_id, product_qty, product_uom, product_uos)"/>
<field name="product_uom" string="UOM"/>
<field name="picking_id" select="1"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="location_id"/>
<field name="location_dest_id"/>
<field name="date_planned"/>
@ -639,7 +639,7 @@
<field name="date_planned"/>
<field name="address_id" select="1" context="{'contact_display':'partner'}"/>
<field groups="base.group_extended" name="product_packaging"/>
<field name="prodlot_id" select="2"
<field name="prodlot_id" select="2" groups="base.group_extended"
context="{'location_id':location_id, 'product_id':product_id}"
domain="[('product_id','=?',product_id)]"
on_change="onchange_lot_id(prodlot_id,product_qty, location_id, product_id)"/>
@ -656,7 +656,7 @@
<button name="action_cancel" states="assigned" string="Cancel" type="object" icon="gtk-cancel"/>
</group>
</page>
<page string="Return Picking History">
<page string="Return Picking History" groups="base.group_extended">
<field name="move_stock_return_history" nolabel="1"/>
</page>
</notebook>
@ -769,7 +769,7 @@
<field name="product_qty" on_change="onchange_quantity(product_id, product_qty, product_uom, product_uos)"/>
<field name="product_uom" string="UOM"/>
<field name="picking_id" select="1"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="location_id"/>
<field name="location_dest_id"/>
<field name="date_planned"/>
@ -778,6 +778,7 @@
name="%(stock.track_line)d"
string="Split in production lots"
type="action" icon="gtk-justify-fill"
groups="base.group_extended"
states="draft,waiting,confirmed,assigned" />
<button name="%(stock.move_scrap)d"
string="Scrap Products" type="action"
@ -799,7 +800,7 @@
<field invisible="1" name="date"/>
<field name="date_planned"/>
<field groups="base.group_extended" name="product_packaging"/>
<field name="prodlot_id" select="2"
<field name="prodlot_id" select="2" groups="base.group_extended"
context="{'location_id':location_id, 'product_id':product_id}"
domain="[('product_id','=?',product_id)]"
on_change="onchange_lot_id(prodlot_id,product_qty, location_id, product_id)"/>
@ -958,7 +959,7 @@
<field name="product_qty" on_change="onchange_quantity(product_id, product_qty, product_uom, product_uos)"/>
<field name="product_uom" string="UOM"/>
<field name="picking_id" select="1"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="location_id"/>
<field name="location_dest_id"/>
<field name="date_planned"/>
@ -989,7 +990,7 @@
<field invisible="1" name="date"/>
<field name="date_planned"/>
<field groups="base.group_extended" name="product_packaging"/>
<field name="prodlot_id" select="1"
<field name="prodlot_id" select="1" groups="base.group_extended"
context="{'location_id':location_id, 'product_id':product_id}"
domain="[('product_id','=?',product_id)]"
on_change="onchange_lot_id(prodlot_id,product_qty, location_id, product_id)"/>
@ -1144,7 +1145,7 @@
<field name="product_qty"/>
<field name="product_uom"/>
<field name="location_dest_id"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="state"/>
<button
name="%(stock.track_line)d"
@ -1173,7 +1174,7 @@
<newline/>
<field groups="base.group_extended" name="product_packaging"/>
<newline/>
<field name="prodlot_id" select="1"
<field name="prodlot_id" select="1" groups="base.group_extended"
context="{'location_id':location_id, 'product_id':product_id}"
domain="[('product_id','=?',product_id)]"
on_change="onchange_lot_id(prodlot_id,product_qty, location_id, product_id)"/>
@ -1320,7 +1321,7 @@
<field name="product_qty" on_change="onchange_quantity(product_id, product_qty, product_uom, product_uos)"/>
<field name="product_uom" string="UOM"/>
<field name="picking_id" select="1"/>
<field name="prodlot_id"/>
<field name="prodlot_id" groups="base.group_extended"/>
<field name="location_id"/>
<field name="location_dest_id"/>
<field name="date_planned"/>
@ -1368,7 +1369,7 @@
<group colspan="2" col="4">
<separator string="Traceability" colspan="4" />
<field name="tracking_id" select="1" colspan="4" />
<field name="prodlot_id" select="2"
<field name="prodlot_id" select="2" groups="base.group_extended"
context="{'location_id':location_id, 'product_id':product_id}"
domain="[('product_id','=?',product_id)]"
on_change="onchange_lot_id(prodlot_id,product_qty, location_id, product_id)"/>
@ -1398,13 +1399,12 @@
<field name="arch" type="xml">
<search string="Stock Moves">
<group col="8" colspan="4">
<filter icon="terp-stock" string="Available" domain="[('state','=','assigned')]" help="Available Moves"/>
<filter icon="terp-stock" string="Confirmed" domain="[('state','=','confirmed')]" help="Confirmed Moves"/>
<filter icon="terp-stock" string="Waiting" domain="[('state','=','waiting')]" help="Waiting"/>
<filter icon="terp-stock" string="Available" domain="[('state','=','done')]" help="Done"/>
<filter icon="terp-stock" string="Available" domain="[('state','in',('assigned','confirmed','waiting'))]" help="Future"/>
<separator orientation="vertical"/>
<field name="location_id" select="1"/>
<field name="location_dest_id" select="1"/>
<field name="product_id" select="1"/>
<field name="location_id"/>
<field name="location_dest_id"/>
<field name="product_id"/>
</group>
<newline/>
<group expand="1" string="Group By..." colspan="4" col="8">
@ -1444,7 +1444,7 @@
<field name="product_id"/>
<field name="product_qty" />
<field name="product_uom" string="UOM"/>
<field name="prodlot_id" string="Lot"/>
<field name="prodlot_id" string="Lot" groups="base.group_extended"/>
<field name="date_planned"/>
<field name="backorder_id"/>
<field name="state"/>
@ -1464,22 +1464,22 @@
<notebook colspan="4">
<page string="General Information">
<separator colspan="4" string="Move Information"/>
<field name="location_id" select="1"/>
<field name="location_dest_id" select="1"/>
<field colspan="4" name="product_id" select="1" on_change="onchange_product_id(product_id,location_id,location_dest_id)"/>
<field name="location_id"/>
<field name="location_dest_id"/>
<field colspan="4" name="product_id" on_change="onchange_product_id(product_id,location_id,location_dest_id)"/>
<field name="product_qty" select="2" on_change="onchange_quantity(product_id, product_qty, product_uom, product_uos)"/>
<field name="product_uom" select="2"/>
<field name="product_uos" select="2"/>
<field colspan="4" name="name" select="2"/>
<field name="date"/>
<field name="company_id" select="1" groups="base.group_multi_company" widget="selection"/>
<field name="company_id" groups="base.group_multi_company" widget="selection"/>
<field name="date_planned"/>
<field name="priority"/>
<field name="address_id" select="2" context="{'contact_display':'partner'}"/>
<newline/>
<field name="picking_id" select="2"/>
<newline/>
<field name="prodlot_id" select="2"
<field name="prodlot_id" select="2" groups="base.group_extended"
context="{'location_id':location_id, 'product_id':product_id}"
domain="[('product_id','=?',product_id)]"
on_change="onchange_lot_id(prodlot_id,product_qty, location_id, product_id)"/>
@ -1488,7 +1488,7 @@
<label/>
<button name="%(track_line)d" string="Split in production lots" type="action" icon="gtk-justify-fill"/>
<separator colspan="4" string="Move State"/>
<field name="state" select="1"/>
<field name="state"/>
<group col="5" colspan="2">
<button name="action_confirm" states="draft" string="Confirm" type="object" icon="gtk-apply"/>
<button name="action_assign" states="confirmed" string="Set Available" type="object" icon="gtk-yes"/>
@ -1517,8 +1517,8 @@
<filter icon="terp-stock" string="Back Orders" domain="[('backorder_id','!=',False)]" help="Back Orders"/>
<filter icon="terp-stock" string="Planned Today" domain="[('date_planned::date','=',time.strftime('%%Y-%%m-%%d'))]" help="Orders planned for today"/>
<separator orientation="vertical"/>
<field name="origin" string="Latest Procurement" select="1"/>
<field name="partner_id" string="Supplier" select="1"/>
<field name="origin" string="Latest Procurement"/>
<field name="partner_id" string="Supplier"/>
<field name="product_id"/>
</group>
<newline/>
@ -1568,7 +1568,7 @@
<field name="arch" type="xml">
<tree string="Incoterms">
<field name="code"/>
<field colspan="4" name="name" select="1"/>
<field colspan="4" name="name"/>
</tree>
</field>
</record>

View File

@ -14,7 +14,7 @@ msgstr ""
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"X-Launchpad-Export-Date: 2010-04-09 03:56+0000\n"
"X-Launchpad-Export-Date: 2010-04-10 03:49+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: survey

View File

@ -95,6 +95,50 @@ class survey(osv.osv):
def copy(self, cr, uid, id, default=None,context={}):
raise osv.except_osv(_('Warning !'),_('You cannot duplicate the resource!'))
def action_print_survey(self, cr, uid, ids, context=None):
"""
If response is available then print this response otherwise print survey form(print template of the survey).
@param self: The object pointer
@param cr: the current row, from the database cursor,
@param uid: the current users ID for security checks,
@param ids: List of Survey IDs
@param context: A standard dictionary for contextual values
@return : Dictionary value for print survey form.
"""
if not context:
context = {}
datas = {}
if 'response_id' in context:
response_id = context.get('response_id', 0)
datas['ids'] = [context.get('survey_id', 0)]
else:
response_id = self.pool.get('survey.response').search(cr, uid, [('survey_id','=', ids)], context=context)
datas['ids'] = ids
page_setting = {'orientation': 'vertical', 'without_pagebreak': 0, 'paper_size': 'letter', 'page_number': 1, 'survey_title': 1}
report = {}
if response_id and response_id[0]:
context.update({'survey_id': datas['ids']})
datas['form'] = page_setting
datas['model'] = 'survey.print.answer'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.browse.response',
'datas': datas,
'nodestroy': True,
'context' : context
}
else:
datas['form'] = page_setting
datas['model'] = 'survey.print'
report = {
'type': 'ir.actions.report.xml',
'report_name': 'survey.form',
'datas': datas,
'nodestroy':True,
'context' : context
}
return report
survey()
class survey_history(osv.osv):

View File

@ -243,8 +243,8 @@
string="Answer Survey" type="action" icon="gtk-execute" context="{'survey_id': active_id}" attrs="{'invisible':[('state','!=','open')]}"/>
<button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel"
string="Edit Survey" type="action" icon="gtk-edit" context="{'active':True,'edit' : True,'survey_id': active_id}"/>
<button name="%(survey_browse_response)d" states="open,draft,close,cancel"
string="Print Answer" type="action" icon="gtk-print"/>
<button name="action_print_survey" states="open,draft,close,cancel"
string="Print Answer" type="object" icon="gtk-print"/>
</tree>
</field>
</record>