mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 10:49:09 +00:00
fixes to website, item (added table for cross listing), modules_setup and form_header
This commit is contained in:
@@ -31,28 +31,8 @@ window.render_product_list = function(data) {
|
||||
var table = $("<table class='table'>").appendTo("#search-list");
|
||||
|
||||
$.each(data, function(i, d) {
|
||||
if(!d.web_short_description)
|
||||
d.web_short_description = "No description given."
|
||||
var $tr = $(repl('<tr>\
|
||||
<td style="width: 30%;">\
|
||||
<img class="product-image" \
|
||||
style="width: 80%;" src="files/%(website_image)s">\
|
||||
</td>\
|
||||
<td>\
|
||||
<h4><a href="%(page_name)s">%(item_name)s</a></h4>\
|
||||
<p class="help">Item Code: %(name)s</p>\
|
||||
<p>%(website_description)s</p>\
|
||||
</td>\
|
||||
</tr>', d)).appendTo(table);
|
||||
|
||||
if(!d.website_image) {
|
||||
$tr.find(".product-image").replaceWith("<div\
|
||||
style='background-color: #eee; padding: 40px; \
|
||||
width: 32px; font-size: 32px; color: #888;'>\
|
||||
<i class='icon-camera'></i></div>");
|
||||
}
|
||||
$(d).appendTo(table);
|
||||
});
|
||||
|
||||
}
|
||||
if(data.length < 10) {
|
||||
if(!table) {
|
||||
|
||||
Reference in New Issue
Block a user