fmui-base 2.0.66 → 2.0.68

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/README.md CHANGED
@@ -3,6 +3,8 @@
3
3
  ---npm publish
4
4
 
5
5
  ## 更新日志
6
+ - 2.0.68:dom结构加载完成回调
7
+ - 2.0.67:批示意见常用语样式修改和加载逻辑修改
6
8
  - 2.0.66:默认批示意见常用语编辑跳转
7
9
  - 2.0.65:移动端门户边距修改
8
10
  - 2.0.64:移动端门户常用应用修改
package/lib/form/form.js CHANGED
@@ -2652,10 +2652,11 @@ var PageHome = function (_React$Component) {
2652
2652
  value: function selectCommonwords() {
2653
2653
  var t = this;
2654
2654
  t.setState({ fold: !this.state.fold });
2655
- var phraseListNow = t.state.phraseList;
2656
- if (phraseListNow.length > 0) {
2657
- // t.refs.slotCommonwords.show();
2658
- } else {
2655
+ // let phraseListNow = t.state.phraseList;
2656
+ // if (phraseListNow.length > 0) {
2657
+ // t.refs.slotCommonwords.show();
2658
+ // } else {
2659
+ if (this.state.fold) {
2659
2660
  //获取常用语列表
2660
2661
  _db2.default.FlowModuleAPI.getPersonalPhrase({}).then(function (content) {
2661
2662
  if (content.length > 0) {
@@ -2663,13 +2664,13 @@ var PageHome = function (_React$Component) {
2663
2664
  content.map(function (item) {
2664
2665
  phraseList1.push({ text: item.content, value: item.content });
2665
2666
  });
2666
- var phraseList2 = [];
2667
- phraseList2.push(phraseList1);
2667
+ // var phraseList2 = [];
2668
+ // phraseList2.push(phraseList1);
2668
2669
  t.setState({
2669
- phraseList: phraseList2,
2670
+ // phraseList: phraseList2,
2670
2671
  phraseListNew: phraseList1
2671
2672
  }, function () {
2672
- // t.refs.slotCommonwords.show();
2673
+ // t.refs.slotCommonwords.show();
2673
2674
  });
2674
2675
  } else {
2675
2676
  _Toast2.default.show({
@@ -2683,6 +2684,8 @@ var PageHome = function (_React$Component) {
2683
2684
  });
2684
2685
  });
2685
2686
  }
2687
+ // }
2688
+
2686
2689
  }
2687
2690
 
2688
2691
  //常用语设置跳转
@@ -2690,6 +2693,7 @@ var PageHome = function (_React$Component) {
2690
2693
  }, {
2691
2694
  key: 'skipToCommonwordsSet',
2692
2695
  value: function skipToCommonwordsSet() {
2696
+ this.setState({ fold: true });
2693
2697
  pageSkip('mobile/modules/mobileoffice/dist/index.html', '#/hospitalmanage/personal/setting/listPhrase');
2694
2698
  }
2695
2699
  }, {
@@ -656,7 +656,7 @@ var PageHome = function (_React$Component) {
656
656
  'div',
657
657
  { className: item.show ? "" : "t-DN" },
658
658
  item.form.map(function (item2, j) {
659
- return _react2.default.createElement(_form2.default, { keyNo: i, ref: item2.uniqueName + '_' + i, dataType: 'sub', subTblName: t.state.itemParam.key, module: t.state.module, formKey: item2.formKey, status: t.state.status, form: item2, allForm: t.props.allForm, formStyle: t.props.formStyle, data: t.state.itemParam.value[i], fieldControll: t.state.fieldControll, caIsPrd: t.props.caIsPrd, preCaFields: t.props.preCaFields, formRelaFieldMaps: t.props.formRelaFieldMaps, linkFields: t.props.linkFields, onChange: _this2.changeSub.bind(_this2, _this2.state.itemParam, i) });
659
+ return _react2.default.createElement(_form2.default, { className: "subform_" + item2.uniqueName, keyNo: i, ref: item2.uniqueName + '_' + i, dataType: 'sub', subTblName: t.state.itemParam.key, module: t.state.module, formKey: item2.formKey, status: t.state.status, form: item2, allForm: t.props.allForm, formStyle: t.props.formStyle, data: t.state.itemParam.value[i], fieldControll: t.state.fieldControll, caIsPrd: t.props.caIsPrd, preCaFields: t.props.preCaFields, formRelaFieldMaps: t.props.formRelaFieldMaps, linkFields: t.props.linkFields, onChange: _this2.changeSub.bind(_this2, _this2.state.itemParam, i) });
660
660
  })
661
661
  )
662
662
  );
package/lib/form/table.js CHANGED
@@ -786,8 +786,9 @@ var PageHome = function (_React$Component) {
786
786
  $('.hejidiv-' + subTableName).find('span')[le - 1].innerText = tx.replace(';', '');
787
787
  }
788
788
  }
789
+
790
+ this.props.onChange(data, itemParam);
789
791
  }
790
- this.props.onChange(data);
791
792
  }
792
793
 
793
794
  //重新加载关联字段
@@ -1450,10 +1451,11 @@ var PageHome = function (_React$Component) {
1450
1451
  value: function selectCommonwords() {
1451
1452
  var t = this;
1452
1453
  t.setState({ fold: !this.state.fold });
1453
- var phraseListNow = t.state.phraseList;
1454
- if (phraseListNow.length > 0) {
1455
- // t.refs.slotCommonwords.show();
1456
- } else {
1454
+ // let phraseListNow = t.state.phraseList;
1455
+ // if (phraseListNow.length > 0) {
1456
+ // t.refs.slotCommonwords.show();
1457
+ // } else {
1458
+ if (this.state.fold) {
1457
1459
  //获取常用语列表
1458
1460
  _db2.default.FlowModuleAPI.getPersonalPhrase({}).then(function (content) {
1459
1461
  if (content.length > 0) {
@@ -1461,10 +1463,10 @@ var PageHome = function (_React$Component) {
1461
1463
  content.map(function (item) {
1462
1464
  phraseList1.push({ text: item.content, value: item.content });
1463
1465
  });
1464
- var phraseList2 = [];
1465
- phraseList2.push(phraseList1);
1466
+ // var phraseList2 = [];
1467
+ // phraseList2.push(phraseList1);
1466
1468
  t.setState({
1467
- phraseList: phraseList2,
1469
+ // phraseList: phraseList2,
1468
1470
  phraseListNew: phraseList1
1469
1471
  }, function () {
1470
1472
  // t.refs.slotCommonwords.show();
@@ -1481,6 +1483,8 @@ var PageHome = function (_React$Component) {
1481
1483
  });
1482
1484
  });
1483
1485
  }
1486
+ // }
1487
+
1484
1488
  }
1485
1489
 
1486
1490
  //常用语设置跳转
@@ -1488,6 +1492,7 @@ var PageHome = function (_React$Component) {
1488
1492
  }, {
1489
1493
  key: 'skipToCommonwordsSet',
1490
1494
  value: function skipToCommonwordsSet() {
1495
+ this.setState({ fold: true });
1491
1496
  pageSkip('mobile/modules/mobileoffice/dist/index.html', '#/hospitalmanage/personal/setting/listPhrase');
1492
1497
  }
1493
1498
  }, {
@@ -1553,16 +1558,16 @@ var PageHome = function (_React$Component) {
1553
1558
  return item.itemType == 'twocolumns' || item.itemType == 'threecolumns' ? item.children.map(function (item2, j) {
1554
1559
  return _react2.default.createElement(
1555
1560
  'div',
1556
- null,
1557
- _react2.default.createElement(_form2.default, { keyNo: j, ref: item.uniqueName, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item2, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, defaultValue: t.props.defaultValue, data: t.props.data, fieldControll: t.props.fieldControll, caIsPrd: t.props.caIsPrd, preCaFields: t.props.preCaFields, formRelaFieldMaps: t.state.formRelaFieldMaps, linkFields: t.state.linkFields, onChange: this.change.bind(this) })
1561
+ { className: "form_" + item2.uniqueName },
1562
+ _react2.default.createElement(_form2.default, { keyNo: j, ref: item2.uniqueName, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item2, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, defaultValue: t.props.defaultValue, data: t.props.data, fieldControll: t.props.fieldControll, caIsPrd: t.props.caIsPrd, preCaFields: t.props.preCaFields, formRelaFieldMaps: t.state.formRelaFieldMaps, linkFields: t.state.linkFields, onChange: this.change.bind(this) })
1558
1563
  );
1559
1564
  }.bind(this)) : item.itemType == 'detail' ? _react2.default.createElement(
1560
1565
  'div',
1561
- null,
1566
+ { className: "subform_" + item.itemCode },
1562
1567
  _react2.default.createElement(_subForm2.default, { keyNo: i, ref: 'sub_' + item.itemCode, operate: t.props.operate, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, defaultValue: t.props.defaultValue, data: t.props.data, fieldControll: t.props.fieldControll, caIsPrd: t.props.caIsPrd, preCaFields: t.props.preCaFields, formRelaFieldMaps: t.state.formRelaFieldMaps, linkFields: t.state.linkFields, onChange: this.change.bind(this) })
1563
1568
  ) : _react2.default.createElement(
1564
1569
  'div',
1565
- null,
1570
+ { className: "form_" + item.uniqueName },
1566
1571
  _react2.default.createElement(_form2.default, { ref: item.uniqueName, keyNo: i, operate: t.props.operate, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, defaultValue: t.props.defaultValue, data: t.props.data, fieldControll: t.props.fieldControll, caIsPrd: t.props.caIsPrd, preCaFields: t.props.preCaFields, formRelaFieldMaps: t.state.formRelaFieldMaps, linkFields: t.state.linkFields, onChange: this.change.bind(this) })
1567
1572
  );
1568
1573
  }.bind(this)) : "" : _react2.default.createElement(
@@ -1590,16 +1595,16 @@ var PageHome = function (_React$Component) {
1590
1595
  return _react2.default.createElement(
1591
1596
  'div',
1592
1597
  { className: t.state.active == item.tabCode ? "" : "t-DN" },
1593
- _react2.default.createElement(_form2.default, { keyNo: j, ref: item.uniqueName, operate: t.props.operate, hasCommentField: t.props.hasCommentField, newspyj: t.props.newspyj, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item2, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, data: t.props.data, fieldControll: t.props.fieldControll, onChange: this.change.bind(this) })
1598
+ _react2.default.createElement(_form2.default, { className: "form_" + item.uniqueName, keyNo: j, ref: item.uniqueName, operate: t.props.operate, hasCommentField: t.props.hasCommentField, newspyj: t.props.newspyj, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item2, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, data: t.props.data, fieldControll: t.props.fieldControll, onChange: this.change.bind(this) })
1594
1599
  );
1595
1600
  }.bind(this)) : item.itemType == 'detail' ? _react2.default.createElement(
1596
1601
  'div',
1597
1602
  { className: t.state.active == item.tabCode ? "" : "t-DN" },
1598
- _react2.default.createElement(_subForm2.default, { keyNo: i, ref: 'sub_' + item.itemCode, operate: t.props.operate, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, data: t.props.data, fieldControll: t.props.fieldControll, onChange: this.change.bind(this) })
1603
+ _react2.default.createElement(_subForm2.default, { className: "subform_" + item.itemCode, keyNo: i, ref: 'sub_' + item.itemCode, operate: t.props.operate, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, data: t.props.data, fieldControll: t.props.fieldControll, onChange: this.change.bind(this) })
1599
1604
  ) : _react2.default.createElement(
1600
1605
  'div',
1601
1606
  { className: t.state.active == item.tabCode ? "" : "t-DN" },
1602
- _react2.default.createElement(_form2.default, { ref: item.uniqueName, keyNo: i, operate: t.props.operate, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, data: t.props.data, fieldControll: t.props.fieldControll, onChange: this.change.bind(this) })
1607
+ _react2.default.createElement(_form2.default, { className: "form_" + item.uniqueName, ref: item.uniqueName, keyNo: i, operate: t.props.operate, newspyj: t.props.newspyj, hasCommentField: t.props.hasCommentField, commentField: t.props.commentField, module: t.props.module, formKey: t.props.allForm.formcode, status: t.props.status, form: item, allForm: t.props.allForm, formStyle: t.props.formStyleObj, commentList: t.props.commentFieldList, data: t.props.data, fieldControll: t.props.fieldControll, onChange: this.change.bind(this) })
1603
1608
  );
1604
1609
  }.bind(this))
1605
1610
  )
@@ -1624,13 +1629,13 @@ var PageHome = function (_React$Component) {
1624
1629
  )
1625
1630
  )
1626
1631
  ),
1627
- _react2.default.createElement('div', { className: t.props.commentDefaultList && t.props.commentDefaultList.length > 0 ? "t-H10 t-BCf7" : 't-DN' }),
1632
+ _react2.default.createElement('div', { className: t.props.commentDefaultList && t.props.commentDefaultList.length > 0 || t.props.commentField == "default" ? "t-H10 t-BCf7" : 't-DN' }),
1628
1633
  _react2.default.createElement(
1629
1634
  'div',
1630
- { className: t.props.commentDefaultList && t.props.commentDefaultList.length > 0 ? '' : 't-DN' },
1635
+ { className: t.props.commentDefaultList && t.props.commentDefaultList.length > 0 || t.props.commentField == "default" ? '' : 't-DN' },
1631
1636
  _react2.default.createElement(
1632
1637
  HBox,
1633
- { className: 'flex-comment t-field-box' },
1638
+ { className: 'flex-comment default-comment t-field-box' },
1634
1639
  _react2.default.createElement(
1635
1640
  'div',
1636
1641
  { className: 't-field-layout-h-label t-FS16 t-FBJ' },
@@ -1643,7 +1648,7 @@ var PageHome = function (_React$Component) {
1643
1648
  _react2.default.createElement(
1644
1649
  'div',
1645
1650
  { className: 't-PT10 t-FB1' },
1646
- _react2.default.createElement(_List2.default, { list: t.props.commentDefaultList }),
1651
+ t.props.commentDefaultList && t.props.commentDefaultList.length > 0 ? _react2.default.createElement(_List2.default, { list: t.props.commentDefaultList }) : "",
1647
1652
  _react2.default.createElement(
1648
1653
  'div',
1649
1654
  { className: t.props.commentField == "default" ? 't-PL10 t-PR10' : 't-DN' },
@@ -1663,7 +1668,7 @@ var PageHome = function (_React$Component) {
1663
1668
  ),
1664
1669
  _react2.default.createElement(_TextareaField2.default, {
1665
1670
  readOnly: false,
1666
- minRows: 10, maxRows: 13,
1671
+ minRows: 5, maxRows: 10,
1667
1672
  placeholder: '请输入批示意见',
1668
1673
  value: this.state.spyj,
1669
1674
  onChange: this.changeSpyj1.bind(this) }),
@@ -1692,74 +1697,6 @@ var PageHome = function (_React$Component) {
1692
1697
  )
1693
1698
  )
1694
1699
  )
1695
- ),
1696
- _react2.default.createElement('div', { className: t.props.commentDefaultList && t.props.commentDefaultList.length == 0 && t.props.commentField == "default" ? "t-H10 t-BCf7" : 't-DN' }),
1697
- _react2.default.createElement(
1698
- 'div',
1699
- { className: t.props.commentDefaultList && t.props.commentDefaultList.length == 0 && t.props.commentField == "default" ? '' : 't-DN' },
1700
- _react2.default.createElement(
1701
- HBox,
1702
- { className: 't-field-box' },
1703
- _react2.default.createElement(
1704
- 'div',
1705
- { className: 't-field-layout-h-label t-FS16 t-FBJ' },
1706
- _react2.default.createElement(
1707
- 'span',
1708
- null,
1709
- '\u6279\u793A\u610F\u89C1'
1710
- )
1711
- ),
1712
- _react2.default.createElement(
1713
- 'div',
1714
- { className: t.props.commentField == "default" ? 't-PL10 t-PT10 t-FB1' : 't-DN' },
1715
- _react2.default.createElement(
1716
- 'div',
1717
- { className: 'theme-color t-P6 t-FS16 commonwords' },
1718
- _react2.default.createElement(
1719
- 'div',
1720
- { onClick: this.selectCommonwords.bind(this) },
1721
- '\u5E38\u7528\u8BED'
1722
- ),
1723
- _react2.default.createElement(
1724
- 'div',
1725
- { onClick: this.skipToCommonwordsSet.bind(this) },
1726
- '\u7F16\u8F91'
1727
- )
1728
- ),
1729
- _react2.default.createElement(
1730
- 'div',
1731
- { id: 'defaultCommentInput' },
1732
- _react2.default.createElement(_TextareaField2.default, {
1733
- readOnly: false,
1734
- minRows: 3, maxRows: 5,
1735
- placeholder: '请输入批示意见',
1736
- value: this.state.spyj,
1737
- onChange: this.changeSpyj1.bind(this) })
1738
- ),
1739
- _react2.default.createElement(_CheckboxField2.default, {
1740
- className: this.state.hasCommentField == '1' ? "" : "t-DN",
1741
- data: this.state.savePhraseList,
1742
- mode: 'list',
1743
- onChange: this.selectSavePhrase.bind(this),
1744
- required: false
1745
- }),
1746
- _react2.default.createElement(
1747
- _FoldablePane2.default,
1748
- { foldHeight: 0, isFold: this.state.fold },
1749
- _react2.default.createElement(
1750
- 'div',
1751
- { className: 'phrase-list' },
1752
- this.state.phraseListNew.length > 0 ? this.state.phraseListNew.map(function (item, i) {
1753
- return _react2.default.createElement(
1754
- 'div',
1755
- { className: 'phrase-item', onClick: this.phraseItemClick.bind(this, item.value) },
1756
- item.value
1757
- );
1758
- }.bind(this)) : ''
1759
- )
1760
- )
1761
- )
1762
- )
1763
1700
  )
1764
1701
  );
1765
1702
  }
@@ -1315,6 +1315,33 @@ var PageHome = function (_React$Component) {
1315
1315
  }, function () {
1316
1316
  t.refs["selectMember_circulate"].initSelectData();
1317
1317
  t.refs["selectMember_circulate1"].initSelectData();
1318
+
1319
+ //项目开发模块统一扩展
1320
+ var mobileModuleExt;
1321
+ try {
1322
+ if (t.state.module) {
1323
+ mobileModuleExt = typeof eval(t.state.module + "_mobileExt") !== 'undefined' ? eval(t.state.module + "_mobileExt") : null;
1324
+ }
1325
+ } catch (e) {
1326
+ // alert("exception: "+e.message);
1327
+ }
1328
+
1329
+ if (typeof mobileModuleExt !== 'undefined' && typeof mobileModuleExt["mainDocomentLoadSuccess"] === "function") {
1330
+ mobileModuleExt["mainDocomentLoadSuccess"](t.state);
1331
+ }
1332
+
1333
+ //项目开发扩展
1334
+ var mobileExt;
1335
+ try {
1336
+ if (formKey) {
1337
+ mobileExt = typeof eval(t.state.module + "_" + formKey + "_mobileExt") !== 'undefined' ? eval(t.state.module + "_" + formKey + "_mobileExt") : null;
1338
+ }
1339
+ } catch (e) {
1340
+ // alert("exception: "+e.message);
1341
+ }
1342
+ if (typeof mobileExt !== 'undefined' && typeof mobileExt["mainDocomentLoadSuccess"] === "function") {
1343
+ content = mobileExt["mainDocomentLoadSuccess"](content);
1344
+ }
1318
1345
  });
1319
1346
  t.dealWithButtons(content, formKey);
1320
1347
  }, function (error) {
@@ -1540,7 +1567,8 @@ var PageHome = function (_React$Component) {
1540
1567
 
1541
1568
  }, {
1542
1569
  key: 'change',
1543
- value: function change(data) {
1570
+ value: function change(data, itemParam) {
1571
+ console.log("数据回调" + itemParam.key);
1544
1572
  this.setState({
1545
1573
  editFormData: data
1546
1574
  });