tango-app-api-store-zone 3.3.1-beta.15 → 3.3.1-beta.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -639,7 +639,6 @@ export const getCameraListv2 = async ( req, res ) => {
|
|
|
639
639
|
}
|
|
640
640
|
} );
|
|
641
641
|
}
|
|
642
|
-
|
|
643
642
|
if ( tagFileList.data.length ) {
|
|
644
643
|
tagFileList.data.forEach( ( item ) => {
|
|
645
644
|
if ( item.Key.length > 1 ) {
|
|
@@ -764,18 +763,18 @@ export const deleteTag = async ( req, res ) => {
|
|
|
764
763
|
return res.sendError( 'no data found', 204 );
|
|
765
764
|
}
|
|
766
765
|
let enableDelete = false;
|
|
767
|
-
if ( req.user.permission ) {
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
}
|
|
778
|
-
if ( req.user?.role == 'superadmin' || ( req.user?.role == 'admin'
|
|
766
|
+
// if ( req.user.permission ) {
|
|
767
|
+
// let permissions = req.user.permission;
|
|
768
|
+
// permissions.forEach( ( permission ) => {
|
|
769
|
+
// if ( permission.featureName == 'analytics' ) {
|
|
770
|
+
// let product = permission.product.find( ( item ) => item.name == 'tangoZone' );
|
|
771
|
+
// if ( product ) {
|
|
772
|
+
// enableDelete = product.isDelete;
|
|
773
|
+
// }
|
|
774
|
+
// }
|
|
775
|
+
// } );
|
|
776
|
+
// }
|
|
777
|
+
if ( req.user?.role == 'superadmin' || ( req.user?.role == 'admin' ) ) {
|
|
779
778
|
await taggingService.deleteMany( { clientId: req.body.clientId, tagName: req.body.tagName } );
|
|
780
779
|
await externalService.deleteMany( { zoneName: req.body.tagName, clientId: req.body.clientId } );
|
|
781
780
|
} else {
|