我需要在highcharts条形图的y轴上有一些非常长的多线标签.
我的问题是长的多行标签会导致删除以下标签 - 可能是某种内部重叠故障保护.
我正处于增加标签宽度的位置,以便我可以通过换行来控制自己的自动换行(内部自动换行也会产生与丢失标签相同的问题.)
我希望能够关闭此功能并自己处理重叠.
例:

图表选项:
{
"colors": [
"#00AEEF"
],
"credits": {
"enabled": false
},
"chart": {
"type": "bar"
},
"tooltip": {},
"plotOptions": {
"column": {
"pointPadding": 0.2,
"borderWidth": 0
},
"series": {
"borderWidth": 0,
"dataLabels": {
"enabled": true,
"format": "{point.y:.1f}%"
}
}
},
"series": [
{
"showInLegend": false,
"data": [
[
"this is a pretty long label <br/>that will most likely cause the next<br/> row not to appear",
70
],
[
"this is a pretty long …Run Code Online (Sandbox Code Playgroud) 我在rails 4中使用gem'fullcalendar-rails'来使用jquery fullcalendar,顺便说一下我是rails的新手,我花了很多天试图做这个工作,但我找不到指南从日历到rails中的控制器执行适当的发布,然后将其保存到数据库中.
我试过这个指南,但似乎没有什么工作正常,有谁知道怎么做?
http://www.rkonrails.com/blog/2013/10/full-calendar-rails-jquery-full-calendar-in-rails/
http://blog.crowdint.com/2014/02/18/fancy-calendars-for-your-web-application-with-fullcalendar.html
其实这是我的代码:
事件模型
class Event < ActiveRecord::Base
def self.between(start_time, end_time)
where('starts_at > :lo and starts_at < :up',
:lo => Event.format_date(start_time),
:up => Event.format_date(end_time)
)
end
def self.format_date(date_time)
Time.at(date_time.to_i).to_formatted_s(:db)
end
def as_json(options = {})
{
:id => self.id,
:title => self.title,
:description => self.description || "",
:start => starts_at.rfc822,
:end => ends_at.rfc822,
:allDay => self.all_day,
:recurring => false,
:url => Rails.application.routes.url_helpers.event_path(id)
}
end
end
Run Code Online (Sandbox Code Playgroud)
事件控制器
class EventsController < ApplicationController
def new
@event = Event.new
respond_to do …Run Code Online (Sandbox Code Playgroud)