try update pac ip address
This commit is contained in:
parent
4c89c31575
commit
8069fea36b
@ -10,6 +10,7 @@ import java.util.Date;
|
|||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
|
import javax.persistence.CascadeType;
|
||||||
import javax.persistence.Column;
|
import javax.persistence.Column;
|
||||||
import javax.persistence.Entity;
|
import javax.persistence.Entity;
|
||||||
import javax.persistence.EntityManager;
|
import javax.persistence.EntityManager;
|
||||||
@ -77,7 +78,7 @@ public class Pac extends AbstractEntity implements Serializable {
|
|||||||
private boolean free = false;
|
private boolean free = false;
|
||||||
|
|
||||||
@JoinColumn(name = "cur_inet_addr_id", nullable = true)
|
@JoinColumn(name = "cur_inet_addr_id", nullable = true)
|
||||||
@ManyToOne(fetch = EAGER)
|
@ManyToOne(fetch = EAGER, cascade = CascadeType.MERGE)
|
||||||
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[0-9\\.]*",overwriteName="curinetaddr")
|
@AnnFieldIO(rw=ReadWriteAccess.WRITEONCE,validation="[0-9\\.]*",overwriteName="curinetaddr")
|
||||||
private INetAddress curINetAddr;
|
private INetAddress curINetAddr;
|
||||||
|
|
||||||
|
@ -81,7 +81,9 @@ public class PacRemote extends AbstractRemote {
|
|||||||
pac.setCurINetAddr(curINetAddr);
|
pac.setCurINetAddr(curINetAddr);
|
||||||
}
|
}
|
||||||
if (curINetAddr != null && curINetAddr.getInet4Addr() != null && assertNotNull(inetAddrString) && !curINetAddr.getInet4Addr().equals(inetAddrString)) {
|
if (curINetAddr != null && curINetAddr.getInet4Addr() != null && assertNotNull(inetAddrString) && !curINetAddr.getInet4Addr().equals(inetAddrString)) {
|
||||||
|
System.out.println("IP Update: " + inetAddrString);
|
||||||
curINetAddr = new INetAddress(inetAddrString);
|
curINetAddr = new INetAddress(inetAddrString);
|
||||||
|
pac.setCurINetAddr(curINetAddr);
|
||||||
}
|
}
|
||||||
Customer customer = pac.getCustomer();
|
Customer customer = pac.getCustomer();
|
||||||
String memberCode = (String) setParams.get("customer");
|
String memberCode = (String) setParams.get("customer");
|
||||||
|
Loading…
Reference in New Issue
Block a user