mirror of
https://github.com/He4eT/simple-spaceapi.git
synced 2026-05-05 01:47:24 +00:00
Sensor: Account Balance
This commit is contained in:
parent
b758d4e4ec
commit
bb81b89795
5 changed files with 91 additions and 0 deletions
|
|
@ -0,0 +1,35 @@
|
||||||
|
{
|
||||||
|
"kind": "collectionType",
|
||||||
|
"collectionName": "account_balance_sensors",
|
||||||
|
"info": {
|
||||||
|
"singularName": "account-balance-sensor",
|
||||||
|
"pluralName": "account-balance-sensors",
|
||||||
|
"displayName": "Sensor: Account Balance"
|
||||||
|
},
|
||||||
|
"options": {
|
||||||
|
"draftAndPublish": true
|
||||||
|
},
|
||||||
|
"attributes": {
|
||||||
|
"value": {
|
||||||
|
"type": "decimal",
|
||||||
|
"required": true
|
||||||
|
},
|
||||||
|
"unit": {
|
||||||
|
"type": "string",
|
||||||
|
"required": true
|
||||||
|
},
|
||||||
|
"location": {
|
||||||
|
"type": "string",
|
||||||
|
"required": true
|
||||||
|
},
|
||||||
|
"name": {
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"description": {
|
||||||
|
"type": "text"
|
||||||
|
},
|
||||||
|
"lastchange": {
|
||||||
|
"type": "biginteger"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
/**
|
||||||
|
* account-balance-sensor controller
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { factories } from '@strapi/strapi'
|
||||||
|
|
||||||
|
export default factories.createCoreController('api::account-balance-sensor.account-balance-sensor');
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
/**
|
||||||
|
* account-balance-sensor router
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { factories } from '@strapi/strapi';
|
||||||
|
|
||||||
|
export default factories.createCoreRouter('api::account-balance-sensor.account-balance-sensor');
|
||||||
|
|
@ -0,0 +1,7 @@
|
||||||
|
/**
|
||||||
|
* account-balance-sensor service
|
||||||
|
*/
|
||||||
|
|
||||||
|
import { factories } from '@strapi/strapi';
|
||||||
|
|
||||||
|
export default factories.createCoreService('api::account-balance-sensor.account-balance-sensor');
|
||||||
35
types/generated/contentTypes.d.ts
vendored
35
types/generated/contentTypes.d.ts
vendored
|
|
@ -369,6 +369,40 @@ export interface AdminUser extends Struct.CollectionTypeSchema {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface ApiAccountBalanceSensorAccountBalanceSensor
|
||||||
|
extends Struct.CollectionTypeSchema {
|
||||||
|
collectionName: 'account_balance_sensors';
|
||||||
|
info: {
|
||||||
|
displayName: 'Sensor: Account Balance';
|
||||||
|
pluralName: 'account-balance-sensors';
|
||||||
|
singularName: 'account-balance-sensor';
|
||||||
|
};
|
||||||
|
options: {
|
||||||
|
draftAndPublish: true;
|
||||||
|
};
|
||||||
|
attributes: {
|
||||||
|
createdAt: Schema.Attribute.DateTime;
|
||||||
|
createdBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> &
|
||||||
|
Schema.Attribute.Private;
|
||||||
|
description: Schema.Attribute.Text;
|
||||||
|
lastchange: Schema.Attribute.BigInteger;
|
||||||
|
locale: Schema.Attribute.String & Schema.Attribute.Private;
|
||||||
|
localizations: Schema.Attribute.Relation<
|
||||||
|
'oneToMany',
|
||||||
|
'api::account-balance-sensor.account-balance-sensor'
|
||||||
|
> &
|
||||||
|
Schema.Attribute.Private;
|
||||||
|
location: Schema.Attribute.String & Schema.Attribute.Required;
|
||||||
|
name: Schema.Attribute.String;
|
||||||
|
publishedAt: Schema.Attribute.DateTime;
|
||||||
|
unit: Schema.Attribute.String & Schema.Attribute.Required;
|
||||||
|
updatedAt: Schema.Attribute.DateTime;
|
||||||
|
updatedBy: Schema.Attribute.Relation<'oneToOne', 'admin::user'> &
|
||||||
|
Schema.Attribute.Private;
|
||||||
|
value: Schema.Attribute.Decimal & Schema.Attribute.Required;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
export interface ApiBarometerSensorBarometerSensor
|
export interface ApiBarometerSensorBarometerSensor
|
||||||
extends Struct.CollectionTypeSchema {
|
extends Struct.CollectionTypeSchema {
|
||||||
collectionName: 'barometer_sensors';
|
collectionName: 'barometer_sensors';
|
||||||
|
|
@ -1377,6 +1411,7 @@ declare module '@strapi/strapi' {
|
||||||
'admin::transfer-token': AdminTransferToken;
|
'admin::transfer-token': AdminTransferToken;
|
||||||
'admin::transfer-token-permission': AdminTransferTokenPermission;
|
'admin::transfer-token-permission': AdminTransferTokenPermission;
|
||||||
'admin::user': AdminUser;
|
'admin::user': AdminUser;
|
||||||
|
'api::account-balance-sensor.account-balance-sensor': ApiAccountBalanceSensorAccountBalanceSensor;
|
||||||
'api::barometer-sensor.barometer-sensor': ApiBarometerSensorBarometerSensor;
|
'api::barometer-sensor.barometer-sensor': ApiBarometerSensorBarometerSensor;
|
||||||
'api::beverage-supply.beverage-supply': ApiBeverageSupplyBeverageSupply;
|
'api::beverage-supply.beverage-supply': ApiBeverageSupplyBeverageSupply;
|
||||||
'api::carbondioxide-sensor.carbondioxide-sensor': ApiCarbondioxideSensorCarbondioxideSensor;
|
'api::carbondioxide-sensor.carbondioxide-sensor': ApiCarbondioxideSensorCarbondioxideSensor;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue