SU Module Installation and Testing

Home Forums StockUnlocks Drupal Module SU Module Installation and Testing

This topic contains 31 replies, has 3 voices, and was last updated by  Eduardo 4 months, 2 weeks ago.

  • Author
    Posts
  • #1043

    SU Admin
    Keymaster

    This module is designed to work with hosted websites ONLY. Do not attempt to test on a local PC installation. Make sure that your website can be reached from the Internet and has a static IP address.


    Official release from tag: 7.x-1.0

    For installation instructions, please see our YouTube video tutorial: “Install the StockUnlocks Drupal module

    If you haven’t received it yet, click here to download the StockUnlocks custom Drupal module .

    Make sure that you have Ubercart with all of its dependent modules installed first.

    Here is what we have so far: Our YouTube channel

    IMPORTANT: Before installing the stockunlocks module, you must first configure your Drupal site’s “Private file system path”. This is a secure area where the module needs to write to in order to function:

    • The last two directory entries must be named “files/private”. e.g. “sites/default/files/private”.
    • Your Drupal website settings are found here: /admin/config/media/file-system
    • Tips – Working with files, Drupal 7: https://drupal.org/documentation/modules/file

    Here are what the above settings should look like:


    Drupal 7 admin config media file-system

    Some things are just better presented audibly & visually – we’re working on it!

    1. On your Drupal website [file system], copy the stockunlocks.zip into:  … /sites/all/modules/ and expand it (unzip it).
      • (If your site is being hosted, another way would be to locate the .zip file from the “+ Install new module” link from the “Modules” page.)
    2. Once expanded, you may delete the stockunlocks.zip file, if you desire.
    3. Navigate back to your website: /admin/modules (refresh)
    4. You will find the “StockUnlocks – Mobile Unlocking” module in the “Other” category, select it (check the box next to it)
    5. Click on “Save configuration” at the bottom of the page.
    6. Scroll back to the top and find the link “update script” and click on that, following all of the instructions afterwards.

    In the future, updates to the stockunlocks module will be automatically pushed to your website via Drupal.org. At that time, you will have a choice whether or not to update.

    In order to test your website, here’s what you’ll have to do: (you must be logged in with the administrator role):

    IMPORTANT (DO THESE FIRST):

    • Make sure that you have the “Administer StockUnlocks” permission enabled for your administrator.

    Make the permission change here, under “StockUnlocks mobile unlocking” : /admin/people/permissions

    • Please update ALL of your email templates with your OWN website information!

    Make the email template changes here (Navigation: SU Email Templates): /suapi/emailtemplates

    1. Sign up for a reseller’s account with your chosen supplier.
    2. Once your account has been activated, request API access from your supplier.
    3. Edit & Activate the default Provider profile in your Drupal site, entering your unique API key and username (Navigation: SU API Status): /suapi/status
    4. Set your supplier as the “Designated Provider” on your Drupal site (Navigation: SU API Designated Provider): /suapi/data
    5. Display IMEI services by selecting “IMEI Service List“, click “Execute(Navigation: SU API Actions): /suapi/actions
    6. Find out the “test” API services that your supplier has available. Find them in you list and place a check mark in the box.
    7. Scroll back to the top and click “Import Selected“.
    8. Click on the link to view the newly imported services. Optionally, you may use the admin menu to view: /admin/content
    9. Select the newly imported services and publish them: under “UPDATE OPTIONS“, select “Publish selected content” then click “Update“.
    10. Either click on one of the services or use the menu to view all published services: /stockunlocks/view
    11. Submit one order for each API Test service; Tip: For testing purposes, 15 zeros will pass as a legitimate IMEI number.
    12. View your orders here (admin menu): Store > View Orders (take note of the order status and details): /admin/store/orders/view

    To force cron to process the orders (if you want to bypass the scheduled execution time):

    1. Click “Configuration” (admin menu)
    2. Under “System”, you’ll see “Cron”, click that: /admin/config/system/cron
    3. Click “Run cron”. This will force submit/process orders.
    4. View your UPDATED orders here (admin menu): Store > View Orders (take note of the order status and details): /admin/store/orders/view

    Please wait the designated time allotted for processing.

    1. Your suppler should automatically process your “orders”.
    2. Click “Configuration” (admin menu)
    3. Under “System”, you’ll see “Cron”, click that: /admin/config/system/cron
    4. On the next screen, click “Run cron”. This will force the processing of submitted orders.
    5. View your UPDATED orders here (admin menu): Store > View Orders (take note of the order status and details): /admin/store/orders/view

    PLEASE let us know of any issues you encounter, large or small.

    Thanks!
    StockUnlocks Support

  • #1377

    dhru-user
    Participant

    I experience this issue when adding imie services and I can’t edit emails.

    PDOException: SQLSTATE[42S02]: Base table or view not found: 1146 Table ‘cobaltun_drup483.dr_uc_attributes’ doesn’t exist: SELECT label, ordering, required, display FROM {uc_attributes} WHERE aid = :aid; Array ( [:aid] => ) in stockunlocks_add_provider_services() (line 499 of /home/cobaltun/public_html/drupal/sites/all/modules/stockunlocks/includes/stockunlocks.functions.api.inc).

    • #1379

      SU Admin
      Keymaster

      It looks like a new install of Drupal helped as well as enabling the “Product attributes” under:

      /admin/modules > Ubercart – core (optional) > Product attributes.

      It’s best to start with a clean install of Drupal, dedicated to Ubercart and the stockunlocks module.

  • #1381

    dhru-user
    Participant

    You are awesome! This tutorial and module of your works very good. I am able to import all the IMEI services from my choice of reseller. Few places I am stuck at.

    1. When I am logged in as admin I can see all the IMEI services offered by my client. Picture is attached.
    2. When I login as a user I am not able to see any IMEI services. Picture attached. How do we correct this?

    • #1383

      SU Admin
      Keymaster

      Thanks! if you need to view your IMEI services while not logged in as Admin, you need to create a public view that contains your Products.

      Take a look at this video to see how it’s done: http://www.youtube.com/watch?v=xXdyI2yyxDU

      In the meantime, go to “Modules” and enable “Catalog” under Ubercart. Once enabled, you can go to yourwebsite.com/catalog to view your products once everything is configured. The default “StockUnlocks” view is designed for Admin viewing only.

  • #1389

    dhru-user
    Participant

    Thanks for your info. I somehow changed the default page to “catalog” and its working for now. Now the site I mentioned above was a test site. Since its working there on the test site I installed everything on the live site now whihc is unlock.phonerepairguru.com.

    I have followed all the steps, installed all the dependent plugins and the missing plugins, created “cckeys” directory, created “private” directory and changed the permissions etc. Then I installed the Stockunlocks module.

    Now when I click on to add a new service provider it gives me an error. I believe its a db error. Picture are attached.

    I am able to view the “Stockunlock View”. I am also able to click on “su API Add” and add the provider as clicking on it takes me to the below link – http://unlock.phonerepairguru.com/?q=suapi/add

    But the problem is that when I click any of the link – http://unlock.phonerepairguru.com/suapi/add – it dont work and gives me the error.

    Any of the option ” ADD DESIGNATE” or “MODIFY AN API Provider” it gives me the error. If I click any of the link from the navigation menu it do not give me the error. I uninstalled the SU Unlock module, deleted the directory and all the files then readd th module it gives the same error.

    Then I uninstalled the whole drupal and installed the dependent modules and the missing modules and added the directories and added the StockUnlock module the same problem happens.

    Any idea?

  • #1394

    dhru-user
    Participant

    hi, I am testing your module but I has a question, for a reseller account I has installed ubercart and user points to work with credit (each user has credit to buy, no need to pay each time), but userpoints don´t accept decimals, for example for blackberry 0,30 and userpoint says to pay 1

    Can you help me? Thanks!!

    • #1396

      SU Admin
      Keymaster

      Hi neodark, Unfortunately, not familiar with “userpoints”. We may look into this in the future, but there is no guarantee, to be honest.

    • #1398

      dhru-user
      Participant

      Thanks for your reply 🙂 Great module!! Best regards!!

  • #1400

    dhru-user
    Participant

    Hey! Great job on the module! I’m having a little bit of trouble having the order sent to my reseller. I tried installing Drupal, Ubercart and StockUnlock 2 times already.

    The first time I got a bunch of errors because I forgot to install the Ubercart modules and dependents first. I tested it out with a real order with an account I made on my website but the order won’t change its’ status from “PENDING”. I checked on my sellers’ website to see if there are any orders but no luck. If you could help me out it would be great!

    • #1402

      SU Admin
      Keymaster

      Hello,

      Did you create an account at […] ? It might help to submit a few test orders with us just to confirm that everything is in order. There is no charge and it ensures that your system is properly configured.

      Additionally, you may need to confirm that your cron task is running:

      Configuration > Cron

      Make sure that it is set to “Run cron every” … for a time period and NOT for “Never”.

  • #1404

    dhru-user
    Participant

    Thanks for the reply. I made an account it’s xxxxxxxxxx. Can you please enable the API for me? I went and looked at the cron settings and it was set for every hour.

    • #1406

      SU Admin
      Keymaster

      All set. You should have received the notification with API key. Regards

  • #1408

    dhru-user
    Participant

    Hello.

    I´ve install all the modules and all dependences, i´ve install the stockunlocks module but i can sync with ur page always say this:

    Work directly with a specific, designated Service Provider using the available API actions.

    ERROR: Message: Authentication Failed
    
    No designated/active API Providers found or a faild connection. Click to either: ADD, DESIGNATE OR MODIFY an API Provider

    and i´ve now have ur api-key and my account:

    Active stockunlocks […]/ KDC-XXX-HIR-XXX-XXX-XXX-RQV-XXX alejandro

    The XXX is the correct keys.

    Can u help me sir?

    Best regards

    • This reply was modified 1 year, 5 months ago by  dhru-user.
    • #1410

      dhru-user
      Participant

      has the set time limit error mentioned above been resolved, as i have the same error and donot know how to proceed. many thanks

    • #1412

      SU Admin
      Keymaster

      The time limit error is entirely based on your hosting environment. Some hosts allow scripts to run for extended time periods, others don’t. When the module attempts to import large amounts of data from your unlocking provider you can get this error.

      The only suggestion would be to try importing smaller amounts of data at a time. Regards

    • #1415

      dhru-user
      Participant

      hi thanks for the reply, i think you may be correct, i wil try impoerting a smaller amount of data. one question that i have is where is this data imported to and what is the next stage in using this data.

    • #1417

      SU Admin
      Keymaster

      First of all, congratulations – you’ve accomplished exactly what was intended using the tutorials.

      Outside of that, you will have to explore for yourself the many aspects of Drupal development. Once the data is imported it can be configured to be used as products to be added to a shopping cart and sold on your website. The details regarding “using the data” are quite involved.

      The time and expense creating additional tutorials and support for the module is proving to be a liability right now. The best we can do is to ensure that it remains bug free at this point.

      Please do your best to search “Drupal Development” or “Ubercart product configuration”. There are tons of tutorials out there that will assist you. It’s not worth our time and effort to re-create what is already out there in abundance.

      Please don’t be put off by my comments, for now that’s just the way things are.

      Many regards

  • #1373

    dhru-user
    Participant

    Hi ,i get this error ,i reinstall 7 times,but nothing same error,please give me a hand. Notice: Undefined index: triggering_element in stockunlocks_api_actions_form_validate() (line 29 of /home/icloudgs/public_html/sites/all/modules/stockunlocks/api_client/info_actions.inc).

    • #1375

      SU Admin
      Keymaster

      First of all, I’m very sorry for the long delay. I just finished importing this forum from the old website and was busy with tidying up after a major website upgrade. At first glance, it looks like the stockunlocks module wasn’t completely uninstalled properly. In order to completely uninstall, you have to first disable the module: THIS WILL DELETE EVERYTHING RELATED TO STOCKUNLOCKS, INCLUDING ALL SERVICES (PRODUCTS), PROVIDERS, etc.

      1. Navigate to your website: /admin/modules
      2. You will find the “StockUnlocks – Mobile Unlocking” module in the “Other” category, de-select it (uncheck the box next to it)
      3. Click on “Save configuration” at the bottom of the page.
      4. Scroll back to the top and find the link “update script” and click on that, following all of the instructions afterwards.

      Next, you have to properly uninstall the module:

      1. Navigate to your website: /admin/modules/uninstall
      2. You will see the “StockUnlocks – Mobile Unlocking” module, select it (check the box next to it)
      3. Click on “Uninstall” at the bottom of the page.
      4. Follow all of the instructions afterwards. This should “clean up” any mess left behind from a bad install.

      Afterwards, just follow the instructions for enabling (installing) the stockunlocks module.

      Keep in mind: The module is still available in the file system, you don’t have to download it again.

      1. Just go back to your website: /admin/modules
      2. You will find the “StockUnlocks – Mobile Unlocking” module in the “Other” category, select it (check the box next to it)
      3. Click on “Save configuration” at the bottom of the page.
      4. Scroll back to the top and find the link “update script” and click on that, following all of the instructions afterwards.

      Let me know how it turns out.

  • #1419

    dhru-user
    Participant

    Hi, i did all things correctly, i test the two api in my drupl site store view orders but i do not find the orders, than i want ask you how to add all imei services to my site

    • #1421

      SU Admin
      Keymaster

      Please confirm that your cron task is running:

      /admin/config/system/cron

      Make sure that it is set to “Run cron every” … for a time period and NOT for “Never“.

      Also, we only provide 2 services for testing with our API. Our […] website is for testing only.

      Once you get everything working with your website, you will have to search to find a unlocking direct supplier in order to connect your website with their API and then download the many services from them.

      Please read the detailed instructions above to be sure that you are looking in the right places for the orders you are submitting.

  • #1423

    dhru-user
    Participant

    Hello,

    Thanks you very much for this post ,

    i was registered on your platform stockUnlocks,
    and I was tried to activate my temporary site (when it is on, I’ll change the domain name)
    but I got blockage on the step 3 , when i try access to edit page on api status :

    i was tried in 2 server (the local on my pc , and my register server)
    – in local server : Object not found ,The requested URL could not be found..

    – in register server :Internal server error ,The server encountered an internal error or misconfiguration and was unable to complete your request.

    so in the final , I can’t edit my provider or enter api keys ,

    please can you help me ?

    best regards

    • #1425

      SU Admin
      Keymaster

      Local PC installation is not supported. As detailed in the provided instructions from reseller.stockunlocks.com, your website must be hosted and have a static IP address in order for the stockunlocks module for Drupal websites to function properly. Please send us your API username here: […] so that we may reset your settings. Thanks.

      • This reply was modified 1 year, 5 months ago by  SU Admin.
    • #1427

      dhru-user
      Participant

      Hello , Thank you for your reactivity, I suspect that its not working locally, but I had the same problem in site hosted (Internal server error, The Server Encountered an internal error or misconfiguration and Was Unable to complete your request) I’ll send you my userName, best regards

    • #1429

      SU Admin
      Keymaster

      Your problem should be resolved when you enable “clean URLs” on your Drupal website.

      Please check for links above in this forum for the details. The links contain detailed explanations.

      Here is the way to access “Clean URLs”:

      Configuration > Search and metadata > Clean URLs OR yourwebsite.com/admin/config/search/clean-urls

      That will do it.

  • #1431

    dhru-user
    Participant

    I got this error all the time: No designated/active API Providers found or a failed connection. Click to either: ADD, DESIGNATE OR MODIFY an API Finally after 20 hours, i got it to work.. Kan you please open up for more services on my retail account?

    • #1433

      SU Admin
      Keymaster

      Hi and congrats on getting the module to work properly. Regarding more services, we only allow testing with our resellers website via the API. We focus mainly on retail sales. We have been considering opening up just a few services for those with accounts with us, but it all depends upon the demand. Would you kindly let us know which services you are interested in? Thanks

  • #1439

    dhru-user
    Participant

    No designated/active API Providers found or a failed connection. Click to either: ADD, DESIGNATE OR MODIFY an API Provider. this error after adding api key i dont get any options

    • #1440

      SU Admin
      Keymaster

      Please contact us at the link above, providing your registered username with […].

  • #2075

    Eduardo
    Participant

    Hello,
    This module is excellent, a great contribution without a doubt to the drupal community.
    I tried it with an order with the account of http://reseller.stockunlocks.com/, but the order will not change its status of “PENDING”. I checked the website to see if there are any orders, but no luck.
    I tested it out with a real order with an account I made on my website but the order won’t change its’ status from “PENDING”. I checked on my sellers’ website to see if there are any orders but no luck. If you could help me out it would be great!
    Create a site in my VPS and buy a hosting in GoDaddy to prove it, and in both cases the ordering always stays in “PENDING”.
    If they explained to me how the module works internally, or how it makes use of cron, would be ideal to find because it does not change the state of the orders ?, and because the orders do not arrive at my supplier?
    Thank you for all your help.

You must be logged in to reply to this topic.