Git Product home page Git Product logo

nativescript-calllog's People

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

nativescript-calllog's Issues

android.database.sqlite.SQLiteException: no such column: undefined

Hi .. I'm try to use your plugin woth android but when it try to execute it give to me this error:

android.database.sqlite.SQLiteException: no such column: undefined (code 1 SQLITE_ERROR): , while compiling: SELECT formatted_number, duration, subscription_id, photo_id, post_dial_digits, number, countryiso, photo_uri, geocoded_location, subscription_component_name, add_for_all_users, numbertype, features, transcription, last_modified, _id, new, date, name, type, presentation, via_number, numberlabel, normalized_number, phone_account_address, lookup_uri, voicemail_uri, matched_number, transcription_state, data_usage, is_read FROM calls WHERE (((type = undefined) AND ((type != 4)) AND ((phone_account_hidden = 0))))
JS: android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:179)

My Code:

 // Your example task.
       // Your example task.
        let doWork = () => {
            return new Promise((resolve, reject) => {

                let args = {
                    filter: [
                        callLogsService.Type.INCOMING,
                        callLogsService.Type.OUTCOMING,
                        callLogsService.Type.MISSED
                    ],
                    contactType: callLogsService.ContactType.UNKNOWN
                };
                // Do some work.
                console.log(callLogsService);
                
                callLogsService.getCallLog([args]).then(callLogs => {
                    console.log(callLogs);
                    callLogs.data.forEach(callLog => {
                        console.log(`${callLog['number']} ${callLog['type']} ${callLog['date']} ${callLog['duration']} ${callLog['contactid']}`);
                        resolve(callLog);
                    });
                }).catch((err) => {
                    console.error(err);
                    reject(err);
                });

            });
        };

no "I" field "REJECTED_TYPE"

Hi,
i try yout nativescript-CallLog, but i get this error.
JS: [Vue warn]: Error in created hook: "Error: java.lang.NoSuchFieldError: no "I" field "REJECTED_TYPE" in class "Landroid/provider/CallLog$Calls;" or its superclasses
JS: com.tns.Runtime.callJSMethodNative(Native Method)
JS: com.tns.Runtime.dispatchCallJSMethodNative(Runtime.java:1116)
JS: com.tns.Runtime.callJSMethodImpl(Runtime.java:996)
JS: com.tns.Runtime.callJSMethod(Runtime.java:983)
JS: com.tns.Runtime.callJSMethod(Runtime.java:967)
JS: com.tns.Runtime.callJSMethod(Runtime.java:959)
JS: com.tns.gen.java.lang.Object_vendor_54830_26_ClickListenerImpl.onClick(Object_vendor_54830_26_ClickListenerImpl.java:17)
JS: android.view.View.performClick(View.java:5198)
JS: android.view.View$PerformClick.run(View.java:21147)
JS: android.os.Handler.handleCallback(Handler.java:739)
JS: android.os.Handler.dispatchMessage(Handler.java:95)
JS: android.os.Looper.loop(Looper.java:148)
JS: android.app.ActivityThread.main(ActivityThread.java:5417)
JS: java.lang.reflect.Method.invoke(Native Method)
JS: com.android.internal.os.Zyg...

My test code:

require("nativescript-CallLog")
let args = {
      filter: [
          callLogsService.Type.INCOMING,
          callLogsService.Type.OUTCOMING,
          callLogsService.Type.MISSED,
      ],
      contactType: callLogsService.ContactType.UNKNOWN
    }
callLogsService.getCallLog([args]).then(callLogs => {
      callLogs.data.forEach(callLog => {
          console.log(`${callLog['number']} ${callLog['type']} ${callLog['date']} ${callLog['duration']} ${callLog['contactid']}`);
      })
    })

image

What am I doing wrong?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.