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,98 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<declare-styleable name="DrawInsetsFrameLayout">
|
||||
<attr name="insetBackground" format="reference|color"/>
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="PullToRefreshView">
|
||||
|
||||
<!-- The class to use as a View's View Delegate. Can be relative path from app's package name -->
|
||||
<attr name="ptrViewDelegateClass" format="reference|string" />
|
||||
|
||||
</declare-styleable>
|
||||
|
||||
<!-- The attribute to set in your Application/Activity theme to reference your custom theme -->
|
||||
<attr name="ptrHeaderStyle" format="reference" />
|
||||
|
||||
<declare-styleable name="PullToRefreshHeader">
|
||||
|
||||
<!-- A drawable to use as the background of the Header View -->
|
||||
<attr name="ptrHeaderBackground" format="reference|color" />
|
||||
|
||||
<!-- The height of the Header View -->
|
||||
<attr name="ptrHeaderHeight" format="reference|dimension" />
|
||||
|
||||
<!-- The Text Appearance of the Header View's Title text -->
|
||||
<attr name="ptrHeaderTitleTextAppearance" format="reference" />
|
||||
|
||||
<!-- The color that the Progress Bar should be tinted with -->
|
||||
<attr name="ptrProgressBarColor" format="reference|color" />
|
||||
|
||||
<!-- The style of the Progress Bar -->
|
||||
<attr name="ptrProgressBarStyle">
|
||||
<flag name="inside" value="0x0" />
|
||||
<flag name="outside" value="0x1" />
|
||||
</attr>
|
||||
|
||||
<!-- The height of the Progress Bar -->
|
||||
<attr name="ptrProgressBarHeight" format="reference|dimension" />
|
||||
|
||||
<!-- Text to show to prompt the user is pull (or keep pulling) -->
|
||||
<attr name="ptrPullText" format="reference|string" />
|
||||
|
||||
<!-- Text to show to tell the user that a refresh is currently in progress -->
|
||||
<attr name="ptrRefreshingText" format="reference|string" />
|
||||
|
||||
<!-- Text to show to tell the user has scrolled enough to refresh -->
|
||||
<attr name="ptrReleaseText" format="reference|string" />
|
||||
|
||||
<!--indeterminate progressbar style-->
|
||||
<attr name="ptrSmoothProgressBarStyle" format="reference"/>
|
||||
|
||||
</declare-styleable>
|
||||
|
||||
<declare-styleable name="SmoothProgressBar">
|
||||
<attr name="spbStyle" format="reference"/>
|
||||
<attr name="spb_color" format="color"/>
|
||||
<attr name="spb_stroke_width" format="dimension"/>
|
||||
<attr name="spb_stroke_separator_length" format="dimension"/>
|
||||
<attr name="spb_sections_count" format="integer"/>
|
||||
<attr name="spb_speed" format="float"/>
|
||||
<attr name="spb_progressiveStart_speed" format="float"/>
|
||||
<attr name="spb_progressiveStop_speed" format="float"/>
|
||||
<attr name="spb_interpolator" format="enum">
|
||||
<enum name="spb_interpolator_accelerate" value="0"/>
|
||||
<enum name="spb_interpolator_linear" value="1"/>
|
||||
<enum name="spb_interpolator_acceleratedecelerate" value="2"/>
|
||||
<enum name="spb_interpolator_decelerate" value="3"/>
|
||||
</attr>
|
||||
<attr name="spb_reversed" format="boolean"/>
|
||||
<attr name="spb_mirror_mode" format="boolean"/>
|
||||
<attr name="spb_colors" format="reference"/>
|
||||
<attr name="spb_progressiveStart_activated" format="boolean"/>
|
||||
<attr name="spb_background" format="reference"/>
|
||||
<attr name="spb_generate_background_with_colors" format="boolean"/>
|
||||
<attr name="spb_gradients" format="boolean"/>
|
||||
</declare-styleable>
|
||||
|
||||
<attr name="cropImageStyle" format="reference" />
|
||||
|
||||
<declare-styleable name="CropImageView">
|
||||
<attr name="highlightColor" format="reference|color" />
|
||||
<attr name="showThirds" format="boolean" />
|
||||
<attr name="showHandles">
|
||||
<enum name="changing" value="0" />
|
||||
<enum name="always" value="1" />
|
||||
<enum name="never" value="2" />
|
||||
</attr>
|
||||
<attr name="guidelines">
|
||||
<enum name="on" value="2"/>
|
||||
<enum name="onTouch" value="1"/>
|
||||
<enum name="off" value="0"/>
|
||||
</attr>
|
||||
<attr name="fixAspectRatio" format="boolean"/>
|
||||
<attr name="aspectRatioX" format="integer"/>
|
||||
<attr name="aspectRatioY" format= "integer"/>
|
||||
<attr name="imageResource" format="reference"/>
|
||||
</declare-styleable>
|
||||
</resources>
|
|
@ -0,0 +1,24 @@
|
|||
package com.adins.mss.odr.followup.api;
|
||||
|
||||
import com.adins.mss.dao.GroupTask;
|
||||
import com.adins.mss.foundation.http.MssResponseType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by olivia.dg on 11/24/2017.
|
||||
*/
|
||||
|
||||
public class GetFollowUpResponse extends MssResponseType {
|
||||
@SerializedName("listFollowUp")
|
||||
private List<GroupTask> listFollowUp;
|
||||
|
||||
public List<GroupTask> getListFollowUp() {
|
||||
return listFollowUp;
|
||||
}
|
||||
|
||||
public void setListFollowUp(List<GroupTask> listFollowUp) {
|
||||
this.listFollowUp = listFollowUp;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,302 @@
|
|||
package com.adins.mss.dao;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.ArrayList;
|
||||
import android.database.Cursor;
|
||||
|
||||
import de.greenrobot.dao.AbstractDao;
|
||||
import de.greenrobot.dao.Property;
|
||||
import de.greenrobot.dao.internal.SqlUtils;
|
||||
import de.greenrobot.dao.internal.DaoConfig;
|
||||
import de.greenrobot.dao.database.Database;
|
||||
import de.greenrobot.dao.database.DatabaseStatement;
|
||||
import de.greenrobot.dao.query.Query;
|
||||
import de.greenrobot.dao.query.QueryBuilder;
|
||||
|
||||
import com.adins.mss.dao.Comment;
|
||||
|
||||
// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.
|
||||
/**
|
||||
* DAO for table "TR_COMMENT".
|
||||
*/
|
||||
public class CommentDao extends AbstractDao<Comment, String> {
|
||||
|
||||
public static final String TABLENAME = "TR_COMMENT";
|
||||
|
||||
/**
|
||||
* Properties of entity Comment.<br/>
|
||||
* Can be used for QueryBuilder and for referencing column names.
|
||||
*/
|
||||
public static class Properties {
|
||||
public final static Property Uuid_comment = new Property(0, String.class, "uuid_comment", true, "UUID_COMMENT");
|
||||
public final static Property Comment = new Property(1, String.class, "comment", false, "COMMENT");
|
||||
public final static Property Dtm_crt_server = new Property(2, java.util.Date.class, "dtm_crt_server", false, "DTM_CRT_SERVER");
|
||||
public final static Property Sender_id = new Property(3, String.class, "sender_id", false, "SENDER_ID");
|
||||
public final static Property Sender_name = new Property(4, String.class, "sender_name", false, "SENDER_NAME");
|
||||
public final static Property Usr_crt = new Property(5, String.class, "usr_crt", false, "USR_CRT");
|
||||
public final static Property Dtm_crt = new Property(6, java.util.Date.class, "dtm_crt", false, "DTM_CRT");
|
||||
public final static Property Usr_upd = new Property(7, String.class, "usr_upd", false, "USR_UPD");
|
||||
public final static Property Dtm_upd = new Property(8, java.util.Date.class, "dtm_upd", false, "DTM_UPD");
|
||||
public final static Property Uuid_timeline = new Property(9, String.class, "uuid_timeline", false, "UUID_TIMELINE");
|
||||
};
|
||||
|
||||
private DaoSession daoSession;
|
||||
|
||||
private Query<Comment> timeline_CommentListQuery;
|
||||
|
||||
public CommentDao(DaoConfig config) {
|
||||
super(config);
|
||||
}
|
||||
|
||||
public CommentDao(DaoConfig config, DaoSession daoSession) {
|
||||
super(config, daoSession);
|
||||
this.daoSession = 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 + "\"TR_COMMENT\" (" + //
|
||||
"\"UUID_COMMENT\" TEXT PRIMARY KEY NOT NULL ," + // 0: uuid_comment
|
||||
"\"COMMENT\" TEXT," + // 1: comment
|
||||
"\"DTM_CRT_SERVER\" INTEGER," + // 2: dtm_crt_server
|
||||
"\"SENDER_ID\" TEXT," + // 3: sender_id
|
||||
"\"SENDER_NAME\" TEXT," + // 4: sender_name
|
||||
"\"USR_CRT\" TEXT," + // 5: usr_crt
|
||||
"\"DTM_CRT\" INTEGER," + // 6: dtm_crt
|
||||
"\"USR_UPD\" TEXT," + // 7: usr_upd
|
||||
"\"DTM_UPD\" INTEGER," + // 8: dtm_upd
|
||||
"\"UUID_TIMELINE\" TEXT);"); // 9: uuid_timeline
|
||||
}
|
||||
|
||||
/** Drops the underlying database table. */
|
||||
public static void dropTable(Database db, boolean ifExists) {
|
||||
String sql = "DROP TABLE " + (ifExists ? "IF EXISTS " : "") + "\"TR_COMMENT\"";
|
||||
db.execSQL(sql);
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
protected void bindValues(DatabaseStatement stmt, Comment entity) {
|
||||
stmt.clearBindings();
|
||||
stmt.bindString(1, entity.getUuid_comment());
|
||||
|
||||
String comment = entity.getComment();
|
||||
if (comment != null) {
|
||||
stmt.bindString(2, comment);
|
||||
}
|
||||
|
||||
java.util.Date dtm_crt_server = entity.getDtm_crt_server();
|
||||
if (dtm_crt_server != null) {
|
||||
stmt.bindLong(3, dtm_crt_server.getTime());
|
||||
}
|
||||
|
||||
String sender_id = entity.getSender_id();
|
||||
if (sender_id != null) {
|
||||
stmt.bindString(4, sender_id);
|
||||
}
|
||||
|
||||
String sender_name = entity.getSender_name();
|
||||
if (sender_name != null) {
|
||||
stmt.bindString(5, sender_name);
|
||||
}
|
||||
|
||||
String usr_crt = entity.getUsr_crt();
|
||||
if (usr_crt != null) {
|
||||
stmt.bindString(6, usr_crt);
|
||||
}
|
||||
|
||||
java.util.Date dtm_crt = entity.getDtm_crt();
|
||||
if (dtm_crt != null) {
|
||||
stmt.bindLong(7, dtm_crt.getTime());
|
||||
}
|
||||
|
||||
String usr_upd = entity.getUsr_upd();
|
||||
if (usr_upd != null) {
|
||||
stmt.bindString(8, usr_upd);
|
||||
}
|
||||
|
||||
java.util.Date dtm_upd = entity.getDtm_upd();
|
||||
if (dtm_upd != null) {
|
||||
stmt.bindLong(9, dtm_upd.getTime());
|
||||
}
|
||||
|
||||
String uuid_timeline = entity.getUuid_timeline();
|
||||
if (uuid_timeline != null) {
|
||||
stmt.bindString(10, uuid_timeline);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void attachEntity(Comment entity) {
|
||||
super.attachEntity(entity);
|
||||
entity.__setDaoSession(daoSession);
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public String readKey(Cursor cursor, int offset) {
|
||||
return cursor.getString(offset + 0);
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public Comment readEntity(Cursor cursor, int offset) {
|
||||
Comment entity = new Comment( //
|
||||
cursor.getString(offset + 0), // uuid_comment
|
||||
cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1), // comment
|
||||
cursor.isNull(offset + 2) ? null : new java.util.Date(cursor.getLong(offset + 2)), // dtm_crt_server
|
||||
cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3), // sender_id
|
||||
cursor.isNull(offset + 4) ? null : cursor.getString(offset + 4), // sender_name
|
||||
cursor.isNull(offset + 5) ? null : cursor.getString(offset + 5), // usr_crt
|
||||
cursor.isNull(offset + 6) ? null : new java.util.Date(cursor.getLong(offset + 6)), // dtm_crt
|
||||
cursor.isNull(offset + 7) ? null : cursor.getString(offset + 7), // usr_upd
|
||||
cursor.isNull(offset + 8) ? null : new java.util.Date(cursor.getLong(offset + 8)), // dtm_upd
|
||||
cursor.isNull(offset + 9) ? null : cursor.getString(offset + 9) // uuid_timeline
|
||||
);
|
||||
return entity;
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public void readEntity(Cursor cursor, Comment entity, int offset) {
|
||||
entity.setUuid_comment(cursor.getString(offset + 0));
|
||||
entity.setComment(cursor.isNull(offset + 1) ? null : cursor.getString(offset + 1));
|
||||
entity.setDtm_crt_server(cursor.isNull(offset + 2) ? null : new java.util.Date(cursor.getLong(offset + 2)));
|
||||
entity.setSender_id(cursor.isNull(offset + 3) ? null : cursor.getString(offset + 3));
|
||||
entity.setSender_name(cursor.isNull(offset + 4) ? null : cursor.getString(offset + 4));
|
||||
entity.setUsr_crt(cursor.isNull(offset + 5) ? null : cursor.getString(offset + 5));
|
||||
entity.setDtm_crt(cursor.isNull(offset + 6) ? null : new java.util.Date(cursor.getLong(offset + 6)));
|
||||
entity.setUsr_upd(cursor.isNull(offset + 7) ? null : cursor.getString(offset + 7));
|
||||
entity.setDtm_upd(cursor.isNull(offset + 8) ? null : new java.util.Date(cursor.getLong(offset + 8)));
|
||||
entity.setUuid_timeline(cursor.isNull(offset + 9) ? null : cursor.getString(offset + 9));
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
protected String updateKeyAfterInsert(Comment entity, long rowId) {
|
||||
return entity.getUuid_comment();
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
public String getKey(Comment entity) {
|
||||
if(entity != null) {
|
||||
return entity.getUuid_comment();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/** @inheritdoc */
|
||||
@Override
|
||||
protected boolean isEntityUpdateable() {
|
||||
return true;
|
||||
}
|
||||
|
||||
/** Internal query to resolve the "commentList" to-many relationship of Timeline. */
|
||||
public List<Comment> _queryTimeline_CommentList(String uuid_timeline) {
|
||||
synchronized (this) {
|
||||
if (timeline_CommentListQuery == null) {
|
||||
QueryBuilder<Comment> queryBuilder = queryBuilder();
|
||||
queryBuilder.where(Properties.Uuid_timeline.eq(null));
|
||||
timeline_CommentListQuery = queryBuilder.build();
|
||||
}
|
||||
}
|
||||
Query<Comment> query = timeline_CommentListQuery.forCurrentThread();
|
||||
query.setParameter(0, uuid_timeline);
|
||||
return query.list();
|
||||
}
|
||||
|
||||
private String selectDeep;
|
||||
|
||||
protected String getSelectDeep() {
|
||||
if (selectDeep == null) {
|
||||
StringBuilder builder = new StringBuilder("SELECT ");
|
||||
SqlUtils.appendColumns(builder, "T", getAllColumns());
|
||||
builder.append(',');
|
||||
SqlUtils.appendColumns(builder, "T0", daoSession.getTimelineDao().getAllColumns());
|
||||
builder.append(" FROM TR_COMMENT T");
|
||||
builder.append(" LEFT JOIN TR_TIMELINE T0 ON T.\"UUID_TIMELINE\"=T0.\"UUID_TIMELINE\"");
|
||||
builder.append(' ');
|
||||
selectDeep = builder.toString();
|
||||
}
|
||||
return selectDeep;
|
||||
}
|
||||
|
||||
protected Comment loadCurrentDeep(Cursor cursor, boolean lock) {
|
||||
Comment entity = loadCurrent(cursor, 0, lock);
|
||||
int offset = getAllColumns().length;
|
||||
|
||||
Timeline timeline = loadCurrentOther(daoSession.getTimelineDao(), cursor, offset);
|
||||
entity.setTimeline(timeline);
|
||||
|
||||
return entity;
|
||||
}
|
||||
|
||||
public Comment loadDeep(Long key) {
|
||||
assertSinglePk();
|
||||
if (key == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
StringBuilder builder = new StringBuilder(getSelectDeep());
|
||||
builder.append("WHERE ");
|
||||
SqlUtils.appendColumnsEqValue(builder, "T", getPkColumns());
|
||||
String sql = builder.toString();
|
||||
|
||||
String[] keyArray = new String[] { key.toString() };
|
||||
Cursor cursor = db.rawQuery(sql, keyArray);
|
||||
|
||||
try {
|
||||
boolean available = cursor.moveToFirst();
|
||||
if (!available) {
|
||||
return null;
|
||||
} else if (!cursor.isLast()) {
|
||||
throw new IllegalStateException("Expected unique result, but count was " + cursor.getCount());
|
||||
}
|
||||
return loadCurrentDeep(cursor, true);
|
||||
} finally {
|
||||
cursor.close();
|
||||
}
|
||||
}
|
||||
|
||||
/** Reads all available rows from the given cursor and returns a list of new ImageTO objects. */
|
||||
public List<Comment> loadAllDeepFromCursor(Cursor cursor) {
|
||||
int count = cursor.getCount();
|
||||
List<Comment> list = new ArrayList<Comment>(count);
|
||||
|
||||
if (cursor.moveToFirst()) {
|
||||
if (identityScope != null) {
|
||||
identityScope.lock();
|
||||
identityScope.reserveRoom(count);
|
||||
}
|
||||
try {
|
||||
do {
|
||||
list.add(loadCurrentDeep(cursor, false));
|
||||
} while (cursor.moveToNext());
|
||||
} finally {
|
||||
if (identityScope != null) {
|
||||
identityScope.unlock();
|
||||
}
|
||||
}
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
protected List<Comment> loadDeepAllAndCloseCursor(Cursor cursor) {
|
||||
try {
|
||||
return loadAllDeepFromCursor(cursor);
|
||||
} finally {
|
||||
cursor.close();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/** A raw-style query where you can pass any WHERE clause and arguments. */
|
||||
public List<Comment> queryDeep(String where, String... selectionArg) {
|
||||
Cursor cursor = db.rawQuery(getSelectDeep() + where, selectionArg);
|
||||
return loadDeepAllAndCloseCursor(cursor);
|
||||
}
|
||||
|
||||
}
|
|
@ -0,0 +1,52 @@
|
|||
package com.adins.mss.coll.models;
|
||||
|
||||
import com.adins.mss.foundation.http.MssResponseType;
|
||||
import com.google.gson.annotations.SerializedName;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by adityapurwa on 20/03/15.
|
||||
*/
|
||||
public class PaymentHistoryResponse extends MssResponseType {
|
||||
@SerializedName("agreementNo")
|
||||
private String agreementNo;
|
||||
@SerializedName("paymentHistoryHList")
|
||||
private List<PaymentHistoryHBean> paymentHistoryHList;
|
||||
|
||||
public String getAgreementNo() {
|
||||
return agreementNo;
|
||||
}
|
||||
|
||||
public void setAgreementNo(String agreementNo) {
|
||||
this.agreementNo = agreementNo;
|
||||
}
|
||||
|
||||
public List<PaymentHistoryHBean> getPaymentHistoryHList() {
|
||||
return paymentHistoryHList;
|
||||
}
|
||||
|
||||
public void setPaymentHistoryHList(List<PaymentHistoryHBean> paymentHistoryHList) {
|
||||
this.paymentHistoryHList = paymentHistoryHList;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// public List<PaymentHistoryResponseHeader> getPaymentHistoryHList() {
|
||||
// return paymentHistoryHList;
|
||||
// }
|
||||
//
|
||||
// public void setPaymentHistoryHList(List<PaymentHistoryResponseHeader> paymentHistoryHList) {
|
||||
// this.paymentHistoryHList = paymentHistoryHList;
|
||||
// }
|
||||
//
|
||||
// public List<PaymentHistoryResponseDetail> getPaymentHistoryDList() {
|
||||
// return paymentHistoryDList;
|
||||
// }
|
||||
//
|
||||
// public void setPaymentHistoryDList(List<PaymentHistoryResponseDetail> paymentHistoryDList) {
|
||||
// this.paymentHistoryDList = paymentHistoryDList;
|
||||
// }
|
||||
|
||||
|
||||
}
|
|
@ -0,0 +1,72 @@
|
|||
package com.adins.mss.foundation.dialog.gitonway.lib;
|
||||
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.BaseEffects;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.FadeIn;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.Fall;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.FlipH;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.FlipV;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.NewsPaper;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.RotateBottom;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.RotateLeft;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.Shake;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.SideFall;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.SlideBottom;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.SlideLeft;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.SlideRight;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.SlideTop;
|
||||
import com.adins.mss.foundation.dialog.gitonway.lib.effects.Slit;
|
||||
|
||||
/*
|
||||
* Copyright 2014 litao
|
||||
* https://github.com/sd6352051/NiftyDialogEffects
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
public enum Effectstype {
|
||||
|
||||
Fadein(FadeIn.class),
|
||||
Slideleft(SlideLeft.class),
|
||||
Slidetop(SlideTop.class),
|
||||
SlideBottom(SlideBottom.class),
|
||||
Slideright(SlideRight.class),
|
||||
Fall(Fall.class),
|
||||
Newspager(NewsPaper.class),
|
||||
Fliph(FlipH.class),
|
||||
Flipv(FlipV.class),
|
||||
RotateBottom(RotateBottom.class),
|
||||
RotateLeft(RotateLeft.class),
|
||||
Slit(Slit.class),
|
||||
Shake(Shake.class),
|
||||
Sidefill(SideFall.class);
|
||||
private Class<? extends BaseEffects> effectsClazz;
|
||||
|
||||
private Effectstype(Class<? extends BaseEffects> mclass) {
|
||||
effectsClazz = mclass;
|
||||
}
|
||||
|
||||
public BaseEffects getAnimator() {
|
||||
BaseEffects bEffects = null;
|
||||
try {
|
||||
bEffects = effectsClazz.newInstance();
|
||||
} catch (ClassCastException e) {
|
||||
throw new Error("Can not init animatorClazz instance");
|
||||
} catch (InstantiationException e) {
|
||||
// TODO Auto-generated catch block
|
||||
throw new Error("Can not init animatorClazz instance");
|
||||
} catch (IllegalAccessException e) {
|
||||
// TODO Auto-generated catch block
|
||||
throw new Error("Can not init animatorClazz instance");
|
||||
}
|
||||
return bEffects;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.manuelpeinado.fadingactionbar.view.RootLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" >
|
||||
|
||||
<include layout="@layout/fab__header_container" />
|
||||
|
||||
<View
|
||||
android:layout_gravity="top"
|
||||
android:id="@+id/fab__listview_background"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@android:color/background_light" />
|
||||
|
||||
</com.manuelpeinado.fadingactionbar.view.RootLayout>
|
|
@ -0,0 +1,257 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:id="@+id/main_activity"
|
||||
android:background="@color/bgColor">
|
||||
<androidx.appcompat.widget.Toolbar
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="?android:attr/actionBarSize"
|
||||
android:background="@drawable/header"
|
||||
app:titleTextAppearance="?android:attr/textAppearanceSmall"
|
||||
android:titleTextColor="@color/fontColorWhite"
|
||||
app:popupTheme="@style/ThemeOverlay.AppCompat.ActionBar"
|
||||
android:fitsSystemWindows="true"/>
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:id="@+id/depositSummaryContainer"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentTop="true"
|
||||
app:cardCornerRadius="10dp"
|
||||
app:contentPadding="7dp"
|
||||
app:cardElevation="@dimen/card_shadow"
|
||||
android:layout_marginTop="@dimen/card_margin"
|
||||
android:layout_marginLeft="@dimen/card_margin"
|
||||
android:layout_marginRight="@dimen/card_margin"
|
||||
android:layout_marginBottom="70dp"
|
||||
app:cardBackgroundColor="@color/fontColorWhite">
|
||||
|
||||
<ScrollView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
<TableLayout
|
||||
android:id="@+id/tableLayout1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/rowBatchId"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="5dp" >
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_batch_id"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/divider2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txtBatchId"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_batch_id"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/rowTransferBy"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="5dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView3"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_transfer_by"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/divider3"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txttransferBy"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_bank"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/rowCashierName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="5dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView4"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_cashier_name"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/divider4"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txtCashierName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_cashier_name"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/rowAccountNumber"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="5dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView5"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_account_number"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/divider5"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txtAccountNumber"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/dummy_number"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/rowBankName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="5dp" >
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView6"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_bank_name"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/divider6"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/txtBankName"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_bank_name"/>
|
||||
</TableRow>
|
||||
|
||||
<TableRow
|
||||
android:id="@+id/rowEvidenceTransfer"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingBottom="5dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/label_transfer_evidence"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/divider"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/imgEvidenceTransfer"
|
||||
android:layout_width="120dp"
|
||||
android:layout_height="120dp"
|
||||
android:layout_weight="0.25"
|
||||
android:scaleType="fitStart"
|
||||
android:src="@drawable/profile_image" />
|
||||
</TableRow>
|
||||
<TableRow>
|
||||
<TextView />
|
||||
</TableRow>
|
||||
<TableRow>
|
||||
<TextView
|
||||
android:id="@+id/lblTotal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:text="@string/total"/>
|
||||
<TextView
|
||||
android:id="@+id/divider7"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.1"
|
||||
android:text="@string/divider_colon"/>
|
||||
<TextView
|
||||
android:id="@+id/txtTotal"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="0.25"
|
||||
android:gravity="end"
|
||||
android:text="@string/total"/>
|
||||
</TableRow>
|
||||
<TableRow>
|
||||
<TextView />
|
||||
</TableRow>
|
||||
</TableLayout>
|
||||
</ScrollView>
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/btnPrintDepReport"
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:layout_margin="5dp"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:background="@android:color/transparent"
|
||||
android:elevation="10dp"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/icon_print" />
|
||||
</RelativeLayout>
|
||||
</LinearLayout>
|
|
@ -0,0 +1,167 @@
|
|||
package com.adins.mss.base.receipt;
|
||||
|
||||
import android.graphics.Canvas;
|
||||
import android.graphics.Paint;
|
||||
import android.graphics.Typeface;
|
||||
|
||||
/**
|
||||
* Created by Loise on 12/04/2018.
|
||||
*/
|
||||
|
||||
/**
|
||||
* menggambar teks pada canvas
|
||||
*/
|
||||
public class DrawText implements IDrawItem {
|
||||
private Paint paint = new Paint();
|
||||
private String text;
|
||||
private boolean newLine;
|
||||
|
||||
/**
|
||||
* konstruktor
|
||||
* @param text teks yang akan digambar
|
||||
*/
|
||||
public DrawText(String text) {
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
/**
|
||||
* menggambarkan teks pada canvas
|
||||
* @param canvas
|
||||
* @param x
|
||||
* @param y
|
||||
*/
|
||||
@Override
|
||||
public void drawOnCanvas(Canvas canvas, float x, float y) {
|
||||
canvas.drawText(text, getX(canvas, x), getY(y), paint);
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan titik awal pada sumbu y
|
||||
* @param y
|
||||
* @return
|
||||
*/
|
||||
private float getY(float y) {
|
||||
float baseline = -paint.ascent();
|
||||
return baseline + y;
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan titik awal pada sumbu x
|
||||
* @param canvas
|
||||
* @param x
|
||||
* @return
|
||||
*/
|
||||
private float getX(Canvas canvas, float x) {
|
||||
float xPos = x;
|
||||
if (paint.getTextAlign().equals(Paint.Align.CENTER)) {
|
||||
xPos = ((float)canvas.getWidth() / 2);
|
||||
} else if (paint.getTextAlign().equals(Paint.Align.RIGHT)) {
|
||||
xPos = canvas.getWidth();
|
||||
}
|
||||
return xPos;
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan tinggi objek teks
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public int getHeight() {
|
||||
return (newLine ? (int) getTextSize() : 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan teks
|
||||
* @return
|
||||
*/
|
||||
public String getText() {
|
||||
return text;
|
||||
}
|
||||
|
||||
/**
|
||||
* setter teks
|
||||
* @param text
|
||||
*/
|
||||
public void setText(String text) {
|
||||
this.text = text;
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan warna teks
|
||||
* @return
|
||||
*/
|
||||
public int getColor() {
|
||||
return paint.getColor();
|
||||
}
|
||||
|
||||
/**
|
||||
* mengubah warna teks
|
||||
* @param color
|
||||
*/
|
||||
public void setColor(int color) {
|
||||
paint.setColor(color);
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan ukuran teks
|
||||
* @return
|
||||
*/
|
||||
public float getTextSize() {
|
||||
return paint.getTextSize();
|
||||
}
|
||||
|
||||
/**
|
||||
* mengubah ukuran teks
|
||||
* @param textSize
|
||||
*/
|
||||
public void setTextSize(float textSize) {
|
||||
paint.setTextSize(textSize);
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan font teks
|
||||
*/
|
||||
public void getTypeface() {
|
||||
paint.getTypeface();
|
||||
}
|
||||
|
||||
/**
|
||||
* mengubah font teks
|
||||
* @param typeface Typeface
|
||||
*/
|
||||
public void setTypeface(Typeface typeface) {
|
||||
paint.setTypeface(typeface);
|
||||
}
|
||||
|
||||
/**
|
||||
* mengubah akignment teks
|
||||
* @param align
|
||||
*/
|
||||
public void setAlign(Paint.Align align) {
|
||||
paint.setTextAlign(align);
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan alignment teks
|
||||
* @return
|
||||
*/
|
||||
public Paint.Align getAlign() {
|
||||
return paint.getTextAlign();
|
||||
}
|
||||
|
||||
/**
|
||||
* menentukan apakah teks akan pindah baris atau tidak
|
||||
* @param newLine
|
||||
*/
|
||||
public void setNewLine(boolean newLine) {
|
||||
this.newLine = newLine;
|
||||
}
|
||||
|
||||
/**
|
||||
* mengembalikan status teks pindah baris atau tidak
|
||||
* @return
|
||||
*/
|
||||
public boolean getNewLine() {
|
||||
return newLine;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,18 @@
|
|||
package com.adins.mss.base.tasklog;
|
||||
|
||||
import com.adins.mss.base.commons.TaskListener;
|
||||
import com.adins.mss.dao.TaskH;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by kusnendi.muhamad on 28/07/2017.
|
||||
*/
|
||||
|
||||
public interface TaskLogInterface {
|
||||
public List<TaskH> getListTaskLog();
|
||||
|
||||
public void callOnlineLog(TaskListener listener);
|
||||
|
||||
public void cancelOnlineLog();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue