Odoo Help


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.


AttributeError: 'NoneType' object has no attribute 'fields_view_get' ///Error occurred while validating the field(s) arch: Inval

Hachem Chraiti
on 4/3/14, 7:56 AM 1,013 views

Hi everyone,im gettin an error :AttributeError: 'NoneType' object has no attribute 'fields_view_get' ///Error occurred while validating the field(s) arch: Invalid XML for View Architecture!')

my code is:

--the xml file : <openerp> <data> <record id="pos_university_form" model="ir.ui.view"> <field name="name">pos.university.form</field> <field name="model">pos.university</field> <field name="arch" type="xml">

<form string="university" version="7.0"> <group col="4"> <field name="university_name"/> <field name="university_pays"/> <field name="pos_university_id"/> </group> </form>

</field> </record>

<record id="pos_university_tree" model="ir.ui.view"> <field name="name">pos.university.tree</field> <field name="model">pos.university</field> <field name="arch" type="xml"> <tree string="Packaging"> <field name="university_name"/> <field name="pos_university_id" ref="pos.university.name"/> </tree> </field> </record>

<record model="ir.ui.view" id="pos_university_search"> <field name="name">pos.university.search</field> <field name="model">pos.university</field> <field name="arch" type="xml"> <search string="university Management"> <field name="university_name"/> <filter name="filter_see_all" string="All" domain="['|', ('active', '=',True), ('active', '=',False)]"/> <filter name="filter_see_active" string="Active" domain="[('active', '=',True)]"/> <filter name="filter_see_inactive" string="Inactive" domain="[('active', '=',False)]"/> </search> </field> </record>

<menuitem name="Faculty Management" id="menu_point_root" sequence="30"/>

<record model="ir.actions.act_window" id="action_pos_university"> <field name="name">universityItem</field> <field name="type">ir.actions.act_window</field> <field name="res_model">pos.university</field> <field name="view_type">form</field> <field name="view_mode">tree,form</field> <field name="view_id" ref="pos_universite_tree"/> <field name="context">{"search_default_filter_see_all":1}</field> <field name="help" type="html">

Click here to create a universities for Hachem. </field> </record>

<menuitem name="Universities Menu" id="menu_point_root_universities" parent="menu_point_root" sequence="17"/> <menuitem id="menu_action_pos_university" parent="menu_point_root_universities" action="action_pos_university"/>

</data> </openerp>

--the py file ::

from openerp.osv import fields, osv

class pos_university(osv.osv): _name = 'pos.university' _columns = { 'pos_university_id' : fields.integer('ID University',size=64), 'university_name': fields.char('Nom de la university', size=128), 'university_pays': fields.char('Lieu de la university', size=128), }

_defaults = { 'university_name' : '', 'university_pays': 'Tunisie', }


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

1 follower(s)


Asked: 4/3/14, 7:56 AM
Seen: 1013 times
Last updated: 3/16/15, 8:10 AM