This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for (int k = 0; k < mOrder.getTmxOrderLine().size(); k++) { | |
Orderline mOrderLine = mOrder.getTmxOrderLine().get(k); | |
//match by product master id | |
if (mOrderLine.getProductMasterId().intValue() == mProduct.getSchemeProductMasterId().intValue()) { | |
quantityRequiredInOrder += mOrderLine.getOrderQuantity(); | |
} | |
else | |
{ | |
//this block will be used to compare productMasterId with child brand and its parent brand |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static List<CustomerDailyStockData> getCustomerStockDataByCustomerId(int customerMasterId) { | |
Realm realm = Realm.getDefaultInstance(); | |
RealmResults<CustomerDailyStockData> stockDatas = realm.where(CustomerDailyStockData.class).equalTo(CustomerDailyStockData.CUSTOMER_MASTER_ID, customerMasterId).findAll(); | |
if (stockDatas != null) { | |
List<CustomerDailyStockData> stockDatasList = (List<CustomerDailyStockData>) realm.copyFromRealm(stockDatas); | |
return stockDatasList; | |
} | |
return null; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://tlx-sd.azurewebsites.net/qa-api/api/v1/CustomerDailyStock/CreateMultiple | |
[ | |
{ | |
"AvailableStock": 1, | |
"CreatedBy": "", | |
"CreatedDate": "2018-06-12 23:42:01", | |
"CustomerDailyStockId": 0, | |
"CustomerMasterId": 12417, | |
"PJPClusterId": 281343, | |
"ProductId": 177, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
E/MediaPlayer: start called in state 2 | |
01-02 12:12:49.970 16745-16745/com.abc.package E/MediaPlayer: error (-38, 0) | |
01-02 12:12:51.181 16745-16745/com.abc.package E/MediaPlayer: prepareAsync called in state 0 | |
01-02 12:12:51.181 16745-16745/com.abc.package E/com.abc.package.activities.detail.AudioDetailActivity: illegal state exception | |
01-02 12:12:51.181 16745-16745/com.abc.package W/System.err: java.lang.IllegalStateException | |
01-02 12:12:51.191 16745-16745/com.abc.package W/System.err: at android.media.MediaPlayer.prepare(Native Method) | |
01-02 12:12:51.191 16745-16745/com.abc.package W/System.err: at com.abc.package.activities.detail.AudioDetailActivity.playAudio(AudioDetailActivity.java:506) | |
01-02 12:12:51.191 16745-16745/com.abc.package W/System.err: at com.abc.package.activities.detail.AudioDetailActivity$2.onClick(AudioDetailActivity.java:206) | |
01-02 12:12:51.201 16745-16745/com.abc.package W/System.err: at android.view.View.performClick(View.java:4753) | |
01-02 12:12:51.201 16745-16745/com.abc |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void playAudio() { | |
if (mediaPlayer == null) { | |
mediaPlayer = new MediaPlayer(); | |
} | |
if (!TextUtils.isEmpty(mediaFileUrl)) { | |
try { | |
mediaPlayer.reset(); | |
mediaPlayer.setDataSource(mediaFileUrl); | |
mediaPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"2EjddfdfdfdfdfdfKLH": { | |
"edition": 1, | |
"language": "ap,sp,ai", | |
"is_public": true | |
} | |
}, | |
{ | |
"2dldfdfdfdfdfVzqE": { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static FailureResponse getErrorMessage(String responseString) { | |
Log.d(Utils.class.getName(),"responseString:"+responseString); | |
JsonParser parser = new JsonParser(); | |
JsonElement mJson = null; | |
mJson = parser.parse(responseString); | |
Gson gson = new Gson(); | |
FailureResponse failureResponse = gson.fromJson(mJson, FailureResponse.class); | |
return failureResponse; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// when i m updating language so its continously launching activity ... how will i resolve this issue ? | |
private void updateLanguageBasedOnLocalStorage() { | |
languageSelection = SharedPreferencesManager.getSharedPreferenceInstance(context).getSharedPreferenceString(context, getString(R.string.str_language)); | |
if (TextUtils.isEmpty(languageSelection)) { | |
languageSelection = getString(R.string.str_en); | |
} | |
setLocal(languageSelection); | |
} | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void PlayAudio() { | |
if (mediaPlayer == null) { | |
mediaPlayer = new MediaPlayer(); | |
} | |
if (!TextUtils.isEmpty(mediaFileUrl)) { | |
try { | |
mediaPlayer.reset(); | |
mediaPlayer.setDataSource(mediaFileUrl); | |
mediaPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
playAudio(); | |
ivActionPlayVideo.setOnClickListener(new View.OnClickListener() { | |
@Override | |
public void onClick(View view) { | |
if (mediaType == 1) { | |
if (!mediaPlayer.isPlaying()) { | |
videoView.setVisibility(View.INVISIBLE); | |
ivViewTracker.setVisibility(View.VISIBLE); |
NewerOlder