Jump to content

NiceDuck

Caspio Ninja
  • Content Count

    73
  • Joined

  • Last visited

  • Days Won

    3

Posts posted by NiceDuck


  1. As for the formula, you may refer to this one:

    Case 
    when [@authfield:Role] = "paid"
    then"URL for report page"
    When (Select count (Id) from "extra_table_for_subform" where DateDiff(month, date, SysDateTime())) = 0) < 10
    then "URL for report page"
    else "URL for notification message about limit"
    end

     


    image.png.efccb06c91669a942b000773baf26642.png
    LAstly, on your destination after submit, select the "Go to a new page" then use the virtual field as value along with the parameter

    I hope the idea helps.
     


  2. I have an Idea for this one but Its a bit tricky to set-up

    first, you will have to create a set-up where you are going to use a seperate search form results form. Please refer to this article:

    https://howto.caspio.com/tech-tips-and-articles/tech-parameters/how-to-separate-search-page-and-results-page-into-two-different-webpages/

    You will also need an extra table with similar design to your main table. Use that as the data source of your submision(search form).

    You will also need an authentication for this workflow. Even if your users are non paying, they should still have an account first before being able to access the forms.

    You will need to have an extra field on your users table which will mark which is paying and which is not. (preferably a text 255 which says "paid" or "free")

    Also, on your submission form, create an extra virtual field, set it to a calculation value that will check if the current users are paid users or not. If it determined that the users are non paying, it will count how many searches are conducted within the month. It can be done by using a conditional statement that returns the URL of the report page if the conditions are met properly. Otherwise, redirect the users to a different page which has a message that they have exceeded their limit search for the month.

     


  3. The other method I found is by placing an identifier on each datapage to check the status of the current user.

    This will require the following.

    1) an extra field on the user accounts table (the table which your authentication uses as data source). Preferably, you can use a text 255. If you are using a view as a data source for your authentication, make sure to include the extra field on your view.

    2)On every datapage you have, create an HTML block and insert the following script (you may want to try using the header instead)

    ********************
    <script>
    if("[@authfield:extra_field]" == "Ban"){
    window.location = "your_logout_URL";
    }
    </script>

    ****************************************

    On this workflow, all the admin had to do is go to the user table and edit the "extra_field" value to "Ban". I prefer that you create a datapage for this instead and also, if you are using a view as an authentication data source, add a criteria on it to filter out records which "extra_field" is equal to "Ban" so they cant login again.

    The problem with this workflow is, your user will not be logout immediately.  They will only be logout if they refreshed the page or go to a new page (given that all of your datapage has this code)

    I am still looking for other workaround but I hope this helps anyone.

    quack
     


  4. The first thing I did to achieve this is I created a dummy datapage with the same authentication as the one being used by the datapage your target user is using.  

    If you have checked the "Only one session per user" you can log in using your target users credential and thus it will log them out on their end. 

    This however, requires for the admin to know the password of the target user. 

    Overall this will work but has some security and trust issues.

     


  5. Hello,

    Do you mean that, you want a task to run between your search form and your results page?

    Like, upon searching, before it shows the results a search, it will run a task first?

    For this case, I suggest that you use a triggered action instead. Then, follow the procedure stated here:  https://howto.caspio.com/tech-tips-and-articles/tech-parameters/how-to-separate-search-page-and-results-page-into-two-different-webpages/

    additional notes for the procedure:

    *create a dummy table and use that for the makeshift search form(submission form)
    *apply the triggered action on this dummy table
    *make sure that the triggered action is designed similary to the task
     

    basically, what will occur is, we will create a triggered action that run on "Insert" for the dummy table which we use as the table data source for the makeshift search form. Therefore, every search will activate the trigger.

    well... that the idea, depending on how fast the process of your trigger is or how long before the makeshift submission form redirect to results page, you may have to refresh the page first to get the proper results. 

    quack


  6. 1) Create an autonumber ID field on your table datasource.

    2) On your task, create a where filter which will only process the records where id field is less than 6000 (assuming that your table has 120,000 records)

    3) Duplicate this task, however, this time, set the where to filter to only include records where id field is greater than 6000.

    4) Set them to run for atleast 30 mins apart. (Just a suggestion)

    Hope it helps.

    Quack.


  7. Hello Shiro,

    On my observation, I noticed that they are greyed out if the table relationship does not follow this conditions

    1) the field on the parent table must be unique

    2) the field on the child table must not be unique

    3)the child table must not be a parent table of another table. it could be a child of another table but It must not be a parent.

    I am still pondering about the logic why that condition is in place though

    quack


  8. Hello, I found your post interesting. I just want to verify some things before I check if we can do something about this.

    Does those records only come from a single data source or table?

    also, just a summary, you are planning to limit them to number of download per record right? so even the count will stack even though they have downloaded it before.

    if so, hmmmmmm let see what we can do...


  9. That? I just happened to need the same information a while back so I asked my account manager.

    They also mentioned that the reason why there is a daily limit for email sending is because it is a fail-safe just incase that a user misconfigured his task or triggered action and make it send automatic emails, infinite times which may cause server issues and exhaustion of the accounts resources.  


  10. Yes it was. You could also try using emails instead. Here are the pros and cons:

    SMS: 
    PRos: Much faster (I think)
    Cons: Canada and America numbers only

    Emails
    Pros: Global and no need for extra device.
    cons:  Due to the recent issue, your email may ended up bouncing back or filtered out as spam if you have not configure it correctly. Also, slower to receive (personal opinion)


  11. Hello. 

    I just want to share a workflow again. 

    I made a workflow where your users can view a document type of files, directly on your report datapage.

    Yes,  I know that there is a howto article for that already.  its this one: https://howto.caspio.com/tech-tips-and-articles/advanced-customizations/tech-tip-embed-documents-in-datapages/

    However,  the catch on the work I made is, 

    1) It also shows the download link for the file.

    2) The files are stored on your Caspio Bridge account

    3) No need for filestore

    The instruction are on the embeded doc file:
    display docs on datapage.docx

    Hope it helps anyone:

     

    Quack


  12. Hello,

    I just want to share this with you.

    Yesterday, I did have a submission form that has a special text field whose value is equal to a a bit complicated  concatenation of two other fields .  Since Triggered action is my personal favorite feature, I used a triggered action to do this concatenation, and the datapage is working as expected. Later on, one of co-user thought that it is wasteful to use triggered action for only this operation. Therefore,  he went to the table design and change the data type of this special field to "Formula field".
     

    After composing the right formula, he went on his merry way without checking the datapage.

    Later on, one of the users noticed that they are no longer able to send any data with the submission form because any attempts are ending up with a "Data Restriction" error.

    After few hours of troubleshooting and some squawking around.  We figured out that the reason of the issue is that the triggered action is not updated nor disbaled. 

    What actually happen is, the triggered action is trying to change the value of the the special field. However, since formula fields can create their own value unlike its former data type which is just a text255.

    Now, since the trigger is failing to run, the datapage is having the error  which down the page for about an hour.

    The lesson is,  make sure that if you check if there are triggered action or task connected to field before modifying its data type as it seems that the trigger action is not being updated when you modify the field type.

    I hope this helps
    quack


  13. Hmmmmm.... How long does one task takes before completion?

    I think that they are indeed being qued, however if they are still not run after a certain amount of time (probably 15 mins), they will be skipped. so you may want to keep on check to your other task if they are still running.

    You may also want to adjust the ran time of the others and check the message tab on your Caspio Bridge Account.

×
×
  • Create New...