What is a good Very-High level UI framework for JavaScript?

后端 未结 22 2220
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-07 17:20

I need to write a temporary Web-based graphical front-end for a custom server system. In this case performance and scalability aren\'t issues, since at most 10 people may ch

22条回答
  •  轮回少年
    2020-12-07 17:41

    I used JQuery.UI. This is not necessarily an answer to this question(Especially since it is an old post), but thought I would share what I have, in case it helps anyone else, as I came to this Post searching for how to create a drop and drag UI.

    Please note that this is for MVC.

    Please note that there is no actual Functionality added to this yet, it is a starting point, which creates a UI that allows drop and drag items:

    Layout:

    
    
    
    
    
    jQuery UI Droppable - Default functionality
    
    
    
    
    
    
    
    
    
    @RenderBody()

    © @DateTime.Now.Year - My ASP.NET Application

    }

    Index Page(I replaced the Home Index with this code):

    @{
        ViewBag.Title = "Home Page";
    }
    
    

    To GRANT a user a role, click and drag a role from the left Red box to the right Green box.
    To DENY a user a role, click and drag a role from the right Green box to the left Red box.

    @using (Html.BeginForm("AssignRoles", "UserAdmin", FormMethod.Post, new { id = "formAssignRoles" })) { String[] AllRoles = ViewBag.AllRoles; String[] AllowRoles = ViewBag.AllowRoles; if (AllRoles == null) { AllRoles = new String[] { "Test1","Test2","Test3","Test4", "Test5", "Test6", "Test7", "Test8", "Test9", "Test10", "Test11", "Test12", "Test13" }; } if (AllowRoles == null) { AllowRoles = new String[] { }; } @Html.ValidationSummary(true)
    Drag and Drop Roles as required; @Html.Hidden("Username", "Username") @Html.Hidden("GrantRoles", "")
    Deny Roles Allow Roles
      @foreach (String role in AllRoles) { if (!AllowRoles.Contains(role)) {
    • @role
    • } }
      @foreach (String hasRole in AllowRoles) {
    • @hasRole
    • }
      @foreach (String hasRole in AllowRoles) {
    • @hasRole
    • }

    }

    Hopefully this can help someone else in the right direction.

提交回复
热议问题