@livinglogic/livingapi 1.23.0 → 1.25.0

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@livinglogic/livingapi",
3
- "version": "1.23.0",
3
+ "version": "1.25.0",
4
4
  "description": "Javascript version of the LivingAPI classes of LivingApps",
5
5
  "repository": {
6
6
  "type": "git",
package/src/livingapi.js CHANGED
@@ -2,8 +2,8 @@
2
2
  * LivingAPI JavaScript Library
3
3
  * https://my.living-apps.de/docs/LivingAPI.html
4
4
  *
5
- * Copyright 2017-2024 by LivingLogic AG, Bayreuth/Germany
6
- * Copyright 2017-2024 by Walter Dörwald
5
+ * Copyright 2017-2025 by LivingLogic AG, Bayreuth/Germany
6
+ * Copyright 2017-2025 by Walter Dörwald
7
7
  *
8
8
  * All Rights Reserved
9
9
  *
@@ -1730,6 +1730,49 @@ Field.prototype._ul4attrs = new Set(["control", "record", "label", "description"
1730
1730
  Field.prototype._inputevent = "input";
1731
1731
 
1732
1732
 
1733
+ class PlaceholderFieldType extends FieldType
1734
+ {
1735
+ instancecheck(obj)
1736
+ {
1737
+ return obj instanceof PlaceholderField;
1738
+ }
1739
+ };
1740
+
1741
+ let placeholderfieldtype = new PlaceholderFieldType("la", "PlaceholderField", "Holds the value of a field with placeholder support of a record (and related information)");
1742
+
1743
+
1744
+ export class PlaceholderField extends Field
1745
+ {
1746
+ constructor(control, record, value)
1747
+ {
1748
+ super(control, record, value);
1749
+ this._placeholder = null;
1750
+ }
1751
+
1752
+ [ul4.symbols.type]()
1753
+ {
1754
+ return placeholderfieldtype;
1755
+ }
1756
+
1757
+ get placeholder()
1758
+ {
1759
+ if (this._placeholder !== null)
1760
+ return this._placeholder;
1761
+ return this.control.placeholder;
1762
+ }
1763
+
1764
+ set placeholder(value)
1765
+ {
1766
+ this._placeholder = value;
1767
+ if (this._in_form())
1768
+ this._dom_control.placeholder = this.placeholder ?? "";
1769
+ }
1770
+ };
1771
+
1772
+ PlaceholderField.prototype._ul4onattrs = [...Field.prototype._ul4onattrs, "_placeholder"];
1773
+ PlaceholderField.prototype._ul4attrs = new Set([...Field.prototype._ul4attrs, "placeholder"]);
1774
+
1775
+
1733
1776
  class BoolFieldType extends FieldType
1734
1777
  {
1735
1778
  instancecheck(obj)
@@ -1897,7 +1940,7 @@ export class IntField extends Field
1897
1940
  };
1898
1941
 
1899
1942
 
1900
- class NumberFieldType extends FieldType
1943
+ class NumberFieldType extends PlaceholderFieldType
1901
1944
  {
1902
1945
  instancecheck(obj)
1903
1946
  {
@@ -1908,7 +1951,7 @@ class NumberFieldType extends FieldType
1908
1951
  let numberfieldtype = new NumberFieldType("la", "NumberField", "Holds the value of a number field of a record (and related information)");
1909
1952
 
1910
1953
 
1911
- export class NumberField extends Field
1954
+ export class NumberField extends PlaceholderField
1912
1955
  {
1913
1956
  [ul4.symbols.type]()
1914
1957
  {
@@ -2091,7 +2134,7 @@ export class NumberField extends Field
2091
2134
  };
2092
2135
 
2093
2136
 
2094
- class StringFieldType extends FieldType
2137
+ class StringFieldType extends PlaceholderFieldType
2095
2138
  {
2096
2139
  instancecheck(obj)
2097
2140
  {
@@ -2102,7 +2145,7 @@ class StringFieldType extends FieldType
2102
2145
  let stringfieldtype = new StringFieldType("la", "StringField", "Holds the value of a string field of a record (and related information)");
2103
2146
 
2104
2147
 
2105
- export class StringField extends Field
2148
+ export class StringField extends PlaceholderField
2106
2149
  {
2107
2150
  [ul4.symbols.type]()
2108
2151
  {
@@ -2496,7 +2539,7 @@ export class FileSignatureField extends FileField
2496
2539
  };
2497
2540
 
2498
2541
 
2499
- class DateFieldBaseType extends FieldType
2542
+ class DateFieldBaseType extends PlaceholderFieldType
2500
2543
  {
2501
2544
  instancecheck(obj)
2502
2545
  {
@@ -2507,7 +2550,7 @@ class DateFieldBaseType extends FieldType
2507
2550
  let datefieldbasetype = new DateFieldBaseType("la", "DateFieldBase", "Holds the value of a date field of a record (and related information)");
2508
2551
 
2509
2552
 
2510
- export class DateFieldBase extends Field
2553
+ export class DateFieldBase extends PlaceholderField
2511
2554
  {
2512
2555
  [ul4.symbols.type]()
2513
2556
  {
@@ -3903,6 +3946,36 @@ export class Control extends Base
3903
3946
  this._in_text = value;
3904
3947
  }
3905
3948
 
3949
+ get in_structured_search()
3950
+ {
3951
+ return this._in_structured_search;
3952
+ }
3953
+
3954
+ set in_structured_search(value)
3955
+ {
3956
+ this._in_structured_search = value;
3957
+ }
3958
+
3959
+ get in_fulltext_search()
3960
+ {
3961
+ return this._in_fulltext_search;
3962
+ }
3963
+
3964
+ set in_fulltext_search(value)
3965
+ {
3966
+ this._in_fulltext_search = value;
3967
+ }
3968
+
3969
+ get in_expert_search()
3970
+ {
3971
+ return this._in_expert_search;
3972
+ }
3973
+
3974
+ set in_expert_search(value)
3975
+ {
3976
+ this._in_expert_search = value;
3977
+ }
3978
+
3906
3979
  get default()
3907
3980
  {
3908
3981
  return null;
@@ -4037,8 +4110,8 @@ export class Control extends Base
4037
4110
 
4038
4111
  Control.prototype.type = null;
4039
4112
  Control.prototype.subtype = null;
4040
- Control.prototype._ul4onattrs = ["identifier", "fieldname", "app", "_label", "_description", "_priority", "_in_mobile_list", "_in_text", "_required", "_required_in_view", "order", "ininsertprocedure", "inupdateprocedure"];
4041
- Control.prototype._ul4attrs = new Set(["id", "identifier", "fieldname", "app", "priority", "in_list", "in_mobile_list", "in_text", "order", "ininsertprocedure", "inupdateprocedure", "fulltype", "label", "description", "top", "left", "width", "height", "z_index", "liveupdate", "tabindex", "required", "mode", "labelpos", "autoalign", "in_active_view"]);
4113
+ Control.prototype._ul4onattrs = ["identifier", "fieldname", "app", "_label", "_description", "_priority", "_in_mobile_list", "_in_text", "_in_structured_search", "_in_fulltext_search", "_in_expert_search", "_required", "_required_in_view", "order", "ininsertprocedure", "inupdateprocedure"];
4114
+ Control.prototype._ul4attrs = new Set(["id", "identifier", "fieldname", "app", "priority", "in_list", "in_mobile_list", "in_text", "in_structured_search", "in_fulltext_search", "in_expert_search", "order", "ininsertprocedure", "inupdateprocedure", "fulltype", "label", "description", "top", "left", "width", "height", "z_index", "liveupdate", "tabindex", "required", "mode", "labelpos", "autoalign", "in_active_view"]);
4042
4115
  Control.prototype._cssclass_root = "llft-control";
4043
4116
  Control.prototype._cssclass_control = "input";
4044
4117
 
@@ -4130,9 +4203,9 @@ class PlaceholderControl extends Control
4130
4203
  get placeholder()
4131
4204
  {
4132
4205
  let view_control = this._view_control();
4133
- if (view_control === null)
4134
- return null;
4135
- return view_control.placeholder;
4206
+ if (view_control !== null)
4207
+ return view_control.placeholder;
4208
+ return this._placeholder;
4136
4209
  }
4137
4210
  };
4138
4211