Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.
Anonymous_User Absent Member.
Absent Member.

Betr.: Re: E few questions about Rules.

I put the changes.
It will be in GW14R2 SP1.

The VacationRule will be derived from Rule.

<xs:complexType name="VacationRule">
<xs:complexContent>
<xs:extension base="tns:Rule">
<xs:sequence>
<xs:element ref="tns:subject" minOccurs="0"/>
<xs:element name="message" type="tns:MessageBody" minOccurs="0"/>
<xs:element name="replyToExternalUsers" type="xs:boolean"
minOccurs="0"/>
<xs:element name="startDate" type="xs:date" minOccurs="0"/>
<xs:element name="endDate" type="xs:date" minOccurs="0"/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>

To get the Vacation Rule to return in SOAP, you will need to pass "1.08"in
the <version> element of the loginRequest.

You will pretty much just deal with the VactionRule elements and not the
base class Rule elements. The safest way to make changes to the Vacation
Rule is to deleted the old rule and create a new rule. (That is what the
GWClient does under the covers.)

Here is some rudimentary code:

private void testVacationRule()
{
DatatypeFactory fact;
GregorianCalendar cal;
GregorianCalendar end;
CreateItemRequest request = new CreateItemRequest();
CreateItemResponse response;
RemoveItemRequest rreq = new RemoveItemRequest();
ItemChanges changes = new ItemChanges();
MessageBody mb = new MessageBody();
MessagePart mp = new MessagePart();
ModifyItemRequest mreq = new ModifyItemRequest();
VacationRule rule = new VacationRule();

try
{
fact = DatatypeFactory.newInstance();
rule.setEnabled(true);
rule.setSubject("I am on vacation");
mp.setValue("I will contact you when I can".getBytes());
mb.getPart().add(mp);
rule.setMessage(mb);
rule.setReplyToExternalUsers(true);

cal = (GregorianCalendar) GregorianCalendar.getInstance();
cal.set(GregorianCalendar.DAY_OF_MONTH, 15);
cal.set(GregorianCalendar.MONTH, GregorianCalendar.FEBRUARY);
cal.set(GregorianCalendar.HOUR, 0);
cal.set(GregorianCalendar.MINUTE, 0);
cal.set(GregorianCalendar.SECOND, 0);
cal.set(GregorianCalendar.MILLISECOND, 0);
end = (GregorianCalendar) cal.clone();
end.add(GregorianCalendar.WEEK_OF_YEAR, 2);

rule.setStartDate(fact.newXMLGregorianCalendar((GregorianCalendar) cal));
rule.setEndDate(fact.newXMLGregorianCalendar((GregorianCalendar) end));
request.setItem(rule);
response = port.createItemRequest(request);
if ( null == response || 0 != response.getStatus().getCode() )
{
DisplayError err = new DisplayError(response.getStatus(),
"testVacationRule", "mvnClientController::testVacationRule");
err = null;
}

testGetRules();

rule = new VacationRule();
rule.setEnabled(false);
changes.setUpdate(rule);
mreq.setId(response.getId().get(0));
mreq.setUpdates(changes);

port.modifyItemRequest(mreq);

testGetRules();

rule = new VacationRule();
rule.setEnabled(true);
changes.setUpdate(rule);
mreq.setId(response.getId().get(0));
mreq.setUpdates(changes);

port.modifyItemRequest(mreq);

testGetRules();

rreq.setId(response.getId().get(0));
port.removeItemRequest(rreq);

testGetRules();
}
catch (DatatypeConfigurationException e)
{
log.error("testVacationRule", e);
}
}

private void testGetRules()
{
GetRuleListRequest req = new GetRuleListRequest();
port.getRuleListRequest(req);
}

Let me know if you have questions or problems.

Preston

>>>

> I will look into implementing / exposing the vacation rule. In looking at
> what the client has done, there is a lot to do.
> We are starting a different development process that is a little more
> structured. I'll let you know when and what is implemented.
>
> Preston
>
>>>>

>
>> Hello Preston,
>>
>>
>> Sorry have another question.
>>
>> I want to add the "vacation rule" option to my management program for
>> administrators.
>>
>> At the moment there is no function for a vacation rule request (I know I


>
>> can find the rule in the list of rules but the "name" of the rule can be


>
>> changed so it is not save to do so).
>>
>> And another problem is that the "reply to external users" is not
>> exposed.
>>
>>
>> Is it possible to add this, maybe as an extention of the
>> getRuleListRequest?
>>
>> Maybe a view option can be added <view>vacation</view> and an extra

result
>
>> option <replytoexternal/>
>>
>>
>> Thanks,
>>
>> Hans
>>
>>
>>
>>
>>
>>
>>>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 17 November

2015
>
>> 14:24 >>>
>>
>>
>> We currently do not expose "reply to all" in SOAP.
>>
>> I've opened a bug to add the logic.
>>
>>
>>
>> It won't get in the code until after GW 14.2.0 ships.
>>
>>
>>
>> Preston
>>
>>
>>
>>>>>

>>
>>> Hello Preston,

>>
>>>

>>
>>> I'm testing the rules actions with postoffice‑version: 14.2.0 ß

>>
>> ‑121842
>>
>>>

>>
>>> A reply action option in the client has two options:

>>
>>> Reply to sender

>>
>>> Reply to all (only enabled if it is allowed in the clientsettings).

>>
>>>

>>
>>> When I read the actions of rules where I know "reply to all" is set.

>>
>>> I'm not able to determine if the option "reply to all" is set.

>>
>>> As far as I can see there is no attribute for this.

>>
>>>

>>
>>> Have I missed something?

>>
>>>

>>
>>> Hans

>>
>>>

>>
>>>

>>
>>>

>>
>>>

>>
>>>>>>

>>
>>>> I put a change to convert the internal field value to a record id

>>
>>> string.

>>
>>>>

>>
>>>> That will be in a gw14.2.0 build greater than or equal to 120895.

>>
>>>>

>>
>>>> Presenting a UI to convert filters is never easy.

>>
>>>> The GWClient might have had a case where is was easier to start

>>
>>>> the filter in an AND array.

>>
>>>> Having an array of 1 item is acceptable,

>>
>>>> The GroupWise engine handles it just fine.

>>
>>>> You can create a filter without the extra AND array in SOAP.

>>
>>>> Since you can get around the issue, I would not try push the GWClient

>>
>>>> to change their code.

>>
>>>>

>>
>>>> Preston

>>
>>>>

>>
>>>>

>>
>>>>

>>
>>>>>>>

>>
>>>>

>>
>>>>> Hello Preston,

>>
>>>>>

>>
>>>>>

>>
>>>>> Thank you for the information/examples., great idea to create just

>>
>>>>> filters (less work).

>>
>>>>>

>>
>>>>> I try to mimic the rule generation form of the GW‑client so I'm

>>
>> slowly
>>
>>>

>>
>>>>> try all the combinations in rules and I have found a few other

>>
>>>> "problems"

>>
>>>>>

>>
>>>>>

>>
>>>>> (gw14.0.1)

>>
>>>>>

>>
>>>>> The filter information for Categories return the wrong "value" info I


>
>>
>>>>> think. It should probably be the id of the category.

>>
>>>>>

>>
>>>>> I get:

>>
>>>>>

>>
>>>>> <gwt:element type="gwt:FilterEntry">

>>
>>>>> <gwt:op>eq</gwt:op>

>>
>>>>> <gwt:field>category</gwt:field>

>>
>>>>> <gwt:value> ! "b ! !</gwt:value>

>>
>>>>> </gwt:element>

>>
>>>>>

>>
>>>>>

>>
>>>>>

>>
>>>>> Just wondering why.

>>
>>>>>

>>
>>>>>

>>
>>>>>

>>
>>>>> Why is there an extra "and group" around the first elenemt?

>>
>>>>>

>>
>>>>> <filter>

>>
>>>>> <element xsi:type="FilterGroup">

>>
>>>>> <op>or</op>

>>
>>>>>

>>
>>>>>

>>
>>>>> <element xsi:type="FilterGroup"> <‑‑‑‑‑‑‑extra

>>
>>>>> <op>and</op> <‑‑‑‑‑‑‑

>>
>>>>> <element xsi:type="FilterEntry">

>>
>>>>> <op>fieldEqual</op>

>>
>>>>> <field>created</field>

>>
>>>>> <value>2</value>

>>
>>>>> <date>Today</date>

>>
>>>>> </element>

>>
>>>>>

>>
>>>>>

>>
>>>>> </element>

>>
>>>>> <element xsi:type="FilterEntry">

>>
>>>>> <op>gt</op>

>>
>>>>> <field>created</field>

>>
>>>>> <value>2015‑07‑14T21:59:59Z</value>

>>
>>>>> </element>

>>
>>>>> </element>

>>
>>>>> </filter>

>>
>>>>>

>>
>>>>>

>>
>>>>> My code

>>
>>
>>

0 Likes
Booj2 Absent Member.
Absent Member.

Betr.: Re: E few questions about Rules.

Hello Preston,

Finnaly I got the software and time to test it. It Works, thanks.

I only noticed that when the start/end date isn't set, the soap call also not returns the replyToExternalUsers
It is still possible to set/reset the replyToExternalUsers even if you ommit the start/end date.

In the final definition for SP1 there are also startDay and endDay. I have tried this and it seem te work, do you have to set the startdate/endDate or is the start/endDay also sufficient.
start/endDate are in GMT so the start/endDay is much easier.

Hans


>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 23 Februari 2016 19:23 >>>


I put the changes.
It will be in GW14R2 SP1.

The VacationRule will be derived from Rule.

<xs:complexType name="VacationRule">
<xs:complexContent>
<xs:extension base="tns:Rule">
<xs:sequence>
<xs:element ref="tns:subject" minOccurs="0"/>
<xs:element name="message" type="tns:MessageBody" minOccurs="0"/>
<xs:element name="replyToExternalUsers" type="xs:boolean"
minOccurs="0"/>
<xs:element name="startDate" type="xs:date" minOccurs="0"/>
<xs:element name="endDate" type="xs:date" minOccurs="0"/>
</xs:sequence>
</xs:extension>
</xs:complexContent>
</xs:complexType>

To get the Vacation Rule to return in SOAP, you will need to pass "1.08"in
the <version> element of the loginRequest.

You will pretty much just deal with the VactionRule elements and not the
base class Rule elements. The safest way to make changes to the Vacation
Rule is to deleted the old rule and create a new rule. (That is what the
GWClient does under the covers.)

Here is some rudimentary code:

private void testVacationRule()
{
DatatypeFactory fact;
GregorianCalendar cal;
GregorianCalendar end;
CreateItemRequest request = new CreateItemRequest();
CreateItemResponse response;
RemoveItemRequest rreq = new RemoveItemRequest();
ItemChanges changes = new ItemChanges();
MessageBody mb = new MessageBody();
MessagePart mp = new MessagePart();
ModifyItemRequest mreq = new ModifyItemRequest();
VacationRule rule = new VacationRule();

try
{
fact = DatatypeFactory.newInstance();
rule.setEnabled(true);
rule.setSubject("I am on vacation");
mp.setValue("I will contact you when I can".getBytes());
mb.getPart().add(mp);
rule.setMessage(mb);
rule.setReplyToExternalUsers(true);

cal = (GregorianCalendar) GregorianCalendar.getInstance();
cal.set(GregorianCalendar.DAY_OF_MONTH, 15);
cal.set(GregorianCalendar.MONTH, GregorianCalendar.FEBRUARY);
cal.set(GregorianCalendar.HOUR, 0);
cal.set(GregorianCalendar.MINUTE, 0);
cal.set(GregorianCalendar.SECOND, 0);
cal.set(GregorianCalendar.MILLISECOND, 0);
end = (GregorianCalendar) cal.clone();
end.add(GregorianCalendar.WEEK_OF_YEAR, 2);

rule.setStartDate(fact.newXMLGregorianCalendar((GregorianCalendar) cal));
rule.setEndDate(fact.newXMLGregorianCalendar((GregorianCalendar) end));
request.setItem(rule);
response = port.createItemRequest(request);
if ( null == response || 0 != response.getStatus().getCode() )
{
DisplayError err = new DisplayError(response.getStatus(),
"testVacationRule", "mvnClientController::testVacationRule");
err = null;
}

testGetRules();

rule = new VacationRule();
rule.setEnabled(false);
changes.setUpdate(rule);
mreq.setId(response.getId().get(0));
mreq.setUpdates(changes);

port.modifyItemRequest(mreq);

testGetRules();

rule = new VacationRule();
rule.setEnabled(true);
changes.setUpdate(rule);
mreq.setId(response.getId().get(0));
mreq.setUpdates(changes);

port.modifyItemRequest(mreq);

testGetRules();

rreq.setId(response.getId().get(0));
port.removeItemRequest(rreq);

testGetRules();
}
catch (DatatypeConfigurationException e)
{
log.error("testVacationRule", e);
}
}

private void testGetRules()
{
GetRuleListRequest req = new GetRuleListRequest();
port.getRuleListRequest(req);
}

Let me know if you have questions or problems.

Preston


>>>

> I will look into implementing / exposing the vacation rule. In looking at
> what the client has done, there is a lot to do.
> We are starting a different development process that is a little more
> structured. I'll let you know when and what is implemented.
>
> Preston
>

>>>>

>

>> Hello Preston,
>>
>>
>> Sorry have another question.
>>
>> I want to add the "vacation rule" option to my management program for
>> administrators.
>>
>> At the moment there is no function for a vacation rule request (I know I



>

>> can find the rule in the list of rules but the "name" of the rule can be



>

>> changed so it is not save to do so).
>>
>> And another problem is that the "reply to external users" is not
>> exposed.
>>
>>
>> Is it possible to add this, maybe as an extention of the
>> getRuleListRequest?
>>
>> Maybe a view option can be added <view>vacation</view> and an extra

result

>

>> option <replytoexternal/>
>>
>>
>> Thanks,
>>
>> Hans
>>
>>
>>
>>
>>
>>

>>>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 17 November

2015

>

>> 14:24 >>>
>>
>>
>> We currently do not expose "reply to all" in SOAP.
>>
>> I've opened a bug to add the logic.
>>
>>
>>
>> It won't get in the code until after GW 14.2.0 ships.
>>
>>
>>
>> Preston
>>
>>
>>

>>>>>

>>

>>> Hello Preston,

>>

>>>

>>

>>> I'm testing the rules actions with postoffice‑version: 14.2.0 ß

>>
>> ‑121842
>>

>>>

>>

>>> A reply action option in the client has two options:

>>

>>> Reply to sender

>>

>>> Reply to all (only enabled if it is allowed in the clientsettings).

>>

>>>

>>

>>> When I read the actions of rules where I know "reply to all" is set.

>>

>>> I'm not able to determine if the option "reply to all" is set.

>>

>>> As far as I can see there is no attribute for this.

>>

>>>

>>

>>> Have I missed something?

>>

>>>

>>

>>> Hans

>>

>>>

>>

>>>

>>

>>>

>>

>>>

>>

>>>>>>

>>

>>>> I put a change to convert the internal field value to a record id

>>

>>> string.

>>

>>>>

>>

>>>> That will be in a gw14.2.0 build greater than or equal to 120895.

>>

>>>>

>>

>>>> Presenting a UI to convert filters is never easy.

>>

>>>> The GWClient might have had a case where is was easier to start

>>

>>>> the filter in an AND array.

>>

>>>> Having an array of 1 item is acceptable,

>>

>>>> The GroupWise engine handles it just fine.

>>

>>>> You can create a filter without the extra AND array in SOAP.

>>

>>>> Since you can get around the issue, I would not try push the GWClient

>>

>>>> to change their code.

>>

>>>>

>>

>>>> Preston

>>

>>>>

>>

>>>>

>>

>>>>

>>

>>>>>>>

>>

>>>>

>>

>>>>> Hello Preston,

>>

>>>>>

>>

>>>>>

>>

>>>>> Thank you for the information/examples., great idea to create just

>>

>>>>> filters (less work).

>>

>>>>>

>>

>>>>> I try to mimic the rule generation form of the GW‑client so I'm

>>
>> slowly
>>

>>>

>>

>>>>> try all the combinations in rules and I have found a few other

>>

>>>> "problems"

>>

>>>>>

>>

>>>>>

>>

>>>>> (gw14.0.1)

>>

>>>>>

>>

>>>>> The filter information for Categories return the wrong "value" info I



>

>>

>>>>> think. It should probably be the id of the category.

>>

>>>>>

>>

>>>>> I get:

>>

>>>>>

>>

>>>>> <gwt:element type="gwt:FilterEntry">

>>

>>>>> <gwt:op>eq</gwt:op>

>>

>>>>> <gwt:field>category</gwt:field>

>>

>>>>> <gwt:value> ! "b ! !</gwt:value>

>>

>>>>> </gwt:element>

>>

>>>>>

>>

>>>>>

>>

>>>>>

>>

>>>>> Just wondering why.

>>

>>>>>

>>

>>>>>

>>

>>>>>

>>

>>>>> Why is there an extra "and group" around the first elenemt?

>>

>>>>>

>>

>>>>> <filter>

>>

>>>>> <element xsi:type="FilterGroup">

>>

>>>>> <op>or</op>

>>

>>>>>

>>

>>>>>

>>

>>>>> <element xsi:type="FilterGroup"> <‑‑‑‑‑‑‑extra

>>

>>>>> <op>and</op> <‑‑‑‑‑‑‑

>>

>>>>> <element xsi:type="FilterEntry">

>>

>>>>> <op>fieldEqual</op>

>>

>>>>> <field>created</field>

>>

>>>>> <value>2</value>

>>

>>>>> <date>Today</date>

>>

>>>>> </element>

>>

>>>>>

>>

>>>>>

>>

>>>>> </element>

>>

>>>>> <element xsi:type="FilterEntry">

>>

>>>>> <op>gt</op>

>>

>>>>> <field>created</field>

>>

>>>>> <value>2015‑07‑14T21:59:59Z</value>

>>

>>>>> </element>

>>

>>>>> </element>

>>

>>>>> </filter>

>>

>>>>>

>>

>>>>>

>>

>>>>> My code

>>
>>
>>


0 Likes
Anonymous_User Absent Member.
Absent Member.

Betr.: Re: E few questions about Rules.

You need to use startDay and endDay to create the vacation rule.
(If you pass values in startDate and endDate on a create / update, they will
be ignored.)
The startDate and endDate values are returned to help WebAccess function
similarly to the GroupWise Windows Client.

There is very little you can do on an update of a rule.
It is safer to delete the existing rule and create a new rule.
(That is the way to update a rule.)

It makes no sense to create a vacation rule without a start day and end
day.
If you don't have a start day and end day, the rule will be disabled.

(I probably misunderstood your comments about replyToExternalUsers.)

Preston


>>>

> Hello Preston,
>
> Finnaly I got the software and time to test it. It Works, thanks.
>
> I only noticed that when the start/end date isn't set, the soap call
> also not returns the replyToExternalUsers
> It is still possible to set/reset the replyToExternalUsers even if you
> ommit the start/end date.
>
> In the final definition for SP1 there are also startDay and endDay. I
> have tried this and it seem te work, do you have to set the
> startdate/endDate or is the start/endDay also sufficient.
> start/endDate are in GMT so the start/endDay is much easier.
>
> Hans
>
>>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 23 Februari 2016


> 19:23 >>>
>
> I put the changes.
> It will be in GW14R2 SP1.
>
> The VacationRule will be derived from Rule.
>
> <xs:complexType name="VacationRule">
> <xs:complexContent>
> <xs:extension base="tns:Rule">
> <xs:sequence>
> <xs:element ref="tns:subject" minOccurs="0"/>
> <xs:element name="message" type="tns:MessageBody" minOccurs="0"/>


> <xs:element name="replyToExternalUsers" type="xs:boolean"
> minOccurs="0"/>
> <xs:element name="startDate" type="xs:date" minOccurs="0"/>
> <xs:element name="endDate" type="xs:date" minOccurs="0"/>
> </xs:sequence>
> </xs:extension>
> </xs:complexContent>
> </xs:complexType>
>
> To get the Vacation Rule to return in SOAP, you will need to pass
> "1.08"in
> the <version> element of the loginRequest.
>
> You will pretty much just deal with the VactionRule elements and not the
>
> base class Rule elements. The safest way to make changes to the Vacation
>
> Rule is to deleted the old rule and create a new rule. (That is what the
>
> GWClient does under the covers.)
>
> Here is some rudimentary code:
>
> private void testVacationRule()
> {
> DatatypeFactory fact;
> GregorianCalendar cal;
> GregorianCalendar end;
> CreateItemRequest request = new CreateItemRequest();
> CreateItemResponse response;
> RemoveItemRequest rreq = new RemoveItemRequest();
> ItemChanges changes = new ItemChanges();
> MessageBody mb = new MessageBody();
> MessagePart mp = new MessagePart();
> ModifyItemRequest mreq = new ModifyItemRequest();
> VacationRule rule = new VacationRule();
>
> try
> {
> fact = DatatypeFactory.newInstance();
> rule.setEnabled(true);
> rule.setSubject("I am on vacation");
> mp.setValue("I will contact you when I can".getBytes());
> mb.getPart().add(mp);
> rule.setMessage(mb);
> rule.setReplyToExternalUsers(true);
>
> cal = (GregorianCalendar) GregorianCalendar.getInstance();
> cal.set(GregorianCalendar.DAY_OF_MONTH, 15);
> cal.set(GregorianCalendar.MONTH, GregorianCalendar.FEBRUARY);
> cal.set(GregorianCalendar.HOUR, 0);
> cal.set(GregorianCalendar.MINUTE, 0);
> cal.set(GregorianCalendar.SECOND, 0);
> cal.set(GregorianCalendar.MILLISECOND, 0);
> end = (GregorianCalendar) cal.clone();
> end.add(GregorianCalendar.WEEK_OF_YEAR, 2);
>
>
> rule.setStartDate(fact.newXMLGregorianCalendar((GregorianCalendar) cal));


>
> rule.setEndDate(fact.newXMLGregorianCalendar((GregorianCalendar)
> end));
> request.setItem(rule);
> response = port.createItemRequest(request);
> if ( null == response || 0 != response.getStatus().getCode() )
> {
> DisplayError err = new DisplayError(response.getStatus(),
> "testVacationRule", "mvnClientController::testVacationRule");
> err = null;
> }
>
> testGetRules();
>
> rule = new VacationRule();
> rule.setEnabled(false);
> changes.setUpdate(rule);
> mreq.setId(response.getId().get(0));
> mreq.setUpdates(changes);
>
> port.modifyItemRequest(mreq);
>
> testGetRules();
>
> rule = new VacationRule();
> rule.setEnabled(true);
> changes.setUpdate(rule);
> mreq.setId(response.getId().get(0));
> mreq.setUpdates(changes);
>
> port.modifyItemRequest(mreq);
>
> testGetRules();
>
> rreq.setId(response.getId().get(0));
> port.removeItemRequest(rreq);
>
> testGetRules();
> }
> catch (DatatypeConfigurationException e)
> {
> log.error("testVacationRule", e);
> }
> }
>
> private void testGetRules()
> {
> GetRuleListRequest req = new GetRuleListRequest();
> port.getRuleListRequest(req);
> }
>
> Let me know if you have questions or problems.
>
> Preston
>
>>>>

>> I will look into implementing / exposing the vacation rule. In looking

> at
>> what the client has done, there is a lot to do.
>> We are starting a different development process that is a little more
>> structured. I'll let you know when and what is implemented.
>>
>> Preston
>>
>>>>>

>>
>>> Hello Preston,
>>>
>>>
>>> Sorry have another question.
>>>
>>> I want to add the "vacation rule" option to my management program for
>>> administrators.
>>>
>>> At the moment there is no function for a vacation rule request (I know I


>
>
>>
>>> can find the rule in the list of rules but the "name" of the rule can be


>
>
>>
>>> changed so it is not save to do so).
>>>
>>> And another problem is that the "reply to external users" is not
>>> exposed.
>>>
>>>
>>> Is it possible to add this, maybe as an extention of the
>>> getRuleListRequest?
>>>
>>> Maybe a view option can be added <view>vacation</view> and an extra

> result
>>
>>> option <replytoexternal/>
>>>
>>>
>>> Thanks,
>>>
>>> Hans
>>>
>>>
>>>
>>>
>>>
>>>
>>>>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 17 November

> 2015
>>
>>> 14:24 >>>
>>>
>>>
>>> We currently do not expose "reply to all" in SOAP.
>>>
>>> I've opened a bug to add the logic.
>>>
>>>
>>>
>>> It won't get in the code until after GW 14.2.0 ships.
>>>
>>>
>>>
>>> Preston
>>>
>>>
>>>
>>>>>>
>>>
>>>> Hello Preston,
>>>
>>>>
>>>
>>>> I'm testing the rules actions with postoffice‑version: 14.2.0 ß
>>>
>>> ‑121842
>>>
>>>>
>>>
>>>> A reply action option in the client has two options:
>>>
>>>> Reply to sender
>>>
>>>> Reply to all (only enabled if it is allowed in the clientsettings).


>>>
>>>>
>>>
>>>> When I read the actions of rules where I know "reply to all" is set.
>>>
>>>> I'm not able to determine if the option "reply to all" is set.
>>>
>>>> As far as I can see there is no attribute for this.
>>>
>>>>
>>>
>>>> Have I missed something?
>>>
>>>>
>>>
>>>> Hans
>>>
>>>>
>>>
>>>>
>>>
>>>>
>>>
>>>>
>>>
>>>>>>>
>>>
>>>>> I put a change to convert the internal field value to a record id
>>>
>>>> string.
>>>
>>>>>
>>>
>>>>> That will be in a gw14.2.0 build greater than or equal to 120895.
>>>
>>>>>
>>>
>>>>> Presenting a UI to convert filters is never easy.
>>>
>>>>> The GWClient might have had a case where is was easier to start
>>>
>>>>> the filter in an AND array.
>>>
>>>>> Having an array of 1 item is acceptable,
>>>
>>>>> The GroupWise engine handles it just fine.
>>>
>>>>> You can create a filter without the extra AND array in SOAP.
>>>
>>>>> Since you can get around the issue, I would not try push the GWClient


>>>
>>>>> to change their code.
>>>
>>>>>
>>>
>>>>> Preston
>>>
>>>>>
>>>
>>>>>
>>>
>>>>>
>>>
>>>>>>>>
>>>
>>>>>
>>>
>>>>>> Hello Preston,
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> Thank you for the information/examples., great idea to create just


>>>
>>>>>> filters (less work).
>>>
>>>>>>
>>>
>>>>>> I try to mimic the rule generation form of the GW‑client so I'm
>>>
>>> slowly
>>>
>>>>
>>>
>>>>>> try all the combinations in rules and I have found a few other
>>>
>>>>> "problems"
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> (gw14.0.1)
>>>
>>>>>>
>>>
>>>>>> The filter information for Categories return the wrong "value" info I


>
>>
>>>
>>>>>> think. It should probably be the id of the category.
>>>
>>>>>>
>>>
>>>>>> I get:
>>>
>>>>>>
>>>
>>>>>> <gwt:element type="gwt:FilterEntry">
>>>
>>>>>> <gwt:op>eq</gwt:op>
>>>
>>>>>> <gwt:field>category</gwt:field>
>>>
>>>>>> <gwt:value> ! "b ! !</gwt:value>
>>>
>>>>>> </gwt:element>
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> Just wondering why.
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> Why is there an extra "and group" around the first elenemt?
>>>
>>>>>>
>>>
>>>>>> <filter>
>>>
>>>>>> <element xsi:type="FilterGroup">
>>>
>>>>>> <op>or</op>
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> <element xsi:type="FilterGroup"> <‑‑‑‑‑‑‑extra
>>>
>>>>>> <op>and</op> <‑‑‑‑‑‑‑


>>>
>>>>>> <element xsi:type="FilterEntry">
>>>
>>>>>> <op>fieldEqual</op>
>>>
>>>>>> <field>created</field>
>>>
>>>>>> <value>2</value>
>>>
>>>>>> <date>Today</date>
>>>
>>>>>> </element>
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> </element>
>>>
>>>>>> <element xsi:type="FilterEntry">
>>>
>>>>>> <op>gt</op>
>>>
>>>>>> <field>created</field>
>>>
>>>>>> <value>2015‑07‑14T21:59:59Z</value>
>>>
>>>>>> </element>
>>>
>>>>>> </element>
>>>
>>>>>> </filter>
>>>
>>>>>>
>>>
>>>>>>
>>>
>>>>>> My code
>>>
>>>
>>>

>


0 Likes
Highlighted
Booj2 Absent Member.
Absent Member.

Betr.: Re: E few questions about Rules.


Hello Prestion,



Thank you for the clearification about startDay and startDate.



The remark about replyToExternalUsers was just that I saw there is a slight difference between the SOAP results and the client. The client can still set/reset/read this optiion even if the start/end date is not set.

I understand that it is not usefull not to set the start/end date.



Hans




>>> Preston Stephenson<PStephenson@gw.novell.com> Maandag 15 Augustus 2016 13:47 >>>



You need to use startDay and endDay to create the vacation rule.

(If you pass values in startDate and endDate on a create / update, they will

be ignored.)

The startDate and endDate values are returned to help WebAccess function

similarly to the GroupWise Windows Client.




There is very little you can do on an update of a rule.

It is safer to delete the existing rule and create a new rule.

(That is the way to update a rule.)




It makes no sense to create a vacation rule without a start day and end

day.

If you don't have a start day and end day, the rule will be disabled.




(I probably misunderstood your comments about replyToExternalUsers.)




Preston








>>>



> Hello Preston,



>



> Finnaly I got the software and time to test it. It Works, thanks.



>



> I only noticed that when the start/end date isn't set, the soap call



> also not returns the replyToExternalUsers



> It is still possible to set/reset the replyToExternalUsers even if you



> ommit the start/end date.



>



> In the final definition for SP1 there are also startDay and endDay. I



> have tried this and it seem te work, do you have to set the



> startdate/endDate or is the start/endDay also sufficient.



> start/endDate are in GMT so the start/endDay is much easier.



>



> Hans



>



>>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 23 Februari 2016






> 19:23 >>>



>



> I put the changes.



> It will be in GW14R2 SP1.



>



> The VacationRule will be derived from Rule.



>



> <xs:complexType name="VacationRule">



> <xs:complexContent>



> <xs:extension base="tns:Rule">



> <xs:sequence>



> <xs:element ref="tns:subject" minOccurs="0"/>



> <xs:element name="message" type="tns:MessageBody" minOccurs="0"/>






> <xs:element name="replyToExternalUsers" type="xs:boolean"



> minOccurs="0"/>



> <xs:element name="startDate" type="xs:date" minOccurs="0"/>



> <xs:element name="endDate" type="xs:date" minOccurs="0"/>



> </xs:sequence>



> </xs:extension>



> </xs:complexContent>



> </xs:complexType>



>



> To get the Vacation Rule to return in SOAP, you will need to pass



> "1.08"in



> the <version> element of the loginRequest.



>



> You will pretty much just deal with the VactionRule elements and not the



>



> base class Rule elements. The safest way to make changes to the Vacation



>



> Rule is to deleted the old rule and create a new rule. (That is what the



>



> GWClient does under the covers.)



>



> Here is some rudimentary code:



>



> private void testVacationRule()



> {



> DatatypeFactory fact;



> GregorianCalendar cal;



> GregorianCalendar end;



> CreateItemRequest request = new CreateItemRequest();



> CreateItemResponse response;



> RemoveItemRequest rreq = new RemoveItemRequest();



> ItemChanges changes = new ItemChanges();



> MessageBody mb = new MessageBody();



> MessagePart mp = new MessagePart();



> ModifyItemRequest mreq = new ModifyItemRequest();



> VacationRule rule = new VacationRule();



>



> try



> {



> fact = DatatypeFactory.newInstance();



> rule.setEnabled(true);



> rule.setSubject("I am on vacation");



> mp.setValue("I will contact you when I can".getBytes());



> mb.getPart().add(mp);



> rule.setMessage(mb);



> rule.setReplyToExternalUsers(true);



>



> cal = (GregorianCalendar) GregorianCalendar.getInstance();



> cal.set(GregorianCalendar.DAY_OF_MONTH, 15);



> cal.set(GregorianCalendar.MONTH, GregorianCalendar.FEBRUARY);



> cal.set(GregorianCalendar.HOUR, 0);



> cal.set(GregorianCalendar.MINUTE, 0);



> cal.set(GregorianCalendar.SECOND, 0);



> cal.set(GregorianCalendar.MILLISECOND, 0);



> end = (GregorianCalendar) cal.clone();



> end.add(GregorianCalendar.WEEK_OF_YEAR, 2);



>



>



> rule.setStartDate(fact.newXMLGregorianCalendar((GregorianCalendar) cal));






>



> rule.setEndDate(fact.newXMLGregorianCalendar((GregorianCalendar)



> end));



> request.setItem(rule);



> response = port.createItemRequest(request);



> if ( null == response || 0 != response.getStatus().getCode() )



> {



> DisplayError err = new DisplayError(response.getStatus(),



> "testVacationRule", "mvnClientController::testVacationRule");



> err = null;



> }



>



> testGetRules();



>



> rule = new VacationRule();



> rule.setEnabled(false);



> changes.setUpdate(rule);



> mreq.setId(response.getId().get(0));



> mreq.setUpdates(changes);



>



> port.modifyItemRequest(mreq);



>



> testGetRules();



>



> rule = new VacationRule();



> rule.setEnabled(true);



> changes.setUpdate(rule);



> mreq.setId(response.getId().get(0));



> mreq.setUpdates(changes);



>



> port.modifyItemRequest(mreq);



>



> testGetRules();



>



> rreq.setId(response.getId().get(0));



> port.removeItemRequest(rreq);



>



> testGetRules();



> }



> catch (DatatypeConfigurationException e)



> {



> log.error("testVacationRule", e);



> }



> }



>



> private void testGetRules()



> {



> GetRuleListRequest req = new GetRuleListRequest();



> port.getRuleListRequest(req);



> }



>



> Let me know if you have questions or problems.



>



> Preston



>



>>>>



>> I will look into implementing / exposing the vacation rule. In looking



> at



>> what the client has done, there is a lot to do.



>> We are starting a different development process that is a little more



>> structured. I'll let you know when and what is implemented.



>>



>> Preston



>>



>>>>>



>>



>>> Hello Preston,



>>>



>>>



>>> Sorry have another question.



>>>



>>> I want to add the "vacation rule" option to my management program for



>>> administrators.



>>>



>>> At the moment there is no function for a vacation rule request (I know I






>



>



>>



>>> can find the rule in the list of rules but the "name" of the rule can be






>



>



>>



>>> changed so it is not save to do so).



>>>



>>> And another problem is that the "reply to external users" is not



>>> exposed.



>>>



>>>



>>> Is it possible to add this, maybe as an extention of the



>>> getRuleListRequest?



>>>



>>> Maybe a view option can be added <view>vacation</view> and an extra



> result



>>



>>> option <replytoexternal/>



>>>



>>>



>>> Thanks,



>>>



>>> Hans



>>>



>>>



>>>



>>>



>>>



>>>



>>>>>> Preston Stephenson<PStephenson@gw.novell.com> Dinsdag 17 November



> 2015



>>



>>> 14:24 >>>



>>>



>>>



>>> We currently do not expose "reply to all" in SOAP.



>>>



>>> I've opened a bug to add the logic.



>>>



>>>



>>>



>>> It won't get in the code until after GW 14.2.0 ships.



>>>



>>>



>>>



>>> Preston



>>>



>>>



>>>



>>>>>>



>>>



>>>> Hello Preston,



>>>



>>>>



>>>



>>>> I'm testing the rules actions with postoffice‑version: 14.2.0 ß



>>>



>>> ‑121842



>>>



>>>>



>>>



>>>> A reply action option in the client has two options:



>>>



>>>> Reply to sender



>>>



>>>> Reply to all (only enabled if it is allowed in the clientsettings).






>>>



>>>>



>>>



>>>> When I read the actions of rules where I know "reply to all" is set.



>>>



>>>> I'm not able to determine if the option "reply to all" is set.



>>>



>>>> As far as I can see there is no attribute for this.



>>>



>>>>



>>>



>>>> Have I missed something?



>>>



>>>>



>>>



>>>> Hans



>>>



>>>>



>>>



>>>>



>>>



>>>>



>>>



>>>>



>>>



>>>>>>>



>>>



>>>>> I put a change to convert the internal field value to a record id



>>>



>>>> string.



>>>



>>>>>



>>>



>>>>> That will be in a gw14.2.0 build greater than or equal to 120895.



>>>



>>>>>



>>>



>>>>> Presenting a UI to convert filters is never easy.



>>>



>>>>> The GWClient might have had a case where is was easier to start



>>>



>>>>> the filter in an AND array.



>>>



>>>>> Having an array of 1 item is acceptable,



>>>



>>>>> The GroupWise engine handles it just fine.



>>>



>>>>> You can create a filter without the extra AND array in SOAP.



>>>



>>>>> Since you can get around the issue, I would not try push the GWClient






>>>



>>>>> to change their code.



>>>



>>>>>



>>>



>>>>> Preston



>>>



>>>>>



>>>



>>>>>



>>>



>>>>>



>>>



>>>>>>>>



>>>



>>>>>



>>>



>>>>>> Hello Preston,



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> Thank you for the information/examples., great idea to create just






>>>



>>>>>> filters (less work).



>>>



>>>>>>



>>>



>>>>>> I try to mimic the rule generation form of the GW‑client so I'm



>>>



>>> slowly



>>>



>>>>



>>>



>>>>>> try all the combinations in rules and I have found a few other



>>>



>>>>> "problems"



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> (gw14.0.1)



>>>



>>>>>>



>>>



>>>>>> The filter information for Categories return the wrong "value" info I






>



>>



>>>



>>>>>> think. It should probably be the id of the category.



>>>



>>>>>>



>>>



>>>>>> I get:



>>>



>>>>>>



>>>



>>>>>> <gwt:element type="gwt:FilterEntry">



>>>



>>>>>> <gwt:op>eq</gwt:op>



>>>



>>>>>> <gwt:field>category</gwt:field>



>>>



>>>>>> <gwt:value> ! "b ! !</gwt:value>



>>>



>>>>>> </gwt:element>



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> Just wondering why.



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> Why is there an extra "and group" around the first elenemt?



>>>



>>>>>>



>>>



>>>>>> <filter>



>>>



>>>>>> <element xsi:type="FilterGroup">



>>>



>>>>>> <op>or</op>



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> <element xsi:type="FilterGroup"> <‑‑‑‑‑‑‑extra



>>>



>>>>>> <op>and</op> <‑‑‑‑‑‑‑






>>>



>>>>>> <element xsi:type="FilterEntry">



>>>



>>>>>> <op>fieldEqual</op>



>>>



>>>>>> <field>created</field>



>>>



>>>>>> <value>2</value>



>>>



>>>>>> <date>Today</date>



>>>



>>>>>> </element>



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> </element>



>>>



>>>>>> <element xsi:type="FilterEntry">



>>>



>>>>>> <op>gt</op>



>>>



>>>>>> <field>created</field>



>>>



>>>>>> <value>2015‑07‑14T21:59:59Z</value>



>>>



>>>>>> </element>



>>>



>>>>>> </element>



>>>



>>>>>> </filter>



>>>



>>>>>>



>>>



>>>>>>



>>>



>>>>>> My code



>>>



>>>



>>>



>
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.