Deluge Script wishlist...

Deluge Script wishlist...

Just throwing it out there ;)

1. += operator. Pleeeeease no more var = var + "test";
2. Ternary Operator for if/else. Man I wish I could just go myVar = myVar == "test" ? "it is test" : "it's not test" instead of having to write out a huge if/else block of ugly brackets. 
3. square bracket notation for referring to record fields and map views. 

This would make it terribly hard for Zoho to debug which might break the whole goal of saving new users from themselves. But here's why it would be extremely useful and would really help to lower deluge script bloat. 

fields = {"first_name","last_name","dob"};
for each f in fields
{
      hide input[f]; //this is just an example.. 
}

3. formRecord.toMap(). I dream about this option every time I use Zoho Creator. Converting a record into a map would make deluge script so much more powerful and DRY because you can now dynamically reference field values. You can build configuration/admin pages that don't require the user to touch deluge script to change the behavior of their app. 

validation example. 

bool validation.contact(contactForm c)
{
      fields = validations[name == 'contactForm'];
      no_go = {"", null, "false", false};
      cMap = c.toMap();
      for each f in fields
      {
              if(no_go.contains(f.get(f)))
            {
                  return false;
            }     
      }
      return true;
}

4. Type prototype methods for chaining! 

So functions are great and all but it would be great to be able to create chained methods just like your built in toList, toString methods that way people could write their own helper methods. 

Example. 

string String.myMethod()
{
     return this.doSomething().doSomethingElse();
}

then it's just "testing".myMethod().toXML(); or something like that. 

BTW I just want to say that I think Deluge Script is FANTASTIC. If you are creative enough you can do just about any sort of business logic in Deluge Script. To parse it, run it for bugs, etc must be a super huge head ache! Anyways, just wanted to show some gratitude for what we already get to use. Thanks again! 

-Stephen, @srhyne

    Access your files securely from anywhere









                          Zoho Developer Community




                                                • Desk Community Learning Series


                                                • Digest


                                                • Functions


                                                • Meetups


                                                • Kbase


                                                • Resources


                                                • Glossary


                                                • Desk Marketplace


                                                • MVP Corner


                                                • Word of the Day


                                                • Ask the Experts





                                                          Manage your brands on social media



                                                                Zoho TeamInbox Resources



                                                                    Zoho CRM Plus Resources

                                                                      Zoho Books Resources


                                                                        Zoho Subscriptions Resources

                                                                          Zoho Projects Resources


                                                                            Zoho Sprints Resources


                                                                              Qntrl Resources


                                                                                Zoho Creator Resources



                                                                                    Zoho CRM Resources

                                                                                    • CRM Community Learning Series

                                                                                      CRM Community Learning Series


                                                                                    • Kaizen

                                                                                      Kaizen

                                                                                    • Functions

                                                                                      Functions

                                                                                    • Meetups

                                                                                      Meetups

                                                                                    • Kbase

                                                                                      Kbase

                                                                                    • Resources

                                                                                      Resources

                                                                                    • Digest

                                                                                      Digest

                                                                                    • CRM Marketplace

                                                                                      CRM Marketplace

                                                                                    • MVP Corner

                                                                                      MVP Corner







                                                                                        Design. Discuss. Deliver.

                                                                                        Create visually engaging stories with Zoho Show.

                                                                                        Get Started Now


                                                                                          Zoho Show Resources

                                                                                            Zoho Writer

                                                                                            Get Started. Write Away!

                                                                                            Writer is a powerful online word processor, designed for collaborative work.

                                                                                              Zoho CRM コンテンツ






                                                                                                Nederlandse Hulpbronnen


                                                                                                    ご検討中の方