Přejít na obsah
Odoo Menu
  • Přihlásit se
  • Vyzkoušejte zdarma
  • Aplikace
    Finance
    • Účetnictví
    • Fakturace
    • Výdaje
    • Spreadsheet (BI)
    • Dokumenty
    • Podpisy
    Prodej
    • CRM
    • Prodej
    • POS Obchod
    • POS Restaurace
    • Předplatné
    • Pronájem
    Webové stránky
    • Webové stránky
    • E-shop
    • Blog
    • Fórum
    • Živý chat
    • eLearning
    Dodavatelský řetězec
    • Sklad
    • Výroba
    • PLM
    • Nákup
    • Údržba
    • Kvalita
    Lidské zdroje
    • Zaměstnanci
    • Nábor
    • Volno
    • Hodnocení zaměstnanců
    • Doporučení
    • Vozový park
    Marketing
    • Marketing sociálních sítí
    • Emailový marketing
    • SMS Marketing
    • Události
    • Marketingová automatizace
    • Dotazníky
    Služby
    • Projekt
    • Časové výkazy
    • Práce v terénu
    • Helpdesk
    • Plánování
    • Schůzky
    Produktivita
    • Diskuze
    • Schvalování
    • IoT
    • VoIP
    • Znalosti
    • WhatsApp
    Aplikace třetích stran Odoo Studio Odoo cloudová platforma
  • Branže
    Maloobchod
    • Knihkupectví
    • Obchod s oblečením
    • Obchod s nábytkem
    • Potraviny
    • Obchod s hardwarem
    • Hračkářství
    Jídlo a pohostinství
    • Bar a Pub
    • Restaurace
    • Fast Food
    • Penzion
    • Distributor nápojů
    • Hotel
    Nemovitost
    • Realitní kancelář
    • Architektonická firma
    • Stavba
    • Správa nemovitostí
    • Zahradnictví
    • Asociace vlastníků nemovitosti
    Poradenství
    • Účetní firma
    • Odoo Partner
    • Marketingová agentura
    • Právník
    • Akvizice talentů
    • Audit a certifikace
    Výroba
    • Textil
    • Kov
    • Nábytek
    • Jídlo
    • Pivovar
    • Korporátní dárky
    Zdraví a fitness
    • Sportovní klub
    • Prodejna brýli
    • Fitness Centrum
    • Wellness praktikové
    • Lékárna
    • Kadeřnictví
    Transakce
    • Údržbář
    • Podpora IT & hardware
    • Systémy solární energie
    • Výrobce obuvi
    • Úklidové služby
    • Služby HVAC
    Ostatní
    • Nezisková organizace
    • Agentura pro životní prostředí
    • Pronájem billboardů
    • Fotografování
    • Leasing jízdních kol
    • Prodejce softwaru
    Procházet všechna odvětví
  • Komunita
    Edukační program
    • Tutoriály
    • Dokumentace
    • Certifikace
    • Vzdělávání
    • Blog
    • Podcast
    Podpora vzdělávání
    • Vzdělávací program
    • Scale Up! Hra na firmu
    • Navštivte Odoo
    Získat software
    • Stáhnout
    • Porovnejte edice
    • Verze
    Spolupráce
    • Github
    • Fórum
    • Události
    • Překlady
    • Stát se partnerem
    • Služby pro partnery
    • Registrujte svou účetní firmu
    Získat služby
    • Najít partnera
    • Najít účetní
    • Setkejte se s poradcem
    • Implementační služby
    • Zákaznické reference
    • Podpora
    • Upgrady
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Dohodnout demo
  • Ceník
  • Pomoc

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

  • CRM
  • e-Commerce
  • Účetnictví
  • Sklad
  • PoS
  • Projekty
  • MRP
All apps
You need to be registered to interact with the community.
All Posts Lidé Odznaky
Štítky (View all)
studio Studio17 Studio customize fields
O tomto fóru
You need to be registered to interact with the community.
All Posts Lidé Odznaky
Štítky (View all)
studio Studio17 Studio customize fields
O tomto fóru
  1. Studio
  2. Fórum

date in number of the day of the year

Odebírat

Get notified when there's activity on this post

This question has been flagged
studio
3 Odpovědi
1454 Zobrazení
Avatar
Comunicazione

Hi, I use  Odoo Online ( and I need to create a field that transforms the date into the number of the day of the year:
ex. 1 = 1/25/2022 = 25
ex. 2 = 05/14/2022 = 134
ex. 3 = 08/12/2022 = 224
I don't have much experience so please be as simple as possible.

Thank you

0
Avatar
Zrušit
Avatar
Cybrosys Techno Solutions Pvt.Ltd
Nejlepší odpověď

Hi,

In Odoo Online you can make use of the Odoo Studio app to do this. To do that please follow the below steps:-

1) Go to settings and turn on the developer mode by clicking the "Activate the developer mode" button under the Developer Tools
2) Now go to the view in which you need to add the field.
3) Now switch to studio mode by clicking on the "Toggle Studio" button found in the top right corner.
4) Now add and name one date field and an integer field using the studio. (You can refer to Odoo Studio Book for help: https://www.cybrosys.com/odoo/odoo-books/odoo-15-studio/build-an-app/creating-models-and-adding-fields/)
5) Now we need to add compute method for the integer field for that you can refer to Odoo Studio Book: https://www.cybrosys.com/odoo/odoo-books/odoo-15-studio/build-an-app/define-compute-method/
6) In "Dependencies" you need to add the technical name of the date field which you will get from studio view or just by placing the name over the date field(which will be similar to "x_studio_input_date").
7) Now in the "Compute" field you need to enter the following code "for rec in self:
rec['x_studio_date_of_the_year'] = rec.x_studio_input_date.strftime('%j')"
8) Now you can save it and close the studio view.

Now the integer field will show the day of the year when the value in the input date field is changed

Regards

0
Avatar
Zrušit
Avatar
Peter Park
Nejlepší odpověď

Sure! You can create a custom field in Odoo which performs the desired transformation. All you need to do is define the formula and let Odoo calculate the field for each entry automatically. It's simple, fast, and requires no prior experience!

1
Avatar
Zrušit
Avatar
Comunicazione
Autor Nejlepší odpověď

Thank you very much, I will trThank you very much, I will try 👍🏼

0
Avatar
Zrušit
Comunicazione
Autor

Hello @Cybrosys Techno Solutions Pvt.Ltd
I had found another solution, but now I need your hand to make yours work.
I tried but it doesn't work for me. The procedure I have adopted is the following:
- created the Date field (x_studio_date_of_the_year)
- created the Day field (x_studio_input_data) and inserted the following formula:
Dependencies : x_studio_date_of_the_year
Calculation : for record in self: record['x_studio_date_of_the_year'] = record.x_studio_input_data.strftime('%j')
It does not work!
But surely I made a mistake in some steps

Could you kindly give me a hand?

Thanks 1000

Enjoying the discussion? Don't just read, join in!

Create an account today to enjoy exclusive features and engage with our awesome community!

Přihlásit se
Related Posts Odpovědi Zobrazení Aktivita
Odoo Studio not Show me all Option
studio
Avatar
Avatar
1
zář 24
3662
Studio application failed to load
studio
Avatar
Avatar
2
čvc 24
4234
Studio not available in Community edition
studio
Avatar
Avatar
1
dub 24
7920
How to add an Activity summary in list view for a new app
studio
Avatar
0
led 24
3122
Specific decimal precision in packaging products
studio
Avatar
0
srp 25
3050
Komunita
  • Tutoriály
  • Dokumentace
  • Fórum
Open Source
  • Stáhnout
  • Github
  • Runbot
  • Překlady
Služby
  • Odoo.sh hostování
  • Podpora
  • Upgrade
  • Nestandardní vývoj
  • Edukační program
  • Najít účetní
  • Najít partnera
  • Stát se partnerem
O nás
  • Naše společnost
  • Podklady značky
  • Kontakujte nás
  • Práce
  • Události
  • Podcast
  • Blog
  • Zákazníci
  • Právní dokumenty • Soukromí
  • Zabezpečení
الْعَرَبيّة 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 je balíček open-source aplikací, které pokrývají všechny potřeby vaší společnosti: CRM, e-shop, účetnictví, sklady, kasy, projektové řízení a další.

Unikátní nabídka od Odoo poskytuje velmi jednoduché uživatelské rozhraní a vše je integrované na jednom místě.

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