mirror of
https://github.com/apache/cloudstack.git
synced 2025-12-16 10:32:34 +01:00
Merge branch '4.9'
This commit is contained in:
commit
01ec8e67b1
@ -32,6 +32,7 @@ import com.cloud.utils.db.TransactionLegacy;
|
||||
import com.cloud.utils.db.TransactionStatus;
|
||||
import com.cloud.utils.exception.CloudRuntimeException;
|
||||
|
||||
import org.apache.cloudstack.acl.RoleType;
|
||||
import org.apache.log4j.Logger;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
@ -113,7 +114,14 @@ public class UsageDaoImpl extends GenericDaoBase<UsageVO, Long> implements Usage
|
||||
pstmt.setLong(1, acct.getId());
|
||||
pstmt.setString(2, acct.getAccountName());
|
||||
pstmt.setShort(3, acct.getType());
|
||||
|
||||
//prevent autoboxing NPE by defaulting to User role
|
||||
if(acct.getRoleId() == null){
|
||||
pstmt.setLong(4, RoleType.User.getId());
|
||||
}else{
|
||||
pstmt.setLong(4, acct.getRoleId());
|
||||
}
|
||||
|
||||
pstmt.setLong(5, acct.getDomainId());
|
||||
|
||||
Date removed = acct.getRemoved();
|
||||
|
||||
@ -310,7 +310,6 @@
|
||||
};
|
||||
|
||||
if(zoneType == 'Advanced') {
|
||||
if($trafficType.hasClass('guest') || $trafficType.hasClass('public')) {
|
||||
if(trafficData.vSwitchType == null) {
|
||||
var useDvs = false;
|
||||
$.ajax({
|
||||
@ -373,7 +372,6 @@
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
} else {
|
||||
fields = {
|
||||
label: {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user