Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    SmartClient Version: v11 - Not able to add custom/formula fields to grid.

    We're upgrading smartclient from 10.1 to 11 and facing issues with "Add Custom Fields" functionality. Please find the below details:
    * Issue Description:
    1. Not able to add custom fields to grid.
    2. Can't use "Add formula column" option multiple times, its erasing previous custom fields.

    * Navigation:
    Grid context menu -> select "columns" -> From "Field Picker", Open dropdown "Add Custom Fields"
    -> Add formula column -> Add formula field and "Save" -> *"Field Picker" visible fields section not updated with new field* but grid has been updated with new field.
    -> Click "Apply" -> will delete formula column from the grid.

    * SmartClient: SmartClient Version: v11.0p_2017-06-04/PowerEdition Development Only (built 2017-06-04)

    * Browser: Mozilla Netscape 5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36

    Attached standalone test case "PSS-3225-Grid-AddCustomFields.html"
    Last edited by nyeddala; 29 Jun 2017, 04:04. Reason: Trying to attach test case (html) and Its not allowing with error "Not a valid Image"

    #2
    Please let me know how to share test case (html)

    Comment


      #3
      Try to rename to txt or include the formatted contents here in code-tags.

      Comment


        #4
        BTW, in this sample it workds as expected and also shows different lables for the buttons.

        Comment


          #5
          Test case:

          Code:
           <!DOCTYPE html>
            <html>
            <head>
                <title ></title>
            <style>
            .diagInfo {
            font-size: 14px;
            font-weight: bold;
            padding: 5px;
            }
            </style>
                <script type="text/javascript" >
            var isomorphicDir="http://localhost:8080/isomorphic/";
            </script>
             
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Core.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Foundation.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Containers.js"></script>
              <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Grids.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Forms.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_DataBinding.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Drawing.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_PluginBridges.js"></script> 
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic//system/modules/ISC_Charts.js"></script>
             <script type="text/javascript" SRC="http://localhost:8080/isomorphic/skins/EnterpriseBlue/load_skin.js"></script>
             
            </head>
            <body>
            <div>
            </br>
            </br>
            </div>
            <div>
             <script type="text/javascript">
             
            var data = [{zip:"11111",createdByID:81580,fax:"123-456-7890",externalCompanyID:"",countryCode:"Unknown",stateCode:"Unknown",address1:"default address, default city, Unknown  11111",address2:null,registrationCode:"",breadcrumb:null,city:"default city",id:349632,createdByName:"Andres Orozco",name:"! Camguard Systems",suite:null,createDate:Date.parseServerDate(2013,11,5),telephone:"123-456-7890"},{zip:"11111",createdByID:85110,fax:"123-456-7890",externalCompanyID:"203031915",countryCode:"Unknown",stateCode:"Unknown",address1:"default address, default city, Unknown  11111",address2:null,registrationCode:"",breadcrumb:null,city:"default city",id:280186,createdByName:"Integration Admin",name:"! SUMMIT EROSION CONTROL INC",suite:null,createDate:Date.parseServerDate(2011,7,24),telephone:"123-456-7890"},{zip:"11111",createdByID:113478,fax:"123-456-7890",externalCompanyID:"",countryCode:"Unknown",stateCode:"Unknown",address1:"default address, default city, Unknown  11111",address2:null,registrationCode:"",breadcrumb:null,city:"default city",id:172641,createdByName:"Dan Palumbo",name:"*** Do not duplicate contractors already listed!!!!!!!!!!!!!!!!!!",suite:null,createDate:Date.parseServerDate(2008,1,6),telephone:"123-456-7890"},{zip:"11111",createdByID:54555,fax:"123-456-7890",externalCompanyID:"221865954",countryCode:"Unknown",stateCode:"Unknown",address1:"default address, default city, Unknown  11111",address2:null,registrationCode:"",breadcrumb:null,city:"default city",id:50898,createdByName:"Turner Admin",name:"**DO NOT USE**A-L SERVICES INC",suite:null,createDate:Date.parseServerDate(2004,10,9),telephone:"123-456-7890"},{zip:"11111",createdByID:54555,fax:"123-456-7890",externalCompanyID:"",countryCode:"Unknown",stateCode:"Unknown",address1:"default address, default city, Unknown  11111",address2:null,registrationCode:"",breadcrumb:null,city:"default city",id:147169,createdByName:"Turner Admin",name:"*Lk Sheet Metal",suite:null,createDate:Date.parseServerDate(2007,1,16),telephone:"123-456-7890"},{zip:"11111",createdByID:54555,fax:"123-456-7890",externalCompanyID:null,countryCode:"Unknown",stateCode:"Unknown",address1:"default address, default city, Unknown  11111",address2:null,registrationCode:"",breadcrumb:null,city:"default city",id:147175,createdByName:"Turner Admin",name:"*Suzio Concrete",suite:null,createDate:Date.parseServerDate(2007,1,16),telephone:"123-456-7890"},{zip:"11111",createdByID:85110,fax:"123-456-7890",externalCompanyID:"141912053",countryCode:"United States",stateCode:"New  York",address1:"default address, default city, New  York  11111",address2:null,registrationCode:"",breadcrumb:" Boston Main",city:"default city",id:153028,createdByName:"Integration Admin",name:"*Turner Construction Company",suite:null,createDate:Date.parseServerDate(2004,10,9),telephone:"123-456-7890"}];
             
            // ===== DO NOT REMOVE =====
            var diagLabel = isc.Label.create({
            ID: "diagInfo",
            width: "100%",
            styleName: "diagInfo",
            autoFit: true
            });
            // ===== DO NOT REMOVE =====
            </script>
             
            <script type="text/javascript">
            // set this to the correct JIRA ticket
            var JIRA_TICKET = "PSS-3225";
             
            // once page loads set some diagnostic information, DO NOT CHANGE
            isc.Page.setEvent("load", function() {
            document.title = JIRA_TICKET + "   (SmartClient version " + isc.versionNumber + ") PowerEdition";
            var html = [];
            html.push("Jira: " + JIRA_TICKET);
            html.push("SmartClient: " + isc.versionNumber);
            html.push("Browser: " + navigator.appCodeName + " " + navigator.appName + " " + navigator.appVersion);
            diagLabel.setContents( html.join("<br>"));
            });
             
            isc.DataSource.create({
            ID: "ds",
            cacheData:data,
            clientOnly: true
            });
             
            var grid = isc.ListGrid.create({
            dataSource : ds,
            fields: [
            {name:"name", type:"text", title:"name"},
            {name:"zip", title:"zip", type:"text" },
            {name:"createdByID", type:"text", title:"createdByID"},
            {name:"fax", type:"text", title:"fax"},
            {name:"externalCompanyID", type:"integer", title:"externalCompanyID"},
            {name:"countryCode", type:"integer", title:"countryCode"},
            {name:"stateCode", type:"text", title:"stateCode"},
            {name:"address1", type:"text", title:"address1"},
            {name:"address2", type:"text", title:"address2"},
            {name:"registrationCode", type:"text", title:"registrationCode"},
            {name:"breadcrumb", type:"text", title:"breadcrumb"},
            {name:"id", type:"text", title:"id"},
            {name:"createdByName", type:"text", title:"createdByName"},
            {name:"suite", type:"text", title:"suite"},
            {name:"createDate", type:"text", title:"createDate"},
            {name:"telephone", type:"text", title:"telephone"},
            {name:"city", type:"text", title:"city"}
            ],
            dataFetchMode : "local",
            autoFetchData: true,
            width : 1020,
            align : "center",
            autoDraw: false,
            autoFitData : "vertical",
            autoFitMaxHeight : 600,
            alternateRecordStyles : true,
            canAddFormulaFields : true,
            //canAddSummaryFields : true,
            canGroupBy : true,
            //canReorderFields : true,
            showGroupSummary : true,
            //groupByMaxRecords : 1000,
            //canMultiGroup : true,
            useAdvancedFieldPicker : true,
            advancedFieldPickerThreshold : 3,
            canEditTitles: true
            });
             
            var layout = isc.VLayout.create({
            width:"100%",
            membersMargin: 20,
            members: [
            // ===== DO NOT REMOVE diagLabel
            diagLabel,
            // ===== place anty components here
            grid
            ]
            });
             
             
            </script> 
            </div>
            </body>
             
            </html>

          Comment

          Working...
          X