[fix] [minor] [website]
This commit is contained in:
parent
43e2bc84a8
commit
3966c4cc5b
@ -14,10 +14,6 @@
|
|||||||
<label>Full Name</label>
|
<label>Full Name</label>
|
||||||
<input class="form-control" type="text" id="fullname" placeholder="Your Name">
|
<input class="form-control" type="text" id="fullname" placeholder="Your Name">
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<fieldset>
|
|
||||||
<label>Password</label>
|
|
||||||
<input class="form-control" type="password" id="password" placeholder="Password">
|
|
||||||
</fieldset>
|
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<label>Company Name</label>
|
<label>Company Name</label>
|
||||||
<input class="form-control" type="text" id="company_name" placeholder="Company Name" value="{{ company_name }}">
|
<input class="form-control" type="text" id="company_name" placeholder="Company Name" value="{{ company_name }}">
|
||||||
@ -42,7 +38,6 @@ $(document).ready(function() {
|
|||||||
type: "POST",
|
type: "POST",
|
||||||
args: {
|
args: {
|
||||||
fullname: $("#fullname").val(),
|
fullname: $("#fullname").val(),
|
||||||
password: $("#password").val(),
|
|
||||||
company_name: $("#company_name").val(),
|
company_name: $("#company_name").val(),
|
||||||
mobile_no: $("#mobile_no").val(),
|
mobile_no: $("#mobile_no").val(),
|
||||||
phone: $("#phone").val()
|
phone: $("#phone").val()
|
||||||
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
from __future__ import unicode_literals
|
from __future__ import unicode_literals
|
||||||
import webnotes
|
import webnotes
|
||||||
|
from webnotes import _
|
||||||
from webnotes.utils import cstr
|
from webnotes.utils import cstr
|
||||||
|
|
||||||
no_cache = True
|
no_cache = True
|
||||||
@ -28,5 +29,11 @@ def update_profile(fullname, password=None, company_name=None, mobile_no=None, p
|
|||||||
from selling.utils.cart import update_party
|
from selling.utils.cart import update_party
|
||||||
update_party(fullname, company_name, mobile_no, phone)
|
update_party(fullname, company_name, mobile_no, phone)
|
||||||
|
|
||||||
from core.doctype.profile import profile
|
if not fullname:
|
||||||
return profile.update_profile(fullname, password)
|
return _("Name is required")
|
||||||
|
|
||||||
|
webnotes.conn.set_value("Profile", webnotes.session.user, "first_name", fullname)
|
||||||
|
webnotes.add_cookies["full_name"] = fullname
|
||||||
|
|
||||||
|
return _("Updated")
|
||||||
|
|
@ -2,9 +2,11 @@
|
|||||||
|
|
||||||
{% block javascript -%}
|
{% block javascript -%}
|
||||||
<script>
|
<script>
|
||||||
|
$(document).ready(function() {
|
||||||
global_number_format = "{{ global_number_format }}";
|
global_number_format = "{{ global_number_format }}";
|
||||||
currency = "{{ currency }}";
|
currency = "{{ currency }}";
|
||||||
wn.currency_symbols = {{ currency_symbols }};
|
wn.currency_symbols = {{ currency_symbols }};
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
{{ super() }}
|
{{ super() }}
|
||||||
|
@ -24,8 +24,12 @@ $(document).ready(function() {
|
|||||||
// update login
|
// update login
|
||||||
erpnext.cart.set_cart_count();
|
erpnext.cart.set_cart_count();
|
||||||
|
|
||||||
$("#user-tools a").tooltip({"placement":"bottom"});
|
// update profile
|
||||||
$("#user-tools-post-login a").tooltip({"placement":"bottom"});
|
if(full_name) {
|
||||||
|
$('.navbar li[data-label="Profile"] a')
|
||||||
|
.html('<i class="icon-fixed-width icon-user"></i> ' + full_name);
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
// shopping cart
|
// shopping cart
|
||||||
|
@ -12,7 +12,6 @@
|
|||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<ul class="breadcrumb">
|
<ul class="breadcrumb">
|
||||||
<li><a href="index">Home</a></li>
|
<li><a href="index">Home</a></li>
|
||||||
<li><a href="account">My Account</a></li>
|
|
||||||
<li><a href="tickets">My Tickets</a></li>
|
<li><a href="tickets">My Tickets</a></li>
|
||||||
<li class="active"><i class="icon-ticket icon-fixed-width"></i> {{ doc.name }}</li>
|
<li class="active"><i class="icon-ticket icon-fixed-width"></i> {{ doc.name }}</li>
|
||||||
</ul>
|
</ul>
|
||||||
@ -34,8 +33,8 @@
|
|||||||
<div class="col-md-8">
|
<div class="col-md-8">
|
||||||
<div class="row col-md-12">{{ doc.subject }}</div>
|
<div class="row col-md-12">{{ doc.subject }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-2 pull-right">
|
<div class="col-md-2">
|
||||||
<span class="text-muted">{{ utils.formatdate(doc.creation) }}</span>
|
<span class="text-muted pull-right">{{ utils.formatdate(doc.creation) }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user