10 changed files with 182 additions and 42 deletions
@ -1,18 +1,64 @@ |
|||
package com.yxt.yyth.api.lpkgiftcard; |
|||
|
|||
import cn.hutool.core.date.DateUtil; |
|||
import lombok.Data; |
|||
|
|||
import java.text.SimpleDateFormat; |
|||
import java.util.List; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/11/22 11:07 |
|||
*/ |
|||
@Data |
|||
public class AppletVo { |
|||
|
|||
private String dateStart; |
|||
private String dateEnd; |
|||
private String customerSid; |
|||
private String giftbagSid; |
|||
private String code; |
|||
private String sid ; |
|||
private String state; |
|||
private String states; |
|||
private boolean showBtn=true; |
|||
private boolean showRecord=true; |
|||
private String time; |
|||
private String name="卡号"; |
|||
private String name="卡号:"; |
|||
private String pName; |
|||
private List<GoodsVo> goodsVos; |
|||
|
|||
public String getName() { |
|||
name=name+code; |
|||
return name; |
|||
} |
|||
|
|||
public String getTime() { |
|||
SimpleDateFormat sdf =new SimpleDateFormat("yyyy-MM-dd"); |
|||
time=sdf.format(DateUtil.parse(dateStart))+"~"+sdf.format(DateUtil.parse(dateEnd)); |
|||
return time; |
|||
} |
|||
|
|||
public boolean isShowBtn() { |
|||
if(states.equals("5")){ |
|||
this.state="失效"; |
|||
showBtn=false; |
|||
} |
|||
return showBtn; |
|||
} |
|||
|
|||
public String getState() { |
|||
int i=DateUtil.parse(dateEnd).compareTo(DateUtil.date()); |
|||
if( String.valueOf(i).equals("1")){ |
|||
state="正常"; |
|||
if(states.equals("5")){ |
|||
this.state="失效"; |
|||
showBtn=false; |
|||
} |
|||
// appletVo.setShowBtn(true);
|
|||
}else{ |
|||
state="失效"; |
|||
showBtn=false; |
|||
} |
|||
return state; |
|||
} |
|||
} |
|||
|
@ -0,0 +1,16 @@ |
|||
package com.yxt.yyth.api.lpkgiftcard; |
|||
|
|||
import lombok.Data; |
|||
import org.springframework.beans.factory.annotation.Value; |
|||
|
|||
/** |
|||
* @author wangpengfei |
|||
* @date 2023/11/22 15:35 |
|||
*/ |
|||
@Data |
|||
public class GoodsVo { |
|||
private String goods; |
|||
private String pic; |
|||
private double num; |
|||
private double lNum; |
|||
} |
Loading…
Reference in new issue