[MERGE]: Merge with lp:~openerp-dev/openobject-addons/trunk-dev-addons2
bzr revid: rpa@tinyerp.com-20100614063742-rhrg1d4lxxz2oeei
This commit is contained in:
@@ -19,26 +19,26 @@
|
||||
position="attributes">
|
||||
<attribute name="string">You can enhance OpenERP's basic accounting support with a few additional OpenERP applications.</attribute>
|
||||
</xpath>
|
||||
<xpath expr="//button[@string='Install Modules']" position="attributes">
|
||||
<xpath expr="//button[@string='Install Modules']" position="attributes">
|
||||
<attribute name="string">Configure</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='rowspan'>23</attribute>
|
||||
<attribute name='string'></attribute>
|
||||
</xpath>
|
||||
<group colspan="8">
|
||||
<group colspan="4" height="450" width="600">
|
||||
</xpath>
|
||||
<group colspan="8">
|
||||
<group colspan="4" height="450" width="600">
|
||||
<field name="charts"/>
|
||||
<group colspan="4">
|
||||
<separator col="4" colspan="4" string="Configure Fiscal Year"/>
|
||||
<separator col="4" colspan="4" string="Configure Fiscal Year"/>
|
||||
<field name="date_start" on_change="on_change_start_date(date_start)"/>
|
||||
<field name="date_stop"/>
|
||||
<field name="period" colspan="4"/>
|
||||
</group>
|
||||
<group colspan="4" attrs="{'invisible':[('charts','!=','configurable')]}">
|
||||
<separator col="4" colspan="4" string="Bank and Cost Account"/>
|
||||
<field colspan="4" mode="tree" name="bank_accounts_id" nolabel="1" widget="one2many_list">
|
||||
<form string="">
|
||||
<separator col="4" colspan="4" string="Bank and Cost Account"/>
|
||||
<field colspan="4" mode="tree" name="bank_accounts_id" nolabel="1" widget="one2many_list">
|
||||
<form string="">
|
||||
<field name="acc_name"/>
|
||||
<field name="account_type"/>
|
||||
<field name="currency_id" widget="selection"/>
|
||||
@@ -51,15 +51,15 @@
|
||||
</field>
|
||||
</group>
|
||||
<group colspan="4" attrs="{'invisible':[('charts','!=','configurable')]}">
|
||||
<field name="sale_tax" colspan="2" on_change="on_change_tax(sale_tax)"/>
|
||||
<field name="purchase_tax" colspan="2" />
|
||||
<field name="sale_tax" colspan="2" on_change="on_change_tax(sale_tax)"/>
|
||||
<field name="purchase_tax" colspan="2" />
|
||||
</group>
|
||||
<group colspan="4" groups="base.group_extended">
|
||||
<separator col="4" colspan="4" string="Install Extra Account Module"/>
|
||||
<field name="account_analytic_plans"/>
|
||||
<field name="account_payment"/>
|
||||
<field name="account_followup"/>
|
||||
<field name="account_asset"/>
|
||||
<separator col="4" colspan="4" string="Install Extra Account Module"/>
|
||||
<field name="account_analytic_plans"/>
|
||||
<field name="account_payment"/>
|
||||
<field name="account_followup"/>
|
||||
<field name="account_asset"/>
|
||||
</group>
|
||||
</group>
|
||||
</group>
|
||||
@@ -88,12 +88,12 @@
|
||||
<field name="name">account_installer_action_replace</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="inherit_id" ref="base.ir_actions_todo_tree"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//button[@string='Launch']" position="replace">
|
||||
<button name="%(action_account_installer)d" states="open,skip" string="Launch" type="action" icon="gtk-execute" help="Launch Configuration Wizard"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//button[@string='Launch']" position="replace">
|
||||
<button name="%(action_account_installer)d" states="open,skip" string="Launch" type="action" icon="gtk-execute" help="Launch Configuration Wizard"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -487,20 +487,5 @@
|
||||
|
||||
<act_window domain="[('partner_id', '=', partner_id), ('account_id.type', 'in', ['receivable', 'payable']), ('reconcile_id','=',False)]" id="act_account_invoice_account_move_unreconciled" name="Unreconciled Receivables & Payables" res_model="account.move.line" src_model="account.invoice"/>
|
||||
|
||||
<!-- Partners inherited form -->
|
||||
|
||||
<record id="view_invoice_partner_info_form" model="ir.ui.view">
|
||||
<field name="name">res.partner.invoice.info.inherit</field>
|
||||
<field name="model">res.partner</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<notebook position="inside">
|
||||
<page string="Account Info">
|
||||
<field name="invoice_ids" colspan="4" nolabel="1" context="{'group_by':'product_id'}"/>
|
||||
</page>
|
||||
</notebook>
|
||||
</field>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -1496,7 +1496,7 @@
|
||||
|
||||
<act_window domain="[('partner_id', '=', active_id), ('account_id.type', 'in', ['receivable', 'payable'])]" id="act_account_partner_account_move_all" name="Receivables & Payables" res_model="account.move.line" src_model="res.partner"/>
|
||||
|
||||
<act_window domain="[('partner_id', '=', active_id)]" id="act_account_partner_account_move" name="All Account Entries" res_model="account.move.line" src_model="res.partner"/>
|
||||
<act_window domain="[('partner_id', '=', active_id)]" id="act_account_partner_account_move" name="All Account Entries" res_model="account.move.line" src_model="res.partner"/>
|
||||
|
||||
<record id="view_account_addtmpl_wizard_form" model="ir.ui.view">
|
||||
<field name="name">Account Add wizard</field>
|
||||
@@ -1519,7 +1519,7 @@
|
||||
res_model="account.addtmpl.wizard"
|
||||
context="{'tmpl_ids': active_id}"
|
||||
src_model="account.account.template"
|
||||
view_type="form" view_mode="form"/>
|
||||
view_type="form" view_mode="form"/>
|
||||
|
||||
<!-- Account Templates -->
|
||||
<menuitem
|
||||
@@ -1752,17 +1752,17 @@
|
||||
<attribute name="string">Generate Chart of Accounts from a Chart Template</attribute>
|
||||
</form>
|
||||
<separator string="title" position="attributes">
|
||||
<attribute name="string"
|
||||
<attribute name="string"
|
||||
>Generate Chart of Accounts from a Chart Template</attribute>
|
||||
</separator>
|
||||
<xpath expr="//label[@string='description']" position="attributes">
|
||||
<attribute name="string">This will automatically configure your chart of accounts, bank accounts, taxes and journals according to the selected template</attribute>
|
||||
<attribute name="width">150</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='rowspan'>15</attribute>
|
||||
<attribute name='string'></attribute>
|
||||
</xpath>
|
||||
</separator>
|
||||
<xpath expr="//label[@string='description']" position="attributes">
|
||||
<attribute name="string">This will automatically configure your chart of accounts, bank accounts, taxes and journals according to the selected template</attribute>
|
||||
<attribute name="width">150</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='rowspan'>15</attribute>
|
||||
<attribute name='string'></attribute>
|
||||
</xpath>
|
||||
<group string="res_config_contents" position="replace">
|
||||
<field name="company_id" widget="selection"
|
||||
/>
|
||||
|
||||
@@ -89,7 +89,7 @@ class res_partner(osv.osv):
|
||||
_inherit = 'res.partner'
|
||||
_description = 'Partner'
|
||||
def _credit_debit_get(self, cr, uid, ids, field_names, arg, context):
|
||||
query = self.pool.get('account.move.line')._query_get(cr, uid, context=context)
|
||||
query = self.pool.get('account.move.line')._query_get(cr, 1, context=context)
|
||||
cr.execute("""select
|
||||
l.partner_id, a.type, sum(l.debit-l.credit)
|
||||
from
|
||||
|
||||
@@ -118,7 +118,6 @@
|
||||
<field name="acc_number"/>
|
||||
</tree>
|
||||
</field>
|
||||
<field name="invoice_ids" colspan="4" nolabel="1" context="{'group_by':'product_id'}"/>
|
||||
</page>
|
||||
</notebook>
|
||||
</field>
|
||||
@@ -126,17 +125,14 @@
|
||||
|
||||
<!-- Partners info tab view-->
|
||||
|
||||
<record id="view_account_partner_info_form" model="ir.ui.view">
|
||||
<field name="name">res.partner.account.info.inherit</field>
|
||||
<field name="model">res.partner</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//notebook[last()]" position="after">
|
||||
<field name="contract_ids" colspan="4" nolabel="1" />
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<act_window
|
||||
id="action_analytic_open"
|
||||
name="Analytic Accounts"
|
||||
res_model="account.analytic.account"
|
||||
domain="[('partner_id','=',active_id)]"
|
||||
src_model="res.partner"
|
||||
view_type="form"
|
||||
view_mode="tree,form,graph,calendar"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -44,77 +44,77 @@
|
||||
</record>
|
||||
|
||||
<record id="account_move_line_comp_rule" model="ir.rule">
|
||||
<field name="name">Entry lines</field>
|
||||
<field name="name">Entry lines</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_move_line"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="journal_period_comp_rule" model="ir.rule">
|
||||
<field name="name">Journal Period</field>
|
||||
<field name="name">Journal Period</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_journal_period"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="journal_comp_rule" model="ir.rule">
|
||||
<field name="name">Journal multi-company</field>
|
||||
<field name="name">Journal multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_journal"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|','|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="analytic_journal_comp_rule" model="ir.rule">
|
||||
<field name="name">Analytic journal multi-company</field>
|
||||
<field name="name">Analytic journal multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_analytic_journal"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="analytic_journal_comp_rule_false" model="ir.rule">
|
||||
<field name="name">Analytic journal multi-company</field>
|
||||
<field name="name">Analytic journal multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_analytic_journal"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="period_comp_rule" model="ir.rule">
|
||||
<field name="name">Period multi-company</field>
|
||||
<field name="name">Period multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_period"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="fiscal_year_comp_rule" model="ir.rule">
|
||||
<field name="name">Fiscal year multi-company</field>
|
||||
<field name="name">Fiscal year multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_fiscalyear"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="account_comp_rule" model="ir.rule">
|
||||
<field name="name">Account multi-company</field>
|
||||
<field name="name">Account multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_account"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="tax_comp_rule" model="ir.rule">
|
||||
<field name="name">Tax multi-company</field>
|
||||
<field name="name">Tax multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_tax"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="tax_code_comp_rule" model="ir.rule">
|
||||
<field name="name">Tax code multi-company</field>
|
||||
<field name="name">Tax code multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_tax_code"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
</record>
|
||||
|
||||
<record id="invoice_comp_rule" model="ir.rule">
|
||||
<field name="name">Invoice multi-company</field>
|
||||
<field name="name">Invoice multi-company</field>
|
||||
<field model="ir.model" name="model_id" ref="model_account_invoice"/>
|
||||
<field eval="True" name="global"/>
|
||||
<field name="domain_force">['|',('company_id','=',False),('company_id','child_of',[user.company_id.id])]</field>
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_product_product_account_user","product.product.account.user","product.model_product_product","group_account_user",1,0,0,0
|
||||
"access_account_payment_term","account.payment.term","model_account_payment_term","account.group_account_user",1,0,0,0
|
||||
"access_account_payment_term_line","account.payment.term.line","model_account_payment_term_line","account.group_account_user",1,0,0,0
|
||||
"access_account_account_type","account.account.type","model_account_account_type","account.group_account_user",1,0,0,0
|
||||
@@ -69,7 +70,6 @@
|
||||
"access_account_add_tmpl_wizard_system_manager","account.addtmpl.wizard system manager","model_account_addtmpl_wizard","base.group_system",1,1,1,1
|
||||
"access_account_invoice_user","account.invoice user","model_account_invoice","base.group_user",1,0,0,0
|
||||
"access_account_invoice_user","account.invoice.line user","model_account_invoice_line","base.group_user",1,0,0,0
|
||||
"access_account_invoice_user","account.invoice.tax user","model_account_invoice_tax","base.group_user",1,0,0,0
|
||||
"access_account_payment_term_partner_manager","account.payment.term partner manager","model_account_payment_term","base.group_user",1,0,0,0
|
||||
"access_account_payment_term_line_partner_manager","account.payment.term.line partner manager","model_account_payment_term_line","base.group_user",1,0,0,0
|
||||
"access_account_account_product_manager","account.account product manager","model_account_account","product.group_product_manager",1,0,0,0
|
||||
@@ -85,7 +85,7 @@
|
||||
"access_account_fiscal_position_account_template","account.fiscal.position.account.template","model_account_fiscal_position_account_template","account.group_account_manager",1,1,1,1
|
||||
"access_account_sequence_fiscal_year","account.sequence.fiscalyear","model_account_sequence_fiscalyear","account.group_account_user",1,1,1,1
|
||||
"access_account_sequence_fiscal_year_user","account.sequence.fiscalyear user","model_account_sequence_fiscalyear","base.group_user",1,0,0,0
|
||||
"access_account_installer","account.installer","model_account_installer","base.group_user",1,0,0,0
|
||||
"access_account_installer","account.installer","model_account_installer","base.group_system",1,1,1,1
|
||||
"access_report_account_receivable","report.account.receivable","model_report_account_receivable","account.group_account_manager",1,0,0,0
|
||||
"access_temp_range","temp.range","model_temp_range","account.group_account_manager",1,0,0,0
|
||||
"access_report_aged_receivable","report.aged.receivable","model_report_aged_receivable","account.group_account_manager",1,0,0,0
|
||||
|
||||
|
@@ -134,7 +134,6 @@ class account_automatic_reconcile(osv.osv_memory):
|
||||
return (reconciled, len(credits)+len(debits))
|
||||
|
||||
def reconcile(self, cr, uid, ids, context=None):
|
||||
service = netsvc.LocalService("object_proxy")
|
||||
move_line_obj = self.pool.get('account.move.line')
|
||||
obj_model = self.pool.get('ir.model.data')
|
||||
if context is None:
|
||||
@@ -240,4 +239,4 @@ class account_automatic_reconcile(osv.osv_memory):
|
||||
|
||||
account_automatic_reconcile()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
@@ -1,22 +1,22 @@
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<record id="account_invoice_confirm_view" model="ir.ui.view">
|
||||
<record id="account_invoice_confirm_view" model="ir.ui.view">
|
||||
<field name="name">account.invoice.confirm.form</field>
|
||||
<field name="model">account.invoice.confirm</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Confirm Draft Invoices">
|
||||
<separator string="Confirm Draft Invoices" colspan="4"/>
|
||||
<form string="Confirm Draft Invoices">
|
||||
<separator string="Confirm Draft Invoices" colspan="4"/>
|
||||
<group colspan="4" col="6">
|
||||
<button icon="gtk-cancel" special="cancel" string="Close"/>
|
||||
<button icon="gtk-execute" string="Confirm Invoices" name="invoice_confirm" type="object" default_focus="1"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="Close"/>
|
||||
<button icon="gtk-execute" string="Confirm Invoices" name="invoice_confirm" type="object" default_focus="1"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
<record id="action_account_invoice_confirm" model="ir.actions.act_window">
|
||||
<record id="action_account_invoice_confirm" model="ir.actions.act_window">
|
||||
<field name="name">Confirm Draft Invoices</field>
|
||||
<field name="res_model">account.invoice.confirm</field>
|
||||
<field name="view_type">form</field>
|
||||
@@ -25,7 +25,7 @@
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.values" id="action_account_invoice_confirm_values">
|
||||
<record model="ir.values" id="action_account_invoice_confirm_values">
|
||||
<field name="model_id" ref="account.model_account_invoice" />
|
||||
<field name="object" eval="1" />
|
||||
<field name="name">Confirm Draft Invoices</field>
|
||||
@@ -33,24 +33,24 @@
|
||||
<field name="value" eval="'ir.actions.act_window,' +str(ref('action_account_invoice_confirm'))" />
|
||||
<field name="key">action</field>
|
||||
<field name="model">account.invoice</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
<record id="account_invoice_cancel_view" model="ir.ui.view">
|
||||
<record id="account_invoice_cancel_view" model="ir.ui.view">
|
||||
<field name="name">account.invoice.cancel.form</field>
|
||||
<field name="model">account.invoice.cancel</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Cancel Selected Invoices">
|
||||
<separator string="Cancel Selected Invoices" colspan="4"/>
|
||||
<form string="Cancel Selected Invoices">
|
||||
<separator string="Cancel Selected Invoices" colspan="4"/>
|
||||
<group colspan="4" col="6">
|
||||
<button icon="gtk-cancel" special="cancel" string="Close"/>
|
||||
<button icon="gtk-execute" string="Cancel Invoices" name="invoice_cancel" type="object" default_focus="1"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="Close"/>
|
||||
<button icon="gtk-execute" string="Cancel Invoices" name="invoice_cancel" type="object" default_focus="1"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
<record id="action_account_invoice_cancel" model="ir.actions.act_window">
|
||||
<record id="action_account_invoice_cancel" model="ir.actions.act_window">
|
||||
<field name="name">Cancel Selected Invoices</field>
|
||||
<field name="res_model">account.invoice.cancel</field>
|
||||
<field name="view_type">form</field>
|
||||
@@ -59,7 +59,7 @@
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.values" id="action_account_invoice_cancel_values">
|
||||
<record model="ir.values" id="action_account_invoice_cancel_values">
|
||||
<field name="model_id" ref="account.model_account_invoice" />
|
||||
<field name="object" eval="1" />
|
||||
<field name="name">Cancel Selected Invoices</field>
|
||||
@@ -67,7 +67,7 @@
|
||||
<field name="value" eval="'ir.actions.act_window,' +str(ref('action_account_invoice_cancel'))" />
|
||||
<field name="key">action</field>
|
||||
<field name="model">account.invoice</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -32,13 +32,12 @@ class account_budget_spread(osv.osv_memory):
|
||||
}
|
||||
|
||||
def check_spread(self, cr, uid, ids, context=None):
|
||||
service = netsvc.LocalService("object_proxy")
|
||||
if context is None:
|
||||
context = {}
|
||||
data = self.read(cr, uid, ids, [])[0]
|
||||
res = service.execute(cr.dbname, uid, 'account.budget.post', 'spread', context['active_ids'], data['fiscalyear'], data['amount'])
|
||||
data = self.browse(cr, uid, ids, context=context)[0]
|
||||
res = self.pool.get('account.budget.post').spread(cr, uid, context['active_ids'], data.fiscalyear.id, data.amount)
|
||||
return {}
|
||||
|
||||
account_budget_spread()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
@@ -27,8 +27,7 @@ class auction_invoice(report_int):
|
||||
report_int.__init__(self, name)
|
||||
|
||||
def create(self,cr, uid, ids, datas, context):
|
||||
service = netsvc.LocalService("object_proxy")
|
||||
lots = service.execute(cr.dbname,uid, 'auction.lots', 'read', ids, ['ach_inv_id'])
|
||||
lots = self.pool.get('auction.lots').read(cr,uid, ids, ['ach_inv_id'], context=context)
|
||||
|
||||
invoices = {}
|
||||
for l in lots:
|
||||
|
||||
@@ -1,2 +1,3 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_base_action_rule","base.action.rule","model_base_action_rule",,1,1,1,1
|
||||
"access_base_action_rule","base.action.rule","model_base_action_rule",,1,0,0,0
|
||||
"access_base_action_rule_config","base.action.rule config","model_base_action_rule",base.group_system,1,0,0,0
|
||||
|
||||
|
@@ -2,7 +2,7 @@
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<!-- Attendee form view-->
|
||||
<!-- Attendee form view-->
|
||||
|
||||
<record id="base_calendar_attendee_form_view" model="ir.ui.view">
|
||||
<field name="name">calendar.attendee.form</field>
|
||||
@@ -10,12 +10,12 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Invitation details">
|
||||
<group col="6" colspan="4">
|
||||
<field name="email" string="Invitation To"/>
|
||||
<field name="cutype" string="Invitation type" />
|
||||
<group col="6" colspan="4">
|
||||
<field name="email" string="Invitation To"/>
|
||||
<field name="cutype" string="Invitation type" />
|
||||
<field name="rsvp" />
|
||||
<field name="role" string="Role" />
|
||||
<field name="sent_by_uid" string="Invitation From" />
|
||||
<field name="sent_by_uid" string="Invitation From" />
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Invitation">
|
||||
@@ -68,7 +68,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Attendee tree view-->
|
||||
<!-- Attendee tree view-->
|
||||
|
||||
<record id="base_calendar_attendee_tree_view" model="ir.ui.view">
|
||||
<field name="name">calendar.attendee.tree</field>
|
||||
@@ -87,7 +87,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Attendee search view-->
|
||||
<!-- Attendee search view-->
|
||||
|
||||
<record id="base_calendar_attendee_search_view" model="ir.ui.view">
|
||||
<field name="name">calendar.attendee.search</field>
|
||||
@@ -103,52 +103,52 @@
|
||||
separator="1" help="Declined Invitations" />
|
||||
<separator orientation="vertical"/>
|
||||
<field name="email" select='1'/>
|
||||
<field name="sent_by_uid" select="1" widget="selection"/>
|
||||
<field name="sent_by_uid" select="1"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="cutype" string="Invitation type" select="1"/>
|
||||
<field name="event_date" select="1"/>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Type" icon="terp-stock_symbol-selection" help="Invitation Type"
|
||||
domain="[]" context="{'group_by':'cutype'}" />
|
||||
<filter string="Role" icon="terp-gtk-select-all"
|
||||
domain="[]" context="{'group_by':'role'}" />
|
||||
<filter string="Required Reply" icon="terp-mail-replied"
|
||||
domain="[]" context="{'group_by':'rsvp'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="User" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'user_id'}" />
|
||||
<filter string="Contact" icon="terp-gtk-jump-to-ltr" domain="[]"
|
||||
context="{'group_by':'partner_address_id'}" />
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" help="Invitation Type"
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Type" icon="terp-stock_symbol-selection" help="Invitation Type"
|
||||
domain="[]" context="{'group_by':'cutype'}" />
|
||||
<filter string="Role" icon="terp-gtk-select-all"
|
||||
domain="[]" context="{'group_by':'role'}" />
|
||||
<filter string="Required Reply" icon="terp-mail-replied"
|
||||
domain="[]" context="{'group_by':'rsvp'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="User" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'user_id'}" />
|
||||
<filter string="Contact" icon="terp-gtk-jump-to-ltr" domain="[]"
|
||||
context="{'group_by':'partner_address_id'}" />
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" help="Invitation Type"
|
||||
domain="[]" context="{'group_by':' state'}" />
|
||||
</group>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
<record id="action_view_attendee_form" model="ir.actions.act_window">
|
||||
<field name="name">Event Invitations</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">calendar.attendee</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="base_calendar.base_calendar_attendee_tree_view" />
|
||||
<field name="context">{'default_sent_by_uid': uid}</field>
|
||||
</record>
|
||||
<record id="action_view_attendee_form" model="ir.actions.act_window">
|
||||
<field name="name">Event Invitations</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">calendar.attendee</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="base_calendar.base_calendar_attendee_tree_view" />
|
||||
<field name="context">{'default_sent_by_uid': uid}</field>
|
||||
</record>
|
||||
|
||||
<!-- Calenadar's menu -->
|
||||
<!-- Calenadar's menu -->
|
||||
<menuitem id="base.menu_calendar_configuration" name="Calendar"
|
||||
parent="base.menu_address_book" sequence="15" />
|
||||
parent="base.menu_base_config" sequence="15" />
|
||||
|
||||
<!-- Invitation menu -->
|
||||
<!-- Invitation menu -->
|
||||
|
||||
<menuitem id="menu_attendee_invitations"
|
||||
<menuitem id="menu_attendee_invitations"
|
||||
name="Event Invitations" parent="base.menu_calendar_configuration"
|
||||
sequence="10" action="action_view_attendee_form" />
|
||||
|
||||
<!-- ALARM FORM VIEW-->
|
||||
<!-- ALARM FORM VIEW-->
|
||||
|
||||
<record id="res_alarm_form_view" model="ir.ui.view">
|
||||
<record id="res_alarm_form_view" model="ir.ui.view">
|
||||
<field name="name">res.alarm.form</field>
|
||||
<field name="model">res.alarm</field>
|
||||
<field name="type">form</field>
|
||||
@@ -165,7 +165,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- ALARM TREE VIEW-->
|
||||
<!-- ALARM TREE VIEW-->
|
||||
|
||||
<record id="res_alarm_tree_view" model="ir.ui.view">
|
||||
<field name="name">res.alarm.tree</field>
|
||||
@@ -189,198 +189,199 @@
|
||||
<field name="view_mode">tree,form</field>
|
||||
</record>
|
||||
|
||||
<!-- Menu for Alarms-->
|
||||
<!-- Menu for Alarms-->
|
||||
|
||||
<menuitem id="menu_crm_meeting_avail_alarm"
|
||||
groups="base.group_extended"
|
||||
action="base_calendar.action_res_alarm_view"
|
||||
parent="base.menu_calendar_configuration" />
|
||||
|
||||
<!-- Event Form View-->
|
||||
|
||||
<record model="ir.ui.view" id="event_form_view">
|
||||
<field name="name">Event Form</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Events">
|
||||
<group col="6" colspan="4">
|
||||
<field name="name" select="1" string="Summary"
|
||||
colspan="4" />
|
||||
<field name="allday" colspan="2" on_change="onchange_allday(allday)" />
|
||||
<newline/>
|
||||
<field name="date" string="Start Date" required="1" select="1"
|
||||
on_change="onchange_dates(date,duration,False,allday)" />
|
||||
<field name="duration" widget="float_time"
|
||||
on_change="onchange_dates(date,duration,False,allday)" attrs="{'invisible': [('allday', '=', True)]}"/>
|
||||
<field name="date_deadline" string="End Date" required="1"
|
||||
on_change="onchange_dates(date,False,date_deadline)" />
|
||||
<field name="location" />
|
||||
<field name="alarm_id" string="Reminder"
|
||||
widget="selection" />
|
||||
<group colspan="2" col="4" >
|
||||
<field name="rrule_type" string="Recurrency"
|
||||
colspan="1" attrs="{'readonly':[('recurrent_uid','!=',False)]}"/>
|
||||
<button string="Edit All"
|
||||
help="Edit all Ourrences of recurrent Meeting"
|
||||
attrs="{'invisible':[('rrule_type','in', ('none', False))]}"
|
||||
name="open_event" icon="gtk-edit"
|
||||
type="object" />
|
||||
</group>
|
||||
</group>
|
||||
<group col="4" colspan="4" name="rrule" attrs="{'invisible': [('rrule_type','!=','custom')]}">
|
||||
<separator string="Select data for Custom Rule" colspan="8"/>
|
||||
<group col="8" colspan="4">
|
||||
<field name="freq" />
|
||||
<field name="interval" />
|
||||
<field name="count" />
|
||||
<field name="end_date" />
|
||||
</group>
|
||||
<group col="14" colspan="4" name="Select weekdays"
|
||||
attrs="{'invisible' : [('freq','!=','weekly')]}">
|
||||
<field name="mo" colspan="1" />
|
||||
<field name="tu" colspan="1" />
|
||||
<field name="we" colspan="1" />
|
||||
<field name="th" colspan="1" />
|
||||
<field name="fr" colspan="1" />
|
||||
<field name="sa" colspan="1" />
|
||||
<field name="su" colspan="1" />
|
||||
<newline />
|
||||
</group>
|
||||
<group col="10" colspan="4"
|
||||
attrs="{'invisible' : [('freq','!=','monthly'), ('freq','!=','yearly')]}">
|
||||
<group col="2" colspan="1">
|
||||
<field name="select1" />
|
||||
</group>
|
||||
<group col="2" colspan="1"
|
||||
attrs="{'invisible' : [('select1','=','day')]}">
|
||||
<field name="day"
|
||||
attrs="{'required' : [('select1','=','date')]}" />
|
||||
</group>
|
||||
<group col="3" colspan="1"
|
||||
attrs="{'invisible' : [('select1','=','date')]}">
|
||||
<field name="byday" string="The"
|
||||
attrs="{'required' : [('select1','=','day')]}" />
|
||||
<field name="week_list" nolabel="1"
|
||||
attrs="{'required' : [('select1','=','day')]}" />
|
||||
</group>
|
||||
<group col="1" colspan="1"
|
||||
attrs="{'invisible' : [('freq','!=','yearly')]}">
|
||||
<field name="month_list" string="of"
|
||||
colspan="1"
|
||||
attrs="{'required' : [('freq','=','yearly')]}" />
|
||||
</group>
|
||||
</group>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Event">
|
||||
<group col="6" colspan="4">
|
||||
<separator colspan="6" string="Visibility"/>
|
||||
<field name="user_id" string="Responsible User" />
|
||||
<field name="show_as" string="Show time as"/>
|
||||
<field name="class" string="Privacy"/>
|
||||
<field name="recurrent_id" invisible="1" />
|
||||
<field name="recurrent_uid" invisible="1" />
|
||||
</group>
|
||||
<separator string="Description" colspan="4" />
|
||||
<field name="description" nolabel="1" colspan="4" />
|
||||
<separator colspan="4"/>
|
||||
</page>
|
||||
<page string="Invitation Detail">
|
||||
<button string="Invite People"
|
||||
name="%(base_calendar.action_view_calendar_invite_attendee_wizard)d"
|
||||
icon="terp-partner" type="action"
|
||||
context="{'model' : 'calendar.event', 'attendee_field':'attendee_ids'}" colspan="2"/>
|
||||
<field name="attendee_ids" colspan="4"
|
||||
nolabel="1" widget="one2many" mode="tree,form">
|
||||
<tree string="Invitation details" editable="top">
|
||||
<field name="email" />
|
||||
<field name="role" width="200" select="1" />
|
||||
<field name="state" />
|
||||
</tree>
|
||||
<form string="Invitation details">
|
||||
<notebook colspan="4">
|
||||
<page string="Details">
|
||||
<field name="email" />
|
||||
<field name="rsvp" select="1" />
|
||||
<field name="cutype" select="1" />
|
||||
<field name="role" select="1" />
|
||||
<separator colspan="4" string="" />
|
||||
<group col="6" colspan="4">
|
||||
<field name="state" select="2" />
|
||||
<button name="do_tentative"
|
||||
states="needs-action,declined,accepted"
|
||||
string="Uncertain"
|
||||
type="object"
|
||||
icon="terp-crm" />
|
||||
<button name="do_accept"
|
||||
string="Accept"
|
||||
states="needs-action,tentative,declined"
|
||||
type="object"
|
||||
icon="gtk-apply" />
|
||||
<button name="do_decline"
|
||||
string="Decline"
|
||||
states="needs-action,tentative,accepted"
|
||||
type="object"
|
||||
icon="gtk-cancel" />
|
||||
<button
|
||||
name="%(base_calendar.action_view_calendar_invite_attendee_wizard)d"
|
||||
string="Delegate"
|
||||
type="action"
|
||||
icon="gtk-sort-descending"
|
||||
states="needs-action,tentative,declined,accepted"
|
||||
context="{'model' : 'calendar.attendee', 'attendee_field' : 'child_ids'}" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="event_form_view">
|
||||
<field name="name">Event Form</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Events">
|
||||
<group col="6" colspan="4">
|
||||
<field name="name" select="1" string="Summary"
|
||||
colspan="4" />
|
||||
<field name="allday" colspan="2" on_change="onchange_allday(allday)" />
|
||||
<newline/>
|
||||
<field name="date" string="Start Date" required="1" select="1"
|
||||
on_change="onchange_dates(date,duration,False,allday)" />
|
||||
<field name="duration" widget="float_time"
|
||||
on_change="onchange_dates(date,duration,False,allday)" attrs="{'invisible': [('allday', '=', True)]}"/>
|
||||
<field name="date_deadline" string="End Date" required="1"
|
||||
on_change="onchange_dates(date,False,date_deadline)" />
|
||||
<field name="location" />
|
||||
<field name="alarm_id" string="Reminder"
|
||||
widget="selection" />
|
||||
<group colspan="2" col="4" >
|
||||
<field name="rrule_type" string="Recurrency"
|
||||
colspan="1" attrs="{'readonly':[('recurrent_uid','!=',False)]}"/>
|
||||
<button string="Edit All"
|
||||
help="Edit all Ourrences of recurrent Meeting"
|
||||
attrs="{'invisible':[('rrule_type','in', ('none', False))]}"
|
||||
name="open_event" icon="gtk-edit"
|
||||
type="object" />
|
||||
</group>
|
||||
</group>
|
||||
<group col="4" colspan="4" name="rrule" attrs="{'invisible': [('rrule_type','!=','custom')]}">
|
||||
<separator string="Select data for Custom Rule" colspan="8"/>
|
||||
<group col="8" colspan="4">
|
||||
<field name="freq" />
|
||||
<field name="interval" />
|
||||
<field name="count" />
|
||||
<field name="end_date" />
|
||||
</group>
|
||||
<group col="14" colspan="4" name="Select weekdays"
|
||||
attrs="{'invisible' : [('freq','!=','weekly')]}">
|
||||
<field name="mo" colspan="1" />
|
||||
<field name="tu" colspan="1" />
|
||||
<field name="we" colspan="1" />
|
||||
<field name="th" colspan="1" />
|
||||
<field name="fr" colspan="1" />
|
||||
<field name="sa" colspan="1" />
|
||||
<field name="su" colspan="1" />
|
||||
<newline />
|
||||
</group>
|
||||
<group col="10" colspan="4"
|
||||
attrs="{'invisible' : [('freq','!=','monthly'), ('freq','!=','yearly')]}">
|
||||
<group col="2" colspan="1">
|
||||
<field name="select1" />
|
||||
</group>
|
||||
<group col="2" colspan="1"
|
||||
attrs="{'invisible' : [('select1','=','day')]}">
|
||||
<field name="day"
|
||||
attrs="{'required' : [('select1','=','date')]}" />
|
||||
</group>
|
||||
<group col="3" colspan="1"
|
||||
attrs="{'invisible' : [('select1','=','date')]}">
|
||||
<field name="byday" string="The"
|
||||
attrs="{'required' : [('select1','=','day')]}" />
|
||||
<field name="week_list" nolabel="1"
|
||||
attrs="{'required' : [('select1','=','day')]}" />
|
||||
</group>
|
||||
<group col="1" colspan="1"
|
||||
attrs="{'invisible' : [('freq','!=','yearly')]}">
|
||||
<field name="month_list" string="of"
|
||||
colspan="1"
|
||||
attrs="{'required' : [('freq','=','yearly')]}" />
|
||||
</group>
|
||||
</group>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Event">
|
||||
<group col="6" colspan="4">
|
||||
<separator colspan="6" string="Visibility"/>
|
||||
<field name="user_id" string="Responsible User" />
|
||||
<field name="show_as" string="Show time as"/>
|
||||
<field name="class" string="Privacy"/>
|
||||
<field name="recurrent_id" invisible="1" />
|
||||
<field name="recurrent_uid" invisible="1" />
|
||||
</group>
|
||||
<separator string="Description" colspan="4" />
|
||||
<field name="description" nolabel="1" colspan="4" />
|
||||
<separator colspan="4"/>
|
||||
</page>
|
||||
<page string="Invitation Detail">
|
||||
<button string="Invite People"
|
||||
name="%(base_calendar.action_view_calendar_invite_attendee_wizard)d"
|
||||
icon="terp-partner" type="action"
|
||||
context="{'model' : 'calendar.event', 'attendee_field':'attendee_ids'}" colspan="2"/>
|
||||
<field name="attendee_ids" colspan="4"
|
||||
nolabel="1" widget="one2many" mode="tree,form">
|
||||
<tree string="Invitation details" editable="top">
|
||||
<field name="email" />
|
||||
<field name="role" width="200" select="1" />
|
||||
<field name="state" />
|
||||
</tree>
|
||||
<form string="Invitation details">
|
||||
<notebook colspan="4">
|
||||
<page string="Details">
|
||||
<field name="email" />
|
||||
<field name="rsvp" select="1" />
|
||||
<field name="cutype" select="1" />
|
||||
<field name="role" select="1" />
|
||||
<separator colspan="4" string="" />
|
||||
<group col="6" colspan="4">
|
||||
<field name="state" select="2" />
|
||||
<button name="do_tentative"
|
||||
states="needs-action,declined,accepted"
|
||||
string="Uncertain"
|
||||
type="object"
|
||||
icon="terp-crm" />
|
||||
<button name="do_accept"
|
||||
string="Accept"
|
||||
states="needs-action,tentative,declined"
|
||||
type="object"
|
||||
icon="gtk-apply" />
|
||||
<button name="do_decline"
|
||||
string="Decline"
|
||||
states="needs-action,tentative,accepted"
|
||||
type="object"
|
||||
icon="gtk-cancel" />
|
||||
<button
|
||||
name="%(base_calendar.action_view_calendar_invite_attendee_wizard)d"
|
||||
string="Delegate"
|
||||
type="action"
|
||||
icon="gtk-sort-descending"
|
||||
states="needs-action,tentative,declined,accepted"
|
||||
context="{'model' : 'calendar.attendee', 'attendee_field' : 'child_ids'}" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Event Tree View -->
|
||||
<!-- Event Tree View -->
|
||||
|
||||
<record model="ir.ui.view" id="event_tree_view">
|
||||
<field name="name">Event Tree</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Events">
|
||||
<field name="name" string="Subject" />
|
||||
<field name="date" string="Meeting Date" />
|
||||
<field name="location" />
|
||||
<field name="show_as" />
|
||||
<field name="class" string="Privacy" />
|
||||
<field name="user_id" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="event_tree_view">
|
||||
<field name="name">Event Tree</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Events">
|
||||
<field name="name" string="Subject" />
|
||||
<field name="date" string="Meeting Date" />
|
||||
<field name="location" />
|
||||
<field name="show_as" />
|
||||
<field name="class" string="Privacy" />
|
||||
<field name="user_id" invisible="1"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Event Calendar View -->
|
||||
<!-- Event Calendar View -->
|
||||
|
||||
<record model="ir.ui.view" id="event_calendar_view">
|
||||
<field name="name">Events Calendar</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">calendar</field>
|
||||
<field name="priority" eval="2"/>
|
||||
<field name="arch" type="xml">
|
||||
<calendar string="Events" date_start="date" color="show_as" date_delay="duration">
|
||||
<field name="name"/>
|
||||
<field name="class"/>
|
||||
<field name="show_as"/>
|
||||
</calendar>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="event_calendar_view">
|
||||
<field name="name">Events Calendar</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">calendar</field>
|
||||
<field name="priority" eval="2"/>
|
||||
<field name="arch" type="xml">
|
||||
<calendar string="Events" date_start="date" color="show_as" date_delay="duration">
|
||||
<field name="name"/>
|
||||
<field name="class"/>
|
||||
<field name="show_as"/>
|
||||
</calendar>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Event Search View-->
|
||||
<!-- Event Search View-->
|
||||
|
||||
<record id="view_calendar_event_filter" model="ir.ui.view">
|
||||
<field name="name">Calendar Events Search</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<record id="view_calendar_event_filter" model="ir.ui.view">
|
||||
<field name="name">Calendar Events Search</field>
|
||||
<field name="model">calendar.event</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Events">
|
||||
<group col="12" colspan="4">
|
||||
<filter icon="terp-go-today" string="My Events"
|
||||
@@ -390,42 +391,42 @@
|
||||
<field name="name" select="1" string="Summary"/>
|
||||
<field name="location" select="1" string="Location"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_id" select="1" widget="selection"/>
|
||||
<field name="user_id" select="1"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="show_as" select="1"/>
|
||||
<field name="class" select="1"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Date" icon="terp-go-month"
|
||||
domain="[]" context="{'group_by':'date'}" />
|
||||
<filter string="Availability" icon="terp-camera_test"
|
||||
domain="[]" context="{'group_by':'show_as'}" />
|
||||
<filter string="Privacy" icon="terp-locked"
|
||||
domain="[]" context="{'group_by':'class'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="Responsible" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'user_id'}" />
|
||||
</group>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Date" icon="terp-go-month"
|
||||
domain="[]" context="{'group_by':'date'}" />
|
||||
<filter string="Availability" icon="terp-camera_test"
|
||||
domain="[]" context="{'group_by':'show_as'}" />
|
||||
<filter string="Privacy" icon="terp-locked"
|
||||
domain="[]" context="{'group_by':'class'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="Responsible" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'user_id'}" />
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
|
||||
<!-- Event action -->
|
||||
<!-- Event action -->
|
||||
|
||||
<record id="action_view_event" model="ir.actions.act_window">
|
||||
<field name="name">Events</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">calendar.event</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form,calendar</field>
|
||||
<field name="search_view_id" ref="view_calendar_event_filter"/>
|
||||
</record>
|
||||
<record id="action_view_event" model="ir.actions.act_window">
|
||||
<field name="name">Events</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">calendar.event</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form,calendar</field>
|
||||
<field name="search_view_id" ref="view_calendar_event_filter"/>
|
||||
</record>
|
||||
|
||||
<!-- Event menu -->
|
||||
<!-- Event menu -->
|
||||
|
||||
<menuitem id="menu_events"
|
||||
<menuitem id="menu_events"
|
||||
name="Events" parent="base.menu_calendar_configuration"
|
||||
sequence="5" action="action_view_event" />
|
||||
|
||||
|
||||
Executable → Regular
+8
-8
@@ -1,9 +1,9 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_calendar_attendee","calendar.attendee","model_calendar_attendee",,1,1,1,1
|
||||
"access_calendar_alarm","calendar.alarm","model_calendar_alarm",,1,1,1,1
|
||||
"access_res_alarm","res.alarm","model_res_alarm",,1,1,1,1
|
||||
"access_calendar_event_all","calendar.event","model_calendar_event",,1,1,1,1
|
||||
"access_calendar_todo","calendar.todo","model_calendar_todo",,1,1,1,1
|
||||
"access_base_calendar_invite_attendee","base_calendar.invite.attendee","model_base_calendar_invite_attendee",,1,1,1,1
|
||||
"access_calendar_event_edit_all","calendar_event_edit_all","model_calendar_event_edit_all",,1,1,1,1
|
||||
"access_base_calendar_set_exrule","base.calendar.set.exrule","model_base_calendar_set_exrule",,1,1,1,1
|
||||
"access_calendar_attendee","calendar.attendee","model_calendar_attendee",base.group_user,1,1,1,1
|
||||
"access_calendar_alarm","calendar.alarm","model_calendar_alarm",base.group_user,1,1,1,1
|
||||
"access_res_alarm","res.alarm","model_res_alarm",base.group_user,1,1,1,1
|
||||
"access_calendar_event_all","calendar.event","model_calendar_event",base.group_user,1,1,1,1
|
||||
"access_calendar_todo","calendar.todo","model_calendar_todo",base.group_user,1,1,1,1
|
||||
"access_base_calendar_invite_attendee","base_calendar.invite.attendee","model_base_calendar_invite_attendee",base.group_user,1,1,1,1
|
||||
"access_calendar_event_edit_all","calendar_event_edit_all","model_calendar_event_edit_all",base.group_user,1,1,1,1
|
||||
"access_base_calendar_set_exrule","base.calendar.set.exrule","model_base_calendar_set_exrule",base.group_user,1,1,1,1
|
||||
|
||||
|
@@ -18,10 +18,10 @@
|
||||
If you don't think you need any of these right now, you can easily install them later on.</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='string'></attribute>
|
||||
<attribute name='rowspan'>15</attribute>
|
||||
</xpath>
|
||||
<separator string="title" position="attributes">
|
||||
<attribute name='string'></attribute>
|
||||
<attribute name='rowspan'>15</attribute>
|
||||
</xpath>
|
||||
<separator string="title" position="attributes">
|
||||
<attribute name="string">Install Generic Modules</attribute>
|
||||
</separator>
|
||||
<group colspan="8">
|
||||
@@ -29,7 +29,7 @@ If you don't think you need any of these right now, you can easily install them
|
||||
<field name="project" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/> <field name="knowledge" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/>
|
||||
<field name="stock" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/> <field name="mrp" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/>
|
||||
<field name="account" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/> <field name="purchase" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/>
|
||||
<field name="hr" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/> <field name="point_of_sale" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)" groups="base.group_extended"/>
|
||||
<field name="hr" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/> <field name="point_of_sale" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/>
|
||||
<field name="marketing" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)" groups="base.group_extended"/> <field name="misc_tools" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/>
|
||||
<field name="report_designer" groups="base.group_extended" on_change="onchange_moduleselection(crm,sale,project,knowledge,stock,mrp,account,purchase,hr,point_of_sale,marketing,misc_tools,report_designer,profile_association,profile_auction,profile_bookstore)"/>
|
||||
<separator string="Install Specific Business Modules" colspan="4"/>
|
||||
@@ -60,11 +60,11 @@ If you don't think you need any of these right now, you can easily install them
|
||||
<field name="name">base_setup_installer_action_replace</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="inherit_id" ref="base.ir_actions_todo_tree"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//button[@string='Launch']" position="replace">
|
||||
<button name="%(action_base_setup_installer)d" states="open,skip" string="Launch" type="action" icon="gtk-execute" help="Launch Configuration Wizard"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//button[@string='Launch']" position="replace">
|
||||
<button name="%(action_base_setup_installer)d" states="open,skip" string="Launch" type="action" icon="gtk-execute" help="Launch Configuration Wizard"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -10,45 +10,45 @@
|
||||
<form position="attributes">
|
||||
<attribute name="string">Main Company Setup</attribute>
|
||||
</form>
|
||||
<xpath expr="//label[@string='description']" position="attributes">
|
||||
<attribute name="string">Information of your company will be used to custiomise your documents like Invoices, Sale Orders,...</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="title"]' position='attributes'>
|
||||
<attribute name='string'>Configure Your Company</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='rowspan'>25</attribute>
|
||||
<attribute name='string'></attribute>
|
||||
</xpath>
|
||||
<xpath expr="//label[@string='description']" position="attributes">
|
||||
<attribute name="string">Information of your company will be used to custiomise your documents like Invoices, Sale Orders,...</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="title"]' position='attributes'>
|
||||
<attribute name='string'>Configure Your Company</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='rowspan'>25</attribute>
|
||||
<attribute name='string'></attribute>
|
||||
</xpath>
|
||||
<group string="res_config_contents" position="replace">
|
||||
<group colspan="5">
|
||||
<group colspan="2">
|
||||
<field name="company_id" invisible="1"/>
|
||||
<field name="name" required="True"/><field name="account_no"/>
|
||||
<field name="currency" widget="selection"/><field name="street"/>
|
||||
<field name="zip"/>
|
||||
<field name="street2"/>
|
||||
<field name="country_id"/>
|
||||
<field name="state_id"/>
|
||||
<field name="city"/>
|
||||
<field name="email"/>
|
||||
<field name="phone"/>
|
||||
<field name="website"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group colspan="2" groups="base.group_extended">
|
||||
<separator string="Report Information" colspan="4"/>
|
||||
<field name="rml_header1" colspan="5"/>
|
||||
<field name="rml_footer1" colspan="5"/>
|
||||
<field name="rml_footer2" colspan="5"/>
|
||||
<group colspan="5">
|
||||
<group colspan="2">
|
||||
<field name="company_id" invisible="1"/>
|
||||
<field name="name" required="True"/><field name="account_no"/>
|
||||
<field name="currency" widget="selection"/><field name="street"/>
|
||||
<field name="zip"/>
|
||||
<field name="street2"/>
|
||||
<field name="country_id"/>
|
||||
<field name="state_id"/>
|
||||
<field name="city"/>
|
||||
<field name="email"/>
|
||||
<field name="phone"/>
|
||||
<field name="website"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group colspan="2" groups="base.group_extended">
|
||||
<separator string="Report Information" colspan="4"/>
|
||||
<field name="rml_header1" colspan="5"/>
|
||||
<field name="rml_footer1" colspan="5"/>
|
||||
<field name="rml_footer2" colspan="5"/>
|
||||
|
||||
<separator colspan="4"
|
||||
string="Your Logo - Use a size of about 450x150 pixels."/>
|
||||
<field colspan="5" name="logo" widget="image"
|
||||
nolabel="1"/>
|
||||
</group>
|
||||
</group>
|
||||
</group>
|
||||
<separator colspan="4"
|
||||
string="Your Logo - Use a size of about 450x150 pixels."/>
|
||||
<field colspan="5" name="logo" widget="image"
|
||||
nolabel="1"/>
|
||||
</group>
|
||||
</group>
|
||||
</group>
|
||||
|
||||
<xpath expr='//button[@name="action_skip"]' position='replace'/>
|
||||
</data>
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink
|
||||
"access_base_setup_installer","base.setup.installer","model_base_setup_installer",,1,0,0,0
|
||||
"access_base_setup_company","base.setup.company","model_base_setup_company",,1,0,0,0
|
||||
"access_base_setup_config","base.setup.config","model_base_setup_config",,1,0,0,0
|
||||
"access_base_setup_installer","base.setup.installer","model_base_setup_installer",base.group_system,1,1,1,1
|
||||
"access_base_setup_company","base.setup.company","model_base_setup_company",base.group_system,1,1,1,1
|
||||
"access_base_setup_config","base.setup.config","model_base_setup_config",base.group_system,1,1,1,1
|
||||
|
||||
|
@@ -2,13 +2,13 @@
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<menuitem icon="terp-graph" id="base.dashboard" name="Dashboards" sequence="2" parent="base.reporting_menu"/>
|
||||
<menuitem icon="terp-graph" id="base.dashboard" name="Dashboards" sequence="2" parent="base.reporting_menu"/>
|
||||
<menuitem
|
||||
id="menu_purchase_deshboard"
|
||||
name="Purchase"
|
||||
parent="base.dashboard"/>
|
||||
|
||||
<record id="purchase_draft" model="ir.actions.act_window">
|
||||
<record id="purchase_draft" model="ir.actions.act_window">
|
||||
<field name="name">Draft Purchases</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">purchase.order</field>
|
||||
@@ -17,7 +17,7 @@
|
||||
<field name="domain">[('date_order','>',time.strftime('%Y-01-01 00:00:00')),('date_order','<',time.strftime('%Y-12-31 23:59:59')), ('state','=','draft')]</field>
|
||||
<field name="search_view_id" ref="purchase.purchase_order_tree"/>
|
||||
</record>
|
||||
<record id="purchase_waiting" model="ir.actions.act_window">
|
||||
<record id="purchase_waiting" model="ir.actions.act_window">
|
||||
<field name="name">Quotation Request</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">purchase.order</field>
|
||||
@@ -47,7 +47,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="open_board_purchase" model="ir.actions.act_window">
|
||||
<record id="open_board_purchase" model="ir.actions.act_window">
|
||||
<field name="name">Purchase Dashboard</field>
|
||||
<field name="res_model">board.board</field>
|
||||
<field name="view_type">form</field>
|
||||
@@ -55,7 +55,7 @@
|
||||
<field name="usage">menu</field>
|
||||
<field name="view_id" ref="board_purchase_form"/>
|
||||
</record>
|
||||
<menuitem
|
||||
<menuitem
|
||||
action="open_board_purchase"
|
||||
icon="terp-graph"
|
||||
id="menu_board_purchase"
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
|
||||
<menuitem id="base.menu_sales" name="Sales"
|
||||
parent="base.menu_base_partner" sequence="1" />
|
||||
|
||||
|
||||
<menuitem parent="base.menu_sales" name="Leads"
|
||||
groups="base.group_extended"
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
states="open,pending" type="object"
|
||||
icon="gtk-go-forward" />
|
||||
</group>
|
||||
<field name="type" readonly="1"/>
|
||||
<field name="type" invisible="1"/>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Lead">
|
||||
@@ -311,7 +311,7 @@
|
||||
<separator orientation="vertical"/>
|
||||
<field name="partner_name"/>
|
||||
<field name="email_from"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<field name="user_id">
|
||||
<filter icon="terp-personal-"
|
||||
domain="[('user_id','=', False)]"
|
||||
help="Unassigned Leads" />
|
||||
|
||||
+20
-11
@@ -32,11 +32,12 @@ from tools.translate import _
|
||||
import tools
|
||||
from osv import fields,osv,orm
|
||||
from osv.orm import except_orm
|
||||
import collections
|
||||
|
||||
from tools import command_re
|
||||
|
||||
class crm_cases(osv.osv):
|
||||
""" crm cases """
|
||||
class mailgate_thread(osv.osv):
|
||||
""" mailgate_thread """
|
||||
|
||||
_name = "mailgate.thread"
|
||||
_inherit = "mailgate.thread"
|
||||
@@ -127,7 +128,7 @@ class crm_cases(osv.osv):
|
||||
#getattr(self, act)(cr, uid, select)
|
||||
return res
|
||||
|
||||
def emails_get(self, cr, uid, ids, context={}):
|
||||
def emails_get(self, cr, uid, ids, context=None):
|
||||
|
||||
"""
|
||||
Get Emails
|
||||
@@ -137,16 +138,24 @@ class crm_cases(osv.osv):
|
||||
@param ids: List of email’s IDs
|
||||
@param context: A standard dictionary for contextual values
|
||||
"""
|
||||
res = []
|
||||
res = {}
|
||||
|
||||
if isinstance(ids, (str, int, long)):
|
||||
select = [ids]
|
||||
select = [long(ids)]
|
||||
else:
|
||||
select = ids
|
||||
for case in self.browse(cr, uid, select):
|
||||
user_email = (case.user_id and case.user_id.address_id and case.user_id.address_id.email) or False
|
||||
res += [(user_email, case.email_from, case.email_cc or False, getattr(case,'priority') and case.priority or False)]
|
||||
if isinstance(ids, (str, int, long)):
|
||||
return len(res) and res[0] or False
|
||||
|
||||
for thread in self.browse(cr, uid, select, context=context):
|
||||
values = collections.defaultdict(set)
|
||||
|
||||
for message in thread.message_ids:
|
||||
user_email = (message.user_id and message.user_id.address_id and message.user_id.address_id.email) or False
|
||||
values['user_email'].add(user_email)
|
||||
values['email_from'].add(message.email_from)
|
||||
values['email_cc'].add(message.email_cc or False)
|
||||
|
||||
res[str(thread.id)] = dict((key,list(values[key])) for key, value in values.iteritems())
|
||||
|
||||
return res
|
||||
|
||||
def msg_send(self, cr, uid, id, *args, **argv):
|
||||
@@ -161,4 +170,4 @@ class crm_cases(osv.osv):
|
||||
"""
|
||||
return True
|
||||
|
||||
crm_cases()
|
||||
mailgate_thread()
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
<field name="act_window_id" ref="crm_case_categ_meet_create_partner"/>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_meet_partner">
|
||||
<record model="ir.actions.act_window.view" id="action_crm_tag_gantt_meet_partner">
|
||||
<field name="sequence" eval="3"/>
|
||||
<field name="view_mode">gantt</field>
|
||||
<field name="view_id" ref="crm_case_gantt_view_meet"/>
|
||||
@@ -85,33 +85,33 @@
|
||||
<!-- ALL MEETINGS -->
|
||||
|
||||
<menuitem name="Meetings" id="menu_meeting_sale"
|
||||
parent="base.menu_base_partner" sequence="3" />
|
||||
parent="base.menu_base_partner" sequence="3" />
|
||||
|
||||
<menuitem name="Meetings" id="menu_crm_case_categ_meet"
|
||||
action="crm_case_categ_meet" parent="menu_meeting_sale"
|
||||
sequence="1" />
|
||||
action="crm_case_categ_meet" parent="menu_meeting_sale"
|
||||
sequence="1" />
|
||||
|
||||
<record id="ir_ui_view_sc_calendar0" model="ir.ui.view_sc">
|
||||
<record id="ir_ui_view_sc_calendar0" model="ir.ui.view_sc">
|
||||
<field name="name">Calendar</field>
|
||||
<field name="resource">ir.ui.menu</field>
|
||||
<field name="user_id" ref="base.user_root"/>
|
||||
<field name="res_id" ref="crm.menu_crm_case_categ_meet"/>
|
||||
</record>
|
||||
</record>
|
||||
<record id="action_view_attendee_form" model="ir.actions.act_window">
|
||||
<field name="name">Meeting Invitations</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">calendar.attendee</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="base_calendar.base_calendar_attendee_tree_view" />
|
||||
<field name="name">Meeting Invitations</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">calendar.attendee</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="base_calendar.base_calendar_attendee_tree_view" />
|
||||
<field name="domain">[('ref','like','crm.meeting,')]</field>
|
||||
<field name="context">{'default_sent_by_uid': uid}</field>
|
||||
</record>
|
||||
<field name="context">{'default_sent_by_uid': uid}</field>
|
||||
</record>
|
||||
|
||||
<menuitem id="menu_attendee_invitations"
|
||||
name="Meeting Invitations" parent="crm.menu_meeting_sale"
|
||||
sequence="10" action="action_view_attendee_form"
|
||||
groups="base.group_extended" />
|
||||
name="Meeting Invitations" parent="crm.menu_meeting_sale"
|
||||
sequence="10" action="action_view_attendee_form"
|
||||
groups="base.group_extended" />
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<!-- CRM Meetings Categories Form View -->
|
||||
<!-- CRM Meetings Categories Form View -->
|
||||
|
||||
<record id="crm_meeting_categ_action" model="ir.actions.act_window">
|
||||
<field name="name">Meeting Categories</field>
|
||||
@@ -16,7 +16,7 @@
|
||||
<menuitem action="crm_meeting_categ_action" name="Categories"
|
||||
id="menu_crm_case_meeting-act" parent="menu_crm_config_meeting" />
|
||||
|
||||
<!-- CRM Meetings Form View -->
|
||||
<!-- CRM Meetings Form View -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_form_view_meet">
|
||||
<field name="name">CRM - Meetings Form</field>
|
||||
@@ -26,7 +26,7 @@
|
||||
<form string="Meetings">
|
||||
<group col="6" colspan="4">
|
||||
<field name="name" select="1" string="Summary"
|
||||
required="1" colspan="2" />
|
||||
required="1" colspan="2" />
|
||||
<field name="categ_id" widget="selection"
|
||||
string="Meeting Type"
|
||||
groups="base.group_extended"
|
||||
@@ -51,9 +51,9 @@
|
||||
name="open_meeting" icon="gtk-edit"
|
||||
type="object" />
|
||||
<button string="ExRule"
|
||||
name="%(base_calendar.action_base_calendar_set_exrule)d" icon="gtk-zoom-out" type="action"
|
||||
context="{'model' : 'crm.meeting'}"
|
||||
attrs="{'invisible':[('rrule_type','in', ('none', False))]}"/>
|
||||
name="%(base_calendar.action_base_calendar_set_exrule)d" icon="gtk-zoom-out" type="action"
|
||||
context="{'model' : 'crm.meeting'}"
|
||||
attrs="{'invisible':[('rrule_type','in', ('none', False))]}"/>
|
||||
</group>
|
||||
</group>
|
||||
<group col="4" colspan="4" name="rrule" attrs="{'invisible': [('rrule_type','!=','custom')]}">
|
||||
@@ -133,7 +133,7 @@
|
||||
<button name="case_close" string="Done"
|
||||
states="open" type="object"
|
||||
icon="gtk-jump-to" />
|
||||
<button name="case_reset" string="Reset to Unconfirmed"
|
||||
<button name="case_reset" string="Reset to Unconfirmed"
|
||||
states="open,done,cancel" type="object"
|
||||
icon="gtk-convert" />
|
||||
<button name="case_open" string="Confirm"
|
||||
@@ -204,7 +204,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Meeting Tree View -->
|
||||
<!-- CRM Meeting Tree View -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_tree_view_meet">
|
||||
<field name="name">CRM - Meetings Tree</field>
|
||||
@@ -222,7 +222,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Meeting Calendar -->
|
||||
<!-- CRM Meeting Calendar -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_calendar_view_meet">
|
||||
<field name="name">CRM - Meetings Calendar</field>
|
||||
@@ -238,7 +238,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Meeting Gantt -->
|
||||
<!-- CRM Meeting Gantt -->
|
||||
|
||||
<record id="crm_case_gantt_view_meet" model="ir.ui.view">
|
||||
<field name="name">CRM - Meetings Gantt</field>
|
||||
@@ -254,7 +254,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Meeting Search View -->
|
||||
<!-- CRM Meeting Search View -->
|
||||
|
||||
<record id="view_crm_case_meetings_filter" model="ir.ui.view">
|
||||
<field name="name">CRM - Meetings Search</field>
|
||||
@@ -274,29 +274,29 @@
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
help="My Sale Team" />
|
||||
</field>
|
||||
<field name="user_id" select="1" widget="selection"/>
|
||||
<field name="user_id" select="1"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Date" icon="terp-go-month"
|
||||
domain="[]" context="{'group_by':'date'}" />
|
||||
<filter string="Privacy" icon="terp-locked"
|
||||
domain="[]" context="{'group_by':'class'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="Responsible" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'user_id'}" />
|
||||
<filter string="Partner" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'partner_id'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" domain="[]"
|
||||
context="{'group_by':'state'}" />
|
||||
<separator orientation="vertical" />
|
||||
</group>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Date" icon="terp-go-month"
|
||||
domain="[]" context="{'group_by':'date'}" />
|
||||
<filter string="Privacy" icon="terp-locked"
|
||||
domain="[]" context="{'group_by':'class'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="Responsible" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'user_id'}" />
|
||||
<filter string="Partner" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'partner_id'}" />
|
||||
<separator orientation="vertical" />
|
||||
<filter string="State" icon="terp-stock_effects-object-colorize" domain="[]"
|
||||
context="{'group_by':'state'}" />
|
||||
<separator orientation="vertical" />
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Calendar Attendee Form View -->
|
||||
<!-- Calendar Attendee Form View -->
|
||||
|
||||
<record id="attendee_form_view_inherit" model="ir.ui.view">
|
||||
<field name="name">calendar.attendee.form.inherit</field>
|
||||
@@ -310,7 +310,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Calendar Attendee Tree View -->
|
||||
<!-- Calendar Attendee Tree View -->
|
||||
|
||||
<record id="attendee_tree_view_inherit" model="ir.ui.view">
|
||||
<field name="name">calendar.attendee.tree.inherit</field>
|
||||
|
||||
@@ -51,8 +51,9 @@ class crm_opportunity(osv.osv):
|
||||
'ref2': fields.reference('Reference 2', selection=crm._links_get, size=128),
|
||||
'phone': fields.char("Phone", size=64),
|
||||
'date_deadline': fields.date('Expected Closing'),
|
||||
'date_action': fields.date('Next Action'),
|
||||
}
|
||||
'date_action': fields.date('Next Action Date'),
|
||||
'title_action': fields.char('Next Action', size=64),
|
||||
}
|
||||
def case_close(self, cr, uid, ids, *args):
|
||||
"""Overrides close for crm_case for setting probability and close date
|
||||
@param self: The object pointer
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
<openerp>
|
||||
<data noupdate="1">
|
||||
|
||||
<act_window
|
||||
<act_window
|
||||
id="act_crm_opportunity_crm_phonecall_new"
|
||||
name="Phone calls"
|
||||
res_model="crm.phonecall"
|
||||
@@ -12,7 +12,7 @@
|
||||
domain="[('user_id','=',uid),('opportunity_id', '=', active_id)]"
|
||||
view_type="form"/>
|
||||
|
||||
<act_window
|
||||
<act_window
|
||||
id="act_crm_opportunity_crm_meeting_new"
|
||||
name="Meetings"
|
||||
res_model="crm.meeting"
|
||||
@@ -25,11 +25,10 @@
|
||||
<record model="ir.actions.act_window" id="crm_case_category_act_oppor11">
|
||||
<field name="name">Opportunities</field>
|
||||
<field name="res_model">crm.lead</field>
|
||||
<field name="view_mode">tree,form,graph</field>
|
||||
<field name="domain">['|',('type','=','opportunity'),('state','=','draft')]</field>
|
||||
<field name="context">{'search_default_user_id':uid,'search_default_current':1}</field>
|
||||
<field name="view_mode">tree,form,graph,calendar</field>
|
||||
<field name="domain">[('type','=','opportunity')]</field>
|
||||
<field name="context">{'search_default_user_id':uid,'search_default_current':1, 'default_type': 'opportunity'}</field>
|
||||
<field name="view_id" ref="crm_case_tree_view_oppor"/>
|
||||
<field name="context">{'search_default_current':1, 'default_type': 'opportunity'}</field>
|
||||
<field name="search_view_id" ref="crm.view_crm_case_opportunities_filter"/>
|
||||
</record>
|
||||
|
||||
@@ -55,11 +54,11 @@
|
||||
</record>
|
||||
|
||||
<menuitem id="base.menu_sales" name="Sales"
|
||||
parent="base.menu_base_partner" sequence="1" />
|
||||
parent="base.menu_base_partner" sequence="1" />
|
||||
|
||||
<menuitem name="Opportunities" id="menu_crm_case_opp"
|
||||
parent="base.menu_sales" action="crm_case_category_act_oppor11"
|
||||
sequence="2" />
|
||||
parent="base.menu_sales" action="crm_case_category_act_oppor11"
|
||||
sequence="2" />
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
id="menu_crm_opportunity_stage_act" name="Stages"
|
||||
parent="menu_crm_config_opportunity" />
|
||||
|
||||
<!-- Opportunity Resource Type Form View -->
|
||||
<!-- Opportunity Resource Type Form View -->
|
||||
|
||||
<record id="crm_opportunity_resource_act" model="ir.actions.act_window">
|
||||
<field name="name">Opportunity Resource Type</field>
|
||||
@@ -81,8 +81,10 @@
|
||||
name="%(opportunity2phonecall_act)d" icon="gtk-redo" type="action" />
|
||||
<newline/>
|
||||
<field name="date_action"/>
|
||||
<field name="title_action"/>
|
||||
<field name="priority" string="Priority"/>
|
||||
<field name="type" readonly="1"/>
|
||||
<newline/>
|
||||
<field name="type" invisible="1"/>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Opportunity">
|
||||
@@ -133,6 +135,27 @@
|
||||
icon="gtk-convert" />
|
||||
</group>
|
||||
</page>
|
||||
<page string="Lead">
|
||||
<group colspan="2" col="4">
|
||||
<separator string="Contact" colspan="4" col="4"/>
|
||||
<field name="partner_name" string="Partner Name" colspan="4"/>
|
||||
<newline/>
|
||||
<field domain="[('domain', '=', 'contact')]" name="title"/>
|
||||
<field name="function" />
|
||||
<field name="street" colspan="4"/>
|
||||
<field name="street2" colspan="4"/>
|
||||
<field name="zip"/>
|
||||
<field name="city"/>
|
||||
<field name="country_id"/>
|
||||
<field name="state_id"/>
|
||||
</group>
|
||||
<group colspan="2" col="3">
|
||||
<separator string="Communication" colspan="4" col="3"/>
|
||||
<field name="fax"/>
|
||||
<newline/>
|
||||
<field name="mobile"/>
|
||||
</group>
|
||||
</page>
|
||||
|
||||
<page string="Emails" groups="base.group_extended">
|
||||
<group colspan="4">
|
||||
@@ -160,10 +183,10 @@
|
||||
icon="gtk-undo" type="action" />
|
||||
</form>
|
||||
<tree string="Communication history">
|
||||
<field name="date"/>
|
||||
<field name="email_from" />
|
||||
<field name="email_to"/>
|
||||
<field name="description"/>
|
||||
<field name="date"/>
|
||||
<field name="email_from" />
|
||||
<field name="email_to"/>
|
||||
<field name="description"/>
|
||||
</tree>
|
||||
</field>
|
||||
<button colspan="2" string="Send New Email"
|
||||
@@ -223,8 +246,8 @@
|
||||
<field name="create_date"/>
|
||||
<field name="name" string="Opportunity"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="date_action"/>
|
||||
<field name="stage_id"/>
|
||||
<field name="categ_id" invisible="1" groups="base.group_extended"/>
|
||||
<button name="stage_previous" string="Previous"
|
||||
states="open,pending" type="object" icon="gtk-go-back" />
|
||||
<button name="stage_next" string="Next"
|
||||
@@ -232,10 +255,9 @@
|
||||
icon="gtk-go-forward" />
|
||||
<field name="planned_revenue" sum="Total of Planned Revenue"/>
|
||||
<field name="probability" widget="progressbar" avg="Avg. of Probability"/>
|
||||
<field name="date_action"/>
|
||||
<field name="section_id" groups="base.group_extended"/>
|
||||
<field name="section_id"
|
||||
invisible="context.get('invisible_section', True)" />
|
||||
<field name="user_id"/>
|
||||
<field name="priority"/>
|
||||
<field name="state"/>
|
||||
<button name="case_open" string="Open"
|
||||
states="draft,pending" type="object"
|
||||
@@ -297,17 +319,23 @@
|
||||
/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="name" string="Opportunity"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<field name="user_id">
|
||||
<filter icon="terp-personal-"
|
||||
domain="[('user_id','=', False)]"
|
||||
help="Unassigned Opportunities" />
|
||||
</field>
|
||||
<field name="section_id"
|
||||
default="context.get('section_id', False)" select="1"
|
||||
default="context.get('section_id', False)"
|
||||
context="{'invisible_section': False}"
|
||||
widget="selection">
|
||||
<filter icon="terp-personal+"
|
||||
domain="[('section_id','=',context.get('section_id',False))]"
|
||||
domain="[('section_id.user_id','=',uid)]"
|
||||
context="{'invisible_section': False}"
|
||||
help="My Sale Team" />
|
||||
<filter icon="terp-personal+"
|
||||
context="{'invisible_section': False}"
|
||||
domain="[]"
|
||||
help="Show Sales Team"/>
|
||||
</field>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By..." colspan="16">
|
||||
|
||||
@@ -261,7 +261,7 @@
|
||||
<separator orientation="vertical"/>
|
||||
<field name="name" string="Call Summary"/>
|
||||
<field name="partner_id"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<field name="user_id">
|
||||
<filter icon="terp-personal-"
|
||||
domain="[('user_id','=',False)]"
|
||||
help="Unassigned Phonecalls" />
|
||||
|
||||
+20
-20
@@ -2,22 +2,22 @@
|
||||
<openerp>
|
||||
<data>
|
||||
<menuitem id="base.menu_crm_config_sales" name="Sales"
|
||||
parent="base.menu_base_config" sequence="1" groups="base.group_extended"/>
|
||||
parent="base.menu_base_config" sequence="1"/>
|
||||
|
||||
<menuitem id="menu_crm_config_lead" name="Lead"
|
||||
parent="base.menu_crm_config_sales" sequence="0" groups="base.group_extended"/>
|
||||
|
||||
<menuitem id="menu_crm_config_opportunity" name="Opportunity"
|
||||
parent="base.menu_crm_config_sales" sequence="1" groups="base.group_extended"/>
|
||||
parent="base.menu_crm_config_sales" sequence="1"/>
|
||||
|
||||
<menuitem id="menu_crm_config_meeting" name="Meeting"
|
||||
parent="base.menu_base_config" sequence="4" groups="base.group_extended"/>
|
||||
parent="base.menu_base_config" sequence="4"/>
|
||||
|
||||
<menuitem id="menu_crm_config_phonecall" name="Phone Call"
|
||||
parent="base.menu_base_config" sequence="5" groups="base.group_extended"/>
|
||||
|
||||
<menuitem id="base.next_id_64" name="Reporting"
|
||||
parent="base.menu_base_partner" sequence="8" />
|
||||
parent="base.menu_base_partner" sequence="8" />
|
||||
|
||||
<!-- Case Sections Form View -->
|
||||
|
||||
@@ -57,7 +57,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Case Sections Tree View -->
|
||||
<!-- Case Sections Tree View -->
|
||||
|
||||
<record id="crm_case_section_view_tree" model="ir.ui.view">
|
||||
<field name="name">crm.case.section.tree</field>
|
||||
@@ -73,7 +73,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Case Sections Action -->
|
||||
<!-- Case Sections Action -->
|
||||
|
||||
<record id="crm_case_section_act" model="ir.actions.act_window">
|
||||
<field name="name">Sales Team</field>
|
||||
@@ -82,7 +82,7 @@
|
||||
<field name="view_id" ref="crm_case_section_view_tree"/>
|
||||
</record>
|
||||
|
||||
<!-- CRM Stage Tree View -->
|
||||
<!-- CRM Stage Tree View -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_stage_tree">
|
||||
<field name="name">crm.case.stage.tree</field>
|
||||
@@ -99,7 +99,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Stage Form View -->
|
||||
<!-- CRM Stage Form View -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_stage_form">
|
||||
<field name="name">crm.case.stage.form</field>
|
||||
@@ -120,7 +120,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Stage Action -->
|
||||
<!-- CRM Stage Action -->
|
||||
|
||||
<record id="crm_case_stage_act" model="ir.actions.act_window">
|
||||
<field name="name">Stages</field>
|
||||
@@ -144,7 +144,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Case Categories Tree View -->
|
||||
<!-- Case Categories Tree View -->
|
||||
|
||||
<record id="crm_case_categ_tree-view" model="ir.ui.view">
|
||||
<field name="name">crm.case.categ.tree</field>
|
||||
@@ -158,7 +158,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Case Categories Action -->
|
||||
<!-- Case Categories Action -->
|
||||
|
||||
<record id="crm_case_categ-act" model="ir.actions.act_window">
|
||||
<field name="name">Categories</field>
|
||||
@@ -173,7 +173,7 @@
|
||||
|
||||
|
||||
|
||||
<!-- Resource Type of case Tree View -->
|
||||
<!-- Resource Type of case Tree View -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_resource_type_tree">
|
||||
<field name="name">crm.case.resource.type.tree</field>
|
||||
@@ -188,7 +188,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Resource Type of case Form View -->
|
||||
<!-- Resource Type of case Form View -->
|
||||
|
||||
<record model="ir.ui.view" id="crm_case_resource_type_form">
|
||||
<field name="name">crm.case.resource.type.form</field>
|
||||
@@ -203,7 +203,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Resource Type of case Action -->
|
||||
<!-- Resource Type of case Action -->
|
||||
|
||||
<record id="crm_case_resource_type_act" model="ir.actions.act_window">
|
||||
<field name="name">Resource Type</field>
|
||||
@@ -220,7 +220,7 @@
|
||||
<field name="view_id" ref="crm_case_section_view_tree"/>
|
||||
</record>
|
||||
|
||||
<!-- Cases Tree View -->
|
||||
<!-- Cases Tree View -->
|
||||
|
||||
<record id="crm_case_log_tree-view" model="ir.ui.view">
|
||||
<field name="name">crm.case.log.tree</field>
|
||||
@@ -240,7 +240,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Segmentation line Tree View -->
|
||||
<!-- Segmentation line Tree View -->
|
||||
|
||||
<record id="crm_segmentation_line_tree-view" model="ir.ui.view">
|
||||
<field name="name">crm.segmentation.line.tree</field>
|
||||
@@ -257,7 +257,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Segmentation line Form View -->
|
||||
<!-- Segmentation line Form View -->
|
||||
|
||||
<record id="crm_segmentation_line-view" model="ir.ui.view">
|
||||
<field name="name">crm.segmentation.line.form</field>
|
||||
@@ -277,7 +277,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Segmentation Form View -->
|
||||
<!-- CRM Segmentation Form View -->
|
||||
|
||||
<record id="crm_segmentation-view" model="ir.ui.view">
|
||||
<field name="name">crm.segmentation.form</field>
|
||||
@@ -322,7 +322,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- CRM Segmentation Tree View -->
|
||||
<!-- CRM Segmentation Tree View -->
|
||||
|
||||
<record id="crm_segmentation_tree-view" model="ir.ui.view">
|
||||
<field name="name">crm.segmentation.tree</field>
|
||||
@@ -383,7 +383,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Inherit View From Partner -->
|
||||
<!-- Inherit View From Partner -->
|
||||
|
||||
<record id="view_partners_form_crm1" model="ir.ui.view">
|
||||
<field name="name">view.res.partner.form.crm.inherited1</field>
|
||||
|
||||
@@ -232,11 +232,9 @@
|
||||
</record>
|
||||
|
||||
<menuitem name="Leads Analysis" id="menu_report_crm_leads_tree"
|
||||
groups="base.group_extended"
|
||||
parent="base.next_id_64" action="action_report_crm_lead" />
|
||||
|
||||
<menuitem name="Opportunities Analysis" id="menu_report_crm_opportunities_tree"
|
||||
groups="base.group_extended"
|
||||
<menuitem name="Opportunities Analysis" id="menu_report_crm_opportunities_tree"
|
||||
parent="base.next_id_64" action="action_report_crm_opportunity" />
|
||||
|
||||
</data>
|
||||
|
||||
@@ -187,9 +187,8 @@
|
||||
<field name="act_window_id" ref="action_report_crm_phonecall"/>
|
||||
</record>
|
||||
|
||||
<menuitem name="Phone Calls"
|
||||
<menuitem name="Phone Calls Analysis"
|
||||
action="action_report_crm_phonecall"
|
||||
groups="base.group_extended"
|
||||
id="menu_report_crm_phonecalls_tree" parent="base.next_id_64" />
|
||||
|
||||
</data>
|
||||
|
||||
@@ -4,58 +4,62 @@
|
||||
|
||||
<!-- Partners inherited form -->
|
||||
|
||||
<record id="view_crm_partner_info_form" model="ir.ui.view">
|
||||
<field name="name">res.partner.crm.info.inherit</field>
|
||||
<field name="model">res.partner</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//notebook[last()]" position="after">
|
||||
<field name="meeting_ids" colspan="4" nolabel="1" />
|
||||
<field name="phonecall_ids" colspan="4" nolabel="1" />
|
||||
<field name="opportunity_ids" colspan="4" nolabel="1" domain="[('type', '=', 'opportunity')]">
|
||||
<tree string="Opportunities" colors="blue:state=='pending';grey:state in ('cancel', 'done')">
|
||||
<field name="create_date"/>
|
||||
<field name="partner_name"/>
|
||||
<field name="name"/>
|
||||
<field name="email_from"/>
|
||||
<field name="phone"/>
|
||||
|
||||
<field name="categ_id" invisible="1"/>
|
||||
<field name="type_id" invisible="1"/>
|
||||
<field name="referred" invisible="1"/>
|
||||
|
||||
<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" />
|
||||
<field name="section_id"
|
||||
invisible="context.get('invisible_section', True)" />
|
||||
<field name="user_id" />
|
||||
<field name="state" />
|
||||
<button name="case_open" string="Open"
|
||||
states="draft,pending" type="object"
|
||||
icon="gtk-go-forward" />
|
||||
<button name="case_close" string="Close"
|
||||
states="open,draft,pending" type="object"
|
||||
icon="gtk-close" />
|
||||
<button string="Convert to Opportunity"
|
||||
name="convert_opportunity"
|
||||
states="draft,open,pending" icon="gtk-index"
|
||||
type="object" />
|
||||
<button name="case_escalate" string="Escalate"
|
||||
states="open,draft,pending" type="object"
|
||||
icon="gtk-go-up" />
|
||||
<button name="case_cancel" string="Cancel"
|
||||
states="draft,open,pending" type="object"
|
||||
icon="gtk-cancel" />
|
||||
</tree>
|
||||
</field>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
<!-- <record id="view_crm_partner_info_form" model="ir.ui.view">-->
|
||||
<!-- <field name="name">res.partner.crm.info.inherit</field>-->
|
||||
<!-- <field name="model">res.partner</field>-->
|
||||
<!-- <field name="type">form</field>-->
|
||||
<!-- <field name="inherit_id" ref="base.view_partner_form"/>-->
|
||||
<!-- <field name="arch" type="xml">-->
|
||||
<!-- <xpath expr="//notebook[last()]" position="after">-->
|
||||
<!-- <notebook colspan="4">-->
|
||||
<!-- <page string="CRM">-->
|
||||
<!-- <field name="meeting_ids" colspan="4" nolabel="1" />-->
|
||||
<!-- <field name="phonecall_ids" colspan="4" nolabel="1" />-->
|
||||
<!-- <field name="opportunity_ids" colspan="4" nolabel="1" domain="[('type', '=', 'opportunity')]">-->
|
||||
<!-- <tree string="Opportunities" colors="blue:state=='pending';grey:state in ('cancel', 'done')">-->
|
||||
<!-- <field name="create_date"/>-->
|
||||
<!-- <field name="partner_name"/>-->
|
||||
<!-- <field name="name"/>-->
|
||||
<!-- <field name="email_from"/>-->
|
||||
<!-- <field name="phone"/>-->
|
||||
<!-- -->
|
||||
<!-- <field name="categ_id" invisible="1"/>-->
|
||||
<!-- <field name="type_id" invisible="1"/>-->
|
||||
<!-- <field name="referred" invisible="1"/>-->
|
||||
<!-- -->
|
||||
<!-- <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" />-->
|
||||
<!-- <field name="section_id"-->
|
||||
<!-- invisible="context.get('invisible_section', True)" />-->
|
||||
<!-- <field name="user_id" />-->
|
||||
<!-- <field name="state" />-->
|
||||
<!-- <button name="case_open" string="Open"-->
|
||||
<!-- states="draft,pending" type="object"-->
|
||||
<!-- icon="gtk-go-forward" />-->
|
||||
<!-- <button name="case_close" string="Close"-->
|
||||
<!-- states="open,draft,pending" type="object"-->
|
||||
<!-- icon="gtk-close" />-->
|
||||
<!-- <button string="Convert to Opportunity"-->
|
||||
<!-- name="convert_opportunity"-->
|
||||
<!-- states="draft,open,pending" icon="gtk-index"-->
|
||||
<!-- type="object" />-->
|
||||
<!-- <button name="case_escalate" string="Escalate"-->
|
||||
<!-- states="open,draft,pending" type="object"-->
|
||||
<!-- icon="gtk-go-up" />-->
|
||||
<!-- <button name="case_cancel" string="Cancel"-->
|
||||
<!-- states="draft,open,pending" type="object"-->
|
||||
<!-- icon="gtk-cancel" />-->
|
||||
<!-- </tree>-->
|
||||
<!-- </field>-->
|
||||
<!-- </page>-->
|
||||
<!-- </notebook>-->
|
||||
<!-- </xpath>-->
|
||||
<!-- </field>-->
|
||||
<!-- </record>-->
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -1,19 +1,23 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_crm_segmentation_user","crm.segmentation user","model_crm_segmentation","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_segmentation_line_user","crm.segmentation.line user","model_crm_segmentation_line","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_segmentation","crm.segmentation","model_crm_segmentation","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_segmentation_line","crm.segmentation.line","model_crm_segmentation_line","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_case_section","crm.case.section","model_crm_case_section","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_case_categ","crm.case.categ","model_crm_case_categ","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_meeting","crm.meeting","model_crm_meeting","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_lead","crm.lead","model_crm_lead","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_phonecall","crm.phonecall","model_crm_phonecall","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_meeting","crm.meeting","model_crm_meeting","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_lead","crm.lead","model_crm_lead","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_phonecall","crm.phonecall","model_crm_phonecall","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_case_section_user","crm.case.section.user","model_crm_case_section","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_case_section_manager","crm.case.section.manager","model_crm_case_section","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_case_categ_user","crm.case.categ.user","model_crm_case_categ","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_case_categ_manager","crm.case.categ.manager","model_crm_case_categ","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_case_stage","crm.case.stage","model_crm_case_stage","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_case_stage_manager","crm.case.stage","model_crm_case_stage","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_case_resource_type_user","crm_case_resource_type user","model_crm_case_resource_type","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_case_resource_type_manager","crm_case_resource_type manager","model_crm_case_resource_type","crm.group_crm_manager",1,1,1,1
|
||||
"access_crm_lead_report_user","crm.lead.report","model_crm_lead_report","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_phonecall_report_user","crm.phonecall.report","model_crm_phonecall_report","crm.group_crm_user",1,0,0,0
|
||||
"access_crm_lead_report_manager","crm.lead.report","model_crm_lead_report","crm.group_crm_manager",1,0,0,0
|
||||
"access_crm_phonecall_report_manager","crm.phonecall.report","model_crm_phonecall_report","crm.group_crm_manager",1,0,0,0
|
||||
"access_crm_lead2partner","crm.lead2partner","model_crm_lead2partner","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_lead2opportunity","crm.lead2opportunity","model_crm_lead2opportunity","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_opportunity2phonecall","crm.opportunity2phonecall","model_crm_opportunity2phonecall","crm.group_crm_user",1,1,1,1
|
||||
@@ -24,6 +28,11 @@
|
||||
"access_crm_send_mail_attachment","crm.send.mail.attachment","model_crm_send_mail_attachment","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_partner2opportunity","crm.partner2opportunity","model_crm_partner2opportunity","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_lead2opportunity_partner","crm.lead2opportunity.partner","model_crm_lead2opportunity_partner","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_installer","crm.installer.rule","model_crm_installer","crm.group_crm_user",1,1,1,1
|
||||
"access_crm_lead_forward_to_partner","crm.lead.forward.to.partner","model_crm_lead_forward_to_partner","crm.group_crm_user",2,2,2,2
|
||||
"access_crm_installer","crm.installer.rule","model_crm_installer","base.group_system",1,1,1,1
|
||||
"access_crm_lead_forward_to_partner","crm.lead.forward.to.partner","model_crm_lead_forward_to_partner","crm.group_crm_user",1,1,1,1
|
||||
"access_mailgate_thread","mailgate.thread","model_mailgate_thread","crm.group_crm_user",1,1,1,1
|
||||
"access_res_partner","res.partner.crm.user","base.model_res_partner","crm.group_crm_user",1,0,0,0
|
||||
"access_res_partner_address","res.partner.address.crm.user","base.model_res_partner_address","crm.group_crm_user",1,0,0,0
|
||||
"access_res_partner_category","res.partner.category.crm.user","base.model_res_partner_category","crm.group_crm_user",1,0,0,0
|
||||
"mail_gateway_mailgate_message","mail_gateway.mailgate.message","mail_gateway.model_mailgate_message","crm.group_crm_user",1,1,1,1
|
||||
"mail_gateway_mailgate_thread","mail_gateway.mailgate.thread","model_mailgate_thread","crm.group_crm_user",1,1,1,1
|
||||
|
||||
|
@@ -1,6 +1,6 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
@@ -15,7 +15,7 @@
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
import pooler
|
||||
@@ -50,11 +50,11 @@ class open_questionnaire(wizard.interface):
|
||||
states = {
|
||||
'init': {
|
||||
'actions': [],
|
||||
'result': {'type': 'form', 'arch': _questionnaire_choice_arch, 'fields': _questionnaire_choice_fields, 'state':[('end', 'Cancel'), ('open', 'Open Questionnaire')]}
|
||||
'result': {'type': 'form', 'arch': _questionnaire_choice_arch, 'fields': _questionnaire_choice_fields, 'state':[('end', 'Cancel','gtk-cancel'), ('open', 'Open Questionnaire','terp-camera_test')]}
|
||||
},
|
||||
'open': {
|
||||
'actions': [build_form],
|
||||
'result': {'type': 'form', 'arch':_QUEST_FORM, 'fields': _QUEST_FIELDS, 'state':[('end', 'Cancel'), ('compute', 'Save Data')]}
|
||||
'result': {'type': 'form', 'arch':_QUEST_FORM, 'fields': _QUEST_FIELDS, 'state':[('end', 'Cancel','gtk-cancel'), ('compute', 'Save Data','terp-stock_format-scientific')]}
|
||||
},
|
||||
'compute': {
|
||||
'actions': [],
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
<field colspan="4" name="line_ids" nolabel="1" select="1"/>
|
||||
</page>
|
||||
<page string="Destination">
|
||||
<separator colspan="4" string="Countries"/>
|
||||
<separator colspan="4" string="Countries"/>
|
||||
<field colspan="4" name="country_ids" nolabel="1"/>
|
||||
<separator colspan="4" string="States"/>
|
||||
<field colspan="4" name="state_ids" nolabel="1"/>
|
||||
@@ -243,18 +243,6 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_move_withweight_tree" model="ir.ui.view">
|
||||
<field name="name">stock.move.tree.weight</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="model">stock.move</field>
|
||||
<field name="inherit_id" ref="stock.view_move_tree"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="product_uom" position="after">
|
||||
<field name="weight"/>
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_move_withweight_form" model="ir.ui.view">
|
||||
<field name="name">stock.move.form.weight</field>
|
||||
<field name="type">form</field>
|
||||
@@ -267,18 +255,6 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_move_reception_picking_withweight_tree" model="ir.ui.view">
|
||||
<field name="name">stock.move.reception.packing.tree.weight</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="model">stock.move</field>
|
||||
<field name="inherit_id" ref="stock.view_move_tree_reception_picking"/>
|
||||
<field name="arch" type="xml">
|
||||
<field name="product_uom" position="after">
|
||||
<field name="weight"/>
|
||||
</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>
|
||||
@@ -297,8 +273,8 @@
|
||||
<field name="inherit_id" ref="sale.view_order_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/notebook/page[@string='Sale Order']/group[1]/button[@name='button_dummy']" position="after">
|
||||
<button name="%(action_delivery_cost)d" states="draft" string="Delivery Costs" type="action" icon="gtk-execute" context="{'order_id':id}"/>
|
||||
</xpath>
|
||||
<button name="%(action_delivery_cost)d" states="draft" string="Delivery Costs" type="action" icon="gtk-execute" context="{'order_id':id}"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
@@ -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-04-23 09:08+0000\n"
|
||||
"Last-Translator: grisha <Unknown>\n"
|
||||
"PO-Revision-Date: 2010-06-11 16:12+0000\n"
|
||||
"Last-Translator: Sios <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-04-24 03:52+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-12 03:44+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: delivery
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<!--<menuitem name="Document Management" icon="terp-stock" id="menu_document"/>
|
||||
<menuitem name="Document Configuration" id="menu_document_configuration" parent="menu_document"/>-->
|
||||
|
||||
<menuitem name="Knowledge Management" icon="terp-stock" id="base.menu_document" sequence="4"/>
|
||||
<menuitem name="Knowledge" icon="terp-stock" id="base.menu_document" sequence="4" groups="base.group_user"/>
|
||||
<menuitem name="Configuration" id="base.menu_document_configuration" parent="base.menu_document" sequence="50"/>
|
||||
<menuitem name="Document Management" id="menu_document_management_configuration" parent="base.menu_document_configuration" sequence="1"/>
|
||||
|
||||
@@ -13,15 +13,15 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Storage Media">
|
||||
<group colspan="4" col="4">
|
||||
<field name="name" select="1" colspan="4"/>
|
||||
<field name="user_id"/>
|
||||
<field name="type"/>
|
||||
<field name="online"/>
|
||||
<field name="readonly"/>
|
||||
<group colspan="4" col="4">
|
||||
<field name="name" select="1" colspan="4"/>
|
||||
<field name="user_id"/>
|
||||
<field name="type"/>
|
||||
<field name="online"/>
|
||||
<field name="readonly"/>
|
||||
</group>
|
||||
<group colspan="2" attrs="{'invisible':[('type','!=','realstore')]}">
|
||||
<field name="path"/>
|
||||
<field name="path"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
@@ -71,13 +71,13 @@
|
||||
<newline/>
|
||||
<field name="domain" attrs="{'required': [('type','=','ressource')], 'readonly': [('type','=','static')]}"/>
|
||||
<field name="ressource_tree"/>
|
||||
<field name="resource_field" domain="[('model_id','=',ressource_type_id), ('ttype', 'in', ('char', 'selection', 'date', 'datetime'))]"/>
|
||||
<field name="resource_field" domain="[('model_id','=',ressource_type_id), ('ttype', 'in', ('char', 'selection', 'date', 'datetime'))]"/>
|
||||
<field name="ressource_id" select="2" readonly="1"/>
|
||||
<field name="ressource_parent_type_id"/>
|
||||
</page>
|
||||
<page string="Generated Files">
|
||||
<label colspan="4" string="For each entry here, virtual files will appear in this folder." />
|
||||
<field name="content_ids" nolabel="1" colspan="4" attrs="{'readonly': [('ressource_type_id','=',False)]}">
|
||||
<field name="content_ids" nolabel="1" colspan="4" attrs="{'readonly': [('ressource_type_id','=',False)]}">
|
||||
<form string="Contents">
|
||||
<field name="name"/>
|
||||
<field name="sequence"/>
|
||||
@@ -237,19 +237,19 @@
|
||||
help="less 1 month modified/created attachments"
|
||||
domain="[('create_date','<=', time.strftime('%%Y-%%m-%%d')),('create_date','>',(datetime.date.today()-datetime.timedelta(days=30)).strftime('%%Y-%%m-%%d'))]"
|
||||
/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_id">
|
||||
<filter icon="terp-personal"
|
||||
domain="[('user_id','=', False)]"
|
||||
help="Filter on my Attachment" />
|
||||
</field>
|
||||
<field name="partner_id" widget="selection"/>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By...">
|
||||
</field>
|
||||
<field name="partner_id"/>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Partner" icon="terp-personal" domain="[]"
|
||||
context="{'group_by':'partner_id'}" />
|
||||
<filter string="Directory" icon="terp-folder-green" domain="[]" context="{'group_by':'parent_id'}"/>
|
||||
</group>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
import doc_conf_wizard
|
||||
import ftpserver
|
||||
import wizard
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
@@ -33,7 +33,8 @@
|
||||
'depends': ['base', 'document'],
|
||||
'init_xml': [],
|
||||
'update_xml': [
|
||||
'document_ftp_view.xml',
|
||||
'wizard/ftp_browse_view.xml',
|
||||
'wizard/document_configuration_view.xml',
|
||||
'security/ir.model.access.csv'
|
||||
],
|
||||
'demo_xml': [],
|
||||
|
||||
@@ -1,149 +0,0 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
# published by the Free Software Foundation, either version 3 of the
|
||||
# License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
import base64
|
||||
|
||||
from osv import osv, fields
|
||||
from osv.orm import except_orm
|
||||
import urlparse
|
||||
|
||||
import os
|
||||
|
||||
class document_configuration_wizard(osv.osv_memory):
|
||||
|
||||
_name='document.configuration.wizard'
|
||||
_description = 'Auto Directory Configuration'
|
||||
_inherit = 'res.config'
|
||||
_rec_name = 'host'
|
||||
_columns = {
|
||||
'host': fields.char('Address', size=64,
|
||||
help="Server address or IP.", required=True),
|
||||
}
|
||||
|
||||
def detect_ip_addr(self, cr, uid, context=None):
|
||||
def _detect_ip_addr(self, cr, uid, context=None):
|
||||
from array import array
|
||||
import socket
|
||||
from struct import pack, unpack
|
||||
|
||||
try:
|
||||
import fcntl
|
||||
except ImportError:
|
||||
fcntl = None
|
||||
|
||||
if not fcntl: # not UNIX:
|
||||
host = socket.gethostname()
|
||||
ip_addr = socket.gethostbyname(host)
|
||||
else: # UNIX:
|
||||
# get all interfaces:
|
||||
nbytes = 128 * 32
|
||||
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
|
||||
names = array('B', '\0' * nbytes)
|
||||
outbytes = unpack('iL', fcntl.ioctl( s.fileno(), 0x8912, pack('iL', nbytes, names.buffer_info()[0])))[0]
|
||||
namestr = names.tostring()
|
||||
ifaces = [namestr[i:i+32].split('\0', 1)[0] for i in range(0, outbytes, 32)]
|
||||
|
||||
for ifname in [iface for iface in ifaces if iface != 'lo']:
|
||||
ip_addr = socket.inet_ntoa(fcntl.ioctl(s.fileno(), 0x8915, pack('256s', ifname[:15]))[20:24])
|
||||
break
|
||||
return ip_addr
|
||||
|
||||
try:
|
||||
ip_addr = _detect_ip_addr(self, cr, uid, context)
|
||||
except:
|
||||
ip_addr = 'localhost'
|
||||
return ip_addr
|
||||
|
||||
_defaults = {
|
||||
'host': detect_ip_addr,
|
||||
}
|
||||
|
||||
def execute(self, cr, uid, ids, context=None):
|
||||
conf = self.browse(cr, uid, ids[0], context)
|
||||
obj=self.pool.get('document.directory')
|
||||
objid=self.pool.get('ir.model.data')
|
||||
|
||||
if self.pool.get('sale.order'):
|
||||
id = objid._get_id(cr, uid, 'document', 'dir_sale_order_all')
|
||||
id = objid.browse(cr, uid, id, context=context).res_id
|
||||
mid = self.pool.get('ir.model').search(cr, uid, [('model','=','sale.order')])
|
||||
obj.write(cr, uid, [id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
'domain': '[]',
|
||||
})
|
||||
aid = objid._get_id(cr, uid, 'sale', 'report_sale_order')
|
||||
aid = objid.browse(cr, uid, aid, context=context).res_id
|
||||
|
||||
self.pool.get('document.directory.content').create(cr, uid, {
|
||||
'name': "Print Order",
|
||||
'suffix': "_print",
|
||||
'report_id': aid,
|
||||
'extension': '.pdf',
|
||||
'include_name': 1,
|
||||
'directory_id': id,
|
||||
})
|
||||
id = objid._get_id(cr, uid, 'document', 'dir_sale_order_quote')
|
||||
id = objid.browse(cr, uid, id, context=context).res_id
|
||||
obj.write(cr, uid, [id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
'domain': "[('state','=','draft')]",
|
||||
})
|
||||
|
||||
if self.pool.get('product.product'):
|
||||
id = objid._get_id(cr, uid, 'document', 'dir_product')
|
||||
id = objid.browse(cr, uid, id, context=context).res_id
|
||||
mid = self.pool.get('ir.model').search(cr, uid, [('model','=','product.product')])
|
||||
obj.write(cr, uid, [id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
})
|
||||
|
||||
if self.pool.get('stock.location'):
|
||||
aid = objid._get_id(cr, uid, 'stock', 'report_product_history')
|
||||
aid = objid.browse(cr, uid, aid, context=context).res_id
|
||||
|
||||
self.pool.get('document.directory.content').create(cr, uid, {
|
||||
'name': "Product Stock",
|
||||
'suffix': "_stock_forecast",
|
||||
'report_id': aid,
|
||||
'extension': '.pdf',
|
||||
'include_name': 1,
|
||||
'directory_id': id,
|
||||
})
|
||||
|
||||
if self.pool.get('account.analytic.account'):
|
||||
id = objid._get_id(cr, uid, 'document', 'dir_project')
|
||||
id = objid.browse(cr, uid, id, context=context).res_id
|
||||
mid = self.pool.get('ir.model').search(cr, uid, [('model','=','account.analytic.account')])
|
||||
obj.write(cr, uid, [id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
'domain': '[]',
|
||||
'ressource_tree': 1
|
||||
})
|
||||
|
||||
# Update the action for FTP browse.
|
||||
aid = objid._get_id(cr, uid, 'document_ftp', 'action_document_browse')
|
||||
aid = objid.browse(cr, uid, aid, context=context).res_id
|
||||
self.pool.get('ir.actions.url').write(cr, uid, [aid], {'url': 'ftp://'+(conf.host or 'localhost')+':8021/'})
|
||||
document_configuration_wizard()
|
||||
@@ -0,0 +1,24 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
# published by the Free Software Foundation, either version 3 of the
|
||||
# License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
import ftp_browse
|
||||
import document_configuration
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
@@ -0,0 +1,121 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
# published by the Free Software Foundation, either version 3 of the
|
||||
# License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
from osv import osv, fields
|
||||
from document_ftp import ftpserver
|
||||
class document_configuration(osv.osv_memory):
|
||||
|
||||
_name='document.configuration'
|
||||
_description = 'Auto Directory Configuration'
|
||||
_inherit = 'res.config'
|
||||
|
||||
_columns = {
|
||||
'sale_order' : fields.boolean('Sale Order', help="Auto directory configuration for Sale Orders and Quotation with report."),
|
||||
'product' : fields.boolean('Product', help="Auto directory configuration for Products."),
|
||||
'project': fields.boolean('Project', help="Auto directory configuration for Projects."),
|
||||
}
|
||||
|
||||
|
||||
def execute(self, cr, uid, ids, context=None):
|
||||
conf_id = ids and ids[0] or False
|
||||
conf = self.browse(cr, uid, conf_id, context)
|
||||
dir_pool = self.pool.get('document.directory')
|
||||
data_pool = self.pool.get('ir.model.data')
|
||||
model_pool = self.pool.get('ir.model')
|
||||
content_pool = self.pool.get('document.directory.content')
|
||||
if conf.sale_order and self.pool.get('sale.order'):
|
||||
# Sale order
|
||||
dir_data_id = data_pool._get_id(cr, uid, 'document', 'dir_sale_order_all')
|
||||
if dir_data_id:
|
||||
sale_dir_id = data_pool.browse(cr, uid, dir_data_id, context=context).res_id
|
||||
else:
|
||||
sale_dir_id = data_pool.create(cr, uid, {'name': 'Sale Orders'})
|
||||
mid = model_pool.search(cr, uid, [('model','=','sale.order')])
|
||||
dir_pool.write(cr, uid, [sale_dir_id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
'domain': '[]',
|
||||
})
|
||||
# Qutation
|
||||
dir_data_id = data_pool._get_id(cr, uid, 'document', 'dir_sale_order_quote')
|
||||
if dir_data_id:
|
||||
quta_dir_id = data_pool.browse(cr, uid, dir_data_id, context=context).res_id
|
||||
else:
|
||||
quta_dir_id = data_pool.create(cr, uid, {'name': 'Sale Quotations'})
|
||||
|
||||
dir_pool.write(cr, uid, [quta_dir_id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
'domain': "[('state','=','draft')]",
|
||||
})
|
||||
# Sale Order Report
|
||||
order_report_data_id = data_pool._get_id(cr, uid, 'sale', 'report_sale_order')
|
||||
if order_report_data_id:
|
||||
order_report_id = data_pool.browse(cr, uid, order_report_data_id, context=context).res_id
|
||||
|
||||
content_pool.create(cr, uid, {
|
||||
'name': "Print Order",
|
||||
'suffix': "_print",
|
||||
'report_id': order_report_id,
|
||||
'extension': '.pdf',
|
||||
'include_name': 1,
|
||||
'directory_id': sale_dir_id,
|
||||
})
|
||||
|
||||
content_pool.create(cr, uid, {
|
||||
'name': "Print Qutation",
|
||||
'suffix': "_print",
|
||||
'report_id': order_report_id,
|
||||
'extension': '.pdf',
|
||||
'include_name': 1,
|
||||
'directory_id': quta_dir_id,
|
||||
})
|
||||
|
||||
|
||||
if conf.product and self.pool.get('product.product'):
|
||||
# Product
|
||||
dir_data_id = data_pool._get_id(cr, uid, 'document', 'dir_product')
|
||||
if dir_data_id:
|
||||
product_dir_id = data_pool.browse(cr, uid, dir_data_id, context=context).res_id
|
||||
else:
|
||||
product_dir_id = data_pool.create(cr, uid, {'name': 'Products'})
|
||||
|
||||
mid = model_pool.search(cr, uid, [('model','=','product.product')])
|
||||
dir_pool.write(cr, uid, [product_dir_id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
})
|
||||
|
||||
if conf.project and self.pool.get('account.analytic.account'):
|
||||
# Project
|
||||
dir_data_id = data_pool._get_id(cr, uid, 'document', 'dir_project')
|
||||
if dir_data_id:
|
||||
project_dir_id = data_pool.browse(cr, uid, dir_data_id, context=context).res_id
|
||||
else:
|
||||
project_dir_id = data_pool.create(cr, uid, {'name': 'Projects'})
|
||||
|
||||
mid = model_pool.search(cr, uid, [('model','=','account.analytic.account')])
|
||||
dir_pool.write(cr, uid, [project_dir_id], {
|
||||
'type':'ressource',
|
||||
'ressource_type_id': mid[0],
|
||||
'domain': '[]',
|
||||
'ressource_tree': 1
|
||||
})
|
||||
document_configuration()
|
||||
+9
-19
@@ -1,22 +1,8 @@
|
||||
<openerp>
|
||||
<data>
|
||||
<record model="ir.actions.url" id="action_document_browse">
|
||||
<field name="name">Browse Files</field>
|
||||
<field name="url">ftp://localhost:8021/</field>
|
||||
</record>
|
||||
<menuitem
|
||||
name="Shared Repository (FTP)"
|
||||
action="action_document_browse"
|
||||
id="menu_document_browse"
|
||||
type="url"
|
||||
icon="STOCK_EXECUTE"
|
||||
parent="document.menu_document_doc" sequence="1"/>
|
||||
|
||||
|
||||
|
||||
<record id="view_auto_config_form" model="ir.ui.view">
|
||||
<field name="name">Auto Configure Directory</field>
|
||||
<field name="model">document.configuration.wizard</field>
|
||||
<field name="model">document.configuration</field>
|
||||
<field name="type">form</field>
|
||||
<field name="inherit_id" ref="base.res_config_view_base"/>
|
||||
<field name="arch" type="xml">
|
||||
@@ -25,17 +11,21 @@
|
||||
<attribute name="string">Auto Configure</attribute>
|
||||
</form>
|
||||
<separator string="title" position="attributes">
|
||||
<attribute name="string">FTP Server Configuration</attribute>
|
||||
<attribute name="string">Resource Directory Configuration </attribute>
|
||||
</separator>
|
||||
<xpath expr="//label[@string='description']" position="attributes">
|
||||
<attribute name="string">Choose the address for the Document Management System's FTP server.</attribute>
|
||||
<attribute name="string">Choose the following Resouces to auto directory configuration.</attribute>
|
||||
</xpath>
|
||||
<xpath expr='//separator[@string="vsep"]' position='attributes'>
|
||||
<attribute name='rowspan'>12</attribute>
|
||||
<attribute name='string'></attribute>
|
||||
</xpath>
|
||||
<group string="res_config_contents" position="replace">
|
||||
<field name="host"/>
|
||||
<group col="6" colspan="4">
|
||||
<field name="sale_order"/>
|
||||
<field name="product"/>
|
||||
<field name="project"/>
|
||||
</group>
|
||||
</group>
|
||||
<xpath expr="//button[@name='action_skip']" position="replace"/>
|
||||
</data>
|
||||
@@ -45,7 +35,7 @@
|
||||
<record id="action_config_auto_directory" model="ir.actions.act_window">
|
||||
<field name="name">Auto Configure Directory</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">document.configuration.wizard</field>
|
||||
<field name="res_model">document.configuration</field>
|
||||
<field name="view_id" ref="view_auto_config_form"/>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
@@ -0,0 +1,53 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
# published by the Free Software Foundation, either version 3 of the
|
||||
# License, or (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU Affero General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
##############################################################################
|
||||
|
||||
from osv import osv, fields
|
||||
from tools.translate import _
|
||||
|
||||
from document_ftp import ftpserver
|
||||
class document_ftp_browse(osv.osv_memory):
|
||||
_name = 'document.ftp.browse'
|
||||
_description = 'Document FTP Browse'
|
||||
|
||||
_columns = {
|
||||
'url' : fields.char('FTP Server', size=64, required=True),
|
||||
}
|
||||
|
||||
def default_get(self, cr, uid, fields, context=None):
|
||||
res = {}
|
||||
if 'url' in fields:
|
||||
user_pool = self.pool.get('res.users')
|
||||
current_user = user_pool.browse(cr, uid, uid, context=context)
|
||||
res['url'] = '%s@%s:%d'%(current_user.login, ftpserver.HOST, ftpserver.PORT)
|
||||
return res
|
||||
|
||||
def browse_ftp(self, cr, uid, ids, context):
|
||||
data_id = ids and ids[0] or False
|
||||
data = self.browse(cr, uid, data_id, context)
|
||||
ftp_url = 'ftp://'
|
||||
final_url = ftp_url + data.url
|
||||
return {
|
||||
'type': 'ir.actions.act_url',
|
||||
'url':final_url,
|
||||
'target': 'new'
|
||||
}
|
||||
document_ftp_browse()
|
||||
|
||||
@@ -0,0 +1,40 @@
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<record id="ftp_browse_form" model="ir.ui.view">
|
||||
<field name="name">Document FTP Browse</field>
|
||||
<field name="model">document.ftp.browse</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Browse Document">
|
||||
<separator string="Browse Document" colspan="4"/>
|
||||
<field name="url" widget="url" colspan="4"/>
|
||||
<separator colspan="4"/>
|
||||
<group col="4" colspan="4">
|
||||
<label string="" colspan="2"/>
|
||||
<button special="cancel" string="Cancel" icon="gtk-cancel"/>
|
||||
<button name="browse_ftp" string="Browse" type="object" icon="gtk-ok"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_ftp_browse" model="ir.actions.act_window">
|
||||
<field name="name">Document Browse</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="res_model">document.ftp.browse</field>
|
||||
<field name="view_id" ref="ftp_browse_form"/>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="target">new</field>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
name="Shared Repository (FTP)"
|
||||
action="action_ftp_browse"
|
||||
id="menu_document_browse"
|
||||
icon="STOCK_EXECUTE"
|
||||
parent="document.menu_document_doc" sequence="1"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
Executable → Regular
Executable → Regular
+1
@@ -16,6 +16,7 @@
|
||||
'email_template_view.xml',
|
||||
'email_template_mailbox_view.xml',
|
||||
'wizard/email_template_send_wizard_view.xml',
|
||||
'security/ir.model.access.csv'
|
||||
],
|
||||
"installable": True,
|
||||
"active": False,
|
||||
|
||||
Executable → Regular
+19
-11
@@ -17,10 +17,10 @@ try:
|
||||
TEMPLATE_ENGINES.append(('mako', 'Mako Templates'))
|
||||
except:
|
||||
LOGGER.notifyChannel(
|
||||
_("Email Template"),
|
||||
netsvc.LOG_ERROR,
|
||||
_("Mako templates not installed")
|
||||
)
|
||||
_("Email Template"),
|
||||
netsvc.LOG_WARNING,
|
||||
_("Mako templates not installed")
|
||||
)
|
||||
try:
|
||||
from django.template import Context, Template as DjangoTemplate
|
||||
#Workaround for bug:
|
||||
@@ -31,10 +31,10 @@ try:
|
||||
TEMPLATE_ENGINES.append(('django', 'Django Template'))
|
||||
except:
|
||||
LOGGER.notifyChannel(
|
||||
_("Email Template"),
|
||||
netsvc.LOG_ERROR,
|
||||
_("Django templates not installed")
|
||||
)
|
||||
_("Email Template"),
|
||||
netsvc.LOG_WARNING,
|
||||
_("Django templates not installed")
|
||||
)
|
||||
|
||||
import email_template_engines
|
||||
import tools
|
||||
@@ -468,7 +468,7 @@ class email_template(osv.osv):
|
||||
context)
|
||||
return True
|
||||
|
||||
def generate_mailbox_item_from_template(self,
|
||||
def _generate_mailbox_item_from_template(self,
|
||||
cursor,
|
||||
user,
|
||||
template,
|
||||
@@ -559,6 +559,8 @@ class email_template(osv.osv):
|
||||
'folder':'drafts',
|
||||
'mail_type':'multipart/alternative'
|
||||
}
|
||||
if not mailbox_values['account_id']:
|
||||
raise Exception("Unable to send the mail. No account linked to the template.")
|
||||
#Use signatures if allowed
|
||||
if template.use_sign:
|
||||
sign = self.pool.get('res.users').read(cursor,
|
||||
@@ -570,13 +572,17 @@ class email_template(osv.osv):
|
||||
mailbox_values['body_text'] += sign
|
||||
if mailbox_values['body_html']:
|
||||
mailbox_values['body_html'] += sign
|
||||
print 'Creating', mailbox_values
|
||||
mailbox_id = self.pool.get('email_template.mailbox').create(
|
||||
cursor,
|
||||
user,
|
||||
mailbox_values,
|
||||
context)
|
||||
|
||||
print 'Sending', mailbox_id
|
||||
self.pool.get('email_template.mailbox').send_this_mail(cursor, user, [mailbox_id], context)
|
||||
return mailbox_id
|
||||
|
||||
|
||||
def generate_mail(self,
|
||||
cursor,
|
||||
user,
|
||||
@@ -588,6 +594,7 @@ class email_template(osv.osv):
|
||||
template = self.browse(cursor, user, template_id, context=context)
|
||||
if not template:
|
||||
raise Exception("The requested template could not be loaded")
|
||||
print 'loaded', record_ids
|
||||
for record_id in record_ids:
|
||||
mailbox_id = self._generate_mailbox_item_from_template(
|
||||
cursor,
|
||||
@@ -595,6 +602,7 @@ class email_template(osv.osv):
|
||||
template,
|
||||
record_id,
|
||||
context)
|
||||
print 'loaded'
|
||||
mail = self.pool.get('email_template.mailbox').browse(
|
||||
cursor,
|
||||
user,
|
||||
@@ -616,7 +624,7 @@ class email_template(osv.osv):
|
||||
mailbox_id,
|
||||
{'folder':'outbox'},
|
||||
context=context
|
||||
)
|
||||
)
|
||||
return True
|
||||
|
||||
email_template()
|
||||
|
||||
Executable → Regular
Executable → Regular
+69
-69
@@ -1,69 +1,69 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<data>
|
||||
|
||||
<menuitem name="Tools" id="base.menu_tools" icon="STOCK_PREFERENCES" sequence="15"/>
|
||||
<menuitem name="Email Template" id="menu_email_template" parent="base.menu_tools"/>
|
||||
|
||||
<record model="ir.ui.view" id="email_template_account_form">
|
||||
<field name="name">email_template.account.form</field>
|
||||
<field name="model">email_template.account</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Email Account Configuration">
|
||||
<group colspan="2">
|
||||
<field name="name" select="1" />
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Outgoing">
|
||||
<separator string="Server Information" colspan="4" />
|
||||
<group colspan="4">
|
||||
<field name="smtpserver" select="1" colspan="2" />
|
||||
<field name="smtpport" select="2" colspan="2" />
|
||||
<field name="smtpssl" select="2" colspan="2" />
|
||||
<field name="smtptls" select="2" colspan="2" />
|
||||
</group>
|
||||
<button name="check_outgoing_connection" type="object" string="Check Outgoing Connection" />
|
||||
<separator string="User Information" colspan="4" />
|
||||
<group col="2" colspan="2">
|
||||
<field name="email_id" select="1" on_change="on_change_emailid(name,email_id)" colspan="2" />
|
||||
<field name="smtppass" password="True" colspan="2" />
|
||||
<field name="company" select="2" colspan="2" />
|
||||
</group>
|
||||
<group col="2" colspan="2">
|
||||
<field name="smtpuname" select="1" colspan="2" />
|
||||
<field name="user" select="2" colspan="2" />
|
||||
<field name="send_pref" colspan="2" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
<group colspan="4" col="10">
|
||||
<field name="state" select="1"/>
|
||||
<button string="Approve Account" name="button_approval" states="draft" type="workflow"/>
|
||||
<button string="Suspend Account" name="button_suspended" states="approved" type="workflow" />
|
||||
<button string="Request Re-activation" name="get_reapprove" states="suspended" type="workflow" />
|
||||
<button string="Send/Receive" name="send_receive" states="approved" type="object" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="email_template_account_form">
|
||||
<field name="name">email_template.account.form</field>
|
||||
<field name="model">email_template.account</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Email Account Configuration">
|
||||
<group colspan="2">
|
||||
<field name="name" select="1" />
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Outgoing">
|
||||
<separator string="Server Information" colspan="4" />
|
||||
<group colspan="4">
|
||||
<field name="smtpserver" select="1" colspan="2" />
|
||||
<field name="smtpport" select="2" colspan="2" />
|
||||
<field name="smtpssl" select="2" colspan="2" />
|
||||
<field name="smtptls" select="2" colspan="2" />
|
||||
</group>
|
||||
<button name="check_outgoing_connection" type="object" string="Check Outgoing Connection" />
|
||||
<separator string="User Information" colspan="4" />
|
||||
<group col="2" colspan="2">
|
||||
<field name="email_id" select="1" on_change="on_change_emailid(name,email_id)" colspan="2" />
|
||||
<field name="smtppass" password="True" colspan="2" />
|
||||
<field name="company" select="2" colspan="2" />
|
||||
</group>
|
||||
<group col="2" colspan="2">
|
||||
<field name="smtpuname" select="1" colspan="2" />
|
||||
<field name="user" select="2" colspan="2" />
|
||||
<field name="send_pref" colspan="2" />
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
<group colspan="4" col="10">
|
||||
<field name="state" select="1"/>
|
||||
<button string="Approve Account" name="button_approval" states="draft" type="workflow"/>
|
||||
<button string="Suspend Account" name="button_suspended" states="approved" type="workflow" />
|
||||
<button string="Request Re-activation" name="get_reapprove" states="suspended" type="workflow" />
|
||||
<button string="Send/Receive" name="send_receive" states="approved" type="object" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="email_template_account_tree">
|
||||
<field name="name">email_template.account.tree</field>
|
||||
<field name="model">email_template.account</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="SMTP Server">
|
||||
<field name="name" select="2" />
|
||||
<field name="email_id" select="2" />
|
||||
<field name="smtpuname" select="2" />
|
||||
<field name="user" select="2" />
|
||||
<field name="smtpserver" select="2" />
|
||||
<field name="smtpport" select="2" />
|
||||
<field name="state" select="2" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="email_template_account_tree">
|
||||
<field name="name">email_template.account.tree</field>
|
||||
<field name="model">email_template.account</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="SMTP Server">
|
||||
<field name="name" select="2" />
|
||||
<field name="email_id" select="2" />
|
||||
<field name="smtpuname" select="2" />
|
||||
<field name="user" select="2" />
|
||||
<field name="smtpserver" select="2" />
|
||||
<field name="smtpport" select="2" />
|
||||
<field name="state" select="2" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_email_template_account_search" model="ir.ui.view">
|
||||
<field name="name">email_template.account.search</field>
|
||||
@@ -85,21 +85,21 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window" id="action_email_template_account_tree_all">
|
||||
<field name="name">Accounts</field>
|
||||
<field name="res_model">email_template.account</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form,tree</field>
|
||||
<field name="view_id" ref="email_template_account_tree" />
|
||||
<record model="ir.actions.act_window" id="action_email_template_account_tree_all">
|
||||
<field name="name">Accounts</field>
|
||||
<field name="res_model">email_template.account</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form,tree</field>
|
||||
<field name="view_id" ref="email_template_account_tree" />
|
||||
<field name="context">{'group_by': [], 'search_default_draft': 1, 'search_default_my': 1}</field>
|
||||
<field name="search_view_id" ref="view_email_template_account_search"/>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
<menuitem name="Configuration" id="menu_email_template_configuration" parent="menu_email_template" />
|
||||
<menuitem name="Configuration" id="menu_email_template_configuration" parent="menu_email_template" />
|
||||
|
||||
<menuitem name="All Accounts" id="menu_email_template_account_all" parent="menu_email_template_configuration" action="action_email_template_account_tree_all" groups="res_groups_email_template_manager" />
|
||||
<menuitem name="Email Accounts" id="menu_email_template_account_all" parent="menu_email_template_configuration" action="action_email_template_account_tree_all"/>
|
||||
|
||||
</data>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
|
||||
|
||||
Executable → Regular
Executable → Regular
+1
-3
@@ -41,9 +41,7 @@ class email_template_mailbox(osv.osv):
|
||||
return True
|
||||
|
||||
def send_this_mail(self, cr, uid, ids=None, context=None):
|
||||
if ids is None:
|
||||
ids = []
|
||||
for id in ids:
|
||||
for id in (ids or []):
|
||||
try:
|
||||
account_obj = self.pool.get('email_template.account')
|
||||
values = self.read(cr, uid, id, [], context)
|
||||
|
||||
Executable → Regular
+77
-77
@@ -1,81 +1,81 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<!-- Email Template-->
|
||||
<record model="ir.ui.view" id="email_template_mailbox_form">
|
||||
<field name="name">email_template.mailbox.form</field>
|
||||
<field name="model">email_template.mailbox</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Outbox">
|
||||
<group col="4" colspan="2">
|
||||
<field name="email_from" colspan="4" select="1"/>
|
||||
<field name="email_cc" colspan="4" select="1"/>
|
||||
<field name="date_mail" colspan="4" select="2"/>
|
||||
</group>
|
||||
<group col="4" colspan="2">
|
||||
<field name="email_to" colspan="4" required="1" select="1" />
|
||||
<field name="email_bcc" colspan="4" select="2"/>
|
||||
<field name="subject" colspan="4" select="1"/>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Standard Body">
|
||||
<separator colspan="4" string="Standard Body" />
|
||||
<notebook colspan="4">
|
||||
<page string="Standard Body (Text)">
|
||||
<field name="body_text" nolabel="1" colspan="4" select="1"/>
|
||||
</page>
|
||||
<page string="Body (HTML-Web Client Only)">
|
||||
<field name="body_html" nolabel="1" colspan="4" />
|
||||
<!--<label string="Note: HTML body can't be edited with GTK desktop client." colspan="4"/>
|
||||
--></page>
|
||||
<data>
|
||||
<!-- Email Template-->
|
||||
<record model="ir.ui.view" id="email_template_mailbox_form">
|
||||
<field name="name">email_template.mailbox.form</field>
|
||||
<field name="model">email_template.mailbox</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Outbox">
|
||||
<group col="4" colspan="2">
|
||||
<field name="email_from" colspan="4" select="1"/>
|
||||
<field name="email_cc" colspan="4" select="1"/>
|
||||
<field name="date_mail" colspan="4" select="2"/>
|
||||
</group>
|
||||
<group col="4" colspan="2">
|
||||
<field name="email_to" colspan="4" required="1" select="1" />
|
||||
<field name="email_bcc" colspan="4" select="2"/>
|
||||
<field name="subject" colspan="4" select="1"/>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Standard Body">
|
||||
<separator colspan="4" string="Standard Body" />
|
||||
<notebook colspan="4">
|
||||
<page string="Standard Body (Text)">
|
||||
<field name="body_text" nolabel="1" colspan="4" select="1"/>
|
||||
</page>
|
||||
<page string="Body (HTML-Web Client Only)">
|
||||
<field name="body_html" nolabel="1" colspan="4" />
|
||||
<!--<label string="Note: HTML body can't be edited with GTK desktop client." colspan="4"/>
|
||||
--></page>
|
||||
|
||||
</notebook>
|
||||
</page>
|
||||
</notebook>
|
||||
</page>
|
||||
|
||||
|
||||
<page string="Attachments">
|
||||
<group col="4">
|
||||
<separator colspan="4" string="Attachments" />
|
||||
<field name="attachments_ids" colspan="4" nolabel="1" />
|
||||
</group>
|
||||
</page>
|
||||
<page string="Advanced">
|
||||
<group col="4">
|
||||
<field name="account_id" colspan="2" />
|
||||
<field name="server_ref" colspan="2" />
|
||||
<field name="mail_type" colspan="2" />
|
||||
<field name="folder" colspan="2" select="2"/>
|
||||
<separator string="History" colspan="4" />
|
||||
<field name="history" nolabel="1" colspan="4"/>
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
<separator colspan="4" string="" />
|
||||
<group col="4" colspan="4">
|
||||
<field name="state" readonly="1" />
|
||||
<button name="complete_mail" type="object" string="Download Full Mail" states="read,unread" />
|
||||
<button name="send_this_mail" type="object" string="Send Mail" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<page string="Attachments">
|
||||
<group col="4">
|
||||
<separator colspan="4" string="Attachments" />
|
||||
<field name="attachments_ids" colspan="4" nolabel="1" />
|
||||
</group>
|
||||
</page>
|
||||
<page string="Advanced">
|
||||
<group col="4">
|
||||
<field name="account_id" colspan="2" />
|
||||
<field name="server_ref" colspan="2" />
|
||||
<field name="mail_type" colspan="2" />
|
||||
<field name="folder" colspan="2" select="2"/>
|
||||
<separator string="History" colspan="4" />
|
||||
<field name="history" nolabel="1" colspan="4"/>
|
||||
</group>
|
||||
</page>
|
||||
</notebook>
|
||||
<separator colspan="4" string="" />
|
||||
<group col="4" colspan="4">
|
||||
<field name="state" readonly="1" />
|
||||
<button name="complete_mail" type="object" string="Download Full Mail" states="read,unread" />
|
||||
<button name="send_this_mail" type="object" string="Send Mail" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!--============================================= TREE VIEWS =============================================-->
|
||||
<record id="view_email_template_mailbox_tree" model="ir.ui.view">
|
||||
<field name="name">email_template.mailbox.tree</field>
|
||||
<field name="model">email_template.mailbox</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Drafts">
|
||||
<field name="user" />
|
||||
<field name="email_from" select="1" />
|
||||
<field name="subject" select="1" />
|
||||
<field name="attachments_ids" select="2" />
|
||||
<field name="date_mail" select="2" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<!--============================================= TREE VIEWS =============================================-->
|
||||
<record id="view_email_template_mailbox_tree" model="ir.ui.view">
|
||||
<field name="name">email_template.mailbox.tree</field>
|
||||
<field name="model">email_template.mailbox</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Drafts">
|
||||
<field name="user" />
|
||||
<field name="email_from" select="1" />
|
||||
<field name="subject" select="1" />
|
||||
<field name="attachments_ids" select="2" />
|
||||
<field name="date_mail" select="2" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_email_template_mailbox_search" model="ir.ui.view">
|
||||
<field name="name">email_template.mailbox.search</field>
|
||||
@@ -109,14 +109,14 @@
|
||||
<field name="search_view_id" ref="view_email_template_mailbox_search"/>
|
||||
</record>
|
||||
|
||||
<!--======================================== MENUS ========================================-->
|
||||
<menuitem name="MailBox" id="menu_email_template_mailbox_all_main2" parent="menu_email_template" />
|
||||
<menuitem name="Personal" id="menu_email_template_personal" parent="menu_email_template_mailbox_all_main2" />
|
||||
<!--======================================== MENUS ========================================-->
|
||||
<menuitem name="MailBox" id="menu_email_template_mailbox_all_main2" parent="menu_email_template" />
|
||||
<menuitem name="Personal" id="menu_email_template_personal" parent="menu_email_template_mailbox_all_main2" />
|
||||
<menuitem name="Mails" id="menu_email_template_personal_mails" parent="menu_email_template_personal" action="action_email_template_mailbox"/>
|
||||
<menuitem name="Company" id="menu_email_template_company" parent="menu_email_template_mailbox_all_main2" />
|
||||
<menuitem name="Company" id="menu_email_template_company" parent="menu_email_template_mailbox_all_main2" />
|
||||
<menuitem name="Mails" id="menu_email_template_company_mails" parent="menu_email_template_company" action="action_email_template_mailbox"/>
|
||||
|
||||
</data>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
|
||||
|
||||
Executable → Regular
Executable → Regular
+147
-147
@@ -1,147 +1,147 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<!-- Email Template PReview -->
|
||||
<record model="ir.ui.view" id="email_template_preview_form">
|
||||
<field name="name">email_template.preview.form</field>
|
||||
<field name="model">email_template.preview</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Email Preview">
|
||||
<field name="rel_model" />
|
||||
<newline />
|
||||
<field name="rel_model_ref" on_change="on_change_ref(rel_model_ref, context)" />
|
||||
<newline />
|
||||
<field name="to" />
|
||||
<newline />
|
||||
<field name="cc" />
|
||||
<newline />
|
||||
<field name="bcc" />
|
||||
<newline />
|
||||
<field name="subject" />
|
||||
<newline />
|
||||
<field name="body_text" />
|
||||
<newline />
|
||||
<!-- <field name="body_html" widget="text_html" />-->
|
||||
<!--
|
||||
Removed text_html because it doesnt work in GTK
|
||||
And TinyMCE messes up the HTML in Web Client
|
||||
-->
|
||||
<field name="body_html"/>
|
||||
<newline />
|
||||
<field name="report" />
|
||||
<group>
|
||||
<button icon="gtk-ok" special="cancel" string="OK" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<data>
|
||||
<!-- Email Template PReview -->
|
||||
<record model="ir.ui.view" id="email_template_preview_form">
|
||||
<field name="name">email_template.preview.form</field>
|
||||
<field name="model">email_template.preview</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Email Preview">
|
||||
<field name="rel_model" />
|
||||
<newline />
|
||||
<field name="rel_model_ref" on_change="on_change_ref(rel_model_ref, context)" />
|
||||
<newline />
|
||||
<field name="to" />
|
||||
<newline />
|
||||
<field name="cc" />
|
||||
<newline />
|
||||
<field name="bcc" />
|
||||
<newline />
|
||||
<field name="subject" />
|
||||
<newline />
|
||||
<field name="body_text" />
|
||||
<newline />
|
||||
<!-- <field name="body_html" widget="text_html" />-->
|
||||
<!--
|
||||
Removed text_html because it doesnt work in GTK
|
||||
And TinyMCE messes up the HTML in Web Client
|
||||
-->
|
||||
<field name="body_html"/>
|
||||
<newline />
|
||||
<field name="report" />
|
||||
<group>
|
||||
<button icon="gtk-ok" special="cancel" string="OK" />
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="wizard_email_template_preview" model="ir.actions.act_window">
|
||||
<field name="name">Template Preview</field>
|
||||
<field name="res_model">email_template.preview</field>
|
||||
<field name="src_model">email_template.preview</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="auto_refresh" eval="1" />
|
||||
<field name="target">new</field>
|
||||
<field name="context">{'ids':active_id}</field>
|
||||
</record>
|
||||
<!--EMail client Form view -->
|
||||
<record id="wizard_email_template_preview" model="ir.actions.act_window">
|
||||
<field name="name">Template Preview</field>
|
||||
<field name="res_model">email_template.preview</field>
|
||||
<field name="src_model">email_template.preview</field>
|
||||
<field name="type">ir.actions.act_window</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form</field>
|
||||
<field name="auto_refresh" eval="1" />
|
||||
<field name="target">new</field>
|
||||
<field name="context">{'ids':active_id}</field>
|
||||
</record>
|
||||
<!--EMail client Form view -->
|
||||
|
||||
<record model="ir.ui.view" id="email_template_form">
|
||||
<field name="name">email.template.form</field>
|
||||
<field name="model">email.template</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Email Templates">
|
||||
<field name="name" />
|
||||
<field name="object_name" required="1"
|
||||
on_change="change_model(object_name)" />
|
||||
<field name="model_int_name" invisible="1" />
|
||||
<notebook colspan="4">
|
||||
<page string="Mail Details">
|
||||
<field name="enforce_from_account" required= "1"/>
|
||||
<group col="4" colspan="2">
|
||||
<field name="from_email"/>
|
||||
<field name="def_to" colspan="4" required="1" />
|
||||
<field name="def_cc" colspan="4" />
|
||||
<field name="def_bcc" colspan="4" />
|
||||
</group>
|
||||
<group col="2" colspan="2">
|
||||
<field name="def_subject" colspan="4" required="1" />
|
||||
<field name="use_sign" colspan="4" />
|
||||
<field name="lang" colspan="4" />
|
||||
</group>
|
||||
<separator colspan="3" string="Standard Body" />
|
||||
<separator colspan="1" string="Expression Builder" />
|
||||
<record model="ir.ui.view" id="email_template_form">
|
||||
<field name="name">email.template.form</field>
|
||||
<field name="model">email.template</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Email Templates">
|
||||
<field name="name" />
|
||||
<field name="object_name" required="1"
|
||||
on_change="change_model(object_name)" />
|
||||
<field name="model_int_name" invisible="1" />
|
||||
<notebook colspan="4">
|
||||
<page string="Mail Details">
|
||||
<field name="enforce_from_account" required= "1"/>
|
||||
<group col="4" colspan="2">
|
||||
<field name="from_email"/>
|
||||
<field name="def_to" colspan="4" required="1" />
|
||||
<field name="def_cc" colspan="4" />
|
||||
<field name="def_bcc" colspan="4" />
|
||||
</group>
|
||||
<group col="2" colspan="2">
|
||||
<field name="def_subject" colspan="4" required="1" />
|
||||
<field name="use_sign" colspan="4" />
|
||||
<field name="lang" colspan="4" />
|
||||
</group>
|
||||
<separator colspan="3" string="Standard Body" />
|
||||
<separator colspan="1" string="Expression Builder" />
|
||||
|
||||
<notebook>
|
||||
<page string="Body (Text)">
|
||||
<field name="def_body_text" colspan="4" nolabel="1" />
|
||||
</page>
|
||||
<page string="Body (Raw HTML)">
|
||||
<field name="def_body_html" colspan="4" nolabel="1" />
|
||||
<label string="Note: This is Raw HTML." colspan="4" />
|
||||
</page>
|
||||
</notebook>
|
||||
<group col="4">
|
||||
<field name="template_language"
|
||||
on_change="onchange_null_value(model_object_field,sub_model_object_field,null_value,template_language,context)" />
|
||||
<notebook>
|
||||
<page string="Insert Simple Field">
|
||||
<notebook>
|
||||
<page string="Body (Text)">
|
||||
<field name="def_body_text" colspan="4" nolabel="1" />
|
||||
</page>
|
||||
<page string="Body (Raw HTML)">
|
||||
<field name="def_body_html" colspan="4" nolabel="1" />
|
||||
<label string="Note: This is Raw HTML." colspan="4" />
|
||||
</page>
|
||||
</notebook>
|
||||
<group col="4">
|
||||
<field name="template_language"
|
||||
on_change="onchange_null_value(model_object_field,sub_model_object_field,null_value,template_language,context)" />
|
||||
<notebook>
|
||||
<page string="Insert Simple Field">
|
||||
|
||||
<field name="model_object_field"
|
||||
domain="[('model_id','=',object_name),('ttype','!=','one2many'),('ttype','!=','many2many')]"
|
||||
on_change="onchange_model_object_field(model_object_field, template_language,context)"
|
||||
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_field(model_object_field,sub_model_object_field,template_language,context)" />
|
||||
<field name="null_value" colspan="4"
|
||||
on_change="onchange_null_value(model_object_field,sub_model_object_field,null_value,template_language,context)" />
|
||||
<field name="copyvalue" colspan="4" />
|
||||
</page>
|
||||
</notebook>
|
||||
<button name="%(wizard_email_template_preview)d" string="Preview Template"
|
||||
type="action" colspan="4" target="new" />
|
||||
</group>
|
||||
</page>
|
||||
<page string="Advanced">
|
||||
<field name="ref_ir_act_window" />
|
||||
<field name="ref_ir_value" />
|
||||
<separator string="Attachments (Report to attach)" colspan="4"/>
|
||||
<field name="file_name" colspan="2" />
|
||||
<field name="report_template" colspan="2"
|
||||
domain="[('model','=',model_int_name)]" />
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<field name="model_object_field"
|
||||
domain="[('model_id','=',object_name),('ttype','!=','one2many'),('ttype','!=','many2many')]"
|
||||
on_change="onchange_model_object_field(model_object_field, template_language,context)"
|
||||
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_field(model_object_field,sub_model_object_field,template_language,context)" />
|
||||
<field name="null_value" colspan="4"
|
||||
on_change="onchange_null_value(model_object_field,sub_model_object_field,null_value,template_language,context)" />
|
||||
<field name="copyvalue" colspan="4" />
|
||||
</page>
|
||||
</notebook>
|
||||
<button name="%(wizard_email_template_preview)d" string="Preview Template"
|
||||
type="action" colspan="4" target="new" />
|
||||
</group>
|
||||
</page>
|
||||
<page string="Advanced">
|
||||
<field name="ref_ir_act_window" />
|
||||
<field name="ref_ir_value" />
|
||||
<separator string="Attachments (Report to attach)" colspan="4"/>
|
||||
<field name="file_name" colspan="2" />
|
||||
<field name="report_template" colspan="2"
|
||||
domain="[('model','=',model_int_name)]" />
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="email_template_tree">
|
||||
<field name="name">email.template.tree</field>
|
||||
<field name="model">email.template</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Email Templates">
|
||||
<field name="name" select="1" />
|
||||
<field name="object_name" required="1" select="1" />
|
||||
<field name="def_to" colspan="4" select="2" />
|
||||
<field name="def_cc" colspan="4" select="2" />
|
||||
<field name="def_bcc" colspan="4" select="2" />
|
||||
<field name="def_subject" colspan="4" select="2" />
|
||||
<field name="use_sign" colspan="4" select="2" />
|
||||
<field name="file_name" colspan="4" />
|
||||
<field name="enforce_from_account" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="email_template_tree">
|
||||
<field name="name">email.template.tree</field>
|
||||
<field name="model">email.template</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Email Templates">
|
||||
<field name="name" select="1" />
|
||||
<field name="object_name" required="1" select="1" />
|
||||
<field name="def_to" colspan="4" select="2" />
|
||||
<field name="def_cc" colspan="4" select="2" />
|
||||
<field name="def_bcc" colspan="4" select="2" />
|
||||
<field name="def_subject" colspan="4" select="2" />
|
||||
<field name="use_sign" colspan="4" select="2" />
|
||||
<field name="file_name" colspan="4" />
|
||||
<field name="enforce_from_account" />
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_email_template_search" model="ir.ui.view">
|
||||
<field name="name">email.template.search</field>
|
||||
@@ -161,19 +161,19 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window" id="action_email_template_tree_all">
|
||||
<field name="name">Email Templates</field>
|
||||
<field name="res_model">email.template</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form,tree</field>
|
||||
<field name="view_id" ref="email_template_tree" />
|
||||
<record model="ir.actions.act_window" id="action_email_template_tree_all">
|
||||
<field name="name">Email Templates</field>
|
||||
<field name="res_model">email.template</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">form,tree</field>
|
||||
<field name="view_id" ref="email_template_tree" />
|
||||
<field name="search_view_id" ref="view_email_template_search"/>
|
||||
</record>
|
||||
</record>
|
||||
|
||||
<menuitem name="E-MAIL Templates" id="menu_email_template_all"
|
||||
parent="menu_email_template_configuration" action="action_email_template_tree_all" />
|
||||
<menuitem name="E-MAIL Templates" id="menu_email_template_all"
|
||||
parent="menu_email_template_configuration" action="action_email_template_tree_all" />
|
||||
|
||||
</data>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
|
||||
|
||||
Executable → Regular
+9
-9
@@ -11,24 +11,24 @@
|
||||
<field name="osv">email_template.account</field>
|
||||
<field name="on_create">True</field>
|
||||
</record>
|
||||
|
||||
|
||||
<!--Activity -->
|
||||
|
||||
|
||||
<record id="act_draft" model="workflow.activity">
|
||||
<field name="wkf_id" ref="wkf_email_template_setting"/>
|
||||
<field name="flow_start">True</field>
|
||||
<field name="name">draft</field>
|
||||
<field name="kind">function</field>
|
||||
<field name="kind">function</field>
|
||||
<field name="action">write({'state':'draft'})</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="act_approved" model="workflow.activity">
|
||||
<field name="name">approval</field>
|
||||
<field name="wkf_id" ref="wkf_email_template_setting"/>
|
||||
<field name="kind">function</field>
|
||||
<field name="action">do_approval()</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="act_suspended" model="workflow.activity">
|
||||
<field name="name">suspended</field>
|
||||
<field name="wkf_id" ref="wkf_email_template_setting"/>
|
||||
@@ -40,16 +40,16 @@
|
||||
<field name="wkf_id" ref="wkf_email_template_setting"/>
|
||||
<field name="flow_stop">True</field>
|
||||
</record>
|
||||
|
||||
|
||||
<!-- Transition -->
|
||||
|
||||
|
||||
<record id="trans_awaiting_approved" model="workflow.transition">
|
||||
<field name="act_from" ref="act_draft"/>
|
||||
<field name="act_to" ref="act_approved"/>
|
||||
<field name="signal">button_approval</field>
|
||||
<field name="role_id" ref="PE_ADMIN"/>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="trans_approved_suspended" model="workflow.transition">
|
||||
<field name="act_from" ref="act_approved"/>
|
||||
<field name="act_to" ref="act_suspended"/>
|
||||
@@ -67,6 +67,6 @@
|
||||
<field name="act_to" ref="act_dummy"/>
|
||||
<field name="signal">get_never</field>
|
||||
<field name="role_id" ref="PE_ADMIN"/>
|
||||
</record>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
Executable → Regular
@@ -1,19 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data noupdate="0">
|
||||
<data noupdate="0">
|
||||
|
||||
<record id="res_groups_email_template_manager" model="res.groups">
|
||||
<field name="name">Email Template / Settings_Manager</field>
|
||||
</record>
|
||||
<record id="res_groups_email_template_admin" model="res.groups">
|
||||
<field name="name">Marketing / Email Template</field>
|
||||
</record>
|
||||
|
||||
<record id="res_groups_email_template_userse" model="res.groups">
|
||||
<field name="name">Email Template / External_users</field>
|
||||
</record>
|
||||
|
||||
<record id="res_groups_email_template_usersi" model="res.groups">
|
||||
<field name="name">Email Template / Internal_users</field>
|
||||
</record>
|
||||
|
||||
|
||||
</data>
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_email_template_engines","email_template.engines","model_email_template_engines","email_template.res_groups_email_template_admin",1,1,1,1
|
||||
"access_email_template_account","email_template.account","model_email_template_account","email_template.res_groups_email_template_admin",1,1,1,1
|
||||
"access_email_template","email.template","model_email_template","email_template.res_groups_email_template_admin",1,1,1,1
|
||||
"access_email_template_preview","email_template.preview","model_email_template_preview","email_template.res_groups_email_template_admin",1,1,1,1
|
||||
"access_email_template_mailbox","email_template.mailbox","model_email_template_mailbox","email_template.res_groups_email_template_admin",1,1,1,1
|
||||
"access_email_template_send_wizard","email_template.send.wizard","model_email_template_send_wizard","email_template.res_groups_email_template_admin",1,1,1,1
|
||||
|
@@ -7,19 +7,19 @@ 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-10-09 07:48+0000\n"
|
||||
"Last-Translator: Sardorbek Pulatov (pROCKrammer) <prockrammer@ya.ru>\n"
|
||||
"PO-Revision-Date: 2010-06-13 13:02+0000\n"
|
||||
"Last-Translator: Alex L. <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-04-17 03:55+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-14 03:42+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: google_map
|
||||
#: model:ir.actions.wizard,name:google_map.wizard_google_map
|
||||
msgid "Launch Google Map"
|
||||
msgstr ""
|
||||
msgstr "Запустить Google Map"
|
||||
|
||||
#. module: google_map
|
||||
#: constraint:ir.ui.view:0
|
||||
@@ -39,6 +39,9 @@ msgid ""
|
||||
"so that we can directly open google map from the\n"
|
||||
"url widget."
|
||||
msgstr ""
|
||||
"Модуль добавляет поле с Google картой в адрес партнера\n"
|
||||
"поэтому мы можем открыть карту Google непосредственно из\n"
|
||||
"адреса виджета."
|
||||
|
||||
#. module: google_map
|
||||
#: view:res.partner:0
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
<search string="Departments">
|
||||
<group col='4' colspan='2'>
|
||||
<field name="name" />
|
||||
<field name="manager_id" widget="selection"/>
|
||||
<field name="manager_id"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
@@ -73,7 +73,7 @@
|
||||
</record>
|
||||
|
||||
<menuitem action="open_module_tree_department" id="menu_department_def" parent="hr.menu_department_tree"/>
|
||||
<menuitem action="open_module_tree_department" id="menu_hr_department_tree" parent="menu_hr_root" sequence="5"/>
|
||||
<menuitem action="open_module_tree_department" id="menu_hr_department_tree" parent="menu_hr_main" sequence="5"/>
|
||||
|
||||
<record model="ir.ui.view" id="view_users_form_inherit">
|
||||
<field name="name">res.users.form</field>
|
||||
|
||||
+18
-12
@@ -6,10 +6,16 @@
|
||||
icon="terp-hr"
|
||||
name="Human Resources"
|
||||
sequence="6"/>
|
||||
<menuitem
|
||||
id="menu_hr_main"
|
||||
parent="menu_hr_root"
|
||||
name="Human Resources"
|
||||
sequence="0"/>
|
||||
<menuitem
|
||||
id="menu_hr_configuration"
|
||||
name="Configuration"
|
||||
parent="hr.menu_hr_root"
|
||||
groups="group_hr_manager"
|
||||
sequence="50" />
|
||||
<menuitem
|
||||
id="menu_view_employee_category_configuration_form"
|
||||
@@ -29,18 +35,18 @@
|
||||
<field name="arch" type="xml">
|
||||
<form string="Employee">
|
||||
<group colspan="4" col="8">
|
||||
<group colspan="6" col="6">
|
||||
<field colspan="6" name="name" select="1"/>
|
||||
<field name="user_id"/>
|
||||
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
|
||||
<field name="active" groups="base.group_extended"/>
|
||||
<newline/>
|
||||
<group colspan="6" col="6">
|
||||
<field colspan="6" name="name" select="1"/>
|
||||
<field name="user_id"/>
|
||||
<field name="company_id" widget="selection" groups="base.group_multi_company"/>
|
||||
<field name="active" groups="base.group_extended"/>
|
||||
<newline/>
|
||||
<field name="parent_id" />
|
||||
<field name="coach_id" />
|
||||
</group>
|
||||
<group colspan="2" col="1">
|
||||
<field name="photo" widget='image' nolabel="1"/>
|
||||
</group>
|
||||
</group>
|
||||
<group colspan="2" col="1">
|
||||
<field name="photo" widget='image' nolabel="1"/>
|
||||
</group>
|
||||
</group>
|
||||
<notebook colspan="6">
|
||||
<page string="Personal Information">
|
||||
@@ -112,7 +118,7 @@
|
||||
<field name="name"/>
|
||||
<field name="department_id" widget="selection"/>
|
||||
<field name="job_id" widget="selection"/>
|
||||
<field name="parent_id" widget="selection" />
|
||||
<field name="parent_id"/>
|
||||
<newline />
|
||||
<group expand="0" string="Group By...">
|
||||
<filter string="Manager" icon="terp-personal" domain="[]" context="{'group_by':'parent_id'}"/>
|
||||
@@ -155,7 +161,7 @@
|
||||
action="open_view_employee_list_my"
|
||||
id="menu_open_view_employee_list_my"
|
||||
sequence="3"
|
||||
parent="menu_hr_root"/>
|
||||
parent="menu_hr_main"/>
|
||||
|
||||
|
||||
<!--
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_employee_category","hr.employee.category","model_hr_employee_category","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_employee","hr.employee","model_hr_employee","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_employee_resource","resource.resource","resource.model_resource_resource","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_department","hr.department","model_hr_department","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_employee_category_manager","hr.employee.category.manager","model_hr_employee_category","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_department_manager","hr.department.manager","model_hr_department","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_employee_marital_status","hr.employee.marital.status","model_hr_employee_marital_status","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_job","hr.job","model_hr_job","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_installer","hr.installer","model_hr_installer","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_installer","hr.installer","model_hr_installer","base.group_system",1,1,1,1
|
||||
|
||||
|
@@ -39,14 +39,10 @@ def hour2str(h):
|
||||
|
||||
class report_custom(report_rml):
|
||||
def create_xml(self, cr, uid, ids, datas, context):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
|
||||
month = DateTime.DateTime(datas['form']['year'], datas['form']['month'], 1)
|
||||
|
||||
user_xml = ['<month>%s</month>' % month2name[month.month], '<year>%s</year>' % month.year]
|
||||
|
||||
for employee_id in ids:
|
||||
emp = service.execute(cr.dbname, uid, 'hr.employee', 'read', [employee_id])[0]
|
||||
emp = self.pool.get('hr.employee').read(cr, uid, 'read', [employee_id], ['name'])[0]
|
||||
stop, days_xml = False, []
|
||||
user_repr = '''
|
||||
<user>
|
||||
|
||||
@@ -32,81 +32,80 @@ one_week = DateTime.RelativeDateTime(days=7)
|
||||
num2day = ['Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday', 'Sunday']
|
||||
|
||||
def to_hour(h):
|
||||
return int(h), int(round((h - int(h)) * 60, 0))
|
||||
return int(h), int(round((h - int(h)) * 60, 0))
|
||||
|
||||
class report_custom(report_rml):
|
||||
def create_xml(self, cr, uid, ids, datas, context):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
def create_xml(self, cr, uid, ids, datas, context):
|
||||
|
||||
start_date = DateTime.strptime(datas['form']['init_date'], '%Y-%m-%d')
|
||||
end_date = DateTime.strptime(datas['form']['end_date'], '%Y-%m-%d')
|
||||
first_monday = start_date - DateTime.RelativeDateTime(days=start_date.day_of_week)
|
||||
last_monday = end_date + DateTime.RelativeDateTime(days=7 - end_date.day_of_week)
|
||||
start_date = DateTime.strptime(datas['form']['init_date'], '%Y-%m-%d')
|
||||
end_date = DateTime.strptime(datas['form']['end_date'], '%Y-%m-%d')
|
||||
first_monday = start_date - DateTime.RelativeDateTime(days=start_date.day_of_week)
|
||||
last_monday = end_date + DateTime.RelativeDateTime(days=7 - end_date.day_of_week)
|
||||
|
||||
if last_monday < first_monday:
|
||||
first_monday, last_monday = last_monday, first_monday
|
||||
if last_monday < first_monday:
|
||||
first_monday, last_monday = last_monday, first_monday
|
||||
|
||||
user_xml = []
|
||||
user_xml = []
|
||||
|
||||
for employee_id in ids:
|
||||
emp = service.execute(cr.dbname, uid, 'hr.employee', 'read', [employee_id], ['id', 'name'])[0]
|
||||
monday, n_monday = first_monday, first_monday + one_week
|
||||
stop, week_xml = False, []
|
||||
user_repr = '''
|
||||
<user>
|
||||
<name>%s</name>
|
||||
%%s
|
||||
</user>
|
||||
''' % toxml(emp['name'])
|
||||
while monday != last_monday:
|
||||
#### Work hour calculation
|
||||
sql = '''
|
||||
select action, att.name
|
||||
from hr_employee as emp inner join hr_attendance as att
|
||||
on emp.id = att.employee_id
|
||||
where att.name between %s and %s and emp.id = %s
|
||||
order by att.name
|
||||
'''
|
||||
for idx in range(7):
|
||||
cr.execute(sql, (monday.strftime('%Y-%m-%d %H:%M:%S'), (monday + DateTime.RelativeDateTime(days=idx+1)).strftime('%Y-%m-%d %H:%M:%S'), employee_id))
|
||||
attendances = cr.dictfetchall()
|
||||
week_wh = {}
|
||||
# Fake sign ins/outs at week ends, to take attendances across week ends into account
|
||||
# XXX this is wrong for the first sign-in ever and the last sign out to this date
|
||||
if attendances and attendances[0]['action'] == 'sign_out':
|
||||
attendances.insert(0, {'name': monday.strftime('%Y-%m-%d %H:%M:%S'), 'action':'sign_in'})
|
||||
if attendances and attendances[-1]['action'] == 'sign_in':
|
||||
attendances.append({'name' : n_monday.strftime('%Y-%m-%d %H:%M:%S'), 'action':'sign_out'})
|
||||
# sum up the attendances' durations
|
||||
for att in attendances:
|
||||
dt = DateTime.strptime(att['name'], '%Y-%m-%d %H:%M:%S')
|
||||
if att['action'] == 'sign_out':
|
||||
week_wh[ldt.day_of_week] = week_wh.get(ldt.day_of_week, 0) + (dt - ldt).hours
|
||||
ldt = dt
|
||||
for employee_id in ids:
|
||||
emp = self.pool.get('hr.employee').read(cr, uid, [employee_id], ['id', 'name'])[0]
|
||||
monday, n_monday = first_monday, first_monday + one_week
|
||||
stop, week_xml = False, []
|
||||
user_repr = '''
|
||||
<user>
|
||||
<name>%s</name>
|
||||
%%s
|
||||
</user>
|
||||
''' % toxml(emp['name'])
|
||||
while monday != last_monday:
|
||||
#### Work hour calculation
|
||||
sql = '''
|
||||
select action, att.name
|
||||
from hr_employee as emp inner join hr_attendance as att
|
||||
on emp.id = att.employee_id
|
||||
where att.name between %s and %s and emp.id = %s
|
||||
order by att.name
|
||||
'''
|
||||
for idx in range(7):
|
||||
cr.execute(sql, (monday.strftime('%Y-%m-%d %H:%M:%S'), (monday + DateTime.RelativeDateTime(days=idx+1)).strftime('%Y-%m-%d %H:%M:%S'), employee_id))
|
||||
attendances = cr.dictfetchall()
|
||||
week_wh = {}
|
||||
# Fake sign ins/outs at week ends, to take attendances across week ends into account
|
||||
# XXX this is wrong for the first sign-in ever and the last sign out to this date
|
||||
if attendances and attendances[0]['action'] == 'sign_out':
|
||||
attendances.insert(0, {'name': monday.strftime('%Y-%m-%d %H:%M:%S'), 'action':'sign_in'})
|
||||
if attendances and attendances[-1]['action'] == 'sign_in':
|
||||
attendances.append({'name' : n_monday.strftime('%Y-%m-%d %H:%M:%S'), 'action':'sign_out'})
|
||||
# sum up the attendances' durations
|
||||
for att in attendances:
|
||||
dt = DateTime.strptime(att['name'], '%Y-%m-%d %H:%M:%S')
|
||||
if att['action'] == 'sign_out':
|
||||
week_wh[ldt.day_of_week] = week_wh.get(ldt.day_of_week, 0) + (dt - ldt).hours
|
||||
ldt = dt
|
||||
|
||||
# Week xml representation
|
||||
week_repr = ['<week>', '<weekstart>%s</weekstart>' % monday.strftime('%Y-%m-%d'), '<weekend>%s</weekend>' % n_monday.strftime('%Y-%m-%d')]
|
||||
for idx in range(7):
|
||||
week_repr.append('<%s>' % num2day[idx])
|
||||
if idx in week_wh:
|
||||
week_repr.append('<workhours>%sh%02d</workhours>' % to_hour(week_wh[idx]))
|
||||
week_repr.append('</%s>' % num2day[idx])
|
||||
week_repr.append('<total>')
|
||||
week_repr.append('<worked>%sh%02d</worked>' % to_hour(reduce(lambda x,y:x+y, week_wh.values(), 0)))
|
||||
week_repr.append('</total>')
|
||||
week_repr.append('</week>')
|
||||
if len(week_repr) > 21: # 21 = minimal length of week_repr
|
||||
week_xml.append('\n'.join(week_repr))
|
||||
|
||||
monday, n_monday = n_monday, n_monday + one_week
|
||||
user_xml.append(user_repr % '\n'.join(week_xml))
|
||||
|
||||
xml = '''<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<report>
|
||||
%s
|
||||
</report>
|
||||
''' % '\n'.join(user_xml)
|
||||
return self.post_process_xml_data(cr, uid, xml, context)
|
||||
# Week xml representation
|
||||
week_repr = ['<week>', '<weekstart>%s</weekstart>' % monday.strftime('%Y-%m-%d'), '<weekend>%s</weekend>' % n_monday.strftime('%Y-%m-%d')]
|
||||
for idx in range(7):
|
||||
week_repr.append('<%s>' % num2day[idx])
|
||||
if idx in week_wh:
|
||||
week_repr.append('<workhours>%sh%02d</workhours>' % to_hour(week_wh[idx]))
|
||||
week_repr.append('</%s>' % num2day[idx])
|
||||
week_repr.append('<total>')
|
||||
week_repr.append('<worked>%sh%02d</worked>' % to_hour(reduce(lambda x,y:x+y, week_wh.values(), 0)))
|
||||
week_repr.append('</total>')
|
||||
week_repr.append('</week>')
|
||||
if len(week_repr) > 21: # 21 = minimal length of week_repr
|
||||
week_xml.append('\n'.join(week_repr))
|
||||
|
||||
monday, n_monday = n_monday, n_monday + one_week
|
||||
user_xml.append(user_repr % '\n'.join(week_xml))
|
||||
|
||||
xml = '''<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<report>
|
||||
%s
|
||||
</report>
|
||||
''' % '\n'.join(user_xml)
|
||||
return self.post_process_xml_data(cr, uid, xml, context)
|
||||
|
||||
report_custom('report.hr.attendance.allweeks', 'hr.employee', '', 'addons/hr_attendance/report/timesheet.xsl')
|
||||
# vim:noexpandtab:tw=0
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_action_reason_employee","hr action reason employee","model_hr_action_reason","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_attendance_employee","hr attendance employee","model_hr_attendance","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_action_reason_employee","hr action reason employee","model_hr_action_reason","hr_attendance.group_hr_attendance",1,0,0,0
|
||||
"access_hr_action_reason_employee","hr action reason employee","model_hr_action_reason","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_attendance_employee","hr attendance employee","model_hr_attendance","hr_attendance.group_hr_attendance",1,1,1,1
|
||||
"access_hr_sign_in_out","hr attendance sign in out","model_hr_sign_in_out","hr_attendance.group_hr_attendance",1,1,1,1
|
||||
"access_hr_attendance_employee","hr employee attendance sign in out","hr.model_hr_employee","hr_attendance.group_hr_attendance",1,0,0,0
|
||||
"access_hr_attendance_resource","hr resource attendance sign in out","resource.model_resource_resource","hr_attendance.group_hr_attendance",1,0,0,0
|
||||
|
||||
|
@@ -33,16 +33,14 @@ class hr_si_so_ask(osv.osv_memory):
|
||||
'emp_id': fields.char('Empoyee ID', size=32, required=True, readonly=True),
|
||||
}
|
||||
def _get_empname(self, cr, uid, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
emp_id = service.execute(cr.dbname, uid, 'hr.employee', 'search', [('user_id', '=', uid)])
|
||||
emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context)
|
||||
if emp_id:
|
||||
employee = service.execute(cr.dbname, uid, 'hr.employee', 'read', emp_id)[0]
|
||||
employee = self.pool.get('hr.employee').browse(cr, uid, emp_id, context=context)[0].name
|
||||
return employee['name']
|
||||
return ''
|
||||
|
||||
def _get_empid(self, cr, uid, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
emp_id = service.execute(cr.dbname, uid, 'hr.employee', 'search', [('user_id', '=', uid)])
|
||||
emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context)
|
||||
if emp_id:
|
||||
return emp_id[0]
|
||||
return False
|
||||
@@ -74,11 +72,10 @@ class hr_sign_in_out(osv.osv_memory):
|
||||
}
|
||||
|
||||
def _get_empid(self, cr, uid, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
emp_id = service.execute(cr.dbname, uid, 'hr.employee', 'search', [('user_id', '=', uid)])
|
||||
emp_id = self.pool.get('hr.employee').search(cr, uid, [('user_id', '=', uid)], context=context)
|
||||
if emp_id:
|
||||
employee = service.execute(cr.dbname, uid, 'hr.employee', 'read', emp_id)[0]
|
||||
return {'name': employee['name'], 'state': employee['state'], 'emp_id': emp_id[0]}
|
||||
employee = self.pool.get('hr.employee').browse(cr, uid, emp_id, context=context)[0]
|
||||
return {'name': employee.name, 'state': employee.state, 'emp_id': emp_id[0]}
|
||||
return {}
|
||||
|
||||
def default_get(self, cr, uid, fields_list, context=None):
|
||||
@@ -88,15 +85,15 @@ class hr_sign_in_out(osv.osv_memory):
|
||||
return res
|
||||
|
||||
def si_check(self, cr, uid, ids, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
obj_model = self.pool.get('ir.model.data')
|
||||
att_obj = self.pool.get('hr.attendance')
|
||||
data = self.read(cr, uid, ids, [])[0]
|
||||
emp_id = data['emp_id']
|
||||
att_id = service.execute(cr.dbname, uid, 'hr.attendance', 'search', [('employee_id', '=', emp_id)], limit=1, order='name desc')
|
||||
last_att = service.execute(cr.dbname, uid, 'hr.attendance', 'read', att_id)
|
||||
att_id = att_obj.search(cr, uid, [('employee_id', '=', emp_id)], limit=1, order='name desc')
|
||||
last_att = att_obj.browse(cr, uid, att_id)
|
||||
if last_att:
|
||||
last_att = last_att[0]
|
||||
cond = not last_att or last_att['action'] == 'sign_out'
|
||||
cond = not last_att or last_att.action == 'sign_out'
|
||||
if cond:
|
||||
return self.sign_in(cr, uid, data, context)
|
||||
else:
|
||||
@@ -113,12 +110,12 @@ class hr_sign_in_out(osv.osv_memory):
|
||||
}
|
||||
|
||||
def so_check(self, cr, uid, ids, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
obj_model = self.pool.get('ir.model.data')
|
||||
data = self.read(cr, uid, ids, [])[0]
|
||||
att_obj = self.pool.get('hr.attendance')
|
||||
emp_id = data['emp_id']
|
||||
att_id = service.execute(cr.dbname, uid, 'hr.attendance', 'search', [('employee_id', '=', emp_id),('action','!=','action')], limit=1, order='name desc')
|
||||
last_att = service.execute(cr.dbname, uid, 'hr.attendance', 'read', att_id)
|
||||
att_id = att_obj.search(cr, uid, [('employee_id', '=', emp_id),('action','!=','action')], limit=1, order='name desc')
|
||||
last_att = att_obj.browse(cr, uid, att_id, context=context)
|
||||
if last_att:
|
||||
last_att = last_att[0]
|
||||
if not att_id and not last_att:
|
||||
@@ -151,35 +148,33 @@ class hr_sign_in_out(osv.osv_memory):
|
||||
}
|
||||
|
||||
def sign_in(self, cr, uid, data, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
emp_id = data['emp_id']
|
||||
if 'last_time' in data:
|
||||
if data['last_time'] > time.strftime('%Y-%m-%d %H:%M:%S'):
|
||||
raise osv.except_osv(_('UserError'), _('The sign-out date must be in the past'))
|
||||
service.execute(cr.dbname, uid, 'hr.attendance', 'create', {
|
||||
self.pool.get('hr.attendance').create(cr, uid, {
|
||||
'name': data['last_time'],
|
||||
'action': 'sign_out',
|
||||
'employee_id': emp_id
|
||||
})
|
||||
try:
|
||||
success = service.execute(cr.dbname, uid, 'hr.employee', 'attendance_action_change', [emp_id], 'sign_in')
|
||||
success = self.pool.get('hr.employee').attendance_action_change(cr, uid, [emp_id], 'sign_in')
|
||||
except:
|
||||
raise osv.except_osv(_('UserError'), _('A sign-in must be right after a sign-out !'))
|
||||
return {} # To do: Return Success message
|
||||
|
||||
def sign_out(self, cr, uid, data, context=None):
|
||||
service = netsvc.LocalService('object_proxy')
|
||||
emp_id = data['emp_id']
|
||||
if 'last_time' in data:
|
||||
if data['last_time'] > time.strftime('%Y-%m-%d %H:%M:%S'):
|
||||
raise osv.except_osv(_('UserError'), _('The Sign-in date must be in the past'))
|
||||
service.execute(cr.dbname, uid, 'hr.attendance', 'create', {'name':data['last_time'], 'action':'sign_in', 'employee_id':emp_id})
|
||||
self.pool.get('hr.attendance').create(cr, uid, {'name':data['last_time'], 'action':'sign_in', 'employee_id':emp_id})
|
||||
try:
|
||||
success = service.execute(cr.dbname, uid, 'hr.employee', 'attendance_action_change', [emp_id], 'sign_out')
|
||||
success = self.pool.get('hr.employee').attendance_action_change(cr, uid, [emp_id], 'sign_out')
|
||||
except:
|
||||
raise osv.except_osv(_('UserError'), _('A sign-out must be right after a sign-in !'))
|
||||
return {} # To do: Return Success message
|
||||
|
||||
hr_sign_in_out()
|
||||
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
|
||||
|
||||
@@ -1,21 +1,21 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<openerp>
|
||||
<data>
|
||||
<record id="view_hr_attendance_sigh_in_out" model="ir.ui.view">
|
||||
<record id="view_hr_attendance_sigh_in_out" model="ir.ui.view">
|
||||
<field name="name">hr.sign.in.out.form</field>
|
||||
<field name="model">hr.sign.in.out</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Sign in / Sign out">
|
||||
<group colspan="4" >
|
||||
<separator string="You are now ready to sign in or out of the attendance follow up" colspan="4" />
|
||||
<field name="name" />
|
||||
<field name="state" />
|
||||
</group>
|
||||
<group colspan="4" >
|
||||
<separator string="You are now ready to sign in or out of the attendance follow up" colspan="4" />
|
||||
<field name="name" />
|
||||
<field name="state" />
|
||||
</group>
|
||||
<group colspan="4" col="6">
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button icon="gtk-go-back" string="Sign in" name="si_check" type="object"/>
|
||||
<button icon="gtk-go-forward" string="Sign out" name="so_check" type="object"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button icon="gtk-go-back" string="Sign in" name="si_check" type="object"/>
|
||||
<button icon="gtk-go-forward" string="Sign out" name="so_check" type="object"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
@@ -27,15 +27,15 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Sign in / Sign out">
|
||||
<label string="Sign-Out Entry must follow Sign-In." colspan="4" />
|
||||
<label string="Sign-Out Entry must follow Sign-In." colspan="4" />
|
||||
<group colspan="4" col="6">
|
||||
<button icon="gtk-cancel" special="cancel" string="Ok"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="Ok"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="action_hr_attendance_sigh_in_out" model="ir.actions.act_window">
|
||||
<record id="action_hr_attendance_sigh_in_out" model="ir.actions.act_window">
|
||||
<field name="name">Sign in / Sign out</field>
|
||||
<field name="res_model">hr.sign.in.out</field>
|
||||
<field name="view_type">form</field>
|
||||
@@ -45,8 +45,8 @@
|
||||
</record>
|
||||
|
||||
<menuitem action="action_hr_attendance_sigh_in_out"
|
||||
id="menu_hr_attendance_sigh_in_out"
|
||||
parent="menu_hr_time_tracking" groups="base.group_extended" />
|
||||
id="menu_hr_attendance_sigh_in_out"
|
||||
parent="menu_hr_time_tracking"/>
|
||||
|
||||
<record id="view_hr_attendance_so_ask" model="ir.ui.view">
|
||||
<field name="name">hr.sign.in.out.ask.form</field>
|
||||
@@ -54,14 +54,14 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="hr.sign.out.ask">
|
||||
<group colspan="4" >
|
||||
<separator string="You did not sign out the last time. Please enter the date and time you signed out." colspan="4" />
|
||||
<field name="name" />
|
||||
<field name="last_time" string="Your last sign out" />
|
||||
</group>
|
||||
<group colspan="4" >
|
||||
<separator string="You did not sign out the last time. Please enter the date and time you signed out." colspan="4" />
|
||||
<field name="name" />
|
||||
<field name="last_time" string="Your last sign out" />
|
||||
</group>
|
||||
<group colspan="4" col="6">
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button icon="gtk-go-back" string="Sign in" name="sign_in" type="object"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button icon="gtk-go-back" string="Sign in" name="sign_in" type="object"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
@@ -73,14 +73,14 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="hr.sign.in.out.ask">
|
||||
<group colspan="4" >
|
||||
<separator string="You did not sign in the last time. Please enter the date and time you signed in." colspan="4" />
|
||||
<field name="name" />
|
||||
<field name="last_time" string="Your last sign in" />
|
||||
</group>
|
||||
<group colspan="4" >
|
||||
<separator string="You did not sign in the last time. Please enter the date and time you signed in." colspan="4" />
|
||||
<field name="name" />
|
||||
<field name="last_time" string="Your last sign in" />
|
||||
</group>
|
||||
<group colspan="4" col="6">
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button icon="gtk-go-back" string="Sign out" name="sign_out" type="object"/>
|
||||
<button icon="gtk-cancel" special="cancel" string="Cancel"/>
|
||||
<button icon="gtk-go-back" string="Sign out" name="sign_out" type="object"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
@@ -27,11 +27,11 @@ class hr_employee(osv.osv):
|
||||
_description = "Employee"
|
||||
_inherit = "hr.employee"
|
||||
_columns = {
|
||||
'manager': fields.boolean('Manager'),
|
||||
'manager': fields.boolean('Is a Manager'),
|
||||
'medic_exam': fields.date('Medical Examination Date'),
|
||||
'place_of_birth': fields.char('Place of Birth', size=30),
|
||||
'children': fields.integer('Number of Children'),
|
||||
'vehicle': fields.integer('Company Vehicle'),
|
||||
'vehicle': fields.char('Company Vehicle', size=64),
|
||||
'vehicle_distance': fields.integer('Home-Work Distance', help="In kilometers"),
|
||||
'contract_ids': fields.one2many('hr.contract', 'employee_id', 'Contracts'),
|
||||
}
|
||||
|
||||
@@ -69,47 +69,6 @@
|
||||
<field name="inherit_id" ref="hr.view_employee_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<notebook position="inside">
|
||||
<page string="Contracts">
|
||||
<field colspan="4" mode="form,tree" name="contract_ids" nolabel="1">
|
||||
<tree string="Contracts">
|
||||
<field name="name"/>
|
||||
<field name="job_id"/>
|
||||
<field name="date_start"/>
|
||||
<field name="date_end"/>
|
||||
<field name="working_hours"/>
|
||||
<field name="wage_type_id"/>
|
||||
<field name="wage"/>
|
||||
</tree>
|
||||
<form string="Contract">
|
||||
<group colspan="3" col="6">
|
||||
<field name="name" select="1"/>
|
||||
<field name="job_id"/>
|
||||
<newline/>
|
||||
<field name="wage"/>
|
||||
<field name="wage_type_id" widget="selection"/>
|
||||
<field name="type_id" widget="selection"/>
|
||||
</group>
|
||||
<notebook>
|
||||
<page string="Main Data">
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Duration"/>
|
||||
<field name="date_start" select="1"/>
|
||||
<field name="date_end" select="1"/>
|
||||
<field name="working_hours"/>
|
||||
</group>
|
||||
<group col="2" colspan="2">
|
||||
<separator colspan="2" string="Advantages"/>
|
||||
<field name="advantages_net"/>
|
||||
<field name="advantages_gross"/>
|
||||
<field name="advantages" nolabel="1" colspan="2"/>
|
||||
</group>
|
||||
<separator colspan="4" string="Notes"/>
|
||||
<field colspan="4" name="notes" nolabel="1"/>
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
</field>
|
||||
</page>
|
||||
<page string="Miscelleanous">
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Personal Info" colspan="2"/>
|
||||
@@ -122,7 +81,6 @@
|
||||
<field name="manager" select="1"/>
|
||||
<field name="vehicle" select="1"/>
|
||||
<field name="vehicle_distance" select="1"/>
|
||||
<field name="medic_exam" select="1"/>
|
||||
</group>
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Others Info" colspan="2"/>
|
||||
@@ -133,22 +91,22 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="hr_contract_view_search" model="ir.ui.view">
|
||||
<record id="hr_contract_view_search" model="ir.ui.view">
|
||||
<field name="name">hr.contract.view.search</field>
|
||||
<field name="model">hr.contract</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Search Contract">
|
||||
<group col='15' colspan='4'>
|
||||
<field name="name"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="date_start"/>
|
||||
<field name="date_end"/>
|
||||
<field name="name"/>
|
||||
<field name="employee_id"/>
|
||||
<field name="date_start"/>
|
||||
<field name="date_end"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By..." colspan="4" col="20">
|
||||
<filter string="Wage Type" icon="terp-stock_symbol-selection" domain="[]" context="{'group_by':'wage_type_id'}"/>
|
||||
</group>
|
||||
<filter string="Wage Type" icon="terp-stock_symbol-selection" domain="[]" context="{'group_by':'wage_type_id'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
@@ -217,7 +175,7 @@
|
||||
<field name="search_view_id" ref="hr_contract_view_search"/>
|
||||
</record>
|
||||
|
||||
<record id="hr_contract_type_view_form" model="ir.ui.view">
|
||||
<record id="hr_contract_type_view_form" model="ir.ui.view">
|
||||
<field name="name">hr.contract.type.view.form</field>
|
||||
<field name="model">hr.contract.type</field>
|
||||
<field name="type">form</field>
|
||||
@@ -228,7 +186,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="hr_contract_type_view_tree" model="ir.ui.view">
|
||||
<record id="hr_contract_type_view_tree" model="ir.ui.view">
|
||||
<field name="name">hr.contract.type.view.tree</field>
|
||||
<field name="model">hr.contract.type</field>
|
||||
<field name="type">tree</field>
|
||||
@@ -246,11 +204,10 @@
|
||||
</record>
|
||||
<menuitem action="action_hr_contract_type" id="hr_menu_contract_type" parent="next_id_56"/>
|
||||
|
||||
<!--<menuitem id="hr_menu_contract_main" parent="hr.menu_hr_root" name="Contracts" sequence="3"/> -->
|
||||
<menuitem action="action_hr_contract" id="hr_menu_contract" parent="hr.menu_hr_root" name="Contracts" sequence="4"/>
|
||||
<menuitem action="action_hr_contract" id="hr_menu_contract" parent="hr.menu_hr_main" name="Contracts" sequence="4"/>
|
||||
|
||||
<!-- Contracts Button on Employee Form -->
|
||||
<act_window domain="[('employee_id', '=', active_id)]" id="act_hr_employee_2_hr_contract" name="Contracts" res_model="hr.contract" src_model="hr.employee"/>
|
||||
<act_window domain="[('employee_id', '=', active_id)]" id="act_hr_employee_2_hr_contract" name="Contracts" res_model="hr.contract" src_model="hr.employee"/>
|
||||
|
||||
|
||||
</data>
|
||||
|
||||
@@ -8,5 +8,8 @@
|
||||
"access_hr_contract_user","hr.contract user","model_hr_contract","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_contract","hr.contract","model_hr_contract","group_hr_contract",1,1,1,1
|
||||
"access_hr_employee_contract","hr.employee contract","hr.model_hr_employee","group_hr_contract",1,0,0,0
|
||||
"access_hr_resource_contract","hr.employee.resource contract","resource.model_resource_resource","group_hr_contract",1,0,0,0
|
||||
"access_hr_resource_calendar_contract","hr.employee.resource.calendar contract","resource.model_resource_calendar","group_hr_contract",1,0,0,0
|
||||
"access_hr_job_contract","hr.employee.job contract","hr.model_hr_job","group_hr_contract",1,0,0,0
|
||||
"access_hr_contract_type_user","hr.contract.type user","model_hr_contract_type","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_contract_type","hr.contract.type","model_hr_contract_type","group_hr_contract",1,1,1,1
|
||||
|
||||
|
@@ -257,7 +257,7 @@
|
||||
/>
|
||||
|
||||
<separator orientation="vertical"/>
|
||||
<field name="employee_id" widget="selection" select="1"/>
|
||||
<field name="employee_id" select="1"/>
|
||||
<field name="plan_id" widget="selection" select="1"/>
|
||||
</group>
|
||||
<newline/>
|
||||
@@ -349,8 +349,8 @@
|
||||
<separator orientation="vertical"/>
|
||||
<filter icon="terp-gnome-cpu-frequency-applet+" string="Late" domain="[('date_deadline','<',current_date)]"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_to_review_id" widget="selection"/>
|
||||
<field name="user_id" string="Interviewer" widget="selection"/>
|
||||
<field name="user_to_review_id"/>
|
||||
<field name="user_id" string="Interviewer"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_evaluation_evaluation","hr_evaluation.evaluation","model_hr_evaluation_evaluation","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_evaluation_manager","hr_evaluation.evaluation","model_hr_evaluation_evaluation","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_evaluation","hr_evaluation.evaluation","model_hr_evaluation_evaluation","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_evaluation_plan","hr_evaluation.plan","model_hr_evaluation_evaluation","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_plan_manager","hr_evaluation.plan","model_hr_evaluation_plan","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_plan_phase","hr_evaluation.plan.phase","model_hr_evaluation_plan_phase","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_plan_phase_manager","hr_evaluation.plan.phase","model_hr_evaluation_plan_phase","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_interview","hr.evaluation.interview","model_hr_evaluation_interview","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_interview_manager","hr.evaluation.interview","model_hr_evaluation_interview","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_report","hr.evaluation.report","model_hr_evaluation_report",,1,0,0,0
|
||||
"access_hr_evaluation_reminder_manager","hr.evaluation.reminder","model_hr_evaluation_reminder","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_evaluation_reminder","hr.evaluation.reminder","model_hr_evaluation_reminder","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_evaluation_interview","hr.evaluation.interview","model_hr_evaluation_interview","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_evaluation_report","hr.evaluation.report","model_hr_evaluation_report","hr.group_hr_manager",1,0,0,0
|
||||
"access_hr_evaluation_reminder","hr.evaluation.reminder","model_hr_evaluation_reminder","hr.group_hr_user",1,1,1,1
|
||||
|
||||
|
@@ -145,8 +145,8 @@
|
||||
<separator orientation="vertical"/>
|
||||
<field name="name" select='1'/>
|
||||
<field name="date" select='1'/>
|
||||
<field name="user_id" select="1" widget="selection" string="User">
|
||||
<filter icon="terp-personal+"
|
||||
<field name="user_id" select="1" string="User">
|
||||
<filter icon="terp-personal+"
|
||||
domain="[('department_id','=',context.get('department_id',False))]"
|
||||
string="Expenses of My Department"/>
|
||||
</field>
|
||||
@@ -183,7 +183,7 @@
|
||||
<field name="inherit_id" ref="product.product_normal_form_view"/>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<field groups="base.group_extended" name="rental" position="after">
|
||||
<field name="purchase_ok" position="after">
|
||||
<field name="hr_expense_ok"/>
|
||||
</field>
|
||||
</field>
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<filter icon="terp-camera_test" domain="[('state','=','validate')]" string="Validated"
|
||||
default="context.get('report', False)"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_id" widget="selection"/>
|
||||
<field name="user_id"/>
|
||||
<field name="department_id" widget="selection">
|
||||
<filter icon="terp-personal+" help="My Department Holidays"
|
||||
domain="[('department_id.manager_id','=',uid)]"
|
||||
|
||||
@@ -9,3 +9,4 @@
|
||||
"access_available_holidays_report","hr.available.holidays.report","model_available_holidays_report","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_holidays_report_user","hr.holidays.report","model_hr_holidays_report","hr.group_hr_user",1,0,0,0
|
||||
"access_available_holidays_report_user","hr.available.holidays.report","model_available_holidays_report","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_holidays_summary_dept","hr.holidays.summary.dept","model_hr_holidays_summary_dept","hr.group_hr_manager",1,1,1,1
|
||||
|
||||
|
@@ -77,7 +77,7 @@ class hr_applicant(osv.osv, crm.crm_case):
|
||||
domain="[('partner_id','=',partner_id)]"),
|
||||
'create_date': fields.datetime('Creation Date' , readonly=True),
|
||||
'write_date': fields.datetime('Update Date' , readonly=True),
|
||||
'stage_id': fields.many2one ('crm.case.stage', 'Stage', \
|
||||
'stage_id': fields.many2one ('hr.recruitment.stage', 'Stage', \
|
||||
domain="[('section_id','=',section_id),\
|
||||
('object_id.model', '=', 'crm.opportunity')]"),
|
||||
'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True,
|
||||
@@ -98,7 +98,6 @@ class hr_applicant(osv.osv, crm.crm_case):
|
||||
'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')]"),
|
||||
'department_id':fields.many2one('hr.department', 'Department'),
|
||||
'state': fields.selection(AVAILABLE_STATES, 'State', size=16, readonly=True),
|
||||
|
||||
@@ -30,8 +30,6 @@
|
||||
<field name="object_id" search="[('model','=','hr.applicant')]" model="ir.model"/>
|
||||
</record>
|
||||
|
||||
<!-- STAGE(stage_id) -->
|
||||
|
||||
<record model="hr.recruitment.stage" id="stage_job1">
|
||||
<field name="name">Initial Jobs Demand</field>
|
||||
<field name="object_id" search="[('model','=','hr.applicant')]" model="ir.model"/>
|
||||
|
||||
@@ -13,23 +13,22 @@
|
||||
# ------------------------------------------------------
|
||||
|
||||
<record id="hr_job_categ_action" model="ir.actions.act_window">
|
||||
<field name="name">Applicant Categories</field>
|
||||
<field name="res_model">crm.case.categ</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="crm.crm_case_categ_tree-view"/>
|
||||
<field name="domain">[('object_id.model', '=', 'hr.applicant')]</field>
|
||||
<field name="context">{'object_id':'hr.applicant'}</field>
|
||||
<field name="name">Applicant Categories</field>
|
||||
<field name="res_model">crm.case.categ</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="crm.crm_case_categ_tree-view"/>
|
||||
<field name="domain">[('object_id.model', '=', 'hr.applicant')]</field>
|
||||
<field name="context">{'object_id':'hr.applicant'}</field>
|
||||
</record>
|
||||
# ------------------------------------------------------
|
||||
# Stage
|
||||
# ------------------------------------------------------
|
||||
<record id="hr_job_stage_act" model="ir.actions.act_window">
|
||||
<field name="name">Applicant Stages</field>
|
||||
<field name="res_model">crm.case.stage</field>
|
||||
<field name="res_model">hr.recruitment.stage</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="crm.crm_case_stage_tree"/>
|
||||
<field name="domain">[('object_id.model', '=', 'hr.applicant')]</field>
|
||||
<field name="context">{'object_id':'hr.applicant'}</field>
|
||||
<field name="domain">[]</field>
|
||||
<field name="context">{}</field>
|
||||
</record>
|
||||
|
||||
<menuitem action="hr_job_stage_act" id="menu_hr_job_stage_act" name="Stages" parent="menu_hr_config_applicant"/>
|
||||
@@ -84,9 +83,9 @@
|
||||
</group>
|
||||
<newline/>
|
||||
<group colspan="3" col="6">
|
||||
<field name="partner_name"/>
|
||||
<field name="job_id" on_change="onchange_job(job_id)"/>
|
||||
<button string="Schedule a Phone Call" name="%(action_hr_recruitment_phonecall)d" icon="gtk-redo" type="action"/>
|
||||
<field name="partner_name"/>
|
||||
<field name="job_id" on_change="onchange_job(job_id)"/>
|
||||
<button string="Schedule a Phone Call" name="%(action_hr_recruitment_phonecall)d" icon="gtk-redo" type="action"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group colspan="3" col="6">
|
||||
@@ -96,7 +95,7 @@
|
||||
</group>
|
||||
<button name="action_print_survey" string="Print Interview" type="object" icon="gtk-print" attrs="{'readonly':[('survey','=',False)]}" groups="base.group_extended"/>
|
||||
<button name="%(survey.action_view_survey_question_message)d" string="Interview Question" type="action" icon="gtk-execute" context="{'survey_id': survey, 'response_id': [response], 'response_no':0 ,'active' : response, 'object' : 'hr.applicant', 'cur_id' :active_id}" attrs="{'readonly':[('survey','=',False)]}" groups="base.group_extended"/>
|
||||
</group>
|
||||
</group>
|
||||
<notebook colspan="4">
|
||||
<page string="Job Info">
|
||||
<group col="2" colspan="2">
|
||||
@@ -187,9 +186,9 @@
|
||||
</tree>
|
||||
</field>
|
||||
<button colspan="4" string="Send New Email"
|
||||
name="%(crm.action_crm_send_mail)d"
|
||||
context="{'mail':'new', 'model': 'hr.applicant'}"
|
||||
icon="gtk-go-forward" type="action" />
|
||||
name="%(crm.action_crm_send_mail)d"
|
||||
context="{'mail':'new', 'model': 'hr.applicant'}"
|
||||
icon="gtk-go-forward" type="action" />
|
||||
</page>
|
||||
</notebook>
|
||||
</form>
|
||||
@@ -237,7 +236,7 @@
|
||||
<field name="partner_name"/>
|
||||
<field name="email_from"/>
|
||||
<field name="job_id" widget="selection"/>
|
||||
<field name="user_id" widget="selection">
|
||||
<field name="user_id">
|
||||
<filter domain="[('user_id','=',False)]" help="Unassigned Recruitements" icon="terp-personal-" separator="1"/>
|
||||
</field>
|
||||
<field name="department_id" widget="selection" string="Department" context="{'invisible_department': False}">
|
||||
@@ -282,56 +281,56 @@
|
||||
|
||||
<!-- Stage Tree View -->
|
||||
|
||||
<record model="ir.ui.view" id="hr_recruitment_stage_tree">
|
||||
<field name="name">hr.recruitment.stage.tree</field>
|
||||
<field name="model">hr.recruitment.stage</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Stages">
|
||||
<field name="sequence"/>
|
||||
<field name="name"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="hr_recruitment_stage_tree">
|
||||
<field name="name">hr.recruitment.stage.tree</field>
|
||||
<field name="model">hr.recruitment.stage</field>
|
||||
<field name="type">tree</field>
|
||||
<field name="arch" type="xml">
|
||||
<tree string="Stages">
|
||||
<field name="sequence"/>
|
||||
<field name="name"/>
|
||||
</tree>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Stage Form View -->
|
||||
|
||||
<record model="ir.ui.view" id="hr_recruitment_stage_form">
|
||||
<field name="name">hr.recruitment.stage.form</field>
|
||||
<field name="model">hr.recruitment.stage</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Stage">
|
||||
<separator string="Stage Definition" colspan="4"/>
|
||||
<field name="name" select="1"/>
|
||||
<field name="sequence"/>
|
||||
<separator string="Requirements" colspan="4"/>
|
||||
<field name="requirements" nolabel="1" colspan="4"/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
<record model="ir.ui.view" id="hr_recruitment_stage_form">
|
||||
<field name="name">hr.recruitment.stage.form</field>
|
||||
<field name="model">hr.recruitment.stage</field>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Stage">
|
||||
<separator string="Stage Definition" colspan="4"/>
|
||||
<field name="name" select="1"/>
|
||||
<field name="sequence"/>
|
||||
<separator string="Requirements" colspan="4"/>
|
||||
<field name="requirements" nolabel="1" colspan="4"/>
|
||||
</form>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!-- Stage Action -->
|
||||
|
||||
<record id="hr_recruitment_stage_act" model="ir.actions.act_window">
|
||||
<field name="name">Stages</field>
|
||||
<field name="res_model">hr.recruitment.stage</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="hr_recruitment_stage_tree"/>
|
||||
</record>
|
||||
<record id="hr_recruitment_stage_act" model="ir.actions.act_window">
|
||||
<field name="name">Stages</field>
|
||||
<field name="res_model">hr.recruitment.stage</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="hr_recruitment_stage_tree"/>
|
||||
</record>
|
||||
|
||||
<menuitem
|
||||
id="menu_hr_recruitment_recruitment"
|
||||
name="Recruitment"
|
||||
parent="hr.menu_hr_configuration"
|
||||
/>
|
||||
<menuitem
|
||||
id="menu_hr_recruitment_recruitment"
|
||||
name="Recruitment"
|
||||
parent="hr.menu_hr_configuration"
|
||||
/>
|
||||
|
||||
<menuitem
|
||||
id="menu_hr_recruitment_stage"
|
||||
name="Stages"
|
||||
parent="menu_hr_recruitment_recruitment"
|
||||
action="hr_recruitment_stage_act"
|
||||
sequence="1"/>
|
||||
<menuitem
|
||||
id="menu_hr_recruitment_stage"
|
||||
name="Stages"
|
||||
parent="menu_hr_recruitment_recruitment"
|
||||
action="hr_recruitment_stage_act"
|
||||
sequence="1"/>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_applicant","hr.applicant","model_hr_applicant","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_recruitment_report","hr.recruitment.report","model_hr_recruitment_report",,1,0,0,0
|
||||
"access_hr_applicant","hr.applicant","model_hr_applicant","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_recruitment_report","hr.recruitment.report","model_hr_recruitment_report","hr.group_hr_manager",1,0,0,0
|
||||
|
||||
|
@@ -1,4 +1,7 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_hr_analytic_timesheet","hr.analytic.timesheet","model_hr_analytic_timesheet","hr.group_hr_user",1,1,1,1
|
||||
"access_hr_account_analytic_line","account.account.analytic.line","account.model_account_analytic_line","hr.group_hr_user",1,1,1,0
|
||||
"access_account_analytic_journal","account.account.analytic.journal","account.model_account_analytic_journal","hr.group_hr_user",1,0,0,0
|
||||
"access_account_analytic_journal","account.account.analytic.journal","account.model_account_analytic_journal","hr.group_hr_user",1,0,0,0
|
||||
"access_hr_sign_in_project","hr.sign.in.project attendance","model_hr_sign_in_project","hr_attendance.group_hr_attendance",1,0,0,0
|
||||
"access_hr_analytal_timesheet_employee","hr.analytical.timesheet.employee","model_hr_analytical_timesheet_employee","hr.group_hr_manager",1,1,1,1
|
||||
"access_hr_analytal_timesheet_user","hr.analytical.timesheet.user","model_hr_analytical_timesheet_users","hr.group_hr_user",1,1,1,1
|
||||
|
||||
|
@@ -20,7 +20,7 @@
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="view_account_analytic_account_form" model="ir.ui.view">
|
||||
<field name="name">account.analytic.account.form</field>
|
||||
<field name="model">account.analytic.account</field>
|
||||
@@ -32,7 +32,7 @@
|
||||
</field>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
|
||||
<record id="hr_timesheet_line_form" model="ir.ui.view">
|
||||
<field name="name">hr.analytic.timesheet.form</field>
|
||||
<field name="model">hr.analytic.timesheet</field>
|
||||
@@ -117,9 +117,9 @@
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="domain">[('to_invoice','<>',False)]</field>
|
||||
</record>
|
||||
<menuitem
|
||||
action="action_hr_analytic_timesheet_open_tree"
|
||||
id="menu_hr_analytic_timesheet_tree"
|
||||
<menuitem
|
||||
action="action_hr_analytic_timesheet_open_tree"
|
||||
id="menu_hr_analytic_timesheet_tree"
|
||||
parent="account.menu_finance_periodical_processing"/>
|
||||
|
||||
<record id="action_hr_analytic_timesheet_tree_invoiced" model="ir.actions.act_window">
|
||||
@@ -178,9 +178,9 @@
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_id" ref="view_hr_timesheet_invoice_factor_tree"/>
|
||||
</record>
|
||||
<menuitem
|
||||
action="action_hr_timesheet_invoice_factor_form"
|
||||
id="hr_timesheet_invoice_factor_view"
|
||||
<menuitem
|
||||
action="action_hr_timesheet_invoice_factor_form"
|
||||
id="hr_timesheet_invoice_factor_view"
|
||||
parent="account.account_analytic_def_account"/>
|
||||
|
||||
</data>
|
||||
|
||||
@@ -3,9 +3,10 @@
|
||||
"access_hr_timesheet_invoice_factor_acc_inv","hr_timesheet_invoice.factor.account.invoice","model_hr_timesheet_invoice_factor","account.group_account_invoice",1,1,1,1
|
||||
"access_report_analytic_account_close","report.analytic.account.close","model_report_analytic_account_close","account.group_account_manager",1,0,0,0
|
||||
"access_report_account_analytic_line_to_invoice","report.account.analytic.line.to.invoice","model_report_account_analytic_line_to_invoice","account.group_account_manager",1,0,0,0
|
||||
"access_report_timesheet_user","report_timesheet.user","model_report_timesheet_user","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_account","report_timesheet.account","model_report_timesheet_account","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_account_date","report_timesheet.account.date","model_report_timesheet_account_date","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_invoice","report_timesheet.invoice","model_report_timesheet_invoice","base.group_user",1,0,0,0
|
||||
"access_report_random_timesheet","report_random_timesheet","model_report_random_timesheet","base.group_user",1,0,0,0
|
||||
"access_report_random_timesheet_lines","random_timesheet_lines","model_random_timesheet_lines","base.group_user",1,0,0,0
|
||||
"access_report_timesheet_user","report_timesheet.user","model_report_timesheet_user","hr.group_hr_manager",1,0,0,0
|
||||
"access_report_timesheet_account","report_timesheet.account","model_report_timesheet_account","hr.group_hr_manager",1,0,0,0
|
||||
"access_report_timesheet_account_date","report_timesheet.account.date","model_report_timesheet_account_date","hr.group_hr_manager",1,0,0,0
|
||||
"access_report_timesheet_invoice","report_timesheet.invoice","model_report_timesheet_invoice","hr.group_hr_manager",1,0,0,0
|
||||
"access_report_random_timesheet","report_random_timesheet","model_report_random_timesheet","hr.group_hr_manager",1,0,0,0
|
||||
"access_report_random_timesheet_lines","random_timesheet_lines","model_random_timesheet_lines","hr.group_hr_manager",1,0,0,0
|
||||
"access_hr_timesheet_analytic_profit","hr_timesheet_analytic_profit","model_hr_timesheet_analytic_profit","account.group_account_invoice",1,1,1,1
|
||||
|
||||
|
@@ -195,7 +195,7 @@
|
||||
<filter icon="terp-document-new" string="In Draft" domain="[('state','in',('draft', 'new'))]" help="Unvalidated Timesheets"/>
|
||||
<filter icon="terp-gtk-go-back-rtl" string="To Validate" domain="[('state','=','confirm')]" help="Confirmed Timesheets"/>
|
||||
<separator orientation="vertical"/>
|
||||
<field name="user_id" select="1" widget="selection"/>
|
||||
<field name="user_id" select="1"/>
|
||||
<field name="date_from"/>
|
||||
<field name="department_id" widget="selection">
|
||||
<filter icon="terp-personal+"
|
||||
|
||||
+20
-20
@@ -68,8 +68,8 @@
|
||||
action="action_idea_category_tree"/>
|
||||
|
||||
<menuitem name="Give Vote" parent="menu_ideas1"
|
||||
id="menu_give_vote"
|
||||
action="action_idea_select"/>
|
||||
id="menu_give_vote"
|
||||
action="action_idea_select"/>
|
||||
|
||||
|
||||
<!-- Open Ideas Action -->
|
||||
@@ -128,11 +128,11 @@
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<form string="Votes">
|
||||
<group colspan="4">
|
||||
<field name="user_id" select="1" />
|
||||
<field name="date"/>
|
||||
<newline/>
|
||||
<field name="score"/>
|
||||
<group colspan="4">
|
||||
<field name="user_id" select="1" />
|
||||
<field name="date"/>
|
||||
<newline/>
|
||||
<field name="score"/>
|
||||
</group>
|
||||
<separator string="Comments:" colspan="4"/>
|
||||
<field name="comment" colspan="4" nolabel="1"/>
|
||||
@@ -147,18 +147,18 @@
|
||||
<field name="model">idea.vote</field>
|
||||
<field name="type">search</field>
|
||||
<field name="arch" type="xml">
|
||||
<search string="Ideas vote">
|
||||
<group col="10" colspan="4">
|
||||
<field name="idea_id" widget="selection"/>
|
||||
<field name="user_id" widget="selection"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By..." colspan="14">
|
||||
<filter string="Vote date" icon="terp-go-month" domain="[]" context="{'group_by':'date'}"/>
|
||||
<filter string="Idea" icon="terp-idea" domain="[]" context="{'group_by':'idea_id'}"/>
|
||||
<filter string="User" name="user" icon="terp-personal" domain="[]" context="{'group_by':'user_id'}"/>
|
||||
</group>
|
||||
</search>
|
||||
<search string="Ideas vote">
|
||||
<group col="10" colspan="4">
|
||||
<field name="idea_id" widget="selection"/>
|
||||
<field name="user_id"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By..." colspan="14">
|
||||
<filter string="Vote date" icon="terp-go-month" domain="[]" context="{'group_by':'date'}"/>
|
||||
<filter string="Idea" icon="terp-idea" domain="[]" context="{'group_by':'idea_id'}"/>
|
||||
<filter string="User" name="user" icon="terp-personal" domain="[]" context="{'group_by':'user_id'}"/>
|
||||
</group>
|
||||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
@@ -270,7 +270,7 @@
|
||||
<separator orientation="vertical"/>
|
||||
<field name="title" select="1"/>
|
||||
<field name="category_id" select="1"/>
|
||||
<field name="user_id" select="1" widget="selection"/>
|
||||
<field name="user_id" select="1"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By..." colspan="12" col="10">
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_knowledge_installer","knowledge.installer","model_knowledge_installer",base.group_user,1,0,0,0
|
||||
"access_knowledge_installer","knowledge.installer","model_knowledge_installer",base.group_system,1,1,1,1
|
||||
|
||||
|
@@ -1,6 +1,6 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_vat_listing_clients","vat.listing.clients","model_vat_listing_clients",,1,1,1,1
|
||||
"access_partner_vat_intra","partner.vat.intra","model_partner_vat_intra",,1,1,1,1
|
||||
"access_partner_vat","partner.vat","model_partner_vat",,1,1,1,1
|
||||
"access_partner_vat_list","partner.vat.list","model_partner_vat_list",,1,1,1,1
|
||||
"access_l1on_be_vat_declaration","l1on_be.vat.declaration","model_l1on_be_vat_declaration",,1,1,1,1
|
||||
"access_vat_listing_clients","vat.listing.clients","model_vat_listing_clients",account.group_account_user,1,1,1,1
|
||||
"access_partner_vat_intra","partner.vat.intra","model_partner_vat_intra",account.group_account_user,1,1,1,1
|
||||
"access_partner_vat","partner.vat","model_partner_vat",account.group_account_user,1,1,1,1
|
||||
"access_partner_vat_list","partner.vat.list","model_partner_vat_list",account.group_account_user,1,1,1,1
|
||||
"access_l1on_be_vat_declaration","l1on_be.vat.declaration","model_l1on_be_vat_declaration",account.group_account_user,1,1,1,1
|
||||
|
||||
|
@@ -66,7 +66,7 @@ class mailgate_thread(osv.osv):
|
||||
'res_id': fields.integer('Resource ID'),
|
||||
}
|
||||
|
||||
def __history(self, cr, uid, cases, keyword, history=False, subject=None, email=False, details=None, email_from=False, message_id=False, attach=[], context={}):
|
||||
def _history(self, cr, uid, cases, keyword, history=False, subject=None, email=False, details=None, email_from=False, message_id=False, attach=None, context=None):
|
||||
"""
|
||||
@param self: The object pointer
|
||||
@param cr: the current row, from the database cursor,
|
||||
@@ -80,9 +80,13 @@ class mailgate_thread(osv.osv):
|
||||
@param context: A standard dictionary for contextual values"""
|
||||
if context is None:
|
||||
context = {}
|
||||
if attach is None:
|
||||
attach = []
|
||||
|
||||
# The mailgate sends the ids of the cases and not the object list
|
||||
if all(isinstance(case_id, (int, long)) for case_id in cases) and context.get('model'):
|
||||
cases = self.pool.get(context['model']).browse(cr, uid, cases, context=context)
|
||||
|
||||
if all(isinstance(case_id, (int, long)) for case_id in cases):
|
||||
cases = self.browse(cr, uid, cases, context=context)
|
||||
|
||||
att_obj = self.pool.get('ir.attachment')
|
||||
obj = self.pool.get('mailgate.message')
|
||||
@@ -94,7 +98,7 @@ class mailgate_thread(osv.osv):
|
||||
'model' : case._name,
|
||||
'res_id': case.id,
|
||||
'date': time.strftime('%Y-%m-%d %H:%M:%S'),
|
||||
'thread_id': case.thread_id.id,
|
||||
'thread_id': case.thread_id.id,
|
||||
'message_id': message_id,
|
||||
}
|
||||
attachments = []
|
||||
@@ -125,8 +129,7 @@ class mailgate_thread(osv.osv):
|
||||
case._table.log(cr, uid, case.id, case._description + " '" + case.name + "': " + keyword, context=context)
|
||||
return True
|
||||
|
||||
_history = __history
|
||||
history = __history
|
||||
__history = history = _history
|
||||
|
||||
|
||||
mailgate_thread()
|
||||
|
||||
@@ -3,7 +3,8 @@
|
||||
##############################################################################
|
||||
#
|
||||
# OpenERP, Open Source Management Solution
|
||||
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
|
||||
# Copyright (C) 2004-2009 Tiny SPRL (<http://tiny.be>).
|
||||
# Copyright (C) 2010-TODAY OpenERP S.A. (http://www.openerp.com)
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU Affero General Public License as
|
||||
@@ -88,9 +89,9 @@ class email_parser(object):
|
||||
return ''.join(map(lambda x:self._to_decode(x[0], [x[1]]), s or []))
|
||||
|
||||
def msg_send(self, msg, emails, priority=None):
|
||||
if not len(emails):
|
||||
if not emails:
|
||||
return False
|
||||
del msg['To']
|
||||
|
||||
msg['To'] = emails[0]
|
||||
if len(emails)>1:
|
||||
if 'Cc' in msg:
|
||||
@@ -141,7 +142,6 @@ class email_parser(object):
|
||||
return res_id, msg_mails
|
||||
|
||||
if __name__ == '__main__':
|
||||
import sys, optparse
|
||||
parser = optparse.OptionParser(usage='usage: %prog [options]', version='%prog v1.0')
|
||||
group = optparse.OptionGroup(parser, "Note",
|
||||
"This program parse a mail from standard input and communicate "
|
||||
|
||||
@@ -29,7 +29,10 @@
|
||||
"description": "Menu for Marketing",
|
||||
'website': 'http://www.openerp.com',
|
||||
'init_xml': [],
|
||||
'update_xml': ['marketing_view.xml'],
|
||||
'update_xml': [
|
||||
'marketing_view.xml',
|
||||
'security/ir.model.access.csv'
|
||||
],
|
||||
'demo_xml': [],
|
||||
'installable': True,
|
||||
'active': False,
|
||||
|
||||
@@ -29,8 +29,9 @@
|
||||
<attribute name="string">Configure</attribute>
|
||||
</xpath>
|
||||
<group colspan="8">
|
||||
<field name="marketing_campaign" />
|
||||
<field name="email_template" />
|
||||
<field name="crm_profiling" />
|
||||
<field name="marketing_campaign" />
|
||||
<field name="marketing_campaign_mailchimp" />
|
||||
</group>
|
||||
</data>
|
||||
|
||||
@@ -25,7 +25,8 @@ class marketing_installer(osv.osv_memory):
|
||||
_name = 'marketing.installer'
|
||||
_inherit = 'res.config.installer'
|
||||
_columns = {
|
||||
# Generic modules
|
||||
'email_template':fields.boolean('Automated E-Mails',
|
||||
help="Helps you to design templates of emails and integrate them in your different processes."),
|
||||
'marketing_campaign':fields.boolean('Marketing Campaigns',
|
||||
help="Helps you to manage marketing campaigns and automate actions and communication steps."),
|
||||
'marketing_campaign_mailchimp':fields.boolean('Mailchimp Integration',
|
||||
|
||||
@@ -0,0 +1,3 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_marketing_installer","marketing.installer","model_marketing_installer","base.group_system",1,1,1,1
|
||||
"access_res_config_installer","access_marketing_installer","base.model_res_config_installer","base.group_system",1,1,1,1
|
||||
|
Executable → Regular
Executable → Regular
+2
@@ -39,6 +39,8 @@
|
||||
'marketing_campaign_data.xml',
|
||||
'marketing_campaign_workflow.xml',
|
||||
'report/campaign_analysis_view.xml',
|
||||
"security/marketing_campaign_security.xml",
|
||||
"security/ir.model.access.csv"
|
||||
],
|
||||
'demo_xml': [
|
||||
'marketing_campaign_demo.xml',
|
||||
|
||||
Executable → Regular
+71
-49
@@ -101,7 +101,7 @@ class marketing_campaign_segment(osv.osv):
|
||||
_columns = {
|
||||
'name': fields.char('Name', size=64,required=True),
|
||||
'campaign_id': fields.many2one('marketing.campaign', 'Campaign',
|
||||
required=True),
|
||||
required=True, select=1),
|
||||
'object_id': fields.related('campaign_id','object_id',
|
||||
type='many2one', relation='ir.model',
|
||||
string='Object'),
|
||||
@@ -200,7 +200,7 @@ class marketing_campaign_activity(osv.osv):
|
||||
_columns = {
|
||||
'name': fields.char('Name', size=128, required=True),
|
||||
'campaign_id': fields.many2one('marketing.campaign', 'Campaign',
|
||||
required = True, ondelete='cascade'),
|
||||
required = True, ondelete='cascade', select=1),
|
||||
'object_id': fields.related('campaign_id','object_id',
|
||||
type='many2one', relation='ir.model',
|
||||
string='Object'),
|
||||
@@ -242,7 +242,7 @@ class marketing_campaign_activity(osv.osv):
|
||||
self._actions = {'paper' : self.process_wi_report,
|
||||
'email' : self.process_wi_email,
|
||||
'server_action' : self.process_wi_action,
|
||||
}
|
||||
}
|
||||
return super(marketing_campaign_activity, self).__init__(*args)
|
||||
|
||||
def search(self, cr, uid, args, offset=0, limit=None, order=None,
|
||||
@@ -259,7 +259,7 @@ class marketing_campaign_activity(osv.osv):
|
||||
return super(marketing_campaign_activity, self).search(cr, uid, args,
|
||||
offset, limit, order, context, count)
|
||||
|
||||
def process_wi_report(self, cr, uid, activity, workitem):
|
||||
def process_wi_report(self, cr, uid, activity, workitem, context={}):
|
||||
service = netsvc.LocalService('report.%s'%activity.report_id.report_name)
|
||||
(report_data, format) = service.create(cr, uid, [], {}, {})
|
||||
attach_vals = {
|
||||
@@ -274,46 +274,58 @@ class marketing_campaign_activity(osv.osv):
|
||||
self.pool.get('ir.attachment').create(cr, uid, attach_vals)
|
||||
return True
|
||||
|
||||
def process_wi_email(self, cr, uid, activity, workitem):
|
||||
template = activity.email_template_id
|
||||
accounts = template.enforce_from_account
|
||||
if not template.enforce_from_account:
|
||||
return {'error_msg' : "There is no account defined for the email"}
|
||||
if not workitem.partner_id.email:
|
||||
return {'error_msg' : "There is no email defined for the partner"}
|
||||
vals = {
|
||||
'email_from': tools.ustr(accounts.name) + "<" + tools.ustr(accounts.email_id) + ">",
|
||||
'email_to': workitem.partner_id.email,
|
||||
'subject': template.def_subject,
|
||||
'body_text': template.def_body_text,
|
||||
'body_html': template.def_body_html,
|
||||
'account_id':accounts.id,
|
||||
'state':'na',
|
||||
'mail_type':'multipart/alternative' #Options:'multipart/mixed','multipart/alternative','text/plain','text/html'
|
||||
}
|
||||
# if accounts.use_sign:
|
||||
# signature = self.pool.get('res.users').read(cr, uid, uid, ['signature'], context)['signature']
|
||||
# if signature:
|
||||
# vals['pem_body_text'] = tools.ustr(vals['pem_body_text'] or '') + signature
|
||||
# vals['pem_body_html'] = tools.ustr(vals['pem_body_html'] or '') + signature
|
||||
def process_wi_email(self, cr, uid, activity, workitem, context=None):
|
||||
print 'Sending Email Init', activity.name
|
||||
return self.pool.get('email.template').generate_mail(cr, uid, activity.email_template_id.id, [workitem.res_id], context=context)
|
||||
|
||||
#Create partly the mail and later update attachments
|
||||
mail_id = self.pool.get('email_template.mailbox').create(cr, uid, vals, context)
|
||||
#if not template.enforce_from_account:
|
||||
# self.pool.get('marketing.campaign.workitem').write(cr, uid, [workitem.id], {
|
||||
# 'error_msg': 'There is no account defined for the email',
|
||||
# 'state': 'exception'
|
||||
# })
|
||||
# return False
|
||||
#if not workitem.partner_id.email:
|
||||
# self.pool.get('marketing.campaign.workitem').write(cr, uid, [workitem.id], {
|
||||
# 'error_msg': "There is no email defined for the partner",
|
||||
# 'state': 'exception'
|
||||
# })
|
||||
# return False
|
||||
#vals = {
|
||||
# 'email_from': tools.ustr(accounts.name) + "<" + tools.ustr(accounts.email_id) + ">",
|
||||
# 'email_to': template.email_to,
|
||||
# 'email_cc': template.email_cc,
|
||||
# 'email_bcc': template.email_bcc,
|
||||
# 'subject': template.def_subject,
|
||||
# 'body_text': template.def_body_text,
|
||||
# 'body_html': template.def_body_html,
|
||||
# 'account_id': accounts.id,
|
||||
# 'state':'na',
|
||||
# 'mail_type':'multipart/alternative' #Options:'multipart/mixed','multipart/alternative','text/plain','text/html'
|
||||
#}
|
||||
# # if accounts.use_sign:
|
||||
# # signature = self.pool.get('res.users').read(cr, uid, uid, ['signature'], context)['signature']
|
||||
# # if signature:
|
||||
# # vals['pem_body_text'] = tools.ustr(vals['pem_body_text'] or '') + signature
|
||||
# # vals['pem_body_html'] = tools.ustr(vals['pem_body_html'] or '') + signature
|
||||
|
||||
##Create partly the mail and later update attachments
|
||||
#print 'Sending Email', vals
|
||||
#mail_id = self.pool.get('email_template.mailbox').create(cr, uid, vals, context)
|
||||
return True
|
||||
|
||||
def process_wi_action(self, cr, uid, activity, workitem):
|
||||
|
||||
def process_wi_action(self, cr, uid, activity, workitem, context={}):
|
||||
context = {}
|
||||
server_obj = self.pool.get('ir.actions.server')
|
||||
server_obj.run(cr, uid, [activity.server_action_id.id], context)
|
||||
server_obj.run(cr, uid, [activity.server_action_id.id], context)
|
||||
return True
|
||||
|
||||
|
||||
def process(self, cr, uid, act_id, wi_id, context={}):
|
||||
activity = self.browse(cr, uid, act_id)
|
||||
print 'Process', activity.name
|
||||
workitem_obj = self.pool.get('marketing.campaign.workitem')
|
||||
workitem = workitem_obj.browse(cr, uid, wi_id)
|
||||
self._actions[activity.type](cr, uid, activity, workitem)
|
||||
return True
|
||||
workitem = workitem_obj.browse(cr, uid, wi_id, context=context)
|
||||
print 'WI', workitem, activity.type
|
||||
return self._actions[activity.type](cr, uid, activity, workitem, context)
|
||||
|
||||
marketing_campaign_activity()
|
||||
|
||||
@@ -324,7 +336,7 @@ class marketing_campaign_transition(osv.osv):
|
||||
|
||||
_columns = {
|
||||
'activity_from_id': fields.many2one('marketing.campaign.activity',
|
||||
'Source Activity'),
|
||||
'Source Activity', select=1),
|
||||
'activity_to_id': fields.many2one('marketing.campaign.activity',
|
||||
'Destination Activity'),
|
||||
'interval_nbr': fields.integer('Interval No.'),
|
||||
@@ -366,12 +378,12 @@ class marketing_campaign_workitem(osv.osv):
|
||||
'campaign_id': fields.related('segment_id', 'campaign_id',
|
||||
type='many2one', relation='marketing.campaign', string='Campaign', readonly=True),
|
||||
'object_id': fields.related('segment_id', 'campaign_id', 'object_id',
|
||||
type='many2one', relation='ir.model', string='Object'),
|
||||
'res_id': fields.integer('Resource ID'),
|
||||
type='many2one', relation='ir.model', string='Object', select=1),
|
||||
'res_id': fields.integer('Resource ID', select=1),
|
||||
'res_name': fields.function(_res_name_get, method=True, string='Resource Name', type="char", size=64),
|
||||
'date': fields.datetime('Execution Date'),
|
||||
'partner_id': fields.many2one('res.partner', 'Partner'),
|
||||
'state': fields.selection([('todo', 'ToDo'), ('inprogress', 'In Progress'),
|
||||
'partner_id': fields.many2one('res.partner', 'Partner', select=1),
|
||||
'state': fields.selection([('todo', 'To Do'), ('inprogress', 'In Progress'),
|
||||
('exception', 'Exception'), ('done', 'Done'),
|
||||
('cancelled', 'Cancelled')], 'State'),
|
||||
|
||||
@@ -400,8 +412,14 @@ class marketing_campaign_workitem(osv.osv):
|
||||
self.create(cr, uid, workitem_vals)
|
||||
return True
|
||||
|
||||
def button_draft(self, cr, uid, workitem_ids, context={}):
|
||||
for wi in self.browse(cr, uid, workitem_ids, context=context):
|
||||
if wi.state=='exception':
|
||||
self.write(cr, uid, [wi.id], {'state':'todo'}, context=context)
|
||||
return True
|
||||
|
||||
def button_cancel(self, cr, uid, workitem_ids, context={}):
|
||||
for wi in self.browse(cr, uid, workitem_ids):
|
||||
for wi in self.browse(cr, uid, workitem_ids, context=context):
|
||||
if wi.state in ('todo','exception'):
|
||||
self.write(cr, uid, [wi.id], {'state':'cancelled'}, context=context)
|
||||
return True
|
||||
@@ -419,14 +437,18 @@ class marketing_campaign_workitem(osv.osv):
|
||||
}
|
||||
expr = eval(str(wi.activity_id.condition), eval_context)
|
||||
if expr:
|
||||
try :
|
||||
try:
|
||||
result = True
|
||||
if wi.campaign_id.mode in ('manual','active'):
|
||||
self.pool.get('marketing.campaign.activity').process(
|
||||
result = self.pool.get('marketing.campaign.activity').process(
|
||||
cr, uid, wi.activity_id.id, wi.id, context)
|
||||
self.write(cr, uid, wi.id, {'state': 'done'})
|
||||
self.process_chain(cr, uid, wi.id, context)
|
||||
if result:
|
||||
self.write(cr, uid, wi.id, {'state': 'done'})
|
||||
self.process_chain(cr, uid, wi.id, context)
|
||||
else:
|
||||
self.write(cr, uid, wi.id, {'state': 'exception'})
|
||||
except Exception,e:
|
||||
self.write(cr, uid, wi.id, {'state': 'exception'})
|
||||
self.write(cr, uid, wi.id, {'state': 'exception', 'error_msg': str(e)})
|
||||
else :
|
||||
self.write(cr, uid, wi.id, {'state': 'cancelled'})
|
||||
|
||||
@@ -444,9 +466,9 @@ class marketing_campaign_workitem(osv.osv):
|
||||
workitem_ids = self.search(cr, uid, [('state', '=', 'todo')])
|
||||
else:
|
||||
# manual states are not processed automatically
|
||||
pass
|
||||
if workitem_ids:
|
||||
self.process(cr, uid, workitem_ids, context)
|
||||
workitem_ids = []
|
||||
if workitem_ids:
|
||||
self.process(cr, uid, workitem_ids, context)
|
||||
|
||||
marketing_campaign_workitem()
|
||||
|
||||
|
||||
Executable → Regular
+9
-4
@@ -182,15 +182,15 @@
|
||||
</group>
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Synchronization" colspan="2"/>
|
||||
<field name="sync_last_date"/>
|
||||
<field name="sync_mode" required="True"/>
|
||||
<field name="sync_last_date"/>
|
||||
<label string="" colspan="1"/>
|
||||
<button string="Synchronize" states="running" name="synchroniz" icon="gtk-apply" type="object"/>
|
||||
</group>
|
||||
<group colspan="2" col="2">
|
||||
<separator string="Dates" colspan="2"/>
|
||||
<field name="date_run" attrs="{'readonly':[('date_run','!=',False),('state','=','running')]}"/>
|
||||
<field name="date_done"/>
|
||||
<field name="date_run" readonly="1"/>
|
||||
<field name="date_done" readonly="1"/>
|
||||
</group>
|
||||
<separator string="Status" colspan="4"/>
|
||||
<group col="10" colspan="4">
|
||||
@@ -397,11 +397,16 @@
|
||||
<button string="Preview" states="todo" name="preview" icon="gtk-apply" type="object"/>
|
||||
</group>
|
||||
</group>
|
||||
<group colspan="4" col="4" attrs="{'invisible':[('state','!=','exception')]}">
|
||||
<separator string="Error Message" colspan="4"/>
|
||||
<field name="error_msg" nolabel="1" colspan="4"/>
|
||||
</group>
|
||||
<separator string="Status" colspan="4"/>
|
||||
<group colspan="4" col="11">
|
||||
<field name="state" nolabel="1" readonly="True" select="1"/>
|
||||
<button string="Retry" states="exception" name="button_draft" type="object" icon="gtk-ok"/>
|
||||
<button string="Process" states="todo" name="process" type="object" icon="gtk-ok"/>
|
||||
<button string="Cancel" states="todo" name="button_cancel" type="object" icon="gtk-cancel"/>
|
||||
<button string="Cancel" states="todo,exception" name="button_cancel" type="object" icon="gtk-cancel"/>
|
||||
</group>
|
||||
</form>
|
||||
</field>
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
"id","name","model_id:id","group_id:id","perm_read","perm_write","perm_create","perm_unlink"
|
||||
"access_marketing_campaign_admin","marketing.campaign","model_marketing_campaign","marketing_campaign.res_groups_marketing_campaign",1,1,1,1
|
||||
"access_marketing_campaign_segment_campaignadmin","marketing.campaign.segment","model_marketing_campaign_segment","marketing_campaign.res_groups_marketing_campaign",1,1,1,1
|
||||
"access_marketing_campaign_activity_campaignadmin","marketing.campaign.activity","model_marketing_campaign_activity","marketing_campaign.res_groups_marketing_campaign",1,1,1,1
|
||||
"access_marketing_campaign_workitem_campaignadmin","marketing.campaign.workitem","model_marketing_campaign_workitem","marketing_campaign.res_groups_marketing_campaign",1,1,1,1
|
||||
"access_marketing_campaign_transition_campaignadmin","marketing.campaign.transition","model_marketing_campaign_transition","marketing_campaign.res_groups_marketing_campaign",1,1,1,1
|
||||
"access_marketing_campaign_analysis_campaignadmin","campaign.analysis","model_campaign_analysis","marketing_campaign.res_groups_marketing_campaign",1,0,0,0
|
||||
|
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0"?>
|
||||
<openerp>
|
||||
<data>
|
||||
|
||||
<record id="res_groups_marketing_campaign" model="res.groups">
|
||||
<field name="name">Marketing / Campaign</field>
|
||||
</record>
|
||||
|
||||
</data>
|
||||
</openerp>
|
||||
+19
-19
@@ -8,13 +8,13 @@ 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: 2010-06-10 09:51+0000\n"
|
||||
"PO-Revision-Date: 2010-06-11 10:07+0000\n"
|
||||
"Last-Translator: vir (Open ERP) <vir@tinyerp.com>\n"
|
||||
"Language-Team: Hindi <hi@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-11 03:42+0000\n"
|
||||
"X-Launchpad-Export-Date: 2010-06-12 03:44+0000\n"
|
||||
"X-Generator: Launchpad (build Unknown)\n"
|
||||
|
||||
#. module: mrp
|
||||
@@ -460,7 +460,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: field:mrp.bom.revision,author_id:0
|
||||
msgid "Author"
|
||||
msgstr ""
|
||||
msgstr "लेखक"
|
||||
|
||||
#. module: mrp
|
||||
#: model:process.transition,name:mrp.process_transition_stockproduct0
|
||||
@@ -491,7 +491,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: field:mrp.procurement,message:0
|
||||
msgid "Latest error"
|
||||
msgstr ""
|
||||
msgstr "नवीनतम त्रुटि"
|
||||
|
||||
#. module: mrp
|
||||
#: field:mrp.bom,bom_lines:0
|
||||
@@ -511,7 +511,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: view:mrp.production:0
|
||||
msgid "Consumed Products"
|
||||
msgstr ""
|
||||
msgstr "खपत उत्पाद"
|
||||
|
||||
#. module: mrp
|
||||
#: constraint:mrp.bom:0
|
||||
@@ -538,12 +538,12 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: selection:mrp.procurement,state:0
|
||||
msgid "Ready"
|
||||
msgstr ""
|
||||
msgstr "तैयार"
|
||||
|
||||
#. module: mrp
|
||||
#: view:mrp.routing:0
|
||||
msgid "Workcenter Operations"
|
||||
msgstr ""
|
||||
msgstr "Workcenter संचालन"
|
||||
|
||||
#. module: mrp
|
||||
#: model:ir.actions.act_window,name:mrp.mrp_production_action2_gantt
|
||||
@@ -564,7 +564,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: field:mrp.production,date_finnished:0
|
||||
msgid "End Date"
|
||||
msgstr ""
|
||||
msgstr "समाप्ति तिथि"
|
||||
|
||||
#. module: mrp
|
||||
#: help:mrp.production,picking_id:0
|
||||
@@ -576,7 +576,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: selection:mrp.production,state:0
|
||||
msgid "In Production"
|
||||
msgstr ""
|
||||
msgstr "उत्पादन में"
|
||||
|
||||
#. module: mrp
|
||||
#: field:stock.warehouse.orderpoint,qty_multiple:0
|
||||
@@ -600,12 +600,12 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: wizard_button:mrp.workcenter.load,init,report:0
|
||||
msgid "Print"
|
||||
msgstr ""
|
||||
msgstr "प्रिंट"
|
||||
|
||||
#. module: mrp
|
||||
#: field:mrp.workcenter,type:0
|
||||
msgid "Type"
|
||||
msgstr ""
|
||||
msgstr "प्रकार"
|
||||
|
||||
#. module: mrp
|
||||
#: model:process.node,note:mrp.process_node_stockproduct0
|
||||
@@ -616,7 +616,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: selection:mrp.workcenter.load,init,time_unit:0
|
||||
msgid "Per month"
|
||||
msgstr ""
|
||||
msgstr "प्रति माह"
|
||||
|
||||
#. module: mrp
|
||||
#: field:mrp.procurement,product_uos_qty:0
|
||||
@@ -626,18 +626,18 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: rml:bom.structure:0
|
||||
msgid "Product Name"
|
||||
msgstr ""
|
||||
msgstr "वस्तु का नाम"
|
||||
|
||||
#. module: mrp
|
||||
#: rml:mrp.production.order:0
|
||||
msgid "Printing date"
|
||||
msgstr ""
|
||||
msgstr "मुद्रण तारीख"
|
||||
|
||||
#. module: mrp
|
||||
#: model:process.node,name:mrp.process_node_orderrfq0
|
||||
#: model:process.node,name:mrp.process_node_rfq0
|
||||
msgid "RFQ"
|
||||
msgstr ""
|
||||
msgstr "कोटेशन के लिए अनुरोध"
|
||||
|
||||
#. module: mrp
|
||||
#: field:mrp.bom,revision_type:0
|
||||
@@ -657,7 +657,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: field:stock.warehouse.orderpoint,product_min_qty:0
|
||||
msgid "Min Quantity"
|
||||
msgstr ""
|
||||
msgstr "न्यूनतम मात्रा"
|
||||
|
||||
#. module: mrp
|
||||
#: view:mrp.production:0
|
||||
@@ -678,7 +678,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: model:process.transition,note:mrp.process_transition_servicemts0
|
||||
msgid "If Product type is service and procure method is Make to stock"
|
||||
msgstr ""
|
||||
msgstr "अगर उत्पाद प्रकार सेवा है और खरीद विधि है स्टॉक बनाने के लिए"
|
||||
|
||||
#. module: mrp
|
||||
#: model:process.node,note:mrp.process_node_serviceproduct0
|
||||
@@ -689,7 +689,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: field:res.company,security_lead:0
|
||||
msgid "Security Days"
|
||||
msgstr ""
|
||||
msgstr "सुरक्षा दिवस"
|
||||
|
||||
#. module: mrp
|
||||
#: view:mrp.production:0
|
||||
@@ -715,7 +715,7 @@ msgstr ""
|
||||
#. module: mrp
|
||||
#: selection:mrp.procurement,state:0
|
||||
msgid "Exception"
|
||||
msgstr ""
|
||||
msgstr "अपवाद"
|
||||
|
||||
#. module: mrp
|
||||
#: wizard_view:product.product.procurement,init:0
|
||||
|
||||
+30
-30
@@ -41,7 +41,7 @@
|
||||
id="menu_mrp_configuration"
|
||||
name="Configuration"
|
||||
parent="base.menu_mrp_root"
|
||||
groups="base.group_extended"
|
||||
groups="group_mrp_manager"
|
||||
sequence="50" />
|
||||
|
||||
<record id="mrp_property_tree_view" model="ir.ui.view">
|
||||
@@ -250,7 +250,7 @@
|
||||
<newline/>
|
||||
<field name="product_uom"/>
|
||||
<field name="product_qty"/>
|
||||
<field name="routing_id" widget="selection" groups="base.group_extended"/>
|
||||
<field name="routing_id" groups="base.group_extended"/>
|
||||
<newline/>
|
||||
<field name="product_uos" groups="product.group_uos,base.group_extended" widget="selection"/>
|
||||
<field name="product_uos_qty" groups="product.group_uos,base.group_extended" />
|
||||
@@ -283,7 +283,7 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record id="view_mrp_bom_filter" model="ir.ui.view">
|
||||
<record id="view_mrp_bom_filter" model="ir.ui.view">
|
||||
<field name="name">mrp.bom.select</field>
|
||||
<field name="model">mrp.bom</field>
|
||||
<field name="type">search</field>
|
||||
@@ -291,9 +291,9 @@
|
||||
<search string="Search Bill Of Material">
|
||||
<group col='4' colspan='4'>
|
||||
<field name="name"/>
|
||||
<field name="code" string="Reference"/>
|
||||
<field name="product_id"/>
|
||||
<field name="company_id" groups="base.group_multi_company"/>
|
||||
<field name="code" string="Reference"/>
|
||||
<field name="product_id"/>
|
||||
<field name="company_id" groups="base.group_multi_company"/>
|
||||
</group>
|
||||
<newline/>
|
||||
<group expand="0" string="Group By" colspan="4" col="8" groups="base.group_extended">
|
||||
@@ -402,26 +402,26 @@
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<!--
|
||||
<!--
|
||||
Procurement
|
||||
-->
|
||||
|
||||
<menuitem action="procurement.procurement_action" id="menu_mrp_procurement_action"
|
||||
parent="mrp.menu_mrp_manufacturing" sequence="2" />
|
||||
<menuitem action="procurement.procurement_action" id="menu_mrp_procurement_action"
|
||||
parent="mrp.menu_mrp_manufacturing" sequence="2" />
|
||||
<!-- <menuitem action="procurement.procurement_action5" id="menu_mrp_procurement_exception_action"-->
|
||||
<!-- parent="mrp.menu_mrp_control" sequence="1" />-->
|
||||
<!-- parent="mrp.menu_mrp_control" sequence="1" />-->
|
||||
|
||||
<menuitem id="menu_mrp_scheduler" name="Schedulers" parent="base.menu_mrp_root" sequence="4"/>
|
||||
<menuitem id="menu_mrp_scheduler" name="Schedulers" parent="base.menu_mrp_root" sequence="4"/>
|
||||
<menuitem action="procurement.action_compute_schedulers" id="mrp_Sched_all" parent="mrp.menu_mrp_scheduler" sequence="90"/>
|
||||
|
||||
<!--
|
||||
Order Point
|
||||
-->
|
||||
<menuitem action="procurement.action_orderpoint_form" id="menu_action_orderpoint_form" parent="mrp.menu_mrp_reordering"/>
|
||||
<!--
|
||||
Order Point
|
||||
-->
|
||||
<menuitem action="procurement.action_orderpoint_form" id="menu_action_orderpoint_form" parent="mrp.menu_mrp_reordering"/>
|
||||
|
||||
<!--
|
||||
Production Management
|
||||
-->
|
||||
Production Management
|
||||
-->
|
||||
|
||||
<record id="mrp_production_tree_view" model="ir.ui.view">
|
||||
<field name="name">mrp.production.tree</field>
|
||||
@@ -515,9 +515,9 @@
|
||||
<notebook colspan="4">
|
||||
<page string="Consumed Products">
|
||||
<field name="bom_id" domain="[('product_id','=',product_id),('bom_id','=',False)]" on_change="bom_id_change(bom_id)" />
|
||||
<field name="routing_id" groups="base.group_extended" select="1" widget="selection"/>
|
||||
<field name="location_src_id" domain="[('usage','=','internal')]" widget="selection" on_change="location_id_change(location_src_id,location_dest_id)"/>
|
||||
<field name="location_dest_id" domain="[('usage','=','internal')]" widget="selection"/>
|
||||
<field name="routing_id" groups="base.group_extended" select="1"/>
|
||||
<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')]"/>
|
||||
<separator string="" colspan="4"/>
|
||||
|
||||
<field colspan="2" name="move_lines" nolabel="1" widget="one2many_list"
|
||||
@@ -807,19 +807,19 @@
|
||||
</record>
|
||||
|
||||
<!--
|
||||
Procurements
|
||||
Procurements
|
||||
-->
|
||||
|
||||
<record id="view_procurement_form_inherit" model="ir.ui.view">
|
||||
<field name="name">procurement.order.form.inherit</field>
|
||||
<field name="model">procurement.order</field>
|
||||
<field name="inherit_id" ref="procurement.procurement_form_view"/>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/notebook/page/field[@name='move_id']" position="before">
|
||||
<field name="bom_id" domain="[('product_id','=',product_id),('bom_id','=',False)]"/>
|
||||
</xpath>
|
||||
</field>
|
||||
<field name="name">procurement.order.form.inherit</field>
|
||||
<field name="model">procurement.order</field>
|
||||
<field name="inherit_id" ref="procurement.procurement_form_view"/>
|
||||
<field name="type">form</field>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="/form/notebook/page/field[@name='move_id']" position="before">
|
||||
<field name="bom_id" domain="[('product_id','=',product_id),('bom_id','=',False)]"/>
|
||||
</xpath>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<act_window
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user