on 11-03-2015 2:10 PM
Hi,
i am creating one table taken three button images(edit,save,delete) ,
At a time one row should be editable ,When edit is clicked ,Other rows edit delete should be disabled .
And
When you click edit, delete button should be replaced with cancel button.
On click of cancel button the changes made should not be saved.
It could be more helpful if you share your code, so that we can give our ideas to you.
I’m writing to let you know that Dennis Seah and Sai Vellanki already shared there ideas with you about the same issue but little bit different scenario.
for ref: http://scn.sap.com/thread/3820663
Try from your end and share your code in JS Bin or Plunker as like how "Sai Vellanki" shows to you. .
Thanks,
KA
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
From my point of view I point out few ideas here.
1. Use model to set/get enable option. Like( give a property called enable in your JSON model. Make it as false at the time of initialization)
for eg:
var aData = [
{ID: 1, Name: "Al", Age: 32, Salary: 100000,enabled:false},
{ID: 2, Name: "Andy", Age: 28, Salary: 75000,enabled:false},
{ID: 3, Name: "Anita", Age:25, Salary: 45000,enabled:false},
{ID: 4, Name: "Doris", Age: 24, Salary: 35000,enabled:false},
{ID: 5, Name: "Doris", Age: 22, Salary: 15000,enabled:false}
];
2. If you want to change your data, you should get the binded context of selected item from the table and change enable mode from false to true. By default table has associated with two way binding. So when you change your data in model. Automatically your desire actions will take place.
3. Give one more button in horizontal content. Named that button as "cancel". Follow up the same idea and execute your output on screen
Best wishes!!!
Do not hesitate to contact us again if you require any further information.
Thanks,
KA
i am trying on buttons, but how to performing using images(button images)
my code is
Applause, Nice try!!!
This is my kind request to you, Don't check with Button text.
Because It will change based on the region. ( This concepts are coming under i18n);
As I opened your code, few things you need to concentrate.
1. Check with Button Id, not to button text
2. Do the same, use setIcon() to change the icon from edit to cancel
Thanks,
KA
thank you for valuable suggestion finally i got it
Can you explain an issue you are facing with? and also would be nice if you share your code with us.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
i am trying below code, but i don't know how to solving the above issue
User | Count |
---|---|
81 | |
24 | |
11 | |
9 | |
7 | |
5 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.