Advertisement
Guest User

SharePoint scroll bug

a guest
Jun 17th, 2019
482
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
JSON 5.14 KB | None | 0 0
  1. {
  2.   "schema": "https://developer.microsoft.com/json-schemas/sp/view-formatting.schema.json",
  3.   "hideSelection": true,
  4.   "hideColumnHeader": true,
  5.   "rowFormatter": {
  6.     "elmType": "div",
  7.     "style": {
  8.       "background-color": "=if([$EntryType] == '1Heading', '#efefef', if([$Status] == 'Out', '#f99090', if([$Status] == 'In', '#aaffaf', if([$Status] == 'Leave', '#ffa754', if([$Status] == 'Home Visit', '#8587f2', if([$Status] == '', '#a2dff9', '')))))",
  9.       "height": "=if([$EntryType] == '1Heading', '40px', '80px')",
  10.       "float": "Left",
  11.       "margin": "0.5%",
  12.       "min-width": "220px",
  13.       "margin-top": "=if([$EntryType] == '1Heading', '1.5%', '0.3%')",
  14.       "width": "=if([$EntryType] == '1Heading', '94%', '18.5%')",
  15.       "padding": "3px"
  16.     },
  17.     "attributes": {
  18.       "class": "sp-row-card"
  19.     },
  20.     "children": [
  21.       {
  22.         "elmType": "div",
  23.         "style": {
  24.           "display": "=if([$Status], 'none', '')",
  25.           "text-align": "center",
  26.           "width": "100%"
  27.         },
  28.         "children": [
  29.           {
  30.             "elmType": "div",
  31.             "attributes": {
  32.               "class": "sp-row-title"
  33.             },
  34.             "style": {
  35.               "font-size": "1.5em"
  36.             },
  37.             "txtContent": "[$Title]"
  38.           },
  39.           {
  40.             "elmType": "button",
  41.             "customRowAction": {
  42.               "action": "defaultClick"
  43.             },
  44.             "txtContent": "Open",
  45.             "attributes": {
  46.               "class": "sp-row-button"
  47.             },
  48.             "style": {
  49.               "margin-top": "5%"
  50.             }
  51.           }
  52.         ]
  53.       },
  54.       {
  55.         "elmType": "div",
  56.         "style": {
  57.           "display": "=if([$EntryType] == '1Heading', '', 'none')",
  58.           "text-align": "center",
  59.           "width": "100%"
  60.         },
  61.         "children": [
  62.           {
  63.             "elmType": "div",
  64.             "attributes": {
  65.               "class": "sp-row-title"
  66.             },
  67.             "style": {
  68.               "font-size": "2em",
  69.               "font-weight": "normal"
  70.             },
  71.             "txtContent": "[$Title]"
  72.           }
  73.         ]
  74.       },
  75.       {
  76.         "elmType": "div",
  77.         "style": {
  78.           "text-align": "left",
  79.           "width": "100%",
  80.           "display": "=if([$EntryType] != '1Heading' && [$Status], '', 'none')",
  81.           "padding": "8px",
  82.           "border": "=if([$Status] != 'Home Visit', 'rgba(0,0,0,0)', if([$Returning] <= @now, '7px solid yellow', 'rgba(0,0,0,0)'))",
  83.           "border-radius": "3px",
  84.           "border-style": "dashed",
  85.           "height": "82%",
  86.           "position": "relative"
  87.         },
  88.         "children": [
  89.           {
  90.             "elmType": "div",
  91.             "attributes": {
  92.               "class": "sp-row-title"
  93.             },
  94.             "style": {
  95.               "float": "right"
  96.             },
  97.             "txtContent": "=if([$EntryType] == '2Manager', [$Team] + ' Manager', if([$EntryType] == '3Coordinator', [$Team] + ' Coordinator', '[$Team]')"
  98.           },
  99.  
  100.           {
  101.             "elmType": "div",
  102.             "attributes": {
  103.               "class": "sp-row-title"
  104.             },
  105.             "style": {
  106.               "font-weight": "bold"
  107.             },
  108.             "txtContent": "[$Person.title]"
  109.           },
  110.           {
  111.             "elmType": "div",
  112.             "style":
  113.             {
  114.               "float": "right",
  115.               "display": "=if([$Status] == 'Home Visit', '', 'none')"
  116.             },
  117.             "txtContent": "=toString('Returning by ' + toLocaleTimeString([$Returning]))"
  118.           },
  119.           {
  120.             "elmType": "div",
  121.             "attributes": {
  122.               "class": "sp-row-listPadding"
  123.             },
  124.             "style": {
  125.               "font-size": "1.2em",
  126.               "font-weight": "bold",
  127.               "color": "=if([$Status] == 'Home Visit' && [$Returning] <= @now, 'yellow', '')"
  128.             },
  129.             "txtContent": "=if([$Status] == 'Home Visit' && [$Returning] <= @now, 'Home Visit - LATE', [$Status])"
  130.           },
  131.           {
  132.             "elmType": "button",
  133.             "customRowAction": {
  134.               "action": "editProps"
  135.             },
  136.             "txtContent": "Edit",
  137.             "attributes": {
  138.               "class": "sp-row-button"
  139.             },
  140.             "style": {
  141.               "position": "absolute",
  142.               "bottom": "2px",
  143.               "right": "5px",
  144.               "margin-left": "7px"
  145.             }
  146.           },
  147.           {
  148.             "elmType": "div",
  149.             "attributes": {
  150.               "class": "sp-row-listPadding"
  151.             },
  152.             "txtContent": "[$Notes]"
  153.           },
  154.           {
  155.             "elmType": "div",
  156.             "attributes": {
  157.               "class" : "sp-row-listPadding"
  158.             },
  159.             "style": {
  160.               "position": "absolute",
  161.               "bottom": "2px"
  162.             },
  163.             "txtContent": "=toString('Updated ' + if(toLocaleDateString(@now) != toLocaleDateString[$Modified], 'more than a day ago', toLocaleTimeString([$Modified])))"
  164.           }
  165.         ]
  166.       }
  167.     ]
  168.   }
  169. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement