fixed old style file names
This commit is contained in:
parent
761a044cd7
commit
8425c87d5f
@ -12,7 +12,6 @@ def execute():
|
|||||||
change_file_data_in_tabseries()
|
change_file_data_in_tabseries()
|
||||||
replace_file_list_column_entries()
|
replace_file_list_column_entries()
|
||||||
|
|
||||||
|
|
||||||
def replace_name_in_file_data():
|
def replace_name_in_file_data():
|
||||||
"""
|
"""
|
||||||
Change / to - in tabFile Data name column entries
|
Change / to - in tabFile Data name column entries
|
||||||
|
|||||||
@ -29,4 +29,6 @@ class DocType:
|
|||||||
#
|
#
|
||||||
def set_html_from_image(self):
|
def set_html_from_image(self):
|
||||||
file_name = self.doc.file_list.split(',')[0]
|
file_name = self.doc.file_list.split(',')[0]
|
||||||
self.doc.header_html = '<div><img style="max-height: 120px; max-width: 600px" src="index.cgi?cmd=get_file&fname=' + file_name + '"/></div>'
|
self.doc.header_html = """<div>
|
||||||
|
<img style="max-height: 120px; max-width: 600px" src="files/%s"/>
|
||||||
|
</div>""" % file_name
|
||||||
|
|||||||
@ -12,4 +12,7 @@ class DocType:
|
|||||||
tmp = json.dumps({"item_group": d.item_group, "label":d.label})
|
tmp = json.dumps({"item_group": d.item_group, "label":d.label})
|
||||||
break
|
break
|
||||||
|
|
||||||
webnotes.conn.set_default("default_product_category", tmp)
|
webnotes.conn.set_default("default_product_category", tmp)
|
||||||
|
|
||||||
|
from webnotes.session_cache import clear_cache
|
||||||
|
clear_cache('Guest')
|
||||||
@ -1,7 +1,7 @@
|
|||||||
<div class="layout_wrapper" id="content-products">
|
<div class="layout_wrapper" id="content-products">
|
||||||
<h1 class="products-category"></h1>
|
<h1 class="products-category"></h1>
|
||||||
<div class="web-main-section">
|
<div class="web-main-section">
|
||||||
<div class="products-search">
|
<div class="products-search" style="margin-bottom: 15px;">
|
||||||
<input name="products-search" /><button class="btn" style="margin-left: 7px">Search</button>
|
<input name="products-search" /><button class="btn" style="margin-left: 7px">Search</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@ -65,7 +65,7 @@ erpnext.products.make_product_list = function(wrapper) {
|
|||||||
parent.innerHTML = repl('<div style="float:left; width: 115px;">\
|
parent.innerHTML = repl('<div style="float:left; width: 115px;">\
|
||||||
<img src="files/%(thumbnail_image)s" style="width:100px;"></div>\
|
<img src="files/%(thumbnail_image)s" style="width:100px;"></div>\
|
||||||
<div style="float:left; width: 400px">\
|
<div style="float:left; width: 400px">\
|
||||||
<b><a href="#!%(page_name)s">%(title)s</a></b>\
|
<p><b><a href="#!%(page_name)s">%(title)s</a></b></p>\
|
||||||
<p>%(short_description)s</p></div>\
|
<p>%(short_description)s</p></div>\
|
||||||
<div style="clear: both; margin-bottom: 15px; border-bottom: 1px solid #AAA"></div>', data);
|
<div style="clear: both; margin-bottom: 15px; border-bottom: 1px solid #AAA"></div>', data);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user