|
@@ -316,94 +316,101 @@ const showTools = {
|
|
|
if (item.InfoPointCode == "BIMLocation") {
|
|
|
return undefined
|
|
|
}
|
|
|
- if (item.Visible || !allMess) {
|
|
|
- //固定不显示的code
|
|
|
- if (!showTools.cantShow(item.InfoPointCode) && !onlyRead && !taizhang) {
|
|
|
- return undefined
|
|
|
- }
|
|
|
-
|
|
|
- if (!showTools.isShow(item.InfoPointCode) && !taizhang && !taizhang) {
|
|
|
- if (isWatch && !onlyRead) {
|
|
|
+ if (onlyRead || InputModeArr.indexOf(item.InputMode) > -1) {
|
|
|
+ if (item.Visible || !allMess) {
|
|
|
+ //固定不显示的code
|
|
|
+ if (!showTools.cantShow(item.InfoPointCode) && !onlyRead && !taizhang) {
|
|
|
return undefined
|
|
|
}
|
|
|
- }
|
|
|
|
|
|
- if (item.InfoPointCode == "EquipQRCode") {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- renderer: text.lookQRCode,
|
|
|
- readOnly: true
|
|
|
+ if (!showTools.isShow(item.InfoPointCode) && !taizhang && !taizhang) {
|
|
|
+ if (isWatch && !onlyRead) {
|
|
|
+ return undefined
|
|
|
+ }
|
|
|
}
|
|
|
- }
|
|
|
|
|
|
- if (item.InputMode == "D1") {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- renderer: tools.customDropdownRenderer,
|
|
|
- editor: "chosen",
|
|
|
- chosenOptions: {
|
|
|
- // multiple: true,//多选
|
|
|
- data: item.DataSource || ""
|
|
|
+ if (item.InfoPointCode == "EquipQRCode") {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ renderer: text.lookQRCode,
|
|
|
+ readOnly: true
|
|
|
}
|
|
|
- };
|
|
|
- } else if (item.InputMode == "A1" || item.InputMode == "A2") {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- type: "numeric",
|
|
|
- numericFormat: {
|
|
|
- pattern: "0,0.00"
|
|
|
- // culture: 'de-DE' // use this for EUR (German),
|
|
|
- // more cultures available on http://numbrojs.com/languages.html
|
|
|
+ }
|
|
|
+
|
|
|
+ if (item.InputMode == "D1") {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ renderer: tools.customDropdownRenderer,
|
|
|
+ editor: "chosen",
|
|
|
+ chosenOptions: {
|
|
|
+ // multiple: true,//多选
|
|
|
+ data: item.DataSource || ""
|
|
|
+ }
|
|
|
+ };
|
|
|
+ } else if (item.InputMode == "A1" || item.InputMode == "A2") {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ type: "numeric",
|
|
|
+ numericFormat: {
|
|
|
+ pattern: "0,0.00"
|
|
|
+ // culture: 'de-DE' // use this for EUR (German),
|
|
|
+ // more cultures available on http://numbrojs.com/languages.html
|
|
|
+ }
|
|
|
+ };
|
|
|
+ } else if (item.InputMode == "C5") {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ type: "date",
|
|
|
+ dateFormat: "YYYY-MM-DD",
|
|
|
+ correctFormat: true
|
|
|
+ };
|
|
|
+ } else if (
|
|
|
+ item.InputMode == "B1" ||
|
|
|
+ item.InputMode == "L" ||
|
|
|
+ item.InputMode == "L1" ||
|
|
|
+ item.InputMode == "L2" ||
|
|
|
+ item.InputMode == "M"
|
|
|
+ ) {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode
|
|
|
+ };
|
|
|
+ } else if (
|
|
|
+ item.InputMode == "X"
|
|
|
+ // item.InputMode == "L1" ||
|
|
|
+ // item.InputMode == "L2"
|
|
|
+ ) {
|
|
|
+ // return undefined
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ readOnly: true
|
|
|
+ };
|
|
|
+ } else if (item.InputMode == "D2") {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ renderer: tools.customDropdownRenderer,
|
|
|
+ editor: "chosen",
|
|
|
+ chosenOptions: {
|
|
|
+ multiple: true, //多选
|
|
|
+ data: item.DataSource || ""
|
|
|
+ }
|
|
|
+ };
|
|
|
+ } else if (item.InputMode == "Own" && !onlyRead) {
|
|
|
+ return {
|
|
|
+ data: "Infos." + item.InfoPointCode,
|
|
|
+ renderer: text.idType,
|
|
|
}
|
|
|
- };
|
|
|
- } else if (item.InputMode == "C5") {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- type: "date",
|
|
|
- dateFormat: "YYYY-MM-DD",
|
|
|
- correctFormat: true
|
|
|
- };
|
|
|
- } else if (
|
|
|
- item.InputMode == "B1" ||
|
|
|
- item.InputMode == "L" ||
|
|
|
- item.InputMode == "L1" ||
|
|
|
- item.InputMode == "L2" ||
|
|
|
- item.InputMode == "M"
|
|
|
- ) {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode
|
|
|
- };
|
|
|
- } else if (
|
|
|
- item.InputMode == "X"
|
|
|
- // item.InputMode == "L1" ||
|
|
|
- // item.InputMode == "L2"
|
|
|
- ) {
|
|
|
- // return undefined
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- readOnly: true
|
|
|
- };
|
|
|
- } else if (item.InputMode == "D2") {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- renderer: tools.customDropdownRenderer,
|
|
|
- editor: "chosen",
|
|
|
- chosenOptions: {
|
|
|
- multiple: true, //多选
|
|
|
- data: item.DataSource || ""
|
|
|
+ } else {
|
|
|
+ return {
|
|
|
+ data: "infos." + item.InfoPointCode
|
|
|
}
|
|
|
- };
|
|
|
- } else if (item.InputMode == "Own" && !onlyRead) {
|
|
|
- return {
|
|
|
- data: "Infos." + item.InfoPointCode,
|
|
|
- renderer: text.idType,
|
|
|
}
|
|
|
} else {
|
|
|
- return undefined;
|
|
|
+ return undefined
|
|
|
}
|
|
|
} else {
|
|
|
- return undefined
|
|
|
+ return false
|
|
|
}
|
|
|
+
|
|
|
|
|
|
}).filter(item => item);
|
|
|
return data
|
|
@@ -428,7 +435,7 @@ const showTools = {
|
|
|
return undefined
|
|
|
}
|
|
|
|
|
|
- if (!showTools.isShow(item.InfoPointCode)) {
|
|
|
+ if (!showTools.isShow(item.InfoPointCode) && !onlyRead) {
|
|
|
if (isWatch && !onlyRead) {
|
|
|
return undefined
|
|
|
}
|