[IMP] form view and apply css

bzr revid: rgaopenerp-20120622054234-cj001wr9crf7chyi
This commit is contained in:
RGA(OpenERP) 2012-06-22 11:12:34 +05:30
parent 93606a0a2e
commit a14e4b502c
4 changed files with 20 additions and 16 deletions

View File

@ -66,6 +66,8 @@ module named account_voucher.
'wizard/account_use_model_view.xml',
'account_installer.xml',
'wizard/account_period_close_view.xml',
'wizard/account_reconcile_view.xml',
'wizard/account_unreconcile_view.xml',
'account_view.xml',
'account_report.xml',
'account_financial_report_data.xml',
@ -88,14 +90,12 @@ module named account_voucher.
'wizard/account_journal_select_view.xml',
'wizard/account_change_currency_view.xml',
'wizard/account_validate_move_view.xml',
'wizard/account_unreconcile_view.xml',
'wizard/account_report_general_ledger_view.xml',
'wizard/account_invoice_state_view.xml',
'wizard/account_report_partner_balance_view.xml',
'wizard/account_report_account_balance_view.xml',
'wizard/account_report_aged_partner_balance_view.xml',
'wizard/account_report_partner_ledger_view.xml',
'wizard/account_reconcile_view.xml',
'wizard/account_reconcile_partner_process_view.xml',
'wizard/account_automatic_reconcile_view.xml',
'wizard/account_financial_report_view.xml',
@ -132,7 +132,9 @@ module named account_voucher.
'static/src/js/account.js',
],
'qweb' : [
"static/src/xml/*",
"static/src/xml/account.xml",
],
'css':['static/src/css/account.css'
],
'demo_xml': [
'demo/account_demo.xml',

View File

@ -536,7 +536,6 @@ class account_move_line(osv.osv):
'company_id': fields.related('account_id', 'company_id', type='many2one', relation='res.company', string='Company', store=True, readonly=True),
'last_reconciliation_date': fields.related('partner_id', 'last_reconciliation_date', type='datetime', relation='res.partner', string='Latest Reconciliation Date',readonly=True),
'lastest_entry': fields.function(_latest_entry_date, type='date', string="Latest Entry"),
'lastest_entry2': fields.function(_latest_entry_date, type='date', string="Latest Recnciliation"),
'reconciliation_progress': fields.function(_rec_progress, string='Progress (%)', type='float')
}

View File

@ -980,15 +980,15 @@
<field name="type">form</field>
<field eval="2" name="priority"/>
<field name="arch" type="xml">
<form string="Journal Item">
<group col="6" colspan="4">
<field name="partner_id" nolabel="1"/>
<field name="lastest_entry" />
<field name="lastest_entry2" /> <newline/>
<button string="Reconcile" name="%(action_view_account_move_line_reconcile)d" widget="list_button" type="action" />
<button string="Nothing to Reconcile" name="%(action_account_unreconcile)d" widget="list_button" type="action" />
<field name="reconciliation_progress" widget="progressbar" nolabel="1"/>
<form string="Journal Item" layout="manual" version="7.0">
<h3>
<field name="partner_id"/>
</h3>
<group col="6">
<field name = "last_reconciliation_date" col="3"/>
<field name = "lastest_entry" col="3"/>
<button string="Reconcile" name="%(action_view_account_move_line_reconcile)d" widget="list_button" type="action" />
<button string="Nothing to Reconcile" name="%(action_account_unreconcile)d" widget="list_button" type="action"/>
</group>
</form>
</field>

View File

@ -60,7 +60,8 @@ instance.account.extend_viewmanager = instance.web.ViewManagerAction.extend({
})
},
setup_exended_list_view: function(parent){
var from_view,
var self = this,
from_view,
obj_from_view;
view_id = this.action.extended_form_view_id[0]
from_view = this.registry.get_object('form_clone');
@ -70,8 +71,10 @@ instance.account.extend_viewmanager = instance.web.ViewManagerAction.extend({
obj_from_view = new from_view(self, this.dataset_form, view_id, options={});
obj_from_view.template = 'ExtendedFormView'
view_promise = obj_from_view.appendTo(this.$element.find('.oe_extended_form_view'))
$.when(view_promise && this.dataset_loaded).then(function() {
obj_from_view.on_pager_action('first')
$.when(view_promise, this.dataset_loaded).then(function() {
if (!_.isEmpty(self.dataset_form.ids)) {
obj_from_view.on_pager_action('first')
}
})
}