Browse Source

修复商品资源属性bug

master
xyiege 3 years ago
parent
commit
70e98c6b00
  1. 30
      src/main/java/cn/chjyj/szwh/bean/GoodsSource.java
  2. 10
      src/main/java/cn/chjyj/szwh/utils/ApiGoodsUtils.java

30
src/main/java/cn/chjyj/szwh/bean/GoodsSource.java

@ -52,7 +52,7 @@ public class GoodsSource {
/**
* 目标标识符-->整体目标标识符目标标识符类型 + 目标标识符ISBN000000XXXXXX
*/
private String targetidentify;
private String targetIdentify;
/**
* 目标片段
@ -62,7 +62,7 @@ public class GoodsSource {
/**
* 目标类型服务关联创建的实体1其他文献/2音频/3视频/4图片/5文化产品
*/
private String targetformat;
private String targetFormat;
/**
* isli元数据其他文献实体/音频实体/视频实体/ json格式
@ -77,7 +77,7 @@ public class GoodsSource {
/**
* isli元数据其他文献实体/音频实体/视频实体/ json格式
*/
private String metadataxml;
private String metadataXml;
/**
* 注销说明
@ -216,12 +216,12 @@ public class GoodsSource {
this.targetNameType = targetNameType;
}
public String getTargetidentify() {
return targetidentify;
public String getTargetIdentify() {
return targetIdentify;
}
public void setTargetidentify(String targetidentify) {
this.targetidentify = targetidentify;
public void setTargetIdentify(String targetIdentify) {
this.targetIdentify = targetIdentify;
}
public String getTargetFragment() {
@ -232,12 +232,12 @@ public class GoodsSource {
this.targetFragment = targetFragment;
}
public String getTargetformat() {
return targetformat;
public String getTargetFormat() {
return targetFormat;
}
public void setTargetformat(String targetformat) {
this.targetformat = targetformat;
public void setTargetFormat(String targetFormat) {
this.targetFormat = targetFormat;
}
public String getSourceData() {
@ -256,12 +256,12 @@ public class GoodsSource {
this.targetData = targetData;
}
public String getMetadataxml() {
return metadataxml;
public String getMetadataXml() {
return metadataXml;
}
public void setMetadataxml(String metadataxml) {
this.metadataxml = metadataxml;
public void setMetadataXml(String metadataXml) {
this.metadataXml = metadataXml;
}
public String getCancellationReason() {

10
src/main/java/cn/chjyj/szwh/utils/ApiGoodsUtils.java

@ -32,7 +32,9 @@ public class ApiGoodsUtils {
Integer ipubid = StringUtils.isNotBlank(pubid)?Integer.valueOf(pubid):0;
goodsSource.setPublisherid(ipubid);
goodsSource.setRegistrant(innerJson.getString("register"));
goodsSource.setResolutionUrl(innerJson.getString("resolutionUrl"));
// 解析地址
String resUrl = innerJson.getString("resolutionUrl");
goodsSource.setResolutionUrl(StringUtils.isNotBlank(resUrl)?resUrl:" ");
goodsSource.setSourceType(innerJson.getString("sourceType"));
goodsSource.setSourceNameType(innerJson.getString("sourceNameType"));
goodsSource.setSourceName(innerJson.getString("sourceName"));
@ -41,15 +43,15 @@ public class ApiGoodsUtils {
goodsSource.setSourceFragment(innerJson.getString("sourceFragment"));
goodsSource.setTargetName(innerJson.getString("targetName"));
goodsSource.setTargetNameType(innerJson.getString("targetNameType"));
goodsSource.setTargetidentify(innerJson.getString("targetIdentify"));
goodsSource.setTargetIdentify(innerJson.getString("targetIdentify"));
//
goodsSource.setTargetFragment(innerJson.getString("targetFragment"));
goodsSource.setTargetformat(innerJson.getString("targetFormat"));
goodsSource.setTargetFormat(innerJson.getString("targetFormat"));
// 存放了json字符串
goodsSource.setSourceData(innerJson.getString("sourceData"));
goodsSource.setTargetData(innerJson.getString("targetData"));
//
goodsSource.setMetadataxml(innerJson.getString("metadataXml"));
goodsSource.setMetadataXml(innerJson.getString("metadataXml"));
goodsSource.setCancellationReason(innerJson.getString("cancellationReason"));
// 字符串转为日期时间格式
String aldate =innerJson.getString("allocationDate");

Loading…
Cancel
Save