weixin_33739541 2014-06-17 09:56 采纳率: 0%
浏览 48

用redmine路由错误

I'm working with Redmine 2.4.5 and I've installed the better_gantt_chart plugin to not change the original Gantt. I'm making a js file to improve the plugin with drag and drop etc...
Here is my problem : when I'm trying to call a url with ajax to use a controller that I've created it's impossible, and I suppose that's because the better_gantt_char plugin is using patches and hooks but I don't really know.

Here is one of the codes I've tried:

routes.rb

put 'projects/wine-investment-network/issues/gantt', :to => 'better_gantt_charts#update_data'

match 'projects/wine-investment-network/issues/gantt'=> 'better_gantt_charts#update_data', via: :put

drag_drop.js

$.ajax({
      type: 'PUT',
      url: project_name + "/issues/gantt",    
      success: function() { /* ... */ },
      error: function() { /* ... */ }
    });

better_gantt_charts_controller

class BetterGanttChartsController < ApplicationController

unloadable

def update_data
...
end

And here is the error

Started PUT "/projects/wine-investment-network/issues/gantt" for 192.168.21.66 at 2014-06-17 12:02:00 +0200

ActionController::RoutingError (uninitialized constant BetterGanttChartsController):
  • 写回答

0条回答 默认 最新

    报告相同问题?

    悬赏问题

    • ¥100 set_link_state
    • ¥15 虚幻5 UE美术毛发渲染
    • ¥15 CVRP 图论 物流运输优化
    • ¥15 Tableau online 嵌入ppt失败
    • ¥100 支付宝网页转账系统不识别账号
    • ¥15 基于单片机的靶位控制系统
    • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)
    • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
    • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
    • ¥15 手机接入宽带网线,如何释放宽带全部速度