arco-support-request 0.0.88 → 0.0.90
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/arco-support-request.metadata.json +1 -1
- package/bundles/arco-support-request.umd.js +177 -104
- package/bundles/arco-support-request.umd.js.map +1 -1
- package/bundles/arco-support-request.umd.min.js +1 -1
- package/bundles/arco-support-request.umd.min.js.map +1 -1
- package/esm2015/lib/core/global.service.js +45 -15
- package/esm2015/lib/core/handlebar-helper-register.js +30 -1
- package/esm2015/lib/entity-type-setup/activities-create/activities-create.component.js +4 -2
- package/esm2015/lib/entity-type-setup/activities-view/activities-view.component.js +4 -1
- package/esm2015/lib/entity-type-setup/dynamic/dynamic-details-view/dynamic-details-view.component.js +7 -1
- package/esm2015/lib/entity-type-setup/dynamic/entity-dynamic-view/entity-dynamic-view.component.js +23 -3
- package/esm2015/lib/entity-type-setup/service/entity-type-setup.service.js +29 -6
- package/esm2015/lib/entity-type-setup/workflow-dynamic-popup/workflow-dynamic-popup.component.js +3 -2
- package/esm2015/lib/support-request/case-list/case-list.component.js +13 -24
- package/esm2015/lib/support-request/request-flow/request-flow.component.js +10 -20
- package/esm2015/lib/support-request/self-service-flow/self-service-flow.component.js +3 -5
- package/esm2015/lib/support-request/support-request-create/support-request-create.component.js +5 -2
- package/esm2015/lib/support-request/support-request-details/support-request-details.component.js +10 -38
- package/esm2015/lib/templates/grid/grid-service.service.js +13 -1
- package/esm2015/lib/templates/interface_enum/common-Interface.js +1 -1
- package/fesm2015/arco-support-request.js +173 -100
- package/fesm2015/arco-support-request.js.map +1 -1
- package/lib/entity-type-setup/service/entity-type-setup.service.d.ts +2 -1
- package/lib/support-request/case-list/case-list.component.d.ts +1 -1
- package/lib/templates/grid/grid-service.service.d.ts +1 -0
- package/lib/templates/interface_enum/common-Interface.d.ts +1 -0
- package/package.json +1 -1
|
@@ -782,6 +782,18 @@
|
|
|
782
782
|
});
|
|
783
783
|
}
|
|
784
784
|
return temparr;
|
|
785
|
+
}
|
|
786
|
+
function GetFormattedDateWithTime(_date) {
|
|
787
|
+
var todayTime = new Date(_date);
|
|
788
|
+
var month = (todayTime.getMonth() + 1);
|
|
789
|
+
month = month > 9 ? month : "0" + month;
|
|
790
|
+
var day = todayTime.getDate() > 9 ? todayTime.getDate() : "0" + todayTime.getDate();
|
|
791
|
+
var year = todayTime.getFullYear();
|
|
792
|
+
var Hours = todayTime.getHours() > 9 ? todayTime.getHours() : "0" + todayTime.getHours();
|
|
793
|
+
var min = todayTime.getMinutes() > 9 ? todayTime.getMinutes() : "0" + todayTime.getMinutes();
|
|
794
|
+
var sec = todayTime.getSeconds() > 9 ? todayTime.getSeconds() : "0" + todayTime.getSeconds();
|
|
795
|
+
return year + '-' + month + '-' + day + "T" + Hours + ":" + min + ":" + sec + ".000Z";
|
|
796
|
+
// "2022-01-23T09:04:45.904Z"
|
|
785
797
|
}
|
|
786
798
|
|
|
787
799
|
var JWT = {
|
|
@@ -2551,20 +2563,50 @@
|
|
|
2551
2563
|
{ type: i1$1.HttpClient }
|
|
2552
2564
|
]; };
|
|
2553
2565
|
function errorMessageType(error) {
|
|
2554
|
-
|
|
2555
|
-
|
|
2556
|
-
error
|
|
2557
|
-
|
|
2558
|
-
|
|
2559
|
-
|
|
2560
|
-
|
|
2561
|
-
|
|
2562
|
-
|
|
2563
|
-
|
|
2564
|
-
|
|
2565
|
-
|
|
2566
|
-
|
|
2567
|
-
|
|
2566
|
+
var _a, _b, _c, _d, _e;
|
|
2567
|
+
try {
|
|
2568
|
+
if (error &&
|
|
2569
|
+
error.error &&
|
|
2570
|
+
error.error.Errors &&
|
|
2571
|
+
error.error.Errors.length > 0)
|
|
2572
|
+
return error.error.Errors.map(function (x) { return x.ErrorMessage; }).join('\n');
|
|
2573
|
+
else if (error && error.error && error.error.Message)
|
|
2574
|
+
return error.error.Message;
|
|
2575
|
+
else if (typeof error.error == 'string')
|
|
2576
|
+
return error.error;
|
|
2577
|
+
else if (((_a = error.error) === null || _a === void 0 ? void 0 : _a.status) == false) {
|
|
2578
|
+
try {
|
|
2579
|
+
var msg = JSON.parse((_b = error.error) === null || _b === void 0 ? void 0 : _b.msg);
|
|
2580
|
+
if (msg && msg.msg) {
|
|
2581
|
+
msg = msg.msg;
|
|
2582
|
+
}
|
|
2583
|
+
else {
|
|
2584
|
+
msg = (_c = error.error) === null || _c === void 0 ? void 0 : _c.msg;
|
|
2585
|
+
}
|
|
2586
|
+
return msg;
|
|
2587
|
+
}
|
|
2588
|
+
catch (err) {
|
|
2589
|
+
var msg = ((_d = error.error) === null || _d === void 0 ? void 0 : _d.msg);
|
|
2590
|
+
if (msg && msg.msg) {
|
|
2591
|
+
msg = msg.msg;
|
|
2592
|
+
}
|
|
2593
|
+
else {
|
|
2594
|
+
msg = (_e = error.error) === null || _e === void 0 ? void 0 : _e.msg;
|
|
2595
|
+
}
|
|
2596
|
+
return msg;
|
|
2597
|
+
}
|
|
2598
|
+
}
|
|
2599
|
+
else if (typeof error.error == "object") {
|
|
2600
|
+
return JSON.stringify(error.error);
|
|
2601
|
+
}
|
|
2602
|
+
else if (error.message)
|
|
2603
|
+
return error.message;
|
|
2604
|
+
else {
|
|
2605
|
+
console.log(error);
|
|
2606
|
+
}
|
|
2607
|
+
}
|
|
2608
|
+
catch (err) {
|
|
2609
|
+
return "Error,Contact system admin";
|
|
2568
2610
|
}
|
|
2569
2611
|
}
|
|
2570
2612
|
|
|
@@ -3108,30 +3150,46 @@
|
|
|
3108
3150
|
EntityTypeSetupService.prototype.dynamicAPi = function (restData, FormValues, searchCriteria, SearchText, isHavecriteria) {
|
|
3109
3151
|
// alert('get service');
|
|
3110
3152
|
var params = this.setparameter(restData.QueryStrings, FormValues, SearchText, isHavecriteria);
|
|
3153
|
+
var headers = this.setHeaders(restData.Headers, FormValues);
|
|
3111
3154
|
var parameter = this.getArraycolumn(params);
|
|
3112
3155
|
var _url = restData.URL + parameter;
|
|
3113
3156
|
// searchCriteria = this.setCriteriaField(restData.QueryStrings,FormValues,searchCriteria)
|
|
3157
|
+
var _responseType = restData.ResponseType ? restData.ResponseType : 'json';
|
|
3114
3158
|
switch (restData.Method) {
|
|
3115
3159
|
case 'GET': {
|
|
3116
3160
|
return this.http.get(_url, {
|
|
3117
3161
|
params: CriteriaBuilder(searchCriteria),
|
|
3162
|
+
responseType: _responseType,
|
|
3163
|
+
headers: headers
|
|
3118
3164
|
});
|
|
3119
3165
|
break;
|
|
3120
3166
|
}
|
|
3121
3167
|
case 'POST': {
|
|
3122
|
-
return this.http.post(_url, restData.Body
|
|
3168
|
+
return this.http.post(_url, restData.Body, {
|
|
3169
|
+
responseType: _responseType,
|
|
3170
|
+
headers: headers
|
|
3171
|
+
});
|
|
3123
3172
|
break;
|
|
3124
3173
|
}
|
|
3125
3174
|
case 'PUT': {
|
|
3126
|
-
return this.http.put(_url, restData.Body
|
|
3175
|
+
return this.http.put(_url, restData.Body, {
|
|
3176
|
+
responseType: _responseType,
|
|
3177
|
+
headers: headers
|
|
3178
|
+
});
|
|
3127
3179
|
break;
|
|
3128
3180
|
}
|
|
3129
3181
|
case 'DELETE': {
|
|
3130
|
-
return this.http.delete(_url
|
|
3182
|
+
return this.http.delete(_url, {
|
|
3183
|
+
responseType: _responseType,
|
|
3184
|
+
headers: headers
|
|
3185
|
+
});
|
|
3131
3186
|
break;
|
|
3132
3187
|
}
|
|
3133
3188
|
default: {
|
|
3134
|
-
return this.http.get(_url
|
|
3189
|
+
return this.http.get(_url, {
|
|
3190
|
+
responseType: _responseType,
|
|
3191
|
+
headers: headers
|
|
3192
|
+
});
|
|
3135
3193
|
}
|
|
3136
3194
|
}
|
|
3137
3195
|
};
|
|
@@ -3179,6 +3237,13 @@
|
|
|
3179
3237
|
else
|
|
3180
3238
|
return '';
|
|
3181
3239
|
};
|
|
3240
|
+
EntityTypeSetupService.prototype.setHeaders = function (header, FormValues) {
|
|
3241
|
+
var headers = new i1$1.HttpHeaders();
|
|
3242
|
+
header.forEach(function (element) {
|
|
3243
|
+
headers = headers.set(element.Name, element.Type == 'FieldValue' ? FormValues[element.Value] : element.Value);
|
|
3244
|
+
});
|
|
3245
|
+
return headers;
|
|
3246
|
+
};
|
|
3182
3247
|
EntityTypeSetupService.prototype.getDyamicUrl = function (url) {
|
|
3183
3248
|
var _url = environment.ServerUrl + "/" + url;
|
|
3184
3249
|
return this.http.get(_url);
|
|
@@ -5248,9 +5313,7 @@
|
|
|
5248
5313
|
_this.getPageCount();
|
|
5249
5314
|
}, function (error) {
|
|
5250
5315
|
console.log(error);
|
|
5251
|
-
Swal__default['default'].fire(
|
|
5252
|
-
title: _this.translatePipe.transform(error.error),
|
|
5253
|
-
});
|
|
5316
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5254
5317
|
});
|
|
5255
5318
|
};
|
|
5256
5319
|
CaseListComponent.prototype.loadGrid = function (data, TotalRecord) {
|
|
@@ -5304,6 +5367,7 @@
|
|
|
5304
5367
|
}
|
|
5305
5368
|
}, function (error) {
|
|
5306
5369
|
console.log(error);
|
|
5370
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5307
5371
|
});
|
|
5308
5372
|
};
|
|
5309
5373
|
CaseListComponent.prototype.getActiveEntityForm = function () {
|
|
@@ -5313,6 +5377,7 @@
|
|
|
5313
5377
|
_this.getFormList();
|
|
5314
5378
|
}, function (error) {
|
|
5315
5379
|
console.log(error);
|
|
5380
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5316
5381
|
});
|
|
5317
5382
|
};
|
|
5318
5383
|
CaseListComponent.prototype.getFormList = function () {
|
|
@@ -5353,6 +5418,7 @@
|
|
|
5353
5418
|
CaseListComponent.prototype.closePopupCreateView = function (Type, Data) {
|
|
5354
5419
|
this.CreateItemId = null;
|
|
5355
5420
|
this.isShowCreateRequest = false;
|
|
5421
|
+
this.openDetailsPopup(Data, true);
|
|
5356
5422
|
};
|
|
5357
5423
|
CaseListComponent.prototype.getPaginationListData = function (pageNo, pageSize) {
|
|
5358
5424
|
this.pageNo = pageNo;
|
|
@@ -5367,11 +5433,14 @@
|
|
|
5367
5433
|
CaseListComponent.prototype.getPageCount = function () {
|
|
5368
5434
|
this.pageCount = Math.ceil(this.totalRecordCount / this.pageSize);
|
|
5369
5435
|
};
|
|
5370
|
-
CaseListComponent.prototype.openDetailsPopup = function (data) {
|
|
5436
|
+
CaseListComponent.prototype.openDetailsPopup = function (data, afterCreate) {
|
|
5371
5437
|
this.isDetails = true;
|
|
5372
5438
|
this.CaseId = data.CaseId;
|
|
5373
5439
|
this.detailsRecId = data.RecId; // RefRecId is the main recid
|
|
5374
5440
|
this.detailsEntityTypeRecId = data.EntityTypeRecId;
|
|
5441
|
+
if (afterCreate) {
|
|
5442
|
+
this.detailsEntityTypeRecId = ((data === null || data === void 0 ? void 0 : data.EntityTypeId) ? data.EntityTypeId : this.EntityTypeId);
|
|
5443
|
+
}
|
|
5375
5444
|
this.supportService.IsShowBackBtn = true;
|
|
5376
5445
|
this.displayPopupDetailView = true;
|
|
5377
5446
|
};
|
|
@@ -5441,9 +5510,8 @@
|
|
|
5441
5510
|
_this.selectStage(_this.StatusAndStageList[0]);
|
|
5442
5511
|
console.log(res.Data);
|
|
5443
5512
|
}, function (error) {
|
|
5444
|
-
var _a;
|
|
5445
5513
|
console.log(error);
|
|
5446
|
-
Swal__default['default'].fire(
|
|
5514
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5447
5515
|
});
|
|
5448
5516
|
};
|
|
5449
5517
|
CaseListComponent.prototype.selectStage = function (item) {
|
|
@@ -5466,7 +5534,7 @@
|
|
|
5466
5534
|
_this.wfActionData = res;
|
|
5467
5535
|
console.log(res);
|
|
5468
5536
|
}, function (error) {
|
|
5469
|
-
|
|
5537
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5470
5538
|
});
|
|
5471
5539
|
};
|
|
5472
5540
|
CaseListComponent.prototype.getStatusField = function (data) {
|
|
@@ -5517,21 +5585,7 @@
|
|
|
5517
5585
|
_this.getListDatas(_this.Searchcriteria);
|
|
5518
5586
|
console.log(res);
|
|
5519
5587
|
}, function (error) {
|
|
5520
|
-
|
|
5521
|
-
error.error;
|
|
5522
|
-
if (((_a = error.error) === null || _a === void 0 ? void 0 : _a.status) == false) {
|
|
5523
|
-
var msg = JSON.parse((_b = error.error) === null || _b === void 0 ? void 0 : _b.msg);
|
|
5524
|
-
if (msg && msg.msg) {
|
|
5525
|
-
msg = msg.msg;
|
|
5526
|
-
}
|
|
5527
|
-
else {
|
|
5528
|
-
msg = (_c = error.error) === null || _c === void 0 ? void 0 : _c.msg;
|
|
5529
|
-
}
|
|
5530
|
-
Swal__default['default'].fire(_this.translatePipe.transform(msg));
|
|
5531
|
-
}
|
|
5532
|
-
else {
|
|
5533
|
-
Swal__default['default'].fire(_this.translatePipe.transform(error.ExceptionMessage), _this.translatePipe.transform(error.message));
|
|
5534
|
-
}
|
|
5588
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5535
5589
|
});
|
|
5536
5590
|
};
|
|
5537
5591
|
CaseListComponent.prototype.slider = function (direction, Id) {
|
|
@@ -5760,6 +5814,7 @@
|
|
|
5760
5814
|
_this.EntityFormId = res.RecId;
|
|
5761
5815
|
}, function (error) {
|
|
5762
5816
|
console.log(error);
|
|
5817
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5763
5818
|
});
|
|
5764
5819
|
};
|
|
5765
5820
|
SupportRequestDetailsComponent.prototype.getWorkflowActionComments = function (comments, updateFileds, updateFieldsObject) {
|
|
@@ -5771,21 +5826,7 @@
|
|
|
5771
5826
|
_this.getTaskDetails();
|
|
5772
5827
|
console.log(res);
|
|
5773
5828
|
}, function (error) {
|
|
5774
|
-
|
|
5775
|
-
error.error;
|
|
5776
|
-
if (((_a = error.error) === null || _a === void 0 ? void 0 : _a.status) == false) {
|
|
5777
|
-
var msg = JSON.parse((_b = error.error) === null || _b === void 0 ? void 0 : _b.msg);
|
|
5778
|
-
if (msg && msg.msg) {
|
|
5779
|
-
msg = msg.msg;
|
|
5780
|
-
}
|
|
5781
|
-
else {
|
|
5782
|
-
msg = (_c = error.error) === null || _c === void 0 ? void 0 : _c.msg;
|
|
5783
|
-
}
|
|
5784
|
-
Swal__default['default'].fire(_this.translatePipe.transform(msg));
|
|
5785
|
-
}
|
|
5786
|
-
else {
|
|
5787
|
-
Swal__default['default'].fire(_this.translatePipe.transform(error.ExceptionMessage), _this.translatePipe.transform(error.message));
|
|
5788
|
-
}
|
|
5829
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5789
5830
|
});
|
|
5790
5831
|
};
|
|
5791
5832
|
SupportRequestDetailsComponent.prototype.getComments = function () {
|
|
@@ -5797,11 +5838,7 @@
|
|
|
5797
5838
|
_this.commentsData = x.Data;
|
|
5798
5839
|
_this.commentsDataCount = x.TotalCount;
|
|
5799
5840
|
}, function (error) {
|
|
5800
|
-
|
|
5801
|
-
Swal__default['default'].fire({
|
|
5802
|
-
title: _this.translatePipe.transform(error.error),
|
|
5803
|
-
});
|
|
5804
|
-
// error.error
|
|
5841
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5805
5842
|
});
|
|
5806
5843
|
}
|
|
5807
5844
|
};
|
|
@@ -5882,9 +5919,8 @@
|
|
|
5882
5919
|
var showPendingIndex = _this.StatusAndStageList.findIndex(function (x) { return x.OrderId == 0; });
|
|
5883
5920
|
_this.StatusAndStageList.splice(showPendingIndex, 1);
|
|
5884
5921
|
}, function (error) {
|
|
5885
|
-
var _a;
|
|
5886
5922
|
console.log(error);
|
|
5887
|
-
Swal__default['default'].fire(
|
|
5923
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5888
5924
|
});
|
|
5889
5925
|
};
|
|
5890
5926
|
SupportRequestDetailsComponent.prototype.selectProcess = function (item) {
|
|
@@ -5932,21 +5968,21 @@
|
|
|
5932
5968
|
console.log('Activity', res.Data);
|
|
5933
5969
|
});
|
|
5934
5970
|
(function (error) {
|
|
5935
|
-
|
|
5971
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5936
5972
|
});
|
|
5937
5973
|
};
|
|
5938
5974
|
SupportRequestDetailsComponent.prototype.setTimeline = function () {
|
|
5939
|
-
var
|
|
5975
|
+
var _b, _c, _d;
|
|
5940
5976
|
this.TimelineList = [];
|
|
5941
5977
|
this.TimelineListReadonly = [];
|
|
5942
5978
|
if (Array.isArray(this.ActivityType)) {
|
|
5943
5979
|
if (this.ActivityType.length > 0)
|
|
5944
|
-
(
|
|
5945
|
-
(
|
|
5980
|
+
(_b = this.TimelineList).push.apply(_b, __spread(this.ActivityType));
|
|
5981
|
+
(_c = this.TimelineListReadonly).push.apply(_c, __spread(this.ActivityType));
|
|
5946
5982
|
}
|
|
5947
5983
|
if (Array.isArray(this.ActivityTypeReadonly)) {
|
|
5948
5984
|
if (this.ActivityTypeReadonly.length > 0)
|
|
5949
|
-
(
|
|
5985
|
+
(_d = this.TimelineListReadonly).push.apply(_d, __spread(this.ActivityTypeReadonly));
|
|
5950
5986
|
}
|
|
5951
5987
|
// if (Array.isArray(this.TaskList)) {
|
|
5952
5988
|
// if (this.TaskList.length > 0) this.TimelineList.push(...this.TaskList);
|
|
@@ -5990,10 +6026,9 @@
|
|
|
5990
6026
|
console.log(res);
|
|
5991
6027
|
_this.loadGrid(res.Data, res.TotalCount);
|
|
5992
6028
|
}, function (error) {
|
|
5993
|
-
var _a;
|
|
5994
6029
|
console.log(error);
|
|
5995
6030
|
_this.loadGrid([], 0);
|
|
5996
|
-
Swal__default['default'].fire(
|
|
6031
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
5997
6032
|
});
|
|
5998
6033
|
}
|
|
5999
6034
|
};
|
|
@@ -6043,7 +6078,7 @@
|
|
|
6043
6078
|
_this.wfStageAction = res;
|
|
6044
6079
|
console.log(res);
|
|
6045
6080
|
}, function (error) {
|
|
6046
|
-
|
|
6081
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6047
6082
|
});
|
|
6048
6083
|
};
|
|
6049
6084
|
SupportRequestDetailsComponent.prototype.getStatusField = function (data) {
|
|
@@ -6110,12 +6145,7 @@
|
|
|
6110
6145
|
_this.closeModelPopup();
|
|
6111
6146
|
_this.taskService.showCommentPopup = false;
|
|
6112
6147
|
_this.taskService.close();
|
|
6113
|
-
|
|
6114
|
-
Swal__default['default'].fire({
|
|
6115
|
-
title: _this.translatePipe.transform(error.error),
|
|
6116
|
-
});
|
|
6117
|
-
// alert("err");
|
|
6118
|
-
// error.error
|
|
6148
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6119
6149
|
});
|
|
6120
6150
|
};
|
|
6121
6151
|
SupportRequestDetailsComponent.prototype.getAssignmentByRefRecIdList = function (Criteria) {
|
|
@@ -6128,11 +6158,7 @@
|
|
|
6128
6158
|
_this.loadGrid(x.Data, x.TotalCount);
|
|
6129
6159
|
_this.globalService.dataLoader = false;
|
|
6130
6160
|
}, function (error) {
|
|
6131
|
-
|
|
6132
|
-
// error.error
|
|
6133
|
-
Swal__default['default'].fire({
|
|
6134
|
-
title: _this.translatePipe.transform(error.error),
|
|
6135
|
-
});
|
|
6161
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6136
6162
|
});
|
|
6137
6163
|
}
|
|
6138
6164
|
};
|
|
@@ -6514,6 +6540,7 @@
|
|
|
6514
6540
|
_this.EntityFormId = res.RecId;
|
|
6515
6541
|
}, function (error) {
|
|
6516
6542
|
console.log(error);
|
|
6543
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6517
6544
|
});
|
|
6518
6545
|
};
|
|
6519
6546
|
SupportRequestCreateComponent.prototype.getAssignedDocumentList = function () {
|
|
@@ -6583,6 +6610,7 @@
|
|
|
6583
6610
|
_this.supportService.displayListPopUp = true;
|
|
6584
6611
|
}, function (error) {
|
|
6585
6612
|
console.log(error);
|
|
6613
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6586
6614
|
});
|
|
6587
6615
|
}
|
|
6588
6616
|
else {
|
|
@@ -6658,6 +6686,7 @@
|
|
|
6658
6686
|
// })
|
|
6659
6687
|
}, function (error) {
|
|
6660
6688
|
console.log(error);
|
|
6689
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6661
6690
|
});
|
|
6662
6691
|
}
|
|
6663
6692
|
};
|
|
@@ -6992,9 +7021,7 @@
|
|
|
6992
7021
|
});
|
|
6993
7022
|
}, function (error) {
|
|
6994
7023
|
console.log(error);
|
|
6995
|
-
Swal__default['default'].fire(
|
|
6996
|
-
title: _this.translatePipe.transform(error.error),
|
|
6997
|
-
});
|
|
7024
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
6998
7025
|
});
|
|
6999
7026
|
};
|
|
7000
7027
|
RequestFlowComponent.prototype.getIssueGroupRequesterMappingByRequesterType = function () {
|
|
@@ -7011,9 +7038,7 @@
|
|
|
7011
7038
|
});
|
|
7012
7039
|
}, function (error) {
|
|
7013
7040
|
console.log(error);
|
|
7014
|
-
Swal__default['default'].fire(
|
|
7015
|
-
title: _this.translatePipe.transform(error.error),
|
|
7016
|
-
});
|
|
7041
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7017
7042
|
});
|
|
7018
7043
|
};
|
|
7019
7044
|
RequestFlowComponent.prototype.getDropDownForIssueSubGroup = function () {
|
|
@@ -7027,9 +7052,7 @@
|
|
|
7027
7052
|
_this.IssueSubGroupDDL = res;
|
|
7028
7053
|
}, function (error) {
|
|
7029
7054
|
console.log(error);
|
|
7030
|
-
Swal__default['default'].fire(
|
|
7031
|
-
title: _this.translatePipe.transform(error.error),
|
|
7032
|
-
});
|
|
7055
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7033
7056
|
});
|
|
7034
7057
|
}
|
|
7035
7058
|
};
|
|
@@ -7070,9 +7093,7 @@
|
|
|
7070
7093
|
//this.getCaseType();
|
|
7071
7094
|
}, function (error) {
|
|
7072
7095
|
console.log(error);
|
|
7073
|
-
Swal__default['default'].fire(
|
|
7074
|
-
title: _this.translatePipe.transform(error.error),
|
|
7075
|
-
});
|
|
7096
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7076
7097
|
});
|
|
7077
7098
|
};
|
|
7078
7099
|
RequestFlowComponent.prototype.getIssuebyissuerequester = function () {
|
|
@@ -7095,9 +7116,7 @@
|
|
|
7095
7116
|
}
|
|
7096
7117
|
}, function (error) {
|
|
7097
7118
|
console.log(error);
|
|
7098
|
-
Swal__default['default'].fire(
|
|
7099
|
-
title: _this.translatePipe.transform(error.error),
|
|
7100
|
-
});
|
|
7119
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7101
7120
|
// this.caseTypeList = [{ RecId: 43, Description: 'Vacation Request' }];
|
|
7102
7121
|
});
|
|
7103
7122
|
};
|
|
@@ -7161,9 +7180,7 @@
|
|
|
7161
7180
|
_this.getPageCount();
|
|
7162
7181
|
}, function (error) {
|
|
7163
7182
|
console.log(error);
|
|
7164
|
-
Swal__default['default'].fire(
|
|
7165
|
-
title: _this.translatePipe.transform(error.error),
|
|
7166
|
-
});
|
|
7183
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7167
7184
|
});
|
|
7168
7185
|
};
|
|
7169
7186
|
RequestFlowComponent.prototype.getStatusListCount = function () {
|
|
@@ -7252,6 +7269,7 @@
|
|
|
7252
7269
|
// this.openIssueGroup();
|
|
7253
7270
|
}, function (error) {
|
|
7254
7271
|
console.log(error);
|
|
7272
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7255
7273
|
});
|
|
7256
7274
|
};
|
|
7257
7275
|
RequestFlowComponent.prototype.closeModel = function () {
|
|
@@ -7422,6 +7440,7 @@
|
|
|
7422
7440
|
_this.RequesterField = _this.SupportRequestUser.FieldTypeIdEn;
|
|
7423
7441
|
}, function (error) {
|
|
7424
7442
|
console.log(error);
|
|
7443
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7425
7444
|
});
|
|
7426
7445
|
};
|
|
7427
7446
|
return RequestFlowComponent;
|
|
@@ -7753,6 +7772,35 @@
|
|
|
7753
7772
|
handlebars.registerHelper('SetFieldByLang', function (Lang, value, value2) {
|
|
7754
7773
|
return Lang == "Ar" ? value2 : value;
|
|
7755
7774
|
});
|
|
7775
|
+
handlebars.registerHelper('DateToStringPipe', function (date, formate) {
|
|
7776
|
+
if (date) {
|
|
7777
|
+
debugger;
|
|
7778
|
+
var _date = new Date(date);
|
|
7779
|
+
var _day = _date.getDate() < 10 ? ("0" + _date.getDate()) : _date.getDate();
|
|
7780
|
+
var _mon = _date.getMonth() + 1;
|
|
7781
|
+
var _month = _mon < 10 ? ("0" + _mon) : _mon;
|
|
7782
|
+
var _year = _date.getFullYear();
|
|
7783
|
+
switch (formate) {
|
|
7784
|
+
case "dd/mm/yyyy":
|
|
7785
|
+
return [_day, _month, _year].join('/');
|
|
7786
|
+
case "dd-mm-yyyy":
|
|
7787
|
+
return [_day, _month, _year].join('-');
|
|
7788
|
+
case "mm/dd/yyyy":
|
|
7789
|
+
return [_month, _day, _year].join('/');
|
|
7790
|
+
case "mm-dd-yyyy":
|
|
7791
|
+
return [_month, _day, _year].join('-');
|
|
7792
|
+
case "yyyy/mm/dd":
|
|
7793
|
+
return [_year, _month, _day].join('/');
|
|
7794
|
+
case "yyyy-mm-dd":
|
|
7795
|
+
return [_year, _month, _day].join('-');
|
|
7796
|
+
default:
|
|
7797
|
+
return [_month, _day, _year].join('/'); // "mm/dd/yyyy"
|
|
7798
|
+
}
|
|
7799
|
+
}
|
|
7800
|
+
else {
|
|
7801
|
+
return date;
|
|
7802
|
+
}
|
|
7803
|
+
});
|
|
7756
7804
|
}
|
|
7757
7805
|
|
|
7758
7806
|
// import { TranslatePipe } from 'src/app/Pipe/translate.pipe';
|
|
@@ -7847,6 +7895,7 @@
|
|
|
7847
7895
|
_this.getFieldListByEntityType(_this.EntityTypeForm.EntityTypeId);
|
|
7848
7896
|
}, function (error) {
|
|
7849
7897
|
console.log(error);
|
|
7898
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7850
7899
|
});
|
|
7851
7900
|
};
|
|
7852
7901
|
EntityDynamicViewComponent.prototype.getFieldListByEntityType = function (EntityTypeId) {
|
|
@@ -7858,6 +7907,7 @@
|
|
|
7858
7907
|
// this.TempFieldValidators();
|
|
7859
7908
|
}, function (error) {
|
|
7860
7909
|
console.log(error);
|
|
7910
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
7861
7911
|
});
|
|
7862
7912
|
};
|
|
7863
7913
|
EntityDynamicViewComponent.prototype.getAllDefaultEntityTypeForm = function (EntityTypeId) {
|
|
@@ -7876,6 +7926,7 @@
|
|
|
7876
7926
|
Swal__default['default'].fire({
|
|
7877
7927
|
title: _this.translatePipe.transform('Template form not found'),
|
|
7878
7928
|
});
|
|
7929
|
+
Swal__default['default'].fire(errorMessageType(error), _this.translatePipe.transform('Template form not found'), 'error');
|
|
7879
7930
|
console.log(error);
|
|
7880
7931
|
});
|
|
7881
7932
|
};
|
|
@@ -8438,6 +8489,11 @@
|
|
|
8438
8489
|
var RestData_1 = JSON.parse(_EntityTypeForm.DataSource);
|
|
8439
8490
|
var _hanbleBardata_1 = {};
|
|
8440
8491
|
_hanbleBardata_1.FormData = _this._PageForm.form.value;
|
|
8492
|
+
for (var key in _hanbleBardata_1.FormData) {
|
|
8493
|
+
if (Object.prototype.toString.call(_hanbleBardata_1.FormData[key]) === '[object Date]') {
|
|
8494
|
+
_hanbleBardata_1.FormData[key] = GetFormattedDateWithTime(_hanbleBardata_1.FormData[key]);
|
|
8495
|
+
}
|
|
8496
|
+
}
|
|
8441
8497
|
RestData_1.URL = _this.hanbleBarHtml(RestData_1.URL, _hanbleBardata_1);
|
|
8442
8498
|
RestData_1.Body = _this.hanbleBarHtml(RestData_1.Body, _hanbleBardata_1);
|
|
8443
8499
|
RestData_1.QueryStrings = RestData_1.QueryStrings.map(function (x) {
|
|
@@ -8462,11 +8518,21 @@
|
|
|
8462
8518
|
if (Fields) {
|
|
8463
8519
|
var _Fields = JSON.parse(JSON.parse(Fields));
|
|
8464
8520
|
_Fields.forEach(function (x) {
|
|
8465
|
-
var
|
|
8521
|
+
var _valuedata = RestData_1.ResponseType == "text" ? _data : _data[x.Value];
|
|
8522
|
+
var _value = _valuedata;
|
|
8466
8523
|
var currentfield = _this.EntityFieldList.filter(function (y) { return y.Description == x.Field; })[0];
|
|
8467
8524
|
if (currentfield.DataType == E_DataType.date || currentfield.DataType == E_DataType.dateTime) {
|
|
8468
8525
|
_value = new Date(_data[x.Value]);
|
|
8469
8526
|
}
|
|
8527
|
+
var _handleData = _this._PageForm.form.value;
|
|
8528
|
+
for (var key in _handleData) {
|
|
8529
|
+
if (Object.prototype.toString.call(_handleData[key]) === '[object Date]') {
|
|
8530
|
+
_handleData[key] = GetFormattedDateWithTime(_handleData[key]);
|
|
8531
|
+
}
|
|
8532
|
+
}
|
|
8533
|
+
_handleData.data = _data;
|
|
8534
|
+
_handleData.currentLang = _this.globalService.CurrentLanguage;
|
|
8535
|
+
_value = _this.hanbleBarHtml(_value, _handleData);
|
|
8470
8536
|
_this._PageForm.form.get(x.Field).setValue(_value, { entitySelf: true });
|
|
8471
8537
|
});
|
|
8472
8538
|
}
|
|
@@ -8484,11 +8550,12 @@
|
|
|
8484
8550
|
}
|
|
8485
8551
|
}, function (error) {
|
|
8486
8552
|
console.log(error);
|
|
8487
|
-
Swal__default['default'].fire(errorMessageType(error));
|
|
8553
|
+
Swal__default['default'].fire(errorMessageType(error), _this.translatePipe.transform(''), 'error');
|
|
8488
8554
|
});
|
|
8489
8555
|
}
|
|
8490
8556
|
}, function (error) {
|
|
8491
8557
|
console.log(error);
|
|
8558
|
+
Swal__default['default'].fire(errorMessageType(error), _this.translatePipe.transform(''), 'error');
|
|
8492
8559
|
});
|
|
8493
8560
|
};
|
|
8494
8561
|
EntityDynamicViewComponent.prototype.getAllRules = function (EntityTypeId) {
|
|
@@ -9952,6 +10019,7 @@
|
|
|
9952
10019
|
_this.EntityTypeDetail = res;
|
|
9953
10020
|
}, function (error) {
|
|
9954
10021
|
console.log(error);
|
|
10022
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
9955
10023
|
});
|
|
9956
10024
|
};
|
|
9957
10025
|
DynamicDetailsViewComponent.prototype.saveDesignForm = function () {
|
|
@@ -9984,6 +10052,7 @@
|
|
|
9984
10052
|
// this._PageForm.form = this.getFieldFormGroup();
|
|
9985
10053
|
}, function (error) {
|
|
9986
10054
|
console.log(error);
|
|
10055
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
9987
10056
|
});
|
|
9988
10057
|
};
|
|
9989
10058
|
DynamicDetailsViewComponent.prototype.getEntityForm = function () {
|
|
@@ -10015,6 +10084,7 @@
|
|
|
10015
10084
|
}
|
|
10016
10085
|
}, function (error) {
|
|
10017
10086
|
console.log(error);
|
|
10087
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10018
10088
|
});
|
|
10019
10089
|
};
|
|
10020
10090
|
DynamicDetailsViewComponent.prototype.addRow = function () {
|
|
@@ -10261,6 +10331,7 @@
|
|
|
10261
10331
|
}
|
|
10262
10332
|
}, function (error) {
|
|
10263
10333
|
console.log(error);
|
|
10334
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10264
10335
|
});
|
|
10265
10336
|
};
|
|
10266
10337
|
DynamicDetailsViewComponent.prototype.getFieldFormValue = function (field) {
|
|
@@ -10354,6 +10425,7 @@
|
|
|
10354
10425
|
_this.EntityFormId = res.RecId;
|
|
10355
10426
|
}, function (error) {
|
|
10356
10427
|
console.log(error);
|
|
10428
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10357
10429
|
});
|
|
10358
10430
|
};
|
|
10359
10431
|
ActivitiesCreateComponent.prototype.closeCreatePage = function () {
|
|
@@ -10402,6 +10474,7 @@
|
|
|
10402
10474
|
_this.closeActivityCreate.emit({ Type: "Create" });
|
|
10403
10475
|
}, function (error) {
|
|
10404
10476
|
console.log(error);
|
|
10477
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10405
10478
|
});
|
|
10406
10479
|
};
|
|
10407
10480
|
ActivitiesCreateComponent.prototype.emitTicketCreateForm = function (CreateData, pageForm) {
|
|
@@ -10454,6 +10527,7 @@
|
|
|
10454
10527
|
_this.EntityFormId = res.RecId;
|
|
10455
10528
|
}, function (error) {
|
|
10456
10529
|
console.log(error);
|
|
10530
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10457
10531
|
});
|
|
10458
10532
|
};
|
|
10459
10533
|
ActivitiesViewComponent.prototype.emitTicketCreateForm = function (CreateData, pageForm) {
|
|
@@ -10541,9 +10615,7 @@
|
|
|
10541
10615
|
});
|
|
10542
10616
|
}, function (error) {
|
|
10543
10617
|
console.log(error);
|
|
10544
|
-
Swal__default['default'].fire(
|
|
10545
|
-
title: _this.translatePipe.transform(error.error),
|
|
10546
|
-
});
|
|
10618
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10547
10619
|
});
|
|
10548
10620
|
};
|
|
10549
10621
|
SelfServiceFlowComponent.prototype.selectCase = function (item) {
|
|
@@ -10891,6 +10963,7 @@
|
|
|
10891
10963
|
_this.EntityFormId = res.RecId;
|
|
10892
10964
|
}, function (error) {
|
|
10893
10965
|
console.log(error);
|
|
10966
|
+
Swal__default['default'].fire(errorMessageType(error), "", 'error');
|
|
10894
10967
|
});
|
|
10895
10968
|
}
|
|
10896
10969
|
};
|