biz9-logic 3.0.9 → 3.0.10

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/biz9_config CHANGED
@@ -1,4 +1,4 @@
1
- VERSION='3.0.9'
1
+ VERSION='3.1.0'
2
2
  TITLE='BiZ9-Logic';
3
3
  REPO='git@github.com:biz9framework/biz9-logic.git';
4
4
  BRANCH='main';
package/index.js CHANGED
@@ -5,8 +5,16 @@ License GNU General Public License v3.0
5
5
  Description: BiZ9 Framework: Logic-JS
6
6
  */
7
7
  const { get_new_item_main,get_data_config_main,get_cloud_url_main,get_biz_item_main,get_cloud_filter_obj_main,get_title_url_main } = require('./main');
8
+ const {Log,Test,Str} = require('biz9-utility');
8
9
 
9
10
  class DataType {
11
+ static get_data_type_title = (data_type) => {
12
+ if(!data_type){
13
+ return "";
14
+ }else{
15
+ return String(Str.get_title(data_type.replaceAll('_',' ').replaceAll('dt','').replace('biz',''))).trim();
16
+ }
17
+ }
10
18
  static DT_ADMIN='admin_biz';
11
19
  static DT_BLANK='blank_biz';
12
20
  static DT_BLOG_POST='blog_post_biz';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "biz9-logic",
3
- "version": "3.0.9",
3
+ "version": "3.0.10",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"
@@ -10,7 +10,7 @@
10
10
  "dependencies": {
11
11
  "async-series": "^0.0.1",
12
12
  "biz9-scriptz": "^5.5.4",
13
- "biz9-utility": "^2.0.27",
13
+ "biz9-utility": "^2.0.28",
14
14
  "jest": "^29.7.0"
15
15
  },
16
16
  "repository": {
package/test.js CHANGED
@@ -28,6 +28,11 @@ const biz9_config ={
28
28
  describe("connect", () => {
29
29
  it("_connect", () => {
30
30
  series([
31
+ function(call) {
32
+ console.log('GET-BIZ9-GET-DATA-TYPE-START');
33
+ console.log(DataType.get_data_type_title(DataType.DT_CART_ITEM));
34
+ console.log('GET-BIZ9-GET-DATA-TYPE-END');
35
+ },
31
36
  function(call) {
32
37
  console.log('GET-BIZ9-CONFIG-FILE-START');
33
38
  let biz9_config = Scriptz.get_biz9_config({biz9_config_file:path.resolve('../../biz9_config')});