[charts] update, without new build system

This commit is contained in:
Prateeksha Singh 2018-05-21 18:04:50 +05:30
parent 1275ea5123
commit b434f2687e
4 changed files with 3 additions and 7 deletions

View File

@ -64,8 +64,7 @@ erpnext.ProductionAnalytics = frappe.views.GridReportWithPlot.extend({
var chart_data = this.get_chart_data ? this.get_chart_data() : null;
this.chart = new Chart({
parent: ".chart",
this.chart = new frappeChart.Chart(".chart", {
data: chart_data,
type: 'line'
});

View File

@ -266,7 +266,6 @@ class Project(Document):
task_doc.append('depends_on', {"task": dt_name})
task_doc.save()
@frappe.whitelist()
def get_timeline_data(doctype, name):
'''Return timeline for attendance'''
return dict(frappe.db.sql('''select unix_timestamp(from_time), count(*)

View File

@ -4,7 +4,6 @@ def get_data():
return {
'heatmap': True,
'heatmap_message': _('This is based on the Time Sheets created against this project'),
'method' : 'erpnext.projects.doctype.project.project.get_timeline_data',
'fieldname': 'project',
'transactions': [
{

View File

@ -146,7 +146,6 @@ frappe.Leaderboard = Class.extend({
me.$graph_area.show().empty();
let args = {
parent: '.leaderboard-graph',
data: {
datasets: [
{
@ -160,7 +159,7 @@ frappe.Leaderboard = Class.extend({
type: 'bar',
height: 140
};
new Chart(args);
new frappeChart.Chart('.leaderboard-graph', args);
notify(me, r, $container);
}