?>

DEAR Inventory + Firebase Realtime Database Integrations

Appy Pie Connect allows you to automate multiple workflows between DEAR Inventory and Firebase Realtime Database

About DEAR Inventory

DEAR Inventory is a cloud-based, inventory and order management application for SMBs. It combines an easy to use interface with powerful reporting and data analysis tools.

About Firebase Realtime Database

Realtime Database Stores and sync app data in milliseconds

Firebase Realtime Database Integrations
Firebase Realtime Database Alternatives

Connect the apps you use everyday and find your productivity super-powers.

  • Caspio Cloud Database Caspio Cloud Database
  • MySQL MySQL
  • RethinkDB RethinkDB

Best DEAR Inventory and Firebase Realtime Database Integrations

  • DEAR Inventory Salesforce

    DEAR Inventory + Salesforce

    Add DEAR Inventory customers to Salesforce as new contacts Read More...
    When this happens...
    DEAR Inventory New Customer OR Updated Customer
     
    Then do this...
    Salesforce Create Record
    Maintain the accuracy of your customer datasets in your CRM and inventory management software. When a new customer is added to the DEAR Inventory, create a matching record in Salesforce so lead information can be sent directly to sales reps for follow up. Once active, this integration will automatically create a new contact in Salesforce for every new DEAR customer. This integration is perfect if you want to create your own personalized workflow of Salesforce data.
    How This DEAR - Salesforce Integration Works
    • A new customer is added to DEAR
    • Appy Pie Connect adds a new contact to Salesforce
    What You Need
    • DEAR account
    • Salesforce account
  • DEAR Inventory Salesforce

    {{item.triggerAppName}} + {{item.actionAppName}}

    {{item.message}} Read More...
    When this happens...
    DEAR Inventory {{item.triggerTitle}}
     
    Then do this...
    {{item.actionAppImage}} {{item.actionTitle}}
Connect DEAR Inventory + Firebase Realtime Database in easier way

It's easy to connect DEAR Inventory + Firebase Realtime Database without coding knowledge. Start creating your own business flow.

    Triggers
  • New Customer OR Updated Customer

    Triggered when customers are created or updated.

  • Edit or Updated Child Object in Firebase Realtime Database

    Triggers on updation of a child object in firebase realtime database.

  • New Child Object in a Firebase Realtime Database

    New Child Object in a Firebase Realtime Database

    Actions
  • Create Invoice

    Create Sales Invoice

  • Create Sale

    Create a new sale.

  • Create Sale Order

    Create Sales order.

  • Create Sale Quote

    Creates a sales quote.

  • Create or Replace Firebase Realtime Database Record

    Creates or replaces a child object within your Firebase Realtime Database.

How DEAR Inventory & Firebase Realtime Database Integrations Work

  1. Step 1: Choose DEAR Inventory as a trigger app and Select "Trigger" from the Triggers List.

    (30 seconds)

  2. Step 2: Authenticate DEAR Inventory with Appy Pie Connect.

    (10 seconds)

  3. Step 3: Select Firebase Realtime Database as an action app.

    (30 seconds)

  4. Step 4: Pick desired action for the selected trigger.

    (10 seconds)

  5. Step 5: Authenticate Firebase Realtime Database with Appy Pie Connect.

    (2 minutes)

  6. Your Connect is ready! It's time to start enjoying the benefits of workflow automation.

Integration of DEAR Inventory and Firebase Realtime Database

DEAR Inventory is a free Android library to save date to Firebase Realtime Database. This article will present how to use DEAR Inventory and Firebase Realtime Database together, and what are the benefits of them.

DEAR Inventory?

DEAR Inventory is an open source library for Android apps for saving data to Firebase Realtime Database. It’s designed in a way that users can easily integrate it into their apps. DEAR Inventory allows users to save a lot of data quickly, without worrying about the database performance. It supports both single and complex data models. The most important feature of DEAR Inventory is that it can be integrated with any existing app without changing the existing code.

Firebase Realtime Database?

Firebase Realtime Database is a cloud-hosted NoSQL database. It enables users to store and sync their data across the web easily. Users can add to or update their data at any time. Firebase Realtime Database also provides powerful security mechanisms to keep your data safe and secure on Google’s infrastructure. And it’s not only realtime, but it’s also very scalable, low latency, and high performance, even for large datasets.

Integration of DEAR Inventory and Firebase Realtime Database

To integrate DEAR Inventory with Firebase Realtime Database, the first step is to create an account in Firebase Conspe. After creating an account, confirm your email address by clicking the link sent to you by Google. Then, create a new project in Firebase Conspe.

Then, download the DEAR Inventory library via Gradle and add it to your app’s build.gradle file as shown below:

dependencies{ compile 'com.tyang1221:dear-inventory:0.8.1' //... } 1 2 3 4 dependencies { compile 'com.tyang1221:dear-inventory:0.8.1' //... }

After adding DEAR Inventory to your app’s build.gradle file, open AppComponent class and add the fplowing variables:

private lateinit var dbRealm. RealmRealm private lateinit var refDb. DatabaseReference private lateinit var dbDeletedItem. DeleteApiService 1 2 3 4 private lateinit var dbRealm . RealmRealm private lateinit var refDb . DatabaseReference private lateinit var dbDeletedItem . DeleteApiService

The first variable dbRealm is used for connecting the DEAR Inventory library with Firebase Realtime Database. The second variable refDb is used for getting reference to a database object from Firebase Realtime Database. And the third variable dbDeletedItem is used for deleting items from Firebase Realtime Database when they are deleted from local database using DEAR Inventory library. The above three variables are created in OnCreate(. method, as shown below:

override fun onCreate(savedInstanceState. Bundle?. { super.onCreate(savedInstanceState. dbRealm = Realm(. dbRealm.scheme = "realm_database" dbRealm.path = "MyDatabase" refDb = FirebaseDatabase.getInstance(.reference(. } 1 2 3 4 5 6 7 8 override fun onCreate ( savedInstanceState . Bundle ? . { super . onCreate ( savedInstanceState . dbRealm = Realm ( . dbRealm . scheme = "realm_database" dbRealm . path = "MyDatabase" refDb = FirebaseDatabase . getInstance ( . . reference ( . }

Then, add the fplowing method in OnCreate(. method called initDB():

private fun initDB(. { dbDeletedItem = DeleteApiService(this. // TODO(yunxiao. Create a database reference to realtime database // TODO(yunxiao. Register the database reference with Firebase // TODO(yunxiao. Set up the database's security rules so that only this app can write to it // TODO(yunxiao. Add tables to the database // TODO(yunxiao. Initialize update listeners } 1 2 3 4 5 6 7 8 9 10 11 12 private fun initDB ( . { dbDeletedItem = DeleteApiService ( this . // TODO(yunxiao. Create a database reference to realtime database // TODO(yunxiao. Register the database reference with Firebase // TODO(yunxiao. Set up the database's security rules so that only this app can write to it // TODO(yunxiao. Add tables to the database // TODO(yunxiao. Initialize update listeners }

In this example, we create an instance of DeleteApiService using “this” keyword, which means that we are using Android’s Context object in this case. Then, we have a bunch of TODO statements which means there are still some work that need to be completed before using DEAR Inventory library with Firebase Realtime Database. We will fix them later in this article. For now, we will skip them because they are too advanced for beginners like us who are just learning Android development and we don’t want to make things complex for beginners like us who are just learning Android development and ready to learn how we can use DEAR Inventory library with Firebase Realtime Database. So let’s move on to writing a simple “Hello World!” application using DEAR Inventory library before doing anything else. 😉

Now that you have installed DEAR Inventory library into your project, let’s write some code to see it in action! First, open your activity_mainlayout.xml file located under res => layout fpder, then add the fplowing code:

<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tops="http://schemas.android.com/tops" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" tops:context=".MainActivity"> <Button android:id="@+id/btnAdd" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Add Item" /> <Button android:id="@+id/btnDelete" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Delete Item" /> </LinearLayout> 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 < LinearLayout xmlns . android = "http://schemas.android.com/apk/res/android" xmlns . tops = "http://schemas.android.com/tops" android . layout_width = "match_parent" android . layout_height = "match_parent" android . orientation = "vertical" tops . context = ".MainActivity" > < Button android . id = "@+id/btnAdd" android . layout_width = "wrap_content" android . layout_height = "wrap_content" android . text = "Add Item" / > < Button android . id = "@+id/btnDelete" android . layout_width = "wrap_content" android . layout_height = "wrap_content" android . text = "Delete Item" / > < / LinearLayout >

Next, open your MainActivity class located under app => java => package => com => tyang1221 => mainactivity fpder, then add the fplowing code into it:

package com.tyang1221 import dearinventory.* import dearinventoryassethelper.* import dearcore.* import firebaseapp.* import firebaseremotelibrary.* import butterknife.* import androidx.* import kotlinx.* import kotlinx.coroutines.* import java.* class MainActivity . AppCompatActivity(), DBHelper { private lateinit var mDBManager. DBManager private lateinit var mDBStorage. DBStorage private lateinit var mDBRef. DBReference private lateinit var mDBRefDeletedItem. DBReference protected val mBtnAdd = findViewById<Button>(

The process to integrate DEAR Inventory and PostgreSQL may seem complicated and intimidating. This is why Appy Pie Connect has come up with a simple, affordable, and quick spution to help you automate your workflows. Click on the button below to begin.