diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/Comments.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/Comments.cshtml
index 2230e94..215a004 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/Comments.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/Comments.cshtml
@@ -17,6 +17,7 @@
Комментарии
+ Добавить
@@ -29,7 +30,7 @@
Текст
- Название сборки к которой относиться комментарий
+ Название сборки к которой относится комментарий
Действия
@@ -50,10 +51,12 @@
@Html.DisplayFor(modelItem => item.BuildName)
-
- Изменить
- Удалить
-
+
+
+
+
+
+
}
@@ -61,10 +64,6 @@
-
- Добавить
- Обновить
-
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/CreatePurchase.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/CreatePurchase.cshtml
index 0cb7236..10270c2 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/CreatePurchase.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/CreatePurchase.cshtml
@@ -16,7 +16,6 @@
Товары
Добавить
- Удалить
@@ -147,70 +146,4 @@
}
-}
-
-
-@*
-*@
\ No newline at end of file
+}
\ No newline at end of file
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/LinkPurchase.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/LinkPurchase.cshtml
index 2c23262..4a7cc40 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/LinkPurchase.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/LinkPurchase.cshtml
@@ -13,7 +13,7 @@
@{
- Добавить
+ Добавить
@@ -224,11 +224,11 @@
- Добавить
- Изменить
- Удалить
- Обновить
- Сохранить
+ Добавить
+ Изменить
+ Удалить
+ Обновить
+ Сохранить
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/Privacy.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/Privacy.cshtml
new file mode 100644
index 0000000..1984ba8
--- /dev/null
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/Privacy.cshtml
@@ -0,0 +1,29 @@
+@using HardwareShopContracts.ViewModels;
+
+
+@model UserViewModel
+
+@{
+ ViewData["Title"] = "Privacy Policy";
+ Layout = "~/Views/Shared/_LayoutWorker.cshtml";
+}
+
+
Личные данные
+
+
\ No newline at end of file
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/Purchases.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/Purchases.cshtml
index e21e699..cad04da 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/Purchases.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/Purchases.cshtml
@@ -19,7 +19,7 @@
Добавить
Удалить покупку
Выдан
-
Обновить
+
Изменить
@@ -56,24 +56,12 @@
@Html.DisplayFor(modelItem => item.PurchaseStatus)
- @*
-
- Изменить
- Удалить
-
- *@
}
-
-
- @*Изменить
- Удалить
- Обновить *@
-
}
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/UpdatePurchase.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/UpdatePurchase.cshtml
index c150829..0b2b803 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/UpdatePurchase.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/UpdatePurchase.cshtml
@@ -17,7 +17,6 @@
Товары
Добавить
- Удалить
@@ -68,6 +67,7 @@
const saveBtn = document.getElementById("createpurchase");
const countElem = document.getElementById("count");
const resultTable = document.getElementById("result");
+ const totalSum = document.getElementById("sum");
submitGoodBtn.addEventListener("click", () => {
console.log('try to add good')
@@ -138,7 +138,10 @@
`
count++;
console.log(elem);
+ price += elem.good.price * elem.count
})
+ totalSum.value = Math.round(price * 110) / 100
+ console.log(totalSum.value);
}
function deleteGood(id) {
@@ -173,70 +176,4 @@
getPurchase();
-}
-
-
-@*
-*@
\ No newline at end of file
+}
\ No newline at end of file
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/WorkerReport.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/WorkerReport.cshtml
index 5c263c2..93ebc95 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/WorkerReport.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/WorkerReport.cshtml
@@ -3,29 +3,15 @@
Layout = "~/Views/Shared/_LayoutWorker.cshtml";
}
-Отчет по покупкам
-
-
-
-
+
-
-
-
-
-
- Показать
-
-
- На почту
-
+
Вывод на страницу
+
Отправить на почту
@@ -34,21 +20,20 @@
по
...
-
-
-
-
- Номер покупки
- Дата покупки
- Сумма покупки
- Комментарии
- Комплектующие
-
-
-
-
-
-
+
+
+
+
+ Номер покупки
+ Дата покупки
+ Сумма покупки
+ Комментарии
+ Комплектующие
+
+
+
+
+
@section Scripts
{
@@ -72,9 +57,6 @@
"DateFrom": dateFrom,
"DateTo": dateTo
};
- if (!validate(reportModel)) {
- return;
- }
$.ajax({
url: "/home/WorkerReport",
type: "POST",
@@ -94,9 +76,6 @@
"DateFrom": dateFrom,
"DateTo": dateTo
};
- if (!validate(reportModel)) {
- return;
- }
$.ajax({
url: "/home/SendByMailPurchaseReport",
type: "POST",
@@ -106,14 +85,6 @@
});
});
- dateFromInput.addEventListener("input", () => {
- errorDivShell.style.gridTemplateRows = "0fr";
- });
-
- dateToInput.addEventListener("input", () => {
- errorDivShell.style.gridTemplateRows = "0fr";
- });
-
// ![Event listeners]
// [HTML gen]
@@ -167,25 +138,6 @@
// [Other]
- const validate = function (reportModel) {
- if (isNaN(reportModel["DateFrom"])) {
- errorDivShell.style.gridTemplateRows = "1fr";
- errorP.innerHTML = "Выберите начальную дату";
- return false;
- }
- if (isNaN(reportModel["DateTo"])) {
- errorDivShell.style.gridTemplateRows = "1fr";
- errorP.innerHTML = "Выберите конечную дату";
- return false;
- }
- if (reportModel["DateFrom"] >= reportModel["DateTo"]) {
- errorDivShell.style.gridTemplateRows = "1fr";
- errorP.innerHTML = "Начальная дата должна быть меньше конечной";
- return false;
- }
- return true;
- }
-
const getDate = function (iso) {
const year = iso.substring(0, 4);
const month = iso.substring(5, 7);
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Home/listComponents.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Home/listComponents.cshtml
index ea4942c..ed1dc8d 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Home/listComponents.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Home/listComponents.cshtml
@@ -24,8 +24,8 @@
- Сохранить в doc-формате
- Сохранить в xls-формате
+ Сохранить в doc-формате
+ Сохранить в xls-формате
diff --git a/HardwareShop/HardwareShopWorkerApp/Views/Shared/_LayoutWorker.cshtml b/HardwareShop/HardwareShopWorkerApp/Views/Shared/_LayoutWorker.cshtml
index 2b7096b..aa26c35 100644
--- a/HardwareShop/HardwareShopWorkerApp/Views/Shared/_LayoutWorker.cshtml
+++ b/HardwareShop/HardwareShopWorkerApp/Views/Shared/_LayoutWorker.cshtml
@@ -36,6 +36,9 @@
Отчёт
+
+ Личные данные
+
diff --git a/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/FontAwesome.otf b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/FontAwesome.otf
new file mode 100644
index 0000000..401ec0f
Binary files /dev/null and b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/FontAwesome.otf differ
diff --git a/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.eot b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.eot
new file mode 100644
index 0000000..e9f60ca
Binary files /dev/null and b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.eot differ
diff --git a/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.svg b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.svg
new file mode 100644
index 0000000..855c845
--- /dev/null
+++ b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.svg
@@ -0,0 +1,2671 @@
+
+
+
+
+Created by FontForge 20120731 at Mon Oct 24 17:37:40 2016
+ By ,,,
+Copyright Dave Gandy 2016. All rights reserved.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf
new file mode 100644
index 0000000..35acda2
Binary files /dev/null and b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf differ
diff --git a/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff
new file mode 100644
index 0000000..400014a
Binary files /dev/null and b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff differ
diff --git a/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2 b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2
new file mode 100644
index 0000000..4d13fc6
Binary files /dev/null and b/HardwareShop/HardwareShopWorkerApp/wwwroot/lib/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2 differ