@fluxhub/fluxhub-lib 10.0.416 → 10.0.418

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.
@@ -17658,11 +17658,87 @@
17658
17658
  ];
17659
17659
  var ok_op = false;
17660
17660
  this.m_wkf.doQuery(p).subscribe(function (data) { });
17661
+ var ical = null;
17662
+ var comm = "";
17663
+ console.log('QUI COMMMM');
17664
+ if (this.nota != "")
17665
+ comm = "<br>Commento: <br>" + this.nota;
17666
+ if (this.nlevel.ical == 1) {
17667
+ if (this.m_obj.ical_dt_ini == null) {
17668
+ this.alert("Attenzione ical non configurato ical_dt_ini", 1);
17669
+ }
17670
+ else if (this.m_obj.ical_dt_fin == null) {
17671
+ this.alert("Attenzione ical non configurato ical_dt_fin", 1);
17672
+ }
17673
+ else
17674
+ ical = {
17675
+ start: this.m_obj.ical_dt_ini,
17676
+ end: this.m_obj.ical_dt_fin,
17677
+ summary: this.app_info.descrizione_breve + " " + this.getTitle(),
17678
+ description: this.getDescri() +
17679
+ comm +
17680
+ "<br>" +
17681
+ this.app_s.COMPANY_SITE_ROOT +
17682
+ "#/" +
17683
+ this.app_info.modulo_swf +
17684
+ "/" +
17685
+ this.id_applicativo +
17686
+ "/" +
17687
+ this.id_documento +
17688
+ "/edit",
17689
+ organizer: this.user_nome +
17690
+ " " +
17691
+ this.user_cognome +
17692
+ " <" +
17693
+ this.user_email +
17694
+ ">",
17695
+ url: this.app_s.COMPANY_SITE_ROOT +
17696
+ "#/" +
17697
+ this.app_info.modulo_swf +
17698
+ "/" +
17699
+ this.id_applicativo +
17700
+ "/" +
17701
+ this.id_documento +
17702
+ "/edit",
17703
+ };
17704
+ }
17705
+ var s_ogg = this.nlevel.oggetto_email;
17706
+ if (s_ogg == null)
17707
+ s_ogg = '';
17708
+ if (this.nlevel != null)
17709
+ if (this.nlevel.descri_livello != null)
17710
+ s_ogg = s_ogg
17711
+ .split("%new_step%")
17712
+ .join(this.nlevel.descri_livello);
17713
+ if (this.clevel != null)
17714
+ if (this.clevel.descri_livello != null)
17715
+ s_ogg = s_ogg
17716
+ .split("%old_step%")
17717
+ .join(this.clevel.descri_livello);
17718
+ s_ogg = s_ogg.split("%new_step%").join("");
17719
+ s_ogg = s_ogg.split("%old_step%").join("");
17720
+ for (var prop in this.m_obj)
17721
+ if (this.m_obj[prop] != null) {
17722
+ console.log(prop +
17723
+ " " +
17724
+ Object.prototype.toString.call(this.m_obj[prop]));
17725
+ if (Object.prototype.toString.call(this.m_obj[prop]) ===
17726
+ "[object Date]") {
17727
+ s_ogg = s_ogg
17728
+ .split("%" + prop + "%")
17729
+ .join(this.uti_s.date2String(this.m_obj[prop]));
17730
+ }
17731
+ else if (("" + this.m_obj[prop]).indexOf("T00:00:00") == -1)
17732
+ s_ogg = s_ogg
17733
+ .split("%" + prop + "%")
17734
+ .join(this.m_obj[prop]);
17735
+ else
17736
+ s_ogg = s_ogg
17737
+ .split("%" + prop + "%")
17738
+ .join(this.uti_s.date2String(this.uti_s.string2date(this.m_obj[prop], 2)));
17739
+ }
17661
17740
  //myRPC.query("UPDATE_FLAG_CARICO",new Array("0",id_applicativo, id_documento,''));
17662
17741
  if (this.m_danotificare != "") {
17663
- var comm_1 = "";
17664
- if (this.nota != "")
17665
- comm_1 = "<br>Commento: <br>" + this.nota;
17666
17742
  if (this.clevel.ccn_mittente == 1) {
17667
17743
  if (this.m_danotificare != "")
17668
17744
  this.m_danotificare = this.m_danotificare + ",";
@@ -17671,46 +17747,6 @@
17671
17747
  if (this.nlevel.approvazione_email == 1) {
17672
17748
  }
17673
17749
  else {
17674
- var ical_1 = null;
17675
- if (this.nlevel.ical == 1) {
17676
- if (this.m_obj.ical_dt_ini == null) {
17677
- this.alert("Attenzione ical non configurato ical_dt_ini", 1);
17678
- }
17679
- else if (this.m_obj.ical_dt_fin == null) {
17680
- this.alert("Attenzione ical non configurato ical_dt_fin", 1);
17681
- }
17682
- else
17683
- ical_1 = {
17684
- start: this.m_obj.ical_dt_ini,
17685
- end: this.m_obj.ical_dt_fin,
17686
- summary: this.app_info.descrizione_breve + " " + this.getTitle(),
17687
- description: this.getDescri() +
17688
- comm_1 +
17689
- "<br>" +
17690
- this.app_s.COMPANY_SITE_ROOT +
17691
- "#/" +
17692
- this.app_info.modulo_swf +
17693
- "/" +
17694
- this.id_applicativo +
17695
- "/" +
17696
- this.id_documento +
17697
- "/edit",
17698
- organizer: this.user_nome +
17699
- " " +
17700
- this.user_cognome +
17701
- " <" +
17702
- this.user_email +
17703
- ">",
17704
- url: this.app_s.COMPANY_SITE_ROOT +
17705
- "#/" +
17706
- this.app_info.modulo_swf +
17707
- "/" +
17708
- this.id_applicativo +
17709
- "/" +
17710
- this.id_documento +
17711
- "/edit",
17712
- };
17713
- }
17714
17750
  if (this.nlevel.email_partecipanti == 1 ||
17715
17751
  this.nlevel.email_ospiti == 1) {
17716
17752
  if (this.b_respingi)
@@ -17721,14 +17757,14 @@
17721
17757
  "<br>" +
17722
17758
  this.getDescri() +
17723
17759
  "<br>Commenti:" +
17724
- comm_1, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17760
+ comm, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17725
17761
  "#/" +
17726
17762
  this.app_info.modulo_swf +
17727
17763
  "/" +
17728
17764
  this.id_applicativo +
17729
17765
  "/" +
17730
17766
  this.id_documento +
17731
- "/edit", this.m_obj.codice, this.nota, true, ical_1);
17767
+ "/edit", this.m_obj.codice, this.nota, true, ical);
17732
17768
  else {
17733
17769
  if (this.nlevel.oggetto_email == null)
17734
17770
  this.sendEMail_ex(this.user_idp, this.m_danotificare, this.app_info.descrizione_breve +
@@ -17743,14 +17779,14 @@
17743
17779
  this.m_statox +
17744
17780
  "<br>" +
17745
17781
  this.getDescri() +
17746
- comm_1, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17782
+ comm, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17747
17783
  "#/" +
17748
17784
  this.app_info.modulo_swf +
17749
17785
  "/" +
17750
17786
  this.id_applicativo +
17751
17787
  "/" +
17752
17788
  this.id_documento +
17753
- "/edit", this.m_obj.codice, this.nota, true, ical_1);
17789
+ "/edit", this.m_obj.codice, this.nota, true, ical);
17754
17790
  else if (this.nlevel.oggetto_email == "")
17755
17791
  this.sendEMail_ex(this.user_idp, this.m_danotificare, this.app_info.descrizione_breve +
17756
17792
  ", Ti è stato assegnato il documento numero: " +
@@ -17764,151 +17800,111 @@
17764
17800
  this.m_statox +
17765
17801
  "<br>" +
17766
17802
  this.getDescri() +
17767
- comm_1, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17803
+ comm, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17768
17804
  "#/" +
17769
17805
  this.app_info.modulo_swf +
17770
17806
  "/" +
17771
17807
  this.id_applicativo +
17772
17808
  "/" +
17773
17809
  this.id_documento +
17774
- "/edit", this.m_obj.codice, this.nota, true, ical_1);
17810
+ "/edit", this.m_obj.codice, this.nota, true, ical);
17775
17811
  else {
17776
- var s_ogg = this.nlevel.oggetto_email;
17777
- if (this.nlevel != null)
17778
- if (this.nlevel.descri_livello != null)
17779
- s_ogg = s_ogg
17780
- .split("%new_step%")
17781
- .join(this.nlevel.descri_livello);
17782
- if (this.clevel != null)
17783
- if (this.clevel.descri_livello != null)
17784
- s_ogg = s_ogg
17785
- .split("%old_step%")
17786
- .join(this.clevel.descri_livello);
17787
- s_ogg = s_ogg.split("%new_step%").join("");
17788
- s_ogg = s_ogg.split("%old_step%").join("");
17789
- for (var prop in this.m_obj)
17790
- if (this.m_obj[prop] != null) {
17791
- console.log(prop +
17792
- " " +
17793
- Object.prototype.toString.call(this.m_obj[prop]));
17794
- if (Object.prototype.toString.call(this.m_obj[prop]) ===
17795
- "[object Date]") {
17796
- s_ogg = s_ogg
17797
- .split("%" + prop + "%")
17798
- .join(this.uti_s.date2String(this.m_obj[prop]));
17799
- }
17800
- else if (("" + this.m_obj[prop]).indexOf("T00:00:00") == -1)
17801
- s_ogg = s_ogg
17802
- .split("%" + prop + "%")
17803
- .join(this.m_obj[prop]);
17804
- else
17805
- s_ogg = s_ogg
17806
- .split("%" + prop + "%")
17807
- .join(this.uti_s.date2String(this.uti_s.string2date(this.m_obj[prop], 2)));
17808
- }
17809
17812
  this.sendEMail_ex(this.user_idp, this.m_danotificare, s_ogg, "<br>Attività:" +
17810
17813
  this.getLvlDescri(String(this.m_liv), this.m_statox) +
17811
17814
  "<br>" +
17812
17815
  this.m_statox +
17813
17816
  "<br>" +
17814
17817
  this.getDescri() +
17815
- comm_1, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17818
+ comm, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17816
17819
  "#/" +
17817
17820
  this.app_info.modulo_swf +
17818
17821
  "/" +
17819
17822
  this.id_applicativo +
17820
17823
  "/" +
17821
17824
  this.id_documento +
17822
- "/edit", this.m_obj.codice, this.nota, true, ical_1);
17825
+ "/edit", this.m_obj.codice, this.nota, true, ical);
17823
17826
  }
17824
17827
  }
17825
17828
  }
17826
17829
  else
17827
17830
  this.goto_edit_doc();
17828
- if (this.nlevel.tipo_notifica_aggiuntiva != 0) {
17829
- if (this.nlevel.tipo_notifica_aggiuntiva == 1)
17830
- this.sendEMail_ex(this.user_idp, this.m_obj.creatore, this.app_info.descrizione_breve +
17831
- ", Il documento numero: " +
17832
- this.m_obj.codice +
17833
- " è passato allo STEP: " +
17834
- this.nlevel.descri_livello +
17835
- " " +
17836
- this.getTitle(), this.m_statox + "<br>" + this.getDescri() + comm_1, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17837
- "#/" +
17838
- this.app_info.modulo_swf +
17839
- "/" +
17840
- this.id_applicativo +
17841
- "/" +
17842
- this.id_documento +
17843
- "/edit", this.m_obj.codice, this.nota, true, ical_1, false);
17844
- if (this.nlevel.tipo_notifica_aggiuntiva == 2) {
17845
- var p_2 = new QParam();
17846
- p_2.sql = "SELECT_PARTECIPANTI_DOC";
17847
- p_2.values = [this.id_applicativo, this.id_documento];
17848
- p_2.types = ["string", "string"];
17849
- this.m_dataService.doQuery(p_2).subscribe(function (data) {
17850
- if (data != null)
17851
- if (data.result_msg == "OK") {
17852
- var lista_p = _this.user_idp;
17853
- for (var i = 0; i < data.result_data.length; i++)
17854
- if (lista_p.indexOf(data.result_data[i].username) == -1) {
17855
- lista_p += ",";
17856
- lista_p += data.result_data[i].username;
17857
- }
17858
- _this.sendEMail_ex(_this.user_idp, lista_p, _this.app_info.descrizione_breve +
17859
- ", Il documento numero: " +
17860
- _this.m_obj.codice +
17861
- " è passato allo STEP: " +
17862
- _this.nlevel.descri_livello +
17863
- " " +
17864
- _this.getTitle(), _this.m_statox + "<br>" + _this.getDescri() + comm_1, _this.id_applicativo, _this.id_documento, _this.app_s.COMPANY_SITE_ROOT +
17865
- "#/" +
17866
- _this.app_info.modulo_swf +
17867
- "/" +
17868
- _this.id_applicativo +
17869
- "/" +
17870
- _this.id_documento +
17871
- "/edit", _this.m_obj.codice, _this.nota, true, ical_1, false);
17831
+ }
17832
+ }
17833
+ console.log('this.nlevel ', this.nlevel);
17834
+ console.log('this.nlevel.tipo_notifica_aggiuntiva ', this.nlevel.tipo_notifica_aggiuntiva);
17835
+ if (s_ogg == '')
17836
+ s_ogg = this.app_info.descrizione_breve +
17837
+ ", Il documento numero: " +
17838
+ this.m_obj.codice +
17839
+ " è passato allo STEP: " +
17840
+ this.nlevel.descri_livello +
17841
+ " " +
17842
+ this.getTitle();
17843
+ if (this.nlevel.tipo_notifica_aggiuntiva != 0) {
17844
+ if (this.nlevel.tipo_notifica_aggiuntiva == 1)
17845
+ this.sendEMail_ex(this.user_idp, this.m_obj.creatore, s_ogg, this.m_statox + "<br>" + this.getDescri() + comm, this.id_applicativo, this.id_documento, this.app_s.COMPANY_SITE_ROOT +
17846
+ "#/" +
17847
+ this.app_info.modulo_swf +
17848
+ "/" +
17849
+ this.id_applicativo +
17850
+ "/" +
17851
+ this.id_documento +
17852
+ "/edit", this.m_obj.codice, this.nota, true, ical, false);
17853
+ if (this.nlevel.tipo_notifica_aggiuntiva == 2) {
17854
+ console.log('SELECT_PARTECIPANTI_DOC ');
17855
+ var p_2 = new QParam();
17856
+ p_2.sql = "SELECT_PARTECIPANTI_DOC";
17857
+ p_2.values = [this.id_applicativo, this.id_documento];
17858
+ p_2.types = ["string", "string"];
17859
+ this.m_dataService.doQuery(p_2).subscribe(function (data) {
17860
+ if (data != null)
17861
+ if (data.result_msg == "OK") {
17862
+ var lista_p = _this.user_idp;
17863
+ for (var i = 0; i < data.result_data.length; i++)
17864
+ if (lista_p.indexOf(data.result_data[i].username) == -1) {
17865
+ lista_p += ",";
17866
+ lista_p += data.result_data[i].username;
17872
17867
  }
17873
- });
17874
- }
17875
- if (this.nlevel.tipo_notifica_aggiuntiva == 3) {
17876
- var p_3 = new QParam();
17877
- p_3.sql = "SELECT_ALL_USERS_DOC";
17878
- p_3.values = [this.id_applicativo, this.id_documento];
17879
- p_3.types = ["string", "string"];
17880
- this.m_dataService.doQuery(p_3).subscribe(function (data) {
17881
- if (data != null)
17882
- if (data.result_msg == "OK") {
17883
- var lista_p = _this.user_idp;
17884
- for (var i = 0; i < data.result_data.length; i++)
17885
- if (lista_p.indexOf(data.result_data[i].username) == -1) {
17886
- console.log("username:", data.result_data[i].username);
17887
- lista_p += ",";
17888
- lista_p += data.result_data[i].username;
17889
- }
17890
- _this.sendEMail_ex(_this.user_idp, lista_p, _this.app_info.descrizione_breve +
17891
- ", Il documento numero: " +
17892
- _this.m_obj.codice +
17893
- " è passato allo STEP: " +
17894
- _this.nlevel.descri_livello +
17895
- " " +
17896
- _this.getTitle(), _this.m_statox + "<br>" + _this.getDescri() + comm_1, _this.id_applicativo, _this.id_documento, _this.app_s.COMPANY_SITE_ROOT +
17897
- "#/" +
17898
- _this.app_info.modulo_swf +
17899
- "/" +
17900
- _this.id_applicativo +
17901
- "/" +
17902
- _this.id_documento +
17903
- "/edit", _this.m_obj.codice, _this.nota, true, ical_1, false);
17868
+ console.log('lista_p ', lista_p);
17869
+ _this.sendEMail_ex(_this.user_idp, lista_p, s_ogg, _this.m_statox + "<br>" + _this.getDescri() + comm, _this.id_applicativo, _this.id_documento, _this.app_s.COMPANY_SITE_ROOT +
17870
+ "#/" +
17871
+ _this.app_info.modulo_swf +
17872
+ "/" +
17873
+ _this.id_applicativo +
17874
+ "/" +
17875
+ _this.id_documento +
17876
+ "/edit", _this.m_obj.codice, _this.nota, true, ical, false);
17877
+ }
17878
+ });
17879
+ }
17880
+ if (this.nlevel.tipo_notifica_aggiuntiva == 3) {
17881
+ var p_3 = new QParam();
17882
+ p_3.sql = "SELECT_ALL_USERS_DOC";
17883
+ p_3.values = [this.id_applicativo, this.id_documento];
17884
+ p_3.types = ["string", "string"];
17885
+ this.m_dataService.doQuery(p_3).subscribe(function (data) {
17886
+ if (data != null)
17887
+ if (data.result_msg == "OK") {
17888
+ var lista_p = _this.user_idp;
17889
+ for (var i = 0; i < data.result_data.length; i++)
17890
+ if (lista_p.indexOf(data.result_data[i].username) == -1) {
17891
+ console.log("username:", data.result_data[i].username);
17892
+ lista_p += ",";
17893
+ lista_p += data.result_data[i].username;
17904
17894
  }
17905
- });
17906
- }
17907
- }
17895
+ _this.sendEMail_ex(_this.user_idp, lista_p, s_ogg, _this.m_statox + "<br>" + _this.getDescri() + comm, _this.id_applicativo, _this.id_documento, _this.app_s.COMPANY_SITE_ROOT +
17896
+ "#/" +
17897
+ _this.app_info.modulo_swf +
17898
+ "/" +
17899
+ _this.id_applicativo +
17900
+ "/" +
17901
+ _this.id_documento +
17902
+ "/edit", _this.m_obj.codice, _this.nota, true, ical, false);
17903
+ }
17904
+ });
17908
17905
  }
17909
17906
  }
17910
- else
17911
- this.goto_edit_doc();
17907
+ this.goto_edit_doc();
17912
17908
  };
17913
17909
  dati_aggiuntivi.prototype.sendEMail_ex = function (mit, to, ogg, descri, idapp, iddoc, link, cc, nota, notif_av, ical, b_exit) {
17914
17910
  var _this = this;