NetTalk Central

Author Topic: Edit page select another record - why?  (Read 3613 times)

kashiash

  • Newbie
  • *
  • Posts: 48
    • View Profile
    • Email
Edit page select another record - why?
« on: March 23, 2011, 03:02:32 AM »
I have table with insurance policy. When user enter on the form, there are RENEW button and i add new record to the same table. next user press Save button.
In Url on Save i wrote : 'FormKalkulacjeTAB?&WSK:IDWNIOSKU='& p_web.GetSessionValue('WznawianyWniosek')& '&Change_btn=Change&',
value in WznawianyWniosek is correct and contains new record ID.
URL on save looks like below
http://.../FormKalkulacjeTAB?&WSK:IDWNIOSKU=20110323103663277850xxx1xxx1xxx11000&Change_btn=Change&

but when FormKalkulacjeTAB is opened i getanother record in this form - with other ID then 20110323103663277850xxx1xxx1xxx11000
on this procedure there are no extra embed code  - just pure NTWS Edit Procedure

whats wrong ?

charl99

  • Full Member
  • ***
  • Posts: 185
    • View Profile
    • Email
Re: Edit page select another record - why?
« Reply #1 on: April 04, 2011, 06:39:19 AM »
I have no idea what you are trying to explain here, but I know what the RENEW button is suposed to do.

If my no idea has a probable answer, put the RENEW button on the Browse (Use the NT 'Copy' Button for this), ie it will automatically create the new record as a match of the old one which can then be changed, and then when you press save it will save the new record.

Anyway, I gave it a go.

Cheers
Charl

kashiash

  • Newbie
  • *
  • Posts: 48
    • View Profile
    • Email
Re: Edit page select another record - why?
« Reply #2 on: April 05, 2011, 03:52:59 PM »
Thank you for this advice. This have a sense ;) but
i need to check if user can copy this record!
where put code to check and how to redirect to other page  if check false ?

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11247
    • View Profile
Re: Edit page select another record - why?
« Reply #3 on: April 05, 2011, 11:40:21 PM »
Hi Jacek,

Out the copy button "in the row" of the record. There is a template setting for "condition" so you can make the button appear on some rows but not on others.

Also, you wouldn't re-direct the copy if they weren't allowed to do it. Rather you would change the behaviour of the form if they tried to do a copy without copy rights. (ie hide some fields, display a warning field and so on.)

cheers
Bruce