mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-22 14:39:19 +00:00
[fix] Product Search
This commit is contained in:
@@ -48,3 +48,9 @@
|
|||||||
.product-text {
|
.product-text {
|
||||||
padding: 15px 0px;
|
padding: 15px 0px;
|
||||||
}
|
}
|
||||||
|
@media (max-width: 767px) {
|
||||||
|
.product-search {
|
||||||
|
width: 100%;
|
||||||
|
margin-bottom: 13px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -51,3 +51,10 @@
|
|||||||
.product-text {
|
.product-text {
|
||||||
padding: 15px 0px;
|
padding: 15px 0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@media (max-width: 767px) {
|
||||||
|
.product-search {
|
||||||
|
width: 100%;
|
||||||
|
margin-bottom: 13px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
frappe.ready(function() {
|
frappe.ready(function() {
|
||||||
$(".product-search").remove();
|
$(".product-search").remove();
|
||||||
|
|
||||||
$('<div class="product-search">\
|
$('<div class="product-search pull-right">\
|
||||||
<form class="form-inline form-search">\
|
<form class="form-inline form-search">\
|
||||||
<div class="input-group">\
|
<div class="input-group">\
|
||||||
<input class="form-control" type="text" id="product-search" placeholder="Product Search...">\
|
<input class="form-control" type="text" id="product-search" placeholder="Product Search...">\
|
||||||
@@ -12,13 +12,13 @@ frappe.ready(function() {
|
|||||||
</span>\
|
</span>\
|
||||||
</div>\
|
</div>\
|
||||||
</form>\
|
</form>\
|
||||||
</div>').appendTo(".page-header-right");
|
</div>').prependTo(".page-header-block");
|
||||||
|
|
||||||
$('.dropdown-toggle').dropdown();
|
$('.dropdown-toggle').dropdown();
|
||||||
$("#btn-product-search").click(function() {
|
$("#btn-product-search").click(function() {
|
||||||
var txt = $("#product-search").val();
|
var txt = $("#product-search").val();
|
||||||
if(txt) {
|
if(txt) {
|
||||||
window.location.href="product_search?q=" + txt;
|
window.location.href="/product_search?q=" + txt;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user