|
@@ -107,17 +107,23 @@ function init_components_dashboard(input){
|
|
|
id : id,
|
|
|
menu : menu
|
|
|
},function(response){
|
|
|
- $('#widget-types li').click(function(){
|
|
|
- $('#widget-types li').removeClass('active');
|
|
|
- $(this).addClass('active');
|
|
|
- $.action({
|
|
|
- action : data.onSelectModel,
|
|
|
- id : id,
|
|
|
- model : $(this).attr('data-model')
|
|
|
- },function(response){
|
|
|
-
|
|
|
- });
|
|
|
- });
|
|
|
+
|
|
|
+ switch(menu){
|
|
|
+ case 'type':
|
|
|
+
|
|
|
+ $('#widget-types li').click(function(){
|
|
|
+ $('#widget-types li').removeClass('active');
|
|
|
+ $(this).addClass('active');
|
|
|
+ $.action({
|
|
|
+ action : data.onSelectModel,
|
|
|
+ id : id,
|
|
|
+ model : $(this).attr('data-model')
|
|
|
+ },function(response){
|
|
|
+
|
|
|
+ });
|
|
|
+ });
|
|
|
+ break;
|
|
|
+ }
|
|
|
});
|
|
|
}
|
|
|
|