add project adins

This commit is contained in:
Alfrid Sanjaya Leo Putra 2024-07-25 14:44:22 +07:00
commit f8f85d679d
5299 changed files with 625430 additions and 0 deletions

View file

@ -0,0 +1,159 @@
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
android {
lintOptions {
disable 'MissingTranslation'
checkReleaseBuilds false
}
// change with your msmkey storeFile
signingConfigs {
msmkey {
keyAlias 'aitmsskey'
keyPassword 'AdIns2020'
storeFile file('keystore2020.jks')
storePassword 'AdIns2020'
}
}
compileSdkVersion 30
buildToolsVersion '29.0.2'
defaultConfig {
applicationId "com.adins.mss.coll.baf"
minSdkVersion 19
targetSdkVersion 30
versionCode 7910
versionName "3.3.0.1-$versionCode"
multiDexEnabled true
useLibrary 'org.apache.http.legacy'
archivesBaseName = "MSSCOLL-$versionName"
vectorDrawables.useSupportLibrary = true
ndk.abiFilters 'armeabi-v7a','arm64-v8a','x86','x86_64'
}
dexOptions {
javaMaxHeapSize "5g"
}
dataBinding {
enabled = true
}
buildTypes {
release {
shrinkResources false
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.msmkey
}
debug {
minifyEnabled false
shrinkResources false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions{
exclude 'META-INF/proguard/androidx-annotations.pro'
}
flavorDimensions "default"
productFlavors {
developer {
applicationId "com.adins.mss.coll.baf.dev"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-D"
buildConfigField "boolean", "IS_DEV", "true"
buildConfigField "boolean", "IS_DBENCRYPT", "false"
buildConfigField "boolean", "IS_BYPASSROOT", "true"
buildConfigField "String", "IS_FLAVORS", "\"DEVELOPER\""
}
product {
applicationId "com.adins.mss.coll.baf"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-P"
buildConfigField "boolean", "IS_DEV", "false"
buildConfigField "boolean", "IS_DBENCRYPT", "true"
buildConfigField "boolean", "IS_BYPASSROOT", "false"
buildConfigField "String", "IS_FLAVORS", "\"PRODUCT\""
}
uat {
applicationId "com.adins.mss.coll.baf.uat"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-U"
buildConfigField "boolean", "IS_DEV", "false"
buildConfigField "boolean", "IS_DBENCRYPT", "true"
buildConfigField "boolean", "IS_BYPASSROOT", "false"
buildConfigField "String", "IS_FLAVORS", "\"UAT\""
}
trial {
applicationId "com.adins.mss.coll.baf.trial"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-P"
buildConfigField "boolean", "IS_DEV", "false"
buildConfigField "boolean", "IS_DBENCRYPT", "true"
buildConfigField "boolean", "IS_BYPASSROOT", "false"
buildConfigField "String", "IS_FLAVORS", "\"TRIAL\""
}
cloud {
applicationId "com.adins.mss.coll.baf.cloud"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-P"
buildConfigField "boolean", "IS_DEV", "false"
buildConfigField "boolean", "IS_DBENCRYPT", "true"
buildConfigField "boolean", "IS_BYPASSROOT", "false"
buildConfigField "String", "IS_FLAVORS", "\"PRODUCT\""
}
clouddev {
applicationId "com.adins.mss.coll.baf.cloud.dev"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-D"
buildConfigField "boolean", "IS_DEV", "true"
buildConfigField "boolean", "IS_DBENCRYPT", "false"
buildConfigField "boolean", "IS_BYPASSROOT", "true"
buildConfigField "String", "IS_FLAVORS", "\"DEVELOPER\""
}
cloudtrial {
applicationId "com.adins.mss.coll.baf.cloud.trial"
versionCode 7910
dimension "default"
versionName "3.3.0.1-$versionCode-P"
buildConfigField "boolean", "IS_DEV", "false"
buildConfigField "boolean", "IS_DBENCRYPT", "true"
buildConfigField "boolean", "IS_BYPASSROOT", "false"
buildConfigField "String", "IS_FLAVORS", "\"TRIAL\""
}
}
}
dependencies {
implementation project(':mssbase')
implementation 'androidx.appcompat:appcompat:1.0.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'com.google.firebase:firebase-messaging:20.2.4'
implementation 'com.google.firebase:firebase-core:17.5.0'
implementation 'com.google.firebase:firebase-analytics:17.5.0'
implementation 'com.google.firebase:firebase-perf:19.1.1'
implementation 'com.google.firebase:firebase-crashlytics:17.2.1'
implementation 'com.github.vihtarb:tooltip:0.2.0'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'com.github.PhilJay:MPAndroidChart:v3.1.0'
testImplementation 'junit:junit:4.12'
implementation 'com.google.android.material:material:1.2.1'
implementation 'com.github.chrisbanes:PhotoView:2.3.0'
}
//dependencies {
// debugimplementation 'com.squareup.leakcanary:leakcanary-android:1.5.1'
// releaseimplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
// testimplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.1'
//}
apply plugin: 'com.google.firebase.firebase-perf'
apply plugin: 'com.google.gms.google-services'
apply plugin: 'com.google.firebase.crashlytics'
apply plugin: 'kotlin-android-extensions'

View file

@ -0,0 +1,88 @@
package com.adins.mss.coll.adapters;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import com.adins.mss.coll.items.ClosingTaskItem;
import com.adins.mss.coll.networks.entities.ClosingTaskEntity;
import java.util.List;
/**
* Created by angga.permadi on 6/6/2016.
*/
public class ClosingTaskAdapter extends BaseAdapter {
private static ClosingTaskAdapter instance;
private List<ClosingTaskEntity> entities;
public ClosingTaskAdapter() {
}
public static ClosingTaskAdapter getInstance() {
if (instance == null) {
instance = new ClosingTaskAdapter();
}
return instance;
}
@Override
public int getCount() {
if (entities == null) return 0;
return entities.size();
}
@Override
public ClosingTaskEntity getItem(int position) {
if (entities == null) return null;
return entities.get(position);
}
@Override
public long getItemId(int position) {
return position;
}
@Override
public View getView(int position, View convertView, ViewGroup parent) {
ClosingTaskItem item;
if (convertView == null) {
item = new ClosingTaskItem(parent.getContext());
} else {
item = (ClosingTaskItem) convertView;
}
item.bind(getItem(position));
return item;
}
public void clear() {
if (entities != null) {
entities.clear();
}
}
public void processData(List<ClosingTaskEntity> ts) {
if (ts == null || ts.size() <= 0) return;
if (entities == null) {
entities = ts;
} else {
entities.addAll(ts);
}
notifyDataSetChanged();
}
public void releaseResources() {
clear();
notifyDataSetChanged();
entities = null;
instance = null;
}
}

View file

@ -0,0 +1,23 @@
package com.services;
import com.adins.mss.base.GlobalData;
import com.adins.mss.foundation.http.MssRequestType;
import com.google.gson.annotations.SerializedName;
public class JsonRequestRefreshTask extends MssRequestType {
@SerializedName("dtm_crt")
private long dtm_crt;
public JsonRequestRefreshTask(long dtm_crt) {
setAudit(GlobalData.getSharedGlobalData().getAuditData());
setDtm_crt(dtm_crt);
}
public long getDtm_crt() {
return dtm_crt;
}
public void setDtm_crt(long dtm_crt) {
this.dtm_crt = dtm_crt;
}
}

View file

@ -0,0 +1,52 @@
package com.adins.mss.svy.models;
import com.adins.mss.foundation.http.MssRequestType;
import com.google.gson.annotations.SerializedName;
import java.util.Date;
/**
* Created by Aditya Purwa on 1/28/2015.
*/
public class SurveyorSearchRequest extends MssRequestType {
@SerializedName("date1")
private Date date1;
@SerializedName("date2")
private Date date2;
@SerializedName("month")
private String month;
@SerializedName("year")
private String year;
public String getYear() {
return year;
}
public void setYear(String year) {
this.year = year;
}
public Date getDate1() {
return date1;
}
public void setDate1(Date date1) {
this.date1 = date1;
}
public Date getDate2() {
return date2;
}
public void setDate2(Date date2) {
this.date2 = date2;
}
public String getMonth() {
return month;
}
public void setMonth(String month) {
this.month = month;
}
}

View file

@ -0,0 +1,67 @@
package com.adins.mss.base.dynamicform.form.resolver;
import com.adins.mss.constant.Global;
import com.gadberry.utility.CalendarUtils;
import com.gadberry.utility.expression.Resolver;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
/**
* Created by gigin.ginanjar on 15/09/2016.
*/
public class DateResolver implements Resolver {
private SimpleDateFormat sdf = new SimpleDateFormat(Global.DATE_STR_FORMAT);
@Override
public boolean canResolve(String path) {
return resolve(path) != null || path.equals("NULL");
}
private Date getDate(String path) {
try {
return sdf.parse(path);
} catch (ParseException e) {
}
return null;
}
private CalendarUtils.Unit getDateUnit(String path) {
if (path.equals("|YEAR|")) {
return CalendarUtils.Unit.YEAR;
} else if (path.equals("|MONTH|")) {
return CalendarUtils.Unit.MONTH;
} else if (path.equals("|DAY|")) {
return CalendarUtils.Unit.DAY;
} else if (path.equals("|HOUR|")) {
return CalendarUtils.Unit.HOUR;
} else if (path.equals("|MINUTE|")) {
return CalendarUtils.Unit.MINUTE;
} else if (path.equals("|SECOND|")) {
return CalendarUtils.Unit.SECOND;
} else if (path.equals("|MILLISECOND|")) {
return CalendarUtils.Unit.MILLISECOND;
}
return null;
}
private boolean isDate(String path) {
return getDate(path) != null;
}
private boolean isDateUnit(String path) {
return getDateUnit(path) != null;
}
@Override
public Object resolve(String path) {
if (isDate(path)) {
return getDate(path);
} else if (isDateUnit(path)) {
return getDateUnit(path);
}
return null;
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 707 B