From b392a4af78e01c8e0f50aad5468e9583675b24be Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Sat, 6 Apr 2024 09:17:52 -0700 Subject: Move to the legacy folder --- web/app/model/Attribute.js | 33 ------------ web/app/model/Calendar.js | 34 ------------- web/app/model/Command.js | 40 --------------- web/app/model/ComputedAttribute.js | 39 -------------- web/app/model/Device.js | 64 ----------------------- web/app/model/Driver.js | 35 ------------- web/app/model/Event.js | 81 ----------------------------- web/app/model/Geofence.js | 40 --------------- web/app/model/Group.js | 34 ------------- web/app/model/KnownAttribute.js | 35 ------------- web/app/model/KnownCommand.js | 34 ------------- web/app/model/KnownNotification.js | 32 ------------ web/app/model/KnownNotificator.js | 32 ------------ web/app/model/Maintenance.js | 41 --------------- web/app/model/Notification.js | 40 --------------- web/app/model/Position.js | 72 -------------------------- web/app/model/ReportStop.js | 58 --------------------- web/app/model/ReportSummary.js | 61 ---------------------- web/app/model/ReportTrip.js | 77 ---------------------------- web/app/model/Server.js | 88 -------------------------------- web/app/model/Statistics.js | 59 ---------------------- web/app/model/User.js | 101 ------------------------------------- 22 files changed, 1130 deletions(-) delete mode 100644 web/app/model/Attribute.js delete mode 100644 web/app/model/Calendar.js delete mode 100644 web/app/model/Command.js delete mode 100644 web/app/model/ComputedAttribute.js delete mode 100644 web/app/model/Device.js delete mode 100644 web/app/model/Driver.js delete mode 100644 web/app/model/Event.js delete mode 100644 web/app/model/Geofence.js delete mode 100644 web/app/model/Group.js delete mode 100644 web/app/model/KnownAttribute.js delete mode 100644 web/app/model/KnownCommand.js delete mode 100644 web/app/model/KnownNotification.js delete mode 100644 web/app/model/KnownNotificator.js delete mode 100644 web/app/model/Maintenance.js delete mode 100644 web/app/model/Notification.js delete mode 100644 web/app/model/Position.js delete mode 100644 web/app/model/ReportStop.js delete mode 100644 web/app/model/ReportSummary.js delete mode 100644 web/app/model/ReportTrip.js delete mode 100644 web/app/model/Server.js delete mode 100644 web/app/model/Statistics.js delete mode 100644 web/app/model/User.js (limited to 'web/app/model') diff --git a/web/app/model/Attribute.js b/web/app/model/Attribute.js deleted file mode 100644 index b1586a73..00000000 --- a/web/app/model/Attribute.js +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright 2015 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Attribute', { - extend: 'Ext.data.Model', - - fields: [{ - name: 'priority', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'value' - }, { - name: 'attribute', - type: 'string' - }] -}); diff --git a/web/app/model/Calendar.js b/web/app/model/Calendar.js deleted file mode 100644 index 8c44d625..00000000 --- a/web/app/model/Calendar.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright 2016 Anton Tananaev (anton@traccar.org) - * Copyright 2016 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Calendar', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'data' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/Command.js b/web/app/model/Command.js deleted file mode 100644 index f64d2a4b..00000000 --- a/web/app/model/Command.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2015 - 2017 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Command', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'description', - type: 'string' - }, { - name: 'deviceId', - type: 'int' - }, { - name: 'type', - type: 'string' - }, { - name: 'textChannel', - type: 'boolean' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/ComputedAttribute.js b/web/app/model/ComputedAttribute.js deleted file mode 100644 index 16a78ef1..00000000 --- a/web/app/model/ComputedAttribute.js +++ /dev/null @@ -1,39 +0,0 @@ -/* - * Copyright 2017 Anton Tananaev (anton@traccar.org) - * Copyright 2017 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.ComputedAttribute', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'description', - type: 'string' - }, { - name: 'type', - type: 'string' - }, { - name: 'attribute', - type: 'string' - }, { - name: 'expression', - type: 'string' - }] -}); diff --git a/web/app/model/Device.js b/web/app/model/Device.js deleted file mode 100644 index ca1e07a6..00000000 --- a/web/app/model/Device.js +++ /dev/null @@ -1,64 +0,0 @@ -/* - * Copyright 2015 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Device', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'uniqueId', - type: 'string' - }, { - name: 'phone', - type: 'string', - allowNull: true - }, { - name: 'model', - type: 'string', - allowNull: true - }, { - name: 'contact', - type: 'string', - allowNull: true - }, { - name: 'category', - type: 'string', - allowNull: true - }, { - name: 'status', - type: 'string', - allowNull: true - }, { - name: 'lastUpdate', - type: 'date', - dateFormat: 'c' - }, { - name: 'groupId', - type: 'int' - }, { - name: 'disabled', - type: 'boolean' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/Driver.js b/web/app/model/Driver.js deleted file mode 100644 index 3c3b30e5..00000000 --- a/web/app/model/Driver.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2017 Anton Tananaev (anton@traccar.org) - * Copyright 2017 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Driver', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'uniqueId', - type: 'string' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/Event.js b/web/app/model/Event.js deleted file mode 100644 index d1297dd7..00000000 --- a/web/app/model/Event.js +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright 2015 - 2018 Anton Tananaev (anton@traccar.org) - * Copyright 2017 - 2018 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Event', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'type', - type: 'string' - }, { - name: 'eventTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'deviceId', - type: 'int' - }, { - name: 'positionId', - type: 'int' - }, { - name: 'geofenceId', - type: 'int' - }, { - name: 'maintenanceId', - type: 'int' - }, { - name: 'text', - convert: function (v, rec) { - var text, alarmKey, geofence, maintenance; - if (rec.get('type') === 'commandResult') { - text = Strings.eventCommandResult + ': ' + rec.get('attributes')['result']; - } else if (rec.get('type') === 'alarm') { - alarmKey = rec.get('attributes')['alarm']; - alarmKey = 'alarm' + alarmKey.charAt(0).toUpperCase() + alarmKey.slice(1); - text = Strings[alarmKey] || alarmKey; - } else if (rec.get('type') === 'textMessage') { - text = Strings.eventTextMessage + ': ' + rec.get('attributes')['message']; - } else if (rec.get('type') === 'driverChanged') { - text = Strings.eventDriverChanged + ': ' + - Traccar.AttributeFormatter.driverUniqueIdFormatter(rec.get('attributes')['driverUniqueId']); - } else { - text = Traccar.app.getEventString(rec.get('type')); - } - if (rec.get('geofenceId')) { - geofence = Ext.getStore('Geofences').getById(rec.get('geofenceId')); - if (geofence) { - text += ' "' + geofence.get('name') + '"'; - } - } - if (rec.get('maintenanceId')) { - maintenance = Ext.getStore('Maintenances').getById(rec.get('maintenanceId')); - if (maintenance) { - text += ' "' + maintenance.get('name') + '"'; - } - } - return text; - }, - depends: ['type', 'attributes', 'geofenceId', 'maintenanceId'] - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/Geofence.js b/web/app/model/Geofence.js deleted file mode 100644 index 12a9f878..00000000 --- a/web/app/model/Geofence.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2016 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Geofence', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'description', - type: 'string' - }, { - name: 'area', - type: 'string' - }, { - name: 'calendarId', - type: 'int' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/Group.js b/web/app/model/Group.js deleted file mode 100644 index 8230fda1..00000000 --- a/web/app/model/Group.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright 2016 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Group', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'groupId', - type: 'int' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/KnownAttribute.js b/web/app/model/KnownAttribute.js deleted file mode 100644 index f6f41a73..00000000 --- a/web/app/model/KnownAttribute.js +++ /dev/null @@ -1,35 +0,0 @@ -/* - * Copyright 2017 Anton Tananaev (anton@traccar.org) - * Copyright 2017 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -Ext.define('Traccar.model.KnownAttribute', { - extend: 'Ext.data.Model', - idProperty: 'key', - - fields: [{ - name: 'key', - type: 'string' - }, { - name: 'name', - type: 'string' - }, { - name: 'valueType', - type: 'string' - }, { - name: 'dataType', - type: 'string' - }] -}); diff --git a/web/app/model/KnownCommand.js b/web/app/model/KnownCommand.js deleted file mode 100644 index 06610e32..00000000 --- a/web/app/model/KnownCommand.js +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright 2017 Anton Tananaev (anton@traccar.org) - * Copyright 2017 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -Ext.define('Traccar.model.KnownCommand', { - extend: 'Ext.data.Model', - idProperty: 'type', - - fields: [{ - name: 'type', - type: 'string' - }, { - name: 'name', - convert: function (v, rec) { - return Traccar.AttributeFormatter.getFormatter('commandType')(rec.get('type')); - }, - depends: ['type'] - }, { - name: 'parameters' - }] -}); diff --git a/web/app/model/KnownNotification.js b/web/app/model/KnownNotification.js deleted file mode 100644 index f42ef972..00000000 --- a/web/app/model/KnownNotification.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright 2017 Anton Tananaev (anton@traccar.org) - * Copyright 2017 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -Ext.define('Traccar.model.KnownNotification', { - extend: 'Ext.data.Model', - idProperty: 'type', - - fields: [{ - name: 'type', - type: 'string' - }, { - name: 'name', - convert: function (v, rec) { - return Traccar.app.getEventString(rec.get('type')); - }, - depends: ['type'] - }] -}); diff --git a/web/app/model/KnownNotificator.js b/web/app/model/KnownNotificator.js deleted file mode 100644 index 7855a12b..00000000 --- a/web/app/model/KnownNotificator.js +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright 2018 Anton Tananaev (anton@traccar.org) - * Copyright 2018 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -Ext.define('Traccar.model.KnownNotificator', { - extend: 'Ext.data.Model', - idProperty: 'type', - - fields: [{ - name: 'type', - type: 'string' - }, { - name: 'name', - convert: function (v, rec) { - return Traccar.app.getNotificatorString(rec.get('type')); - }, - depends: ['type'] - }] -}); diff --git a/web/app/model/Maintenance.js b/web/app/model/Maintenance.js deleted file mode 100644 index a0654275..00000000 --- a/web/app/model/Maintenance.js +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright 2018 Anton Tananaev (anton@traccar.org) - * Copyright 2018 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Maintenance', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'type', - type: 'string' - }, { - name: 'start', - type: 'float' - }, { - name: 'period', - type: 'float' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/Notification.js b/web/app/model/Notification.js deleted file mode 100644 index fc9d84d7..00000000 --- a/web/app/model/Notification.js +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2016 - 2018 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Notification', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'type', - type: 'string' - }, { - name: 'always', - type: 'bool' - }, { - name: 'attributes' - }, { - name: 'notificators', - type: 'string' - }, { - name: 'calendarId', - type: 'int' - }] -}); diff --git a/web/app/model/Position.js b/web/app/model/Position.js deleted file mode 100644 index 6db54653..00000000 --- a/web/app/model/Position.js +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright 2015 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Position', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'protocol', - type: 'string' - }, { - name: 'deviceId', - type: 'int' - }, { - name: 'serverTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'deviceTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'fixTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'valid', - type: 'boolean' - }, { - name: 'accuracy', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('accuracy') - }, { - name: 'latitude', - type: 'float' - }, { - name: 'longitude', - type: 'float' - }, { - name: 'altitude', - type: 'float' - }, { - name: 'speed', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('speed') - }, { - name: 'course', - type: 'float' - }, { - name: 'address', - type: 'string' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/ReportStop.js b/web/app/model/ReportStop.js deleted file mode 100644 index 9aaa58b0..00000000 --- a/web/app/model/ReportStop.js +++ /dev/null @@ -1,58 +0,0 @@ -/* - * Copyright 2017 Anton Tananaev (anton@traccar.org) - * Copyright 2017 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.ReportStop', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'deviceId', - type: 'int' - }, { - name: 'deviceName', - type: 'string' - }, { - name: 'duration', - type: 'int' - }, { - name: 'startTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'startOdometer', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'address', - type: 'string' - }, { - name: 'endTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'engineHours', - type: 'int' - }, { - name: 'positionId', - type: 'int' - }, { - name: 'spentFuel', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('spentFuel') - }] -}); diff --git a/web/app/model/ReportSummary.js b/web/app/model/ReportSummary.js deleted file mode 100644 index 559ffd41..00000000 --- a/web/app/model/ReportSummary.js +++ /dev/null @@ -1,61 +0,0 @@ -/* - * Copyright 2016 Anton Tananaev (anton@traccar.org) - * Copyright 2016 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.ReportSummary', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'deviceId', - type: 'int' - }, { - name: 'deviceName', - type: 'string' - }, { - name: 'startTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'maxSpeed', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('speed') - }, { - name: 'averageSpeed', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('speed') - }, { - name: 'distance', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'startOdometer', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'endOdometer', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'engineHours', - type: 'int' - }, { - name: 'spentFuel', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('spentFuel') - }] -}); diff --git a/web/app/model/ReportTrip.js b/web/app/model/ReportTrip.js deleted file mode 100644 index 9d45fc87..00000000 --- a/web/app/model/ReportTrip.js +++ /dev/null @@ -1,77 +0,0 @@ -/* - * Copyright 2016 Anton Tananaev (anton@traccar.org) - * Copyright 2016 Andrey Kunitsyn (andrey@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.ReportTrip', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'deviceId', - type: 'int' - }, { - name: 'deviceName', - type: 'string' - }, { - name: 'maxSpeed', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('speed') - }, { - name: 'averageSpeed', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('speed') - }, { - name: 'distance', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'startOdometer', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'endOdometer', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('distance') - }, { - name: 'duration', - type: 'int' - }, { - name: 'startTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'startAddress', - type: 'string' - }, { - name: 'endTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'endAddress', - type: 'string' - }, { - name: 'spentFuel', - type: 'float', - convert: Traccar.AttributeFormatter.getConverter('spentFuel') - }, { - name: 'driverUniqueId', - type: 'string' - }, { - name: 'driverName', - type: 'string' - }] -}); diff --git a/web/app/model/Server.js b/web/app/model/Server.js deleted file mode 100644 index 177b4fc4..00000000 --- a/web/app/model/Server.js +++ /dev/null @@ -1,88 +0,0 @@ -/* - * Copyright 2015 - 2018 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Server', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'registration', - type: 'boolean' - }, { - name: 'readonly', - type: 'boolean' - }, { - name: 'deviceReadonly', - type: 'boolean' - }, { - name: 'limitCommands', - type: 'boolean' - }, { - name: 'disableReports', - type: 'boolean' - }, { - name: 'map', - type: 'string' - }, { - name: 'bingKey', - type: 'string' - }, { - name: 'mapUrl', - type: 'string' - }, { - name: 'latitude', - type: 'float' - }, { - name: 'longitude', - type: 'float' - }, { - name: 'zoom', - type: 'int' - }, { - name: 'twelveHourFormat', - type: 'boolean' - }, { - name: 'forceSettings', - type: 'boolean' - }, { - name: 'coordinateFormat', - type: 'string' - }, { - name: 'poiLayer', - type: 'string' - }, { - name: 'announcement', - type: 'string' - }, { - name: 'attributes' - }], - - proxy: { - type: 'ajax', - url: 'api/server', - actionMethods: { - update: 'PUT' - }, - writer: { - type: 'json', - writeAllFields: true - } - } -}); diff --git a/web/app/model/Statistics.js b/web/app/model/Statistics.js deleted file mode 100644 index 95280ac4..00000000 --- a/web/app/model/Statistics.js +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright 2016 - 2017 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.Statistics', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'captureTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'activeUsers', - type: 'int' - }, { - name: 'activeDevices', - type: 'int' - }, { - name: 'requests', - type: 'int' - }, { - name: 'messagesReceived', - type: 'int' - }, { - name: 'messagesStored', - type: 'int' - }, { - name: 'mailSent', - type: 'int' - }, { - name: 'smsSent', - type: 'int' - }, { - name: 'geocoderRequests', - type: 'int' - }, { - name: 'geolocationRequests', - type: 'int' - }, { - name: 'attributes' - }] -}); diff --git a/web/app/model/User.js b/web/app/model/User.js deleted file mode 100644 index 455bca64..00000000 --- a/web/app/model/User.js +++ /dev/null @@ -1,101 +0,0 @@ -/* - * Copyright 2015 - 2018 Anton Tananaev (anton@traccar.org) - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -Ext.define('Traccar.model.User', { - extend: 'Ext.data.Model', - identifier: 'negative', - - fields: [{ - name: 'id', - type: 'int' - }, { - name: 'name', - type: 'string' - }, { - name: 'login', - type: 'string' - }, { - name: 'email', - type: 'string' - }, { - name: 'password', - type: 'string' - }, { - name: 'phone', - type: 'string' - }, { - name: 'readonly', - type: 'boolean' - }, { - name: 'administrator', - type: 'boolean' - }, { - name: 'map', - type: 'string' - }, { - name: 'latitude', - type: 'float' - }, { - name: 'longitude', - type: 'float' - }, { - name: 'zoom', - type: 'int' - }, { - name: 'twelveHourFormat', - type: 'boolean' - }, { - name: 'coordinateFormat', - type: 'string' - }, { - name: 'disabled', - type: 'boolean' - }, { - name: 'expirationTime', - type: 'date', - dateFormat: 'c' - }, { - name: 'deviceLimit', - type: 'int' - }, { - name: 'userLimit', - type: 'int' - }, { - name: 'deviceReadonly', - type: 'boolean' - }, { - name: 'limitCommands', - type: 'boolean' - }, { - name: 'disableReports', - type: 'boolean' - }, { - name: 'poiLayer', - type: 'string' - }, { - name: 'attributes' - }], - - proxy: { - type: 'rest', - url: 'api/users', - writer: { - type: 'json', - writeAllFields: true - } - } -}); -- cgit v1.2.3