| | |
| | | public Component2 component { get; set; } |
| | | |
| | | public bool lost { get; set; } = false; |
| | | public bool isHidden { get; set; } = false; |
| | | public bool suppressed { get; set; } = false; |
| | | public bool lightWeight { get; set; } = false; |
| | | |
| | |
| | | |
| | | private int? _checkRuleResult = 0; |
| | | |
| | | public bool isHidden; |
| | | |
| | | public int? checkRuleResult |
| | | { |
| | | get => _checkRuleResult; |
| | |
| | | public Dictionary<string, string> properties => BomInfo?.properties; |
| | | public string d3FilePath => BomInfo?.d3FilePath; |
| | | public string filePath => BomInfo?.filePath; |
| | | public bool lost => BomInfo?.lost == true; |
| | | public bool lost => BomInfo?.lost == true || isHidden; |
| | | |
| | | public bool isHidden = false; |
| | | |
| | | public bool suppressed => BomInfo?.suppressed == true; |
| | | public bool lightWeight => BomInfo?.lightWeight == true; |
| | | |
| | |
| | | /// <summary> |
| | | /// 规则检查结果 |
| | | /// </summary> |
| | | public int? checkRuleResult => (IsHistoryData || skipCheck) ? 3 : _drawInfo?.checkRuleResult; |
| | | public int? checkRuleResult => (IsHistoryData || skipCheck) ? 3 : (isHidden ? 2 : _drawInfo?.checkRuleResult); |
| | | /// <summary> |
| | | /// 检查是否OK |
| | | /// </summary> |
| | |
| | | } |
| | | } |
| | | |
| | | public List<string> ErrorMsgs; |
| | | |
| | | /// <summary> |
| | | /// 是否需要审核 |
| | | /// </summary> |
| | |
| | | if (ExcludeFromBOM) return false; |
| | | // 模组不审核 |
| | | if (produceWay == "模组") return false; |
| | | // 待审核的不冲突提交 |
| | | // 待审核的不重复提交 |
| | | if (drawStatus == "submitted" || drawStatus == "resubmitted") return false; |
| | | if (IsHistoryData) |
| | | { |
| | |
| | | if (ExcludeFromBOM) return null; |
| | | if (IsHistoryData) |
| | | { |
| | | bool err = false; |
| | | string msg = $"历史图纸【{partModel}】"; |
| | | if (localDocChanged) |
| | | { |
| | | return $"历史图纸【{partModel}】变更后未重新审核"; |
| | | err = true; |
| | | msg += "变更后未重新审核;"; |
| | | } |
| | | else if (drawStatus == "rejected" || drawStatus == "submitted" || drawStatus == "resubmitted") |
| | | { |
| | | return $"历史图纸【{partModel}】未通过审核"; |
| | | err = true; |
| | | msg += "未通过审核"; |
| | | } |
| | | |
| | | if (isHidden) |
| | | { |
| | | err = true; |
| | | msg += "被隐藏;"; |
| | | } |
| | | return err ? msg : null; |
| | | } |
| | | if (!IsHistoryData) |
| | | { |
| | |
| | | if (!skipCheck && !checkRuleOk) |
| | | { |
| | | error = true; |
| | | msg += "未通过规则检查"; |
| | | msg += "未通过规则检查;"; |
| | | } |
| | | if (!skipCheck && isHidden) |
| | | { |
| | | error = true; |
| | | msg += "被隐藏;"; |
| | | } |
| | | if (produceWay == "加工件" && drawStatus != "completed") |
| | | { |