cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From raj...@apache.org
Subject [27/50] git commit: updated refs/heads/master to 0b83559
Date Wed, 29 Apr 2015 05:44:11 GMT
volume upload: showing browser uploaded templates in UI.

Templates are not observed on UI after GetUploadParamsForTemplate API
call and Template upload requests initiated.


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/5643d514
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/5643d514
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/5643d514

Branch: refs/heads/master
Commit: 5643d514eedf4d4fe40bde16915bb3c4afa3c007
Parents: c62ce3e
Author: Rajani Karuturi <rajanikaruturi@gmail.com>
Authored: Tue Mar 24 14:55:38 2015 +0530
Committer: Rajani Karuturi <rajanikaruturi@gmail.com>
Committed: Tue Mar 24 15:11:14 2015 +0530

----------------------------------------------------------------------
 server/src/com/cloud/api/query/QueryManagerImpl.java        | 2 +-
 server/src/com/cloud/api/query/dao/TemplateJoinDaoImpl.java | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/5643d514/server/src/com/cloud/api/query/QueryManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/QueryManagerImpl.java b/server/src/com/cloud/api/query/QueryManagerImpl.java
index 824bb9b..ac37c97 100644
--- a/server/src/com/cloud/api/query/QueryManagerImpl.java
+++ b/server/src/com/cloud/api/query/QueryManagerImpl.java
@@ -3202,7 +3202,7 @@ public class QueryManagerImpl extends ManagerBase implements QueryService
{
         if (showRemovedTmpl) {
             uniqueTmplPair = _templateJoinDao.searchIncludingRemovedAndCount(sc, searchFilter);
         } else {
-            sc.addAnd("templateState", SearchCriteria.Op.EQ, State.Active);
+            sc.addAnd("templateState", SearchCriteria.Op.IN, new State[]{State.Active, State.NotUploaded,
State.UploadInProgress});
             uniqueTmplPair = _templateJoinDao.searchAndCount(sc, searchFilter);
         }
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/5643d514/server/src/com/cloud/api/query/dao/TemplateJoinDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/dao/TemplateJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/TemplateJoinDaoImpl.java
index 4e33728..15cefa5 100644
--- a/server/src/com/cloud/api/query/dao/TemplateJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/TemplateJoinDaoImpl.java
@@ -74,7 +74,7 @@ public class TemplateJoinDaoImpl extends GenericDaoBase<TemplateJoinVO,
Long> im
     protected TemplateJoinDaoImpl() {
 
         tmpltIdPairSearch = createSearchBuilder();
-        tmpltIdPairSearch.and("templateState", tmpltIdPairSearch.entity().getTemplateState(),
SearchCriteria.Op.EQ);
+        tmpltIdPairSearch.and("templateState", tmpltIdPairSearch.entity().getTemplateState(),
SearchCriteria.Op.IN);
         tmpltIdPairSearch.and("tempZonePairIN", tmpltIdPairSearch.entity().getTempZonePair(),
SearchCriteria.Op.IN);
         tmpltIdPairSearch.done();
 
@@ -412,7 +412,7 @@ public class TemplateJoinDaoImpl extends GenericDaoBase<TemplateJoinVO,
Long> im
             }
             SearchCriteria<TemplateJoinVO> sc = tmpltIdPairSearch.create();
             if (!showRemoved) {
-                sc.setParameters("templateState", VirtualMachineTemplate.State.Active);
+                sc.setParameters("templateState", VirtualMachineTemplate.State.Active, VirtualMachineTemplate.State.NotUploaded,
VirtualMachineTemplate.State.UploadInProgress);
             }
             sc.setParameters("tempZonePairIN", labels);
             List<TemplateJoinVO> vms = searchIncludingRemoved(sc, searchFilter, null,
false);


Mime
View raw message