diff options
Diffstat (limited to 'openo-portal/portal-lifecyclemgr/src/main')
3 files changed, 21 insertions, 15 deletions
diff --git a/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/gsolcmmain.html b/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/gsolcmmain.html index 087f125e..ad3b5977 100644 --- a/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/gsolcmmain.html +++ b/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/gsolcmmain.html @@ -29,6 +29,7 @@ <script type="text/javascript" src="js/rest.js"></script>
<script type="text/javascript" src="js/bootstrap-table.min.js"></script>
<script type="text/javascript" src="js/gsolcm.js"></script>
+ <script type="text/javascript" src="../common/thirdparty/bootbox/bootbox.min.js"></script>
<script type="text/javascript" src="js/jquery-ui-1.12.1.min.js"></script>
<link href="css/jquery-ui-1.12.1.min.css" rel="stylesheet" />
<script type="text/javascript" src="js/bootstrap-table-filter-control.min.js"></script>
diff --git a/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/gsolcm.js b/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/gsolcm.js index c675ba47..eb667968 100644 --- a/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/gsolcm.js +++ b/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/gsolcm.js @@ -538,21 +538,26 @@ function formatDate(date) { } function deleteNe(rowId, row) { - var instanceId = row.serviceId; - var serviceType = row.serviceType; - var gatewayService = '/openoapi/servicegateway/v1/services/' + instanceId + '/terminate'; - var remove = function () { - $('#sai').bootstrapTable('remove', {field: 'serviceId', values: [instanceId]}); + var deleteHandle = function(result) { + if(result) { + var instanceId = row.serviceId; + var serviceType = row.serviceType; + var gatewayService = '/openoapi/servicegateway/v1/services/' + instanceId + '/terminate'; + var remove = function () { + $('#sai').bootstrapTable('remove', {field: 'serviceId', values: [instanceId]}); + }; + if(serviceType === 'GSO') { + deleteGsoServiceInstance(gatewayService, instanceId, remove); + } else if (serviceType === 'NFVO') { + var nfvoNsUri = '/openoapi/nslcm/v1/ns'; + deleteNonGsoServiceInstance(gatewayService, nfvoNsUri, instanceId, remove); + } else if (serviceType === 'SDNO') { + var sdnoNsUri = '/openoapi/sdnonslcm/v1/ns'; + deleteNonGsoServiceInstance(gatewayService, sdnoNsUri, instanceId, remove); + } + } }; - if(serviceType === 'GSO') { - deleteGsoServiceInstance(gatewayService, instanceId, remove) - } else if (serviceType === 'NFVO') { - var nfvoNsUri = '/openoapi/nslcm/v1/ns'; - deleteNonGsoServiceInstance(gatewayService, nfvoNsUri, instanceId, remove); - } else if (serviceType === 'SDNO') { - var sdnoNsUri = '/openoapi/sdnonslcm/v1/ns'; - deleteNonGsoServiceInstance(gatewayService, sdnoNsUri, instanceId, remove); - } + bootbox.confirm("Do you confirm to delete service?", deleteHandle); } function deleteGsoServiceInstance(gatewayService, instanceId, remove) { diff --git a/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/rest.js b/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/rest.js index 7590bdf7..a6e2eba3 100644 --- a/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/rest.js +++ b/openo-portal/portal-lifecyclemgr/src/main/webapp/lifecyclemgr/js/rest.js @@ -174,7 +174,7 @@ function loadGetServiceData(){ var parameter = {
'sort': [],
'pagination': 0,
- 'pagesize': 25,
+ 'pagesize': 10000,
'condition': {},
'serviceId': ""
};
|