Jump to content

Mushigee2266

Members
  • Posts

    23
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Mushigee2266's Achievements

  1. Please use this code in the header of the datapage. Simply use field ID and set its minimum width to your required width <style> #yourFieldID{ min-width: 900px !important; } .Option { min-width: 900px !important; overflow:hidden !important; } </style>
  2. I am using the following code to change the background color of the cell conditionally it is chnaging the background color of the div, but I want to change the background color of the complete cell : " <div id="mydiv_[@field:Test_ID]"></div> <script> var percentageSupport = parseFloat("[@field:Score2#]"); var maxScore = parseFloat('[@calcfield:2#]'); var second = parseFloat('[@calcfield:6#]'); var third = parseFloat('[@calcfield:7#]'); var fourth = parseFloat('[@calcfield:8#]'); var fifth = parseFloat('[@calcfield:9#]'); var sixth = parseFloat('[@calcfield:10#]'); var seven = parseFloat('[@calcfield:11#]'); var eight = parseFloat('[@calcfield:12#]'); var nine = parseFloat('[@calcfield:13#]'); var ten = parseFloat('[@calcfield:14#]'); if (percentageSupport >= second){ document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#006837;font-weight: bold; height: 50px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >=third ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#1A9850;font-weight: bold; height: 50px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= fourth ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#66BD63;font-weight: bold; height: 50px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= fifth ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#A6D96A;font-weight: bold; height: 50px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= sixth ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#D9EF8B;font-weight: bold; height: 50px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= seven ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#FDAE61;font-weight: bold; height: 50px;display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= eight ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#F46D43;font-weight: bold; height: 50px;display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= nine ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#D73027;font-weight: bold; height: 50px;display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#A50026;font-weight: bold; height: 50px; display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } </script>" attched is the screenshot of the result
  3. I have a dropdown and want that when user select some particular option then two fileds should become hidden. I am using the following script but it is not working <script> document.addEventListener('DataPageReady', function() { var dpoptionElement = '[@field:Style_1Style]'; var dadop2 ='[@field:Style_1Wing]'; var dadop3 = '[@field:Style_1WingWall]'; // Check if the element exists before trying to attach an event listener if (dpoptionElement === 'Winged (BH9)' || dpoptionElement === 'Deep Diamond Button (BH7)') { dadop2.style.display = 'none'; dadop3.style.display = 'none'; } }); </script> please anyone have some solution
  4. I have achived my requirement by adding div element in the field and make the width and height of the div to the width and height of the field. But I want to change the background of the cell/filed not div Here is datapage URL https://c4aby432.caspio.com/dp/f8c6d000d3feca7e221c426bb0ad"
  5. I am using following code. This code it changing the background of the text perfectly. But I want to change the background color of the cells of the column with the same conditions which are in the code. I have tried different method but unsuccefull. Is there any solution <div id="mydiv_[@field:Test_ID]"></div> <script> var percentageSupport = parseFloat("[@field:Score2#]"); var maxScore = parseFloat('[@calcfield:2#]'); var second = parseFloat('[@calcfield:6#]'); var third = parseFloat('[@calcfield:7#]'); var fourth = parseFloat('[@calcfield:8#]'); var fifth = parseFloat('[@calcfield:9#]'); var sixth = parseFloat('[@calcfield:10#]'); var seven = parseFloat('[@calcfield:11#]'); var eight = parseFloat('[@calcfield:12#]'); var nine = parseFloat('[@calcfield:13#]'); var ten = parseFloat('[@calcfield:14#]'); if (percentageSupport >= second){ document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#006400;font-weight: bold; height: 40px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >=third ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#228B22;font-weight: bold; height: 40px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= fourth ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#808000;font-weight: bold; height: 40px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= fifth ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#556B2F;font-weight: bold; height: 40px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= sixth ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#BDB76B;font-weight: bold; height: 40px; display: flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= seven ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#8B4513;font-weight: bold; height: 40px;display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= eight ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#B22222;font-weight: bold; height: 40px;display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else if (percentageSupport >= nine ) { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:#8B0000;font-weight: bold; height: 40px;display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } else { document.getElementById("mydiv_[@field:Test_ID]").innerHTML = "<div style='background-color:red;font-weight: bold; height: 40px; display:flex; justify-content: center; align-items: center;'>[@field:Score2#]</div>"; } </script>
  6. I have embedded a Tabular Report inside of a Tabular Report and what I want to achieve is that using one button, it should automatically download the two report in Excel format.
  7. I am developing a stock input form. The scenario is as follows 1. I will receive a big packet from company which consist of many items in it. This number can vary. and every item has its own ID. Now I have input from to receive this packet. 2. I want to add some logic on the form that when user open the box he will add number of items for example he add 7 itmes. Seven rows on the datapge is automatically created to record their IDs. User should not been able to add more then 7 or even less then seven items, Similarly if user enter 12 number of items the form should allow him 12 enteries not more or less than 12. please help me in this regard
  8. I am filtering data with many fields and date is one of them. I have added date criteria which is filtering data accurately. My problem is this , I am using calculating fields on results page and using this criteria on that as shown below in sql code. But it is not working. Please check the code and send me solution if any I am receiving DateFrom in calcfields3 and DateTo in Calfield4 on results page and then use them in the code ISNULL(((SELECT COUNT (Master_Data_Auto_Condition_Validation) FROM _v_Master_Data_Auto_102522 WHERE Master_Data_Auto_Category=Target.[@field:Master_Data_Auto_Category] AND Master_Data_Auto_Condition_Validation>=0 AND Master_Data_Auto_Indice=target.[@field:Master_Data_Auto_Indice] AND Master_Data_Auto_Condition_Description=target.[@field:Master_Data_Auto_Condition_Description] and Master_Data_Auto_Date>=[@calcfield:3] and Master_Data_Auto_Date<=[@calcfield:4] )),0)
  9. I have following two SQL formulas in formula fields 1. (SELECT COUNT (Master_Data_Auto_Short_Condition_Validation) FROM _v_Master_Data_Auto_Short_View WHERE Master_Data_Auto_Short_Category=Target.[@field:Master_Data_Auto_Short_Category] AND Master_Data_Auto_Short_Condition_Validation !="3" ) Its answer is 13 2. and second is (SELECT SUM (Master_Data_Auto_Short_Condition_Validation) FROM _v_Master_Data_Auto_Short_View WHERE Master_Data_Auto_Short_Category=Target.[@field:Master_Data_Auto_Short_Category] AND Master_Data_Auto_Short_Condition_Validation !="3") It answer is 10 3. Now I am dividing serial 2 with serial 1 ( i.e, 10/13) but answer is 0 in caspio calculated fields. These formulas give accurate answer when I divide with equal number. Otherwise answer is zero. Please can anybody diagnose the problem
  10. hi @Meekeee - Formula is same as mentioned above problem occures in last when i Mention Loctician_ID=Target.(@filed:Loctition_ID)
  11. SELECT STATEMENT IS WORKING FINE. BUT WHEN I APPLY CASE STATEMENT IT SHOWS CALCULATION ERROR EVERYTHING IS FINE BUT STILL I AM FACING THIS ISSUE
  12. I have applied this SQL query in the calculation field in submission form but results is calculation error. Please look and help me CASE WHEN '[@cbParamVirtual3]'="Retwist Root Maintenanace" THEN( SELECT Retwist_RT_M_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Inter Lock Root Maintenance" THEN( SELECT Inter_RT_M_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Sister Lock Root Maintenance" THEN( SELECT Sister_RT_GR_Ret_M_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Crochet Root Maintenance" THEN( SELECT Cro_RT_M_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Wick Root Maintenance" THEN( SELECT Wick_Rt_M_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Loc Repairs(Thinning, Breakage, reattachment, removal,etc)" THEN( SELECT Loc_Repairs_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Loc Climbing / Converting" THEN( SELECT Loc_Comb_Conver_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Loc Styles" THEN( SELECT LocStyle_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Extending Locs" THEN( SELECT Exte_Locs_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Starter Coil/Finger/2 Strand Locs" THEN( SELECT Starter_Coil_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Loc Attachment/Reattchment" THEN( SELECT Loc_Attch_Reattch_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Starting WIck Locs" THEN( SELECT Start_Wick_Loc_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Temporary Locs" THEN( SELECT Tem_Locs_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="New Lock Extensions" THEN( SELECT New_Loc_Ext_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Instant Locs" THEN( SELECT InstantLocs_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) WHEN '[@cbParamVirtual3]'="Starting Sister Locs" THEN( SELECT Star_Sis_Locs_rate from LocticianServices where Loctician_ID=target.[@filed:Loctician_ID]) END
  13. Hi I want to show legends with value above legends on the spline chart and a selection dropdown to filter the table. As shown in the below picture. How I can do this by using JavaScript
×
×
  • Create New...