Giter Site home page Giter Site logo

Comments (12)

EddyVerbruggen avatar EddyVerbruggen commented on May 13, 2024

Hey Colin,

What are you saying.. is the plugin broken, or is the readme incorrect?

Actually the Calendar.js file was already automatically injected in the 3.x version of the plugin. Check the plugin.xml: https://github.com/EddyVerbruggen/Calendar-PhoneGap-Plugin/tree/3.x

So that can't be the problem. I just tested the 4.x version again on iOS7 and Android 4.3 and it works fine. Can you try this repo on your 4.0.3 device and let me know if adding and removing events work as expected? https://github.com/EddyVerbruggen/X-Services-PhoneGap-Build-Plugins-Demo

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

let me explain again

When I use PGB 3.3 with your 3.2 version plugin,the Calendar.js is under the directory,look at this pic
http://www.littlebau.com/Calendar_plug/01.gif

When I use PGB 3.3 with your 4.0 version plugin,the Calendar.js is under the directory (The original 3.2 version Calendar.js was gone),look at this pic
http://www.littlebau.com/Calendar_plug/02.gif
AND the cordova_plugins.js add a few new line
http://www.littlebau.com/Calendar_plug/03.gif

this is why when I am in plugin 3.2 version,I use this syntax to include the "01.gif" Calendar.js (all function work)

<script type="text/javascript" src="js/Calendar.js"></script>

(all function broken)
when I am in plugin 4.0 version,I don't have to use the above syntax
because of the "02.gif" and "03.gif" is automatically loaded when I launch my app

The conclusion is
when I am in plugin 3.2 version,all function work
but...
when I am in plugin 4.0 version,all function broken (the code is as same as 3.2 version,In addition that I deleted the "script type="text/javascript" src="js/Calendar.js" code)

from calendar-phonegap-plugin.

EddyVerbruggen avatar EddyVerbruggen commented on May 13, 2024

Please send me your code so I can have a look. The entire project.

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

wait for a minute please

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

OK
this is all my code

<script type="text/javascript">
$(function()
{
$.getScript("plugins/Calendar.js"); //only when you use 3.2 version plugin,if 4.0,it should be  delete
});
</script>
<script type="text/javascript">
function checkCalendar() 
{
var startDate = new Date(2014,2,15,18,30,0,0,0);
var endDate = new Date(2014,2,15,19,30,0,0,0);
var title = "title";
var location = "place";
var notes = "notes";
var success = function(message) { alert("success:" + JSON.stringify(message)); };
var error = function(message) { alert("fail:" + message); };

window.plugins.calendar.createEvent(title, location, notes, startDate, endDate, success, error);
window.plugins.calendar.findEvent(title, location, notes, startDate, endDate, success, error);
var newTitle = "new title";
window.plugins.calendar.modifyEvent(title, location, notes, startDate, endDate, newTitle, location, notes, startDate, endDate, success, error);
//window.plugins.calendar.deleteEvent(newTitle,location,notes,startDate,endDate,success,error);
}
</script>

from calendar-phonegap-plugin.

EddyVerbruggen avatar EddyVerbruggen commented on May 13, 2024

Hi, appreciate the effort of pasting it here, but please, can you send me ALL your code? Your entire project. Mail it to eddyverbruggen[at]gmail.com. I just want to copy it to my devices as is.

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

@EddyVerbruggen
but...I just use phonegap build (build.phonegao.com),not Eclipse or Xcode,just javascript and html
give you my apk file ?

from calendar-phonegap-plugin.

EddyVerbruggen avatar EddyVerbruggen commented on May 13, 2024

Just zip up your www folder and mail it to me. Or a link to your project on github.

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

to @EddyVerbruggen
sorry for the lately reply
I am already send a zip to your email

but before this...
Do you remember this "Flashlight" issues
EddyVerbruggen/Flashlight-PhoneGap-Plugin#6
EddyVerbruggen/Flashlight-PhoneGap-Plugin#4

The conclusion is that you found It turns out the available function was broken on 1.1 version (although it still broken by the latest version 1.4 that I tried in the afternoon)

so...I mean is,don't you think that the "Calendar" plugin 4.0 issues have a similar behavior with "Flashlight"

all of them is work done (Android 4.0.3) by the old plugin version,but not work (Android 4.0.3) by the new plugin version

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

to @EddyVerbruggen

this is all my code (only four line code)

var startDate = new Date(2014,2,15,18,30,0,0,0);
var endDate = new Date(2014,2,15,19,30,0,0,0);
var success = function(message) { alert("success:" + JSON.stringify(message)); };
window.plugins.calendar.createEvent("title", "location", "notes", startDate, endDate, success, error);

when I am using 3.2 version plugin with "window.plugins.calendar.createEvent"
it will show this first http://www.littlebau.com/ca01.png
if I press "Cancel" button,it will reback to the app,and show this http://www.littlebau.com/caok.png
good work

but...

when I am using 4.0 version plugin with "window.plugins.calendar.createEvent"
it will show this only http://www.littlebau.com/caok.png
not work

this is all..over

from calendar-phonegap-plugin.

EddyVerbruggen avatar EddyVerbruggen commented on May 13, 2024

Ah, OK, that's because the 4.0 version of the plugin is now by default adding events silently to the Calendar (like iOS does). If you still want to use the interactive version, you should now use createEventInteractively() for Android. See the readme for details.

from calendar-phonegap-plugin.

bau720123 avatar bau720123 commented on May 13, 2024

what the "oh my god" problem is....
anywaytks

from calendar-phonegap-plugin.

Related Issues (20)

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.