Difference between revisions of "BulkMail new"

From Catglobe Wiki
Jump to: navigation, search
(jrfconvert import)
 
 
(9 intermediate revisions by 5 users not shown)
Line 1: Line 1:
[[Category:HelpBooks]]
+
[[Category:Email_and_SMS_Functions]]

+
{{HelpFiles}}
  
====BulkMail_new====
+
==== BulkMail_new ====
  
 
Create new bulk mail object
 
Create new bulk mail object
Line 8: Line 8:
 
'''Syntax'''
 
'''Syntax'''
  
BulkMail_new(bulkMailName, parentResourceId, mailTemplateId)
+
BulkMail_new(bulkMailName, parentResourceId, mailTemplateResourceId)
  
 
or
 
or
  
BulkMail_new( bulkMailName, parentResourceId, mailTemplateId , bulkMailTemplateResourceId)
+
BulkMail_new( bulkMailName, parentResourceId, mailTemplateResourceId , bulkMailTemplateResourceId)
  
 
'''Arguments'''
 
'''Arguments'''
  
* bulkMailName: is string. It is the name of new bulkMail
+
*bulkMailName: is string. It is the name of new bulkMail
* parentResourceId: is number. It is parent resource id of the new bulkMail
+
*parentResourceId: is number. It is parent resource id of the new bulkMail
* mailTemplateId: is number. It is the mail template resource Id gotten from Communicator template
+
*mailTemplateResourceId: is number. It is the mail template resource Id gotten from Communicator template
* bulkMailTemplateResourceId: is number. It is bulkMail template resource Id
+
*bulkMailTemplateResourceId: is number. It is bulkMail template resource Id
  
 
'''Return value'''
 
'''Return value'''
Line 25: Line 25:
 
Array which is BulkMail object:
 
Array which is BulkMail object:
  
{| class="tableintopic" style="border-collapse: collapse" width="1067" cellpadding="2"
+
{| class="tableintopic" style="border-collapse: collapse" cellpadding="2" width="1067"
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" bgcolor="#C0C0C0" |
+
| style="border: 1px solid #010101" bgcolor="#C0C0C0" width="356" |  
 
'''Index'''
 
'''Index'''
| style="border: 1px solid #010101" width="356" bgcolor="#C0C0C0" |
+
 
 +
| style="border: 1px solid #010101" bgcolor="#C0C0C0" width="356" |  
 
'''Data type'''
 
'''Data type'''
| style="border: 1px solid #010101" width="356" bgcolor="#C0C0C0" |
+
 
 +
| style="border: 1px solid #010101" bgcolor="#C0C0C0" width="356" |  
 
'''Value'''
 
'''Value'''
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_RESOURCE_ID
 
BULKMAIL_RESOURCE_ID
| width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
number
 
number
| width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
0
 
0
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_NAME
 
BULKMAIL_NAME
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
number
 
number
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Entered value
 
Entered value
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_PARENT_RESOURCE_ID
 
BULKMAIL_PARENT_RESOURCE_ID
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
string
 
string
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Entered value
 
Entered value
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_TEMPLATE_RESOURCE_ID
 
BULKMAIL_TEMPLATE_RESOURCE_ID
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
number
 
number
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
if it is not specified explicitly in the constructor as a parameter, then get default bulk mail template
 
if it is not specified explicitly in the constructor as a parameter, then get default bulk mail template
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_MAIL_TEMPLATE_RESOURCE_ID
 
BULKMAIL_MAIL_TEMPLATE_RESOURCE_ID
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
number
 
number
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Entered value
 
Entered value
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_EMAIL_ACCOUNT
 
BULKMAIL_EMAIL_ACCOUNT
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
string
 
string
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
It will be the default private email inside the parent resource or the first global email in case there is no a default private email. If there is no any private and global email then it's ""
 
It will be the default private email inside the parent resource or the first global email in case there is no a default private email. If there is no any private and global email then it's ""
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_USER_RESOURCE_IDS
 
BULKMAIL_USER_RESOURCE_IDS
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
array
 
array
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
{}
 
{}
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_GROUP_RESOURCE_IDS
 
BULKMAIL_GROUP_RESOURCE_IDS
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
array
 
array
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
{}
 
{}
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_GROUP_TO_BE_REBUILD_RESOURCE_IDS
 
BULKMAIL_GROUP_TO_BE_REBUILD_RESOURCE_IDS
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
array
 
array
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
{}
 
{}
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_PRIORITY
 
BULKMAIL_PRIORITY
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
number
 
number
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Normal
 
Normal
  
 
There must be constants defined for 3 levels of priority:
 
There must be constants defined for 3 levels of priority:
  
Bulkmail_Priority_Low
+
0: Bulkmail_Priority_Normal
 +
 
 +
1: Bulkmail_Priority_Low
  
Bulkmail_Priority_Normal
+
2: Bulkmail_Priority_High
  
Bulkmail_Priority_High
 
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_NO_IN_OUT_QUEUE
 
BULKMAIL_NO_IN_OUT_QUEUE
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Number (read only)
 
Number (read only)
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Default is 0
 
Default is 0
 +
 
|- align="left" valign="top"
 
|- align="left" valign="top"
| style="border: 1px solid #010101" width="356" |
+
| style="border: 1px solid #010101" width="356" |  
 
BULKMAIL_NO_OF_SENT
 
BULKMAIL_NO_OF_SENT
| style="border: 1px solid #010101" width="356" |
+
 
 +
| style="border: 1px solid #010101" width="356" |  
 
Number (read only)
 
Number (read only)
 +
 +
| style="border: 1px solid #010101" width="356" |
 +
Default is 0
 +
 +
|- align="left" valign="top"
 +
| style="border: 1px solid #010101" width="356" |
 +
BULKMAIL_DEPENDANT_BULKMAIL
 +
 +
| style="border: 1px solid #010101" width="356" |
 +
number
 +
 +
| style="border: 1px solid #010101" width="356" |
 +
 +
 +
|- align="left" valign="top"
 +
| style="border: 1px solid #010101" width="356" |
 +
BULKMAIL_SELECTED_HISTORY
 +
 +
| style="border: 1px solid #010101" width="356" |
 +
array
 +
 
| style="border: 1px solid #010101" width="356" |
 
| style="border: 1px solid #010101" width="356" |
Default is 0
+
|- align="left" valign="top"
 +
| style="border: 1px solid #010101" width="356" |
 +
BULKMAIL_SELECTED_RECIPIENTS
 +
 
 +
| style="border: 1px solid #010101" width="356" |
 +
[[BulkRecipients_class|BulkRecipients]]
 +
 
 +
| style="border: 1px solid #010101" width="356" |
 +
|- align="left" valign="top"
 +
| style="border: 1px solid #010101" width="356" |
 +
BULKMAIL_CAN_EDIT
 +
 
 +
| style="border: 1px solid #010101" width="356" |
 +
bool
 +
 
 +
| style="border: 1px solid #010101" width="356" |
 +
 
 +
<br/>
 +
 
 +
<!-- imported from file: 7597.htm-->
 +
 
 +
|}
  
 
'''Example'''
 
'''Example'''
Line 136: Line 215:
 
array newBM = BulkMail_new(bulkMailName, parentResourceId, mailTemplateResourceId);
 
array newBM = BulkMail_new(bulkMailName, parentResourceId, mailTemplateResourceId);
  
print(newBM);
+
print(newBM); // {27,0,TestBulkMail,34778803,34409968,501537,Administrator@mycatinet.catglobe.com,{},{},{},0,0,0}
  
'''Availability'''
+
<br/>Availability
  
Version 5.8
+
Version 5.8 __NOTOC__
__NOTOC__
 
<!-- imported from file: 7597.htm-->
 

Latest revision as of 10:10, 7 March 2022


BulkMail_new

Create new bulk mail object

Syntax

BulkMail_new(bulkMailName, parentResourceId, mailTemplateResourceId)

or

BulkMail_new( bulkMailName, parentResourceId, mailTemplateResourceId , bulkMailTemplateResourceId)

Arguments

  • bulkMailName: is string. It is the name of new bulkMail
  • parentResourceId: is number. It is parent resource id of the new bulkMail
  • mailTemplateResourceId: is number. It is the mail template resource Id gotten from Communicator template
  • bulkMailTemplateResourceId: is number. It is bulkMail template resource Id

Return value

Array which is BulkMail object:

Index

Data type

Value

BULKMAIL_RESOURCE_ID

number

0

BULKMAIL_NAME

number

Entered value

BULKMAIL_PARENT_RESOURCE_ID

string

Entered value

BULKMAIL_TEMPLATE_RESOURCE_ID

number

if it is not specified explicitly in the constructor as a parameter, then get default bulk mail template

BULKMAIL_MAIL_TEMPLATE_RESOURCE_ID

number

Entered value

BULKMAIL_EMAIL_ACCOUNT

string

It will be the default private email inside the parent resource or the first global email in case there is no a default private email. If there is no any private and global email then it's ""

BULKMAIL_USER_RESOURCE_IDS

array

{}

BULKMAIL_GROUP_RESOURCE_IDS

array

{}

BULKMAIL_GROUP_TO_BE_REBUILD_RESOURCE_IDS

array

{}

BULKMAIL_PRIORITY

number

Normal

There must be constants defined for 3 levels of priority:

0: Bulkmail_Priority_Normal

1: Bulkmail_Priority_Low

2: Bulkmail_Priority_High

BULKMAIL_NO_IN_OUT_QUEUE

Number (read only)

Default is 0

BULKMAIL_NO_OF_SENT

Number (read only)

Default is 0

BULKMAIL_DEPENDANT_BULKMAIL

number


BULKMAIL_SELECTED_HISTORY

array

BULKMAIL_SELECTED_RECIPIENTS

BulkRecipients

BULKMAIL_CAN_EDIT

bool



Example

string bulkMailName = "TestBulkMail";

number parentResourceId = 34778803;

number mailTemplateResourceId = 501537;

array newBM = BulkMail_new(bulkMailName, parentResourceId, mailTemplateResourceId);

print(newBM); // {27,0,TestBulkMail,34778803,34409968,501537,Administrator@mycatinet.catglobe.com,{},{},{},0,0,0}


Availability

Version 5.8