update common models
This commit is contained in:
parent
69f7ae7c34
commit
b981876d86
|
@ -326,7 +326,7 @@ public class WordBuilderImpl implements WordBuilder {
|
|||
// CTDecimalNumber number = paragraph.getCTP().getPPr().getNumPr().addNewIlvl();
|
||||
// number.setVal(BigInteger.valueOf(indent));
|
||||
paragraphPos = mainDocumentPart.getPosOfParagraph(paragraph);
|
||||
if (!fieldSetModel.getMultiplicity().getTableView() && propertyDefinitionFieldSetItemModels.size() > 1) {
|
||||
if (fieldSetModel.getMultiplicity() != null && !fieldSetModel.getMultiplicity().getTableView() && propertyDefinitionFieldSetItemModels.size() > 1) {
|
||||
XWPFParagraph paragraphInner = addParagraphContent(c + ". ", mainDocumentPart, ParagraphStyle.TEXT, numId, indent);
|
||||
paragraphPosInner = mainDocumentPart.getPosOfParagraph(paragraphInner);
|
||||
hasMultiplicityItems = true;
|
||||
|
@ -336,7 +336,7 @@ public class WordBuilderImpl implements WordBuilder {
|
|||
XWPFTable tbl = null;
|
||||
XWPFTableRow row = null;
|
||||
int numOfRows = 0;
|
||||
if (fieldSetModel.getMultiplicity().getTableView()) {
|
||||
if (fieldSetModel.getMultiplicity() != null && fieldSetModel.getMultiplicity().getTableView()) {
|
||||
tbl = mainDocumentPart.createTable();
|
||||
tbl.setTableAlignment(TableRowAlign.CENTER);
|
||||
mainDocumentPart.createParagraph();
|
||||
|
@ -344,7 +344,7 @@ public class WordBuilderImpl implements WordBuilder {
|
|||
numOfRows = tbl.getRows().size();
|
||||
row = tbl.createRow();
|
||||
}
|
||||
if (fieldSetModel.getMultiplicity().getTableView()) {
|
||||
if (fieldSetModel.getMultiplicity() != null && fieldSetModel.getMultiplicity().getTableView()) {
|
||||
hasValue = createFieldsInTable(fieldSetModel, propertyDefinitionFieldSetItemModels.getFirst(), row, indent, createListing, hasMultiplicityItems, numOfRows, visibilityService);
|
||||
numOfRows++;
|
||||
} else {
|
||||
|
@ -360,7 +360,7 @@ public class WordBuilderImpl implements WordBuilder {
|
|||
if (propertyDefinitionFieldSetItemModels.size() > 1) {
|
||||
for (PropertyDefinitionFieldSetItemModel multiplicityFieldset : propertyDefinitionFieldSetItemModels.stream().skip(1).toList()) {
|
||||
paragraphPosInner = -1;
|
||||
if (!fieldSetModel.getMultiplicity().getTableView() && !createListing) {
|
||||
if (fieldSetModel.getMultiplicity() != null && !fieldSetModel.getMultiplicity().getTableView() && !createListing) {
|
||||
c++;
|
||||
// addParagraphContent(c + ". ", mainDocumentPart, ParagraphStyle.HEADER6, numId);
|
||||
XWPFParagraph paragraphInner = addParagraphContent(c + ". ", mainDocumentPart, ParagraphStyle.TEXT, numId, indent);
|
||||
|
@ -370,7 +370,7 @@ public class WordBuilderImpl implements WordBuilder {
|
|||
}
|
||||
// hasValue = createFields(multiplicityFieldset.getFields(), mainDocumentPart, 3, createListing, visibilityRuleService, hasMultiplicityItems);
|
||||
boolean hasValueInner = false;
|
||||
if (fieldSetModel.getMultiplicity().getTableView()) {
|
||||
if (fieldSetModel.getMultiplicity() != null && fieldSetModel.getMultiplicity().getTableView()) {
|
||||
row = tbl.createRow();
|
||||
hasValueInner = createFieldsInTable(fieldSetModel, multiplicityFieldset, row, indent, createListing, hasMultiplicityItems, numOfRows, visibilityService);
|
||||
numOfRows++;
|
||||
|
|
Loading…
Reference in New Issue