Bỏ qua để đến Nội dung
Odoo Menu
  • Đăng nhập
  • Dùng thử miễn phí
  • Ứng dụng
    Tài chính
    • Kế toán
    • Hóa đơn
    • Chi phí
    • Bảng tính (BI)
    • Tài liệu
    • Ký tên
    Bán hàng
    • CRM
    • Bán hàng
    • POS Cửa hàng
    • POS Nhà hàng
    • Đăng ký
    • Cho thuê
    Trang web
    • Trình tạo trang web
    • Thương mại điện tử
    • Blog
    • Diễn đàn
    • Trò chuyện trực tiếp
    • Học trực tuyến
    Chuỗi cung ứng
    • Tồn kho
    • Sản xuất
    • PLM
    • Mua hàng
    • Bảo dưỡng
    • Chất lượng
    Nhân sự
    • Nhân viên
    • Tuyển dụng
    • Ngày nghỉ
    • Đánh giá
    • Giới thiệu
    • Đội xe
    Marketing
    • Marketing trên MXH
    • Marketing qua email
    • Marketing qua SMS
    • Sự kiện
    • Tự động hóa Marketing
    • Khảo sát
    Dịch vụ
    • Dự án
    • Bảng chấm công
    • Dịch vụ hiện trường
    • Hỗ trợ
    • Kế hoạch
    • Lịch hẹn
    Năng suất
    • Thảo luận
    • Phê duyệt
    • IoT
    • VoIP
    • Kiến thức
    • WhatsApp
    Ứng dụng của bên thứ ba Studio Odoo Nền tảng Đám mây Odoo
  • Ngành
    Bán lẻ
    • Nhà sách
    • Cửa hàng quần áo
    • Cửa hàng nội thất
    • Cửa hàng tạp hóa
    • Cửa hàng đồ kim khí
    • Cửa hàng đồ chơi
    Ẩm thực & Dịch vụ lưu trú
    • Bar và quán rượu
    • Nhà hàng
    • Đồ ăn nhanh
    • Guest house
    • Nhà phân phối đồ uống
    • Khách sạn
    Bất động sản
    • Công ty môi giới bất động sản
    • Công ty kiến trúc
    • Xây dựng
    • Quản lý bất động sản
    • Làm vườn
    • Hiệp hội chủ sở hữu bất động sản
    Tư vấn
    • Công ty kế toán
    • Đối tác Odoo
    • Công ty marketing
    • Công ty luật
    • Tuyển dụng
    • Thanh tra & chứng nhận
    Sản xuất
    • Dệt may
    • Kim loại
    • Nội thất
    • Ẩm thực
    • Nhà máy bia
    • Quà tặng doanh nghiệp
    Sức khoẻ & fitness
    • CLB thể thao
    • Cửa hàng kính mắt
    • Trung tâm fitness
    • Chuyên gia chăm sóc sức khỏe
    • Hiệu thuốc
    • Tiệm làm tóc
    Thương mại
    • Dịch vụ sửa chữa
    • Phần cứng CNTT & Hỗ trợ
    • Hệ thống năng lượng mặt trời
    • Công ty sản xuất giày
    • Dịch vụ vệ sinh
    • Dịch vụ HVAC
    Khác
    • Tổ chức phi lợi nhuận
    • Cơ quan môi trường
    • Cho thuê biển quảng cáo
    • Nhiếp ảnh
    • Cho thuê xe đạp
    • Đại lý phần mềm
    Xem tất cả ngành
  • Cộng đồng
    Học tập
    • Khóa học
    • Tài liệu
    • Chứng chỉ
    • Đào tạo
    • Blog
    • Podcast
    Thúc đẩy đào tạo
    • Chương trình đào tạo
    • Trò chơi kinh doanh Scale Up!
    • Tham quan Odoo
    Nhận phần mềm
    • Tải xuống
    • So sánh các phiên bản
    • Phiên bản
    Hợp tác
    • Github
    • Diễn đàn
    • Sự kiện
    • Dịch thuật
    • Trở thành đối tác
    • Dịch vụ dành cho Đối tác
    • Đăng ký công ty kế toán của bạn
    Nhận dịch vụ
    • Tìm đối tác
    • Tìm kế toán
    • Gặp chuyên gia hỗ trợ
    • Dịch vụ Triển khai
    • Khách hàng tham khảo
    • Hỗ trợ
    • Nâng cấp
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Nhận một buổi demo
  • Bảng giá
  • Trợ giúp

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Kế toán
  • Tồn kho
  • PoS
  • Dự án
  • MRP
All apps
Bạn cần phải đăng ký để tương tác với cộng đồng.
Tất cả bài viết Người Huy hiệu
Thẻ (Xem tất cả)
odoo accounting v14 pos v15
Về diễn đàn này
Bạn cần phải đăng ký để tương tác với cộng đồng.
Tất cả bài viết Người Huy hiệu
Thẻ (Xem tất cả)
odoo accounting v14 pos v15
Về diễn đàn này
Hỗ trợ

Pivot view does not display in odoo 8

Đăng ký nhận tin

Nhận thông báo khi có hoạt động trên bài viết này

Câu hỏi này đã bị gắn cờ
python2.7odoo8
1 Trả lời
6305 Lượt xem
Ảnh đại diện
Dhouha

I have created a custom module in odoo 8 that allows me to add a sub_menu "convention" which I want to display a pivot view to display the numbers of the convention used as a table. My problem is how to display a pivot view because I found a problem to display a pivot view with version 8 of odoo. I tried this module with version 9 of odoo and it works well but with version 8 even the icon of the pivot view is not displayed. Any idea for help please?
here is a link to an image to explain my problem https://ibb.co/io0uZJ

Convention.xml 

<?xml version="1.0" encoding="UTF-8"?>

<openerp>
<data>
  <record id="convention_table_tree_view" model="ir.ui.view">
    <field name="name">Convention Table Tree View</field>
    <field name="model">hr.convention</field>
    <field name="arch" type="xml">
        <tree>
            <field name="Degree"/>
            <field name="Categorie_11"/>
            <field name="Categorie_12"/>
            <field name="Categorie_13"/>
            <field name="Categorie_21"/>
            <field name="Categorie_22"/>
            <field name="Categorie_23"/>
            <field name="Categorie_31"/>
            <field name="Categorie_32"/>
            <field name="Categorie_33"/>
            <field name="Categorie_41"/>
            <field name="Categorie_42"/>
            <field name="Categorie_43"/>
        </tree>
    </field>
</record>
<!-- salary_table graph view -->
<record id="convention_table_graph_view" model="ir.ui.view">
    <field name="name">Convention Table Graph View</field>
    <field name="model">hr.convention</field>
    <field name="arch" type="xml">
        <graph>              
            <field name="Degree" type="row"/>
        </graph>
    </field>
</record>
<!-- salary_table Pivot view -->
<record id="convention_table_pivot_view" model="ir.ui.view">
    <field name="name">Salary Table Pivot View</field>
    <field name="model">hr.convention</field>
    <field name="arch" type="xml">
        <graph string="pivot" type="pivot">
            <field name="Categorie_11" type="measure"/>
            <field name="Categorie_12" type="measure"/>
            <field name="Categorie_13" type="measure"/>
            <field name="Categorie_21" type="measure"/>
            <field name="Categorie_22" type="measure"/>
            <field name="Categorie_23" type="measure"/>
            <field name="Categorie_31" type="measure"/>
            <field name="Categorie_32" type="measure"/>
            <field name="Categorie_33" type="measure"/>
            <field name="Categorie_41" type="measure"/>
            <field name="Categorie_42" type="measure"/>
            <field name="Categorie_43" type="measure"/>
            <field name="Degree" type="row"/>
        </graph>
    </field>
</record>

    <record model="hr.convention" id="five1">
    <field name="Categorie_11" >2.253</field>
    <field name="Categorie_12" >2.418</field>
    <field name="Categorie_13" >2.494</field>
    <field name="Categorie_21" >2.548</field>
    <field name="Categorie_22" >2.784</field>
    <field name="Categorie_23" >2.964</field>
    <field name="Categorie_31" >3.165</field>
    <field name="Categorie_32" >3.321</field>
    <field name="Categorie_33" >3.396</field>
    <field name="Categorie_41" >3.165</field>
    <field name="Categorie_42" >3.321</field>
    <field name="Categorie_43" >3.396</field>
    <field name="Degree" >Degree_1</field>
</record>

<!-- salary_table Action -->
<record model="ir.actions.act_window" id="action_convention">
    <field name="name">Salary Table</field>
    <field name="res_model">hr.convention</field>
    <field name="view_type">form</field>
    <field name="view_mode">tree,form,graph,pivot</field>
</record>


    <!-- convention menu item -->

     <menuitem action="action_convention" id="hr_menu_convention" parent="hr.menu_hr_configuration" name="Convention" sequence="0" groups="base.group_hr_manager"/>


</data>
</openerp> 

hr_convention.py

 from openerp.osv import fields, osv


 class Convention(osv.osv):
_name = 'hr.convention'
_columns = {

 "Degree" : fields.char(string="Degree"),
"Categorie_11"  : fields.float(string="Categorie_11"), 
"Categorie_12"  : fields.float(string="Categorie_12"),
"Categorie_13"  : fields.float(string="Categorie_13"),
"Categorie_21"  : fields.float(string="Categorie_21"),
"Categorie_22"  : fields.float(string="Categorie_22"),
"Categorie_23"  : fields.float(string="Categorie_23") ,
"Categorie_31"  : fields.float(string="Categorie_31"),
"Categorie_32"  : fields.float(string="Categorie_32"),
"Categorie_33"  : fields.float(string="Categorie_33"),
"Categorie_41"  : fields.float(string="Categorie_41"),
"Categorie_42"  : fields.float(string="Categorie_42"),
"Categorie_43"  : fields.float(string="Categorie_43"),

    }
0
Ảnh đại diện
Huỷ bỏ
Ảnh đại diện
Nikhil Krishnan
Câu trả lời hay nhất

Hi  Dhouha,
In odoo 8 It's not Pivot view its gantt view.

<field name="view_mode">kanban,tree,form,calendar,gantt,graph</field>

so please change the code like bellow

<!-- salary_table Action -->
<record model="ir.actions.act_window" id="action_convention">
    <field name="name">Salary Table</field>
    <field name="res_model">hr.convention</field>
    <field name="view_type">form</field>
    <field name="view_mode">tree,form,graph,gantt</field>
</record>


0
Ảnh đại diện
Huỷ bỏ
Dhouha
Tác giả

Thank you but how can i modify the record structure (id="salary_table_pivot_view") to suit the gantt view ?

Nikhil Krishnan

Sorry, I can't get you exactly.!

you just edit the form " id="action_convention" ".

Update the module. then you check the pivot view.

Bạn có hứng thú với cuộc thảo luận không? Đừng chỉ đọc, hãy tham gia nhé!

Tạo tài khoản ngay hôm nay để tận hưởng các tính năng độc đáo và tham gia cộng đồng tuyệt vời của chúng tôi!

Đăng ký
Bài viết liên quan Trả lời Lượt xem Hoạt động
Odoo 8: how to prevent wizard from closing after a new one is opened?
wizard python2.7 odoo8
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
2
thg 11 17
7052
Error occurred during the installation of loan management(V6.1) module in V7.0
python2.7
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
3
thg 10 23
6859
How to write a python function called automatically?
python2.7
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
2
thg 1 23
6305
Selecting items for one2many relation Đã xử lý
odoo8
Ảnh đại diện
Ảnh đại diện
Ảnh đại diện
2
thg 12 22
15778
How to upload files automatically on attachments on button click ?
odoo8
Ảnh đại diện
Ảnh đại diện
1
thg 11 21
5869
Cộng đồng
  • Khóa học
  • Tài liệu
  • Diễn đàn
Open source
  • Tải xuống
  • Github
  • Runbot
  • Dịch thuật
Dịch vụ
  • Lưu trữ Odoo.sh
  • Hỗ trợ
  • Nâng cấp
  • Phát triển tùy chỉnh
  • Đào tạo
  • Tìm kế toán
  • Tìm đối tác
  • Trở thành đối tác
Giới thiệu công ty
  • Công ty của chúng tôi
  • Tài sản thương hiệu
  • Liên hệ
  • Việc làm
  • Sự kiện
  • Podcast
  • Blog
  • Khách hàng
  • Pháp lý • Riêng tư
  • Bảo mật
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo là bộ ứng dụng kinh doanh có open source đáp ứng tất cả các nhu cầu của công ty bạn: CRM, thương mại điện tử, kế toán, tồn kho, POS, quản lý dự án, v.v.

Định hướng giá trị riêng biệt của Odoo là tích hợp hoàn toàn và dễ dàng sử dụng.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now