@wibetter/json-utils 5.3.1 → 6.0.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/dist/index.esm.js CHANGED
@@ -1033,1344 +1033,6 @@ var EmptyDynamicDataCont = {
1033
1033
  localFilter: 'return data;',
1034
1034
  };
1035
1035
 
1036
- /** dynamicConfig: 动态配置
1037
- * 【字段属性说明】
1038
- * title:字段项的label值
1039
- * properties:存放所有的子字段数据内容
1040
- * type:用于标识字段项的展示类型(input、date、data-time、url、textarea 等)
1041
- * readOnly:字段项可设置是否可编辑
1042
- * propertyOrder:按序存放所有子字段的key值(排序功能)
1043
- * */
1044
- var initDynamicConfig = {
1045
- type: 'dynamic-config',
1046
- title: '动态配置',
1047
- description: '',
1048
- isContainer: false,
1049
- properties: {
1050
- type: {
1051
- type: 'select',
1052
- title: '数据来源',
1053
- options: [
1054
- {
1055
- label: '模板直接设置',
1056
- value: 'DevDefaults',
1057
- },
1058
- {
1059
- label: 'mp后台配置',
1060
- value: 'ContentStaticConfig',
1061
- },
1062
- {
1063
- label: '内容Meta数据',
1064
- value: 'Content',
1065
- },
1066
- {
1067
- label: '全局配置数据',
1068
- value: 'RuntimeConst',
1069
- },
1070
- {
1071
- label: '资源中心配置',
1072
- value: 'ResourceCenter',
1073
- },
1074
- ],
1075
- default: 'DevDefaults',
1076
- isConditionProp: true,
1077
- description:
1078
- '目前支持的数据来源包括: 1)模版直接设置:在模版配置直接生效,支持直接输入或图片上传。 2)mp后台配置:选择mp后台配置后,属性会出现在mp后台中,支持属性描述的输入。 3)内容meta数据:支持内容meta数据的获取,页面meta数据。 4)全局配置数据:目前支持的全局配置包括:全局Tab配置及主题包配置。相关属性会挂载至:window.globalConst',
1079
- },
1080
- value: {
1081
- title: '数据值',
1082
- type: 'input',
1083
- default: '',
1084
- description: '',
1085
- placeholder: '',
1086
- onShow:
1087
- 'type === "DevDefaults" || type === "Content" || type === "RuntimeConst"',
1088
- },
1089
- description: {
1090
- title: '属性名称',
1091
- type: 'input',
1092
- default: '',
1093
- description: '',
1094
- placeholder: '',
1095
- onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
1096
- },
1097
- valueType: {
1098
- type: 'radio',
1099
- title: '配置方式',
1100
- options: [
1101
- {
1102
- label: '填写',
1103
- value: 'string',
1104
- },
1105
- {
1106
- label: '选择',
1107
- value: 'select',
1108
- },
1109
- ],
1110
- default: 'string',
1111
- isConditionProp: true,
1112
- description: '在MP后台或资源中心配置时的交互方式,推荐使用"选择"',
1113
- onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
1114
- },
1115
- range: {
1116
- type: 'select',
1117
- title: '可选项',
1118
- multiple: true,
1119
- options: [],
1120
- onShow:
1121
- '(type === "ContentStaticConfig" || type === "ResourceCenter") && valueType === "select"',
1122
- description: '这里会使用value中的配置选项作为options',
1123
- },
1124
- },
1125
- propertyOrder: ['type', 'value', 'description', 'valueType', 'range'],
1126
- showCodeViewBtn: false,
1127
- };
1128
-
1129
- /** dynamic-object: 动态对象,支持在json-editor 中动态添加属性。
1130
- * 【字段属性说明】
1131
- * title:字段项的label值
1132
- * properties:存放所有的子字段数据内容
1133
- * type:用于标识字段项的展示类型(input、date、data-time、url、textarea 等)
1134
- * readOnly:字段项可设置是否可编辑
1135
- * propertyOrder:按序存放所有子字段的key值(排序功能)
1136
- * */
1137
- var initDynamicObject = {
1138
- type: 'dynamic-object',
1139
- title: '动态配置',
1140
- description: '',
1141
- isContainer: false,
1142
- properties: {
1143
- type: {
1144
- type: 'select',
1145
- title: '数据来源',
1146
- options: [
1147
- {
1148
- label: '模板直接设置',
1149
- value: 'DevDefaults',
1150
- },
1151
- {
1152
- label: 'mp后台配置',
1153
- value: 'ContentStaticConfig',
1154
- },
1155
- {
1156
- label: '内容Meta数据',
1157
- value: 'Content',
1158
- },
1159
- {
1160
- label: '全局配置数据',
1161
- value: 'RuntimeConst',
1162
- },
1163
- {
1164
- label: '资源中心配置',
1165
- value: 'ResourceCenter',
1166
- },
1167
- ],
1168
- default: 'DevDefaults',
1169
- isConditionProp: true,
1170
- description:
1171
- '目前支持的数据来源包括: 1)模版直接设置: 在模版配置直接生效,支持直接输入或图片上传。 2)mp后台配置: 选择mp后台配置后,属性会出现在mp后台中,支持属性描述的输入。 3)内容meta数据: 支持内容meta数据的获取,页面meta数据。 4)全局配置数据: 目前支持的全局配置包括:全局Tab配置及主题包配置。相关属性会挂载至:window.globalConst',
1172
- },
1173
- value: {
1174
- title: '数据值',
1175
- type: 'input',
1176
- default: '',
1177
- description: '',
1178
- placeholder: '',
1179
- onShow: 'type === "Content" || type === "RuntimeConst"',
1180
- },
1181
- description: {
1182
- title: '自定义配置名称',
1183
- type: 'input',
1184
- default: '主题包配置',
1185
- description: '',
1186
- placeholder: '',
1187
- onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
1188
- },
1189
- attrs: {
1190
- type: 'array',
1191
- title: '属性列表',
1192
- description: 'Tab需要配置的属性',
1193
- items: {
1194
- type: 'object',
1195
- title: '数组项',
1196
- description: '',
1197
- properties: {
1198
- attr: {
1199
- type: 'input',
1200
- title: '属性Key',
1201
- default: '',
1202
- description: '',
1203
- placeholder: '',
1204
- },
1205
- description: {
1206
- title: '描述',
1207
- type: 'input',
1208
- default: '',
1209
- description: '',
1210
- placeholder: '',
1211
- },
1212
- value: {
1213
- title: '数值',
1214
- typeOn:
1215
- "type === 'image' ? 'input-image' : type === 'number' ? 'number' : 'input'",
1216
- default: '',
1217
- description: '',
1218
- placeholder: '',
1219
- },
1220
- type: {
1221
- type: 'select',
1222
- title: '属性类型',
1223
- options: [
1224
- {
1225
- label: '图片类型',
1226
- value: 'image',
1227
- },
1228
- {
1229
- label: '字符串',
1230
- value: 'string',
1231
- },
1232
- {
1233
- label: '数字',
1234
- value: 'number',
1235
- },
1236
- ],
1237
- default: 'string',
1238
- description: '',
1239
- },
1240
- },
1241
- propertyOrder: ['attr', 'description', 'type', 'value'],
1242
- },
1243
- 'minimum-child': 1,
1244
- showCodeViewBtn: false,
1245
- onShow:
1246
- 'type === "DevDefaults" || type === "ContentStaticConfig" || type === "ResourceCenter"',
1247
- },
1248
- },
1249
- propertyOrder: ['type', 'description', 'attrs', 'value'],
1250
- showCodeViewBtn: false,
1251
- showKey: true,
1252
- };
1253
-
1254
- /** dynamic-array: 动态数组,其对象数值支持在json-editor 中动态添加子属性。
1255
- * 【字段属性说明】
1256
- * title:字段项的label值
1257
- * properties:存放所有的子字段数据内容
1258
- * type:用于标识字段项的展示类型(input、date、data-time、url、textarea 等)
1259
- * readOnly:字段项可设置是否可编辑
1260
- * propertyOrder:按序存放所有子字段的key值(排序功能)
1261
- * */
1262
- var initDynamicArray = {
1263
- type: 'dynamic-array',
1264
- title: '动态数组',
1265
- description: '',
1266
- isContainer: false,
1267
- properties: {
1268
- type: {
1269
- type: 'select',
1270
- title: '数据来源',
1271
- options: [
1272
- {
1273
- label: '模板直接设置',
1274
- value: 'DevDefaults',
1275
- },
1276
- {
1277
- label: 'mp后台配置',
1278
- value: 'ContentStaticConfig',
1279
- },
1280
- {
1281
- label: '资源中心配置',
1282
- value: 'ResourceCenter',
1283
- },
1284
- ],
1285
- default: 'DevDefaults',
1286
- isConditionProp: true,
1287
- description:
1288
- '目前支持的数据来源包括: 1)模版直接设置:在模版配置直接生效,支持直接输入或图片上传。 2)mp后台配置:选择mp后台配置后,属性会出现在mp后台中,支持属性描述的输入。 3)内容meta数据:支持内容meta数据的获取,页面meta数据。 4)全局配置数据:目前支持的全局配置包括:全局Tab配置及主题包配置。相关属性会挂载至:window.globalConst',
1289
- },
1290
- description: {
1291
- title: '自定义配置名称',
1292
- type: 'input',
1293
- default: 'Tab全局配置',
1294
- description: '',
1295
- placeholder: '',
1296
- onShow: 'type === "ContentStaticConfig" || type === "ResourceCenter"',
1297
- },
1298
- tabNums: {
1299
- title: 'Tab配置数',
1300
- type: 'number',
1301
- default: 1,
1302
- description: '需要配置的Tab数量',
1303
- placeholder: '',
1304
- onShow: "type === 'ContentStaticConfig' || type === 'ResourceCenter'",
1305
- },
1306
- attrs: {
1307
- type: 'array',
1308
- title: 'Tab属性',
1309
- description: 'Tab需要配置的属性',
1310
- items: {
1311
- type: 'object',
1312
- title: '数组项',
1313
- description: '',
1314
- properties: {
1315
- attr: {
1316
- type: 'input',
1317
- title: '属性Key',
1318
- default: '',
1319
- description: '',
1320
- placeholder: '',
1321
- },
1322
- description: {
1323
- title: '描述',
1324
- type: 'input',
1325
- default: '',
1326
- description: '',
1327
- placeholder: '',
1328
- },
1329
- tipText: {
1330
- title: '提示说明',
1331
- type: 'textarea',
1332
- default: '',
1333
- description: '',
1334
- placeholder: '',
1335
- },
1336
- },
1337
- propertyOrder: ['attr', 'description', 'tipText'],
1338
- },
1339
- 'minimum-child': 1,
1340
- onShow: "type === 'ContentStaticConfig' || type === 'ResourceCenter'",
1341
- showCodeViewBtn: false,
1342
- },
1343
- value: {
1344
- type: 'array',
1345
- title: 'Tab配置',
1346
- description: '',
1347
- items: {
1348
- type: 'object',
1349
- title: '数组项',
1350
- description: '',
1351
- properties: {
1352
- title: {
1353
- type: 'input',
1354
- title: '名称',
1355
- default: '',
1356
- description: '',
1357
- placeholder: '',
1358
- },
1359
- id: {
1360
- title: 'id',
1361
- type: 'input',
1362
- default: '',
1363
- description: '',
1364
- placeholder: '',
1365
- },
1366
- value: {
1367
- title: '数值',
1368
- type: 'input',
1369
- default: '',
1370
- description: '',
1371
- placeholder: '',
1372
- },
1373
- },
1374
- propertyOrder: ['title', 'value', 'id'],
1375
- },
1376
- 'minimum-child': 1,
1377
- onShow: "type === 'DevDefaults'",
1378
- showCodeViewBtn: false,
1379
- },
1380
- },
1381
- propertyOrder: ['type', 'value', 'description', 'tabNums', 'attrs'],
1382
- showCodeViewBtn: false,
1383
- showKey: true,
1384
- };
1385
-
1386
- var initSohuSourceData = {
1387
- type: 'sohu-source',
1388
- title: '数据源',
1389
- description: '',
1390
- isContainer: false,
1391
- properties: {
1392
- mainConfig: {
1393
- type: 'object',
1394
- title: '主要配置',
1395
- description: '',
1396
- isContainer: false,
1397
- properties: {
1398
- type: {
1399
- type: 'select',
1400
- title: '数据来源',
1401
- isConditionProp: true,
1402
- options: [
1403
- /*
1404
- {
1405
- label: '模板直接配置',
1406
- value: "DevDefaults",
1407
- },
1408
- */
1409
- {
1410
- label: '模板自定义数据源',
1411
- value: 'RuntimeDataSelfDefine',
1412
- },
1413
- {
1414
- label: 'mp后台配置',
1415
- value: 'ContentStaticConfig',
1416
- },
1417
- {
1418
- label: '请求当前页面数据',
1419
- value: 'RuntimeDataSelfContent',
1420
- },
1421
- {
1422
- label: '资源中心配置',
1423
- value: 'ResourceCenter',
1424
- },
1425
- ],
1426
- default: 'RuntimeDataSelfDefine',
1427
- description: '',
1428
- },
1429
- description: {
1430
- title: '数据源名称',
1431
- type: 'input',
1432
- description: '',
1433
- placeholder: '',
1434
- onShow: 'type === "ContentStaticConfig"',
1435
- },
1436
- dataType: {
1437
- type: 'radio',
1438
- title: '请求方式',
1439
- default: false,
1440
- options: [
1441
- {
1442
- label: '批量请求',
1443
- value: 'FROMCIS',
1444
- },
1445
- {
1446
- label: '组件内部请求',
1447
- value: 'FROMCOMPCIS',
1448
- },
1449
- {
1450
- label: '不请求',
1451
- value: false,
1452
- },
1453
- ],
1454
- description: '',
1455
- },
1456
- CONTENTID: {
1457
- title: '数据源ID',
1458
- type: 'input',
1459
- description: '',
1460
- placeholder: '',
1461
- onShow: 'type === "RuntimeDataSelfDefine"',
1462
- },
1463
- CONTENTTYPE: {
1464
- type: 'select',
1465
- title: '数据源类型',
1466
- options: [
1467
- {
1468
- label: 'channel',
1469
- value: 13,
1470
- },
1471
- {
1472
- label: 'topic',
1473
- value: 15,
1474
- },
1475
- {
1476
- label: 'block',
1477
- value: 14,
1478
- },
1479
- ],
1480
- description: '',
1481
- onShow: 'type === "RuntimeDataSelfDefine"',
1482
- },
1483
- },
1484
- propertyOrder: [
1485
- 'type',
1486
- 'description',
1487
- 'dataType',
1488
- 'CONTENTID',
1489
- 'CONTENTTYPE',
1490
- ],
1491
- showCodeViewBtn: false,
1492
- },
1493
- outConfig: {
1494
- type: 'object',
1495
- title: '出流配置',
1496
- description: '',
1497
- isContainer: false,
1498
- properties: {
1499
- PRO: {
1500
- type: 'select',
1501
- title: '内容类型',
1502
- options: [
1503
- {
1504
- label: '置顶+加精',
1505
- value: '4',
1506
- },
1507
- {
1508
- label: '长效置顶',
1509
- value: '5',
1510
- },
1511
- ],
1512
- description: '',
1513
- },
1514
- FEEDTYPE: {
1515
- type: 'select',
1516
- title: '排序类型',
1517
- options: [
1518
- {
1519
- label: '综合',
1520
- value: 'XTOPIC_SYNTHETICAL',
1521
- },
1522
- {
1523
- label: '最新',
1524
- value: 'XTOPIC_LATEST',
1525
- },
1526
- {
1527
- label: '相关',
1528
- value: 'XTOPIC_RELATED',
1529
- },
1530
- ],
1531
- description: '',
1532
- },
1533
- VIEW: {
1534
- type: 'select',
1535
- title: '数据裁剪',
1536
- options: [
1537
- {
1538
- label: '相关推荐模式',
1539
- value: 'articleFeedMode',
1540
- },
1541
- {
1542
- label: '文字链裁剪方式',
1543
- value: 'textMode',
1544
- },
1545
- {
1546
- label: '短内容摘录方式',
1547
- value: 'excerptMode',
1548
- },
1549
- {
1550
- label: '互动(点赞/评论)裁剪方式',
1551
- value: 'interactMode',
1552
- },
1553
- {
1554
- label: '评论文字链裁剪方式',
1555
- value: 'commentTextMode',
1556
- },
1557
- {
1558
- label: '摘录方式(无点赞)',
1559
- value: 'excerptCommentMode',
1560
- },
1561
- {
1562
- label: '无限流卡片模式',
1563
- value: 'dynamicFeedMode',
1564
- },
1565
- {
1566
- label: '时间线模式',
1567
- value: 'timeLineMode',
1568
- },
1569
- {
1570
- label: '复合内容流模式',
1571
- value: 'multiFeedMode',
1572
- },
1573
- {
1574
- label: '搜狐号推荐模式',
1575
- value: 'recommendFeedMode',
1576
- },
1577
- {
1578
- label: '作者页内容流模式',
1579
- value: 'operateFeedMode',
1580
- },
1581
- {
1582
- label: '标签内容流模式',
1583
- value: 'tagsFeedMode',
1584
- },
1585
- {
1586
- label: '评论链裁剪方式',
1587
- value: 'commentMode',
1588
- },
1589
- {
1590
- label: '标签摘录方式',
1591
- value: 'excerptTagsMode',
1592
- },
1593
- {
1594
- label: '内容流模式',
1595
- value: 'feedMode',
1596
- },
1597
- ],
1598
- description: '',
1599
- },
1600
- CONTENTCONTEXT: {
1601
- type: 'select',
1602
- title: 'mKey参数',
1603
- options: [
1604
- {
1605
- label: '作者ID+栏目ID',
1606
- value: 'authorColumnId_${#authorColumnId}',
1607
- },
1608
- {
1609
- label: '账号ID',
1610
- value: 'accountId_${#contentData_account_id}',
1611
- },
1612
- {
1613
- label: 'mkeyID',
1614
- value: 'mid_${#mkeyConst_mid}',
1615
- },
1616
- {
1617
- label: 'mkey名称',
1618
- value: 'mname_${#mkeyConst_mname}',
1619
- },
1620
- {
1621
- label: '城市Code码',
1622
- value: 'cityCode_${#cityInfo_cityCode}',
1623
- },
1624
- {
1625
- label: '城市名称',
1626
- value: 'cityName_${#cityInfo_cityName}',
1627
- },
1628
- {
1629
- label: '焦点城市Code码',
1630
- value: 'focusCityCode_${#focusCityInfo_cityCode}',
1631
- },
1632
- ],
1633
- description: '',
1634
- },
1635
- CONTENTPARAMS: {
1636
- title: '动态参数',
1637
- type: 'json',
1638
- description: '请填写JSON格式的参数',
1639
- placeholder: '',
1640
- },
1641
- },
1642
- propertyOrder: [
1643
- 'PRO',
1644
- 'FEEDTYPE',
1645
- 'VIEW',
1646
- 'CONTENTCONTEXT',
1647
- 'CONTENTPARAMS',
1648
- ],
1649
- showCodeViewBtn: false,
1650
- },
1651
- otherConfig: {
1652
- type: 'object',
1653
- title: '选配内容',
1654
- description: '',
1655
- isContainer: false,
1656
- properties: {
1657
- SIZE: {
1658
- type: 'number',
1659
- title: '容量',
1660
- minimum: 0,
1661
- maximum: 1000,
1662
- description: '该位置区块需要的内容条数',
1663
- },
1664
- TITLE: {
1665
- title: '标题',
1666
- type: 'input',
1667
- description: '',
1668
- placeholder: '',
1669
- },
1670
- URL: {
1671
- type: 'url',
1672
- title: '更多跳转链接',
1673
- description: '该区块下点击“更多或箭头图标”后的跳转链接',
1674
- placeholder: '',
1675
- },
1676
- CODE: {
1677
- title: 'Code参数',
1678
- type: 'input',
1679
- description: '',
1680
- placeholder: '',
1681
- onShow: false,
1682
- },
1683
- },
1684
- propertyOrder: ['SIZE', 'TITLE', 'URL', 'CODE'],
1685
- showCodeViewBtn: false,
1686
- },
1687
- },
1688
- propertyOrder: ['mainConfig', 'otherConfig', 'outConfig'],
1689
- showCodeViewBtn: false,
1690
- };
1691
- var initAdConfigSchema = {
1692
- type: 'object',
1693
- title: '广告配置',
1694
- description: '',
1695
- properties: {
1696
- type: {
1697
- type: 'select',
1698
- title: '数据源类型',
1699
- isConditionProp: true,
1700
- options: [
1701
- {
1702
- label: '模板直接设置',
1703
- value: 'DevDefaults',
1704
- },
1705
- {
1706
- label: '资源中心配置',
1707
- value: 'ResourceCenter',
1708
- },
1709
- ],
1710
- description: '',
1711
- },
1712
- value: {
1713
- type: 'object',
1714
- title: '广告规则',
1715
- description: '',
1716
- onShow: 'type === "DevDefaults"',
1717
- properties: {
1718
- id: {
1719
- title: '广告ID',
1720
- type: 'number',
1721
- description: '',
1722
- placeholder: '',
1723
- },
1724
- rule: {
1725
- type: 'radio',
1726
- title: '规则类型',
1727
- isConditionProp: true,
1728
- options: [
1729
- {
1730
- label: '固定位置',
1731
- value: 1,
1732
- },
1733
- {
1734
- label: '隔几出几',
1735
- value: 2,
1736
- },
1737
- {
1738
- label: '固定位置隔几出几',
1739
- value: 3,
1740
- },
1741
- ],
1742
- description: '',
1743
- },
1744
- fixArray: {
1745
- type: 'select',
1746
- title: '固定位置',
1747
- description: '',
1748
- multiple: true,
1749
- onShow: 'rule === 1 || rule === 3',
1750
- options: [
1751
- {
1752
- label: '1',
1753
- value: 1,
1754
- },
1755
- {
1756
- label: '2',
1757
- value: 2,
1758
- },
1759
- {
1760
- label: '3',
1761
- value: 3,
1762
- },
1763
- {
1764
- label: '4',
1765
- value: 4,
1766
- },
1767
- {
1768
- label: '5',
1769
- value: 5,
1770
- },
1771
- {
1772
- label: '6',
1773
- value: 6,
1774
- },
1775
- {
1776
- label: '7',
1777
- value: 7,
1778
- },
1779
- {
1780
- label: '8',
1781
- value: 8,
1782
- },
1783
- {
1784
- label: '9',
1785
- value: 9,
1786
- },
1787
- {
1788
- label: '10',
1789
- value: 10,
1790
- },
1791
- {
1792
- label: '11',
1793
- value: 11,
1794
- },
1795
- {
1796
- label: '12',
1797
- value: 12,
1798
- },
1799
- {
1800
- label: '13',
1801
- value: 13,
1802
- },
1803
- {
1804
- label: '14',
1805
- value: 14,
1806
- },
1807
- {
1808
- label: '15',
1809
- value: 15,
1810
- },
1811
- {
1812
- label: '16',
1813
- value: 16,
1814
- },
1815
- {
1816
- label: '17',
1817
- value: 17,
1818
- },
1819
- {
1820
- label: '18',
1821
- value: 18,
1822
- },
1823
- {
1824
- label: '19',
1825
- value: 19,
1826
- },
1827
- {
1828
- label: '20',
1829
- value: 20,
1830
- },
1831
- {
1832
- label: '21',
1833
- value: 21,
1834
- },
1835
- {
1836
- label: '22',
1837
- value: 22,
1838
- },
1839
- {
1840
- label: '23',
1841
- value: 23,
1842
- },
1843
- {
1844
- label: '24',
1845
- value: 24,
1846
- },
1847
- {
1848
- label: '25',
1849
- value: 25,
1850
- },
1851
- {
1852
- label: '26',
1853
- value: 26,
1854
- },
1855
- {
1856
- label: '27',
1857
- value: 27,
1858
- },
1859
- {
1860
- label: '28',
1861
- value: 28,
1862
- },
1863
- {
1864
- label: '29',
1865
- value: 29,
1866
- },
1867
- {
1868
- label: '30',
1869
- value: 30,
1870
- },
1871
- {
1872
- label: '31',
1873
- value: 31,
1874
- },
1875
- {
1876
- label: '32',
1877
- value: 32,
1878
- },
1879
- {
1880
- label: '33',
1881
- value: 33,
1882
- },
1883
- {
1884
- label: '34',
1885
- value: 34,
1886
- },
1887
- {
1888
- label: '35',
1889
- value: 35,
1890
- },
1891
- {
1892
- label: '36',
1893
- value: 36,
1894
- },
1895
- {
1896
- label: '37',
1897
- value: 37,
1898
- },
1899
- {
1900
- label: '38',
1901
- value: 38,
1902
- },
1903
- {
1904
- label: '39',
1905
- value: 39,
1906
- },
1907
- {
1908
- label: '40',
1909
- value: 40,
1910
- },
1911
- {
1912
- label: '41',
1913
- value: 41,
1914
- },
1915
- {
1916
- label: '42',
1917
- value: 42,
1918
- },
1919
- {
1920
- label: '43',
1921
- value: 43,
1922
- },
1923
- {
1924
- label: '44',
1925
- value: 44,
1926
- },
1927
- {
1928
- label: '45',
1929
- value: 45,
1930
- },
1931
- {
1932
- label: '46',
1933
- value: 46,
1934
- },
1935
- {
1936
- label: '47',
1937
- value: 47,
1938
- },
1939
- {
1940
- label: '48',
1941
- value: 48,
1942
- },
1943
- {
1944
- label: '49',
1945
- value: 49,
1946
- },
1947
- {
1948
- label: '50',
1949
- value: 50,
1950
- },
1951
- ],
1952
- },
1953
- begin: {
1954
- type: 'number',
1955
- title: '开始位置',
1956
- minimum: '1',
1957
- maximum: '50',
1958
- description: '',
1959
- onShow: 'rule === 2 || rule === 3',
1960
- },
1961
- turn: {
1962
- type: 'number',
1963
- title: '间隔/隔',
1964
- minimum: '1',
1965
- maximum: '50',
1966
- description: '',
1967
- onShow: 'rule === 2 || rule === 3',
1968
- },
1969
- number: {
1970
- type: 'number',
1971
- title: '间隔/出',
1972
- minimum: '1',
1973
- maximum: '50',
1974
- description: '',
1975
- onShow: 'rule === 2 || rule === 3',
1976
- },
1977
- mergeType: {
1978
- type: 'radio',
1979
- title: '插入规则',
1980
- options: [
1981
- {
1982
- label: '覆盖',
1983
- value: 0,
1984
- },
1985
- {
1986
- label: '插入',
1987
- value: 1,
1988
- },
1989
- ],
1990
- description: '',
1991
- },
1992
- },
1993
- propertyOrder: [
1994
- 'id',
1995
- 'rule',
1996
- 'fixArray',
1997
- 'begin',
1998
- 'turn',
1999
- 'number',
2000
- 'mergeType',
2001
- ],
2002
- },
2003
- range: {
2004
- type: 'array',
2005
- title: '广告规则列表',
2006
- description: '',
2007
- onShow: 'type === "ResourceCenter"',
2008
- items: {
2009
- type: 'object',
2010
- title: '数组项',
2011
- description: '',
2012
- properties: {
2013
- rule: {
2014
- type: 'radio',
2015
- title: '规则类型',
2016
- isConditionProp: true,
2017
- options: [
2018
- {
2019
- label: '固定位置',
2020
- value: 1,
2021
- },
2022
- {
2023
- label: '隔几出几',
2024
- value: 2,
2025
- },
2026
- {
2027
- label: '固定位置隔几出几',
2028
- value: 3,
2029
- },
2030
- ],
2031
- description: '',
2032
- },
2033
- fixArray: {
2034
- type: 'select',
2035
- title: '固定位置',
2036
- description: '',
2037
- onShow: 'rule === 1 || rule === 3',
2038
- multiple: true,
2039
- options: [
2040
- {
2041
- label: '1',
2042
- value: 1,
2043
- },
2044
- {
2045
- label: '2',
2046
- value: 2,
2047
- },
2048
- {
2049
- label: '3',
2050
- value: 3,
2051
- },
2052
- {
2053
- label: '4',
2054
- value: 4,
2055
- },
2056
- {
2057
- label: '5',
2058
- value: 5,
2059
- },
2060
- {
2061
- label: '6',
2062
- value: 6,
2063
- },
2064
- {
2065
- label: '7',
2066
- value: 7,
2067
- },
2068
- {
2069
- label: '8',
2070
- value: 8,
2071
- },
2072
- {
2073
- label: '9',
2074
- value: 9,
2075
- },
2076
- {
2077
- label: '10',
2078
- value: 10,
2079
- },
2080
- {
2081
- label: '11',
2082
- value: 11,
2083
- },
2084
- {
2085
- label: '12',
2086
- value: 12,
2087
- },
2088
- {
2089
- label: '13',
2090
- value: 13,
2091
- },
2092
- {
2093
- label: '14',
2094
- value: 14,
2095
- },
2096
- {
2097
- label: '15',
2098
- value: 15,
2099
- },
2100
- {
2101
- label: '16',
2102
- value: 16,
2103
- },
2104
- {
2105
- label: '17',
2106
- value: 17,
2107
- },
2108
- {
2109
- label: '18',
2110
- value: 18,
2111
- },
2112
- {
2113
- label: '19',
2114
- value: 19,
2115
- },
2116
- {
2117
- label: '20',
2118
- value: 20,
2119
- },
2120
- {
2121
- label: '21',
2122
- value: 21,
2123
- },
2124
- {
2125
- label: '22',
2126
- value: 22,
2127
- },
2128
- {
2129
- label: '23',
2130
- value: 23,
2131
- },
2132
- {
2133
- label: '24',
2134
- value: 24,
2135
- },
2136
- {
2137
- label: '25',
2138
- value: 25,
2139
- },
2140
- {
2141
- label: '26',
2142
- value: 26,
2143
- },
2144
- {
2145
- label: '27',
2146
- value: 27,
2147
- },
2148
- {
2149
- label: '28',
2150
- value: 28,
2151
- },
2152
- {
2153
- label: '29',
2154
- value: 29,
2155
- },
2156
- {
2157
- label: '30',
2158
- value: 30,
2159
- },
2160
- {
2161
- label: '31',
2162
- value: 31,
2163
- },
2164
- {
2165
- label: '32',
2166
- value: 32,
2167
- },
2168
- {
2169
- label: '33',
2170
- value: 33,
2171
- },
2172
- {
2173
- label: '34',
2174
- value: 34,
2175
- },
2176
- {
2177
- label: '35',
2178
- value: 35,
2179
- },
2180
- {
2181
- label: '36',
2182
- value: 36,
2183
- },
2184
- {
2185
- label: '37',
2186
- value: 37,
2187
- },
2188
- {
2189
- label: '38',
2190
- value: 38,
2191
- },
2192
- {
2193
- label: '39',
2194
- value: 39,
2195
- },
2196
- {
2197
- label: '40',
2198
- value: 40,
2199
- },
2200
- {
2201
- label: '41',
2202
- value: 41,
2203
- },
2204
- {
2205
- label: '42',
2206
- value: 42,
2207
- },
2208
- {
2209
- label: '43',
2210
- value: 43,
2211
- },
2212
- {
2213
- label: '44',
2214
- value: 44,
2215
- },
2216
- {
2217
- label: '45',
2218
- value: 45,
2219
- },
2220
- {
2221
- label: '46',
2222
- value: 46,
2223
- },
2224
- {
2225
- label: '47',
2226
- value: 47,
2227
- },
2228
- {
2229
- label: '48',
2230
- value: 48,
2231
- },
2232
- {
2233
- label: '49',
2234
- value: 49,
2235
- },
2236
- {
2237
- label: '50',
2238
- value: 50,
2239
- },
2240
- ],
2241
- },
2242
- begin: {
2243
- type: 'number',
2244
- title: '开始位置',
2245
- minimum: '1',
2246
- maximum: '50',
2247
- description: '',
2248
- onShow: 'rule === 2 || rule === 3',
2249
- },
2250
- turn: {
2251
- type: 'number',
2252
- title: '间隔/隔',
2253
- minimum: '1',
2254
- maximum: '50',
2255
- description: '',
2256
- onShow: 'rule === 2 || rule === 3',
2257
- },
2258
- number: {
2259
- type: 'number',
2260
- title: '间隔/出',
2261
- minimum: '1',
2262
- maximum: '50',
2263
- description: '',
2264
- onShow: 'rule === 2 || rule === 3',
2265
- },
2266
- mergeType: {
2267
- type: 'radio',
2268
- title: '插入规则',
2269
- options: [
2270
- {
2271
- label: '覆盖',
2272
- value: 0,
2273
- },
2274
- {
2275
- label: '插入',
2276
- value: 1,
2277
- },
2278
- ],
2279
- description: '',
2280
- },
2281
- },
2282
- propertyOrder: [
2283
- 'rule',
2284
- 'fixArray',
2285
- 'begin',
2286
- 'turn',
2287
- 'number',
2288
- 'mergeType',
2289
- ],
2290
- },
2291
- },
2292
- },
2293
- propertyOrder: ['type', 'value', 'range'],
2294
- };
2295
-
2296
- /** dynamicConfig: 动态配置
2297
- * 【字段属性说明】
2298
- * title:字段项的label值
2299
- * properties:存放所有的子字段数据内容
2300
- * type:用于标识字段项的展示类型(input、date、data-time、url、textarea 等)
2301
- * readOnly:字段项可设置是否可编辑
2302
- * propertyOrder:按序存放所有子字段的key值(排序功能)
2303
- * */
2304
- var initSohuEventConfig = {
2305
- type: 'sohu-event',
2306
- title: 'sohu组件事件',
2307
- showCodeViewBtn: false,
2308
- isContainer: false,
2309
- properties: {
2310
- globalEventMap: {
2311
- type: 'object',
2312
- title: '全局事件Map',
2313
- description: '',
2314
- properties: {
2315
- eventCode: {
2316
- type: 'input',
2317
- title: '事件名称',
2318
- default: '',
2319
- description: '',
2320
- placeholder: '',
2321
- readOnly: true,
2322
- },
2323
- },
2324
- propertyOrder: ['eventCode'],
2325
- showCodeViewBtn: false,
2326
- },
2327
- event: {
2328
- type: 'array',
2329
- title: '监听事件',
2330
- description: '当前组件监听事件列表',
2331
- default: [],
2332
- items: {
2333
- type: 'object',
2334
- title: '数组项',
2335
- description: '',
2336
- properties: {
2337
- name: {
2338
- type: 'input',
2339
- title: '事件',
2340
- default: '',
2341
- description: '',
2342
- placeholder: '',
2343
- },
2344
- code: {
2345
- title: '事件code',
2346
- type: 'input',
2347
- default: '',
2348
- description: '',
2349
- placeholder: '',
2350
- },
2351
- listenName: {
2352
- title: '事件名称',
2353
- type: 'input',
2354
- default: '',
2355
- description: '',
2356
- placeholder: '',
2357
- },
2358
- desc: {
2359
- title: '事件描述',
2360
- type: 'input',
2361
- default: '',
2362
- description: '',
2363
- placeholder: '',
2364
- },
2365
- },
2366
- propertyOrder: ['name', 'code', 'listenName', 'desc'],
2367
- },
2368
- showCodeViewBtn: false,
2369
- },
2370
- },
2371
- propertyOrder: ['globalEventMap', 'event'],
2372
- };
2373
-
2374
1036
  // 类型数据清单
2375
1037
  var TypeDataList = {
2376
1038
  jsonschema: initJSONSchemaData,
@@ -2403,12 +1065,6 @@ var TypeDataList = {
2403
1065
  'dynamic-data': initDynamicData,
2404
1066
  datasource: initDataSourceData,
2405
1067
  event: initEventData,
2406
- 'dynamic-config': initDynamicConfig,
2407
- 'dynamic-object': initDynamicObject,
2408
- 'dynamic-array': initDynamicArray,
2409
- 'sohu-source': initSohuSourceData,
2410
- 'sohu-event': initSohuEventConfig,
2411
- 'sohu-ad': initAdConfigSchema,
2412
1068
  };
2413
1069
 
2414
1070
  // 事件类型数据
@@ -7804,11 +6460,6 @@ var valExpectType =
7804
6460
  (_valExpectType['text-editor'] = 'string'),
7805
6461
  (_valExpectType.time = 'string'),
7806
6462
  (_valExpectType.url = 'string'),
7807
- (_valExpectType['dynamic-config'] = 'object'),
7808
- (_valExpectType['dynamic-object'] = 'object'),
7809
- (_valExpectType['dynamic-array'] = 'object'),
7810
- (_valExpectType['sohu-source'] = 'object'),
7811
- (_valExpectType['sohu-event'] = 'object'),
7812
6463
  _valExpectType);
7813
6464
 
7814
6465
  // 根据type获取对应元素的期望类型值