Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Openerp 7 How i can show in _view.xml field about another addon?

By
mirko lazzarini
on 8/24/13, 12:10 PM 627 views

I've this little custom addon

class Project_Document(osv.osv):

'''Project Document'''
_name = 'project.qms.document'

_columns = {
    'name': fields.char('Name',size=250),
    'notes': fields.text('Note'),
    'type_id': fields.many2one('project.qms.document.type',string='Type'),
    'filname': fields.char('File Name',size=250),
    'file': fields.binary('File'),
}

Project_Document()

class Project_Document_Type(osv.osv):

'''Project Document_Type'''
_name = 'project.qms.document.type'

_columns = {
    'name': fields.char('Name',size=250),
    'description': fields.text('Description'),
    'qms_code': fields.char('QMS Code',size=250),
    'file': fields.binary('File'),
}

Project_Document_Type()

How can i view 'project.qms.document' in another custom addon like this?

<openerp> <data>

<record model="ir.ui.view" id="edit_project">

        <field name="name">project.project.form</field>
        <field name="model">project.project</field>
     <field name="type">form</field>
        <field name="inherit_id" ref="project.edit_project"/>
        <field name="arch" type="xml">
    <field name='user_id' position='after'>
               <field name="type_id" />
               <field name="sales_order_id" />
    </field>
    <notebook>
        <page string="QMS">
            <group col="2" colspan="2">
                    <field name="legacy_project_code"/>
                        <field name="redmine_project" />
            </group>
        </page>
        <page string="Purchases">
            <group col="2" colspan="2">
            </group>
        </page>
        <page string="QMS Documents">

"here i must put project.qms.document"

        </page>
    </notebook>
        </field>
   </record>

</data>

</openerp>

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 8/24/13, 12:10 PM
Seen: 627 times
Last updated: 3/16/15, 8:10 AM