diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidAPIUtils.java b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidAPIUtils.java index 0ae9e65e4..89fc4481a 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidAPIUtils.java +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidAPIUtils.java @@ -339,7 +339,7 @@ public class AndroidAPIUtils { app.setVersion(element.getAsJsonObject().get(AndroidConstants.ApplicationProperties.VERSION).getAsString()); } if (element.getAsJsonObject().get(AndroidConstants.ApplicationProperties.IS_ACTIVE) != null) { - app.setActive(element.getAsJsonObject().get(AndroidConstants.ApplicationProperties.VERSION).getAsBoolean()); + app.setActive(element.getAsJsonObject().get(AndroidConstants.ApplicationProperties.IS_ACTIVE).getAsBoolean()); } applications.add(app); } @@ -396,6 +396,8 @@ public class AndroidAPIUtils { deviceInfo.getDeviceDetailsMap().put("mac", prop.getValue()); } else if (prop.getName().equalsIgnoreCase("SERIAL")) { deviceInfo.getDeviceDetailsMap().put("serial", prop.getValue()); + } else if (prop.getName().equalsIgnoreCase("OS_BUILD_DATE")) { + deviceInfo.setOsBuildDate(prop.getValue()); } } else { if (prop.getName().equalsIgnoreCase("CPU_INFO")) { diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidConstants.java b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidConstants.java index 5102b3c01..58519bb83 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidConstants.java +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android.api/src/main/java/org/wso2/carbon/mdm/services/android/util/AndroidConstants.java @@ -128,7 +128,7 @@ public final class AndroidConstants { public static final String USS = "USS"; public static final String VERSION = "version"; public static final String ICON = "icon"; - public static final String IS_ACTIVE = "is_active"; + public static final String IS_ACTIVE = "isActive"; } } diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/dao/impl/AndroidDeviceDAOImpl.java b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/dao/impl/AndroidDeviceDAOImpl.java index 1c72d858b..2fa63e5bc 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/dao/impl/AndroidDeviceDAOImpl.java +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/dao/impl/AndroidDeviceDAOImpl.java @@ -53,7 +53,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ conn = AndroidDAOFactory.getConnection(); String selectDBQuery = "SELECT DEVICE_ID, GCM_TOKEN, DEVICE_INFO, DEVICE_MODEL, SERIAL, " + - "VENDOR, MAC_ADDRESS, DEVICE_NAME, LATITUDE, LONGITUDE, IMEI, IMSI, OS_VERSION" + + "VENDOR, MAC_ADDRESS, DEVICE_NAME, LATITUDE, LONGITUDE, IMEI, IMSI, OS_VERSION, OS_BUILD_DATE" + " FROM AD_DEVICE WHERE DEVICE_ID = ?"; stmt = conn.prepareStatement(selectDBQuery); stmt.setString(1, mblDeviceId); @@ -70,6 +70,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ mobileDevice.setImei(rs.getString(AndroidPluginConstants.IMEI)); mobileDevice.setImsi(rs.getString(AndroidPluginConstants.IMSI)); mobileDevice.setOsVersion(rs.getString(AndroidPluginConstants.OS_VERSION)); + mobileDevice.setOsBuildDate(rs.getString(AndroidPluginConstants.OS_BUILD_DATE)); Map propertyMap = new HashMap(); propertyMap.put(AndroidPluginConstants.GCM_TOKEN, rs.getString(AndroidPluginConstants.GCM_TOKEN)); @@ -104,7 +105,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ String createDBQuery = "INSERT INTO AD_DEVICE(DEVICE_ID, GCM_TOKEN, DEVICE_INFO, SERIAL, " + "VENDOR, MAC_ADDRESS, DEVICE_NAME, LATITUDE, LONGITUDE, IMEI, IMSI, " + - "OS_VERSION, DEVICE_MODEL) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"; + "OS_VERSION, DEVICE_MODEL, OS_BUILD_DATE) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"; stmt = conn.prepareStatement(createDBQuery); stmt.setString(1, mobileDevice.getMobileDeviceId()); @@ -122,6 +123,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ stmt.setString(11, mobileDevice.getImsi()); stmt.setString(12, mobileDevice.getOsVersion()); stmt.setString(13, mobileDevice.getModel()); + stmt.setString(14, mobileDevice.getOsBuildDate()); int rows = stmt.executeUpdate(); if (rows > 0) { status = true; @@ -149,7 +151,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ String updateDBQuery = "UPDATE AD_DEVICE SET GCM_TOKEN = ?, DEVICE_INFO = ?, SERIAL = ?, VENDOR = ?, " + "MAC_ADDRESS = ?, DEVICE_NAME = ?, LATITUDE = ?, LONGITUDE = ?, IMEI = ?, " + - "IMSI = ?, OS_VERSION = ?, DEVICE_MODEL = ? WHERE DEVICE_ID = ?"; + "IMSI = ?, OS_VERSION = ?, DEVICE_MODEL = ?, OS_BUILD_DATE = ? WHERE DEVICE_ID = ?"; stmt = conn.prepareStatement(updateDBQuery); Map properties = mobileDevice.getDeviceProperties(); @@ -166,6 +168,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ stmt.setString(11, mobileDevice.getOsVersion()); stmt.setString(12, mobileDevice.getModel()); stmt.setString(13, mobileDevice.getMobileDeviceId()); + stmt.setString(14, mobileDevice.getOsBuildDate()); int rows = stmt.executeUpdate(); if (rows > 0) { status = true; @@ -225,7 +228,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ conn = AndroidDAOFactory.getConnection(); String selectDBQuery = "SELECT DEVICE_ID, GCM_TOKEN, DEVICE_INFO, DEVICE_MODEL, SERIAL, " + - "VENDOR, MAC_ADDRESS, DEVICE_NAME, LATITUDE, LONGITUDE, IMEI, IMSI, OS_VERSION " + + "VENDOR, MAC_ADDRESS, DEVICE_NAME, LATITUDE, LONGITUDE, IMEI, IMSI, OS_VERSION, OS_BUILD_DATE " + "FROM AD_DEVICE"; stmt = conn.prepareStatement(selectDBQuery); rs = stmt.executeQuery(); @@ -241,6 +244,7 @@ public class AndroidDeviceDAOImpl implements MobileDeviceDAO{ mobileDevice.setImei(rs.getString(AndroidPluginConstants.IMEI)); mobileDevice.setImsi(rs.getString(AndroidPluginConstants.IMSI)); mobileDevice.setOsVersion(rs.getString(AndroidPluginConstants.OS_VERSION)); + mobileDevice.setOsBuildDate(rs.getString(AndroidPluginConstants.OS_BUILD_DATE)); Map propertyMap = new HashMap<>(); propertyMap.put(AndroidPluginConstants.GCM_TOKEN, rs.getString(AndroidPluginConstants.GCM_TOKEN)); diff --git a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/util/AndroidPluginConstants.java b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/util/AndroidPluginConstants.java index 7f6386210..31fea9d5d 100644 --- a/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/util/AndroidPluginConstants.java +++ b/components/mobile-plugins/android-plugin/org.wso2.carbon.device.mgt.mobile.android/src/main/java/org/wso2/carbon/device/mgt/mobile/android/impl/util/AndroidPluginConstants.java @@ -36,6 +36,7 @@ public class AndroidPluginConstants { public static final String IMSI = "IMSI"; public static final String VENDOR = "VENDOR"; public static final String OS_VERSION = "OS_VERSION"; + public static final String OS_BUILD_DATE = "OS_BUILD_DATE"; public static final String MAC_ADDRESS = "MAC_ADDRESS"; //Properties related to AD_FEATURE table diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/dto/MobileDevice.java b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/dto/MobileDevice.java index 185168da4..6de016dfb 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/dto/MobileDevice.java +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/dto/MobileDevice.java @@ -19,6 +19,7 @@ package org.wso2.carbon.device.mgt.mobile.dto; import java.io.Serializable; +import java.util.Date; import java.util.HashMap; import java.util.Map; @@ -36,6 +37,8 @@ public class MobileDevice implements Serializable { private String imei; private String imsi; private String serial; + private String osBuildDate; + private Map deviceProperties; public MobileDevice() { @@ -122,4 +125,11 @@ public class MobileDevice implements Serializable { this.deviceProperties = deviceProperties; } + public String getOsBuildDate() { + return osBuildDate; + } + + public void setOsBuildDate(String osBuildDate) { + this.osBuildDate = osBuildDate; + } } diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/util/MobileDeviceManagementUtil.java b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/util/MobileDeviceManagementUtil.java index 34d9dced1..d23bab34b 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/util/MobileDeviceManagementUtil.java +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/main/java/org/wso2/carbon/device/mgt/mobile/util/MobileDeviceManagementUtil.java @@ -38,6 +38,9 @@ import org.wso2.carbon.registry.core.Registry; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import java.io.File; +import java.text.DateFormat; +import java.text.ParseException; +import java.text.SimpleDateFormat; import java.util.*; /** @@ -54,6 +57,7 @@ public class MobileDeviceManagementUtil { private static final String MOBILE_DEVICE_LATITUDE = "LATITUDE"; private static final String MOBILE_DEVICE_LONGITUDE = "LONGITUDE"; private static final String MOBILE_DEVICE_SERIAL = "SERIAL"; + private static final String MOBILE_DEVICE_OS_BUILD_DATE = "OS_BUILD_DATE"; public static Document convertToDocument(File file) throws DeviceManagementException { DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); @@ -100,6 +104,7 @@ public class MobileDeviceManagementUtil { mobileDevice.setLatitude(getPropertyValue(device, MOBILE_DEVICE_LATITUDE)); mobileDevice.setLongitude(getPropertyValue(device, MOBILE_DEVICE_LONGITUDE)); mobileDevice.setSerial(getPropertyValue(device, MOBILE_DEVICE_SERIAL)); + mobileDevice.setOsBuildDate(getPropertyValue(device, MOBILE_DEVICE_OS_BUILD_DATE)); if (device.getProperties() != null) { Map deviceProperties = new HashMap(); @@ -124,6 +129,7 @@ public class MobileDeviceManagementUtil { propertyList.add(getProperty(MOBILE_DEVICE_IMSI, mobileDevice.getImsi())); propertyList.add(getProperty(MOBILE_DEVICE_MODEL, mobileDevice.getModel())); propertyList.add(getProperty(MOBILE_DEVICE_OS_VERSION, mobileDevice.getOsVersion())); + propertyList.add(getProperty(MOBILE_DEVICE_OS_BUILD_DATE, mobileDevice.getOsBuildDate())); propertyList.add(getProperty(MOBILE_DEVICE_VENDOR, mobileDevice.getVendor())); if(mobileDevice.getLatitude() != null) { propertyList.add(getProperty(MOBILE_DEVICE_LATITUDE, mobileDevice.getLatitude())); diff --git a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/test/resources/sql/h2.sql b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/test/resources/sql/h2.sql index 78b5b7b8b..6d2106879 100644 --- a/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/test/resources/sql/h2.sql +++ b/components/mobile-plugins/mobile-base-plugin/org.wso2.carbon.device.mgt.mobile/src/test/resources/sql/h2.sql @@ -16,6 +16,7 @@ CREATE TABLE IF NOT EXISTS `AD_DEVICE` ( `TOKEN` VARCHAR(500) NULL DEFAULT NULL, `UNLOCK_TOKEN` VARCHAR(500) NULL DEFAULT NULL, `SERIAL` VARCHAR(45) NULL DEFAULT NULL, + `OS_BUILD_DATE` VARCHAR(45) NULL DEFAULT NULL, PRIMARY KEY (`DEVICE_ID`) ); diff --git a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/h2.sql b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/h2.sql index 3673fd122..3352ba8de 100644 --- a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/h2.sql +++ b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/h2.sql @@ -16,6 +16,7 @@ CREATE TABLE IF NOT EXISTS `AD_DEVICE` ( `SERIAL` VARCHAR(45) NULL DEFAULT NULL, `MAC_ADDRESS` VARCHAR(45) NULL DEFAULT NULL, `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, + `OS_BUILD_DATE` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`DEVICE_ID`)); -- ----------------------------------------------------- diff --git a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mssql.sql b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mssql.sql index be8caf6c4..2269e4c19 100644 --- a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mssql.sql +++ b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mssql.sql @@ -15,6 +15,7 @@ CREATE TABLE AD_DEVICE ( SERIAL VARCHAR(45) NULL DEFAULT NULL, MAC_ADDRESS VARCHAR(45) NULL DEFAULT NULL, DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + OS_BUILD_DATE VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (DEVICE_ID)); -- ----------------------------------------------------- diff --git a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mysql.sql b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mysql.sql index 8e85b92c2..3fc6fd32c 100644 --- a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mysql.sql +++ b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/mysql.sql @@ -15,6 +15,7 @@ CREATE TABLE IF NOT EXISTS `AD_DEVICE` ( `SERIAL` VARCHAR(45) NULL DEFAULT NULL, `MAC_ADDRESS` VARCHAR(45) NULL DEFAULT NULL, `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, + `OS_BUILD_DATE` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`DEVICE_ID`)) ENGINE = InnoDB; diff --git a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/oracle.sql b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/oracle.sql index 1331581e7..ba4b4239b 100644 --- a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/oracle.sql +++ b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/oracle.sql @@ -15,6 +15,7 @@ CREATE TABLE AD_DEVICE ( SERIAL VARCHAR(45) DEFAULT NULL, MAC_ADDRESS VARCHAR(45) DEFAULT NULL, DEVICE_NAME VARCHAR(100) DEFAULT NULL, + OS_BUILD_DATE VARCHAR(100) DEFAULT NULL, CONSTRAINT PK_AD_DEVICE PRIMARY KEY (DEVICE_ID) ) / diff --git a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/postgresql.sql b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/postgresql.sql index e4512c53f..95c4709cc 100644 --- a/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/postgresql.sql +++ b/features/mobile-plugins-feature/android-plugin-feature/org.wso2.carbon.device.mgt.mobile.android.feature/src/main/resources/dbscripts/plugins/postgresql.sql @@ -15,6 +15,7 @@ CREATE TABLE IF NOT EXISTS AD_DEVICE ( SERIAL VARCHAR(45) NULL DEFAULT NULL, MAC_ADDRESS VARCHAR(45) NULL DEFAULT NULL, DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + OS_BUILD_DATE VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (DEVICE_ID) ); diff --git a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/h2.sql b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/h2.sql index 3673fd122..3352ba8de 100644 --- a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/h2.sql +++ b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/h2.sql @@ -16,6 +16,7 @@ CREATE TABLE IF NOT EXISTS `AD_DEVICE` ( `SERIAL` VARCHAR(45) NULL DEFAULT NULL, `MAC_ADDRESS` VARCHAR(45) NULL DEFAULT NULL, `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, + `OS_BUILD_DATE` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`DEVICE_ID`)); -- ----------------------------------------------------- diff --git a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mssql.sql b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mssql.sql index be8caf6c4..2269e4c19 100644 --- a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mssql.sql +++ b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mssql.sql @@ -15,6 +15,7 @@ CREATE TABLE AD_DEVICE ( SERIAL VARCHAR(45) NULL DEFAULT NULL, MAC_ADDRESS VARCHAR(45) NULL DEFAULT NULL, DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + OS_BUILD_DATE VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (DEVICE_ID)); -- ----------------------------------------------------- diff --git a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mysql.sql b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mysql.sql index 8e85b92c2..3fc6fd32c 100644 --- a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mysql.sql +++ b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/mysql.sql @@ -15,6 +15,7 @@ CREATE TABLE IF NOT EXISTS `AD_DEVICE` ( `SERIAL` VARCHAR(45) NULL DEFAULT NULL, `MAC_ADDRESS` VARCHAR(45) NULL DEFAULT NULL, `DEVICE_NAME` VARCHAR(100) NULL DEFAULT NULL, + `OS_BUILD_DATE` VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (`DEVICE_ID`)) ENGINE = InnoDB; diff --git a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/oracle.sql b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/oracle.sql index 1331581e7..ba4b4239b 100644 --- a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/oracle.sql +++ b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/oracle.sql @@ -15,6 +15,7 @@ CREATE TABLE AD_DEVICE ( SERIAL VARCHAR(45) DEFAULT NULL, MAC_ADDRESS VARCHAR(45) DEFAULT NULL, DEVICE_NAME VARCHAR(100) DEFAULT NULL, + OS_BUILD_DATE VARCHAR(100) DEFAULT NULL, CONSTRAINT PK_AD_DEVICE PRIMARY KEY (DEVICE_ID) ) / diff --git a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/postgresql.sql b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/postgresql.sql index e4512c53f..95c4709cc 100644 --- a/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/postgresql.sql +++ b/features/mobile-plugins-feature/mobile-base-plugin-feature/org.wso2.carbon.device.mgt.mobile.feature/src/main/resources/dbscripts/plugins/android/postgresql.sql @@ -15,6 +15,7 @@ CREATE TABLE IF NOT EXISTS AD_DEVICE ( SERIAL VARCHAR(45) NULL DEFAULT NULL, MAC_ADDRESS VARCHAR(45) NULL DEFAULT NULL, DEVICE_NAME VARCHAR(100) NULL DEFAULT NULL, + OS_BUILD_DATE VARCHAR(100) NULL DEFAULT NULL, PRIMARY KEY (DEVICE_ID) );