|
@@ -1,4 +1,4 @@
|
|
|
-## Êëàññû
|
|
|
+## Кла��ы
|
|
|
|
|
|
```
|
|
|
namespace WpfApp2.model
|
|
@@ -81,16 +81,16 @@ namespace WpfApp2.model
|
|
|
ItemsSource="{Binding SparesList}">
|
|
|
<DataGrid.Columns>
|
|
|
<DataGridTextColumn
|
|
|
-Header="Íàçâàíèå äåòàëè"
|
|
|
+Header="�азвание детали"
|
|
|
Binding="{Binding name}"/>
|
|
|
<DataGridTextColumn
|
|
|
-Header="Öåíà"
|
|
|
+Header="Цена"
|
|
|
Binding="{Binding price}"/>
|
|
|
<DataGridTextColumn
|
|
|
-Header="Êëàññèôèêàöèÿ äåòàëè"
|
|
|
+Header="Кла��ификаци� детали"
|
|
|
Binding="{Binding detail}"/>
|
|
|
<DataGridTextColumn
|
|
|
-Header="Òèï ÒÑ"
|
|
|
+Header="Тип ТС"
|
|
|
Binding="{Binding type}"/>
|
|
|
</DataGrid.Columns>
|
|
|
</DataGrid>
|
|
@@ -100,7 +100,7 @@ Binding="{Binding type}"/>
|
|
|
VerticalAlignment="Bottom">
|
|
|
<Button
|
|
|
x:Name="ExitButton"
|
|
|
- Content="Âûõîä"
|
|
|
+ Content="Выход"
|
|
|
Click="ExitButton_Click"
|
|
|
Height="50"/>
|
|
|
</StackPanel>
|
|
@@ -110,7 +110,7 @@ Binding="{Binding type}"/>
|
|
|
Grid.Column="1"
|
|
|
MinHeight="50">
|
|
|
<Label
|
|
|
- Content="Äåòàëü:"
|
|
|
+ Content="Деталь:"
|
|
|
VerticalAlignment="Center"/>
|
|
|
|
|
|
<ComboBox
|
|
@@ -129,7 +129,7 @@ Binding="{Binding type}"/>
|
|
|
</ComboBox.ItemTemplate>
|
|
|
</ComboBox>
|
|
|
<Label
|
|
|
-Content="Öåíà:"
|
|
|
+Content="Цена:"
|
|
|
VerticalAlignment="Center"/>
|
|
|
<ComboBox
|
|
|
Name="PriceFilterComboBox"
|
|
@@ -147,7 +147,7 @@ ItemsSource="{Binding SparesPriceList}">
|
|
|
</ComboBox.ItemTemplate>
|
|
|
</ComboBox>
|
|
|
<Label
|
|
|
-Content="Òèï ÒÑ"
|
|
|
+Content="Тип ТС"
|
|
|
VerticalAlignment="Center"/>
|
|
|
<ComboBox
|
|
|
Name="TypeFilterComboBox"
|
|
@@ -191,9 +191,9 @@ namespace WpfApp2
|
|
|
if (PropertyChanged != null)
|
|
|
PropertyChanged(this, new PropertyChangedEventArgs("SparesList"));
|
|
|
}
|
|
|
- public string selectedDetail = "Äåòàëü";
|
|
|
+ public string selectedDetail = "Деталь";
|
|
|
public SparesPrice? selectedPrice = null;
|
|
|
- public string selectedType = "Òèï ÒÑ";
|
|
|
+ public string selectedType = "Тип ТС";
|
|
|
|
|
|
private IEnumerable<Spares> _SparesList;
|
|
|
public IEnumerable<Spares> SparesList
|
|
@@ -201,9 +201,9 @@ namespace WpfApp2
|
|
|
get
|
|
|
{
|
|
|
return _SparesList
|
|
|
- .Where(c => (c.detail == selectedDetail || selectedDetail == "Äåòàëü"))
|
|
|
+ .Where(c => (c.detail == selectedDetail || selectedDetail == "Деталь"))
|
|
|
.Where(c => (selectedPrice == null || (c.price >= selectedPrice.PriceFrom && c.price < selectedPrice.PriceTo)))
|
|
|
- .Where(c => (c.type == selectedType || selectedType == "Òèï ÒÑ"));
|
|
|
+ .Where(c => (c.type == selectedType || selectedType == "Тип ТС"));
|
|
|
}
|
|
|
set
|
|
|
{
|
|
@@ -221,10 +221,10 @@ namespace WpfApp2
|
|
|
Globals.dataProvider = new LocalDataProvider();
|
|
|
SparesList = Globals.dataProvider.getSpares();
|
|
|
SparesDetailList = Globals.dataProvider.getDetail().ToList();
|
|
|
- SparesDetailList.Insert(0, new SparesDetail { title = "Äåòàëü" });
|
|
|
+ SparesDetailList.Insert(0, new SparesDetail { title = "Деталь" });
|
|
|
SparesPriceList = Globals.dataProvider.getPrice().ToList();
|
|
|
SparesTypeList = Globals.dataProvider.getType().ToList();
|
|
|
- SparesTypeList.Insert(0, new SparesType { title = "Òèï ÒÑ" });
|
|
|
+ SparesTypeList.Insert(0, new SparesType { title = "Тип ТС" });
|
|
|
}
|
|
|
|
|
|
private void ExitButton_Click(object sender, RoutedEventArgs e)
|
|
@@ -266,23 +266,23 @@ namespace WpfApp2
|
|
|
{
|
|
|
new SparesDetail()
|
|
|
{
|
|
|
- title="Äâèãàòåëü"
|
|
|
+ title="Двигатель"
|
|
|
},
|
|
|
new SparesDetail()
|
|
|
{
|
|
|
- title="ÊÏÏ"
|
|
|
+ title="КПП"
|
|
|
},
|
|
|
new SparesDetail()
|
|
|
{
|
|
|
- title="Ïîäâåñêà"
|
|
|
+ title="Подве�ка"
|
|
|
},
|
|
|
new SparesDetail()
|
|
|
{
|
|
|
- title="Ñòåêëà"
|
|
|
+ title="Стекла"
|
|
|
},
|
|
|
new SparesDetail()
|
|
|
{
|
|
|
- title="Êîëåñà"
|
|
|
+ title="Коле�а"
|
|
|
},
|
|
|
};
|
|
|
}
|
|
@@ -292,35 +292,35 @@ namespace WpfApp2
|
|
|
{
|
|
|
new SparesPrice()
|
|
|
{
|
|
|
- title="Âñå öåíû",
|
|
|
+ title="В�е цены",
|
|
|
PriceFrom=0,
|
|
|
PriceTo=99999999
|
|
|
|
|
|
},
|
|
|
new SparesPrice()
|
|
|
{
|
|
|
- title="ÁÓ",
|
|
|
+ title="БУ",
|
|
|
PriceFrom=0,
|
|
|
PriceTo=10000
|
|
|
|
|
|
},
|
|
|
new SparesPrice()
|
|
|
{
|
|
|
- title="Äåøåâàÿ",
|
|
|
+ title="Дешева�",
|
|
|
PriceFrom=10000,
|
|
|
PriceTo=20000
|
|
|
|
|
|
},
|
|
|
new SparesPrice()
|
|
|
{
|
|
|
- title="Ñðåäíÿÿ",
|
|
|
+ title="Средн��",
|
|
|
PriceFrom=20000,
|
|
|
PriceTo=50000
|
|
|
|
|
|
},
|
|
|
new SparesPrice()
|
|
|
{
|
|
|
- title="Ýëèòíàÿ",
|
|
|
+ title="ÐлитнаÑ�",
|
|
|
PriceFrom=50000,
|
|
|
PriceTo=99999999
|
|
|
}
|
|
@@ -334,11 +334,11 @@ namespace WpfApp2
|
|
|
{
|
|
|
new SparesType()
|
|
|
{
|
|
|
- title="Ëåãêàÿ"
|
|
|
+ title="Легка�"
|
|
|
},
|
|
|
new SparesType()
|
|
|
{
|
|
|
- title="Ãðóçîâàÿ"
|
|
|
+ title="Грузова�"
|
|
|
},
|
|
|
};
|
|
|
}
|
|
@@ -346,30 +346,30 @@ namespace WpfApp2
|
|
|
{
|
|
|
return new Spares[]{
|
|
|
new Spares{
|
|
|
- type="Ëåãêàÿ",
|
|
|
- name="Äâèãàòåëü ÌÁ140(ÎÊ2281.4)",
|
|
|
+ type="Легка�",
|
|
|
+ name="Двигатель МБ140(ОК2281.4)",
|
|
|
price = 72000,
|
|
|
- detail="Äâèãàòåëü"},
|
|
|
+ detail="Двигатель"},
|
|
|
new Spares{
|
|
|
- type="Ëåãêàÿ",
|
|
|
- name="ÊÏÏ 5-ÑÒ ÐÑ-ÏÄÐ",
|
|
|
+ type="Легка�",
|
|
|
+ name="КПП 5-СТ РС-ПДР",
|
|
|
price = 20000,
|
|
|
- detail="ÊÏÏ"},
|
|
|
+ detail="КПП"},
|
|
|
new Spares{
|
|
|
- type="Ãðóçîâàÿ",
|
|
|
- name="Ïîäâåñêà ÏÄÐÑ1337",
|
|
|
+ type="Грузова�",
|
|
|
+ name="Подве�ка ПДРС1337",
|
|
|
price = 15000,
|
|
|
- detail="Ïîäâåñêà"},
|
|
|
+ detail="Подве�ка"},
|
|
|
new Spares{
|
|
|
- type="Ëåãêàÿ",
|
|
|
- name="Øèíà 15-Ð",
|
|
|
+ type="Легка�",
|
|
|
+ name="Шина 15-Р",
|
|
|
price = 3000,
|
|
|
- detail="Êîëåñà"},
|
|
|
+ detail="Коле�а"},
|
|
|
new Spares{
|
|
|
- type="Ãðóçîâàÿ",
|
|
|
- name="Ëîáîâîå ñòåêëî ÑÒ150",
|
|
|
+ type="Грузова�",
|
|
|
+ name="Лобовое �текло СТ150",
|
|
|
price = 40000,
|
|
|
- detail="Ñòåêëà"},
|
|
|
+ detail="Стекла"},
|
|
|
|
|
|
};
|
|
|
}
|
|
@@ -378,7 +378,7 @@ namespace WpfApp2
|
|
|
}
|
|
|
```
|
|
|
|
|
|
-# Ñêðèíû ðàáîòû
|
|
|
+# Скрины работы
|
|
|
|
|
|
![](./img/1.jpg)
|
|
|
|