2016-05-02 11 views
0

私はDjango 1.9.2を使って正常にローカルに行ったyahoo financesのためのデータ視覚化を作成しようとしています。それはヤフーの資金を奪い、ツールチップを使ってバブルチャートを作成するためにD3を使います。 しかし、バブルは表示されません。 https://pure-woodland-72284.herokuapp.com/ これはHerokuのログに表示されます。 Heroku Log Error MessagesHeroku(Django App)でD3をデプロイする方法は?

DEBUG = True

ALLOWED_HOSTS = []

INSTALLED_APPS = ( 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'rest_framework', 'rest_framework_swagger', 'mysite' ) TEMPLATES = [ { 'BACKEND': 'django.template.backends.django.DjangoTemplates',

'DIRS': [ 
     # insert your TEMPLATE_DIRS here 
      os.path.join(os.path.dirname(__file__), 'templates'), 

    ], 
    'APP_DIRS': True, 
    'OPTIONS': { 
     'context_processors': [ 
      # Insert your TEMPLATE_CONTEXT_PROCESSORS here or use this 
      # list if you haven't customized them: 
      'django.contrib.auth.context_processors.auth', 
      'django.template.context_processors.debug', 
      'django.template.context_processors.i18n', 
      'django.template.context_processors.media', 
      'django.template.context_processors.static', 
      'django.template.context_processors.tz', 
      'django.contrib.messages.context_processors.messages', 
     ], 
    }, 
}, 

]

REST_FRAMEWORK={ 'DEFAULT_PERMISSION_CLASSES': [ 'rest_framework.permissions.DjangoModelPermissionsOrAnonReadOnly' ] }

MIDDLEWARE_CLASSES = (
'django.contrib.sessions.middleware.SessionMiddleware', 
'django.middleware.common.CommonMiddleware', 
'django.middleware.csrf.CsrfViewMiddleware', 
'django.contrib.auth.middleware.AuthenticationMiddleware', 
'django.contrib.auth.middleware.SessionAuthenticationMiddleware', 
'django.contrib.messages.middleware.MessageMiddleware', 
'django.middleware.clickjacking.XFrameOptionsMiddleware', 
'django.middleware.security.SecurityMiddleware', 

答えて

0

あなたのコンソールに以下のエラーを持っている:あなたは本当にだから私はあなたが輸入していることを推測している、あなたのライブラリ

を輸入していなかったので、

Mixed Content: The page at 'https://pure-woodland-72284.herokuapp.com/' was loaded over HTTPS, but requested an insecure stylesheet 'http://fonts.googleapis.com/css?family=Lobster+Two:400,700italic'. This request has been blocked; the content must be served over HTTPS. 

は、したがって、あなたは'Uncaught ReferenceError: $ is not defined'エラーを取得していますあなたのスクリプト(jquery、d3.tip、cssfonts)をcdnから読み込み、インポート中にhttpを使いました。 httpsでそれらをインポートし、問題が解決するかどうか確認してください。

関連する問題