removed gsmmodem and aliyun sms api from API & Admin UI
parent
2539b129e5
commit
c65a24682c
|
@ -1058,36 +1058,6 @@ app
|
|||
]
|
||||
}
|
||||
})
|
||||
.state('settings.gsmmodem', {
|
||||
url: "/gsmmodem",
|
||||
templateUrl: "views/settings/gsmmodem/gsmmodem.html",
|
||||
data: {
|
||||
pageTitle: 'MENU.SETTINGS.GSM_MODEM'
|
||||
},
|
||||
resolve: {
|
||||
deps: [
|
||||
'$ocLazyLoad',
|
||||
function ($ocLazyLoad) {
|
||||
return $ocLazyLoad.load(['ui.select', 'ui.checkbox', 'toaster']).then(
|
||||
function () {
|
||||
return $ocLazyLoad.load([{
|
||||
files: ['js/plugins/sweetalert/sweetalert.min.js', 'css/plugins/sweetalert/sweetalert.css']
|
||||
}, {
|
||||
name: 'oitozero.ngSweetAlert',
|
||||
files: ['js/plugins/sweetalert/angular-sweetalert.min.js']
|
||||
}, {
|
||||
serie: true,
|
||||
files: [
|
||||
'app/services/settings/gsmmodem/gsmmodem.service.js',
|
||||
'app/controllers/settings/gsmmodem/gsmmodem.controller.js'
|
||||
]
|
||||
}]);
|
||||
}
|
||||
);
|
||||
}
|
||||
]
|
||||
}
|
||||
})
|
||||
.state('settings.knowledgefile', {
|
||||
url: "/knowledgefile",
|
||||
templateUrl: "views/settings/knowledgefile/knowledgefile.html",
|
||||
|
|
|
@ -1,155 +0,0 @@
|
|||
'use strict';
|
||||
|
||||
app.controller('GSMModemController', function($scope, $translate,$uibModal, GSMModemService,toaster,SweetAlert) {
|
||||
|
||||
$scope.getAllGSMModems = function() {
|
||||
GSMModemService.getAllGSMModems(function (response) {
|
||||
if (angular.isDefined(response.status) && response.status === 200) {
|
||||
$scope.gsmmodems = response.data;
|
||||
} else {
|
||||
$scope.gsmmodems = [];
|
||||
}
|
||||
});
|
||||
|
||||
};
|
||||
|
||||
$scope.addGSMModem = function() {
|
||||
var modalInstance = $uibModal.open({
|
||||
templateUrl: 'views/settings/gsmmodem/gsmmodem.model.html',
|
||||
controller: 'ModalAddGSMModemCtrl',
|
||||
windowClass: "animated fadeIn",
|
||||
resolve: {
|
||||
params:function(){
|
||||
return {
|
||||
gsmmodems:angular.copy($scope.gsmmodems)
|
||||
};
|
||||
}
|
||||
}
|
||||
});
|
||||
modalInstance.result.then(function(gsmmodem) {
|
||||
GSMModemService.addGSMModem(gsmmodem, function(response) {
|
||||
if (angular.isDefined(response.status) && response.status === 201) {
|
||||
toaster.pop({
|
||||
type: "success",
|
||||
title: $translate.instant("TOASTER.SUCCESS_TITLE"),
|
||||
body: $translate.instant("TOASTER.SUCCESS_ADD_BODY", {template: $translate.instant("SETTING.GSM_MODEM")}),
|
||||
showCloseButton: true,
|
||||
});
|
||||
$scope.getAllGSMModems();
|
||||
} else {
|
||||
toaster.pop({
|
||||
type: "error",
|
||||
title: $translate.instant("TOASTER.ERROR_ADD_BODY", {template: $translate.instant("SETTING.GSM_MODEM")}),
|
||||
body: $translate.instant(response.data.description),
|
||||
showCloseButton: true,
|
||||
});
|
||||
}
|
||||
});
|
||||
}, function() {
|
||||
|
||||
});
|
||||
};
|
||||
|
||||
$scope.editGSMModem=function(gsmmodem){
|
||||
var modalInstance = $uibModal.open({
|
||||
windowClass: "animated fadeIn",
|
||||
templateUrl: 'views/settings/gsmmodem/gsmmodem.model.html',
|
||||
controller: 'ModalEditGSMModemCtrl',
|
||||
resolve: {
|
||||
params:function(){
|
||||
return {
|
||||
gsmmodem:angular.copy(gsmmodem),
|
||||
gsmmodems:angular.copy($scope.gsmmodems)
|
||||
};
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
modalInstance.result.then(function (modifiedGSMModem) {
|
||||
GSMModemService.editGSMModem(modifiedGSMModem,function (response){
|
||||
if(angular.isDefined(response.status) && response.status === 200) {
|
||||
toaster.pop({
|
||||
type: "success",
|
||||
title: $translate.instant("TOASTER.SUCCESS_TITLE"),
|
||||
body: $translate.instant("TOASTER.SUCCESS_UPDATE_BODY", {template: $translate.instant("SETTING.GSM_MODEM")}),
|
||||
showCloseButton: true,
|
||||
});
|
||||
$scope.getAllGSMModems();
|
||||
}else{
|
||||
toaster.pop({
|
||||
type: "error",
|
||||
title: $translate.instant("TOASTER.ERROR_UPDATE_BODY", {template: $translate.instant("SETTING.GSM_MODEM")}),
|
||||
body: $translate.instant(response.data.description),
|
||||
showCloseButton: true,
|
||||
});
|
||||
}
|
||||
});
|
||||
}, function () {
|
||||
//do nothing;
|
||||
});
|
||||
};
|
||||
|
||||
$scope.deleteGSMModem=function(gsmmodem){
|
||||
SweetAlert.swal({
|
||||
title: $translate.instant("SWEET.TITLE"),
|
||||
text: $translate.instant("SWEET.TEXT"),
|
||||
type: "warning",
|
||||
showCancelButton: true,
|
||||
confirmButtonColor: "#DD6B55",
|
||||
confirmButtonText: $translate.instant("SWEET.CONFIRM_BUTTON_TEXT"),
|
||||
cancelButtonText: $translate.instant("SWEET.CANCEL_BUTTON_TEXT"),
|
||||
closeOnConfirm: true,
|
||||
closeOnCancel: true },
|
||||
function (isConfirm) {
|
||||
if (isConfirm) {
|
||||
GSMModemService.deleteGSMModem(gsmmodem, function(response) {
|
||||
if (angular.isDefined(response.status) && response.status === 204) {
|
||||
toaster.pop({
|
||||
type: "success",
|
||||
title: $translate.instant("TOASTER.SUCCESS_TITLE"),
|
||||
body: $translate.instant("TOASTER.SUCCESS_DELETE_BODY", {template: $translate.instant("SETTING.GSM_MODEM")}),
|
||||
showCloseButton: true,
|
||||
});
|
||||
$scope.getAllGSMModems();
|
||||
} else {
|
||||
toaster.pop({
|
||||
type: "error",
|
||||
title: $translate.instant("TOASTER.ERROR_DELETE_BODY", {template: $translate.instant("SETTING.GSM_MODEM")}),
|
||||
body: $translate.instant(response.data.description),
|
||||
showCloseButton: true,
|
||||
});
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
$scope.getAllGSMModems();
|
||||
});
|
||||
|
||||
app.controller('ModalAddGSMModemCtrl', function ($scope, $uibModalInstance,params) {
|
||||
|
||||
$scope.operation="SETTING.ADD_GSM_MODEM";
|
||||
$scope.gsmmodems=params.gsmmodems;
|
||||
$scope.ok = function () {
|
||||
$uibModalInstance.close($scope.gsmmodem);
|
||||
};
|
||||
|
||||
$scope.cancel = function () {
|
||||
$uibModalInstance.dismiss('cancel');
|
||||
};
|
||||
});
|
||||
|
||||
app.controller('ModalEditGSMModemCtrl', function ($scope, $uibModalInstance, params) {
|
||||
$scope.operation="SETTING.EDIT_GSM_MODEM";
|
||||
$scope.gsmmodem = params.gsmmodem;
|
||||
$scope.gsmmodems=params.gsmmodems;
|
||||
|
||||
$scope.ok = function () {
|
||||
$uibModalInstance.close($scope.gsmmodem);
|
||||
};
|
||||
|
||||
$scope.cancel = function () {
|
||||
$uibModalInstance.dismiss('cancel');
|
||||
};
|
||||
});
|
|
@ -1,53 +0,0 @@
|
|||
'use strict';
|
||||
app.factory('GSMModemService', function($http) {
|
||||
return {
|
||||
getAllGSMModems:function(callback){
|
||||
$http.get(getAPI()+'gsmmodems')
|
||||
.then(function (response) {
|
||||
callback(response);
|
||||
}, function (response) {
|
||||
callback(response);
|
||||
});
|
||||
},
|
||||
searchGSMModems: function(query, callback) {
|
||||
$http.get(getAPI()+'gsmmodems', { params: { q: query } })
|
||||
.then(function (response) {
|
||||
callback(response);
|
||||
}, function (response) {
|
||||
callback(response);
|
||||
});
|
||||
},
|
||||
addGSMModem: function(gsmmodem, callback) {
|
||||
$http.post(getAPI()+'gsmmodems',{data:gsmmodem})
|
||||
.then(function (response) {
|
||||
callback(response);
|
||||
}, function (response) {
|
||||
callback(response);
|
||||
});
|
||||
},
|
||||
editGSMModem: function(gsmmodem, callback) {
|
||||
$http.put(getAPI()+'gsmmodems/'+gsmmodem.id,{data:gsmmodem})
|
||||
.then(function (response) {
|
||||
callback(response);
|
||||
}, function (response) {
|
||||
callback(response);
|
||||
});
|
||||
},
|
||||
deleteGSMModem: function(gsmmodem, callback) {
|
||||
$http.delete(getAPI()+'gsmmodems/'+gsmmodem.id)
|
||||
.then(function (response) {
|
||||
callback(response);
|
||||
}, function (response) {
|
||||
callback(response);
|
||||
});
|
||||
},
|
||||
getGSMModem: function(id, callback) {
|
||||
$http.get(getAPI()+'gsmmodems/'+id)
|
||||
.then(function (response) {
|
||||
callback(response);
|
||||
}, function (response) {
|
||||
callback(response);
|
||||
});
|
||||
}
|
||||
};
|
||||
});
|
|
@ -96,7 +96,6 @@ function config($translateProvider) {
|
|||
MENU: 'Menu Settings',
|
||||
TARIFF: 'Tariff Settings',
|
||||
EMAIL_SERVER: 'Email Server Settings',
|
||||
GSM_MODEM: 'GSM Modem Settings',
|
||||
CONTACT: 'Contacts',
|
||||
KNOWLEDGEFILE: 'Knowledge Base Settings'
|
||||
},
|
||||
|
@ -155,7 +154,6 @@ function config($translateProvider) {
|
|||
ADD_ENERGY_ITEM: 'Add Energy Item',
|
||||
ADD_CONTACT: 'Add Contact',
|
||||
ADD_EMAIL_SERVER: 'Add Email Server',
|
||||
ADD_GSM_MODEM: 'Add GSM Modem',
|
||||
|
||||
EDIT_SPACE: 'Edit Space',
|
||||
EDIT_TENANT: 'Edit Tenant',
|
||||
|
@ -169,7 +167,6 @@ function config($translateProvider) {
|
|||
EDIT_CATEGORY: 'Edit Energy Category',
|
||||
EDIT_CONTACT: 'Edit Contact',
|
||||
EDIT_EMAIL_SERVER: 'Edit Email Server',
|
||||
EDIT_GSM_MODEM: 'Edit GSM Modem',
|
||||
|
||||
REQUIRES_AUTHENTICATION: 'Requires Authentication',
|
||||
SELECT_DATE: 'Please Select Date',
|
||||
|
@ -1086,7 +1083,6 @@ function config($translateProvider) {
|
|||
MENU: '菜单管理',
|
||||
TARIFF: '能源费率管理',
|
||||
EMAIL_SERVER: '邮件服务器设置',
|
||||
GSM_MODEM: '短信模块设置',
|
||||
CONTACT: '联系人管理',
|
||||
KNOWLEDGEFILE: '知识库管理'
|
||||
},
|
||||
|
@ -1145,7 +1141,6 @@ function config($translateProvider) {
|
|||
ADD_ENERGY_ITEM: '添加能耗分项',
|
||||
ADD_CONTACT: '添加联系人',
|
||||
ADD_EMAIL_SERVER: '添加邮件服务器',
|
||||
ADD_GSM_MODEM: '添加短信模块',
|
||||
|
||||
EDIT_SPACE: '编辑空间',
|
||||
EDIT_TENANT: '编辑租户',
|
||||
|
@ -1160,7 +1155,6 @@ function config($translateProvider) {
|
|||
EDIT_ENERGY_ITEM: '编辑能耗分项',
|
||||
EDIT_CONTACT: '编辑联系人',
|
||||
EDIT_EMAIL_SERVER: '编辑邮箱服务器',
|
||||
EDIT_GSM_MODEM: '编辑短信模块',
|
||||
|
||||
REQUIRES_AUTHENTICATION: '需要身份验证',
|
||||
SELECT_DATE: '请选择日期',
|
||||
|
@ -1194,7 +1188,6 @@ function config($translateProvider) {
|
|||
INPUT_BAUD_RATE: '请输入波特率',
|
||||
|
||||
EMAIL_SERVER: '邮件服务器',
|
||||
GSM_MODEM: '短信模块',
|
||||
INVALID_FORMAT: '格式不正确',
|
||||
INVALID_FROM_ADDR: '发件人地址不正确',
|
||||
INVALID_BAUD_RATE: '波特率不正确',
|
||||
|
@ -2084,7 +2077,6 @@ function config($translateProvider) {
|
|||
MENU: 'Verwaltung des Menüs',
|
||||
TARIFF: 'Energieratenmanagement',
|
||||
EMAIL_SERVER: 'Mailserver-Einstellungen',
|
||||
GSM_MODEM: 'SMS-Moduleinstellungen',
|
||||
CONTACT: 'Kontaktmanagement',
|
||||
KNOWLEDGEFILE: 'Wissensdatenbankverwaltung'
|
||||
},
|
||||
|
@ -2143,7 +2135,6 @@ function config($translateProvider) {
|
|||
ADD_ENERGY_ITEM: 'Unterelemente zum Energieverbrauch hinzufügen',
|
||||
ADD_CONTACT: 'Kontakt hinzufügen',
|
||||
ADD_EMAIL_SERVER: 'Mail-Server hinzufügen',
|
||||
ADD_GSM_MODEM: 'SMS-Modul hinzufügen',
|
||||
|
||||
EDIT_SPACE: 'Leerzeichen bearbeiten',
|
||||
EDIT_TENANT: 'Mieter bearbeiten',
|
||||
|
@ -2158,7 +2149,6 @@ function config($translateProvider) {
|
|||
EDIT_ENERGY_ITEM: 'Unterelemente zum Energieverbrauch bearbeiten',
|
||||
EDIT_CONTACT: 'Kontakt bearbeiten',
|
||||
EDIT_EMAIL_SERVER: 'Postfachserver bearbeiten',
|
||||
EDIT_GSM_MODEM: 'SMS-Modul bearbeiten',
|
||||
|
||||
REQUIRES_AUTHENTICATION: 'Authentifizierung erforderlich',
|
||||
SELECT_DATE: 'Bitte wählen Sie ein Datum',
|
||||
|
@ -2192,7 +2182,6 @@ function config($translateProvider) {
|
|||
INPUT_BAUD_RATE: 'Bitte geben Sie die Baudrate ein',
|
||||
|
||||
EMAIL_SERVER: 'Mail-Server',
|
||||
GSM_MODEM: 'SMS-Modul',
|
||||
INVALID_FORMAT: 'Falsches Format',
|
||||
INVALID_FROM_ADDR: 'Falsche Absenderadresse',
|
||||
INVALID_BAUD_RATE: 'Falsche Baudrate',
|
||||
|
|
|
@ -32,7 +32,6 @@
|
|||
<li ui-sref-active="active"><a ui-sref="settings.distributionsystem">{{ 'MENU.SETTINGS.DISTRIBUTION_SYSTEM' | translate }}</a></li>
|
||||
<li ui-sref-active="active"><a ui-sref="settings.menu">{{ 'MENU.SETTINGS.MENU' | translate }}</a></li>
|
||||
<li ui-sref-active="active"><a ui-sref="settings.emailserver">{{ 'MENU.SETTINGS.EMAIL_SERVER' | translate }}</a></li>
|
||||
<li ui-sref-active="active"><a ui-sref="settings.gsmmodem">{{ 'MENU.SETTINGS.GSM_MODEM' | translate }}</a></li>
|
||||
<li ui-sref-active="active"><a ui-sref="settings.knowledgefile">{{ 'MENU.SETTINGS.KNOWLEDGEFILE' | translate }}</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
|
|
|
@ -1,36 +0,0 @@
|
|||
<div class="wrapper wrapper-content">
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<div class="tabs-container">
|
||||
<uib-tabset>
|
||||
<uib-tab heading="{{'SETTING.GSM_MODEM' | translate}}">
|
||||
<div class="panel-body" ng-controller="GSMModemController">
|
||||
<!-- <a ng-click="addGSMModem()" class="btn btn-primary btn-rounded btn-outline" href=""><i class="fa fa-plus-circle"></i> {{'SETTING.ADD_GSM_MODEM' | translate}}</a> -->
|
||||
<table class="table table-bordered table-hover" >
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="text-center">{{'SETTING.ID' | translate}}</th>
|
||||
<th class="text-center">{{'SETTING.SERIAL_PORT' | translate}}</th>
|
||||
<th class="text-center">{{'SETTING.BAUD_RATE' | translate}}</th>
|
||||
<th class="text-center">{{'SETTING.ACTION' | translate}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr ng-repeat="gsmmodem in gsmmodems">
|
||||
<td class="text-center">{{ gsmmodem.id }}</td>
|
||||
<td class="text-center">{{ gsmmodem.serial_port }}</td>
|
||||
<td class="text-center">{{ gsmmodem.baud_rate }}</td>
|
||||
<td class="text-center">
|
||||
<a class="btn btn-primary btn-rounded btn-xs" ng-click="editGSMModem(gsmmodem)" >{{'SETTING.EDIT' | translate}}</a>
|
||||
<!-- <a ng-click="deleteGSMModem(gsmmodem)" class="btn btn-danger btn-rounded btn-xs" >{{'SETTING.DELETE' | translate}}</a> -->
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</uib-tab>
|
||||
</uib-tabset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -1,31 +0,0 @@
|
|||
<div class="inmodal">
|
||||
<div class="modal-header">
|
||||
<h4 class="modal-title">{{operation | translate}}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<form role="form" name="form_gsmmodem" novalidate class="form-horizontal">
|
||||
<div class="form-group"><label class="col-sm-3 control-label">{{'SETTING.SERIAL_PORT' | translate}}</label>
|
||||
|
||||
<div class="col-sm-9"><input ng-model="gsmmodem.serial_port" type="text" name="serial_port" class="form-control" required="">
|
||||
<div class="m-t-xs" ng-show="form_gsmmodem.serial_port.$invalid && form_gsmmodem.serial_port.$dirty">
|
||||
<small class="text-danger" ng-show="form_gsmmodem.serial_port.$error.required">{{'SETTING.INPUT_SERIAL_PORT' | translate}}</small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="hr-line-dashed"></div>
|
||||
<div class="form-group"><label class="col-sm-3 control-label">{{'SETTING.BAUD_RATE' | translate}}</label>
|
||||
|
||||
<div class="col-sm-9"><input ng-model="gsmmodem.baud_rate" type="number" name="baud_rate" class="form-control" required="">
|
||||
<div class="m-t-xs" ng-show="form_gsmmodem.port.$invalid && form_gsmmodem.baud_rate.$dirty">
|
||||
<small class="text-danger" ng-show="form_gsmmodem.baud_rate.$error.required">{{'SETTING.INPUT_BAUD_RATE' | translate}}</small>
|
||||
<small class="text-danger" ng-show="form_gsmmodem.baud_rate.$error">{{'SETTING.INVALID_BAUD_RATE' | translate}}</small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-white" ng-click="cancel()">{{'SETTING.CANCEL' | translate}}</button>
|
||||
<button type="button" ng-disabled="form_contact.$invalid" class="btn btn-primary" ng-click="ok()">{{'SETTING.SAVE' | translate}}</button>
|
||||
</div>
|
||||
</div>
|
|
@ -7,22 +7,6 @@ DROP DATABASE IF EXISTS `myems_fdd_db` ;
|
|||
CREATE DATABASE IF NOT EXISTS `myems_fdd_db` ;
|
||||
USE `myems_fdd_db` ;
|
||||
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
-- Table `myems_fdd_db`.`tbl_aliyun_sms_api`
|
||||
-- refer to https://dysms.console.aliyun.com/
|
||||
-- API Version 2017-05-25
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
DROP TABLE IF EXISTS `myems_fdd_db`.`tbl_aliyun_sms_api` ;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `myems_fdd_db`.`tbl_aliyun_sms_api` (
|
||||
`id` BIGINT NOT NULL AUTO_INCREMENT,
|
||||
`access_key_id` VARCHAR(256) NOT NULL,
|
||||
`access_key_secret` VARCHAR(256) NOT NULL,
|
||||
`endpoint` VARCHAR(256) NOT NULL,
|
||||
`sign_name` VARCHAR(256) NOT NULL,
|
||||
`template_code` VARCHAR(256) NOT NULL,
|
||||
PRIMARY KEY (`id`));
|
||||
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
-- Table `myems_fdd_db`.`tbl_email_messages`
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -42,30 +26,6 @@ CREATE TABLE IF NOT EXISTS `myems_fdd_db`.`tbl_email_messages` (
|
|||
PRIMARY KEY (`id`));
|
||||
CREATE INDEX `tbl_email_messages_index_1` ON `myems_fdd_db`.`tbl_email_messages` (`status`, `scheduled_datetime_utc`);
|
||||
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
-- Table `myems_fdd_db`.`tbl_gsm_modems`
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
DROP TABLE IF EXISTS `myems_fdd_db`.`tbl_gsm_modems` ;
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `myems_fdd_db`.`tbl_gsm_modems` (
|
||||
`id` BIGINT NOT NULL AUTO_INCREMENT,
|
||||
`serial_port` VARCHAR(64) NOT NULL,
|
||||
`baud_rate` INT NOT NULL,
|
||||
PRIMARY KEY (`id`));
|
||||
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
-- Data for table `myems_fdd_db`.`tbl_gsm_modems`
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
START TRANSACTION;
|
||||
USE `myems_fdd_db`;
|
||||
|
||||
INSERT INTO `myems_fdd_db`.`tbl_gsm_modems`
|
||||
(`id`, `serial_port`, `baud_rate`)
|
||||
VALUES
|
||||
(1, '/dev/ttyS0', 115200);
|
||||
|
||||
COMMIT;
|
||||
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
-- Table `myems_fdd_db`.`tbl_rules`
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
|
|
|
@ -1,16 +1,3 @@
|
|||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
-- Table `myems_fdd_db`.`tbl_aliyun_sms_api`
|
||||
-- refer to https://dysms.console.aliyun.com/
|
||||
-- API Version 2017-05-25
|
||||
-- ---------------------------------------------------------------------------------------------------------------------
|
||||
CREATE TABLE IF NOT EXISTS `myems_fdd_db`.`tbl_aliyun_sms_api` (
|
||||
`id` BIGINT NOT NULL AUTO_INCREMENT,
|
||||
`access_key_id` VARCHAR(256) NOT NULL,
|
||||
`access_key_secret` VARCHAR(256) NOT NULL,
|
||||
`endpoint` VARCHAR(256) NOT NULL,
|
||||
`sign_name` VARCHAR(256) NOT NULL,
|
||||
`template_code` VARCHAR(256) NOT NULL,
|
||||
PRIMARY KEY (`id`));
|
||||
|
||||
DROP TABLE IF EXISTS `myems_fdd_db`.`tbl_gsm_modems` ;
|
||||
|
||||
|
|
|
@ -2701,107 +2701,6 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Aliyun SMS API",
|
||||
"item": [
|
||||
{
|
||||
"name": "GET All Aliyun SMS APIs",
|
||||
"request": {
|
||||
"method": "GET",
|
||||
"header": [],
|
||||
"url": {
|
||||
"raw": "{{base_url}}/aliyunsmsapis",
|
||||
"host": [
|
||||
"{{base_url}}"
|
||||
],
|
||||
"path": [
|
||||
"aliyunsmsapis"
|
||||
]
|
||||
}
|
||||
},
|
||||
"response": []
|
||||
},
|
||||
{
|
||||
"name": "GET an Aliyun SMS API by ID",
|
||||
"request": {
|
||||
"method": "GET",
|
||||
"header": [],
|
||||
"url": {
|
||||
"raw": "{{base_url}}/aliyunsmsapis/1",
|
||||
"host": [
|
||||
"{{base_url}}"
|
||||
],
|
||||
"path": [
|
||||
"aliyunsmsapis",
|
||||
"1"
|
||||
]
|
||||
}
|
||||
},
|
||||
"response": []
|
||||
},
|
||||
{
|
||||
"name": "POST Create New Aliyun SMS API",
|
||||
"request": {
|
||||
"method": "POST",
|
||||
"header": [],
|
||||
"body": {
|
||||
"mode": "raw",
|
||||
"raw": "{\"data\":{\"access_key_id\":\"xTAI5t8KUj8jXXXXXXXXXXXX\",\"access_key_secret\":\"fXXjFLA7GeXXXXXXXXXXXXXXXXXXXX\",\"endpoint\":\"https://dysmsapi.aliyuncs.com\",\"sign_name\":\"MYEMS\",\"template_code\":\"SMS_153055065\"}}"
|
||||
},
|
||||
"url": {
|
||||
"raw": "{{base_url}}/aliyunsmsapis",
|
||||
"host": [
|
||||
"{{base_url}}"
|
||||
],
|
||||
"path": [
|
||||
"aliyunsmsapis"
|
||||
]
|
||||
}
|
||||
},
|
||||
"response": []
|
||||
},
|
||||
{
|
||||
"name": "PUT Update an Aliyun SMS API",
|
||||
"request": {
|
||||
"method": "PUT",
|
||||
"header": [],
|
||||
"body": {
|
||||
"mode": "raw",
|
||||
"raw": "{\"data\":{\"access_key_id\":\"LTAI5t8KUj8jXXXXXXXXXXXX\",\"access_key_secret\":\"fXXjFLA7GeXXXXXXXXXXXXXXXXXXXX\",\"endpoint\":\"https://dysmsapi.aliyuncs.com\",\"sign_name\":\"MYEMS\",\"template_code\":\"SMS_153055065\"}}"
|
||||
},
|
||||
"url": {
|
||||
"raw": "{{base_url}}/aliyunsmsapis/1",
|
||||
"host": [
|
||||
"{{base_url}}"
|
||||
],
|
||||
"path": [
|
||||
"aliyunsmsapis",
|
||||
"1"
|
||||
]
|
||||
}
|
||||
},
|
||||
"response": []
|
||||
},
|
||||
{
|
||||
"name": "DELETE an Aliyun SMS API by ID",
|
||||
"request": {
|
||||
"method": "DELETE",
|
||||
"header": [],
|
||||
"url": {
|
||||
"raw": "{{base_url}}/aliyunsmsapis/2",
|
||||
"host": [
|
||||
"{{base_url}}"
|
||||
],
|
||||
"path": [
|
||||
"aliyunsmsapis",
|
||||
"2"
|
||||
]
|
||||
}
|
||||
},
|
||||
"response": []
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"name": "Knowledge File",
|
||||
"item": [
|
||||
|
|
|
@ -183,7 +183,7 @@ View in Postman: import the file MyEMS.postman_collection.json with Postman
|
|||
|
||||
[Rule](#Rule) | [Email Message](#Email Message) | [Text Message](#Text Message) | [Web Message](#Web Message) | [Wechat Message](#Wechat Message)
|
||||
|
||||
[Email Server](#Email Server) | [GSM Modem](#GSM Modem)
|
||||
[Email Server](#Email Server)
|
||||
|
||||
[User](#User) | [Privilege](#Privilege) | [Contact](#Contact) | [Notification](#Notification)
|
||||
|
||||
|
@ -891,37 +891,6 @@ curl -i -H "Content-Type: application/json" -X PUT -d '{"data":{"name":"MyEMS Ga
|
|||
curl -i -X GET {{base_url}}/gateways/{id}/datasources
|
||||
```
|
||||
|
||||
### GSM Modem
|
||||
* GET a GSM Modem by ID
|
||||
|
||||
```bash
|
||||
curl -i -X GET {{base_url}}/gsmmodems/{id}
|
||||
```
|
||||
Result in JSON
|
||||
|
||||
| Name | Data Type | Description |
|
||||
|---------------|-----------|---------------------------------------|
|
||||
| id | integer | GSM Modem ID |
|
||||
| serial_port | string | GSM Modem serial port |
|
||||
| baud_rate | integer | GSM Modem baud rate |
|
||||
|
||||
* GET All GSM Modems
|
||||
```bash
|
||||
curl -i -X GET {{base_url}}/gsmmodems
|
||||
```
|
||||
* DELETE a GSM Modem by ID
|
||||
```bash
|
||||
curl -i -X DELETE {{base_url}}/gsmmodems/{id}
|
||||
```
|
||||
* POST Create New GSM Modem
|
||||
```bash
|
||||
curl -i -H "Content-Type: application/json" -X POST -d '{"data":{"serial_port":"/dev/ttyS0","baud_rate":115200}}' {{base_url}}/gsmmodems
|
||||
```
|
||||
* PUT Update a GSM Modem
|
||||
```bash
|
||||
curl -i -H "Content-Type: application/json" -X PUT -d '{"data":{"serial_port":"/dev/ttyS0","baud_rate":115200}}' {{base_url}}/gsmmodems/{id}
|
||||
```
|
||||
|
||||
### Knowledge File
|
||||
* GET Knowledge File by ID
|
||||
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
import falcon
|
||||
from falcon_cors import CORS
|
||||
from falcon_multipart.middleware import MultipartMiddleware
|
||||
from core import aliyunsmsapi, energyflowdiagram, privilege, textmessage, distributioncircuit, virtualmeter, \
|
||||
from core import energyflowdiagram, privilege, textmessage, distributioncircuit, virtualmeter, \
|
||||
costcenter, point, knowledgefile, meter, tariff, user, storetype, timezone, \
|
||||
costfile, offlinemeterfile, version, contact, emailserver, combinedequipment, datasource, equipment, tenant, \
|
||||
shopfloor, webmessage, distributionsystem, store, emailmessage, tenanttype, wechatmessage, space, gateway, \
|
||||
|
@ -102,10 +102,6 @@ api = falcon.API(middleware=[cors.middleware, MultipartMiddleware()])
|
|||
# Routes for System Core
|
||||
########################################################################################################################
|
||||
|
||||
api.add_route('/aliyunsmsapis',
|
||||
aliyunsmsapi.AliyunSMSAPICollection())
|
||||
api.add_route('/aliyunsmsapis/{id_}',
|
||||
aliyunsmsapi.AliyunSMSAPIItem())
|
||||
api.add_route('/combinedequipments',
|
||||
combinedequipment.CombinedEquipmentCollection())
|
||||
api.add_route('/combinedequipments/{id_}',
|
||||
|
|
|
@ -1,268 +0,0 @@
|
|||
import falcon
|
||||
import json
|
||||
import mysql.connector
|
||||
import config
|
||||
from core.userlogger import user_logger
|
||||
|
||||
|
||||
class AliyunSMSAPICollection:
|
||||
@staticmethod
|
||||
def __init__():
|
||||
"""Initializes AliyunSMSAPICollection"""
|
||||
pass
|
||||
|
||||
@staticmethod
|
||||
def on_options(req, resp):
|
||||
resp.status = falcon.HTTP_200
|
||||
|
||||
@staticmethod
|
||||
def on_get(req, resp):
|
||||
cnx = mysql.connector.connect(**config.myems_fdd_db)
|
||||
cursor = cnx.cursor()
|
||||
|
||||
query = (" SELECT id, access_key_id, access_key_secret, endpoint, sign_name, template_code "
|
||||
" FROM tbl_aliyun_sms_api ")
|
||||
cursor.execute(query)
|
||||
rows = cursor.fetchall()
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
|
||||
result = list()
|
||||
if rows is not None and len(rows) > 0:
|
||||
for row in rows:
|
||||
meta_result = {"id": row[0],
|
||||
"access_key_id": row[1],
|
||||
"access_key_secret": row[2],
|
||||
"endpoint": row[3],
|
||||
"sign_name": row[4],
|
||||
"template_code": row[5]}
|
||||
result.append(meta_result)
|
||||
|
||||
resp.body = json.dumps(result)
|
||||
|
||||
@staticmethod
|
||||
@user_logger
|
||||
def on_post(req, resp):
|
||||
"""Handles POST requests"""
|
||||
try:
|
||||
raw_json = req.stream.read().decode('utf-8')
|
||||
except Exception as ex:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.ERROR', description=ex)
|
||||
|
||||
new_values = json.loads(raw_json)
|
||||
|
||||
if 'access_key_id' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['access_key_id'], str) or \
|
||||
len(str.strip(new_values['data']['access_key_id'])) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_ID')
|
||||
access_key_id = str.strip(new_values['data']['access_key_id'])
|
||||
|
||||
if 'access_key_secret' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['access_key_secret'], str) or \
|
||||
len(new_values['data']['access_key_secret']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_SECRET')
|
||||
access_key_secret = new_values['data']['access_key_secret']
|
||||
|
||||
if 'endpoint' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['endpoint'], str) or \
|
||||
len(new_values['data']['endpoint']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ENDPOINT')
|
||||
endpoint = new_values['data']['endpoint']
|
||||
|
||||
if 'sign_name' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['sign_name'], str) or \
|
||||
len(new_values['data']['sign_name']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_SIGN_NAME')
|
||||
sign_name = new_values['data']['sign_name']
|
||||
|
||||
if 'template_code' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['template_code'], str) or \
|
||||
len(new_values['data']['template_code']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_TEMPLATE_CODE')
|
||||
template_code = new_values['data']['template_code']
|
||||
|
||||
cnx = mysql.connector.connect(**config.myems_fdd_db)
|
||||
cursor = cnx.cursor()
|
||||
|
||||
cursor.execute(" SELECT id "
|
||||
" FROM tbl_aliyun_sms_api "
|
||||
" WHERE access_key_id = %s ", (access_key_id,))
|
||||
if cursor.fetchone() is not None:
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
raise falcon.HTTPError(falcon.HTTP_404, title='API.BAD_REQUEST',
|
||||
description='API.ALIYUN_SMS_API_ACCESS_KEY_ID_IS_ALREADY_IN_USE')
|
||||
|
||||
add_value = (" INSERT INTO tbl_aliyun_sms_api "
|
||||
" (access_key_id, access_key_secret, endpoint, sign_name, template_code) "
|
||||
" VALUES (%s, %s, %s, %s, %s) ")
|
||||
cursor.execute(add_value, (access_key_id,
|
||||
access_key_secret,
|
||||
endpoint,
|
||||
sign_name,
|
||||
template_code))
|
||||
new_id = cursor.lastrowid
|
||||
cnx.commit()
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
|
||||
resp.status = falcon.HTTP_201
|
||||
resp.location = '/aliyunsmsapis/' + str(new_id)
|
||||
|
||||
|
||||
class AliyunSMSAPIItem:
|
||||
@staticmethod
|
||||
def __init__():
|
||||
"""Initializes AliyunSMSAPIItem"""
|
||||
pass
|
||||
|
||||
@staticmethod
|
||||
def on_options(req, resp, id_):
|
||||
resp.status = falcon.HTTP_200
|
||||
|
||||
@staticmethod
|
||||
def on_get(req, resp, id_):
|
||||
if not id_.isdigit() or int(id_) <= 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, '400 Bad Request')
|
||||
|
||||
cnx = mysql.connector.connect(**config.myems_fdd_db)
|
||||
cursor = cnx.cursor()
|
||||
|
||||
query = (" SELECT id, access_key_id, access_key_secret, endpoint, sign_name, template_code "
|
||||
" FROM tbl_aliyun_sms_api "
|
||||
" WHERE id = %s ")
|
||||
cursor.execute(query, (id_,))
|
||||
row = cursor.fetchone()
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
if row is None:
|
||||
raise falcon.HTTPError(falcon.HTTP_404, 'API.NOT_FOUND')
|
||||
|
||||
result = {"id": row[0],
|
||||
"access_key_id": row[1],
|
||||
"access_key_secret": row[2],
|
||||
"endpoint": row[3],
|
||||
"sign_name": row[4],
|
||||
"template_code": row[5]}
|
||||
resp.body = json.dumps(result)
|
||||
|
||||
@staticmethod
|
||||
@user_logger
|
||||
def on_delete(req, resp, id_):
|
||||
if not id_.isdigit() or int(id_) <= 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ID')
|
||||
|
||||
cnx = mysql.connector.connect(**config.myems_fdd_db)
|
||||
cursor = cnx.cursor()
|
||||
|
||||
cursor.execute(" SELECT access_key_id "
|
||||
" FROM tbl_aliyun_sms_api "
|
||||
" WHERE id = %s ", (id_,))
|
||||
if cursor.fetchone() is None:
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
raise falcon.HTTPError(falcon.HTTP_404, title='API.NOT_FOUND',
|
||||
description='API.ALIYUN_SMS_API_NOT_FOUND')
|
||||
|
||||
cursor.execute(" DELETE FROM tbl_aliyun_sms_api WHERE id = %s ", (id_,))
|
||||
cnx.commit()
|
||||
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
|
||||
resp.status = falcon.HTTP_204
|
||||
|
||||
@staticmethod
|
||||
@user_logger
|
||||
def on_put(req, resp, id_):
|
||||
"""Handles PUT requests"""
|
||||
try:
|
||||
raw_json = req.stream.read().decode('utf-8')
|
||||
except Exception as ex:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.EXCEPTION', description=ex)
|
||||
|
||||
if not id_.isdigit() or int(id_) <= 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ID')
|
||||
|
||||
new_values = json.loads(raw_json)
|
||||
|
||||
if 'access_key_id' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['access_key_id'], str) or \
|
||||
len(str.strip(new_values['data']['access_key_id'])) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_ID')
|
||||
access_key_id = str.strip(new_values['data']['access_key_id'])
|
||||
|
||||
if 'access_key_secret' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['access_key_secret'], str) or \
|
||||
len(new_values['data']['access_key_secret']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_SECRET')
|
||||
access_key_secret = new_values['data']['access_key_secret']
|
||||
|
||||
if 'endpoint' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['endpoint'], str) or \
|
||||
len(new_values['data']['endpoint']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_ENDPOINT')
|
||||
endpoint = new_values['data']['endpoint']
|
||||
|
||||
if 'sign_name' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['sign_name'], str) or \
|
||||
len(new_values['data']['sign_name']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_SIGN_NAME')
|
||||
sign_name = new_values['data']['sign_name']
|
||||
|
||||
if 'template_code' not in new_values['data'].keys() or \
|
||||
not isinstance(new_values['data']['template_code'], str) or \
|
||||
len(new_values['data']['template_code']) == 0:
|
||||
raise falcon.HTTPError(falcon.HTTP_400, title='API.BAD_REQUEST',
|
||||
description='API.INVALID_ALIYUN_SMS_API_TEMPLATE_CODE')
|
||||
template_code = new_values['data']['template_code']
|
||||
|
||||
cnx = mysql.connector.connect(**config.myems_fdd_db)
|
||||
cursor = cnx.cursor()
|
||||
|
||||
cursor.execute(" SELECT access_key_id "
|
||||
" FROM tbl_aliyun_sms_api "
|
||||
" WHERE id = %s ",
|
||||
(id_,))
|
||||
if cursor.fetchone() is None:
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
raise falcon.HTTPError(falcon.HTTP_404, title='API.NOT_FOUND',
|
||||
description='API.ALIYUN_SMS_API_NOT_FOUND')
|
||||
|
||||
cursor.execute(" SELECT access_key_id "
|
||||
" FROM tbl_aliyun_sms_api "
|
||||
" WHERE access_key_id = %s AND id != %s ", (access_key_id, id_))
|
||||
if cursor.fetchone() is not None:
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
raise falcon.HTTPError(falcon.HTTP_404, title='API.BAD_REQUEST',
|
||||
description='API.ALIYUN_SMS_API_ACCESS_KEY_ID_IS_ALREADY_IN_USE')
|
||||
|
||||
update_row = (" UPDATE tbl_aliyun_sms_api "
|
||||
" SET access_key_id = %s, access_key_secret = %s, endpoint = %s, sign_name = %s, "
|
||||
" template_code = %s "
|
||||
" WHERE id = %s ")
|
||||
cursor.execute(update_row, (access_key_id,
|
||||
access_key_secret,
|
||||
endpoint,
|
||||
sign_name,
|
||||
template_code,
|
||||
id_,))
|
||||
cnx.commit()
|
||||
|
||||
cursor.close()
|
||||
cnx.disconnect()
|
||||
|
||||
resp.status = falcon.HTTP_200
|
|
@ -353,8 +353,6 @@ const resources = {
|
|||
"API.ADMINISTRATOR_SESSION_NOT_FOUND": "Administrator session not found",
|
||||
"API.ADMINISTRATOR_SESSION_TIMEOUT": "Administrator session timeout",
|
||||
"API.ADVANCED_REPORT_NOT_FOUND": "Advanced report not found",
|
||||
"API.ALIYUN_SMS_API_ACCESS_KEY_ID_IS_ALREADY_IN_USE": "Aliyun SMS API Access Key ID is Already in Use",
|
||||
"API.ALIYUN_SMS_API_NOT_FOUND": "Aliyun SMS API Not Found",
|
||||
"API.BAD_REQUEST": "Bad request",
|
||||
"API.CANNOT_SET_EXISTING_SUBMETER_AS_MASTER_METER": "Cannot set existing submeter as master meter",
|
||||
"API.COMBINED_EQUIPMENT_EQUIPMENT_RELATION_EXISTS": "Combined equipment equipment relation exists",
|
||||
|
@ -433,12 +431,6 @@ const resources = {
|
|||
"API.INVALID_ADDRESS": "Invalid address",
|
||||
"API.INVALID_ADDRESS_VALUE": "Invalid address value",
|
||||
"API.INVALID_ADVANCED_REPORT_ID": "Invalid advanced report id",
|
||||
"API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_ID": "Invalid Aliyun SMS API Access Key ID",
|
||||
"API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_SECRET": "Invalid Aliyun SMS API Access Key Secret",
|
||||
"API.INVALID_ALIYUN_SMS_API_ENDPOINT": "Invalid Aliyun SMS API Endpoint",
|
||||
"API.INVALID_ALIYUN_SMS_API_ID": "Invalid Aliyun SMS API ID",
|
||||
"API.INVALID_ALIYUN_SMS_API_SIGN_NAME": "Invalid Aliyun SMS API Sign Name",
|
||||
"API.INVALID_ALIYUN_SMS_API_TEMPLATE_CODE": "Invalid Aliyun SMS API Template Code",
|
||||
"API.INVALID_AREA_VALUE": "Invalid area value",
|
||||
"API.INVALID_BASE_PERIOD_END_DATETIME": "Invalid base period end datetime",
|
||||
"API.INVALID_BASE_PERIOD_START_DATETIME": "Invalid base period start datetime",
|
||||
|
@ -1110,8 +1102,6 @@ const resources = {
|
|||
"API.ADMINISTRATOR_SESSION_NOT_FOUND": "Administrator session not found",
|
||||
"API.ADMINISTRATOR_SESSION_TIMEOUT": "Administrator session timeout",
|
||||
"API.ADVANCED_REPORT_NOT_FOUND": "Advanced report not found",
|
||||
"API.ALIYUN_SMS_API_ACCESS_KEY_ID_IS_ALREADY_IN_USE": "Aliyun SMS API Access Key ID is Already in Use",
|
||||
"API.ALIYUN_SMS_API_NOT_FOUND": "Aliyun SMS API Not Found",
|
||||
"API.BAD_REQUEST": "Bad request",
|
||||
"API.CANNOT_SET_EXISTING_SUBMETER_AS_MASTER_METER": "Cannot set existing submeter as master meter",
|
||||
"API.COMBINED_EQUIPMENT_EQUIPMENT_RELATION_EXISTS": "Combined equipment equipment relation exists",
|
||||
|
@ -1190,12 +1180,6 @@ const resources = {
|
|||
"API.INVALID_ADDRESS": "Invalid address",
|
||||
"API.INVALID_ADDRESS_VALUE": "Invalid address value",
|
||||
"API.INVALID_ADVANCED_REPORT_ID": "Invalid advanced report id",
|
||||
"API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_ID": "Invalid Aliyun SMS API Access Key ID",
|
||||
"API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_SECRET": "Invalid Aliyun SMS API Access Key Secret",
|
||||
"API.INVALID_ALIYUN_SMS_API_ENDPOINT": "Invalid Aliyun SMS API Endpoint",
|
||||
"API.INVALID_ALIYUN_SMS_API_ID": "Invalid Aliyun SMS API ID",
|
||||
"API.INVALID_ALIYUN_SMS_API_SIGN_NAME": "Invalid Aliyun SMS API Sign Name",
|
||||
"API.INVALID_ALIYUN_SMS_API_TEMPLATE_CODE": "Invalid Aliyun SMS API Template Code",
|
||||
"API.INVALID_AREA_VALUE": "Invalid area value",
|
||||
"API.INVALID_BASE_PERIOD_END_DATETIME": "Invalid base period end datetime",
|
||||
"API.INVALID_BASE_PERIOD_START_DATETIME": "Invalid base period start datetime",
|
||||
|
@ -1866,8 +1850,6 @@ const resources = {
|
|||
"API.ADMINISTRATOR_SESSION_NOT_FOUND": "Administrator session not found",
|
||||
"API.ADMINISTRATOR_SESSION_TIMEOUT": "Administrator session timeout",
|
||||
"API.ADVANCED_REPORT_NOT_FOUND": "Advanced report not found",
|
||||
"API.ALIYUN_SMS_API_ACCESS_KEY_ID_IS_ALREADY_IN_USE": "Aliyun SMS API Access Key ID is Already in Use",
|
||||
"API.ALIYUN_SMS_API_NOT_FOUND": "Aliyun SMS API Not Found",
|
||||
"API.BAD_REQUEST": "Bad request",
|
||||
"API.CANNOT_SET_EXISTING_SUBMETER_AS_MASTER_METER": "Cannot set existing submeter as master meter",
|
||||
"API.COMBINED_EQUIPMENT_EQUIPMENT_RELATION_EXISTS": "Combined equipment equipment relation exists",
|
||||
|
@ -1946,12 +1928,6 @@ const resources = {
|
|||
"API.INVALID_ADDRESS": "Invalid address",
|
||||
"API.INVALID_ADDRESS_VALUE": "Invalid address value",
|
||||
"API.INVALID_ADVANCED_REPORT_ID": "Invalid advanced report id",
|
||||
"API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_ID": "Invalid Aliyun SMS API Access Key ID",
|
||||
"API.INVALID_ALIYUN_SMS_API_ACCESS_KEY_SECRET": "Invalid Aliyun SMS API Access Key Secret",
|
||||
"API.INVALID_ALIYUN_SMS_API_ENDPOINT": "Invalid Aliyun SMS API Endpoint",
|
||||
"API.INVALID_ALIYUN_SMS_API_ID": "Invalid Aliyun SMS API ID",
|
||||
"API.INVALID_ALIYUN_SMS_API_SIGN_NAME": "Invalid Aliyun SMS API Sign Name",
|
||||
"API.INVALID_ALIYUN_SMS_API_TEMPLATE_CODE": "Invalid Aliyun SMS API Template Code",
|
||||
"API.INVALID_AREA_VALUE": "Invalid area value",
|
||||
"API.INVALID_BASE_PERIOD_END_DATETIME": "Invalid base period end datetime",
|
||||
"API.INVALID_BASE_PERIOD_START_DATETIME": "Invalid base period start datetime",
|
||||
|
|
Loading…
Reference in New Issue