跳至內容
選單
此問題已被標幟
3 回覆
10533 瀏覽次數


/data/sequence.xml

<?xml version='1.0' encoding='utf-8'?>
<odoo>
    <data noupdate="1">
        <record id="seq_hospital_patient" model="ir.sequence">
            <field name="name">Patient Reference</field>
            <field name="code">hospital.patient.sequence</field>
            <field name="prefix">PN</field>
            <field name="padding">3</field>
            <field name="company_id" eval="False"/>
        </record>
    </data>
    <data noupdate="1">    
        <record id="seq_hospital_appointment" model="ir.sequence">
            <field name="name">Appointment ID</field>
            <field name="code">hospital.appointment.sequence</field>
            <field name="prefix"> PA </field>
            <field name="padding">3</field>
            <field name="company_id" eval="False"/>
        </record>

    </data>
</odoo>


Sequence has been created and Active





頭像
捨棄
最佳答案

Hi,

Everything seems to be correct , make sure that there is no extra space get entered in the code of the sequence, just copy paste the code of the sequence from the user interface and add it your code and see.

As rest of the sequence are working correctly this also has to work.

You can see a use case here, which seems you have added in the question: How to Add New Sequence in odoo


Thanks

頭像
捨棄
作者

Thanks it worked

最佳答案

If you have multiple companies, switching the company can be a solution

頭像
捨棄
作者 最佳答案

Yes there was a space in the Sequence Prefix


頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
3
10月 23
8814
1
9月 23
3329
3
9月 23
3560
1
5月 23
2274
2
4月 23
2828