Skip to content

Commit

Permalink
Issue #SB-000 merge: Merge pull request #3501 from shikshalokam/relea…
Browse files Browse the repository at this point in the history
…se-5.1.0.10

Release 5.1.0.10
  • Loading branch information
swayangjit authored Oct 13, 2023
2 parents 9698f8d + 0cb034e commit 56fbd71
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 18 deletions.
8 changes: 4 additions & 4 deletions build_config
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ cordova-plugin=cordova-plugin-x-socialsharing
cordova-plugin=cordova-plugin-androidx-adapter
cordova-plugin=cordova-plugin-device
cordova-plugin=cordova-plugin-file
cordova-plugin=https://github.com/vishwanath1004/cordova-plugin-file-transfer
cordova-plugin=https://github.com/shikshalokam/cordova-plugin-file-transfer.git
cordova-plugin=cordova-plugin-inappbrowser
cordova-plugin=cordova-plugin-network-information
cordova-plugin=cordova-plugin-statusbar
Expand All @@ -20,20 +20,20 @@ cordova-plugin=cordova-plugin-android-permissions
cordova-plugin=cordova.plugins.diagnostic
cordova-plugin=com.telerik.plugins.nativepagetransitions
cordova-plugin=cordova-plugin-secure-storage-echo
cordova-plugin=cordova-plugin-chooser
cordova-plugin=https://github.com/shikshalokam/cordova-plugin-chooser.git
cordova-plugin=cordova-plugin-appavailability
cordova-plugin=cordova-plugin-filepicker
cordova-plugin=cordova-plugin-document-viewer
cordova-plugin=com-sarriaroman-photoviewer
cordova-plugin=https://github.com/vishwanath1004/cordova-plugin-filepath.git
cordova-plugin=https://github.com/shikshalokam/cordova-plugin-filepath.git
cordova-plugin=https://github.com/greybax/cordova-plugin-proguard.git
cordova-plugin=https://github.com/Sunbird-Ed/sb-cordova-plugin-utility.git#release-4.1.0
cordova-plugin=https://github.com/Sunbird-Ed/sb-cordova-plugin-downloadmanager.git
cordova-plugin=https://github.com/Sunbird-Ed/sb-cordova-plugin-db.git#release-4.6.0
cordova-plugin=https://github.com/Sunbird-Ed/sb-cordova-plugin-customtabs.git#release-5.0.2 --variable URL_SCHEME=@string/custom_scheme_url --variable URL_HOST=mobile
cordova-plugin=cordova-sqlite-storage
cordova plugin=cordova-plugin-googleplus
cordova-plugin=https://github.com/vishwanath1004/cordova-plugin-camera.git
cordova-plugin=https://github.com/shikshalokam/cordova-plugin-camera.git
[email protected]
cordova-plugin=cordova-plugin-filechooser
cordova-plugin=cordova-plugin-media
Expand Down
10 changes: 5 additions & 5 deletions src/app/home/user-home/user-home.page.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,7 @@ describe('UserHomePage', () => {
'ekstep_ncert_k-12': {
teacher: [
{
name: 'observation',
name: 'observations',
icon: {
web: 'assets/images/mask-image/observation_category.png',
app: 'assets/imgs/observation_category.png',
Expand All @@ -522,7 +522,7 @@ describe('UserHomePage', () => {
'CBSE': {
teacher: [
{
name: 'observation',
name: 'observations',
icon: {
web: 'assets/images/mask-image/observation_category.png',
app: 'assets/imgs/observation_category.png',
Expand Down Expand Up @@ -586,7 +586,7 @@ describe('UserHomePage', () => {
'CBSE': {
teacher: [
{
name: 'observation',
name: 'observations',
icon: {
web: 'assets/images/mask-image/observation_category.png',
app: 'assets/imgs/observation_category.png',
Expand Down Expand Up @@ -618,7 +618,7 @@ describe('UserHomePage', () => {
describe('should handle click action of otherCategories', () => {
it('should show login prompt', (done) => {
userHomePage.guestUser = true;
let event = { data: [{ value: {name:'observation'} }] };
let event = { data: [{ value: {name:'observations'} }] };
mockPopoverController.create = jest.fn(() =>
Promise.resolve({
present: jest.fn(() => Promise.resolve({})),
Expand All @@ -636,7 +636,7 @@ describe('UserHomePage', () => {

it('should navigate to observation listing page', (done) => {
userHomePage.guestUser = false;
let event = { data: [{ value: {name:'observation'} }] };
let event = { data: [{ value: {name:'observations'} }] };
mockPopoverController.create = jest.fn(() =>
Promise.resolve({
present: jest.fn(() => Promise.resolve({})),
Expand Down
11 changes: 9 additions & 2 deletions src/app/manage-learn/core/constants/actions.constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,16 @@ export const actions = {
id:'camera'
},
{
title: "FRMELEMNTS_LBL_GALLERY",
title: "FRMELEMENTS_LBL_UPLOAD_IMAGE",
icon: "images",
action: "openGallery",
action: "openImage",
color: 'primary',
id:'images'
},
{
title: "FRMELEMENTS_LBL_UPLOAD_VIDEO",
icon: "videocam",
action: "openVideo",
color: 'primary',
id:'images'
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,6 @@ export class AttachmentService {
text: this.texts["FRMELEMENTS_LBL_UPLOAD_FILE"],
icon: "document",
handler: () => {
// this.openAllFile()
this.openFile();
return false;
},
Expand Down Expand Up @@ -273,8 +272,8 @@ export class AttachmentService {
const file = await this.chooser.getFile('application/pdf');
let sizeOftheFile: number = file.data.length
if (sizeOftheFile > localStorageConstants.FILE_LIMIT) {
this.actionSheetController.dismiss();
this.presentToast(this.texts["FRMELEMNTS_MSG_ERROR_FILE_SIZE_LIMIT"]);
this.presentToast(this.texts["FRMELEMNTS_LBL_FILE_SIZE_EXCEEDED"]);
this.actionSheetOpen ? this.actionSheetController.dismiss() :'';
} else {
const pathToWrite = path ? path :this.directoryPath();
const newFileName = this.createFileName(file.name)
Expand All @@ -292,7 +291,11 @@ export class AttachmentService {
}

} catch (error) {
this.presentToast(this.texts["FRMELEMNTS_MSG_ERROR_WHILE_STORING_FILE"]);
if(error == "OutOfMemory"){
this.presentToast(this.texts["FRMELEMNTS_LBL_FILE_SIZE_EXCEEDED"]);
}else{
this.presentToast(this.texts["FRMELEMNTS_MSG_ERROR_WHILE_STORING_FILE"]);
}
}
}

Expand Down Expand Up @@ -342,6 +345,12 @@ export class AttachmentService {
case 'openGallery':
this.takePicture(this.camera.PictureSourceType.PHOTOLIBRARY);
break;
case 'openImage':
this.takePicture(this.camera.PictureSourceType.PHOTOLIBRARY, this.camera.MediaType.PICTURE);
break;
case 'openVideo':
this.takePicture(this.camera.PictureSourceType.PHOTOLIBRARY, this.camera.MediaType.VIDEO);
break;
case 'openFiles':
this.openFile();
break;
Expand Down
6 changes: 3 additions & 3 deletions src/assets/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -1021,9 +1021,9 @@
"FRMELEMENTS_LBL_FILES": "Files",
"FRMELEMENTS_LBL_ADD_IMAGE": "Add images",
"FRMELEMENTS_LBL_CAMERA": "Camera",
"FRMELEMENTS_LBL_UPLOAD_FILE": "Upload file",
"FRMELEMENTS_LBL_UPLOAD_IMAGE": "Upload image",
"FRMELEMENTS_LBL_UPLOAD_VIDEO":"Upload video",
"FRMELEMENTS_LBL_UPLOAD_FILE": "File",
"FRMELEMENTS_LBL_UPLOAD_IMAGE": "Image",
"FRMELEMENTS_LBL_UPLOAD_VIDEO":"Video",
"FRMELEMENTS_LBL_DATE": "Date",
"FRMELEMENTS_LBL_CAPTURE": "Capture",
"FRMELEMNTS_LBL_ENTITIES": "Entities",
Expand Down

0 comments on commit 56fbd71

Please sign in to comment.