1. #1
    Sencha User
    Join Date
    Jul 2012
    Location
    Ukraine
    Posts
    7
    Vote Rating
    0
    Vitaly Ivanov is on a distinguished road

      0  

    Default SignaturePad plugin for the Sencha Touch 2

    SignaturePad plugin for the Sencha Touch 2


    Hey guys, I have updated the existing signature pad plugin written for Sencha Touch 1.
    You can find the source code here https://github.com/ivanovvitaly/SignaturePadST2 and the code for the sample form bellow as well.

    Here is the sample image of what I've got
    Attached Images

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,524
    Vote Rating
    873
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    You should really optimize your code. You should only have 1 class per file.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha Premium Member
    Join Date
    Aug 2012
    Location
    California
    Posts
    29
    Vote Rating
    1
    thejonz is on a distinguished road

      0  

    Default Architect 2 - Sencha Touch?

    Architect 2 - Sencha Touch?


    I'm very extied to use this - thanks for making! Any tips on how to get this to work in Sencha Touch in Architect 2?

    thanks!

  4. #4
    Sencha User
    Join Date
    Jul 2012
    Location
    Ukraine
    Posts
    7
    Vote Rating
    0
    Vitaly Ivanov is on a distinguished road

      0  

    Default


    Hey, I'm not working with Sencha Architect, so I can't help with this

  5. #5
    Sencha User QuinnPerkins's Avatar
    Join Date
    Mar 2008
    Posts
    22
    Vote Rating
    0
    QuinnPerkins is on a distinguished road

      0  

    Default Probably Something Stupid on My Part

    Probably Something Stupid on My Part


    Ok...should I have to do anything more to see the sample app from Git than put it in a directory up on a standard LAMP build and hit its index file?

    I threw this up on a server, and get this error:

    Error: The following classes are not declared even if their files have been loaded: 'Sencha.ux.SignaturePad'. Please check the source code of their corresponding files for possible typos: 'app/plugin/SignaturePad.js
    [Break On This Error]

    "corresponding files for possible typos: '" + missingPaths.join("', '"));

    sencha-touch.js (line 7897)

    http://sigtest.m3tr1cs.com/

    Can anyone offer me any guidance on what I'm doing wrong?

    Thanks!

  6. #6
    Touch Premium Member
    Join Date
    Dec 2010
    Posts
    28
    Vote Rating
    1
    netlogic is on a distinguished road

      0  

    Default fix

    fix


    I was able to get it to run by going to app and modifying the requires statement

    requires: [
    'Ext.MessageBox',
    //'Sencha.ux.SignaturePad'
    'ST2.plugin.SignaturePad'
    ],

  7. #7
    Sencha User
    Join Date
    Dec 2011
    Posts
    17
    Vote Rating
    0
    bionicmaster is on a distinguished road

      0  

    Default


    to use any ux plugin in sencha architect you can do this:

    Create a loader in Application
    Add in routes this:
    {'Ext.ux.touch' : 'app/ux'}
    or if you wanna be more specific:
    {'Ext.ux.touch.Rating' : 'app/view/fieldRating.js'} //this uses starRating, renames and relocates in another place

    and you can load this, but you can't edit in SA, you need external editor to edit anything inside the file, as an extra thing, don't forget to use require in the Class that is invoking it.

    Greetings

  8. #8
    Sencha User
    Join Date
    Jun 2011
    Posts
    8
    Vote Rating
    0
    mikegriffin is on a distinguished road

      0  

    Default Getting SignaturePad working in Architect

    Getting SignaturePad working in Architect


    Add SignaturePad.js to your project root.
    Add in a JS Resource that points to this (note: this will then deploy with your project and let you edit in Architect)

    Create a loader
    Ext.Loader.setConfig({
    enabled: true,
    paths: {
    'ST2.plugin.SignaturePad': 'SignaturePad.js'
    }
    });

    Create a container in the form you want to use it.
    Promote to Class
    Create override in class

    Ext.define('DiveLogger.view.override.MyContainer', {
    override: 'DiveLogger.view.MyContainer',
    config:{
    plugins: [
    {
    xclass: 'ST2.plugin.SignaturePad',
    canvasId: 'signature',
    width: 500,
    height: 230,
    disableScrollCmp: 'formpanel'
    }
    ]
    },
    initialize:function(){
    Ext.create('ST2.plugin.SignaturePad');
    this.callOverridden(arguments);
    }

    });

    Note: disableScrollCmp will be the parent xtype for your form.

  9. #9
    Sencha User
    Join Date
    Jun 2011
    Posts
    8
    Vote Rating
    0
    mikegriffin is on a distinguished road

      0  

    Default


    This link has a working version and the Architect xds file

    http://www.onebiglink.com/autograph/