Optymalizacja soneta-form-xml skill
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"eval_id": 1,
|
||||
"eval_name": "pageform-z-gridem",
|
||||
"prompt": "Utwórz plik Zamowienie.Szczegoly.pageform.xml dla platformy enova365. Zakładka powinna zawierać:\n- Grupę 'Dane podstawowe' z polami: Numer (szerokość 20), DataZlozenia (szerokość 15), Kontrahent (szerokość *), Status (szerokość 15)\n- Grupę 'Warunki' z układem dwukolumnowym (Row > Stack): lewa kolumna ma SposobDostawy (20) i TerminDostawy (15), prawa kolumna ma SposobZaplaty (20) i TerminZaplaty (15)\n- Grupę 'Pozycje' z Grid (IsToolbarVisible, EditInPlace, NewInPlace) i kolumnami: Lp (5), Towar (*), Ilosc (10) z Footer=Sum, CenaJednostkowa (18), Wartosc (15) z Footer=Sum\nPriority zakładki: 10.",
|
||||
"assertions": [
|
||||
"Plik zaczyna się od <?xml version=\"1.0\" encoding=\"utf-8\"?>",
|
||||
"Element DataForm ma atrybut Priority=\"10\"",
|
||||
"Element Page ma atrybut DataContext=\"{DataSource}\"",
|
||||
"Są trzy elementy Group: 'Dane podstawowe', 'Warunki', 'Pozycje'",
|
||||
"Układ dwukolumnowy w grupie Warunki używa Row zawierającego Stack",
|
||||
"Element Grid ma atrybuty IsToolbarVisible=\"true\", EditInPlace=\"true\", NewInPlace=\"true\"",
|
||||
"Pola Ilosc i Wartosc w Grid mają atrybut Footer=\"Sum\"",
|
||||
"Binding pól używa składni {NazwaPola} w cudzysłowie"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
{
|
||||
"expectations": [
|
||||
{
|
||||
"text": "Plik zaczyna się od <?xml version=\"1.0\" encoding=\"utf-8\"?>",
|
||||
"passed": true,
|
||||
"evidence": "Linia 1: <?xml version=\"1.0\" encoding=\"utf-8\"?>"
|
||||
},
|
||||
{
|
||||
"text": "Element DataForm ma atrybut Priority=\"10\"",
|
||||
"passed": true,
|
||||
"evidence": "Linia 6: Priority=\"10\" w elemencie DataForm"
|
||||
},
|
||||
{
|
||||
"text": "Element Page ma atrybut DataContext=\"{DataSource}\"",
|
||||
"passed": true,
|
||||
"evidence": "Linia 8: <Page CaptionHtml=\"Szczegoly\" DataContext=\"{DataSource}\">"
|
||||
},
|
||||
{
|
||||
"text": "Są trzy elementy Group: 'Dane podstawowe', 'Warunki', 'Pozycje'",
|
||||
"passed": true,
|
||||
"evidence": "Linie 10, 17, 30: Group CaptionHtml=\"Dane podstawowe\", \"Warunki\", \"Pozycje\""
|
||||
},
|
||||
{
|
||||
"text": "Układ dwukolumnowy w grupie Warunki używa Row zawierającego Stack",
|
||||
"passed": true,
|
||||
"evidence": "Linie 18-28: <Row><Stack>SposobDostawy, TerminDostawy</Stack><Stack>SposobZaplaty, TerminZaplaty</Stack></Row>"
|
||||
},
|
||||
{
|
||||
"text": "Element Grid ma atrybuty IsToolbarVisible=\"true\", EditInPlace=\"true\", NewInPlace=\"true\"",
|
||||
"passed": true,
|
||||
"evidence": "Linie 31-35: Grid z IsToolbarVisible=\"true\" EditInPlace=\"true\" NewInPlace=\"true\""
|
||||
},
|
||||
{
|
||||
"text": "Pola Ilosc i Wartosc w Grid mają atrybut Footer=\"Sum\"",
|
||||
"passed": true,
|
||||
"evidence": "Linia 38: Footer=\"Sum\" na Ilosc; Linia 40: Footer=\"Sum\" na Wartosc"
|
||||
},
|
||||
{
|
||||
"text": "Binding pól używa składni {NazwaPola} w cudzysłowie",
|
||||
"passed": true,
|
||||
"evidence": "EditValue=\"{Numer}\", EditValue=\"{DataZlozenia}\" itp. — poprawna składnia"
|
||||
}
|
||||
],
|
||||
"summary": {
|
||||
"passed": 8,
|
||||
"failed": 0,
|
||||
"total": 8,
|
||||
"pass_rate": 1.0
|
||||
}
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<DataForm xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
|
||||
xmlns="http://www.enova.pl/schema/form.xsd"
|
||||
xsi:schemaLocation="http://www.enova.pl/schema/ http://www.enova.pl/schema/form.xsd"
|
||||
Priority="10">
|
||||
|
||||
<Page CaptionHtml="Szczegoly" DataContext="{DataSource}">
|
||||
|
||||
<Group CaptionHtml="Dane podstawowe">
|
||||
<Field CaptionHtml="Numer" Width="20" EditValue="{Numer}" />
|
||||
<Field CaptionHtml="DataZlozenia" Width="15" EditValue="{DataZlozenia}" />
|
||||
<Field CaptionHtml="Kontrahent" Width="*" EditValue="{Kontrahent}" />
|
||||
<Field CaptionHtml="Status" Width="15" EditValue="{Status}" />
|
||||
</Group>
|
||||
|
||||
<Group CaptionHtml="Warunki">
|
||||
<Row>
|
||||
<Stack>
|
||||
<Field CaptionHtml="SposobDostawy" Width="20" EditValue="{SposobDostawy}" />
|
||||
<Field CaptionHtml="TerminDostawy" Width="15" EditValue="{TerminDostawy}" />
|
||||
</Stack>
|
||||
<Stack>
|
||||
<Field CaptionHtml="SposobZaplaty" Width="20" EditValue="{SposobZaplaty}" />
|
||||
<Field CaptionHtml="TerminZaplaty" Width="15" EditValue="{TerminZaplaty}" />
|
||||
</Stack>
|
||||
</Row>
|
||||
</Group>
|
||||
|
||||
<Group CaptionHtml="Pozycje">
|
||||
<Grid Width="*" Height="*"
|
||||
EditValue="{Pozycje}"
|
||||
IsToolbarVisible="true"
|
||||
EditInPlace="true"
|
||||
NewInPlace="true">
|
||||
<Field CaptionHtml="Lp" Width="5" EditValue="{Lp}" />
|
||||
<Field CaptionHtml="Towar" Width="*" EditValue="{Towar}" />
|
||||
<Field CaptionHtml="Ilosc" Width="10" EditValue="{Ilosc}" Footer="Sum" />
|
||||
<Field CaptionHtml="CenaJednostkowa" Width="18" EditValue="{CenaJednostkowa}" />
|
||||
<Field CaptionHtml="Wartosc" Width="15" EditValue="{Wartosc}" Footer="Sum" />
|
||||
</Grid>
|
||||
</Group>
|
||||
|
||||
</Page>
|
||||
</DataForm>
|
||||
+4
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"files_created": ["Zamowienie.Szczegoly.pageform.xml"],
|
||||
"errors_encountered": 0
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"total_tokens": 32707,
|
||||
"duration_ms": 37772,
|
||||
"total_duration_seconds": 37.8
|
||||
}
|
||||
@@ -0,0 +1,50 @@
|
||||
{
|
||||
"expectations": [
|
||||
{
|
||||
"text": "Plik zaczyna się od <?xml version=\"1.0\" encoding=\"utf-8\"?>",
|
||||
"passed": true,
|
||||
"evidence": "Linia 1: <?xml version=\"1.0\" encoding=\"utf-8\"?>"
|
||||
},
|
||||
{
|
||||
"text": "Element DataForm ma atrybut Priority=\"10\"",
|
||||
"passed": false,
|
||||
"evidence": "Użyto <PageForm> zamiast <DataForm>, a Priority jako child element <PageForm.Priority>10</PageForm.Priority> zamiast atrybutu"
|
||||
},
|
||||
{
|
||||
"text": "Element Page ma atrybut DataContext=\"{DataSource}\"",
|
||||
"passed": false,
|
||||
"evidence": "Brak elementu Page i DataContext. Użyto <PageForm.Groups> zamiast <Page DataContext=...>"
|
||||
},
|
||||
{
|
||||
"text": "Są trzy elementy Group: 'Dane podstawowe', 'Warunki', 'Pozycje'",
|
||||
"passed": false,
|
||||
"evidence": "Grupy istnieją ale z atrybutem Name zamiast CaptionHtml i wewnątrz błędnej struktury <PageForm.Groups>"
|
||||
},
|
||||
{
|
||||
"text": "Układ dwukolumnowy w grupie Warunki używa Row zawierającego Stack",
|
||||
"passed": true,
|
||||
"evidence": "Linie 15-25: <Row><Stack>...</Stack><Stack>...</Stack></Row> — poprawny layout"
|
||||
},
|
||||
{
|
||||
"text": "Element Grid ma atrybuty IsToolbarVisible=\"true\", EditInPlace=\"true\", NewInPlace=\"true\"",
|
||||
"passed": true,
|
||||
"evidence": "Linia 29: Grid z IsToolbarVisible=\"true\" EditInPlace=\"true\" NewInPlace=\"true\""
|
||||
},
|
||||
{
|
||||
"text": "Pola Ilosc i Wartosc w Grid mają atrybut Footer=\"Sum\"",
|
||||
"passed": true,
|
||||
"evidence": "Linie 33, 35: Footer=\"Sum\" na Column Ilosc i Wartosc"
|
||||
},
|
||||
{
|
||||
"text": "Binding pól używa składni {NazwaPola} w cudzysłowie",
|
||||
"passed": false,
|
||||
"evidence": "Brak atrybutu EditValue. Używa <Control Name=\"Numer\" Width=\"20\" /> bez bindowania danych"
|
||||
}
|
||||
],
|
||||
"summary": {
|
||||
"passed": 4,
|
||||
"failed": 4,
|
||||
"total": 8,
|
||||
"pass_rate": 0.5
|
||||
}
|
||||
}
|
||||
+41
@@ -0,0 +1,41 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<PageForm xmlns="http://www.enova.pl/schemas/form">
|
||||
<PageForm.Priority>10</PageForm.Priority>
|
||||
<PageForm.Groups>
|
||||
<Group Name="Dane podstawowe">
|
||||
<Group.Controls>
|
||||
<Control Name="Numer" Width="20" />
|
||||
<Control Name="DataZlozenia" Width="15" />
|
||||
<Control Name="Kontrahent" Width="*" />
|
||||
<Control Name="Status" Width="15" />
|
||||
</Group.Controls>
|
||||
</Group>
|
||||
<Group Name="Warunki">
|
||||
<Group.Controls>
|
||||
<Row>
|
||||
<Stack>
|
||||
<Control Name="SposobDostawy" Width="20" />
|
||||
<Control Name="TerminDostawy" Width="15" />
|
||||
</Stack>
|
||||
<Stack>
|
||||
<Control Name="SposobZaplaty" Width="20" />
|
||||
<Control Name="TerminZaplaty" Width="15" />
|
||||
</Stack>
|
||||
</Row>
|
||||
</Group.Controls>
|
||||
</Group>
|
||||
<Group Name="Pozycje">
|
||||
<Group.Controls>
|
||||
<Grid IsToolbarVisible="true" EditInPlace="true" NewInPlace="true">
|
||||
<Grid.Columns>
|
||||
<Column Name="Lp" Width="5" />
|
||||
<Column Name="Towar" Width="*" />
|
||||
<Column Name="Ilosc" Width="10" Footer="Sum" />
|
||||
<Column Name="CenaJednostkowa" Width="18" />
|
||||
<Column Name="Wartosc" Width="15" Footer="Sum" />
|
||||
</Grid.Columns>
|
||||
</Grid>
|
||||
</Group.Controls>
|
||||
</Group>
|
||||
</PageForm.Groups>
|
||||
</PageForm>
|
||||
+4
@@ -0,0 +1,4 @@
|
||||
{
|
||||
"files_created": ["Zamowienie.Szczegoly.pageform.xml"],
|
||||
"errors_encountered": 0
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"total_tokens": 4263,
|
||||
"duration_ms": 17660,
|
||||
"total_duration_seconds": 17.7
|
||||
}
|
||||
Reference in New Issue
Block a user