chr
2025-01-03 31a636e735a0addc56e4f4527f500b7aa0874eb5
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
using System.Xml.Linq;
using System;
using System.Collections.Generic;
using PdmSwPlugin.Common.Entity;
 
namespace PdmSwPlugin.PriceCheck.Param
{
    /// <summary>
    /// 材料工艺对象
    /// </summary>
    public class Technology
    {
        public string materialNumber { get; set; }
        public string materialName { get; set; }
        public string materialType { get; set; }
 
        public List<TechCraft> surfaceProcesses { get; set; }
        public List<TechCraft> heatProcesses { get; set; }
        public List<TechProp> props { get; set; }
        public List<TechProcess> techProcesses { get; set; }
    }
    /// <summary>
    /// 工艺要求
    /// </summary>
    public class TechCraft
    {
        private string treatmentCode { get; set; }
        public string treatmentInfoId { get; set; }
        public string processName { get; set; }
        public string parameter { get; set; }
        public string value { get; set; }
    }
 
    /// <summary>
    /// 材料工艺属性
    /// </summary>
    public class TechProp
    {
        public string name { get; set; }
        public string value { get; set; }
    }
 
    /// <summary>
    /// 加工工序
    /// </summary>
    public class TechProcess :NotifyBase
    {
        public string name { get; set; }
        public string value { get; set; }
 
        private string _workhour;
        public string workhour
        {
            get => _workhour;
            set
            {
                RaiseAndSetIfChanged(ref _workhour, value);
                Count();
            }
        }
 
        public double _price;
        public double price
        {
            get => _price;
            set => RaiseAndSetIfChanged(ref _price, value);
        }
 
        private void Count()
        {
            double.TryParse(workhour, out double w);
            double.TryParse(value, out double v);
            price = w * v;
        }
    }
}