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
function addMoneyToWallet(userDataTransactionsOrderId, data) { | |
let serviceFeeCal = Math.ceil(parseInt(data.data().amountToPay.toString()) * 0.05) | |
let netAmount = parseInt(data.data().amountToPay.toString()) - serviceFeeCal | |
console.log(`WALLET -------------------${serviceFeeCal} -- ${netAmount} - ${JSON.stringify(data.data())}`) | |
admin.firestore().collection("wallet").doc(data.data().recepientId.toString()).collection("transactions").add( | |
{ | |
tenancyTransactionId: userDataTransactionsOrderId, | |
date: data.data().payedDate, | |
hash: "Genesis", | |
prevHash: "PrevHash", |
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
/* | |
Author : Eng.Muli Eric | |
Project : The Epistles Fellowhip Mobile App | |
Platform : Mobile Application | |
Technology : Flutter | |
Target : Android And IoS Os | |
Date : Fri May 31 st 23:18:45 | |
Page Title : Login Section | |
*/ |
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
///////////////////////////////////////////////////DIO////////////////////////////////////// | |
////////////////HEADERs | |
dio.options.headers = {'Content-Type': 'application/x-www-form-urlencoded'}; | |
//code | |
File _image; | |
String fileName = | |
_image.path.split('/').last; | |
FormData formData = | |
new FormData.fromMap({ | |
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
import 'dart:io'; | |
import 'package:cloud_firestore/cloud_firestore.dart'; | |
import 'package:country_code_picker/country_code_picker.dart'; | |
import 'package:firebase_storage/firebase_storage.dart'; | |
import 'package:flutter/material.dart'; | |
import 'package:font_awesome_flutter/font_awesome_flutter.dart'; | |
import 'package:image_picker/image_picker.dart'; | |
//import 'package:flutter_image_compress/flutter_image_compress.dart'; | |
//import 'package:image_cropper/image_cropper.dart'; |
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
import 'dart:io'; | |
import 'package:cloud_firestore/cloud_firestore.dart'; | |
import 'package:country_code_picker/country_code_picker.dart'; | |
import 'package:device_info/device_info.dart'; | |
import 'package:firebase_messaging/firebase_messaging.dart'; | |
import 'package:firebase_storage/firebase_storage.dart'; | |
import 'package:flutter/cupertino.dart'; | |
import 'package:flutter/material.dart'; | |
import 'package:flutter_image_compress/flutter_image_compress.dart'; |
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
/* | |
Author : Eng.Muli Eric | |
Project : The Epistles Fellowhip Mobile App | |
Platform : Mobile Application | |
Technology : Flutter | |
Target : Android And IoS Os | |
Date : Mon May 27th 2019 22:34:30 | |
Page Title : Home Page | |
*/ |
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
Future<void> updateData(data) async { | |
print('function add data called'); | |
Firestore.instance | |
.collection('users') | |
.document(widget.uid) | |
.updateData(data) | |
.then((result) { | |
print("data added ..................................... "); | |
// print(result); | |
}).catchError((e) { |
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
class VideoCallPerosnalScreen extends StatefulWidget { | |
/// non-modifiable channel name of the page | |
final String channelName; | |
final String callerid; | |
final String receiverid; | |
/// Creates a call page with given channel name. | |
const VideoCallPerosnalScreen( |
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
Future getVideo() async { | |
setState(() { | |
video = null; | |
thumbfilepath = null; | |
}); | |
setState(() { | |
messageid = DateTime.now().millisecondsSinceEpoch.toString(); | |
}); | |
var vinput = await ImagePicker.pickVideo(source: ImageSource.gallery); | |
final uint8list = await VideoThumbnail.thumbnailFile( |
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
/////////////////////////////////////////////////////////////////////EXTRACTED SHORT SNIPPETS Garage Idea from properties snippet //////////////////////////////// | |
//////////////////////////////////////////////MAPS SCREEN | |
////Suggests garages within a given radius from users loactions | |
List gdata = []; | |
List searchedGarage = []; | |
///In this block i receive my data from fireabse garage collections then regeneate a list containig my garage ,then i | |
//their ids within each garage's MAP ( |
NewerOlder