Aggiungi conto corrente
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -25,45 +25,6 @@
|
|||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" attributes="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace min="-2" pref="17" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" attributes="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="lblDataDiNascita" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lblSaldoIniziale" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="18" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
|
||||||
<Group type="102" attributes="0">
|
|
||||||
<Component id="txtDataDiNascita" min="-2" pref="64" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
|
||||||
<Component id="btnDataDiNascita" min="-2" pref="39" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<Component id="txtSaldoIniziale" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="37" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="btnVersamento" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="btnPrelievo" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="btnListaMovimenti" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" attributes="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="lblNome" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lblCognome" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lblCodiceFiscale" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="26" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="txtNome" min="-2" pref="113" max="-2" attributes="0"/>
|
|
||||||
<Component id="txtCodiceFiscale" min="-2" pref="115" max="-2" attributes="0"/>
|
|
||||||
<Component id="txtCognome" min="-2" pref="113" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace min="-2" pref="99" max="-2" attributes="0"/>
|
<EmptySpace min="-2" pref="99" max="-2" attributes="0"/>
|
||||||
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
||||||
@@ -75,6 +36,48 @@
|
|||||||
</Group>
|
</Group>
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
<EmptySpace max="32767" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
|
<Group type="102" alignment="0" attributes="0">
|
||||||
|
<EmptySpace min="-2" pref="17" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="lblDataDiNascita" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblSaldoIniziale" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="18" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Component id="txtDataDiNascita" min="-2" pref="64" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnDataDiNascita" min="-2" pref="39" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<Component id="txtSaldoIniziale" max="32767" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="lblNome" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblCognome" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblCodiceFiscale" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="26" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="txtNome" min="-2" pref="113" max="-2" attributes="0"/>
|
||||||
|
<Component id="txtCodiceFiscale" min="-2" pref="115" max="-2" attributes="0"/>
|
||||||
|
<Component id="txtCognome" min="-2" pref="113" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace pref="39" max="32767" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||||
|
<Component id="lblNumeroContoCorrente" max="32767" attributes="0"/>
|
||||||
|
<Component id="btnVersamento" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnPrelievo" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnListaMovimenti" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="txtNumeroContoCorrente" alignment="0" max="32767" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="23" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
<DimensionLayout dim="1">
|
<DimensionLayout dim="1">
|
||||||
@@ -84,36 +87,46 @@
|
|||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="lblNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="txtNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblNumeroContoCorrente" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="lblCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="txtCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="btnVersamento" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtNumeroContoCorrente" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Component id="lblCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Group type="102" attributes="0">
|
||||||
<Component id="txtCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="btnPrelievo" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
<Component id="txtCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
</Group>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Component id="lblDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="txtDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="btnDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="btnListaMovimenti" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="btnDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="lblSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="txtSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Component id="btnVersamento" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnPrelievo" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnListaMovimenti" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
<EmptySpace pref="37" max="32767" attributes="0"/>
|
||||||
<Component id="jScrollPane1" min="-2" pref="65" max="-2" attributes="0"/>
|
<Component id="jScrollPane1" min="-2" pref="65" max="-2" attributes="0"/>
|
||||||
<EmptySpace pref="9" max="32767" attributes="0"/>
|
<EmptySpace min="-2" pref="14" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@@ -221,5 +234,12 @@
|
|||||||
</Component>
|
</Component>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Container>
|
</Container>
|
||||||
|
<Component class="javax.swing.JLabel" name="lblNumeroContoCorrente">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" value="Numero conto corrente:"/>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JTextField" name="txtNumeroContoCorrente">
|
||||||
|
</Component>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Form>
|
</Form>
|
||||||
|
|||||||
Binary file not shown.
@@ -2,6 +2,8 @@
|
|||||||
<project-private xmlns="http://www.netbeans.org/ns/project-private/1">
|
<project-private xmlns="http://www.netbeans.org/ns/project-private/1">
|
||||||
<editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/2" lastBookmarkId="0"/>
|
<editor-bookmarks xmlns="http://www.netbeans.org/ns/editor-bookmarks/2" lastBookmarkId="0"/>
|
||||||
<open-files xmlns="http://www.netbeans.org/ns/projectui-open-files/2">
|
<open-files xmlns="http://www.netbeans.org/ns/projectui-open-files/2">
|
||||||
<group/>
|
<group>
|
||||||
|
<file>file:/home/Verde/git/GUIMyBank/src/gui/GUIMyBank.java</file>
|
||||||
|
</group>
|
||||||
</open-files>
|
</open-files>
|
||||||
</project-private>
|
</project-private>
|
||||||
|
|||||||
@@ -25,45 +25,6 @@
|
|||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" attributes="0">
|
<Group type="102" attributes="0">
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Group type="102" alignment="0" attributes="0">
|
|
||||||
<EmptySpace min="-2" pref="17" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Group type="102" attributes="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="lblDataDiNascita" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lblSaldoIniziale" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="18" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
|
||||||
<Group type="102" attributes="0">
|
|
||||||
<Component id="txtDataDiNascita" min="-2" pref="64" max="-2" attributes="0"/>
|
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
|
||||||
<Component id="btnDataDiNascita" min="-2" pref="39" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<Component id="txtSaldoIniziale" max="32767" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="37" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="btnVersamento" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="btnPrelievo" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="btnListaMovimenti" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" attributes="0">
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="lblNome" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lblCognome" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
<Component id="lblCodiceFiscale" alignment="0" min="-2" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
<EmptySpace min="-2" pref="26" max="-2" attributes="0"/>
|
|
||||||
<Group type="103" groupAlignment="0" attributes="0">
|
|
||||||
<Component id="txtNome" min="-2" pref="113" max="-2" attributes="0"/>
|
|
||||||
<Component id="txtCodiceFiscale" min="-2" pref="115" max="-2" attributes="0"/>
|
|
||||||
<Component id="txtCognome" min="-2" pref="113" max="-2" attributes="0"/>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
</Group>
|
|
||||||
<Group type="102" alignment="0" attributes="0">
|
<Group type="102" alignment="0" attributes="0">
|
||||||
<EmptySpace min="-2" pref="99" max="-2" attributes="0"/>
|
<EmptySpace min="-2" pref="99" max="-2" attributes="0"/>
|
||||||
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
||||||
@@ -75,6 +36,48 @@
|
|||||||
</Group>
|
</Group>
|
||||||
<EmptySpace max="32767" attributes="0"/>
|
<EmptySpace max="32767" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
|
<Group type="102" alignment="0" attributes="0">
|
||||||
|
<EmptySpace min="-2" pref="17" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="lblDataDiNascita" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblSaldoIniziale" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="18" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Component id="txtDataDiNascita" min="-2" pref="64" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnDataDiNascita" min="-2" pref="39" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<Component id="txtSaldoIniziale" max="32767" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="lblNome" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblCognome" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblCodiceFiscale" alignment="0" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="26" max="-2" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
|
<Component id="txtNome" min="-2" pref="113" max="-2" attributes="0"/>
|
||||||
|
<Component id="txtCodiceFiscale" min="-2" pref="115" max="-2" attributes="0"/>
|
||||||
|
<Component id="txtCognome" min="-2" pref="113" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace pref="39" max="32767" attributes="0"/>
|
||||||
|
<Group type="103" groupAlignment="0" max="-2" attributes="0">
|
||||||
|
<Component id="lblNumeroContoCorrente" max="32767" attributes="0"/>
|
||||||
|
<Component id="btnVersamento" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnPrelievo" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnListaMovimenti" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="txtNumeroContoCorrente" alignment="0" max="32767" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
<EmptySpace min="-2" pref="23" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
<DimensionLayout dim="1">
|
<DimensionLayout dim="1">
|
||||||
@@ -84,36 +87,46 @@
|
|||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="lblNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="txtNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtNome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
<Component id="lblNumeroContoCorrente" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="lblCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="txtCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtCognome" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="btnVersamento" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtNumeroContoCorrente" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="0" attributes="0">
|
||||||
<Component id="lblCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Group type="102" attributes="0">
|
||||||
<Component id="txtCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="btnPrelievo" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
<Component id="txtCodiceFiscale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
</Group>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Component id="lblDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="txtDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="btnDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="btnListaMovimenti" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="btnDataDiNascita" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Group type="103" groupAlignment="3" attributes="0">
|
<Group type="103" groupAlignment="3" attributes="0">
|
||||||
<Component id="lblSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="lblSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
<Component id="txtSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
<Component id="txtSaldoIniziale" alignment="3" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
|
</Group>
|
||||||
|
<Group type="102" attributes="0">
|
||||||
|
<Component id="btnVersamento" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnPrelievo" min="-2" max="-2" attributes="0"/>
|
||||||
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
|
<Component id="btnListaMovimenti" min="-2" max="-2" attributes="0"/>
|
||||||
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
<EmptySpace type="separate" max="-2" attributes="0"/>
|
<EmptySpace type="separate" max="-2" attributes="0"/>
|
||||||
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
<Component id="btnAprireContoCorrente" min="-2" max="-2" attributes="0"/>
|
||||||
<EmptySpace type="unrelated" max="-2" attributes="0"/>
|
<EmptySpace pref="37" max="32767" attributes="0"/>
|
||||||
<Component id="jScrollPane1" min="-2" pref="65" max="-2" attributes="0"/>
|
<Component id="jScrollPane1" min="-2" pref="65" max="-2" attributes="0"/>
|
||||||
<EmptySpace pref="9" max="32767" attributes="0"/>
|
<EmptySpace min="-2" pref="14" max="-2" attributes="0"/>
|
||||||
</Group>
|
</Group>
|
||||||
</Group>
|
</Group>
|
||||||
</DimensionLayout>
|
</DimensionLayout>
|
||||||
@@ -221,5 +234,12 @@
|
|||||||
</Component>
|
</Component>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Container>
|
</Container>
|
||||||
|
<Component class="javax.swing.JLabel" name="lblNumeroContoCorrente">
|
||||||
|
<Properties>
|
||||||
|
<Property name="text" type="java.lang.String" value="Numero conto corrente:"/>
|
||||||
|
</Properties>
|
||||||
|
</Component>
|
||||||
|
<Component class="javax.swing.JTextField" name="txtNumeroContoCorrente">
|
||||||
|
</Component>
|
||||||
</SubComponents>
|
</SubComponents>
|
||||||
</Form>
|
</Form>
|
||||||
|
|||||||
@@ -5,6 +5,8 @@
|
|||||||
package gui;
|
package gui;
|
||||||
|
|
||||||
import java.awt.Color;
|
import java.awt.Color;
|
||||||
|
import java.text.ParseException;
|
||||||
|
import java.util.Date;
|
||||||
import java.util.regex.Pattern;
|
import java.util.regex.Pattern;
|
||||||
import logic.MyBank;
|
import logic.MyBank;
|
||||||
import logic.ContoCorrente;
|
import logic.ContoCorrente;
|
||||||
@@ -20,7 +22,7 @@ import javax.swing.border.LineBorder;
|
|||||||
public class GUIMyBank extends javax.swing.JFrame {
|
public class GUIMyBank extends javax.swing.JFrame {
|
||||||
|
|
||||||
static Border borderOriginale = UIManager.getBorder("TextField.border");
|
static Border borderOriginale = UIManager.getBorder("TextField.border");
|
||||||
static ContoCorrente contoCorrente;
|
static ContoCorrente contoCorrenteAperto;
|
||||||
|
|
||||||
private static final java.util.logging.Logger logger = java.util.logging.Logger
|
private static final java.util.logging.Logger logger = java.util.logging.Logger
|
||||||
.getLogger(GUIMyBank.class.getName());
|
.getLogger(GUIMyBank.class.getName());
|
||||||
@@ -30,6 +32,9 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
*/
|
*/
|
||||||
public GUIMyBank() {
|
public GUIMyBank() {
|
||||||
initComponents();
|
initComponents();
|
||||||
|
lblNumeroContoCorrente.setVisible(false);
|
||||||
|
txtNumeroContoCorrente.setVisible(false);
|
||||||
|
txtNumeroContoCorrente.setEditable(false);
|
||||||
btnVersamento.setVisible(false);
|
btnVersamento.setVisible(false);
|
||||||
btnPrelievo.setVisible(false);
|
btnPrelievo.setVisible(false);
|
||||||
btnListaMovimenti.setVisible(false);
|
btnListaMovimenti.setVisible(false);
|
||||||
@@ -45,6 +50,7 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
// <editor-fold defaultstate="collapsed" desc="Generated
|
// <editor-fold defaultstate="collapsed" desc="Generated
|
||||||
// <editor-fold defaultstate="collapsed" desc="Generated
|
// <editor-fold defaultstate="collapsed" desc="Generated
|
||||||
|
// <editor-fold defaultstate="collapsed" desc="Generated
|
||||||
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
|
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
|
||||||
private void initComponents() {
|
private void initComponents() {
|
||||||
|
|
||||||
@@ -65,6 +71,8 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
btnListaMovimenti = new javax.swing.JButton();
|
btnListaMovimenti = new javax.swing.JButton();
|
||||||
jScrollPane1 = new javax.swing.JScrollPane();
|
jScrollPane1 = new javax.swing.JScrollPane();
|
||||||
txtaListaMovimenti = new javax.swing.JTextArea();
|
txtaListaMovimenti = new javax.swing.JTextArea();
|
||||||
|
lblNumeroContoCorrente = new javax.swing.JLabel();
|
||||||
|
txtNumeroContoCorrente = new javax.swing.JTextField();
|
||||||
|
|
||||||
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
|
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
|
||||||
|
|
||||||
@@ -126,41 +134,14 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
txtaListaMovimenti.setRows(5);
|
txtaListaMovimenti.setRows(5);
|
||||||
jScrollPane1.setViewportView(txtaListaMovimenti);
|
jScrollPane1.setViewportView(txtaListaMovimenti);
|
||||||
|
|
||||||
|
lblNumeroContoCorrente.setText("Numero conto corrente:");
|
||||||
|
|
||||||
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
|
javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
|
||||||
getContentPane().setLayout(layout);
|
getContentPane().setLayout(layout);
|
||||||
layout.setHorizontalGroup(
|
layout.setHorizontalGroup(
|
||||||
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addGroup(layout.createSequentialGroup()
|
.addGroup(layout.createSequentialGroup()
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addGroup(layout.createSequentialGroup()
|
|
||||||
.addGap(17, 17, 17)
|
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
|
||||||
.addGroup(layout.createSequentialGroup()
|
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
|
||||||
.addComponent(lblDataDiNascita)
|
|
||||||
.addComponent(lblSaldoIniziale))
|
|
||||||
.addGap(18, 18, 18)
|
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
|
||||||
.addGroup(layout.createSequentialGroup()
|
|
||||||
.addComponent(txtDataDiNascita, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE)
|
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
|
||||||
.addComponent(btnDataDiNascita, javax.swing.GroupLayout.PREFERRED_SIZE, 39, javax.swing.GroupLayout.PREFERRED_SIZE))
|
|
||||||
.addComponent(txtSaldoIniziale))
|
|
||||||
.addGap(37, 37, 37)
|
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
|
||||||
.addComponent(btnVersamento)
|
|
||||||
.addComponent(btnPrelievo)
|
|
||||||
.addComponent(btnListaMovimenti)))
|
|
||||||
.addGroup(layout.createSequentialGroup()
|
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
|
||||||
.addComponent(lblNome)
|
|
||||||
.addComponent(lblCognome)
|
|
||||||
.addComponent(lblCodiceFiscale))
|
|
||||||
.addGap(26, 26, 26)
|
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
|
||||||
.addComponent(txtNome, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE)
|
|
||||||
.addComponent(txtCodiceFiscale, javax.swing.GroupLayout.PREFERRED_SIZE, 115, javax.swing.GroupLayout.PREFERRED_SIZE)
|
|
||||||
.addComponent(txtCognome, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE)))))
|
|
||||||
.addGroup(layout.createSequentialGroup()
|
.addGroup(layout.createSequentialGroup()
|
||||||
.addGap(99, 99, 99)
|
.addGap(99, 99, 99)
|
||||||
.addComponent(btnAprireContoCorrente))
|
.addComponent(btnAprireContoCorrente))
|
||||||
@@ -168,6 +149,38 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
.addGap(56, 56, 56)
|
.addGap(56, 56, 56)
|
||||||
.addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 272, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
.addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 272, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
||||||
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
|
.addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
|
||||||
|
.addGroup(layout.createSequentialGroup()
|
||||||
|
.addGap(17, 17, 17)
|
||||||
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
|
.addGroup(layout.createSequentialGroup()
|
||||||
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
|
.addComponent(lblDataDiNascita)
|
||||||
|
.addComponent(lblSaldoIniziale))
|
||||||
|
.addGap(18, 18, 18)
|
||||||
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
||||||
|
.addGroup(layout.createSequentialGroup()
|
||||||
|
.addComponent(txtDataDiNascita, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||||
|
.addComponent(btnDataDiNascita, javax.swing.GroupLayout.PREFERRED_SIZE, 39, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||||
|
.addComponent(txtSaldoIniziale)))
|
||||||
|
.addGroup(layout.createSequentialGroup()
|
||||||
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
|
.addComponent(lblNome)
|
||||||
|
.addComponent(lblCognome)
|
||||||
|
.addComponent(lblCodiceFiscale))
|
||||||
|
.addGap(26, 26, 26)
|
||||||
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
|
.addComponent(txtNome, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
|
.addComponent(txtCodiceFiscale, javax.swing.GroupLayout.PREFERRED_SIZE, 115, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
|
.addComponent(txtCognome, javax.swing.GroupLayout.PREFERRED_SIZE, 113, javax.swing.GroupLayout.PREFERRED_SIZE))))
|
||||||
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 39, Short.MAX_VALUE)
|
||||||
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
|
||||||
|
.addComponent(lblNumeroContoCorrente, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
|
||||||
|
.addComponent(btnVersamento)
|
||||||
|
.addComponent(btnPrelievo)
|
||||||
|
.addComponent(btnListaMovimenti)
|
||||||
|
.addComponent(txtNumeroContoCorrente))
|
||||||
|
.addGap(23, 23, 23))
|
||||||
);
|
);
|
||||||
layout.setVerticalGroup(
|
layout.setVerticalGroup(
|
||||||
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
@@ -175,41 +188,48 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
.addGap(14, 14, 14)
|
.addGap(14, 14, 14)
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(lblNome)
|
.addComponent(lblNome)
|
||||||
.addComponent(txtNome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
.addComponent(txtNome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
|
.addComponent(lblNumeroContoCorrente))
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(lblCognome)
|
.addComponent(lblCognome)
|
||||||
.addComponent(txtCognome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(txtCognome, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addComponent(btnVersamento))
|
.addComponent(txtNumeroContoCorrente, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||||
.addGap(18, 18, 18)
|
.addGap(18, 18, 18)
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
|
||||||
.addComponent(lblCodiceFiscale)
|
.addGroup(layout.createSequentialGroup()
|
||||||
.addComponent(txtCodiceFiscale, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(btnPrelievo))
|
.addComponent(lblCodiceFiscale)
|
||||||
.addGap(18, 18, 18)
|
.addComponent(txtCodiceFiscale, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGap(18, 18, 18)
|
||||||
.addComponent(lblDataDiNascita)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(txtDataDiNascita, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(lblDataDiNascita)
|
||||||
.addComponent(btnDataDiNascita)
|
.addComponent(txtDataDiNascita, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addComponent(btnListaMovimenti))
|
.addComponent(btnDataDiNascita))
|
||||||
.addGap(18, 18, 18)
|
.addGap(18, 18, 18)
|
||||||
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
.addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
|
||||||
.addComponent(lblSaldoIniziale)
|
.addComponent(lblSaldoIniziale)
|
||||||
.addComponent(txtSaldoIniziale, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
|
.addComponent(txtSaldoIniziale, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)))
|
||||||
|
.addGroup(layout.createSequentialGroup()
|
||||||
|
.addComponent(btnVersamento)
|
||||||
|
.addGap(18, 18, 18)
|
||||||
|
.addComponent(btnPrelievo)
|
||||||
|
.addGap(18, 18, 18)
|
||||||
|
.addComponent(btnListaMovimenti)))
|
||||||
.addGap(18, 18, 18)
|
.addGap(18, 18, 18)
|
||||||
.addComponent(btnAprireContoCorrente)
|
.addComponent(btnAprireContoCorrente)
|
||||||
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
|
.addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 37, Short.MAX_VALUE)
|
||||||
.addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 65, javax.swing.GroupLayout.PREFERRED_SIZE)
|
.addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 65, javax.swing.GroupLayout.PREFERRED_SIZE)
|
||||||
.addContainerGap(9, Short.MAX_VALUE))
|
.addGap(14, 14, 14))
|
||||||
);
|
);
|
||||||
|
|
||||||
pack();
|
pack();
|
||||||
}// </editor-fold>//GEN-END:initComponents
|
}// </editor-fold>//GEN-END:initComponents
|
||||||
|
|
||||||
private void btnListaMovimentiActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnListaMovimentiActionPerformed
|
private void btnListaMovimentiActionPerformed(java.awt.event.ActionEvent evt) {// GEN-FIRST:event_btnListaMovimentiActionPerformed
|
||||||
txtaListaMovimenti.setText(contoCorrente.getLogOperazioni());
|
txtaListaMovimenti.setText(contoCorrente.getLogOperazioni());
|
||||||
txtaListaMovimenti.setVisible(true);
|
txtaListaMovimenti.setVisible(true);
|
||||||
}//GEN-LAST:event_btnListaMovimentiActionPerformed
|
}// GEN-LAST:event_btnListaMovimentiActionPerformed
|
||||||
|
|
||||||
private void txtNomeFocusGained(java.awt.event.FocusEvent evt) {// GEN-FIRST:event_txtNomeFocusGained
|
private void txtNomeFocusGained(java.awt.event.FocusEvent evt) {// GEN-FIRST:event_txtNomeFocusGained
|
||||||
txtNome.setBorder(borderOriginale);
|
txtNome.setBorder(borderOriginale);
|
||||||
@@ -273,18 +293,20 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
}// GEN-LAST:event_btnPrelievoActionPerformed
|
}// GEN-LAST:event_btnPrelievoActionPerformed
|
||||||
|
|
||||||
private void btnAprireContoCorrenteActionPerformed(java.awt.event.ActionEvent evt) {// GEN-FIRST:event_btnAprireContoCorrenteActionPerformed
|
private void btnAprireContoCorrenteActionPerformed(java.awt.event.ActionEvent evt) {// GEN-FIRST:event_btnAprireContoCorrenteActionPerformed
|
||||||
String nome = txtNome.getText();
|
String nome = txtNome.getText().trim();
|
||||||
String cognome = txtCognome.getText();
|
String cognome = txtCognome.getText().trim();
|
||||||
String codiceFiscale = txtCodiceFiscale.getText();
|
String codiceFiscale = txtCodiceFiscale.getText().trim().toUpperCase();
|
||||||
// String dataDiNascita = txtDataDiNascita.getText();
|
String dataDiNascitaString = txtDataDiNascita.getText().trim();
|
||||||
String saldoIniziale = txtSaldoIniziale.getText();
|
Date dataDiNascita;
|
||||||
|
String saldoInizialeString = txtSaldoIniziale.getText().trim();
|
||||||
|
double saldoIniziale;
|
||||||
boolean nomeEmpty = nome.isEmpty();
|
boolean nomeEmpty = nome.isEmpty();
|
||||||
boolean cognomeEmpty = cognome.isEmpty();
|
boolean cognomeEmpty = cognome.isEmpty();
|
||||||
boolean codiceFiscaleEmpty = codiceFiscale.isEmpty();
|
boolean codiceFiscaleEmpty = codiceFiscale.isEmpty();
|
||||||
// boolean dataDiNascitaEmpty = dataDiNascita.isEmpty();
|
boolean dataDiNascitaEmpty = dataDiNascitaString.isEmpty();
|
||||||
boolean saldoInizialeEmpty = saldoIniziale.isEmpty();
|
boolean saldoInizialeEmpty = saldoInizialeString.isEmpty();
|
||||||
|
|
||||||
if (nomeEmpty || cognomeEmpty || codiceFiscaleEmpty /* || dataDiNascitaEmpty */ || saldoInizialeEmpty) {
|
if (nomeEmpty || cognomeEmpty || codiceFiscaleEmpty || dataDiNascitaEmpty || saldoInizialeEmpty) {
|
||||||
if (nomeEmpty) {
|
if (nomeEmpty) {
|
||||||
txtNome.setBorder(new LineBorder(Color.red));
|
txtNome.setBorder(new LineBorder(Color.red));
|
||||||
}
|
}
|
||||||
@@ -294,11 +316,9 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
if (codiceFiscaleEmpty) {
|
if (codiceFiscaleEmpty) {
|
||||||
txtCodiceFiscale.setBorder(new LineBorder(Color.red));
|
txtCodiceFiscale.setBorder(new LineBorder(Color.red));
|
||||||
}
|
}
|
||||||
/*
|
if (dataDiNascitaEmpty) {
|
||||||
* if(dataDiNascitaEmpty){
|
txtDataDiNascita.setBorder(new LineBorder(Color.red));
|
||||||
* txtDataDiNascita.setBorder(new LineBorder(Color.red));
|
}
|
||||||
* }
|
|
||||||
*/
|
|
||||||
if (saldoInizialeEmpty) {
|
if (saldoInizialeEmpty) {
|
||||||
txtSaldoIniziale.setBorder(new LineBorder(Color.red));
|
txtSaldoIniziale.setBorder(new LineBorder(Color.red));
|
||||||
}
|
}
|
||||||
@@ -306,23 +326,33 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isCodiceFiscaleValid(codiceFiscale)) {
|
if (MyBank.isCodiceFiscaleValid(codiceFiscale)) {
|
||||||
JOptionPane.showMessageDialog(null, "Il codice fiscale non è valido.");
|
JOptionPane.showMessageDialog(null, "Il codice fiscale non è valido.");
|
||||||
txtCodiceFiscale.setBorder(new LineBorder(Color.red));
|
txtCodiceFiscale.setBorder(new LineBorder(Color.red));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// TODO: gestione data
|
|
||||||
// if(dataDiNascita.isEmpty()){
|
try {
|
||||||
// dataDiNascitaError = true;
|
dataDiNascita = MyBank.dataDiNascita(dataDiNascitaString);
|
||||||
// }
|
} catch (ParseException _) {
|
||||||
if (!isNumeroValid(saldoIniziale)) {
|
JOptionPane.showMessageDialog(null, "La data di nascita non è valida.");
|
||||||
|
txtDataDiNascita.setBorder(new LineBorder(Color.red));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
saldoIniziale = MyBank.valoreDouble(saldoInizialeString);
|
||||||
|
} catch (NumberFormatException _) {
|
||||||
JOptionPane.showMessageDialog(null, "Il saldo iniziale non è valido.");
|
JOptionPane.showMessageDialog(null, "Il saldo iniziale non è valido.");
|
||||||
txtSaldoIniziale.setBorder(new LineBorder(Color.red));
|
txtSaldoIniziale.setBorder(new LineBorder(Color.red));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
contoCorrente = new ContoCorrente(nome, cognome, codiceFiscale, Double.parseDouble(saldoIniziale));
|
this.contoCorrenteAperto = MyBank.aggiungiConto(nome, cognome, codiceFiscale, dataDiNascita, saldoIniziale);
|
||||||
|
txtNumeroContoCorrente.setText(Integer.toString(MyBank.getConti().getLast().getNumeroContoCorrente()));
|
||||||
|
|
||||||
|
lblNumeroContoCorrente.setVisible(true);
|
||||||
|
txtNumeroContoCorrente.setVisible(true);
|
||||||
btnVersamento.setVisible(true);
|
btnVersamento.setVisible(true);
|
||||||
btnPrelievo.setVisible(true);
|
btnPrelievo.setVisible(true);
|
||||||
btnListaMovimenti.setVisible(true);
|
btnListaMovimenti.setVisible(true);
|
||||||
@@ -336,29 +366,6 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
|
|
||||||
}// GEN-LAST:event_btnAprireContoCorrenteActionPerformed
|
}// GEN-LAST:event_btnAprireContoCorrenteActionPerformed
|
||||||
|
|
||||||
boolean isCodiceFiscaleValid(String codiceFiscale) {
|
|
||||||
Pattern pattern = Pattern.compile("[A-Z]{6}[ABCDEHLMPRST]{3}\\d{2}[A-Z]\\d{3}[A-Z]");
|
|
||||||
|
|
||||||
return !pattern.matcher(codiceFiscale).find();
|
|
||||||
}
|
|
||||||
|
|
||||||
boolean isNumeroValid(String numero) {
|
|
||||||
boolean isNumeroValid = true;
|
|
||||||
double valoreNumero;
|
|
||||||
|
|
||||||
try {
|
|
||||||
valoreNumero = Double.parseDouble(numero);
|
|
||||||
|
|
||||||
if (valoreNumero <= 0) {
|
|
||||||
isNumeroValid = false;
|
|
||||||
}
|
|
||||||
} catch (NumberFormatException _) {
|
|
||||||
isNumeroValid = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return isNumeroValid;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param args the command line arguments
|
* @param args the command line arguments
|
||||||
*/
|
*/
|
||||||
@@ -399,11 +406,13 @@ public class GUIMyBank extends javax.swing.JFrame {
|
|||||||
private javax.swing.JLabel lblCognome;
|
private javax.swing.JLabel lblCognome;
|
||||||
private javax.swing.JLabel lblDataDiNascita;
|
private javax.swing.JLabel lblDataDiNascita;
|
||||||
private javax.swing.JLabel lblNome;
|
private javax.swing.JLabel lblNome;
|
||||||
|
private javax.swing.JLabel lblNumeroContoCorrente;
|
||||||
private javax.swing.JLabel lblSaldoIniziale;
|
private javax.swing.JLabel lblSaldoIniziale;
|
||||||
private javax.swing.JTextField txtCodiceFiscale;
|
private javax.swing.JTextField txtCodiceFiscale;
|
||||||
private javax.swing.JTextField txtCognome;
|
private javax.swing.JTextField txtCognome;
|
||||||
private javax.swing.JTextField txtDataDiNascita;
|
private javax.swing.JTextField txtDataDiNascita;
|
||||||
private javax.swing.JTextField txtNome;
|
private javax.swing.JTextField txtNome;
|
||||||
|
private javax.swing.JTextField txtNumeroContoCorrente;
|
||||||
private javax.swing.JTextField txtSaldoIniziale;
|
private javax.swing.JTextField txtSaldoIniziale;
|
||||||
private javax.swing.JTextArea txtaListaMovimenti;
|
private javax.swing.JTextArea txtaListaMovimenti;
|
||||||
// End of variables declaration//GEN-END:variables
|
// End of variables declaration//GEN-END:variables
|
||||||
|
|||||||
@@ -36,10 +36,14 @@ public class MyBank {
|
|||||||
static final String ERRORE_GENERICO = "Errore: opzione non valida.";
|
static final String ERRORE_GENERICO = "Errore: opzione non valida.";
|
||||||
static final String ERRORE_CONTI_VUOTO = "Errore: è necessario aggiungere almeno un conto corrente prima di proseguire.";
|
static final String ERRORE_CONTI_VUOTO = "Errore: è necessario aggiungere almeno un conto corrente prima di proseguire.";
|
||||||
static final String PATH_CONTI = "./src/logic/conti/";
|
static final String PATH_CONTI = "./src/logic/conti/";
|
||||||
|
private static ArrayList<ContoCorrente> conti = importaConti();
|
||||||
|
|
||||||
|
public static ArrayList<ContoCorrente> getConti() {
|
||||||
|
return conti;
|
||||||
|
}
|
||||||
|
|
||||||
public static void main(String[] args) {
|
public static void main(String[] args) {
|
||||||
int scelta = -1;
|
int scelta = -1;
|
||||||
ArrayList<ContoCorrente> conti = importaConti();
|
|
||||||
|
|
||||||
do {
|
do {
|
||||||
System.out.println("Scegliere un'opzione:");
|
System.out.println("Scegliere un'opzione:");
|
||||||
@@ -58,7 +62,6 @@ public class MyBank {
|
|||||||
case 0:
|
case 0:
|
||||||
break;
|
break;
|
||||||
case 1:
|
case 1:
|
||||||
aggiungiConto(conti);
|
|
||||||
System.out.println("Numero conto: " + conti.getLast().getNumeroContoCorrente());
|
System.out.println("Numero conto: " + conti.getLast().getNumeroContoCorrente());
|
||||||
System.out.println("Conto corrente aggiunto con successo.");
|
System.out.println("Conto corrente aggiunto con successo.");
|
||||||
pausa();
|
pausa();
|
||||||
@@ -143,114 +146,56 @@ public class MyBank {
|
|||||||
return conti;
|
return conti;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void aggiungiConto(ArrayList<ContoCorrente> conti) {
|
public static ContoCorrente aggiungiConto(String nome, String cognome, String codiceFiscale, Date dataDiNascita,
|
||||||
String nome;
|
double saldoIniziale) {
|
||||||
String cognome;
|
|
||||||
String codiceFiscale;
|
|
||||||
Date dataDiNascita;
|
|
||||||
double saldoIniziale;
|
|
||||||
int numeroContoCorrente;
|
int numeroContoCorrente;
|
||||||
boolean error;
|
|
||||||
ContoCorrente contoCorrente;
|
ContoCorrente contoCorrente;
|
||||||
|
boolean exit = false;
|
||||||
|
int i = 0;
|
||||||
|
|
||||||
do {
|
numeroContoCorrente = Math.abs(codiceFiscale.hashCode());
|
||||||
error = false;
|
|
||||||
System.out.print("Inserire il proprio nome: ");
|
|
||||||
nome = sc.nextLine().trim();
|
|
||||||
|
|
||||||
System.out.print("Inserire il proprio cognome: ");
|
if (ContoCorrente.getNumeriContiCorrenti().contains(numeroContoCorrente)) {
|
||||||
cognome = sc.nextLine().trim();
|
for (; i < conti.size() && exit; i++) {
|
||||||
|
exit = conti.get(i).getNumeroContoCorrente() == numeroContoCorrente;
|
||||||
codiceFiscale = codiceFiscale();
|
|
||||||
|
|
||||||
dataDiNascita = dataDiNascita();
|
|
||||||
|
|
||||||
saldoIniziale = quantita("del saldo iniziale");
|
|
||||||
|
|
||||||
numeroContoCorrente = Math.abs(codiceFiscale.hashCode());
|
|
||||||
|
|
||||||
if (ContoCorrente.getNumeriContiCorrenti().contains(numeroContoCorrente)) {
|
|
||||||
System.out.println("Errore: esiste già un conto corrente per questo codice fiscale, riprovare.");
|
|
||||||
pausa();
|
|
||||||
error = true;
|
|
||||||
} else {
|
|
||||||
File percorsoConti = new File(PATH_CONTI);
|
|
||||||
if (!percorsoConti.exists()) {
|
|
||||||
percorsoConti.mkdir();
|
|
||||||
}
|
|
||||||
contoCorrente = new ContoCorrente(nome, cognome, codiceFiscale, dataDiNascita, saldoIniziale,
|
|
||||||
numeroContoCorrente);
|
|
||||||
conti.add(contoCorrente);
|
|
||||||
salvaContoCorrente(contoCorrente);
|
|
||||||
}
|
}
|
||||||
} while (error);
|
contoCorrente = conti.get(i);
|
||||||
|
} else {
|
||||||
|
File percorsoConti = new File(PATH_CONTI);
|
||||||
|
if (!percorsoConti.exists()) {
|
||||||
|
percorsoConti.mkdir();
|
||||||
|
}
|
||||||
|
contoCorrente = new ContoCorrente(nome, cognome, codiceFiscale, dataDiNascita, saldoIniziale,
|
||||||
|
numeroContoCorrente);
|
||||||
|
conti.add(contoCorrente);
|
||||||
|
salvaContoCorrente(contoCorrente);
|
||||||
|
}
|
||||||
|
|
||||||
|
return contoCorrente;
|
||||||
}
|
}
|
||||||
|
|
||||||
static String codiceFiscale() {
|
public static boolean isCodiceFiscaleValid(String codiceFiscale) {
|
||||||
String codiceFiscale;
|
|
||||||
boolean error;
|
|
||||||
Pattern pattern = Pattern.compile("[A-Z]{6}[ABCDEHLMPRST]{3}\\d{2}[A-Z]\\d{3}[A-Z]");
|
Pattern pattern = Pattern.compile("[A-Z]{6}[ABCDEHLMPRST]{3}\\d{2}[A-Z]\\d{3}[A-Z]");
|
||||||
Matcher matcher;
|
return pattern.matcher(codiceFiscale).find();
|
||||||
|
|
||||||
do {
|
|
||||||
error = false;
|
|
||||||
System.out.print("Inserire il proprio codice fiscale: ");
|
|
||||||
codiceFiscale = sc.nextLine().trim().toUpperCase();
|
|
||||||
matcher = pattern.matcher(codiceFiscale);
|
|
||||||
if (!matcher.find()) {
|
|
||||||
System.out.println(ERRORE_GENERICO);
|
|
||||||
pausa();
|
|
||||||
error = true;
|
|
||||||
}
|
|
||||||
} while (error);
|
|
||||||
return codiceFiscale;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static Date dataDiNascita() {
|
public static Date dataDiNascita(String dataDiNascita) throws ParseException {
|
||||||
Date dataDiNascita = null;
|
|
||||||
boolean error;
|
|
||||||
final String FORMATO_DATA = "dd/MM/yyyy";
|
final String FORMATO_DATA = "dd/MM/yyyy";
|
||||||
SimpleDateFormat sdf = new SimpleDateFormat(FORMATO_DATA);
|
SimpleDateFormat sdf = new SimpleDateFormat(FORMATO_DATA);
|
||||||
sdf.setLenient(false);
|
sdf.setLenient(false);
|
||||||
|
return sdf.parse(dataDiNascita);
|
||||||
do {
|
|
||||||
error = false;
|
|
||||||
System.out.print("Inserire la propria data di nascita nel formato " + FORMATO_DATA + ": ");
|
|
||||||
try {
|
|
||||||
dataDiNascita = sdf.parse(sc.nextLine());
|
|
||||||
} catch (ParseException _) {
|
|
||||||
System.out.println("Errore: la data inserita non è valida.");
|
|
||||||
pausa();
|
|
||||||
error = true;
|
|
||||||
}
|
|
||||||
} while (error);
|
|
||||||
return dataDiNascita;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static double quantita(String diCheCosa) {
|
public static double valoreDouble(String numeroDouble) throws NumberFormatException {
|
||||||
double quantita = 0;
|
double valoreDouble;
|
||||||
boolean error;
|
|
||||||
|
|
||||||
do {
|
valoreDouble = Double.parseDouble(numeroDouble);
|
||||||
error = false;
|
|
||||||
System.out.print("Inserire la quantità " + diCheCosa + ": ");
|
|
||||||
try {
|
|
||||||
quantita = sc.nextDouble();
|
|
||||||
sc.nextLine();
|
|
||||||
|
|
||||||
if (quantita <= 0) {
|
if (valoreDouble <= 0) {
|
||||||
System.out.println("Errore: la quantità non può essere minore o uguale a zero.");
|
throw new NumberFormatException();
|
||||||
pausa();
|
}
|
||||||
error = true;
|
|
||||||
}
|
|
||||||
} catch (InputMismatchException _) {
|
|
||||||
System.out.println(ERRORE_GENERICO);
|
|
||||||
pausa();
|
|
||||||
error = true;
|
|
||||||
}
|
|
||||||
} while (error);
|
|
||||||
|
|
||||||
return quantita;
|
return valoreDouble;
|
||||||
}
|
}
|
||||||
|
|
||||||
static void salvaContoCorrente(ContoCorrente conto) {
|
static void salvaContoCorrente(ContoCorrente conto) {
|
||||||
|
|||||||
Reference in New Issue
Block a user