|
|
|
@@ -15,13 +15,12 @@ import com.aliyun.openservices.shade.org.apache.commons.lang3.StringUtils; |
|
|
|
@Service |
|
|
|
public class PrintCustomedTableDataHandler{ |
|
|
|
|
|
|
|
|
|
|
|
public String getTableContent(String componentContent,JSONArray datas,JSONObject entity){ |
|
|
|
if (null != entity) { |
|
|
|
for (Iterator<String> it = entity.keySet().iterator(); it.hasNext();) { |
|
|
|
String fieldName = it.next(); |
|
|
|
Object o = entity.get(fieldName); |
|
|
|
componentContent = componentContent.replaceAll("{"+fieldName+"}", String.valueOf(o)); |
|
|
|
componentContent = componentContent.replaceAll("\\{"+fieldName+"\\}", String.valueOf(o)); |
|
|
|
} |
|
|
|
} |
|
|
|
componentContent = getTableListContent(componentContent,datas); |
|
|
|
|