added patch
This commit is contained in:
parent
4ef3a28450
commit
d9cfee58a1
18
patches/january_2013/update_number_format.py
Normal file
18
patches/january_2013/update_number_format.py
Normal file
@ -0,0 +1,18 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import webnotes
|
||||
|
||||
def execute():
|
||||
from webnotes.country_info import get_all
|
||||
data = get_all()
|
||||
|
||||
webnotes.reload_doc("setup", "doctype", "currency")
|
||||
|
||||
for c in data:
|
||||
info = webnotes._dict(data[c])
|
||||
if webnotes.conn.exists("Currency", info.currency):
|
||||
doc = webnotes.doc("Currency", info.currency)
|
||||
doc.fields.update({
|
||||
"number_format": info.number_format,
|
||||
})
|
||||
doc.save()
|
Loading…
x
Reference in New Issue
Block a user