From 274b412718b81deba404a1d10ae83d5d3c82238a Mon Sep 17 00:00:00 2001 From: Abyss777 Date: Mon, 20 Feb 2017 14:03:47 +0500 Subject: Add SMS to notifications and phone to user --- web/app/model/Notification.js | 3 +++ web/app/model/User.js | 3 +++ web/app/view/DeviceDialog.js | 2 +- web/app/view/Notifications.js | 7 +++++++ web/app/view/UserDialog.js | 4 ++++ web/l10n/en.json | 3 ++- 6 files changed, 20 insertions(+), 2 deletions(-) (limited to 'web') diff --git a/web/app/model/Notification.js b/web/app/model/Notification.js index 54f6674..3ae13c0 100644 --- a/web/app/model/Notification.js +++ b/web/app/model/Notification.js @@ -36,5 +36,8 @@ Ext.define('Traccar.model.Notification', { }, { name: 'mail', type: 'bool' + }, { + name: 'sms', + type: 'bool' }] }); diff --git a/web/app/model/User.js b/web/app/model/User.js index df346ee..49400a3 100644 --- a/web/app/model/User.js +++ b/web/app/model/User.js @@ -31,6 +31,9 @@ Ext.define('Traccar.model.User', { }, { name: 'password', type: 'string' + }, { + name: 'phone', + type: 'string' }, { name: 'readonly', type: 'boolean' diff --git a/web/app/view/DeviceDialog.js b/web/app/view/DeviceDialog.js index 960b3f9..5782069 100644 --- a/web/app/view/DeviceDialog.js +++ b/web/app/view/DeviceDialog.js @@ -43,7 +43,7 @@ Ext.define('Traccar.view.DeviceDialog', { }, { xtype: 'textfield', name: 'phone', - fieldLabel: Strings.devicePhone + fieldLabel: Strings.sharedPhone }, { xtype: 'textfield', name: 'model', diff --git a/web/app/view/Notifications.js b/web/app/view/Notifications.js index 8f6ca48..0f6552a 100644 --- a/web/app/view/Notifications.js +++ b/web/app/view/Notifications.js @@ -59,6 +59,13 @@ Ext.define('Traccar.view.Notifications', { listeners: { checkChange: 'onCheckChange' } + }, { + text: Strings.notificationSms, + dataIndex: 'sms', + xtype: 'checkcolumn', + listeners: { + checkChange: 'onCheckChange' + } }] } }); diff --git a/web/app/view/UserDialog.js b/web/app/view/UserDialog.js index 34c3b4a..84103ee 100644 --- a/web/app/view/UserDialog.js +++ b/web/app/view/UserDialog.js @@ -42,6 +42,10 @@ Ext.define('Traccar.view.UserDialog', { fieldLabel: Strings.userPassword, inputType: 'password', allowBlank: false + }, { + xtype: 'textfield', + name: 'phone', + fieldLabel: Strings.sharedPhone }, { xtype: 'checkboxfield', inputValue: true, diff --git a/web/l10n/en.json b/web/l10n/en.json index 62f8a22..222f388 100644 --- a/web/l10n/en.json +++ b/web/l10n/en.json @@ -46,6 +46,7 @@ "sharedCalendars": "Calendars", "sharedFile": "File", "sharedSelectFile": "Select File", + "sharedPhone": "Phone", "errorTitle": "Error", "errorUnknown": "Unknown error", "errorConnection": "Connection error", @@ -71,7 +72,6 @@ "devicesAndState": "Devices and State", "deviceTitle": "Devices", "deviceIdentifier": "Identifier", - "devicePhone": "Phone", "deviceModel": "Model", "deviceContact": "Contact", "deviceCategory": "Category", @@ -184,6 +184,7 @@ "notificationType": "Type of Notification", "notificationWeb": "Send via Web", "notificationMail": "Send via Mail", + "notificationSms": "Send via SMS", "reportRoute": "Route", "reportEvents": "Events", "reportTrips": "Trips", -- cgit v1.2.3