Siebel CSSBCActivity.SetGridBeginEndDate 或如何获取 eScript 中重复操作的所有实例?

发布于 2024-09-25 06:02:49 字数 1458 浏览 2 评论 0原文

我想通过 eScript bcAction 查询获取重复操作的所有实例。

我已经发现了关于重复动作的内容:

  • 我创建了一个重复动作,重复 间隔 = 每天
  • 我可以在 Siebel 日历小程序中看到此操作的多个实例。
  • 如果我通过 eScript 查询所有操作,我会得到重复操作的单行,这是所有重复实例的“模板”。
  • 如果我通过 Siebel 日历修改特定操作实例,则会为该实例创建一个新行。
  • 如果再次查询所有操作,我会得到 2 个与重复操作相关的操作。 “模板”和修改后的实例。
  • 当我在 Siebel 日历中打开一个未更改的重复操作实例并打开菜单“帮助 -> 关于记录...”时,我发现该实例的行 ID 有点特殊,就像临时 rowid:8SIA-81UT810 /10/2010

到目前为止,一切顺利。现在我想获取 eScript 中重复操作的所有实例,无论它们是否已更改。就像在 Siebel 日历小程序中一样。

在Bookshelf中我发现了一个很有前途的方法:

CSSBCActivity.SetGridBeginEndDate(startDate, endDate)

它将业务组件设置为日历模式。我希望通过这样做,对于给定时间范围内的所有重复操作实例,将创建临时操作行,然后我可以对其进行查询。

var args = new Array(2);
args[0] = "10/01/2010";
args[1] = "10/31/2010";
bcActivity.InvokeMethod("SetGridBeginEndDate", args);
...
bcACtivity.ExecuteQuery(ForwardOnly);

但是,执行查询失败,并出现异常“00/00/0000 无法转换为时间戳”。 我跟踪查询并发现以下内容:

SELECT ... FROM SIEBEL.S_EVT_ACT T1 ...
WHERE 
      ((T1.APPT_REPT_FLG = 'Y' AND (T1.APPT_REPT_END_DT IS NULL OR T1.APPT_REPT_END_DT >= '00/00/0000') AND T1.TODO_PLAN_START_DT < '01/02/,)/.' OR T1.TODO_PLAN_START_DT >= '00/00/0000' AND T1.TODO_PLAN_START_DT < '01/02/,)/.' AND T1.APPT_REPT_FLG = 'N' OR T1.TODO_PLAN_START_DT < '00/00/0000' AND T1.TODO_PLAN_END_DT >= '00/00/0000' AND T1.APPT_REPT_FLG = 'N') AND

这里的某些日期文字显然有问题。 所以我敢打赌我做错了什么。 知道如何正确做吗?谢谢!

I would like to get all instances of a repeating action via a eScript bcAction query.

What I already found out about repeating actions:

  • I create an repeating action, repeat
    interval = daily
  • I can see multiple instances for this action in Siebel calendar applet.
  • If I query all actions by eScript, I get a single row for the repeating action, kind of the "template" of all repeating instances
  • If I modify a specific action instance via Siebel calendar, a new row is created for that instance.
  • If query all actions again, I get 2 actions which relate to the repeating action. The "template" and the modified instance.
  • When I open an unchanged repeating action instance in Siebel calendar and open Menu "Help -> About Record...", I see that the row id of the instance is somehow special, like a temporary rowid: 8SIA-81UT810/10/2010

So far, so good. Now I want to get all instances of the repeating action in eScript, whether they have been changed or not. Just like in the Siebel calender applet.

In Bookshelf I found a promising method:

CSSBCActivity.SetGridBeginEndDate(startDate, endDate)

It should set the business component into calendar mode. My hope is that by doing this, for all repeating action instances of the given time frame temporary action rows will be created, which I can query then.

var args = new Array(2);
args[0] = "10/01/2010";
args[1] = "10/31/2010";
bcActivity.InvokeMethod("SetGridBeginEndDate", args);
...
bcACtivity.ExecuteQuery(ForwardOnly);

However, executing the query fails with an exception "00/00/0000 cannot be converted to a timestamp".
I traced the query and found the following:

SELECT ... FROM SIEBEL.S_EVT_ACT T1 ...
WHERE 
      ((T1.APPT_REPT_FLG = 'Y' AND (T1.APPT_REPT_END_DT IS NULL OR T1.APPT_REPT_END_DT >= '00/00/0000') AND T1.TODO_PLAN_START_DT < '01/02/,)/.' OR T1.TODO_PLAN_START_DT >= '00/00/0000' AND T1.TODO_PLAN_START_DT < '01/02/,)/.' AND T1.APPT_REPT_FLG = 'N' OR T1.TODO_PLAN_START_DT < '00/00/0000' AND T1.TODO_PLAN_END_DT >= '00/00/0000' AND T1.APPT_REPT_FLG = 'N') AND

There is obviously something wrong with some date literals here.
So I bet I am doing something wrong.
Any idea how to do it right? Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

挥剑断情 2024-10-02 06:02:49

我发现了错误。 InvokeMethod 的参数必须按如下方式传递:

bcActivity.InvokeMethod("SetGridBeginEndDate", "10/01/2010", "10/31/2010");

获取重复操作的临时实例按预期方式工作。凉爽的!

I found the error. The parameters of InvokeMethod must be passed like this:

bcActivity.InvokeMethod("SetGridBeginEndDate", "10/01/2010", "10/31/2010");

Getting the temporary instances of the repeating action works this way as expected. Cool!

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文