Skip to Content
เมนู
คุณต้องลงทะเบียนเพื่อโต้ตอบกับคอมมูนิตี้
คำถามนี้ถูกตั้งค่าสถานะ
2397 มุมมอง

I want to track last updated changes in a html field and highlight the changes with different color.

Below is what I have tried:


content = fields.Html()

<record id="view_form" model="ir.ui.view">
        <field name="name">Formfield>
        <field name="model">module.modulefield>
        <field name="arch" type="xml">
            <form class="o_form">
                <script>
                    $(document).ready(function () {
                    $('.content-track').keyup(function () {
                    $(this).css({backgroundColor: "#333", color: "#FFF"});
                    });
                    });
                script>   
                <sheet>
                    <separator/>
                    <label for="content"/>
                    <field name="content" class="content-track"/>
                    <separator/>       
                sheet>  
            form>
        field>
    record>

But don't how to achieve it for last updated changes or if I can change the color of text whenever I type new content by default? And also I have issue in above code that whenever I refresh the page changes get removed.

Do anyone have any idea how to achieve this  and how to resolve the issue or any other idea to solve this?


อวตาร
ละทิ้ง
Related Posts ตอบกลับ มุมมอง กิจกรรม
0
ก.ค. 23
2531
1
เม.ย. 25
1474
Odoo App แก้ไขแล้ว
1
พ.ย. 23
2053
0
พ.ค. 24
1783
0
ก.ย. 23
2703