Giter Club home page Giter Club logo

ng2-listview-crud's People

Contributors

mohdrashid avatar

Watchers

 avatar  avatar  avatar

ng2-listview-crud's Issues

Two Lists in same page

list 1

As you can see in attached screenshot I have created two lists. There are few issues I have identified

  1. search is not case insensitive. Neither I can disable search.
  2. I cannot select two different Items from different different list. For Eg: I cant select "Kapil" from List 1 and "Mistry" from List 2. the mouse selection disappears if from "Kapil" if I select "Mistry" (am I missing something?)
  3. these are two different list. see code below

` <div class="row" *ngIf="marketDataSource;" >


<listitem #l1 [listView]="listMarket" [dataSource]="marketDataSource">


<listitem #l2 [listView]="listResidualMarketGroup" [dataSource]="marketGroupDataSource" >

                </div>`

where listMarket and ListResidualMarketGroup are List view properties defined as below
`this.listMarket = {
add: false,
remove: false,
edit: false,
dataIsObject: true,
//path: ["description"],
path: ["name"],
label: "Made For Markets",
headingBackgroundColor: "#3752ff",
headingFontColor: "white",
icon: "fa fa-cogs",
onDelete: function (value) {
return true;
},
onUpdate: function (value, newValue) {
return true;
},
onSearch: function (value) {

    },
    onAdd: function (value) {           
        return true;
    },
    onSelect: function (value) {            
        console.log(JSON.stringify(value));
    },
    onSearchChange: function (value) {      
        console.log("kapil")
    }
};

 this.listResidualMarketGroup = {
    add: false,
    remove: false,
    edit: false,
    dataIsObject: true,
    //path: (this.localvariables.ApplicationCode == "P" ? ["description"] : ["r2mGroupDescription"]),
    path:["last"],
    label: "Residual Market Groups",
    headingBackgroundColor: "#3752ff",
    headingFontColor: "white",
    icon: "fa fa-cogs",
    onDelete: function (value) {
        return true;
    },
    onUpdate: function (value, newValue) {
        return true;
    },
    onSearch: function (value) {
       
    },
    onAdd: function (value) {
        return true;
    },
    onSelect: function (value) {
        console.log(JSON.stringify(value));
    },
    onSearchChange: function (value) {
        console.log("kapil")
    }
};`

where is defined as
.html page
<ng2-listview-crud [properties]="listView" [data]="dataSource"></ng2-listview-crud>

.ts page
`import { Component, Input, EventEmitter, Output, IterableDiffers } from '@angular/core';
import { CommonModule } from '@angular/common';
import { GroupDescriptor, process, State } from '@progress/kendo-data-query';
import { ItemData } from '../common/base.component';
import { Ng2ListViewCRUD, Ng2ListViewCRUDProperty } from 'ng2-listview-crud';
import { ListViewModule } from 'ng2-list-view';

@component({
selector: 'listitem',
template: require('./listItem.component.html'),

})
export class ListItemComponent {

@Input()
public listView: Ng2ListViewCRUDProperty;

@Input()
public dataSource: Array<Object>;

}`

issue is.. if I select first item in List 1 ... the onselect event gets fired for both of the list...

see screenshot [list2
list2
]

here in console both the records (from list1 and list2) are fired.

Am I implementing this incorrectly ??

Thanks for help..

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.