• Sign in
  • Try it free
    • Apps
      Finance
      • Accounting
      • Invoicing
      • Expenses
      • Spreadsheet (BI)
      • Documents
      • Sign
      Sales
      • CRM
      • Sales
      • Point of Sale
      • Subscriptions
      • Rental
      • Amazon Connector
      Websites
      • Website
      • eCommerce
      • Blogs
      • Forums
      • Live Chat
      • eLearning
      Inventory & MRP
      • Inventory
      • Manufacturing
      • PLM
      • Purchase
      • Maintenance
      • Quality
      Human Resources
      • Employees
      • Recruitment
      • Time Off
      • Appraisals
      • Referrals
      • Fleet
      Marketing
      • Social Marketing
      • Email Marketing
      • SMS Marketing
      • Events
      • Marketing Automation
      • Surveys
      Services
      • Project
      • Timesheet
      • Field Service
      • Helpdesk
      • Planning
      • Appointments
      Productivity
      • Discuss
      • Approvals
      • IoT
      Third party apps Odoo Studio Odoo Cloud Platform
    • Community
      Learn
      • eLearning
      • Documentation
      • Certifications
      • Education Program
      • Scale Up! Business Game
      • Customer References
      Get the Software
      • Download
      • Compare Editions
      • Releases
      Collaborate
      • Github
      • Forum
      • Events
      • Translations
      • Become a Partner
      Get Services
      • Find a Partner
      • Find an Accountant
      • Get a Tailored Demo
    • Pricing

    Help

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

    • CRM
    • e-Commerce
    • Accounting
    • Inventory
    • PoS
    • Project management
    • MRP
    Take the tour
    • All Forums
    • Topics
    • People
    • Tags
    • Badges
    • About
      Go to:
    • Question
      All Topics People Tags Badges About
    0

    how to raise duplication error on odoo with link to exited record form view?

    Avatar
    Mohamed Fouad
    8 July 2020
    Thanks for your subscription!
    wizardraiseduplicationodoo12

    i know that a lot of ways to stop duplication in odoo, but I need the warning of duplication to appear with the existed record to go directly to it, this is the methods

    @api.multi
    
    @api.onchange('name', 'categ')
    def check_id(self):
    all = self.env['muk_dms.directory']
    for record in self:
    rec = all.search([('name','=', record.name)])
    if rec:
    # what should I write here to display the wizard with link or any way to go to rec directly
    else:
    pass

    any help will be appreciated

    Comment Share
    Avatar
    Discard
    1 Answer
    0
    Avatar
    Sahil
    6 November 2020
    Best Answer

    May be you can achieve this by creating your own wizard, then catch the error in your code and return the wizard action showing the link using url widget 

    Comment Share
    Avatar
    Discard
    Community
    • eLearning
    • Documentation
    • Forum
    • Mailing Lists
    Open Source
    • Download
    • Github
    • Runbot
    • Translations
    Services
    • Odoo.sh Hosting
    • Support
    • Upgrade
    • Education
    • Find an Accountant
    • Find a Partner
    • Become a Partner
    About us
    • Our company
    • Contact us
    • Jobs
    • Events
    • Blog
    • Customers
    • Partners
    • Legal
    • Privacy
    • Security
    الْعَرَبيّة 简体中文 繁體中文 Nederlands English Français Deutsch Bahasa Indonesia Italiano 日本語 한국어 (KR) Português (BR) русский язык Slovenský jazyk Español ภาษาไทย Türkçe українська Tiếng Việt

    Odoo is a suite of open source business apps that cover all your company needs: CRM, eCommerce, accounting, inventory, point of sale, project management, etc.

    Odoo's unique value proposition is to be at the same time very easy to use and fully integrated.

    Website made with

    Partner Webinar on YouTube

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

    Watch now