Browse Source

refs #795 Syncronizing with release commit:aa2d451b53ac066978f31b52ee28eb73770b1b4c build:201802212316.

git-svn-id: https://help.cyberplat.com/svn@706 03a3ef96-f0a9-4432-b0b0-a3692ed642c1
tags/3.11.0
svn 3 years ago
parent
commit
8d4a969035
20 changed files with 109 additions and 47 deletions
  1. +4
    -4
      3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_de.ts
  2. +4
    -4
      3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_en.ts
  3. +4
    -4
      3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_kk.ts
  4. +4
    -4
      3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_ru.ts
  5. +4
    -4
      3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_ru_bankomat.ts
  6. +28
    -4
      3.0/src/includes/Hardware/Printers/PrinterConstants.h
  7. +2
    -0
      3.0/src/interface/modern/main_menu_scene.qml
  8. +13
    -5
      3.0/src/interface/modern/scene_with_context/operators/11611/widgets/Car.qml
  9. BIN
      3.0/src/interface/modern/scene_with_context/operators/11611/widgets/images/er.png
  10. +15
    -5
      3.0/src/interface/modern/scene_with_context/operators/11611/widgets/kzd_calendar_editor.qml
  11. +8
    -2
      3.0/src/interface/modern/scene_with_context/operators/11611/widgets/kzd_enum_editor.qml
  12. +1
    -1
      3.0/src/interface/modern/scene_with_context/operators/11611/widgets/kzd_ticket_editor.qml
  13. +3
    -2
      3.0/src/interface/modern/scripts/gui.js
  14. +6
    -1
      3.0/src/interface/modern/widgets/ad.qml
  15. +3
    -3
      3.0/src/interface/modern/widgets/enum_editor.qml
  16. +1
    -0
      3.0/src/interface/modern/widgets/list.qml
  17. +1
    -1
      3.0/src/modules/GraphicsEngine/src/GraphicsEngine.cpp
  18. +1
    -1
      3.0/src/modules/Hardware/CashAcceptors/src/CCNet/FirmwareVersions.h
  19. +5
    -0
      3.0/src/modules/Hardware/Printers/src/Base/PrinterBase.cpp
  20. +2
    -2
      3.0/src/modules/Hardware/Printers/src/POSPrinters/Custom/CustomKZTCodec.h

+ 4
- 4
3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_de.ts View File

@@ -12,7 +12,7 @@
<context>
<name>GUIService</name>
<message>
<location filename="../Services/GUIService.cpp" line="498"/>
<location filename="../Services/GUIService.cpp" line="497"/>
<source>#penetration_detected</source>
<translation></translation>
</message>
@@ -20,17 +20,17 @@
<context>
<name>PrintFiscalCommand</name>
<message>
<location filename="../Services/PrintingCommands.cpp" line="95"/>
<location filename="../Services/PrintingCommands.cpp" line="100"/>
<source>#bank_fee</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="96"/>
<location filename="../Services/PrintingCommands.cpp" line="101"/>
<source>#dealer_fee</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="102"/>
<location filename="../Services/PrintingCommands.cpp" line="107"/>
<source>#processing_fee</source>
<translation type="unfinished"></translation>
</message>


+ 4
- 4
3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_en.ts View File

@@ -12,7 +12,7 @@
<context>
<name>GUIService</name>
<message>
<location filename="../Services/GUIService.cpp" line="498"/>
<location filename="../Services/GUIService.cpp" line="497"/>
<source>#penetration_detected</source>
<translation>Remote control attempt.</translation>
</message>
@@ -20,17 +20,17 @@
<context>
<name>PrintFiscalCommand</name>
<message>
<location filename="../Services/PrintingCommands.cpp" line="95"/>
<location filename="../Services/PrintingCommands.cpp" line="100"/>
<source>#bank_fee</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="96"/>
<location filename="../Services/PrintingCommands.cpp" line="101"/>
<source>#dealer_fee</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="102"/>
<location filename="../Services/PrintingCommands.cpp" line="107"/>
<source>#processing_fee</source>
<translation type="unfinished"></translation>
</message>


+ 4
- 4
3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_kk.ts View File

@@ -12,7 +12,7 @@
<context>
<name>GUIService</name>
<message>
<location filename="../Services/GUIService.cpp" line="498"/>
<location filename="../Services/GUIService.cpp" line="497"/>
<source>#penetration_detected</source>
<translation type="unfinished"></translation>
</message>
@@ -20,17 +20,17 @@
<context>
<name>PrintFiscalCommand</name>
<message>
<location filename="../Services/PrintingCommands.cpp" line="95"/>
<location filename="../Services/PrintingCommands.cpp" line="100"/>
<source>#bank_fee</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="96"/>
<location filename="../Services/PrintingCommands.cpp" line="101"/>
<source>#dealer_fee</source>
<translation type="unfinished"></translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="102"/>
<location filename="../Services/PrintingCommands.cpp" line="107"/>
<source>#processing_fee</source>
<translation type="unfinished"></translation>
</message>


+ 4
- 4
3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_ru.ts View File

@@ -12,7 +12,7 @@
<context>
<name>GUIService</name>
<message>
<location filename="../Services/GUIService.cpp" line="498"/>
<location filename="../Services/GUIService.cpp" line="497"/>
<source>#penetration_detected</source>
<translation>Попытка удаленного управления</translation>
</message>
@@ -20,17 +20,17 @@
<context>
<name>PrintFiscalCommand</name>
<message>
<location filename="../Services/PrintingCommands.cpp" line="95"/>
<location filename="../Services/PrintingCommands.cpp" line="100"/>
<source>#bank_fee</source>
<translation>Комиссия БПА</translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="96"/>
<location filename="../Services/PrintingCommands.cpp" line="101"/>
<source>#dealer_fee</source>
<translation>Комиссия субагента</translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="102"/>
<location filename="../Services/PrintingCommands.cpp" line="107"/>
<source>#processing_fee</source>
<translation>Комиссия КБ Платина</translation>
</message>


+ 4
- 4
3.0/src/apps/PaymentProcessor/src/locale/paymentprocessor_ru_bankomat.ts View File

@@ -12,7 +12,7 @@
<context>
<name>GUIService</name>
<message>
<location filename="../Services/GUIService.cpp" line="498"/>
<location filename="../Services/GUIService.cpp" line="497"/>
<source>#penetration_detected</source>
<translation>Попытка удаленного управления</translation>
</message>
@@ -20,17 +20,17 @@
<context>
<name>PrintFiscalCommand</name>
<message>
<location filename="../Services/PrintingCommands.cpp" line="95"/>
<location filename="../Services/PrintingCommands.cpp" line="100"/>
<source>#bank_fee</source>
<translation>Комиссия БПА</translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="96"/>
<location filename="../Services/PrintingCommands.cpp" line="101"/>
<source>#dealer_fee</source>
<translation>Комиссия субагента</translation>
</message>
<message>
<location filename="../Services/PrintingCommands.cpp" line="102"/>
<location filename="../Services/PrintingCommands.cpp" line="107"/>
<source>#processing_fee</source>
<translation>Комиссия КБ Платина</translation>
</message>


+ 28
- 4
3.0/src/includes/Hardware/Printers/PrinterConstants.h View File

@@ -2,10 +2,7 @@

#pragma once

#include "Common/QtHeadersBegin.h"
#include <QtCore/QString>
#include <QtCore/QByteArray>
#include "Common/QtHeadersEnd.h"
#include "Hardware/Common/Specifications.h"

//--------------------------------------------------------------------------------
namespace CPrinters
@@ -35,6 +32,33 @@ namespace CPrinters
Retract /// Забрать в ретрактор.
};
}

/// Автозамена символов.
class CAutoCorrection: public CSpecification<QChar, QChar>
{
public:
CAutoCorrection::CAutoCorrection()
{
add("«", "\"");
add("»", "\"");
add("˝", "\"");
add("˵", "\"");
add("˶", "\"");
add("″", "\"");
add("“", "\"");
add("”", "\"");
add("і", "i"); // кириллическая буква, украинский и белорусский языки.
add("І", "I"); // кириллическая буква, украинский и белорусский языки.
}

private:
void add(const char * aKey, const char * aValue)
{
mBuffer.insert(QString::fromUtf8(aKey)[0], QString::fromUtf8(aValue)[0]);
}
};

static CAutoCorrection AutoCorrection;
}

//--------------------------------------------------------------------------------

+ 2
- 0
3.0/src/interface/modern/main_menu_scene.qml View File

@@ -155,6 +155,8 @@ Widgets.SceneBase {

// Переход в категорию/подкатегорию
function goToCategory(aId, aIsGroup, aSelectedIndex) {
GUI.log("GO TO CATEGORY: ", aId, aIsGroup, aSelectedIndex)

if (aIsGroup) {
global.menuLevel = MenuWalker.go(aId, operatorSelector.getCurrentPosition());
Utils.playSound(Scenario.Sound.ChooseOperator);


+ 13
- 5
3.0/src/interface/modern/scene_with_context/operators/11611/widgets/Car.qml View File

@@ -1,4 +1,4 @@
import QtQuick 1.1
import QtQuick 1.1

Component {
BorderImage {
@@ -19,10 +19,18 @@ Component {
width: 250
anchors.verticalCenter: parent.verticalCenter

Text {
text: "Вагон №%1".arg(model.Number)
color: Utils.ui.color("color.title")
font: Utils.ui.font("font.main.accent")
Row {
spacing: 10
Text {
text: "Вагон №%1".arg(model.Number)
color: Utils.ui.color("color.title")
font: Utils.ui.font("font.main.accent")
}
Image {
anchors.verticalCenter: parent.verticalCenter
source: "images/er.png"
visible: model.ElRegPossible
}
}

Text {


BIN
3.0/src/interface/modern/scene_with_context/operators/11611/widgets/images/er.png View File

Before After
Width: 25  |  Height: 18  |  Size: 1.5KB

+ 15
- 5
3.0/src/interface/modern/scene_with_context/operators/11611/widgets/kzd_calendar_editor.qml View File

@@ -1,4 +1,4 @@
/* @file Редактор выбора даты. */
/* @file Редактор выбора даты. */

import QtQuick 1.1
import "../../../../widgets" 1.0 as Widgets
@@ -102,8 +102,7 @@ FocusScope {
width: view.cellWidth
height: view.cellHeight

//!modelData.isActive ? "transparent"
//прячем дни пред и пост месяцев. так проще, чем переделывать модель :)
//Дизаблим дни пред и пост месяцев. так проще, чем переделывать модель :)

Rectangle {
id: background
@@ -111,7 +110,7 @@ FocusScope {
width: 164
height:60
radius: 4
color: modelData.isSelected ? Utils.ui.color("color.button.primary.background") : (modelData.isActive ? Utils.ui.color("color.title") : "transparent")
color: modelData.isSelected ? Utils.ui.color("color.button.primary.background") : Utils.ui.color("color.title")//(modelData.isActive ? Utils.ui.color("color.title") : "transparent")

Text {
anchors.fill: parent
@@ -257,9 +256,20 @@ FocusScope {
});
}

function checkActiveDay(aDayNumber) {
if (__year < __today.getFullYear()) return false

else if (__year == __today.getFullYear()) {
if (__month < __today.getMonth()) return false
if (__month == __today.getMonth() && aDayNumber < __today.getDate()) return false
}

return true
}

for (var ii = 1; ii <= daysInMonth(__year, __month); ii++) {
model.push({ dayNumber: ii,
isActive: true,
isActive: checkActiveDay(ii),
isSelected: false,
isToday: (__today.getMonth() === __month) ? (__today.getDate() == ii) : ii == 1,
isHoliday: isHoliday(__month, ii),


+ 8
- 2
3.0/src/interface/modern/scene_with_context/operators/11611/widgets/kzd_enum_editor.qml View File

@@ -164,10 +164,14 @@ Item {
}
else {
ticket = Core.userProperties.get("ticket");
global.timeInWay = ticket.timeInWay.split(":")[0]
global.timeInWay = Number(ticket.timeInWay.split(":")[0])
global.timeInWay = global.timeInWay ? global.timeInWay : 1 // Скорректируем до часа

GUI.notify("update_fields", {fields: [{"id": "wo_bedding", "behavior": "readonly", "default_value": "1"}]});

//ticket.type=3 плацкарт
if (ticket.type == 3 && global.timeInWay < 6) {
// Время в пути больше суток кодируется количество_суток.оставшиеся_часы
if (ticket.type == 3 && (global.timeInWay.indexOf(".") == -1 && global.timeInWay < 6)) {
GUI.notify("update_fields", {fields: [{"id": "wo_bedding", "behavior": ""}]});
}
}
@@ -180,6 +184,8 @@ Item {

description.comment = aField.extendedComment ? "" : Utils.toPlain(aField.comment);

GUI.log(aField, aValue)

// Установка текущего значения
if (rootItem.setupDefaultValue) {
if (aValue == undefined || (aValue.value == 0 || aValue.value == "") || (aValue.value instanceof Array ?


+ 1
- 1
3.0/src/interface/modern/scene_with_context/operators/11611/widgets/kzd_ticket_editor.qml View File

@@ -196,7 +196,7 @@ Item {
doc: $("doc", num),
docType: $("doc_type", num, true),
sex: $("sex", num, true),
citizenship: $("citizenship", num),
citizenship: $("citizenship", num, true),
childBirthday: fields.hasOwnProperty("birthday%1".arg(num)) ? $("birthday", num) : "",
needPlace: fields.hasOwnProperty("need_place%1".arg(num)) ? $("need_place", num, true) : 1,
phone: fields.hasOwnProperty("phone%1".arg(num)) ? $("phone", num) : ""


+ 3
- 2
3.0/src/interface/modern/scripts/gui.js View File

@@ -41,10 +41,11 @@ function countdown(aText, aTimeout) {
}

//------------------------------------------------------------------------------
function notification(aText, aTimeout, aResult) {
function notification(aText, aTimeout, aResult, aHandler) {
log(typeof aHandler)
popup("InfoPopup", {reset: true,
message: aText, timeout: __isValid(aTimeout) ? aTimeout : 10000,
cancelable: true, result: __isValid(aResult) ? aResult : ""});
cancelable: true, result: __isValid(aResult) ? aResult : "", handler: aHandler});
}

// button: { result: "", text: "", ... }


+ 6
- 1
3.0/src/interface/modern/widgets/ad.qml View File

@@ -1,5 +1,6 @@
import QtQuick 1.1
import "." 1.0 as Widgets
import "../scripts/gui.js" as GUI

Item {
id: rootItem
@@ -19,8 +20,12 @@ Item {

onFlashChanged: Core.ad.addEvent(type, {})
onPopuped: rootItem.popuped(aParameters.html)
onClicked: rootItem.clicked(aParameters.hasOwnProperty("id") ? aParameters.id : -1,
onClicked: {
GUI.log("BANNER CLICKED: ", aParameters)
// Для групп указывается id без префикса
rootItem.clicked(aParameters.hasOwnProperty("id") ? aParameters.id : -1,
aParameters.hasOwnProperty("group") ? aParameters.group : false)
}
}

function reset() {


+ 3
- 3
3.0/src/interface/modern/widgets/enum_editor.qml View File

@@ -71,9 +71,10 @@ Item {
global.savedState = rootItem.acceptable;
global.enabled = false;
global.id = aField.id;
var readonly = aField.hasOwnProperty("behavior") && aField.behavior == "readonly";

try {
var readonly = aField.hasOwnProperty("behavior") && aField.behavior == "readonly"

description.title = aField.title + (aField.isRequired ? "" : Utils.locale.tr(QT_TRANSLATE_NOOP("editor", "editor#not_required")));
description.title += readonly ? Utils.locale.tr(QT_TRANSLATE_NOOP("editor", "editor#readonly")) : ""
description.comment = aField.extendedComment ? "" : Utils.toPlain(aField.comment);
@@ -104,8 +105,7 @@ Item {
}
}

list.readonly = readonly;

list.readonly = readonly
} catch (e) {
Core.log.error("Failed to setup editor for field %1: %2.".arg(aField.id).arg(e.message));
}


+ 1
- 0
3.0/src/interface/modern/widgets/list.qml View File

@@ -263,5 +263,6 @@ Item {
view.currentIndex = -1;
rootItem.__doubleHeightMode = false;
rootItem.__halfFontHeightMode = false;
rootItem.readonly = false
}
}

+ 1
- 1
3.0/src/modules/GraphicsEngine/src/GraphicsEngine.cpp View File

@@ -1,4 +1,4 @@
/* @file Графический интерфейс. */
/* @file Графический интерфейс. */


// Qt


+ 1
- 1
3.0/src/modules/Hardware/CashAcceptors/src/CCNet/FirmwareVersions.h View File

@@ -26,7 +26,7 @@ namespace CCCNet

data()[Models::CashcodeSM ][Currency::RUB][true] = TFimwareVersionSet() << 1353;

data()[Models::CashcodeSM ][Currency::RUB][false] = TFimwareVersionSet() << 1378 << 1434;
data()[Models::CashcodeSM ][Currency::RUB][false] = TFimwareVersionSet() << 1382 << 1434;
data()[Models::CashcodeMSM][Currency::RUB][false] = TFimwareVersionSet() << 1115;
data()[Models::CashcodeMSM][Currency::EUR][false] = TFimwareVersionSet() << 1130 << 1228 << 1329 << 1411 << 1527;
data()[Models::CashcodeMVU][Currency::RUB][false] = TFimwareVersionSet() << 1330;


+ 5
- 0
3.0/src/modules/Hardware/Printers/src/Base/PrinterBase.cpp View File

@@ -147,6 +147,11 @@ void PrinterBase<T>::cleanReceipt(QStringList & aReceipt)
for (int i = 0; i < aReceipt.size(); ++i)
{
aReceipt[i] = aReceipt[i].replace(ASCII::TAB, ASCII::Space);

for (auto it = CPrinters::AutoCorrection.data().begin(); it != CPrinters::AutoCorrection.data().end(); ++it)
{
aReceipt[i] = aReceipt[i].replace(it.key(), it.value());
}
}

for (int i = 0; i < aReceipt.size(); ++i)


+ 2
- 2
3.0/src/modules/Hardware/Printers/src/POSPrinters/Custom/CustomKZTCodec.h View File

@@ -33,8 +33,8 @@ public:
mData.add('\xB9', "ө");
mData.add('\xBA', "Ұ");
mData.add('\xBB', "ұ");
//mData.add('\xBC', "U");
//mData.add('\xBD', "u");
mData.add('\xBC', "Ү");
mData.add('\xBD', "ү");
mData.add('\xBE', "Һ");
mData.add('\xBF', "һ");
}


Loading…
Cancel
Save