NetSuite子列表/子记录在编辑模式下不更新/刷新 [英] NetSuite Sublist/child record does not update/refresh in edit mode

查看:85
本文介绍了NetSuite子列表/子记录在编辑模式下不更新/刷新的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如果我使用的表单处于编辑模式,并且我通过我的脚本将项目添加到子列表(子级自定义记录)中,则无法获得客户可见的列表以进行刷新/更新.

If the form I am on is in edit mode, and I add items to the sublist (A child custom record) via my suitescript I can not get the list that is visible to the customer to refresh/update.

我尝试使用以下命令,但随后发现它仅适用于静态/只读列表.

I have attempted to use the following command, but then found that it only works on a static / read only list.

// Refresh the package contents list
nlapiRefreshLineItems('recmachcustrecord_myCustomRecord');

当父交易记录表单处于编辑模式时,是否有一种方法可以强制子列表/子记录更新其视图?

Is there a way to force a sublist/child record to update its view when the parent transaction form is in edit mode?

在我的表单上,我单击了做某事"按钮,该按钮用于创建子记录.创建记录后,事务处理表单不会更新子列表.当我退出编辑模式时,表单将实现新行并显示它们.

On my form I have clicked my "Do Something" button which is to create child records. After the records are created the transaction form does not update the sublist. When I exit edit mode the form then realizes the new lines and displays them.

谢谢

推荐答案

记录中可能还有其他尚未保存的字段.

You may have other fields on the record that are not saved yet.

要执行所需的操作,您必须保存记录并使用脚本重新打开.

In order to do what you want you'd have to save the record and reopen it with your script.

以下是Netsuite帮助中保存并重新打开记录的示例:

Here is an example from Netsuite help of saving and reopening a record:

try
{
//committing the phone call record to the database
  var callId = nlapiSubmitRecord(call, true);
  nlapiLogExecution('DEBUG', 'call record created successfully', 'ID = ' + callId);

  //Redirect the user to the newly created phone call
  nlapiSetRedirectURL('RECORD', 'phonecall', callId, false, null); 
}
catch (e)
{
  nlapiLogExecution('ERROR', e.getCode(), e.getDetails());
}

这篇关于NetSuite子列表/子记录在编辑模式下不更新/刷新的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆