私は作業者とその作業を計画しましたが、今は予定を簡単に変更して改善する必要があります。タスクを移動して継続時間を変更するためにドラッグアンドドロップを行うことが可能かどうかを知りたいですか?SAPUI5:PlanningCalendarの予定の拡張と移動
私はそれがそうだと思いますが、私がインターネット上で見つけたものはすべて、mvcアプリケーションに適合しません。プランニングは単一のビューになっているので、ビューのコントローラーでのみ自分の仕事をしたいと思います。
EDIT:私のコントローラで、私はこのコードをした:
onInit : function(){
var oView = this.getView();
//load jquery libraries for drag n drop
jQuery.sap.require("sap.ui.thirdparty.jqueryui.jquery-ui-core");
jQuery.sap.require("sap.ui.thirdparty.jqueryui.jquery-ui-widget");
jQuery.sap.require("sap.ui.thirdparty.jqueryui.jquery-ui-mouse");
jQuery.sap.require("sap.ui.thirdparty.jqueryui.jquery-ui-draggable");
jQuery.sap.require("sap.ui.thirdparty.jqueryui.jquery-ui-droppable");
//make the appointments drag n droppables
var oAppointment = oView.byId("draggable");
var idAppointment = oAppointment.getId();
oAppointment.onAfterRendering = function(){
$("#"+idAppointment).draggable({
cancel:false
})
};
}
draggable
idはこのように私のCalendarAppointmentsに設定されています:1つだけで、別のプロジェクトで
<appointments>
<unified:CalendarAppointment
id="draggable"
startDate="{CustomModel>EarlSchedStartdate}"
endDate="{CustomModel>EarlSchedFindate}"
title="{CustomModel>Description}">
</unified:CalendarAppointment>
</appointments>
ボタン、それは動作しますが、それは私の計画の任命のためではありません。
'jquery-ui-draggable/droppable'を使用するには、' draggable() 'と' droppable() 'イベントハンドラを'CalendarAppointment'や' PlanningCalendar'オブジェクトのいずれかを呼び出すことができます。 – Qualiture
コンパイラはドラッグ可能な関数を認識しませんが、同じ場所で使用することはできません。私のonInit()関数では、 'jQuery.sap.require'で正しい名前空間を得ました。私はこれをしました: 'oView.byId(" draggable ")。draggable();'; 'Uncaught TypeError:oView.byId(...)。draggableは関数ではありません。 ' – Nicaps
説明が不明確な場合は、私の投稿を編集しました。 – Nicaps