瀏覽代碼

Graphy增加适配视图功能。

张维新 4 年之前
父節點
當前提交
ae6bd9e666

+ 13 - 3
build.gradle

@@ -21,15 +21,21 @@
  * ********************************************************************************************************************
  */
 
-group SYBOTAN_GROUP
-version SYBOTAN_ANDROID_VERSION
+group SAGA_GROUP
+version SAGA_ANDROID_VERSION
 
 buildscript {
     repositories {
+
+        maven{ url'http://maven.aliyun.com/nexus/content/repositories/jcenter'}
+        maven { url 'https://maven.aliyun.com/repository/google' }
         maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
         mavenCentral()
         jcenter()
         google()
+
+
+
     }
     dependencies {
         classpath group: 'com.android.tools.build', name: 'gradle', version: GRADLE_VERSION
@@ -41,11 +47,15 @@ buildscript {
 
 allprojects {
     repositories {
+        mavenCentral()
         maven{ url MAVEN_REPO_PUBLIC_URL}
+        maven{ url'http://maven.aliyun.com/nexus/content/repositories/jcenter'}
+        maven { url 'https://maven.aliyun.com/repository/google' }
         maven{ url 'http://maven.aliyun.com/nexus/content/groups/public/'}
-        mavenCentral()
+
         jcenter()
         google()
+
     }
     tasks.withType(Javadoc) {
         options{

+ 3 - 3
demo/build.gradle

@@ -32,8 +32,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
         vectorDrawables.useSupportLibrary = true
@@ -127,7 +127,7 @@ dependencies {
 
     ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
     // Sybotan依赖
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-base', version: SYBOTAN_KOTLIN_VERSION
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-base', version: SAGA_KOTLIN_VERSION
     implementation project(':sybotan-android-base')
     implementation project(':sybotan-android-database')
     implementation project(':sybotan-android-devices')

+ 14 - 6
gradle.properties

@@ -23,11 +23,19 @@
 org.gradle.jvmargs = -Xmx1536m
 #org.gradle.configureondemand=false
 
-SYBOTAN_URL = http://www.sybotan.com
-SYBOTAN_KOTLIN_VERSION = 1.4.63
-SYBOTAN_ANDROID_VERSION = 1.2.35
-SYBOTAN_CODE = 5
-SYBOTAN_GROUP = com.sybotan
+SAGA_URL = http://www.sagaloud.cn
+SAGA_KOTLIN_VERSION = 1.4.102
+SAGA_SERVICE_VERSION = 1.4.140
+SAGA_ANDROID_VERSION = 1.2.40
+SAGA_CODE = 5
+SAGA_GROUP = cn.sagacloud
+
+
+#SYBOTAN_URL = http://www.sybotan.com
+#SYBOTAN_KOTLIN_VERSION = 1.4.64
+#SYBOTAN_ANDROID_VERSION = 1.2.36
+#SYBOTAN_CODE = 5
+#SYBOTAN_GROUP = com.sybotan
 
 MAVEN_REPO_PUBLIC_URL = http://dev.dp.sagacloud.cn:8082/repository/maven-public/
 MAVEN_REPO_RELEASE_URL = http://dev.dp.sagacloud.cn:8082/repository/maven-releases/
@@ -78,7 +86,7 @@ JACKSON_VERSION = 2.9.8
 # https://mvnrepository.com/artifact/org.junit.jupiter/junit-jupiter-api
 JUNIT_VERSION = 5.3.1
 # https://mvnrepository.com/artifact/org.jetbrains.kotlin/kotlin-stdlib-jdk8
-KOTLIN_VERSION = 1.3.20
+KOTLIN_VERSION = 1.3.72
 # https://mvnrepository.com/artifact/com.squareup.okhttp3/okhttp
 OKHTTP_VERSION = 3.11.0
 # https://mvnrepository.com/artifact/javax.persistence/persistence-api

+ 1 - 1
local.properties

@@ -21,4 +21,4 @@
 # *********************************************************************************************************************
 #
 
-sdk.dir=D\:/SDK/android/android-sdk-windows
+sdk.dir=D\:/studiosdk

+ 1 - 1
settings.gradle

@@ -20,7 +20,7 @@
  *
  * ********************************************************************************************************************
  */
-rootProject.name = 'sybotan-android'
+rootProject.name = 'saga-android'
 
 include ':sybotan-android-base'
 include ':sybotan-android-database'

+ 5 - 5
sybotan-android-base/build.gradle

@@ -47,8 +47,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
     }
@@ -112,8 +112,8 @@ dependencies {
     implementation group: 'com.google.zxing', name: 'core', version: ZXING_VERSION
 
     ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-    // Sybotan依赖
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-base', version: SYBOTAN_KOTLIN_VERSION
+    // SAGA依赖
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-base', version: SAGA_KOTLIN_VERSION
 }
 
 ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
@@ -162,7 +162,7 @@ uploadArchives {
             pom.project {
                 name project.name
                 packaging 'jar'
-                url SYBOTAN_URL
+                url SAGA_URL
                 description '斯伯坦机器人世界 android核心支持库。'
                 licenses {
                     license {

+ 6 - 6
sybotan-android-database/build.gradle

@@ -39,8 +39,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
     }
@@ -92,9 +92,9 @@ dependencies {
     implementation group: "javax.persistence", name: "persistence-api", version: PERSISTENCE_VERSION
 
     ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-    // Sybotan依赖
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-base', version: SYBOTAN_KOTLIN_VERSION
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-database', version: SYBOTAN_KOTLIN_VERSION
+    // SAGA依赖
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-base', version: SAGA_KOTLIN_VERSION
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-database', version: SAGA_KOTLIN_VERSION
     implementation project(':sybotan-android-base')
 }
 
@@ -143,7 +143,7 @@ uploadArchives {
             pom.project {
                 name project.name
                 packaging 'jar'
-                url SYBOTAN_URL
+                url SAGA_URL
                 description '斯伯坦机器人世界 android database库。'
                 licenses {
                     license {

+ 29 - 13
sybotan-android-database/src/main/java/com/sybotan/android/database/SAndroidDao.kt

@@ -102,6 +102,19 @@ abstract class SAndroidDao<ENTITY: Any>(entityClazz: Class<ENTITY>) : SAbstractD
         return true
     } // Function deleteAll()
 
+    override fun update(entity: ENTITY, projection: ArrayList<String>?, args: List<SFilter>?): Boolean {
+                use {
+            val whereArgs = ArrayList<Pair<String, Any>>()
+            val clause = buildWhereArgList(args!!, whereArgs)
+            val valueList = buildUpdateValues(entity, projection)
+            update("`${tableName()}`", *Array(valueList.size){ i-> valueList[i]})
+                    .whereArgs(clause, *Array(whereArgs.size){i-> whereArgs[i]}).exec()
+        }
+        return true
+    }
+
+
+
     /**
      * 根据条件更新
      *
@@ -109,16 +122,19 @@ abstract class SAndroidDao<ENTITY: Any>(entityClazz: Class<ENTITY>) : SAbstractD
      * @param   args        删除条件
      * @return  更新是否成功
      */
-    override fun update(entity: ENTITY, projection: ArrayList<String>?, args: List<SFilter>): Boolean {
-        use {
-            val whereArgs = ArrayList<Pair<String, Any>>()
-            val clause = buildWhereArgList(args, whereArgs)
-            val valueList = buildUpdateValues(entity, projection)
-            update("`${tableName()}`", *Array(valueList.size){ i-> valueList[i]})
-                    .whereArgs(clause, *Array(whereArgs.size){i-> whereArgs[i]}).exec()
-        }
-        return true
-    } // Function update()
+//    override fun update(entity: ENTITY, projection: ArrayList<String>?, args: List<SFilter>): Boolean {
+//        use {
+//            val whereArgs = ArrayList<Pair<String, Any>>()
+//            val clause = buildWhereArgList(args, whereArgs)
+//            val valueList = buildUpdateValues(entity, projection)
+//            update("`${tableName()}`", *Array(valueList.size){ i-> valueList[i]})
+//                    .whereArgs(clause, *Array(whereArgs.size){i-> whereArgs[i]}).exec()
+//        }
+//        return true
+//    } // Function update()
+
+
+
 
     /**
      * 根据条件查询记录
@@ -475,7 +491,7 @@ abstract class SAndroidDao<ENTITY: Any>(entityClazz: Class<ENTITY>) : SAbstractD
      * @param   idList      对象ID列表
      * @return  关系列表
      */
-    override fun relationQuery(table: String, id1: String, id2: String, self: Boolean, idList: ArrayList<Any>): ArrayList<HashMap<String, Any>> {
-        return ArrayList<HashMap<String, Any>>();
-    } // Function cascadeIdList()
+//    override fun relationQuery(table: String, id1: String, id2: String, self: Boolean, idList: ArrayList<Any>): ArrayList<HashMap<String, Any>> {
+//        return ArrayList<HashMap<String, Any>>();
+//    } // Function cascadeIdList()
 } // Class SAndroidDao

+ 3 - 3
sybotan-android-devices/build.gradle

@@ -38,8 +38,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
 
@@ -136,7 +136,7 @@ uploadArchives {
             pom.project {
                 name project.name
                 packaging 'jar'
-                url SYBOTAN_URL
+                url SAGA_URL
                 description '斯伯坦机器人世界 android 设备支持库。'
                 licenses {
                     license {

+ 4 - 4
sybotan-android-graphy/build.gradle

@@ -39,8 +39,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
 
@@ -86,7 +86,7 @@ dependencies {
 
     ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
     // Sybotan依赖
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-base', version: SYBOTAN_KOTLIN_VERSION
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-base', version: SAGA_KOTLIN_VERSION
     implementation project(':sybotan-android-base')
 }
 
@@ -135,7 +135,7 @@ uploadArchives {
             pom.project {
                 name project.name
                 packaging 'jar'
-                url SYBOTAN_URL
+                url SAGA_URL
                 description '斯伯坦机器人世界 android Graphy框架库。'
                 licenses {
                     license {

+ 5 - 5
sybotan-android-views/build.gradle

@@ -39,8 +39,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
 
@@ -99,8 +99,8 @@ dependencies {
     implementation group: 'com.google.zxing', name: 'android-core', version: ZXING_VERSION
 
     ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-    // Sybotan依赖
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-base', version: SYBOTAN_KOTLIN_VERSION
+    // SAGA依赖
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-base', version: SAGA_KOTLIN_VERSION
     implementation project(':sybotan-android-base')
 
 }
@@ -150,7 +150,7 @@ uploadArchives {
             pom.project {
                 name project.name
                 packaging 'jar'
-                url SYBOTAN_URL
+                url SAGA_URL
                 description '斯伯坦机器人世界 android view组件库。'
                 licenses {
                     license {

+ 5 - 5
sybotan-android-works/build.gradle

@@ -39,8 +39,8 @@ android {
     defaultConfig {
         minSdkVersion ANDROID_MIN_SDK_VERSION.toInteger()
         targetSdkVersion ANDROID_SDK_VERSION.toInteger()
-        versionCode SYBOTAN_CODE.toInteger()
-        versionName SYBOTAN_ANDROID_VERSION
+        versionCode SAGA_CODE.toInteger()
+        versionName SAGA_ANDROID_VERSION
 
         testInstrumentationRunner 'android.support.test.runner.AndroidJUnitRunner'
 
@@ -99,8 +99,8 @@ dependencies {
     implementation group: 'com.google.zxing', name: 'android-core', version: ZXING_VERSION
 
     ////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
-    // Sybotan依赖
-    implementation group: 'com.sybotan', name: 'sybotan-kotlin-base', version: SYBOTAN_KOTLIN_VERSION
+    // SAGA依赖
+    implementation group: 'cn.sagacloud', name: 'saga-kotlin-base', version: SAGA_KOTLIN_VERSION
     implementation project(':sybotan-android-base')
     implementation project(':sybotan-android-views')
 }
@@ -150,7 +150,7 @@ uploadArchives {
             pom.project {
                 name project.name
                 packaging 'jar'
-                url SYBOTAN_URL
+                url SAGA_URL
                 description '斯伯坦机器人世界 android works组件库。'
                 licenses {
                     license {