mirror of
https://github.com/freeedcom/ai-codereviewer.git
synced 2025-06-30 21:04:16 +00:00
add project adins
This commit is contained in:
parent
ad06ac5505
commit
f8f85d679d
5299 changed files with 625430 additions and 0 deletions
|
@ -0,0 +1,202 @@
|
|||
package com.adins.mss.base.personalization;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.crashlytics.FireCrash;
|
||||
import com.adins.mss.dao.User;
|
||||
import com.adins.mss.foundation.db.dataaccess.UserDataAccess;
|
||||
import com.adins.mss.foundation.http.HttpConnectionResult;
|
||||
import com.adins.mss.foundation.http.HttpCryptedConnection;
|
||||
|
||||
/**
|
||||
* Helper class which help to pick picture from gallery or camera to apply as profile photo or cover photo. This class
|
||||
* pick a picture from user chosen application for camera or gallery, and save the picture to user database
|
||||
*
|
||||
* @author glen.iglesias
|
||||
*/
|
||||
public class Personalization {
|
||||
|
||||
// public static final int TYPE_PROF_PICT = 1;
|
||||
// public static final int TYPE_COVER_PICT = 2;
|
||||
|
||||
public static final String FAILED_SIZE_LIMIT = "Image size exceeded maximum allowed limit";
|
||||
public static final String FAILED_CONNECTION = "Connection to server failed";
|
||||
public Personalization() {
|
||||
}
|
||||
|
||||
/**
|
||||
* Method to update photo, including cropping image, store to database, and, on upcoming version, send to server.
|
||||
* <br>Method will call PersonalizationHandler on success or fail
|
||||
*
|
||||
* @param context
|
||||
* @param image
|
||||
* @param imageType type of image to be updated, either profile picture or cover picture
|
||||
* @param handler a PersonalizationHandler to whom updatePhoto will call on success or failure
|
||||
*/
|
||||
public static void updatePhoto(Context context, byte[] image, ImageType imageType, PersonalizationHandler handler) {
|
||||
//TODO use cropping function
|
||||
byte[] croppedImage = image;
|
||||
int sizeLimit = GlobalData.getSharedGlobalData().getMaxPhotoSize();
|
||||
if (croppedImage.length > sizeLimit) {
|
||||
handler.onExceedSizeLimit(croppedImage, imageType, sizeLimit);
|
||||
} else {
|
||||
//process picture
|
||||
savePicture(context, croppedImage, imageType);
|
||||
//no need to send picture to server yet
|
||||
handler.onUpdateSuccess(croppedImage, imageType);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Save image to database and update current user data. Use updatePhoto() for more complete implementation like cropping and sending to server
|
||||
*
|
||||
* @param context
|
||||
* @param image
|
||||
* @param imageType type of image to be updated, either profile picture or cover picture
|
||||
*/
|
||||
public static void savePicture(Context context, byte[] image, ImageType imageType) {
|
||||
User currentActiveUser = GlobalData.getSharedGlobalData().getUser();
|
||||
if (imageType == ImageType.TYPE_PROF_PICT) {
|
||||
currentActiveUser.setImage_profile(image);
|
||||
} else {
|
||||
currentActiveUser.setImage_cover(image);
|
||||
}
|
||||
UserDataAccess.update(context, currentActiveUser);
|
||||
}
|
||||
|
||||
/**
|
||||
* A method to update profile picture by uploading it to server
|
||||
*
|
||||
* @param context
|
||||
* @param profPicture
|
||||
* @throws Exception
|
||||
* @deprecated use updatePhoto() instead
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
private static Object changeProfilePicture(Context context, byte[] profPicture) throws Exception {
|
||||
// TODO
|
||||
//crop to fit
|
||||
byte[] croppedImage = profPicture;
|
||||
// //save to GlobalData and DB
|
||||
// User currentActiveUser = GlobalData.getSharedGlobalData().getUser();
|
||||
// currentActiveUser.setImage_profile(croppedImage);
|
||||
// UserDataAccess.update(context, currentActiveUser);
|
||||
|
||||
//send to server
|
||||
sendPicture(context, croppedImage, ImageType.TYPE_PROF_PICT);
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* A method to update cover picture by uploading it to server
|
||||
*
|
||||
* @param context
|
||||
* @param coverPicture
|
||||
* @return
|
||||
* @deprecated use updatePhoto() instead, hide by changing access to private only
|
||||
*/
|
||||
@SuppressWarnings("unused")
|
||||
private static Object changeCoverPicture(Context context, byte[] coverPicture) {
|
||||
// TODO
|
||||
//crop to fit
|
||||
byte[] croppedImage = coverPicture;
|
||||
// //save to GlobalData and DB
|
||||
// User currentActiveUser = GlobalData.getSharedGlobalData().getUser();
|
||||
// currentActiveUser.setImage_profile(croppedImage);
|
||||
// UserDataAccess.update(context, currentActiveUser);
|
||||
|
||||
//send to server
|
||||
sendPicture(context, croppedImage, ImageType.TYPE_PROF_PICT);
|
||||
return false;
|
||||
}
|
||||
|
||||
//=== Deprecated or Unpublished ===//
|
||||
|
||||
/**
|
||||
* Method upload picture to server
|
||||
*
|
||||
* @param image
|
||||
* @param imageType
|
||||
* @return
|
||||
* @deprecated MSS save profile picture only on local device
|
||||
*/
|
||||
private static Object sendPicture(Context context, byte[] image, ImageType imageType) {
|
||||
String url = "";
|
||||
|
||||
// TODO
|
||||
switch (imageType) {
|
||||
case TYPE_COVER_PICT:
|
||||
url = GlobalData.getSharedGlobalData().getUrlPersonalization();
|
||||
;
|
||||
break;
|
||||
case TYPE_PROF_PICT:
|
||||
url = GlobalData.getSharedGlobalData().getUrlPersonalization();
|
||||
;
|
||||
break;
|
||||
default:
|
||||
url = "";
|
||||
break;
|
||||
}
|
||||
|
||||
boolean encrypt = GlobalData.getSharedGlobalData().isEncrypt();
|
||||
boolean decrypt = GlobalData.getSharedGlobalData().isDecrypt();
|
||||
HttpCryptedConnection httpConn = new HttpCryptedConnection(context, encrypt, decrypt);
|
||||
|
||||
HttpConnectionResult result = null;
|
||||
try {
|
||||
result = httpConn.requestToServer(url, "");
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
if (result != null) {
|
||||
//TODO
|
||||
if (result.isOK()) {
|
||||
//save to DB
|
||||
|
||||
if (imageType == ImageType.TYPE_PROF_PICT) {
|
||||
|
||||
}
|
||||
} else {
|
||||
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public enum ImageType {
|
||||
TYPE_PROF_PICT,
|
||||
TYPE_COVER_PICT
|
||||
}
|
||||
|
||||
public interface PersonalizationHandler {
|
||||
/**
|
||||
* Called when update is successful
|
||||
*
|
||||
* @param image image which was successfully updated
|
||||
* @param imageType image type of updated image
|
||||
*/
|
||||
public void onUpdateSuccess(byte[] image, ImageType imageType);
|
||||
|
||||
/**
|
||||
* Called when update failed because of exceeded size limit
|
||||
*
|
||||
* @param image image which update is requested and failed
|
||||
* @param sizeLimit size limit which was exceeded
|
||||
* @param imageType image type of updated image
|
||||
*/
|
||||
public void onExceedSizeLimit(byte[] image, ImageType imageType, int sizeLimit);
|
||||
|
||||
//TODO check on login or other place, if HttpConnectionResult is the correct type to return
|
||||
// /**
|
||||
// * Called when update failed because of connection failure
|
||||
// * @param image image which update is requested and failed
|
||||
// * @param failedResult HttpConnectionResult of failed connection attempt
|
||||
// * @param imageType image type of updated image
|
||||
// */
|
||||
// public void onConnetionFailed(byte[] image, ImageType imageType, HttpConnectionResult failedResult);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,235 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.adins.mss.svy"
|
||||
android:installLocation="internalOnly">
|
||||
|
||||
<!--<uses-permission android:name="android.permission.RECORD_AUDIO" />-->
|
||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<uses-permission android:name="android.permission.CAMERA" />
|
||||
|
||||
<uses-feature android:name="android.hardware.camera.autofocus" />
|
||||
<uses-feature android:name="android.hardware.camera" />
|
||||
<uses-feature
|
||||
android:name="android.hardware.camera.front"
|
||||
android:required="false" />
|
||||
<uses-feature
|
||||
android:name="android.hardware.camera.flash"
|
||||
android:required="false" />
|
||||
|
||||
<uses-permission android:name="android.permission.VIBRATE" />
|
||||
<uses-permission android:name="android.permission.FLASHLIGHT" />
|
||||
<uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" /> <!-- External storage for caching. -->
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.READ_PHONE_STATE" /> <!-- My Location -->
|
||||
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
|
||||
<uses-permission android:name="android.permission.ACCESS_BACKGROUND_LOCATION" />
|
||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
||||
<uses-permission android:name="android.permission.BLUETOOTH" />
|
||||
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" />
|
||||
<uses-permission android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS" /> <!-- <uses-permission android:name="android.permission.CALL_PHONE" /> -->
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" /> <!-- Maps API needs OpenGL ES 2.0. -->
|
||||
<uses-feature
|
||||
android:glEsVersion="0x00020000"
|
||||
android:required="true" />
|
||||
|
||||
<application
|
||||
android:name="com.adins.mss.main.MSMApplication"
|
||||
android:allowBackup="false"
|
||||
android:fullBackupContent="false"
|
||||
android:icon="@drawable/icon_launcher_check_id"
|
||||
android:label="@string/app_name"
|
||||
android:logo="@drawable/logo_mss"
|
||||
android:supportsRtl="true"
|
||||
android:theme="@style/CustomTheme"
|
||||
android:usesCleartextTraffic="true">
|
||||
<receiver
|
||||
android:name="com.services.RestartAutoSendLocationReceiver"
|
||||
android:enabled="true"
|
||||
android:exported="false">
|
||||
|
||||
<intent-filter>
|
||||
<action android:name="com.adins.intent.action_RESTART_AUTOSEND_LOCATION" />
|
||||
</intent-filter>
|
||||
</receiver>
|
||||
|
||||
<service
|
||||
android:name="com.services.MSLocationTrackingService"
|
||||
android:foregroundServiceType="location"
|
||||
android:enabled="true"
|
||||
android:exported="false" />
|
||||
|
||||
<receiver android:name="com.services.MSLocationTrackingService$UserLogoutReceiver">
|
||||
<intent-filter>
|
||||
<action android:name="com.adins.mss.action_USER_LOGOUT" />
|
||||
</intent-filter>
|
||||
</receiver>
|
||||
|
||||
<activity
|
||||
android:name=".MSLoginActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:excludeFromRecents="true"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/CustomTheme">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
<activity
|
||||
android:name=".NewMSMainActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:label="@string/app_name"
|
||||
android:launchMode="singleTask"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/CustomTheme" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.ServerLinkActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:label="@string/title_server_link"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/CustomTheme" />
|
||||
<activity
|
||||
android:name=".MSSynchronizeActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:label="@string/app_name"
|
||||
android:theme="@style/CustomTheme" />
|
||||
<activity
|
||||
android:name=".MSMainMenuActivity"
|
||||
android:configChanges="locale|orientation|screenSize"
|
||||
android:exported="false"
|
||||
android:launchMode="singleTop"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/CustomTheme.TranslucentActionBar" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.dynamicform.VoiceNotePage"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:excludeFromRecents="true"
|
||||
android:screenOrientation="portrait" />
|
||||
<activity
|
||||
android:name="com.adins.mss.foundation.image.ViewImageActivity"
|
||||
android:launchMode="singleTop" />
|
||||
<activity android:name="com.soundcloud.android.crop.CropImageActivity" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.timeline.comment.activity.CommentActivity"
|
||||
android:launchMode="singleTop" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.dynamicform.DynamicFormActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:parentActivityName=".NewMSMainActivity"
|
||||
android:screenOrientation="portrait">
|
||||
<meta-data
|
||||
android:name="android.support.PARENT_ACTIVITY"
|
||||
android:value=".NewMSMainActivity" />
|
||||
</activity>
|
||||
<activity
|
||||
android:name="com.adins.mss.base.dynamicform.SendResultActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:launchMode="singleTop" />
|
||||
<activity
|
||||
android:name=".reassignment.OrderReassignmentResult"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:launchMode="singleTop" />
|
||||
<activity
|
||||
android:name=".assignment.LookupAssignment"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:launchMode="singleTop" />
|
||||
<activity
|
||||
android:name=".assignment.OrderAssignmentResult"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:launchMode="singleTop"
|
||||
android:windowSoftInputMode="adjustResize" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.timeline.MapsViewer"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:launchMode="singleTop" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.ChangePasswordActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:launchMode="singleTop" />
|
||||
<activity
|
||||
android:name="com.adins.mss.foundation.image.CroppingImageActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize" />
|
||||
<activity android:name="com.adins.mss.base.PrintActivity" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.todolist.form.ViewMapActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize" />
|
||||
<activity
|
||||
android:name="com.adins.mss.foundation.questiongenerator.form.LocationTagingView"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize" />
|
||||
<activity
|
||||
android:name="com.adins.mss.foundation.questiongenerator.form.FingerDrawingActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.todolist.form.AllHeaderViewerActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize" />
|
||||
<activity
|
||||
android:name="com.adins.mss.foundation.camera2.Camera2BasicRealActivity"
|
||||
android:launchMode="singleTop"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/AppTheme.NoTitle" />
|
||||
|
||||
<meta-data
|
||||
android:name="com.google.android.maps.v2.API_KEY"
|
||||
android:value="AIzaSyA2V50uQBKw5_w2f3BEEbcNkmwofZyt-Io" /> <!-- android:value="AIzaSyDEK_F1pp8MEVvkCLtVs4R9spdm_JColds" /> -->
|
||||
<!-- android:value="AIzaSyDbW6WbmyOF7-QtIPPja1xFT6VNvpBNEC0" /> -->
|
||||
<meta-data
|
||||
android:name="com.google.android.gms.version"
|
||||
android:value="@integer/google_play_services_version" />
|
||||
<meta-data
|
||||
android:name="firebase_crashlytics_collection_enabled"
|
||||
android:value="false" />
|
||||
|
||||
<service android:name="com.tracking.LocationTrackingService" />
|
||||
<service android:name="com.services.AutoSendImageService" />
|
||||
<service android:name="com.services.AutoSendTaskService" />
|
||||
<service android:name="com.services.NotificationService" />
|
||||
<service android:name="com.services.SurveyVerificationService" />
|
||||
<service android:name="com.services.SurveyApprovalService" />
|
||||
|
||||
<activity
|
||||
android:name=".SurveyVerificationActionActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:label="@string/title_activity_survey_verification_action" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.DeveloperOptionActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize"
|
||||
android:label="@string/title_developer_option"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/CustomTheme" />
|
||||
<activity
|
||||
android:name="com.adins.mss.base.mainmenu.settings.SettingActivity"
|
||||
android:configChanges="orientation|keyboard|keyboardHidden|screenSize" />
|
||||
<activity
|
||||
android:name="com.adins.mss.foundation.camerainapp.CameraActivity"
|
||||
android:launchMode="singleTop"
|
||||
android:screenOrientation="portrait"
|
||||
android:theme="@style/AppTheme.NoTitle" />
|
||||
|
||||
<service android:name="com.services.FirebaseMessagingService">
|
||||
<intent-filter>
|
||||
<action android:name="com.google.firebase.MESSAGING_EVENT" />
|
||||
</intent-filter>
|
||||
</service>
|
||||
<service android:name="com.services.RefreshToken">
|
||||
<intent-filter>
|
||||
<action android:name="com.google.firebase.INSTANCE_ID_EVENT" />
|
||||
</intent-filter>
|
||||
</service>
|
||||
|
||||
<uses-library
|
||||
android:name="org.apache.http.legacy"
|
||||
android:required="false" />
|
||||
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="${applicationId}.provider"
|
||||
android:exported="false"
|
||||
android:grantUriPermissions="true">
|
||||
<meta-data
|
||||
android:name="android.support.FILE_PROVIDER_PATHS"
|
||||
android:resource="@xml/provider_paths" />
|
||||
</provider>
|
||||
</application>
|
||||
|
||||
</manifest>
|
|
@ -0,0 +1,74 @@
|
|||
package com.adins.mss.coll.api;
|
||||
|
||||
import android.content.Context;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.crashlytics.FireCrash;
|
||||
import com.adins.mss.base.util.GsonHelper;
|
||||
import com.adins.mss.base.util.Utility;
|
||||
import com.adins.mss.coll.models.DepositReportReconcileRequest;
|
||||
import com.adins.mss.coll.models.DepositReportReconcileResponse;
|
||||
import com.adins.mss.constant.Global;
|
||||
import com.adins.mss.foundation.http.HttpConnectionResult;
|
||||
import com.adins.mss.foundation.http.HttpCryptedConnection;
|
||||
import com.google.firebase.perf.FirebasePerformance;
|
||||
import com.google.firebase.perf.metrics.HttpMetric;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by dian.ina on 02/09/2015.
|
||||
*/
|
||||
public class DepositReportReconcileApi {
|
||||
private final Context context;
|
||||
|
||||
public DepositReportReconcileApi(Context context) {
|
||||
this.context = context;
|
||||
}
|
||||
|
||||
public DepositReportReconcileResponse request(List<String> taskId, List<String> flag) throws IOException {
|
||||
DepositReportReconcileRequest request = new DepositReportReconcileRequest();
|
||||
request.setTaskId(taskId);
|
||||
request.setFlag(flag);
|
||||
request.setAudit(GlobalData.getSharedGlobalData().getAuditData());
|
||||
|
||||
String requestJson = GsonHelper.toJson(request);
|
||||
|
||||
// HttpClient client = new HttpClient(context);
|
||||
String url = GlobalData.getSharedGlobalData().getURL_GET_RECAPITULATE();
|
||||
// Request httpRequest = client.request(url)
|
||||
// .post(RequestBody.create(MediaType.parse("application/json"), requestJson))
|
||||
// .build();
|
||||
//
|
||||
// Response response = client.execute(httpRequest);
|
||||
boolean encrypt = GlobalData.getSharedGlobalData().isEncrypt();
|
||||
boolean decrypt = GlobalData.getSharedGlobalData().isDecrypt();
|
||||
HttpCryptedConnection httpConn = new HttpCryptedConnection(context, encrypt, decrypt);
|
||||
HttpConnectionResult serverResult = null;
|
||||
|
||||
//Firebase Performance Trace HTTP Request
|
||||
HttpMetric networkMetric =
|
||||
FirebasePerformance.getInstance().newHttpMetric(url, FirebasePerformance.HttpMethod.POST);
|
||||
Utility.metricStart(networkMetric, requestJson);
|
||||
|
||||
try {
|
||||
serverResult = httpConn.requestToServer(url, requestJson, Global.DEFAULTCONNECTIONTIMEOUT);
|
||||
Utility.metricStop(networkMetric, serverResult);
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
}
|
||||
String responseJson ="" ;
|
||||
if(serverResult!=null && serverResult.isOK()){
|
||||
try {
|
||||
responseJson = serverResult.getResult();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e); }
|
||||
}
|
||||
//String responseJson = "{\"taskId\":[\"COL150000243\"],\"status\":{\"code\":0}}";
|
||||
DepositReportReconcileResponse reconcileResponse = GsonHelper.fromJson(responseJson, DepositReportReconcileResponse.class);
|
||||
|
||||
return reconcileResponse;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,25 @@
|
|||
package com.adins.mss.foundation.UserHelp.Bean.Dummy;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class UserHelpViewDummy {
|
||||
private String viewid;
|
||||
private List<UserHelpIconDummy> iconid;
|
||||
|
||||
public String getViewid() {
|
||||
return viewid;
|
||||
}
|
||||
|
||||
public void setViewid(String viewid) {
|
||||
this.viewid = viewid;
|
||||
}
|
||||
|
||||
public List<UserHelpIconDummy> getIconid() {
|
||||
return iconid;
|
||||
}
|
||||
|
||||
public void setIconid(List<UserHelpIconDummy> iconid) {
|
||||
this.iconid = iconid;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,141 @@
|
|||
package com.adins.mss.dao;
|
||||
|
||||
import com.adins.mss.dao.DaoSession;
|
||||
import de.greenrobot.dao.DaoException;
|
||||
|
||||
import com.adins.mss.base.util.ExcludeFromGson;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT. Enable "keep" sections if you want to edit.
|
||||
/**
|
||||
* Entity mapped to table "TR_THEME_ITEM".
|
||||
*/
|
||||
public class ThemeItem {
|
||||
|
||||
/** Not-null value. */
|
||||
@SerializedName("uuid_theme_item")
|
||||
private String uuid_theme_item;
|
||||
/** Not-null value. */
|
||||
@SerializedName("theme_item")
|
||||
private String theme_item;
|
||||
@SerializedName("value")
|
||||
private String value;
|
||||
@SerializedName("uuid_theme")
|
||||
private String uuid_theme;
|
||||
|
||||
/** Used to resolve relations */
|
||||
private transient DaoSession daoSession;
|
||||
|
||||
/** Used for active entity operations. */
|
||||
private transient ThemeItemDao myDao;
|
||||
|
||||
private Theme theme;
|
||||
private String theme__resolvedKey;
|
||||
|
||||
|
||||
public ThemeItem() {
|
||||
}
|
||||
|
||||
public ThemeItem(String uuid_theme_item) {
|
||||
this.uuid_theme_item = uuid_theme_item;
|
||||
}
|
||||
|
||||
public ThemeItem(String uuid_theme_item, String theme_item, String value, String uuid_theme) {
|
||||
this.uuid_theme_item = uuid_theme_item;
|
||||
this.theme_item = theme_item;
|
||||
this.value = value;
|
||||
this.uuid_theme = uuid_theme;
|
||||
}
|
||||
|
||||
/** called by internal mechanisms, do not call yourself. */
|
||||
public void __setDaoSession(DaoSession daoSession) {
|
||||
this.daoSession = daoSession;
|
||||
myDao = daoSession != null ? daoSession.getThemeItemDao() : null;
|
||||
}
|
||||
|
||||
/** Not-null value. */
|
||||
public String getUuid_theme_item() {
|
||||
return uuid_theme_item;
|
||||
}
|
||||
|
||||
/** Not-null value; ensure this value is available before it is saved to the database. */
|
||||
public void setUuid_theme_item(String uuid_theme_item) {
|
||||
this.uuid_theme_item = uuid_theme_item;
|
||||
}
|
||||
|
||||
/** Not-null value. */
|
||||
public String getTheme_item() {
|
||||
return theme_item;
|
||||
}
|
||||
|
||||
/** Not-null value; ensure this value is available before it is saved to the database. */
|
||||
public void setTheme_item(String theme_item) {
|
||||
this.theme_item = theme_item;
|
||||
}
|
||||
|
||||
public String getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
public void setValue(String value) {
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
public String getUuid_theme() {
|
||||
return uuid_theme;
|
||||
}
|
||||
|
||||
public void setUuid_theme(String uuid_theme) {
|
||||
this.uuid_theme = uuid_theme;
|
||||
}
|
||||
|
||||
/** To-one relationship, resolved on first access. */
|
||||
public Theme getTheme() {
|
||||
String __key = this.uuid_theme;
|
||||
if (theme__resolvedKey == null || theme__resolvedKey != __key) {
|
||||
if (daoSession == null) {
|
||||
throw new DaoException("Entity is detached from DAO context");
|
||||
}
|
||||
ThemeDao targetDao = daoSession.getThemeDao();
|
||||
Theme themeNew = targetDao.load(__key);
|
||||
synchronized (this) {
|
||||
theme = themeNew;
|
||||
theme__resolvedKey = __key;
|
||||
}
|
||||
}
|
||||
return theme;
|
||||
}
|
||||
|
||||
public void setTheme(Theme theme) {
|
||||
synchronized (this) {
|
||||
this.theme = theme;
|
||||
uuid_theme = theme == null ? null : theme.getUuid_theme();
|
||||
theme__resolvedKey = uuid_theme;
|
||||
}
|
||||
}
|
||||
|
||||
/** Convenient call for {@link AbstractDao#delete(Object)}. Entity must attached to an entity context. */
|
||||
public void delete() {
|
||||
if (myDao == null) {
|
||||
throw new DaoException("Entity is detached from DAO context");
|
||||
}
|
||||
myDao.delete(this);
|
||||
}
|
||||
|
||||
/** Convenient call for {@link AbstractDao#update(Object)}. Entity must attached to an entity context. */
|
||||
public void update() {
|
||||
if (myDao == null) {
|
||||
throw new DaoException("Entity is detached from DAO context");
|
||||
}
|
||||
myDao.update(this);
|
||||
}
|
||||
|
||||
/** Convenient call for {@link AbstractDao#refresh(Object)}. Entity must attached to an entity context. */
|
||||
public void refresh() {
|
||||
if (myDao == null) {
|
||||
throw new DaoException("Entity is detached from DAO context");
|
||||
}
|
||||
myDao.refresh(this);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,143 @@
|
|||
{
|
||||
"project_info": {
|
||||
"project_number": "704968583093",
|
||||
"project_id": "bafmcs-v3",
|
||||
"storage_bucket": "bafmcs-v3.appspot.com"
|
||||
},
|
||||
"client": [
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:b6d5a55c6d0b9516b0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:88edd1524719ca55b0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf.cloud"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:40ba1109f2857f8ab0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf.cloud.dev"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:a086889bc73ff0f3b0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf.cloud.trial"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:abffaf68794a4afeb0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf.dev"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:342ce6d0298a653fb0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf.trial"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"client_info": {
|
||||
"mobilesdk_app_id": "1:704968583093:android:4c7ee739daa1cebeb0dbfc",
|
||||
"android_client_info": {
|
||||
"package_name": "com.adins.mss.coll.baf.uat"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyBtlePqW9xuNurZXgJheQVtBqBC3Kwyh80"
|
||||
}
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
}
|
||||
}
|
||||
}
|
||||
],
|
||||
"configuration_version": "1"
|
||||
}
|
|
@ -0,0 +1,20 @@
|
|||
package com.adins.mss.foundation.sync.api;
|
||||
|
||||
import com.adins.mss.dao.Sync;
|
||||
import com.adins.mss.foundation.http.MssResponseType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class SynchronizeResponseSync extends MssResponseType {
|
||||
@SerializedName("listSync")
|
||||
private List<Sync> listSync;
|
||||
|
||||
public List<Sync> getListSync() {
|
||||
return listSync;
|
||||
}
|
||||
|
||||
public void setListSync(List<Sync> listSync) {
|
||||
this.listSync = listSync;
|
||||
}
|
||||
}
|
Binary file not shown.
After Width: | Height: | Size: 2.8 KiB |
|
@ -0,0 +1,186 @@
|
|||
package com.adins.mss.base.todolist.form.followup;
|
||||
|
||||
import android.app.ProgressDialog;
|
||||
import android.os.AsyncTask;
|
||||
import android.os.Bundle;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.R;
|
||||
import com.adins.mss.base.crashlytics.FireCrash;
|
||||
import com.adins.mss.base.util.GsonHelper;
|
||||
import com.adins.mss.constant.Global;
|
||||
import com.adins.mss.foundation.dialog.NiftyDialogBuilder;
|
||||
import com.adins.mss.foundation.formatter.Tool;
|
||||
import com.adins.mss.foundation.http.HttpConnectionResult;
|
||||
import com.adins.mss.foundation.http.HttpCryptedConnection;
|
||||
import com.adins.mss.foundation.http.MssResponseType;
|
||||
|
||||
import static com.pax.ippi.impl.NeptuneUser.getApplicationContext;
|
||||
|
||||
public class FollowUpFormFragment extends Fragment {
|
||||
|
||||
private EditText namaKonsumen;
|
||||
private EditText nomorPerjanjian;
|
||||
private EditText tanggalJanjiBayar;
|
||||
private EditText catatan;
|
||||
private Button submitFormBtn;
|
||||
private Button scrollUpBtn;
|
||||
private Button scrollDownBtn;
|
||||
|
||||
private String uuidTaskH;
|
||||
private String customerName;
|
||||
private String agreementNo;
|
||||
private String flagTask;
|
||||
private String tglJanjiBayar;
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
|
||||
View view = inflater.inflate(R.layout.fragment_follow_up_form, container, false);
|
||||
namaKonsumen = view.findViewById(R.id.namaKonsumen);
|
||||
nomorPerjanjian = view.findViewById(R.id.nomorPerjanjian);
|
||||
tanggalJanjiBayar = view.findViewById(R.id.tanggalJanjiBayar);
|
||||
catatan = view.findViewById(R.id.catatan);
|
||||
submitFormBtn = view.findViewById(R.id.submitFormBtn);
|
||||
|
||||
scrollDownBtn = view.findViewById(R.id.button_scroll_down);
|
||||
scrollUpBtn = view.findViewById(R.id.button_scroll_up);
|
||||
|
||||
|
||||
if(getArguments() != null){
|
||||
uuidTaskH = getArguments().getString("uuidTaskH");
|
||||
customerName = getArguments().getString("customerName");
|
||||
agreementNo = getArguments().getString("agreementNo");
|
||||
flagTask = getArguments().getString("flagTask");
|
||||
tglJanjiBayar = getArguments().getString("tglJanjiBayar");
|
||||
|
||||
namaKonsumen.setText(customerName);
|
||||
nomorPerjanjian.setText(agreementNo);
|
||||
tanggalJanjiBayar.setText(tglJanjiBayar);
|
||||
}
|
||||
|
||||
scrollUpBtn.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
int totalLines = catatan.getLineCount();
|
||||
int visibleLines = catatan.getMaxLines();
|
||||
int lineHeight = catatan.getLineHeight();
|
||||
int scrollAmount = lineHeight * visibleLines; // Scroll one page up
|
||||
int currentScrollY = catatan.getScrollY();
|
||||
|
||||
int maxScroll = Math.max(0, currentScrollY - scrollAmount);
|
||||
|
||||
catatan.scrollTo(0, maxScroll);
|
||||
}
|
||||
});
|
||||
|
||||
scrollDownBtn.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
int totalLines = catatan.getLineCount();
|
||||
int visibleLines = catatan.getMaxLines();
|
||||
int lineHeight = catatan.getLineHeight();
|
||||
int scrollAmount = lineHeight * visibleLines; // Scroll one page down
|
||||
int currentScrollY = catatan.getScrollY();
|
||||
int maxScroll = Math.min(lineHeight * (totalLines - visibleLines), currentScrollY + scrollAmount);
|
||||
|
||||
catatan.scrollTo(0, maxScroll);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
submitFormBtn.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
new submitFormFollowUp().execute();
|
||||
}
|
||||
});
|
||||
return view;
|
||||
}
|
||||
|
||||
|
||||
|
||||
private class submitFormFollowUp extends AsyncTask<Void, Void, String>{
|
||||
private ProgressDialog progressDialog;
|
||||
|
||||
@Override
|
||||
protected void onPreExecute() {
|
||||
super.onPreExecute();
|
||||
|
||||
progressDialog = ProgressDialog.show(getActivity(), "", getString(R.string.progressWait), true);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected String doInBackground(Void... voids) {
|
||||
try {
|
||||
if(Tool.isInternetconnected(getActivity())){
|
||||
String result = "";
|
||||
SubmitFormRequest request = new SubmitFormRequest();
|
||||
request.setUuidTaskH(uuidTaskH);
|
||||
request.setFlagTask(flagTask);
|
||||
|
||||
request.setFollowUpNotes(catatan.getText().toString());
|
||||
request.setAudit(GlobalData.getSharedGlobalData().getAuditData());
|
||||
|
||||
String json = GsonHelper.toJson(request);
|
||||
String url = GlobalData.getSharedGlobalData().getURL_SUBMIT_FOLLOW_UP();
|
||||
boolean encrypt = GlobalData.getSharedGlobalData().isEncrypt();
|
||||
boolean decrypt = GlobalData.getSharedGlobalData().isDecrypt();
|
||||
HttpCryptedConnection httpConn = new HttpCryptedConnection(getApplicationContext(), encrypt, decrypt);
|
||||
HttpConnectionResult serverResult = null;
|
||||
serverResult = httpConn.requestToServer(url, json, Global.DEFAULTCONNECTIONTIMEOUT);
|
||||
|
||||
if(serverResult != null){
|
||||
if(serverResult .isOK()){
|
||||
try {
|
||||
result = serverResult.getResult();
|
||||
return result;
|
||||
|
||||
}catch (Exception e){
|
||||
FireCrash.log(e);
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}catch (Exception e){
|
||||
FireCrash.log(e);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPostExecute(String result) {
|
||||
super.onPostExecute(result);
|
||||
if(progressDialog != null && progressDialog.isShowing()){
|
||||
progressDialog.dismiss();
|
||||
}
|
||||
|
||||
if(result != null){
|
||||
final NiftyDialogBuilder dialogBuilder = NiftyDialogBuilder.getInstance(getActivity());
|
||||
dialogBuilder.withTitle(getActivity().getString(R.string.success_label))
|
||||
.isCancelableOnTouchOutside(false)
|
||||
.withMessage(getActivity().getString(R.string.submit_follow_up_success))
|
||||
.withButton1Text(getActivity().getString(R.string.btnOk))
|
||||
.setButton1Click(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
dialogBuilder.dismiss();
|
||||
getActivity().getSupportFragmentManager().popBackStackImmediate();
|
||||
}
|
||||
})
|
||||
.show();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,103 @@
|
|||
package com.adins.mss.dao;
|
||||
|
||||
import com.adins.mss.base.util.ExcludeFromGson;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT. Enable "keep" sections if you want to edit.
|
||||
/**
|
||||
* Entity mapped to table "MS_CONTACT".
|
||||
*/
|
||||
public class Contact {
|
||||
|
||||
/** Not-null value. */
|
||||
@SerializedName("uuid_contact")
|
||||
private String uuid_contact;
|
||||
@SerializedName("contact_name")
|
||||
private String contact_name;
|
||||
@SerializedName("contact_dept")
|
||||
private String contact_dept;
|
||||
@SerializedName("contact_phone")
|
||||
private String contact_phone;
|
||||
@SerializedName("contact_email")
|
||||
private String contact_email;
|
||||
@SerializedName("uuid_account")
|
||||
private String uuid_account;
|
||||
@SerializedName("dtm_crt")
|
||||
private java.util.Date dtm_crt;
|
||||
|
||||
public Contact() {
|
||||
}
|
||||
|
||||
public Contact(String uuid_contact) {
|
||||
this.uuid_contact = uuid_contact;
|
||||
}
|
||||
|
||||
public Contact(String uuid_contact, String contact_name, String contact_dept, String contact_phone, String contact_email, String uuid_account, java.util.Date dtm_crt) {
|
||||
this.uuid_contact = uuid_contact;
|
||||
this.contact_name = contact_name;
|
||||
this.contact_dept = contact_dept;
|
||||
this.contact_phone = contact_phone;
|
||||
this.contact_email = contact_email;
|
||||
this.uuid_account = uuid_account;
|
||||
this.dtm_crt = dtm_crt;
|
||||
}
|
||||
|
||||
/** Not-null value. */
|
||||
public String getUuid_contact() {
|
||||
return uuid_contact;
|
||||
}
|
||||
|
||||
/** Not-null value; ensure this value is available before it is saved to the database. */
|
||||
public void setUuid_contact(String uuid_contact) {
|
||||
this.uuid_contact = uuid_contact;
|
||||
}
|
||||
|
||||
public String getContact_name() {
|
||||
return contact_name;
|
||||
}
|
||||
|
||||
public void setContact_name(String contact_name) {
|
||||
this.contact_name = contact_name;
|
||||
}
|
||||
|
||||
public String getContact_dept() {
|
||||
return contact_dept;
|
||||
}
|
||||
|
||||
public void setContact_dept(String contact_dept) {
|
||||
this.contact_dept = contact_dept;
|
||||
}
|
||||
|
||||
public String getContact_phone() {
|
||||
return contact_phone;
|
||||
}
|
||||
|
||||
public void setContact_phone(String contact_phone) {
|
||||
this.contact_phone = contact_phone;
|
||||
}
|
||||
|
||||
public String getContact_email() {
|
||||
return contact_email;
|
||||
}
|
||||
|
||||
public void setContact_email(String contact_email) {
|
||||
this.contact_email = contact_email;
|
||||
}
|
||||
|
||||
public String getUuid_account() {
|
||||
return uuid_account;
|
||||
}
|
||||
|
||||
public void setUuid_account(String uuid_account) {
|
||||
this.uuid_account = uuid_account;
|
||||
}
|
||||
|
||||
public java.util.Date getDtm_crt() {
|
||||
return dtm_crt;
|
||||
}
|
||||
|
||||
public void setDtm_crt(java.util.Date dtm_crt) {
|
||||
this.dtm_crt = dtm_crt;
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,294 @@
|
|||
package com.services;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.AsyncTask;
|
||||
import android.util.Log;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.crashlytics.FireCrash;
|
||||
import com.adins.mss.base.dynamicform.TaskManager;
|
||||
import com.adins.mss.base.util.GsonHelper;
|
||||
import com.adins.mss.base.util.Utility;
|
||||
import com.adins.mss.constant.Global;
|
||||
import com.adins.mss.dao.GeneralParameter;
|
||||
import com.adins.mss.dao.LastSync;
|
||||
import com.adins.mss.dao.TaskH;
|
||||
import com.adins.mss.foundation.camerainapp.helper.Logger;
|
||||
import com.adins.mss.foundation.db.dataaccess.GeneralParameterDataAccess;
|
||||
import com.adins.mss.foundation.db.dataaccess.LastSyncDataAccess;
|
||||
import com.adins.mss.foundation.db.dataaccess.TaskDDataAccess;
|
||||
import com.adins.mss.foundation.db.dataaccess.TaskHDataAccess;
|
||||
import com.adins.mss.foundation.formatter.Formatter;
|
||||
import com.adins.mss.foundation.formatter.Tool;
|
||||
import com.adins.mss.foundation.http.HttpConnectionResult;
|
||||
import com.adins.mss.foundation.http.HttpCryptedConnection;
|
||||
import com.google.firebase.perf.FirebasePerformance;
|
||||
import com.google.firebase.perf.metrics.HttpMetric;
|
||||
import com.services.models.JsonRequestLastSync;
|
||||
import com.services.models.JsonResponseLastSync;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
public class AutoSendTaskThread extends Thread {
|
||||
private static String TAG = "AUTOSEND";
|
||||
private Context context;
|
||||
private int interval = 0;
|
||||
private volatile boolean keepRunning = true;
|
||||
private volatile boolean isWait = false;
|
||||
private boolean debug;
|
||||
private static List<String> listTaskSubmitManual = new ArrayList<>();
|
||||
private final Object threadMonitor;
|
||||
|
||||
public AutoSendTaskThread(Context context,Object threadMonitor) {
|
||||
this.threadMonitor = threadMonitor;
|
||||
this.context = context;
|
||||
this.debug = Global.IS_DEV;
|
||||
|
||||
try {
|
||||
GeneralParameter gp = GeneralParameterDataAccess.getOne(context,
|
||||
GlobalData.getSharedGlobalData().getUser().getUuid_user(),
|
||||
Global.GS_INTERVAL_AUTOSEND);
|
||||
if (gp != null) {
|
||||
|
||||
interval = Global.SECOND * Integer.parseInt(gp.getGs_value());
|
||||
}
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
interval = 0;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
while (keepRunning) {
|
||||
try {
|
||||
synchronized (threadMonitor) {
|
||||
if (isWait) {
|
||||
threadMonitor.wait();
|
||||
}
|
||||
}
|
||||
try {
|
||||
String uuidUser = GlobalData.getSharedGlobalData().getUser()
|
||||
.getUuid_user();
|
||||
if (uuidUser != null) {
|
||||
GeneralParameter gp = GeneralParameterDataAccess.getOne(context, uuidUser, Global.GS_INTERVAL_AUTOSEND);
|
||||
if (gp != null && gp.getGs_value() != null
|
||||
&& !gp.getGs_value()
|
||||
.isEmpty()) {
|
||||
interval = Integer.parseInt(gp.getGs_value()) * Global.SECOND;
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
}
|
||||
|
||||
if (interval > 0) {
|
||||
if (Tool.isInternetconnected(context)) {
|
||||
//Check unsent last sync from db
|
||||
List<LastSync> sendlistsync = LastSyncDataAccess.getAllBySentStatus(context, 0);
|
||||
int count = sendlistsync.size();
|
||||
if (count > 0) {
|
||||
//loop unsent last sync and send to server
|
||||
for (LastSync lastSync : sendlistsync) {
|
||||
try {
|
||||
SendLastSync sendLastSync = new SendLastSync(context, lastSync);
|
||||
sendLastSync.execute();
|
||||
} catch (Exception exc) {
|
||||
FireCrash.log(exc);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
if (Tool.isInternetconnected(context) && !Global.isIsManualSubmit()) {
|
||||
List<TaskH> sendTask = TaskHDataAccess
|
||||
.getAllTaskByStatus(context, GlobalData
|
||||
.getSharedGlobalData().getUser()
|
||||
.getUuid_user(),
|
||||
TaskHDataAccess.STATUS_SEND_PENDING);
|
||||
int count = sendTask.size();
|
||||
if (count > 0) {
|
||||
for (TaskH taskH : sendTask) {
|
||||
try {
|
||||
boolean isPrintable = false;
|
||||
try {
|
||||
isPrintable = Formatter.stringToBoolean(taskH.getScheme().getIs_printable());
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
}
|
||||
boolean isTaskPaid = TaskDDataAccess.isTaskPaid(context, GlobalData.getSharedGlobalData().getUser().getUuid_user(),
|
||||
taskH.getUuid_task_h());
|
||||
|
||||
if (!isPrintable && !isTaskPaid) {
|
||||
try {
|
||||
if (taskH.getIs_prepocessed() != null && taskH.getIs_prepocessed().equals(Global.FORM_TYPE_VERIFICATION)) {
|
||||
if (taskH.getFlag_survey() != null && taskH.getFlag_survey().equals(Global.FLAG_FOR_REJECTEDTASK))
|
||||
new TaskManager.ApproveTaskOnBackground(context, taskH, Global.FLAG_FOR_REJECTEDTASK, false, taskH.getVerification_notes()).execute();
|
||||
else if (taskH.getFlag_survey() != null && taskH.getFlag_survey().equals(Global.FLAG_FOR_REJECTEDTASK_WITHRESURVEY))
|
||||
new TaskManager.RejectWithReSurveyTaskOnBackground(context, taskH, Global.FLAG_FOR_REJECTEDTASK_WITHRESURVEY, Global.VERIFICATION_FLAG).execute();
|
||||
else
|
||||
new TaskManager().saveAndSendTaskOnBackground(context, taskH.getTask_id(), false, false);
|
||||
} else if (taskH.getIs_prepocessed() != null && taskH.getIs_prepocessed().equals(Global.FORM_TYPE_APPROVAL)) {
|
||||
if (taskH.getFlag_survey() != null && taskH.getFlag_survey().equals(Global.FLAG_FOR_REJECTEDTASK))
|
||||
new TaskManager.ApproveTaskOnBackground(context, taskH, Global.FLAG_FOR_REJECTEDTASK, true, taskH.getVerification_notes()).execute();
|
||||
else if (taskH.getFlag_survey() != null && taskH.getFlag_survey().equals(Global.FLAG_FOR_REJECTEDTASK_WITHRESURVEY))
|
||||
new TaskManager.RejectWithReSurveyTaskOnBackground(context, taskH, Global.FLAG_FOR_REJECTEDTASK_WITHRESURVEY, Global.APPROVAL_FLAG).execute();
|
||||
else
|
||||
new TaskManager.ApproveTaskOnBackground(context, taskH, Global.FLAG_FOR_APPROVALTASK, true, taskH.getVerification_notes()).execute();
|
||||
} else
|
||||
new TaskManager().saveAndSendTaskOnBackground(context, taskH.getUuid_task_h(), false, false);
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
}
|
||||
|
||||
} else {
|
||||
if (!isTaskPaid) {
|
||||
//Nendi: 2019.06.13 | Bugfix PRDAITMSS-660 (CollAct - Autosend untuk result gagal collect tidak jalan)
|
||||
new TaskManager().saveAndSendTaskOnBackground(context, taskH.getUuid_task_h(), false, false);
|
||||
}
|
||||
}
|
||||
TaskHDataAccess.doBackup(context, taskH);
|
||||
} catch (Exception ex) {
|
||||
ex.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
try {
|
||||
MainServices.autoSendTaskThread.requestStop();
|
||||
} catch (Exception e) {
|
||||
FireCrash.log(e);
|
||||
}
|
||||
}
|
||||
try {
|
||||
Thread.sleep(interval);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
Thread.currentThread().interrupt();
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
Logger.e(TAG, Log.getStackTraceString(ex));
|
||||
ex.printStackTrace();
|
||||
try {
|
||||
Thread.sleep(interval);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
Thread.currentThread().interrupt();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
try {
|
||||
sleep(1000);
|
||||
} catch (InterruptedException e) {
|
||||
e.printStackTrace();
|
||||
Thread.currentThread().interrupt();
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized void requestWait() {
|
||||
isWait = true;
|
||||
}
|
||||
|
||||
public synchronized void stopWaiting() {
|
||||
isWait = false;
|
||||
synchronized (threadMonitor) {
|
||||
threadMonitor.notifyAll();
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized void requestStop() {
|
||||
keepRunning = false;
|
||||
}
|
||||
|
||||
public static void addTaskSubmitManual(String uuid_task_h) {
|
||||
if(!listTaskSubmitManual.contains(uuid_task_h))
|
||||
listTaskSubmitManual.add(uuid_task_h);
|
||||
}
|
||||
|
||||
public static void removeTaskSubmitManual(String uuid_task_h) {
|
||||
listTaskSubmitManual.remove(uuid_task_h);
|
||||
}
|
||||
|
||||
class SendLastSync extends AsyncTask<Void, Void, Void> {
|
||||
private Context context;
|
||||
private LastSync lastSync;
|
||||
|
||||
public SendLastSync(Context context, LastSync lastSync) {
|
||||
this.context = context;
|
||||
this.lastSync = lastSync;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected Void doInBackground(Void... params) {
|
||||
String uuidLastSync = lastSync.getUuid_last_sync();
|
||||
JsonRequestLastSync request = new JsonRequestLastSync();
|
||||
request.setAudit(GlobalData.getSharedGlobalData().getAuditData());
|
||||
request.setDtm_req(lastSync.getDtm_req());
|
||||
request.setData(lastSync.getData());
|
||||
request.setFlag(lastSync.getFlag());
|
||||
String[] arr = null;
|
||||
if (lastSync.getListOfLOV() != null) {
|
||||
arr = lastSync.getListOfLOV().substring(
|
||||
1, lastSync.getListOfLOV().length() - 1).split(",");
|
||||
List<String> list = Arrays.asList(arr);
|
||||
} else {
|
||||
arr = null;
|
||||
}
|
||||
List<String> list = new ArrayList<>();
|
||||
if (arr == null) {
|
||||
list.add("");
|
||||
} else {
|
||||
for (int i = 0; i < arr.length; i++) {
|
||||
list.add(arr[i].trim());
|
||||
}
|
||||
}
|
||||
request.setListOfLOV(list);
|
||||
String json = GsonHelper.toJson(request);
|
||||
String url = GlobalData.getSharedGlobalData().getURL_LAST_SYNC();
|
||||
boolean encrypt = GlobalData.getSharedGlobalData().isEncrypt();
|
||||
boolean decrypt = GlobalData.getSharedGlobalData().isDecrypt();
|
||||
HttpCryptedConnection httpConn = new HttpCryptedConnection(context, encrypt, decrypt);
|
||||
HttpConnectionResult serverResult = null;
|
||||
|
||||
//Firebase Performance Trace HTTP Request
|
||||
HttpMetric networkMetric =
|
||||
FirebasePerformance.getInstance().newHttpMetric(url, FirebasePerformance.HttpMethod.POST);
|
||||
Utility.metricStart(networkMetric, json);
|
||||
|
||||
try {
|
||||
serverResult = httpConn.requestToServer(url, json, Global.DEFAULTCONNECTIONTIMEOUT);
|
||||
Utility.metricStop(networkMetric, serverResult);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
if(serverResult == null){
|
||||
return null;
|
||||
}
|
||||
|
||||
if (serverResult.isOK()) {
|
||||
try {
|
||||
String result = serverResult.getResult();
|
||||
JsonResponseLastSync responseLastSync = GsonHelper.fromJson(result, JsonResponseLastSync.class);
|
||||
if (responseLastSync.getStatus().getCode() == 1) {
|
||||
LastSyncDataAccess.delete(context, uuidLastSync);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
return null;
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPostExecute(Void aVoid) {
|
||||
super.onPostExecute(aVoid);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,86 @@
|
|||
package com.adins.mss.odr.simulasi;
|
||||
|
||||
import android.app.ActionBar;
|
||||
import android.content.Context;
|
||||
import android.os.Bundle;
|
||||
import android.view.View;
|
||||
import android.widget.AdapterView;
|
||||
|
||||
import com.adins.mss.base.GlobalData;
|
||||
import com.adins.mss.base.dynamicform.CustomerFragment;
|
||||
import com.adins.mss.base.dynamicform.FormBean;
|
||||
import com.adins.mss.base.dynamicform.QuestionSetTask;
|
||||
import com.adins.mss.base.dynamicform.SurveyHeaderBean;
|
||||
import com.adins.mss.base.todo.form.NewTaskActivity;
|
||||
import com.adins.mss.base.todo.form.NewTaskAdapter;
|
||||
import com.adins.mss.constant.Global;
|
||||
import com.adins.mss.dao.Scheme;
|
||||
import com.adins.mss.dao.TaskH;
|
||||
import com.adins.mss.foundation.db.dataaccess.TaskHDataAccess;
|
||||
import com.adins.mss.foundation.formatter.Tool;
|
||||
import com.adins.mss.odr.R;
|
||||
|
||||
import org.acra.ACRA;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public class CreditSimulationActivity extends NewTaskActivity{
|
||||
private CreditSimulation simulation;
|
||||
private List<Scheme> objects;
|
||||
|
||||
@Override
|
||||
public void onAttach(Context activity) {
|
||||
super.onAttach(activity);
|
||||
ACRA.getErrorReporter().putCustomData("LAST_CLASS_ACCESSED", getClass().getSimpleName());
|
||||
getActivity().getActionBar().setTitle(getString(R.string.title_mn_creditsimulation));
|
||||
}
|
||||
@Override
|
||||
public void onResume(){
|
||||
super.onResume();
|
||||
getActivity().getActionBar().removeAllTabs();
|
||||
getActivity().getActionBar().setTitle(getString(R.string.title_mn_creditsimulation));
|
||||
getActivity().getActionBar().setNavigationMode(ActionBar.NAVIGATION_MODE_STANDARD);
|
||||
}
|
||||
@Override
|
||||
protected NewTaskAdapter getNewTaskAdapter() {
|
||||
simulation = new CreditSimulation(getActivity());
|
||||
objects = simulation.getSimulationScheme();
|
||||
return new NewTaskAdapter(getActivity(), objects);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected TaskH setNewTaskH(Scheme scheme){
|
||||
TaskH taskH = new TaskH();
|
||||
taskH.setUuid_task_h(Tool.getUUID());
|
||||
taskH.setUser(GlobalData.getSharedGlobalData().getUser());
|
||||
taskH.setScheme(scheme);
|
||||
taskH.setStatus(TaskHDataAccess.STATUS_SEND_INIT);
|
||||
taskH.setIs_verification("0");
|
||||
taskH.setCustomer_name("Customer Simulasi");
|
||||
taskH.setCustomer_address("Alamat Simulasi");
|
||||
taskH.setCustomer_phone("12345678");
|
||||
taskH.setZip_code("12345");
|
||||
return taskH;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void itemClick(AdapterView<?> parent, View v, int position, long id){
|
||||
Scheme selectedScheme= getNewTaskAdapter().getItem(position);
|
||||
TaskH selectedTask = setNewTaskH(selectedScheme);
|
||||
CustomerFragment.setHeader(new SurveyHeaderBean(selectedTask));
|
||||
|
||||
FormBean formBean = new FormBean(CustomerFragment.getHeader().getScheme());
|
||||
if(CustomerFragment.getHeader().getStart_date()==null)
|
||||
CustomerFragment.getHeader().setStart_date(Tool.getSystemDateTime());
|
||||
CustomerFragment.getHeader().setForm(formBean);
|
||||
CustomerFragment.getHeader().setIs_preview_server(formBean.getIs_preview_server());
|
||||
|
||||
Bundle extras = new Bundle();
|
||||
extras.putInt(Global.BUND_KEY_MODE_SURVEY, Global.MODE_NEW_SURVEY);
|
||||
extras.putString(Global.BUND_KEY_UUID_TASKH, CustomerFragment.getHeader().getUuid_task_h());
|
||||
extras.putSerializable(Global.BUND_KEY_SURVEY_BEAN, CustomerFragment.getHeader());
|
||||
extras.putBoolean(Global.BUND_KEY_MODE_SIMULASI, true);
|
||||
QuestionSetTask task =new QuestionSetTask(getActivity(), extras);
|
||||
task.execute();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,137 @@
|
|||
package com.adins.mss.dao;
|
||||
|
||||
import android.database.Cursor;
|
||||
|
||||
import de.greenrobot.dao.AbstractDao;
|
||||
import de.greenrobot.dao.Property;
|
||||
import de.greenrobot.dao.internal.DaoConfig;
|
||||
import de.greenrobot.dao.database.Database;
|
||||
import de.greenrobot.dao.database.DatabaseStatement;
|
||||
|
||||
import com.adins.mss.dao.BankAccountOfBranch;
|
||||
|
||||
// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.
|
||||
/**
|
||||
* DAO for table "MS_BANKACCOUNTOFBRANCH".
|
||||
*/
|
||||
public class BankAccountOfBranchDao extends AbstractDao<BankAccountOfBranch, String> {
|
||||
|
||||
public static final String TABLENAME = "MS_BANKACCOUNTOFBRANCH";
|
||||
|
||||
/**
|
||||
* Properties of entity BankAccountOfBranch.<br/>
|
||||
* Can be used for QueryBuilder and for referencing column names.
|
||||
*/
|
||||
public static class Properties {
|
||||
public final static Property Uuid_bankaccountofbranch = new Property(0, String.class, "uuid_bankaccountofbranch", true, "UUID_BANKACCOUNTOFBRANCH");
|
||||
public final static Property Bank_account_id = new Property(1, String.class, "bank_account_id", false, "BANK_ACCOUNT_ID");
|
||||
public final static Property Bank_account_no = new Property(2, String.class, "bank_account_no", false, "BANK_ACCOUNT_NO");
|
||||
public final static Property Bank_account_name = new Property(3, String.class, "bank_account_name", false, "BANK_ACCOUNT_NAME");
|
||||
public final static Property Branch_code = new Property(4, String.class, "branch_code", false, "BRANCH_CODE");
|
||||
};
|
||||
|
||||
|
||||
public BankAccountOfBranchDao(DaoConfig config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
public BankAccountOfBranchDao(DaoConfig config, DaoSession daoSession) {
|
||||
super(config, daoSession);
|
||||
}
|
||||
|
||||
/** Creates the underlying database table. */
|
||||
public static void createTable(Database db, boolean ifNotExists) {
|
||||
String constraint = ifNotExists? "IF NOT EXISTS ": "";
|
||||
db.execSQL("CREATE TABLE " + constraint + "\"MS_BANKACCOUNTOFBRANCH\" (" + //
|
||||
"\"UUID_BANKACCOUNTOFBRANCH\" TEXT PRIMARY KEY NOT NULL ," + // 0: uuid_bankaccountofbranch
|
||||
"\"BANK_ACCOUNT_ID\" TEXT," + // 1: bank_account_id
|
||||
"\"BANK_ACCOUNT_NO\" TEXT," + // 2: bank_account_no
|
||||
"\"BANK_ACCOUNT_NAME\" TEXT," + // 3: bank_account_name
|
||||
"\"BRANCH_CODE\" TEXT);"); // 4: branch_code
|
||||
}
|
||||
|
||||
/** Drops the underlying database table. */
|
||||
public static void dropTable(Database db, boolean ifExists) {
|
||||
String sql = "DROP TABLE " + (ifExists ? "IF EXISTS " : "") + "\"MS_BANKACCOUNTOFBRANCH\"";
|
||||
db.execSQL(sql);
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
protected void bindValues(DatabaseStatement stmt, BankAccountOfBranch entity) {
|
||||
stmt.clearBindings();
|
||||
stmt.bindString(1, entity.getUuid_bankaccountofbranch());
|
||||
|
||||
String bank_account_id = entity.getBank_account_id();
|
||||
if (bank_account_id != null) {
|
||||
stmt.bindString(2, bank_account_id);
|
||||
}
|
||||
|
||||
String bank_account_no = entity.getBank_account_no();
|
||||
if (bank_account_no != null) {
|
||||
stmt.bindString(3, bank_account_no);
|
||||
}
|
||||
|
||||
String bank_account_name = entity.getBank_account_name();
|
||||
if (bank_account_name != null) {
|
||||
stmt.bindString(4, bank_account_name);
|
||||
}
|
||||
|
||||
String branch_code = entity.getBranch_code();
|
||||
if (branch_code != null) {
|
||||
stmt.bindString(5, branch_code);
|
||||
}
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public String readKey(Cursor cursor, int offset) {
|
||||
return cursor.getString(offset + 0);
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public BankAccountOfBranch readEntity(Cursor cursor, int offset) {
|
||||
BankAccountOfBranch entity = new BankAccountOfBranch( //
|
||||
cursor.getString(offset + 0), // uuid_bankaccountofbranch
|
||||
cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1), // bank_account_id
|
||||
cursor.isNull(offset + 2) ? null : cursor.getString(offset + 2), // bank_account_no
|
||||
cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3), // bank_account_name
|
||||
cursor.isNull(offset + 4) ? null : cursor.getString(offset + 4) // branch_code
|
||||
);
|
||||
return entity;
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public void readEntity(Cursor cursor, BankAccountOfBranch entity, int offset) {
|
||||
entity.setUuid_bankaccountofbranch(cursor.getString(offset + 0));
|
||||
entity.setBank_account_id(cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1));
|
||||
entity.setBank_account_no(cursor.isNull(offset + 2) ? null : cursor.getString(offset + 2));
|
||||
entity.setBank_account_name(cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3));
|
||||
entity.setBranch_code(cursor.isNull(offset + 4) ? null : cursor.getString(offset + 4));
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
protected String updateKeyAfterInsert(BankAccountOfBranch entity, long rowId) {
|
||||
return entity.getUuid_bankaccountofbranch();
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public String getKey(BankAccountOfBranch entity) {
|
||||
if(entity != null) {
|
||||
return entity.getUuid_bankaccountofbranch();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
protected boolean isEntityUpdateable() {
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue