@resconet/jsbridge 17.0.0 → 17.1.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/JSBridge.d.ts +600 -375
- package/src/JSBridge.js +4303 -4193
package/src/JSBridge.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
// JSBridge.js TypeScript definition file
|
|
2
2
|
// (c) 2023 Resco
|
|
3
3
|
|
|
4
|
-
declare
|
|
5
|
-
|
|
4
|
+
declare namespace MobileCRM {
|
|
6
5
|
class Size {
|
|
7
6
|
width: string;
|
|
8
7
|
height: string;
|
|
@@ -20,9 +19,24 @@ declare module MobileCRM {
|
|
|
20
19
|
command(command: string, params: any, success?: (data: any) => void, failed?: (error: string) => void, scope?: any);
|
|
21
20
|
invokeCommandPromise(command: string, params: any): Promise<any>;
|
|
22
21
|
getWindowSize(callback: (size: Size) => void, erroCallback?: (error: string) => void, scope?: any);
|
|
23
|
-
invokeMethodAsync(
|
|
22
|
+
invokeMethodAsync(
|
|
23
|
+
objectName: string,
|
|
24
|
+
method: string,
|
|
25
|
+
params: any,
|
|
26
|
+
callback?: (retVal: any) => void,
|
|
27
|
+
errorCallback?: (error: string) => void,
|
|
28
|
+
scope?: any
|
|
29
|
+
);
|
|
24
30
|
invokeMethodPromise(objectName: string, method: string, params: any): Promise<any>;
|
|
25
|
-
invokeStaticMethodAsync(
|
|
31
|
+
invokeStaticMethodAsync(
|
|
32
|
+
assembly: string,
|
|
33
|
+
typeName: string,
|
|
34
|
+
method: string,
|
|
35
|
+
paramsList: any[],
|
|
36
|
+
callback?: (retVal: any) => void,
|
|
37
|
+
errorCallback?: (error: string) => void,
|
|
38
|
+
scope?: any
|
|
39
|
+
);
|
|
26
40
|
invokeStaticMethodPromise(assembly: string, typeName: string, method: string, paramsList: any[]): Promise<any>;
|
|
27
41
|
raiseGlobalEvent(eventName: string, args: any);
|
|
28
42
|
onGlobalEvent(eventName: string, handler: (args: any) => void, bind: boolean, scope?: any);
|
|
@@ -148,7 +162,7 @@ declare module MobileCRM {
|
|
|
148
162
|
/**Gets or sets whether the current user is demo user. */
|
|
149
163
|
isDemoUser: boolean;
|
|
150
164
|
/**Gets whether the login is for a CRM Online instance.*/
|
|
151
|
-
isCrmOnline: boolean
|
|
165
|
+
isCrmOnline: boolean;
|
|
152
166
|
/**Gets whether the login information is valid and complete.
|
|
153
167
|
Indicates whether the user name and password are non-empty.
|
|
154
168
|
Whether they are correct is up to the we service. Also checks whether the web service url is non-empty.*/
|
|
@@ -240,7 +254,12 @@ declare module MobileCRM {
|
|
|
240
254
|
public static initialized: boolean;
|
|
241
255
|
|
|
242
256
|
static initialize(callback: (localization: Localization) => void, errorCallback?: (error: string) => void, scope?: any);
|
|
243
|
-
static initializeEx(
|
|
257
|
+
static initializeEx(
|
|
258
|
+
regularExpression: string,
|
|
259
|
+
callback?: (localization: Localization) => void,
|
|
260
|
+
errorCallback?: (error: string) => void,
|
|
261
|
+
scope?: any
|
|
262
|
+
);
|
|
244
263
|
static initializeAsync(regularExpression: string): Promise<Localization>;
|
|
245
264
|
static getLoadedLangId(callback: (langId: string) => void, errorCallback?: (error: string) => void, scope?: any);
|
|
246
265
|
static getTextOrDefault: (id: string, defaultString: string) => string;
|
|
@@ -368,7 +387,7 @@ declare module MobileCRM {
|
|
|
368
387
|
static loadAsync(entityName: string, id: string): Promise<Reference>;
|
|
369
388
|
}
|
|
370
389
|
|
|
371
|
-
/**
|
|
390
|
+
/**
|
|
372
391
|
* Person or group associated with an activity.
|
|
373
392
|
* An activity can have multiple activity parties.
|
|
374
393
|
*/
|
|
@@ -402,7 +421,15 @@ declare module MobileCRM {
|
|
|
402
421
|
* @param failed A callback function for command failure. The <b>error</b> argument will carry the error message.
|
|
403
422
|
* @param scope A scope for calling the callbacks; set "null" to call the callbacks in global scope.
|
|
404
423
|
*/
|
|
405
|
-
private static addRecord(
|
|
424
|
+
private static addRecord(
|
|
425
|
+
entityName: string,
|
|
426
|
+
ref1: Reference,
|
|
427
|
+
ref2: Reference,
|
|
428
|
+
create: boolean,
|
|
429
|
+
success?: () => void,
|
|
430
|
+
failed?: (string) => void,
|
|
431
|
+
scope?: any
|
|
432
|
+
);
|
|
406
433
|
/**
|
|
407
434
|
* Creates a new N-N relationship between the two passed entities.
|
|
408
435
|
* @param entityName The relationship entity name.
|
|
@@ -441,10 +468,31 @@ declare module MobileCRM {
|
|
|
441
468
|
static createNew: (entityName: string, id?: string, primaryName?: string, properties?: any) => MobileCRM.DynamicEntity;
|
|
442
469
|
static deleteById(entityName: string, id: string, sucess?: () => void, failed?: (error: string) => void, scope?: any);
|
|
443
470
|
static deleteAsync(entityName: string, id: string): Promise<void>;
|
|
444
|
-
static loadById(
|
|
471
|
+
static loadById(
|
|
472
|
+
entityName: string,
|
|
473
|
+
id: string,
|
|
474
|
+
sucess: (DynamicEntity: MobileCRM.DynamicEntity) => void,
|
|
475
|
+
failed?: (error: string) => void,
|
|
476
|
+
scope?: any
|
|
477
|
+
);
|
|
445
478
|
static loadAsync(entityName: string, id: string): Promise<MobileCRM.DynamicEntity>;
|
|
446
|
-
static saveDocumentBody(
|
|
447
|
-
|
|
479
|
+
static saveDocumentBody(
|
|
480
|
+
entityId: string,
|
|
481
|
+
entityName: string,
|
|
482
|
+
relationship: MobileCRM.Relationship,
|
|
483
|
+
filePath: string,
|
|
484
|
+
mimeType: string,
|
|
485
|
+
sucess?: (result: MobileCRM.Reference) => void,
|
|
486
|
+
failed?: (error: string) => void,
|
|
487
|
+
scope?: any
|
|
488
|
+
);
|
|
489
|
+
static saveDocumentBodyAsync(
|
|
490
|
+
entityId: string,
|
|
491
|
+
entityName: string,
|
|
492
|
+
relationship: MobileCRM.Relationship,
|
|
493
|
+
filePath: string,
|
|
494
|
+
mimeType: string
|
|
495
|
+
): Promise<MobileCRM.Reference>;
|
|
448
496
|
static loadDocumentBody(entityName: string, id: string, sucess: (base64: string) => void, failed?: (error: string) => void, scope?: any);
|
|
449
497
|
static loadDocumentBodyAsync(entityName: string, id: string): Promise<string>;
|
|
450
498
|
static unzipDocumentBody(entityName: string, id: string, targetDir: string, sucess?: () => void, failed?: (error: string) => void, scope?: any);
|
|
@@ -458,7 +506,13 @@ declare module MobileCRM {
|
|
|
458
506
|
* @param failureCallback A callback function for command failure. The argument will carry the error message.
|
|
459
507
|
* @param scope A scope for calling the callbacks
|
|
460
508
|
*/
|
|
461
|
-
static saveMultiple(
|
|
509
|
+
static saveMultiple(
|
|
510
|
+
updatedEntities: Array<MobileCRM.DynamicEntity>,
|
|
511
|
+
online?: boolean,
|
|
512
|
+
sucessCallback?: () => void,
|
|
513
|
+
failureCallback?: (error: string) => void,
|
|
514
|
+
scope?: any
|
|
515
|
+
);
|
|
462
516
|
/**
|
|
463
517
|
* Delete an entities instances to storage.Where the entity is stored is determined by how it was loaded: online / offline.
|
|
464
518
|
* @param deletedEntities Array of MobileCRM.DynamicEntity or MobileCRM.Reference what will be deleted.
|
|
@@ -467,7 +521,13 @@ declare module MobileCRM {
|
|
|
467
521
|
* @param failureCallback A callback function for command failure. The argument will carry the error message.
|
|
468
522
|
* @param scope A scope for calling the callbacks
|
|
469
523
|
*/
|
|
470
|
-
static deleteMultiple(
|
|
524
|
+
static deleteMultiple(
|
|
525
|
+
deletedEntities: Array<MobileCRM.Reference>,
|
|
526
|
+
online?: boolean,
|
|
527
|
+
sucessCallback?: () => void,
|
|
528
|
+
failureCallback?: (error: string) => void,
|
|
529
|
+
scope?: any
|
|
530
|
+
);
|
|
471
531
|
}
|
|
472
532
|
|
|
473
533
|
class Metadata {
|
|
@@ -482,7 +542,13 @@ declare module MobileCRM {
|
|
|
482
542
|
static getActivities(): Array<string>;
|
|
483
543
|
static getEntityParent(childEntityName: string): string;
|
|
484
544
|
static entityHasChildren(entityName: string): boolean;
|
|
485
|
-
static getOptionSetValues(
|
|
545
|
+
static getOptionSetValues(
|
|
546
|
+
entityName: string,
|
|
547
|
+
optionSetName: string,
|
|
548
|
+
sucess: (optioneSets: any) => void,
|
|
549
|
+
failed?: (error: string) => void,
|
|
550
|
+
scope?: any
|
|
551
|
+
);
|
|
486
552
|
static getStringListOptions(entityName: string, propertyName: string): Array<string>;
|
|
487
553
|
}
|
|
488
554
|
|
|
@@ -650,7 +716,14 @@ declare module MobileCRM {
|
|
|
650
716
|
* @param precision Desired accuracy in meters.
|
|
651
717
|
* @param timeout Timeout in milliseconds (since v10.1).
|
|
652
718
|
*/
|
|
653
|
-
public static getLocation(
|
|
719
|
+
public static getLocation(
|
|
720
|
+
success: (obj: Location) => void,
|
|
721
|
+
failed?: (error: string) => void,
|
|
722
|
+
scope?: any,
|
|
723
|
+
age?: number,
|
|
724
|
+
precision?: number,
|
|
725
|
+
timeout?: number
|
|
726
|
+
);
|
|
654
727
|
/**
|
|
655
728
|
* Gets current geo-location from platform-specific location service.
|
|
656
729
|
* If the current platform does not support the location service, the <b>failed</b> handler is called with error "Unsupported".
|
|
@@ -679,40 +752,49 @@ declare module MobileCRM {
|
|
|
679
752
|
*/
|
|
680
753
|
public static sendSMS(phoneNumber: string, text: string, failed?: (error: string) => void, scope?: any);
|
|
681
754
|
/**
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
755
|
+
* @since 8.1
|
|
756
|
+
* Opens the platform-specific e-mail message form with pre-filled data.
|
|
757
|
+
* @param address Recipients email address.
|
|
758
|
+
* @param subject An e-mail subject.
|
|
759
|
+
* @param body A string with email body.
|
|
760
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
761
|
+
* @param scope The scope for errorCallback.
|
|
762
|
+
*/
|
|
690
763
|
public static email(address: string, subject: string, body: string, errorCallback?: () => void, scope?: any);
|
|
691
764
|
/**
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
765
|
+
* @since 15.0
|
|
766
|
+
* Opens the platform-specific e-mail message form with pre-filled data.
|
|
767
|
+
* @param address Recipients email address.
|
|
768
|
+
* @param subject An e-mail subject.
|
|
769
|
+
* @param body A string with email body.
|
|
770
|
+
* @param mimeType Body content MIME type.
|
|
771
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
772
|
+
* @param scope The scope for errorCallback.
|
|
773
|
+
*/
|
|
701
774
|
public static sendEmail(address: string, subject: string, body: string, mimeType: string, errorCallback?: () => void, scope?: any);
|
|
702
775
|
/**
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
public static emailWithAttachments(
|
|
776
|
+
* @since 9.1
|
|
777
|
+
* Sends a list of files (full paths or IReferences to blobs) as email attachments.
|
|
778
|
+
* This method either open the CRM Email form or the native mail client (depending on application settings).
|
|
779
|
+
* @param address Recipients email address.
|
|
780
|
+
* @param subject An e-mail subject.
|
|
781
|
+
* @param body A string with email body.
|
|
782
|
+
* @param attachment Array of files to send. Element must be a full path or a IReference to a note, etc.
|
|
783
|
+
* @param entity The related entity reference.
|
|
784
|
+
* @param relationship The relationship to the created email entity. (optional).
|
|
785
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
786
|
+
* @param scope The scope for errorCallback.
|
|
787
|
+
*/
|
|
788
|
+
public static emailWithAttachments(
|
|
789
|
+
address: string,
|
|
790
|
+
subject: string,
|
|
791
|
+
body: string,
|
|
792
|
+
attachment: Array<any>,
|
|
793
|
+
entity: MobileCRM.Reference,
|
|
794
|
+
relationship: MobileCRM.Relationship,
|
|
795
|
+
errorCallback: (err: any) => void,
|
|
796
|
+
scope?: any
|
|
797
|
+
);
|
|
716
798
|
/**
|
|
717
799
|
* Gets network information.
|
|
718
800
|
* @since 11.2
|
|
@@ -805,7 +887,15 @@ declare module MobileCRM {
|
|
|
805
887
|
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
806
888
|
* @param scope The scope for callback.
|
|
807
889
|
*/
|
|
808
|
-
static writeFileWithEncoding(
|
|
890
|
+
static writeFileWithEncoding(
|
|
891
|
+
path: string,
|
|
892
|
+
text: string,
|
|
893
|
+
encoding: string,
|
|
894
|
+
append: boolean,
|
|
895
|
+
success: () => void,
|
|
896
|
+
failed?: (err: string) => void,
|
|
897
|
+
scope?: any
|
|
898
|
+
);
|
|
809
899
|
/**
|
|
810
900
|
* @since 12.1
|
|
811
901
|
* Asynchronously refresh access token using saved token in protected settings and send serialized token to success callback
|
|
@@ -853,7 +943,14 @@ declare module MobileCRM {
|
|
|
853
943
|
* @param failed A callback function for command failure. The <b>error</b> argument will carry the error message.
|
|
854
944
|
* @param scope A scope for calling the callbacks; set "null" to call the callbacks in global scope.
|
|
855
945
|
*/
|
|
856
|
-
public static getOAuthAccessToken(
|
|
946
|
+
public static getOAuthAccessToken(
|
|
947
|
+
configurationName: string,
|
|
948
|
+
oauthSettings: MobileCRM.OAuthSettings,
|
|
949
|
+
prompt: boolean,
|
|
950
|
+
success: (textAccessToken: string) => void,
|
|
951
|
+
failed?: (err: string) => void,
|
|
952
|
+
scope?: any
|
|
953
|
+
);
|
|
857
954
|
}
|
|
858
955
|
|
|
859
956
|
/**
|
|
@@ -900,7 +997,17 @@ declare module MobileCRM {
|
|
|
900
997
|
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
901
998
|
* @param scope The scope for errorCallback.
|
|
902
999
|
*/
|
|
903
|
-
static runReport(
|
|
1000
|
+
static runReport(
|
|
1001
|
+
fetch: string,
|
|
1002
|
+
reportXML: string,
|
|
1003
|
+
reportFormat: string,
|
|
1004
|
+
isExportOnly: boolean,
|
|
1005
|
+
isOnline: boolean,
|
|
1006
|
+
outputFile: string,
|
|
1007
|
+
success: (filePath: string) => void,
|
|
1008
|
+
failed?: (err: string) => void,
|
|
1009
|
+
scope?: any
|
|
1010
|
+
);
|
|
904
1011
|
/**
|
|
905
1012
|
* @since 9.1
|
|
906
1013
|
* Executes the mobile reporting request which produces the mobile report document of given format.
|
|
@@ -912,7 +1019,14 @@ declare module MobileCRM {
|
|
|
912
1019
|
* @param outputFile The full path to the output file. If omitted a temp file is created. The output path is always passed to the success callback.
|
|
913
1020
|
* @returns The file path to successfully created report.
|
|
914
1021
|
*/
|
|
915
|
-
static runReportAsync(
|
|
1022
|
+
static runReportAsync(
|
|
1023
|
+
fetch: string,
|
|
1024
|
+
reportXML: string,
|
|
1025
|
+
reportFormat: string,
|
|
1026
|
+
isExportOnly: boolean,
|
|
1027
|
+
isOnline: boolean,
|
|
1028
|
+
outputFile: string
|
|
1029
|
+
): Promise<string>;
|
|
916
1030
|
/**
|
|
917
1031
|
* @since 10.1
|
|
918
1032
|
* Shows new MobileReport form. Source for the report can be defined either as list of MobileCRM.Reference objects or as FetchXML query.
|
|
@@ -933,7 +1047,14 @@ declare module MobileCRM {
|
|
|
933
1047
|
* @param failed A callback which is called in case of error.
|
|
934
1048
|
* @param scope The scope for callbacks.
|
|
935
1049
|
*/
|
|
936
|
-
static showFormWithConfiguration(
|
|
1050
|
+
static showFormWithConfiguration(
|
|
1051
|
+
report: MobileCRM.Reference,
|
|
1052
|
+
source: Array<MobileCRM.Reference>,
|
|
1053
|
+
fetchXml: string,
|
|
1054
|
+
paramString: string,
|
|
1055
|
+
failed?: (err: string) => void,
|
|
1056
|
+
scope?: any
|
|
1057
|
+
);
|
|
937
1058
|
}
|
|
938
1059
|
class Questionnaire {
|
|
939
1060
|
static getQuestionName(name: string, repeatIndex: number): string;
|
|
@@ -946,13 +1067,13 @@ declare module MobileCRM {
|
|
|
946
1067
|
*/
|
|
947
1068
|
declare module MobileCRM.FetchXml {
|
|
948
1069
|
/**
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
1070
|
+
* @class Represents a FetchXml
|
|
1071
|
+
* @property entity {MobileCRM.FetchXml.Entity} An entity object.
|
|
1072
|
+
* @property count {number} The maximum number of records to retrieve.
|
|
1073
|
+
* @property page {number} 1-based index of the data page to retrieve.
|
|
1074
|
+
* @property aggregate {boolean} Indicates whether the fetch is aggregated.
|
|
1075
|
+
* @property distinct {boolean} Indicates whether to return only distinct (different) values.
|
|
1076
|
+
*/
|
|
956
1077
|
class Fetch {
|
|
957
1078
|
constructor(entity?: MobileCRM.FetchXml.Entity, count?: number, page?: number, distinct?: boolean);
|
|
958
1079
|
|
|
@@ -972,16 +1093,16 @@ declare module MobileCRM.FetchXml {
|
|
|
972
1093
|
public static executeFromXML(fetchXmlData: string, success: (res: Array<any>) => void, failed?: (error: string) => void, scope?: any);
|
|
973
1094
|
/**
|
|
974
1095
|
* @since 10.0
|
|
975
|
-
|
|
1096
|
+
* Deserializes XML to the Fetch object.
|
|
976
1097
|
* @param xml A string defining the fetch XML request.
|
|
977
1098
|
* @param success A callback function for successful asynchronous result.The result argument will carry the Fetch object.
|
|
978
1099
|
* @param failed A callback function for command failure.The error argument will carry the error message.
|
|
979
1100
|
* @param scope A scope for calling the callbacks.Set to call the callbacks in global scope.
|
|
980
1101
|
*/
|
|
981
|
-
public static deserializeFromXml(xml: string, success: (result: MobileCRM.FetchXml.Fetch) => void, failed?: (err: string) => void, scope?: any)
|
|
1102
|
+
public static deserializeFromXml(xml: string, success: (result: MobileCRM.FetchXml.Fetch) => void, failed?: (err: string) => void, scope?: any);
|
|
982
1103
|
/**
|
|
983
1104
|
* @since 10.0
|
|
984
|
-
|
|
1105
|
+
* Deserializes XML to the Fetch object.
|
|
985
1106
|
* @param xml A string defining the fetch XML request.
|
|
986
1107
|
* @returns A Promise resolved with corresponding Fetch object.
|
|
987
1108
|
*/
|
|
@@ -1035,13 +1156,13 @@ declare module MobileCRM.FetchXml {
|
|
|
1035
1156
|
public executeAsync(output: string, online?: boolean): Promise<any[]>;
|
|
1036
1157
|
}
|
|
1037
1158
|
/**
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1159
|
+
* @class Represents a FetchXml query root entity.
|
|
1160
|
+
* @param name {string} An entity logical name.
|
|
1161
|
+
* @property attributes {Array<Attribute>} An array of <see cref="MobileCRM.FetchXml.Attribute">MobileCRM.FetchXml.Attribute</see> objects.
|
|
1162
|
+
* @property order {Array<Order>} An array of {MobileCRM.FetchXml.Order} objects
|
|
1163
|
+
* @property filter {Filter} A query filter.
|
|
1164
|
+
* @property linkentities {Array<LinkEntity>} An array of {MobileCRM.FetchXml.LinkEntity} objects.
|
|
1165
|
+
*/
|
|
1045
1166
|
class Entity {
|
|
1046
1167
|
constructor(name: string);
|
|
1047
1168
|
|
|
@@ -1072,13 +1193,13 @@ declare module MobileCRM.FetchXml {
|
|
|
1072
1193
|
*/
|
|
1073
1194
|
addAttributes();
|
|
1074
1195
|
/**
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1196
|
+
* Adds an entity link (join) to the fetch query.
|
|
1197
|
+
* @param target The target entity.
|
|
1198
|
+
* @param from The "from" field (if parent then target entity primary key).
|
|
1199
|
+
* @param to The "to" field.
|
|
1200
|
+
* @param linkType The link (join) type ("inner" or "outer").
|
|
1201
|
+
* @returns MobileCRM.FetchXml.LinkEntity
|
|
1202
|
+
*/
|
|
1082
1203
|
addLink(target: string, from: string, to: string, linkType: string): MobileCRM.FetchXml.LinkEntity;
|
|
1083
1204
|
removeLink(link: MobileCRM.FetchXml.LinkEntity): void;
|
|
1084
1205
|
/**
|
|
@@ -1102,16 +1223,16 @@ declare module MobileCRM.FetchXml {
|
|
|
1102
1223
|
* @param failed A callback function for command failure. The error argument will carry the error message.
|
|
1103
1224
|
* @param scope A scope for calling the callbacks. Set to call the callbacks in global scope.
|
|
1104
1225
|
*/
|
|
1105
|
-
deserializeFromXml(xml: string, success: (result: MobileCRM.FetchXml.Fetch) => void, failed?: (err: string) => void, scope?: any)
|
|
1226
|
+
deserializeFromXml(xml: string, success: (result: MobileCRM.FetchXml.Fetch) => void, failed?: (err: string) => void, scope?: any);
|
|
1106
1227
|
}
|
|
1107
1228
|
/**
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1229
|
+
* @class Represents a FetchXml query linked entity.
|
|
1230
|
+
* @param name {string} An entity name
|
|
1231
|
+
* @property from {number} The "from" field (if parent then target entity primary key).
|
|
1232
|
+
* @property to {number}
|
|
1233
|
+
* @property linktype {boolean} The link (join) type ("inner" or "outer").
|
|
1234
|
+
* @property alias {string} Defines an order alias.
|
|
1235
|
+
*/
|
|
1115
1236
|
class LinkEntity extends Entity {
|
|
1116
1237
|
constructor(name: string);
|
|
1117
1238
|
|
|
@@ -1121,14 +1242,14 @@ declare module MobileCRM.FetchXml {
|
|
|
1121
1242
|
alias: string;
|
|
1122
1243
|
}
|
|
1123
1244
|
/**
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1245
|
+
* @class Represents a FetchXml select statement (CRM field).
|
|
1246
|
+
* @param name {string} lower-case entity attribute name (CRM logical field name).
|
|
1247
|
+
* @property name {string} A lower-case entity attribute name (CRM logical field name).
|
|
1248
|
+
* @property aggregate {boolean} An aggregation function.
|
|
1249
|
+
* @property grouby {number} Indicates whether to group by this attribute.
|
|
1250
|
+
* @property alias {string} Defines an order alias.
|
|
1251
|
+
* @property dategrouping {string} A date group by modifier (year, quarter, month, week, day).
|
|
1252
|
+
*/
|
|
1132
1253
|
class Attribute {
|
|
1133
1254
|
constructor(name: string);
|
|
1134
1255
|
name: string;
|
|
@@ -1138,11 +1259,11 @@ declare module MobileCRM.FetchXml {
|
|
|
1138
1259
|
dategrouping: string;
|
|
1139
1260
|
}
|
|
1140
1261
|
/**
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1262
|
+
* @class Represents a FetchXml order statement.
|
|
1263
|
+
* @property attribure {string} An attribute name (CRM logical field name).
|
|
1264
|
+
* @property alias {string} Defines an order alias.
|
|
1265
|
+
* @property descending {boolean} true, for descending order; false, for ascending order
|
|
1266
|
+
*/
|
|
1146
1267
|
class Order {
|
|
1147
1268
|
constructor(attribute?: string, descending?: boolean);
|
|
1148
1269
|
attribute: string;
|
|
@@ -1150,11 +1271,11 @@ declare module MobileCRM.FetchXml {
|
|
|
1150
1271
|
descending: boolean;
|
|
1151
1272
|
}
|
|
1152
1273
|
/**
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1274
|
+
* @class Represents a FetchXml filter statement. A logical combination of {Condition} and child-filters.
|
|
1275
|
+
* @property type {string} Defines the filter operator ("or" / "and").
|
|
1276
|
+
* @property conditions {Array<Condition>} An array of {Condition} objects.
|
|
1277
|
+
* @property filters { Array<Filter>} An array of <see cref="MobileCRM.FetchXml.Filter"/> objects representing child-filters.
|
|
1278
|
+
*/
|
|
1158
1279
|
class Filter {
|
|
1159
1280
|
type: string;
|
|
1160
1281
|
conditions: Array<Condition>;
|
|
@@ -1204,14 +1325,14 @@ declare module MobileCRM.FetchXml {
|
|
|
1204
1325
|
contains(attribute: string, value: string): MobileCRM.FetchXml.Condition;
|
|
1205
1326
|
}
|
|
1206
1327
|
/**
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1328
|
+
* @class Represents a FetchXml attribute condition statement.
|
|
1329
|
+
* @property attribute {string} The attribute name (CRM logical field name).
|
|
1330
|
+
* @property operator {string} The condition operator. "eq", "ne", "in", "not-in", "between", "not-between", "lt", "le", "gt", "ge", "like", "not-like", "null", "not-null", "eq-userid", "eq-userteams", "today", "yesterday", "tomorrow", "this-year", "last-week", "last-x-hours", "next-x-years", "olderthan-x-months", ...
|
|
1331
|
+
* @property uitype {string} The lookup target entity display name.
|
|
1332
|
+
* @property uiname {string} The lookup target entity logical name.
|
|
1333
|
+
* @property value {any} The value to compare to.
|
|
1334
|
+
* @property values {Array<any>} The list of values to compare to.
|
|
1335
|
+
*/
|
|
1215
1336
|
class Condition {
|
|
1216
1337
|
attribute: string;
|
|
1217
1338
|
entityname: string;
|
|
@@ -1226,7 +1347,12 @@ declare module MobileCRM.Services {
|
|
|
1226
1347
|
class CompanyInformation {
|
|
1227
1348
|
name: string;
|
|
1228
1349
|
address: string;
|
|
1229
|
-
public static getCompanyInfoFromVat(
|
|
1350
|
+
public static getCompanyInfoFromVat(
|
|
1351
|
+
vat: string | number,
|
|
1352
|
+
success: (result: MobileCRM.Services.CompanyInformation) => void,
|
|
1353
|
+
failed?: (err: string) => void,
|
|
1354
|
+
scope?: any
|
|
1355
|
+
);
|
|
1230
1356
|
}
|
|
1231
1357
|
class FileInfo {
|
|
1232
1358
|
filePath: string;
|
|
@@ -1277,22 +1403,22 @@ declare module MobileCRM.Services {
|
|
|
1277
1403
|
* @param failed A callback function for command failure. The error argument will carry the error message.
|
|
1278
1404
|
* @param scope A scope for calling the callbacks. Set to call the callbacks in global scope.
|
|
1279
1405
|
*/
|
|
1280
|
-
saveFileDialog(fileName: string, fileData: string, success: (result: boolean) => void, failed?: (err: string) => void, scope?: any)
|
|
1406
|
+
saveFileDialog(fileName: string, fileData: string, success: (result: boolean) => void, failed?: (err: string) => void, scope?: any);
|
|
1281
1407
|
}
|
|
1282
1408
|
/** Represents the synchronization result.
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1409
|
+
* @property newCustomizationReady {boolean} Indicates whether the new customization is ready.
|
|
1410
|
+
* @property customizationDownloaded {boolean} Indicates whether the new customization was applied.
|
|
1411
|
+
* @property dataErrorsEncountered {boolean} Indicates whether some data errors were encountered during sync (cannot upload, delete, change status, owner, etc.).
|
|
1412
|
+
* @property appWasLocked {boolean} Application was locked.
|
|
1413
|
+
* @property syncAborted {boolean} Sync was aborted.
|
|
1414
|
+
* @property adminFullSync {boolean} Full sync was requested so background sync was aborted.
|
|
1415
|
+
* @property wasBackgroundSync {boolean} Indicates whether the last sync was background sync or foreground sync.
|
|
1416
|
+
* @property connectFailed {boolean} Indicates whether sync could not start because of a connection failure.
|
|
1417
|
+
* @property webError {boolean} Indicates whether sync failed due to a communication error (HttpException, for example).
|
|
1418
|
+
* @property OAuthError {boolean} Sync failed because the OAuth access token can't be acquired or refreshed.
|
|
1419
|
+
* @property syncDownloadRestartedOnBackground {boolean} New customization was downloaded. Sync is still downloading data on background.
|
|
1420
|
+
* @property warning {boolean} Sync result contains some warnings that are not critical.
|
|
1421
|
+
*/
|
|
1296
1422
|
class SynchronizationResult {
|
|
1297
1423
|
constructor(synchronizationResult?: number);
|
|
1298
1424
|
newCustomizationReady: boolean;
|
|
@@ -1310,7 +1436,12 @@ declare module MobileCRM.Services {
|
|
|
1310
1436
|
}
|
|
1311
1437
|
class AddressBookService {
|
|
1312
1438
|
public static getService(errorCallback?: (error: string) => void, scope?: any): AddressBookService;
|
|
1313
|
-
getContact(
|
|
1439
|
+
getContact(
|
|
1440
|
+
id: string,
|
|
1441
|
+
callback: (addressBookRecord: MobileCRM.Services.AddressBookService.AddressBookRecord) => void,
|
|
1442
|
+
errorCallback?: (error: string) => void,
|
|
1443
|
+
scope?: any
|
|
1444
|
+
);
|
|
1314
1445
|
}
|
|
1315
1446
|
class ChatService {
|
|
1316
1447
|
chatUser: MobileCRM.DynamicEntity;
|
|
@@ -1318,9 +1449,29 @@ declare module MobileCRM.Services {
|
|
|
1318
1449
|
userId: string;
|
|
1319
1450
|
|
|
1320
1451
|
static getService(callback: (res: MobileCRM.Services.ChatService) => void, errorCallback?: (error: string) => void, scope?: any);
|
|
1321
|
-
postMessage(
|
|
1322
|
-
|
|
1323
|
-
|
|
1452
|
+
postMessage(
|
|
1453
|
+
regardingEntity: MobileCRM.Reference,
|
|
1454
|
+
text: string,
|
|
1455
|
+
callback?: (res: MobileCRM.DynamicEntity) => void,
|
|
1456
|
+
errorCallback?: (error: string) => void,
|
|
1457
|
+
scope?: any
|
|
1458
|
+
);
|
|
1459
|
+
attachNoteToPost(
|
|
1460
|
+
postId: string,
|
|
1461
|
+
filePath: string,
|
|
1462
|
+
mimeType: string,
|
|
1463
|
+
subject: string,
|
|
1464
|
+
callback?: (res: MobileCRM.DynamicEntity) => void,
|
|
1465
|
+
errorCallback?: (error: string) => void,
|
|
1466
|
+
scope?: any
|
|
1467
|
+
);
|
|
1468
|
+
subscribeToEntityChannel(
|
|
1469
|
+
regardingEntity: MobileCRM.Reference,
|
|
1470
|
+
subscribe: boolean,
|
|
1471
|
+
callback?: (res: MobileCRM.DynamicEntity) => void,
|
|
1472
|
+
errorCallback?: (error: string) => void,
|
|
1473
|
+
scope?: any
|
|
1474
|
+
);
|
|
1324
1475
|
}
|
|
1325
1476
|
|
|
1326
1477
|
class GeoAddress {
|
|
@@ -1332,7 +1483,13 @@ declare module MobileCRM.Services {
|
|
|
1332
1483
|
country: string;
|
|
1333
1484
|
isValid: string;
|
|
1334
1485
|
|
|
1335
|
-
public static fromLocation(
|
|
1486
|
+
public static fromLocation(
|
|
1487
|
+
latitude: number,
|
|
1488
|
+
longitude: number,
|
|
1489
|
+
success: (res: MobileCRM.Services.GeoAddress) => void,
|
|
1490
|
+
failed?: (error: string) => void,
|
|
1491
|
+
scope?: any
|
|
1492
|
+
);
|
|
1336
1493
|
public toLocation(success: (res: Location) => void, failed?: (error: string) => void, scope?: any);
|
|
1337
1494
|
}
|
|
1338
1495
|
class HttpWebRequest {
|
|
@@ -1418,7 +1575,7 @@ declare module MobileCRM.Services {
|
|
|
1418
1575
|
}
|
|
1419
1576
|
|
|
1420
1577
|
interface IAIVisionResult {
|
|
1421
|
-
tags: Array<IAIVisionTags
|
|
1578
|
+
tags: Array<IAIVisionTags>;
|
|
1422
1579
|
filePath: string;
|
|
1423
1580
|
}
|
|
1424
1581
|
interface IAIVisionTags {
|
|
@@ -1431,7 +1588,6 @@ declare module MobileCRM.Services {
|
|
|
1431
1588
|
responseText: string;
|
|
1432
1589
|
responseType: string;
|
|
1433
1590
|
}
|
|
1434
|
-
|
|
1435
1591
|
}
|
|
1436
1592
|
declare module MobileCRM.Services.AddressBookService {
|
|
1437
1593
|
class AddressBookRecord {
|
|
@@ -1599,8 +1755,8 @@ declare module MobileCRM.UI {
|
|
|
1599
1755
|
hasWarning: boolean;
|
|
1600
1756
|
}
|
|
1601
1757
|
/**
|
|
1602
|
-
|
|
1603
|
-
|
|
1758
|
+
* Represents the Javascript equivalent of native entity form object.
|
|
1759
|
+
*/
|
|
1604
1760
|
class EntityForm {
|
|
1605
1761
|
/** Gets the associated views as an array of MobileCRM.UI.IEntityList objects.*/
|
|
1606
1762
|
associatedViews: Array<IEntityList>;
|
|
@@ -1635,68 +1791,68 @@ declare module MobileCRM.UI {
|
|
|
1635
1791
|
/** NoteForm only. Gets the view containing the note attachment. */
|
|
1636
1792
|
documentView?: _DocumentView;
|
|
1637
1793
|
/**
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1794
|
+
* Returns the DetailView by its name.
|
|
1795
|
+
* @param name A name of DetailView.
|
|
1796
|
+
* @returns MobileCRM.UI._DetailView
|
|
1797
|
+
*/
|
|
1642
1798
|
getDetailView(name: string): MobileCRM.UI._DetailView;
|
|
1643
1799
|
/**
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1800
|
+
* Returns the tab controller by its view name.
|
|
1801
|
+
* @param name A name of 'controllers' view.
|
|
1802
|
+
* @returns MobileCRM.UI._Controller
|
|
1803
|
+
*/
|
|
1648
1804
|
getController(name: string): _Controller;
|
|
1649
1805
|
/**
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1806
|
+
* Returns the entity list by its view name.
|
|
1807
|
+
* This method looks for plain associated views but also for controllers that can be flipped into a list (in addition to map or chart).
|
|
1808
|
+
* @param name A name of associated view.
|
|
1809
|
+
* @returns IEntityList
|
|
1810
|
+
*/
|
|
1655
1811
|
getEntityList(name: string): IEntityList;
|
|
1656
1812
|
/**
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1813
|
+
* Sets the address fields according to the current geo-location from platform-specific location service.
|
|
1814
|
+
* @param latitude The latitude from geo-location from platform-specific location service
|
|
1815
|
+
* @param longitude longitude from geo-location from platform-specific location service
|
|
1816
|
+
*/
|
|
1661
1817
|
updateAddressFields(latitude: number, longitude: number);
|
|
1662
1818
|
/**
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1819
|
+
* Stops the onSave validation and optionally causes an error message to be displayed.
|
|
1820
|
+
* @param errorMsg An error message to be displayed or "null" to cancel the validation without message.
|
|
1821
|
+
*/
|
|
1666
1822
|
cancelValidation(errorMsg: string);
|
|
1667
1823
|
/**
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1824
|
+
* @since 8.0
|
|
1825
|
+
* Selects the form tab by its name.
|
|
1826
|
+
* @param tabName The name of the tab.
|
|
1827
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
1828
|
+
* @param scope The scope for callback.
|
|
1829
|
+
*/
|
|
1674
1830
|
selectTab(tabName: string, errorCallback?: (err: string) => void, scope?: any);
|
|
1675
1831
|
/**
|
|
1676
|
-
|
|
1677
|
-
|
|
1678
|
-
|
|
1679
|
-
|
|
1680
|
-
|
|
1681
|
-
|
|
1832
|
+
* @since 8.0
|
|
1833
|
+
* Selects the form tab by its name using static method.
|
|
1834
|
+
* @param tabName The name of the tab.
|
|
1835
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error.
|
|
1836
|
+
* @param scope The scope for callback.
|
|
1837
|
+
*/
|
|
1682
1838
|
public static selectTabEx(tabName: string, errorCallback?: (err: string) => void, scope?: any);
|
|
1683
1839
|
/**
|
|
1684
|
-
|
|
1685
|
-
|
|
1686
|
-
|
|
1687
|
-
|
|
1840
|
+
* The name of the associated entity list tab.
|
|
1841
|
+
* @param tabName The name of the associated entity list tab.
|
|
1842
|
+
* @param viewName The view name.
|
|
1843
|
+
*/
|
|
1688
1844
|
selectView(tabName: string, viewName: string);
|
|
1689
1845
|
/**
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1846
|
+
* Sets the visibility of the form tab defined by its name.
|
|
1847
|
+
* @param tabName The name of the tab.
|
|
1848
|
+
* @param visible Defines desired visibility state.
|
|
1849
|
+
*/
|
|
1694
1850
|
setTabVisibility(tabName: string, visible: boolean);
|
|
1695
1851
|
/**
|
|
1696
|
-
|
|
1697
|
-
|
|
1698
|
-
|
|
1699
|
-
|
|
1852
|
+
* Gets the MediaTab object representing the media tab with given name.
|
|
1853
|
+
* @param name The name of the tab
|
|
1854
|
+
* @returns MobileCRM.UI.MediaTab
|
|
1855
|
+
*/
|
|
1700
1856
|
getMediaTab(name: string): MediaTab;
|
|
1701
1857
|
|
|
1702
1858
|
/**
|
|
@@ -1710,144 +1866,149 @@ declare module MobileCRM.UI {
|
|
|
1710
1866
|
*/
|
|
1711
1867
|
suspendPostSave(): IFormPostSaveHandler;
|
|
1712
1868
|
/**
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1869
|
+
* @since 9.1
|
|
1870
|
+
* Reactivates inactive entity and reloads the form.
|
|
1871
|
+
* @param statuscode Activation status code.
|
|
1872
|
+
*/
|
|
1717
1873
|
reactivateEntity(statuscode: number);
|
|
1718
1874
|
|
|
1719
1875
|
/**
|
|
1720
|
-
|
|
1721
|
-
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1876
|
+
* Requests the managed EntityForm object.
|
|
1877
|
+
* @description Method initiates an asynchronous request which either ends with calling the errorCallback or with calling the callback with Javascript version of EntityForm object. See { MobileCRM.Bridge.requestObject } for further details.
|
|
1878
|
+
* @param callback The callback function that is called asynchronously with serialized EntityForm object as argument. Callback should return true to apply changed properties.
|
|
1879
|
+
* @param errorCallback The errorCallback which is called in case of error.
|
|
1880
|
+
* @param scope The scope for callbacks.
|
|
1881
|
+
*/
|
|
1726
1882
|
public static requestObject(callback: (entityForm: EntityForm) => void, errorCallback: (err?: string) => void, scope?: any);
|
|
1727
1883
|
/**
|
|
1728
|
-
|
|
1729
|
-
|
|
1884
|
+
* Reloads the form edit state.
|
|
1885
|
+
*/
|
|
1730
1886
|
public static refreshForm();
|
|
1731
1887
|
/**
|
|
1732
|
-
|
|
1733
|
-
|
|
1734
|
-
|
|
1735
|
-
|
|
1736
|
-
|
|
1888
|
+
* Binds or unbinds the handler for onSave event on EntityForm.
|
|
1889
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
1890
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1891
|
+
* @param scope The scope for callbacks.
|
|
1892
|
+
*/
|
|
1737
1893
|
public static onSave(handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1738
1894
|
/**
|
|
1739
|
-
|
|
1740
|
-
|
|
1741
|
-
|
|
1742
|
-
|
|
1743
|
-
|
|
1895
|
+
* Binds or unbinds the handler for onChange event on EntityForm.
|
|
1896
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
1897
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1898
|
+
* @param scope The scope for callbacks.
|
|
1899
|
+
*/
|
|
1744
1900
|
public static onChange(handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1745
1901
|
/**
|
|
1746
|
-
|
|
1747
|
-
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1902
|
+
* @since 15.1
|
|
1903
|
+
* Binds or unbinds the handler for onProcessLoaded event on EntityForm.
|
|
1904
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
1905
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1906
|
+
* @param scope The scope for callbacks.
|
|
1907
|
+
*/
|
|
1752
1908
|
public static onProcessLoaded(handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1753
1909
|
/**
|
|
1754
|
-
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1910
|
+
* @since 11.2
|
|
1911
|
+
* Binds or unbinds the handler for specific item change event on EntityForm.
|
|
1912
|
+
* @param itemName The name of desired detail item (mostly logical name of the field).
|
|
1913
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
1914
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1915
|
+
* @param scope The scope for callbacks.
|
|
1916
|
+
*/
|
|
1761
1917
|
public static onItemChange(itemName: string, handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1762
1918
|
/**
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1919
|
+
*
|
|
1920
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
1921
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1922
|
+
* @param scope The scope for callbacks.
|
|
1923
|
+
*/
|
|
1768
1924
|
public static onPostSave(handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1769
1925
|
/**
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1926
|
+
* @since 9.1
|
|
1927
|
+
* Saves the form entity and its children and refreshes the form.
|
|
1928
|
+
*/
|
|
1773
1929
|
public static save();
|
|
1774
1930
|
/**
|
|
1775
|
-
|
|
1776
|
-
|
|
1931
|
+
* Saves edited entity and closes the form.
|
|
1932
|
+
*/
|
|
1777
1933
|
public static saveAndClose();
|
|
1778
1934
|
/**
|
|
1779
|
-
|
|
1780
|
-
|
|
1935
|
+
* Closes the form ignoring all changes that have been made on it.
|
|
1936
|
+
*/
|
|
1781
1937
|
public static closeWithoutSaving();
|
|
1782
1938
|
/**
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
public static executeCommandByName(
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1939
|
+
* @since 8.1
|
|
1940
|
+
* Execute the command with the passed name. The command must exist and must be enabled.
|
|
1941
|
+
* @param command
|
|
1942
|
+
* @param callback The callback function that is called asynchronously in case of success.
|
|
1943
|
+
* @param errorCallback The errorCallback which is called in case of error.
|
|
1944
|
+
* @param scope The scope for callbacks.
|
|
1945
|
+
*/
|
|
1946
|
+
public static executeCommandByName(
|
|
1947
|
+
command: string,
|
|
1948
|
+
callback: (entityForm: EntityForm) => void,
|
|
1949
|
+
errorCallback?: (err: string) => void,
|
|
1950
|
+
scope?: any
|
|
1951
|
+
);
|
|
1952
|
+
/**
|
|
1953
|
+
* Binds or unbinds the handler for EntityForm command.
|
|
1954
|
+
* @param command The name of the EntityForm command.
|
|
1955
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
1956
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1957
|
+
* @param scope The scope for callbacks.
|
|
1958
|
+
*/
|
|
1798
1959
|
public static onCommand(command: string, handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1799
1960
|
/**
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1961
|
+
* Binds or unbinds the handler called when the EntityForm needs to find out whether the command can be executed (is enabled).
|
|
1962
|
+
* @param command The name of the EntityForm command. Optionally can contain the param value separated by slash (e.g. ChangeStatus/5).
|
|
1963
|
+
* @param handler The handler function that has to be bound or unbound. Handler return value indicates whether the command is enabled (true/false).
|
|
1964
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
1965
|
+
* @param scope The scope for callbacks.
|
|
1966
|
+
*/
|
|
1806
1967
|
public static onCanExecuteCommand(command: string, handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1807
1968
|
/**
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1969
|
+
* Enables or disables the form command.
|
|
1970
|
+
* @param command The name of the command.
|
|
1971
|
+
* @param enable Determines whether to enable or disable the command.
|
|
1972
|
+
* @param iParam @since 9.1 Optional parameter defining the additional command parameter (like status code value for 'ChangeStatus'; command).
|
|
1973
|
+
*/
|
|
1813
1974
|
public static enableCommand(command: string, enable: boolean, iParam?: number);
|
|
1814
1975
|
/**
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1976
|
+
* Shows a please wait message, disabling the form except for the close command.
|
|
1977
|
+
* @param caption Wait message.
|
|
1978
|
+
* @returns An object representing the UI component with single method 'close';.
|
|
1979
|
+
*/
|
|
1819
1980
|
public static showPleaseWait: (caption: string) => any;
|
|
1820
1981
|
/**
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1982
|
+
* @since 8.1
|
|
1983
|
+
* Makes the passed view maximized/restored.
|
|
1984
|
+
* @param viewName The name of the view which has to be maximized/restored.
|
|
1985
|
+
* @param maximize true, to maximize the view; false, to restore it.
|
|
1986
|
+
*/
|
|
1826
1987
|
public static maximizeView(viewName: string, maximize: boolean);
|
|
1827
1988
|
/**
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1989
|
+
* @since 8.1
|
|
1990
|
+
* Makes the passed view maximized/restored.
|
|
1991
|
+
* @param viewName The name of the view which has to be maximized/restored.
|
|
1992
|
+
* @param callback Asynchronous callback which is called with Boolean result: true, if the view is maximized; false, if it is restored.
|
|
1993
|
+
* @param errorCallback The errorCallback which is called in case of error.
|
|
1994
|
+
* @param scope The scope for callbacks.
|
|
1995
|
+
*/
|
|
1835
1996
|
public static isViewMaximized(viewName: string, callback: (isMaximized: boolean) => void, errorCallback?: (err?: string) => void, scope?: any);
|
|
1836
1997
|
/**
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1998
|
+
* @since 8.2
|
|
1999
|
+
* Shows an entity edit dialog.
|
|
2000
|
+
* @param detail Detail entity {MobileCRM.DynamicEntity}.
|
|
2001
|
+
* @param errorCallback The errorCallback which is called in case of error.
|
|
2002
|
+
*/
|
|
1842
2003
|
public static openSalesEntityDetail(detail: MobileCRM.DynamicEntity, errorCallback: (err?: string) => void);
|
|
1843
2004
|
/**
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
2005
|
+
* @ since 9.3
|
|
2006
|
+
* Binds or unbinds the handler for onSelectedViewChanged event on EntityForm.
|
|
2007
|
+
* @description Bound handler is called with the EntityForm object as an argument. The EntityForm context object contains 'selectedView' property with the name of currently selected view.
|
|
2008
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2009
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2010
|
+
* @param scope The scope for callbacks.
|
|
2011
|
+
*/
|
|
1851
2012
|
public static onSelectedViewChanged(handler: (entityForm: EntityForm) => void, bind: boolean, scope?: any);
|
|
1852
2013
|
}
|
|
1853
2014
|
interface IFormSaveHandler {
|
|
@@ -1993,7 +2154,14 @@ declare module MobileCRM.UI {
|
|
|
1993
2154
|
* @param errorCallback The errorCallback which is called in case of error.
|
|
1994
2155
|
* @param scope The scope for callback calls.
|
|
1995
2156
|
*/
|
|
1996
|
-
public static setEntityProperty(
|
|
2157
|
+
public static setEntityProperty(
|
|
2158
|
+
rowIndex: number,
|
|
2159
|
+
propertyName: string,
|
|
2160
|
+
editValue: any,
|
|
2161
|
+
saveImmediately: boolean,
|
|
2162
|
+
errorCallback?: (errorCallback: string) => void,
|
|
2163
|
+
scope?: any
|
|
2164
|
+
);
|
|
1997
2165
|
/**
|
|
1998
2166
|
* @since 10.1
|
|
1999
2167
|
* Starts the editing of a list cell.
|
|
@@ -2004,7 +2172,14 @@ declare module MobileCRM.UI {
|
|
|
2004
2172
|
* @param errorCallback The errorCallback which is called in case of error.
|
|
2005
2173
|
* @param scope The scope for callback calls.
|
|
2006
2174
|
*/
|
|
2007
|
-
public static startEditCell(
|
|
2175
|
+
public static startEditCell(
|
|
2176
|
+
rowIndex: number,
|
|
2177
|
+
cellIndex: number,
|
|
2178
|
+
saveImmediately: boolean,
|
|
2179
|
+
binding?: number,
|
|
2180
|
+
errorCallback?: (errorCallback: string) => void,
|
|
2181
|
+
scope?: any
|
|
2182
|
+
);
|
|
2008
2183
|
/**
|
|
2009
2184
|
* @since 10.1
|
|
2010
2185
|
* Simulates click on a clickable list cell.
|
|
@@ -2109,7 +2284,7 @@ declare module MobileCRM.UI {
|
|
|
2109
2284
|
Editable = 0x1000,
|
|
2110
2285
|
Clickable = 0x2000,
|
|
2111
2286
|
DirectEdit = 0x4000 | Editable,
|
|
2112
|
-
ActionMask =
|
|
2287
|
+
ActionMask = 0xf000,
|
|
2113
2288
|
}
|
|
2114
2289
|
|
|
2115
2290
|
class ListDataSource {
|
|
@@ -2163,9 +2338,9 @@ declare module MobileCRM.UI {
|
|
|
2163
2338
|
context: any;
|
|
2164
2339
|
|
|
2165
2340
|
/**
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2341
|
+
* Stops the onSave validation and optionally causes an error message to be displayed.
|
|
2342
|
+
* @param errorMsg An error message to be displayed or "null" to cancel the validation without message.
|
|
2343
|
+
*/
|
|
2169
2344
|
cancelValidation(errorMsg: string);
|
|
2170
2345
|
/**
|
|
2171
2346
|
* Returns the question item with given name.
|
|
@@ -2201,12 +2376,12 @@ declare module MobileCRM.UI {
|
|
|
2201
2376
|
|
|
2202
2377
|
public static requestObject(callback: (questionnaireForm: QuestionnaireForm) => void, errorCallback?: (err: string) => void, scope?: any);
|
|
2203
2378
|
/**
|
|
2204
|
-
|
|
2205
|
-
|
|
2206
|
-
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
|
|
2379
|
+
* Asynchronously sets the answer value for this question.
|
|
2380
|
+
* @param questionName The name of the question that has to be answered.
|
|
2381
|
+
* @param value A value that has to be set as answer. It must correspond to the type of that question.
|
|
2382
|
+
* @param errorCallback A callback which is called in case of error.
|
|
2383
|
+
* @param scope A scope for calling the callbacks.
|
|
2384
|
+
*/
|
|
2210
2385
|
public static trySetAnswer(questionName: string, answer: any, errorCallback?: (err: string) => void, scope?: any);
|
|
2211
2386
|
/**
|
|
2212
2387
|
* Asynchronously sets the image as answer value for this question
|
|
@@ -2214,25 +2389,37 @@ declare module MobileCRM.UI {
|
|
|
2214
2389
|
* @param base64Data A value that us used to create image answer.
|
|
2215
2390
|
* @param mimeType The valid mime type of corresponding base64Data.
|
|
2216
2391
|
* @param errorCallback A callback which is called in case of error.
|
|
2217
|
-
|
|
2392
|
+
* @param scope A scope for calling the callbacks.
|
|
2218
2393
|
*/
|
|
2219
|
-
public static trySetImageAnswer(
|
|
2394
|
+
public static trySetImageAnswer(
|
|
2395
|
+
imageQuestionName: string,
|
|
2396
|
+
base64Data: string,
|
|
2397
|
+
mimeType: string,
|
|
2398
|
+
errorCallback?: (err: string) => void,
|
|
2399
|
+
scope?: any
|
|
2400
|
+
);
|
|
2220
2401
|
/**
|
|
2221
2402
|
* Asynchronously sets the the focus on given question.
|
|
2222
2403
|
* @param questionName A name of the question.
|
|
2223
|
-
|
|
2224
|
-
|
|
2404
|
+
* @param errorCallback A callback which is called in case of error.
|
|
2405
|
+
* @param scope A scope for calling the callbacks.
|
|
2225
2406
|
*/
|
|
2226
2407
|
public static focusQuestion(questionName: string, errorCallback?: (err: string) => void, scope?: any);
|
|
2227
2408
|
/**
|
|
2228
|
-
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
public static overridePicklistOptions(
|
|
2409
|
+
* Overrides the list of options for given picklist question.
|
|
2410
|
+
* @param questionName The name of the picklist question.
|
|
2411
|
+
* @param allowNull Indicates whether the empty answer is allowed.
|
|
2412
|
+
* @param options An object with label-to-value mappings, e.g. {'Option 1':1,'Option 2':2}.
|
|
2413
|
+
* @param errorCallback A callback which is called in case of error.
|
|
2414
|
+
* @param scope A scope for calling the callbacks.
|
|
2415
|
+
*/
|
|
2416
|
+
public static overridePicklistOptions(
|
|
2417
|
+
questionName: string,
|
|
2418
|
+
allowNull: boolean,
|
|
2419
|
+
options: QuestionnaireForm.IPicklistDataSource,
|
|
2420
|
+
errorCallback?: (err: string) => void,
|
|
2421
|
+
scope?: any
|
|
2422
|
+
);
|
|
2236
2423
|
/**
|
|
2237
2424
|
* Sets the views and filters for specified lookup question.
|
|
2238
2425
|
* @param questionName The name of the lookup question.
|
|
@@ -2242,7 +2429,14 @@ declare module MobileCRM.UI {
|
|
|
2242
2429
|
* @param errorCallback A callback which is called in case of error.
|
|
2243
2430
|
* @param scope A scope for calling the callbacks.
|
|
2244
2431
|
*/
|
|
2245
|
-
public static changeLookupQuestionSetup(
|
|
2432
|
+
public static changeLookupQuestionSetup(
|
|
2433
|
+
questionName: string,
|
|
2434
|
+
dialogSetup: DetailViewItems.LookupSetup,
|
|
2435
|
+
inlinePickSetup: DetailViewItems.LookupSetup,
|
|
2436
|
+
dialogOnly: boolean,
|
|
2437
|
+
errorCallback?: (err: string) => void,
|
|
2438
|
+
scope?: any
|
|
2439
|
+
);
|
|
2246
2440
|
/**
|
|
2247
2441
|
* Duplicates repeatable group with all its questions. The name of the group will contain the lowest available repeatIndex and suffix in form #00X.
|
|
2248
2442
|
* @param id Id of the source group
|
|
@@ -2260,47 +2454,47 @@ declare module MobileCRM.UI {
|
|
|
2260
2454
|
public static deleteGroup(id: string, errorCallback?: (err: string) => void, scope?: any);
|
|
2261
2455
|
|
|
2262
2456
|
/**
|
|
2263
|
-
|
|
2264
|
-
|
|
2265
|
-
|
|
2266
|
-
|
|
2267
|
-
|
|
2457
|
+
* Binds or unbinds the handler for onSave event on QuestionnaireForm.
|
|
2458
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2459
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2460
|
+
* @param scope The scope for callbacks.
|
|
2461
|
+
*/
|
|
2268
2462
|
public static onSave(handler: (questionnaireForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2269
2463
|
/**
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2464
|
+
* Binds or unbinds the handler for onChange event on QuestionnaireForm.
|
|
2465
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2466
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2467
|
+
* @param scope The scope for callbacks.
|
|
2468
|
+
*/
|
|
2275
2469
|
public static onChange(handler: (questionnaireForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2276
2470
|
/**
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2471
|
+
* @since 11.2
|
|
2472
|
+
* Binds or unbinds the handler for specific question change event on QuestionnaireForm.
|
|
2473
|
+
* @param questionName The name of desired question.
|
|
2474
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2475
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2476
|
+
* @param scope The scope for callbacks.
|
|
2477
|
+
*/
|
|
2284
2478
|
public static onAnswerChanged(questionName: string, handler: (questionnaireForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2285
2479
|
/**
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2480
|
+
* Binds or unbinds the handler for onPostSave event on QuestionnaireForm.
|
|
2481
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2482
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2483
|
+
* @param scope The scope for callbacks.
|
|
2484
|
+
*/
|
|
2291
2485
|
public static onPostSave(handler: (questionnaireForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2292
2486
|
/**
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2296
|
-
|
|
2487
|
+
* Binds or unbinds the handler for onRepeatGroup event on QuestionnaireForm.
|
|
2488
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2489
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2490
|
+
* @param scope The scope for callbacks.
|
|
2297
2491
|
*/
|
|
2298
2492
|
public static onRepeatGroup(handler: (questionnaireForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2299
2493
|
/**
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2303
|
-
|
|
2494
|
+
* Binds or unbinds the handler for onDeleteGroup event on QuestionnaireForm.
|
|
2495
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2496
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2497
|
+
* @param scope The scope for callbacks.
|
|
2304
2498
|
*/
|
|
2305
2499
|
public static onDeleteGroup(handler: (questionnaireForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2306
2500
|
/**
|
|
@@ -2311,24 +2505,24 @@ declare module MobileCRM.UI {
|
|
|
2311
2505
|
*/
|
|
2312
2506
|
public static getQuestionnaireEntity(handler: (entity: DynamicEntity) => boolean, errorCallback?: (err: string) => void, scope?: any);
|
|
2313
2507
|
/**
|
|
2314
|
-
|
|
2315
|
-
|
|
2508
|
+
* Saves the form entity and its children and refreshes the form.
|
|
2509
|
+
*/
|
|
2316
2510
|
public static save();
|
|
2317
2511
|
/**
|
|
2318
|
-
|
|
2319
|
-
|
|
2512
|
+
* Saves edited entity and closes the form.
|
|
2513
|
+
*/
|
|
2320
2514
|
public static saveAndClose();
|
|
2321
2515
|
/**
|
|
2322
|
-
|
|
2323
|
-
|
|
2516
|
+
* Closes the form ignoring all changes that have been made on it.
|
|
2517
|
+
*/
|
|
2324
2518
|
public static closeWithoutSaving();
|
|
2325
2519
|
/**
|
|
2326
|
-
|
|
2327
|
-
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2520
|
+
* Binds or unbinds the handler for QuestionnaireForm command.
|
|
2521
|
+
* @param command The name of the QuestionnaireForm command.
|
|
2522
|
+
* @param handler The handler function that has to be bound or unbound.
|
|
2523
|
+
* @param bind Determines whether to bind or unbind the handler.
|
|
2524
|
+
* @param scope The scope for callbacks.
|
|
2525
|
+
*/
|
|
2332
2526
|
public static onCommand(command: string, handler: (entityForm: QuestionnaireForm) => void, bind: boolean, scope?: any);
|
|
2333
2527
|
}
|
|
2334
2528
|
|
|
@@ -2366,11 +2560,11 @@ declare module MobileCRM.UI {
|
|
|
2366
2560
|
errorMessage: string;
|
|
2367
2561
|
|
|
2368
2562
|
/**
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2563
|
+
* Asynchronously sets the answer value for this question.
|
|
2564
|
+
* @param value A value that has to be set as answer. It must correspond to the type of this question.
|
|
2565
|
+
* @param errorCallback A callback which is called in case of error.
|
|
2566
|
+
* @param scope A scope for calling the callbacks.
|
|
2567
|
+
*/
|
|
2374
2568
|
trySetAnswer(value: any, errorCallback?: (err: string) => void, scope?: any);
|
|
2375
2569
|
}
|
|
2376
2570
|
|
|
@@ -2433,7 +2627,14 @@ declare module MobileCRM.UI {
|
|
|
2433
2627
|
static hideUIReplacement();
|
|
2434
2628
|
static onSyncFinished(handler: (homeForm: HomeForm) => void, scope?: any);
|
|
2435
2629
|
|
|
2436
|
-
static updateHomeItemAsync(
|
|
2630
|
+
static updateHomeItemAsync(
|
|
2631
|
+
items: string[],
|
|
2632
|
+
title?: string,
|
|
2633
|
+
subTitle?: string,
|
|
2634
|
+
badge?: string,
|
|
2635
|
+
errorCallback?: (err: string) => void,
|
|
2636
|
+
scope?: any
|
|
2637
|
+
);
|
|
2437
2638
|
static updateHomeItems(items: IHomeItem[]);
|
|
2438
2639
|
}
|
|
2439
2640
|
|
|
@@ -2471,7 +2672,17 @@ declare module MobileCRM.UI {
|
|
|
2471
2672
|
defaultReport: string;
|
|
2472
2673
|
|
|
2473
2674
|
show(success: (obj: any) => void, failed?: (err: string) => void, scope?: any);
|
|
2474
|
-
runReport(
|
|
2675
|
+
runReport(
|
|
2676
|
+
fetch: string,
|
|
2677
|
+
reportXML: string,
|
|
2678
|
+
reportFormat: string,
|
|
2679
|
+
isExportOnly: boolean,
|
|
2680
|
+
isOnline: boolean,
|
|
2681
|
+
outputFile: string,
|
|
2682
|
+
success: (filePath: string) => void,
|
|
2683
|
+
failed?: (err: string) => void,
|
|
2684
|
+
scope?: any
|
|
2685
|
+
);
|
|
2475
2686
|
}
|
|
2476
2687
|
|
|
2477
2688
|
class Form {
|
|
@@ -2508,18 +2719,18 @@ declare module MobileCRM.UI {
|
|
|
2508
2719
|
*/
|
|
2509
2720
|
changeProccess(callback: (processReference: MobileCRM.Reference) => void, errorCallback?: (err: string) => void, scope?: any);
|
|
2510
2721
|
/**
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2722
|
+
* @since 15.0
|
|
2723
|
+
* Progresses to the next stage of the active process.
|
|
2724
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error
|
|
2725
|
+
* @param scope The scope for callback.
|
|
2726
|
+
*/
|
|
2516
2727
|
MoveToPreviousStage(errorCallback?: (err: string) => void, scope?: any);
|
|
2517
2728
|
/**
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2729
|
+
* @since 15.0
|
|
2730
|
+
* Moves to the previous stage of the active process.
|
|
2731
|
+
* @param errorCallback The errorCallback which is called asynchronously in case of error
|
|
2732
|
+
* @param scope The scope for callback.
|
|
2733
|
+
*/
|
|
2523
2734
|
MoveToNextStage(errorCallback?: (err: string) => void, scope?: any);
|
|
2524
2735
|
}
|
|
2525
2736
|
|
|
@@ -2531,10 +2742,15 @@ declare module MobileCRM.UI {
|
|
|
2531
2742
|
version: number;
|
|
2532
2743
|
buttons: Array<string>;
|
|
2533
2744
|
selector: string;
|
|
2534
|
-
templates: Array<any
|
|
2745
|
+
templates: Array<any>;
|
|
2535
2746
|
entityLabel: string;
|
|
2536
2747
|
|
|
2537
|
-
public static loadEntityViews(
|
|
2748
|
+
public static loadEntityViews(
|
|
2749
|
+
entityName: string,
|
|
2750
|
+
callback: (viewDefinitions: Array<ViewDefinition>) => void,
|
|
2751
|
+
errorCallback?: (err: string) => void,
|
|
2752
|
+
scope?: any
|
|
2753
|
+
);
|
|
2538
2754
|
}
|
|
2539
2755
|
|
|
2540
2756
|
class MessageBox {
|
|
@@ -2686,7 +2902,7 @@ declare module MobileCRM.UI {
|
|
|
2686
2902
|
/** Saves to file to disk.*/
|
|
2687
2903
|
Export = 0x8000000,
|
|
2688
2904
|
/** Actions that are non-destructive.*/
|
|
2689
|
-
ReadOnlyMask = SendTo | View | OpenExternal | Print | Email | Copy | Export
|
|
2905
|
+
ReadOnlyMask = SendTo | View | OpenExternal | Print | Email | Copy | Export,
|
|
2690
2906
|
}
|
|
2691
2907
|
|
|
2692
2908
|
interface _Controller {
|
|
@@ -2980,8 +3196,19 @@ declare module MobileCRM.UI.EntityForm {
|
|
|
2980
3196
|
static getAsync(index: number): Promise<MobileCRM.DynamicEntity>;
|
|
2981
3197
|
static deleteByIndex(index: number, callback: () => void, errorCallback?: (error: string) => void, scope?: any);
|
|
2982
3198
|
static deleteById(orderDetailId: string, callback: () => void, errorCallback?: (error: string) => void, scope?: any);
|
|
2983
|
-
static add(
|
|
2984
|
-
|
|
3199
|
+
static add(
|
|
3200
|
+
product: MobileCRM.Reference,
|
|
3201
|
+
callback: (details: MobileCRM.DynamicEntity) => void,
|
|
3202
|
+
errorCallback?: (error: string) => void,
|
|
3203
|
+
scope?: any
|
|
3204
|
+
);
|
|
3205
|
+
static addProductWithQuantity(
|
|
3206
|
+
product: MobileCRM.Reference,
|
|
3207
|
+
quantity: number,
|
|
3208
|
+
callback: (details: MobileCRM.DynamicEntity) => void,
|
|
3209
|
+
errorCallback?: (error: string) => void,
|
|
3210
|
+
scope?: any
|
|
3211
|
+
);
|
|
2985
3212
|
static onChange(handler: (entityForm: MobileCRM.UI.EntityForm) => void, bind: boolean, scope?: any);
|
|
2986
3213
|
static onSelectedViewChanged(handler: (entityForm: MobileCRM.UI.EntityForm) => void, bind: boolean, scope?: any);
|
|
2987
3214
|
}
|
|
@@ -3001,8 +3228,7 @@ declare module MobileCRM.UI.DetailViewItems {
|
|
|
3001
3228
|
validate: boolean;
|
|
3002
3229
|
style: string;
|
|
3003
3230
|
}
|
|
3004
|
-
class SeparatorItem extends Item {
|
|
3005
|
-
}
|
|
3231
|
+
class SeparatorItem extends Item {}
|
|
3006
3232
|
class TextBoxItem extends Item {
|
|
3007
3233
|
isPassword: boolean;
|
|
3008
3234
|
kind: number;
|
|
@@ -3027,8 +3253,7 @@ declare module MobileCRM.UI.DetailViewItems {
|
|
|
3027
3253
|
parts: Number;
|
|
3028
3254
|
value: Date;
|
|
3029
3255
|
}
|
|
3030
|
-
class DurationItem extends Item {
|
|
3031
|
-
}
|
|
3256
|
+
class DurationItem extends Item {}
|
|
3032
3257
|
class ComboBoxItem extends Item {
|
|
3033
3258
|
listDataSource: any;
|
|
3034
3259
|
}
|
|
@@ -3078,7 +3303,7 @@ declare module MobileCRM.UI.DetailViewItems {
|
|
|
3078
3303
|
/**Multi string list format.*/
|
|
3079
3304
|
MultiStringList = 19,
|
|
3080
3305
|
/**Multi string list with input format */
|
|
3081
|
-
MultiStringListInput = 20
|
|
3306
|
+
MultiStringListInput = 20,
|
|
3082
3307
|
}
|
|
3083
3308
|
class GridItem extends MobileCRM.UI.DetailViewItems.Item {
|
|
3084
3309
|
/**
|
|
@@ -3108,8 +3333,8 @@ declare module MobileCRM.UI.DetailViewItems {
|
|
|
3108
3333
|
* @param rows Defines the rows style.
|
|
3109
3334
|
*/
|
|
3110
3335
|
constructor(columns: Array<DetailGridLength>, rows: Array<DetailGridLength>);
|
|
3111
|
-
columns: Array<DetailGridLength
|
|
3112
|
-
rows: Array<DetailGridLength
|
|
3336
|
+
columns: Array<DetailGridLength>;
|
|
3337
|
+
rows: Array<DetailGridLength>;
|
|
3113
3338
|
}
|
|
3114
3339
|
class DetailGridLength {
|
|
3115
3340
|
/**
|
|
@@ -3126,6 +3351,6 @@ declare module MobileCRM.UI.DetailViewItems {
|
|
|
3126
3351
|
/**Gets absolute pixel unit type.*/
|
|
3127
3352
|
pixel = 1,
|
|
3128
3353
|
/**Gets relative unit type.*/
|
|
3129
|
-
star = 2
|
|
3354
|
+
star = 2,
|
|
3130
3355
|
}
|
|
3131
|
-
}
|
|
3356
|
+
}
|