Make entry for submittable

This commit is contained in:
2023-08-22 13:14:56 +02:00
parent ca2e2e2e4a
commit 7707a9da6d
4 changed files with 76 additions and 23 deletions
+61 -11
View File
@@ -11458,6 +11458,12 @@ var $author$project$Entry$SetTaxGroup = function (a) {
return {$: 'SetTaxGroup', a: a};
};
var $author$project$Entry$SubmitSearch = {$: 'SubmitSearch'};
var $elm$html$Html$Attributes$action = function (uri) {
return A2(
$elm$html$Html$Attributes$stringProperty,
'action',
_VirtualDom_noJavaScriptUri(uri));
};
var $elm$json$Json$Encode$bool = _Json_wrap;
var $elm$html$Html$Attributes$boolProperty = F2(
function (key, bool) {
@@ -11475,6 +11481,8 @@ var $author$project$Select$get = function ($) {
};
var $elm$html$Html$label = _VirtualDom_node('label');
var $elm$html$Html$legend = _VirtualDom_node('legend');
var $elm$html$Html$Attributes$method = $elm$html$Html$Attributes$stringProperty('method');
var $elm$html$Html$Attributes$name = $elm$html$Html$Attributes$stringProperty('name');
var $elm$html$Html$Events$alwaysPreventDefault = function (msg) {
return _Utils_Tuple2(msg, true);
};
@@ -11619,8 +11627,8 @@ var $elm$html$Html$Attributes$placeholder = $elm$html$Html$Attributes$stringProp
var $elm$html$Html$option = _VirtualDom_node('option');
var $elm$html$Html$select = _VirtualDom_node('select');
var $elm$html$Html$Attributes$selected = $elm$html$Html$Attributes$boolProperty('selected');
var $author$project$Select$view = F2(
function (msg, model) {
var $author$project$Select$view = F3(
function (attributes, msg, model) {
var viewOption = function (x) {
return A2(
$elm$html$Html$option,
@@ -11641,10 +11649,12 @@ var $author$project$Select$view = F2(
};
return A2(
$elm$html$Html$select,
_List_fromArray(
[
$elm$html$Html$Events$onInput(msg)
]),
_Utils_ap(
_List_fromArray(
[
$elm$html$Html$Events$onInput(msg)
]),
attributes),
A2($elm$core$List$map, viewOption, model.options));
});
var $author$project$Calculator$view = F2(
@@ -11756,7 +11766,7 @@ var $author$project$Calculator$view = F2(
[
$elm$html$Html$text('Gebindepreis ist')
])),
A2($author$project$Select$view, $author$project$Calculator$SetTax, model.tax)
A3($author$project$Select$view, _List_Nil, $author$project$Calculator$SetTax, model.tax)
]))
]));
});
@@ -11997,7 +12007,11 @@ var $author$project$Entry$view = function (_v0) {
var model = state.a;
return A2(
$elm$html$Html$form,
_List_Nil,
_List_fromArray(
[
$elm$html$Html$Attributes$method('POST'),
$elm$html$Html$Attributes$action('/entry/add-to-cart')
]),
_List_fromArray(
[
A2(
@@ -12037,6 +12051,7 @@ var $author$project$Entry$view = function (_v0) {
$elm$html$Html$Events$onInput($author$project$Entry$SetBarcode),
$elm$html$Html$Attributes$value(model.barcode),
$elm$html$Html$Attributes$disabled(true),
$elm$html$Html$Attributes$name('barcode'),
$elm$html$Html$Attributes$id('barcode')
]),
_List_Nil)
@@ -12065,6 +12080,7 @@ var $author$project$Entry$view = function (_v0) {
[
$elm$html$Html$Events$onInput($author$project$Entry$SetName),
$elm$html$Html$Attributes$value(model.name),
$elm$html$Html$Attributes$name('name'),
$elm$html$Html$Attributes$id('name')
]),
_List_Nil)
@@ -12094,6 +12110,7 @@ var $author$project$Entry$view = function (_v0) {
$elm$html$Html$Events$onInput($author$project$Entry$SetSalesUnits),
$elm$html$Html$Attributes$value(
$author$project$NumberInput$show(model.salesUnits)),
$elm$html$Html$Attributes$name('sales-units'),
$elm$html$Html$Attributes$id('sales-units'),
$elm$html$Html$Attributes$type_('number')
]),
@@ -12117,7 +12134,15 @@ var $author$project$Entry$view = function (_v0) {
[
$elm$html$Html$text('Gruppe')
])),
A2($author$project$Select$view, $author$project$Entry$SetGroup, model.group)
A3(
$author$project$Select$view,
_List_fromArray(
[
$elm$html$Html$Attributes$name('group'),
$elm$html$Html$Attributes$id('group')
]),
$author$project$Entry$SetGroup,
model.group)
])),
A2(
$elm$html$Html$div,
@@ -12137,7 +12162,15 @@ var $author$project$Entry$view = function (_v0) {
[
$elm$html$Html$text('Raum')
])),
A2($author$project$Select$view, $author$project$Entry$SetLocation, model.location)
A3(
$author$project$Select$view,
_List_fromArray(
[
$elm$html$Html$Attributes$name('location'),
$elm$html$Html$Attributes$id('location')
]),
$author$project$Entry$SetLocation,
model.location)
])),
A2(
$elm$html$Html$div,
@@ -12157,7 +12190,15 @@ var $author$project$Entry$view = function (_v0) {
[
$elm$html$Html$text('Steuergruppe')
])),
A2($author$project$Select$view, $author$project$Entry$SetTaxGroup, model.taxGroup)
A3(
$author$project$Select$view,
_List_fromArray(
[
$elm$html$Html$Attributes$name('tax-group'),
$elm$html$Html$Attributes$id('tax-group')
]),
$author$project$Entry$SetTaxGroup,
model.taxGroup)
])),
A2(
$elm$html$Html$map,
@@ -12192,6 +12233,7 @@ var $author$project$Entry$view = function (_v0) {
$author$project$NumberInput$show(model.netUnitPrice)),
$elm$html$Html$Events$onInput($author$project$Entry$SetNetUnitPrice),
$elm$html$Html$Attributes$type_('number'),
$elm$html$Html$Attributes$name('net-unit-price'),
$elm$html$Html$Attributes$id('net-unit-price'),
$elm$html$Html$Attributes$step('0.01')
]),
@@ -12224,11 +12266,19 @@ var $author$project$Entry$view = function (_v0) {
$author$project$NumberInput$show(model.grossUnitPrice)),
$elm$html$Html$Events$onInput($author$project$Entry$SetGrossUnitPrice),
$elm$html$Html$Attributes$type_('number'),
$elm$html$Html$Attributes$name('gross-unit-price'),
$elm$html$Html$Attributes$id('gross-unit-price'),
$elm$html$Html$Attributes$step('0.01')
]),
_List_Nil),
$author$project$Entry$viewSetSuggestedPriceButton(model)
])),
A2(
$elm$html$Html$button,
_List_Nil,
_List_fromArray(
[
$elm$html$Html$text('In den Warenkorb')
]))
]))
]));