diff --git a/src/CurScreen.java b/src/CurScreen.java index a74bf37..e453db2 100644 --- a/src/CurScreen.java +++ b/src/CurScreen.java @@ -133,6 +133,17 @@ Map screenTemplate = screenTemplates.getScreenTemplate(this.value).getValue(); this.screen.updateFromCurScreen(this.value, screenTemplate); } + public void updateFromState11(String scId, String wid, int state) { + String temp_if14; + if ((state==0)) { + temp_if14 = "編集画面2"; + } else { + temp_if14 = this.value; + } + this.value = temp_if14; + Map screenTemplate = screenTemplates.getScreenTemplate(this.value).getValue(); + this.screen.updateFromCurScreen(this.value, screenTemplate); + } public void changeCurScreen(String nextScId) { this.value = nextScId; Map screenTemplate = screenTemplates.getScreenTemplate(this.value).getValue(); diff --git a/src/Widget1.java b/src/Widget1.java index 897cf52..61a7bfb 100644 --- a/src/Widget1.java +++ b/src/Widget1.java @@ -132,19 +132,27 @@ } public void updateStateFromState(String self, String self2, String wid, int state, String curScreen) { this.state = state; - if ((curScreen.equals("検索画面")&&wid.equals("w7de33900c55f4379983056aee325c057"))) { - this.curScreen.updateFromState10(curScreen, wid, this.state); - } - if ((curScreen.equals("編集画面2")&&wid.equals("w71f9e06eb3654cc2bb57ce3482579e11"))) { - this.curScreen.updateFromState9(curScreen, wid, this.state); - } - if ((curScreen.equals("検索画面")&&wid.equals("web3d4ea933244ee195c972cec50c9474"))) { + if ((curScreen.equals("企業一覧")&&wid.equals("w191cc519b2344758b8d9878328b41cd9"))) { // 「検索」ボタン + this.curScreen.updateFromState3(curScreen, wid, this.state); + } + if ((curScreen.equals("企業一覧")&&wid.equals("w0498c4eb3524489494c288e2fc7a3211"))) { // 「登録」ボタン + this.curScreen.updateFromState2(curScreen, wid, this.state); + } + if ((curScreen.equals("企業一覧")&&wid.equals("wa6aa4bcbb7a64e9eaf75758eae59310a"))) { // 「編集」ボタン + this.curScreen.updateFromState11(curScreen, wid, this.state); + } + if ((curScreen.equals("企業一覧")&&wid.equals("wa1b27f08c9fd4c08b7dda38625c04f3b"))) { // 「削除」ボタン + } + if ((curScreen.equals("検索画面")&&wid.equals("w7de33900c55f4379983056aee325c057"))) { // 「検索項目の入力」ボタン + this.curScreen.updateFromState10(curScreen, wid, this.state); + } + if ((curScreen.equals("検索画面")&&wid.equals("web3d4ea933244ee195c972cec50c9474"))) { // 「一覧へ戻る」ボタン this.curScreen.updateFromState8(curScreen, wid, this.state); } - if ((curScreen.equals("検索画面結果")&&wid.equals("w0becbeb6b2d54c03a69d63e3facd2eaa"))) { - this.curScreen.updateFromState7(curScreen, wid, this.state); - } - if ((curScreen.equals("編集画面2")&&wid.equals("w11dd0f050a5044d384b10351b83ad390"))) { + if ((curScreen.equals("編集画面2")&&wid.equals("w71f9e06eb3654cc2bb57ce3482579e11"))) { // 「一覧へ戻る」ボタン + this.curScreen.updateFromState9(curScreen, wid, this.state); + } + if ((curScreen.equals("編集画面2")&&wid.equals("w11dd0f050a5044d384b10351b83ad390"))) { // 「編集」ボタン String company = this.company.getValue(); String representative = this.representative.getValue(); String position = this.position.getValue(); @@ -191,41 +199,57 @@ String companydetail_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(URL); String URL_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson1); - String contactPerson1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position1); - String position1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel1); - String tel1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email1); - String email1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson2); - String contactPerson2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position2); - String position2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel2); - String tel2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email2); - String email2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson3); - String contactPerson3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position3); - String position3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel3); - String tel3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email3); - String email3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson4); - String contactPerson4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position4); - String position4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel4); - String tel4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email4); - String email4_ = this.widget1.getText(); + String contactPerson1_ = ""; + String position1_ = ""; + String tel1_ = ""; + String email1_ = ""; + String contactPerson2_ = ""; + String position2_ = ""; + String tel2_ = ""; + String email2_ = ""; + String contactPerson3_ = ""; + String position3_ = ""; + String tel3_ = ""; + String email3_ = ""; + String contactPerson4_ = ""; + String position4_ = ""; + String tel4_ = ""; + String email4_ = ""; +// this.widget1 = screen.getWidgets().getWidget(contactPerson1); +// String contactPerson1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position1); +// String position1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel1); +// String tel1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email1); +// String email1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson2); +// String contactPerson2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position2); +// String position2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel2); +// String tel2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email2); +// String email2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson3); +// String contactPerson3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position3); +// String position3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel3); +// String tel3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email3); +// String email3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson4); +// String contactPerson4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position4); +// String position4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel4); +// String tel4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email4); +// String email4_ = this.widget1.getText(); this.businessCardManagement.updateFromState3(curScreen, wid, this.state, company_, representative_, position_, establish_, address1_, address2_, business1_, business2_, companydetail_, URL_, contactPerson1_, position1_, tel1_, email1_, contactPerson2_, position2_, tel2_, email2_, contactPerson3_, position3_, tel3_, email3_, contactPerson4_, position4_, tel4_, email4_); } - if ((curScreen.equals("編集画面2")&&wid.equals("w11dd0f050a5044d384b10351b83ad390"))) { + if ((curScreen.equals("編集画面2")&&wid.equals("w11dd0f050a5044d384b10351b83ad390"))) { // 「編集」ボタン String company = this.company.getValue(); String representative = this.representative.getValue(); String position = this.position.getValue(); @@ -261,19 +285,10 @@ Map> businessCardManagement = this.businessCardManagement.getValue(); this.curScreen.updateFromState5(curScreen, wid, this.state, company_, representative_, position_, establish_, address1_, address2_, business1_, business2_, companydetail_, URL_, businessCardManagement); } - if ((curScreen.equals("検索項目画面")&&wid.equals("w614b5ee1e161473d8f859fbfb5c8074e"))) { - this.curScreen.updateFromState4(curScreen, wid, this.state); - } - if ((curScreen.equals("企業一覧")&&wid.equals("w191cc519b2344758b8d9878328b41cd9"))) { - this.curScreen.updateFromState3(curScreen, wid, this.state); - } - if ((curScreen.equals("企業一覧")&&wid.equals("w0498c4eb3524489494c288e2fc7a3211"))) { - this.curScreen.updateFromState2(curScreen, wid, this.state); - } - if ((curScreen.equals("登録画面1")&&wid.equals("wf10ab1752fe44c4d97ffb2ca2afdeba0"))) { + if ((curScreen.equals("登録画面1")&&wid.equals("wf10ab1752fe44c4d97ffb2ca2afdeba0"))) { // 「一覧へ戻る」ボタン this.curScreen.updateFromState(curScreen, wid, this.state); } - if ((curScreen.equals("登録画面1")&&wid.equals("wf10ab1752fe44c4d97ffb2ca2afdeba0"))) { + if ((curScreen.equals("登録画面1")&&wid.equals("wf10ab1752fe44c4d97ffb2ca2afdeba0"))) { // 「一覧へ戻る」ボタン String company = this.company.getValue(); String representative = this.representative.getValue(); String position = this.position.getValue(); @@ -320,41 +335,57 @@ String companyoverview_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(URL); String URL_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson1); - String contactPerson1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position1); - String position1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel1); - String tel1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email1); - String email1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson2); - String contactPerson2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position2); - String position2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel2); - String tel2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email2); - String email2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson3); - String contactPerson3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position3); - String position3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel3); - String tel3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email3); - String email3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson4); - String contactPerson4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position4); - String position4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel4); - String tel4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email4); - String email4_ = this.widget1.getText(); + String contactPerson1_ = ""; + String position1_ = ""; + String tel1_ = ""; + String email1_ = ""; + String contactPerson2_ = ""; + String position2_ = ""; + String tel2_ = ""; + String email2_ = ""; + String contactPerson3_ = ""; + String position3_ = ""; + String tel3_ = ""; + String email3_ = ""; + String contactPerson4_ = ""; + String position4_ = ""; + String tel4_ = ""; + String email4_ = ""; +// this.widget1 = screen.getWidgets().getWidget(contactPerson1); +// String contactPerson1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position1); +// String position1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel1); +// String tel1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email1); +// String email1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson2); +// String contactPerson2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position2); +// String position2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel2); +// String tel2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email2); +// String email2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson3); +// String contactPerson3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position3); +// String position3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel3); +// String tel3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email3); +// String email3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson4); +// String contactPerson4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position4); +// String position4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel4); +// String tel4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email4); +// String email4_ = this.widget1.getText(); this.businessCardManagement.updateFromState(curScreen, wid, this.state, company_, representative_, position_, establishment_, address1_, address2_, businessdescription1_, businessdescription2_, companyoverview_, URL_, contactPerson1_, position1_, tel1_, email1_, contactPerson2_, position2_, tel2_, email2_, contactPerson3_, position3_, tel3_, email3_, contactPerson4_, position4_, tel4_, email4_); } - if ((curScreen.equals("登録画面1")&&wid.equals("w7c6cfb14ed4f410aa33a440e6ab2e4bf"))) { + if ((curScreen.equals("登録画面1")&&wid.equals("w7c6cfb14ed4f410aa33a440e6ab2e4bf"))) { // 「登録」ボタン String company = this.company.getValue(); String representative = this.representative.getValue(); String position = this.position.getValue(); @@ -402,40 +433,56 @@ this.widget1 = screen.getWidgets().getWidget(URL); String URL_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(contactPerson1); - String contactPerson1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position1); - String position1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel1); - String tel1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email1); - String email1_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson2); - String contactPerson2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position2); - String position2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel2); - String tel2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email2); - String email2_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson3); - String contactPerson3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position3); - String position3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel3); - String tel3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email3); - String email3_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(contactPerson4); - String contactPerson4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(position4); - String position4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(tel4); - String tel4_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(email4); - String email4_ = this.widget1.getText(); + String contactPerson1_ = ""; + String position1_ = ""; + String tel1_ = ""; + String email1_ = ""; + String contactPerson2_ = ""; + String position2_ = ""; + String tel2_ = ""; + String email2_ = ""; + String contactPerson3_ = ""; + String position3_ = ""; + String tel3_ = ""; + String email3_ = ""; + String contactPerson4_ = ""; + String position4_ = ""; + String tel4_ = ""; + String email4_ = ""; +// String contactPerson1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position1); +// String position1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel1); +// String tel1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email1); +// String email1_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson2); +// String contactPerson2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position2); +// String position2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel2); +// String tel2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email2); +// String email2_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson3); +// String contactPerson3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position3); +// String position3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel3); +// String tel3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email3); +// String email3_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(contactPerson4); +// String contactPerson4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(position4); +// String position4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(tel4); +// String tel4_ = this.widget1.getText(); +// this.widget1 = screen.getWidgets().getWidget(email4); +// String email4_ = this.widget1.getText(); this.businessCardManagement.updateFromState2(curScreen, wid, this.state, company_, representative_, position_, establishment_, address1_, address2_, businessdescription1_, businessdescription2_, companyoverview_, URL_, contactPerson1_, position1_, tel1_, email1_, contactPerson2_, position2_, tel2_, email2_, contactPerson3_, position3_, tel3_, email3_, contactPerson4_, position4_, tel4_, email4_); } - if ((curScreen.equals("登録画面1")&&wid.equals("w7c6cfb14ed4f410aa33a440e6ab2e4bf"))) { + if ((curScreen.equals("登録画面1")&&wid.equals("w7c6cfb14ed4f410aa33a440e6ab2e4bf"))) { // 「登録」ボタン String company = this.company.getValue(); String representative = this.representative.getValue(); String position = this.position.getValue(); @@ -469,7 +516,13 @@ Map> businessCardManagement = this.businessCardManagement.getValue(); this.curScreen.updateFromState6(curScreen, wid, this.state, company_, representative_, position_, establishment_, address1_, address2_, businessdescription1_, businessdescription2_, companyoverview_, URL_, businessCardManagement); } - if ((curScreen.equals("検索項目画面")&&wid.equals("w725d1e48b8584a70bad1fbdc07ea8280"))) { + if ((curScreen.equals("検索項目画面")&&wid.equals("w614b5ee1e161473d8f859fbfb5c8074e"))) { // 「一覧へ戻る」ボタン + this.curScreen.updateFromState4(curScreen, wid, this.state); + } + if ((curScreen.equals("検索画面結果")&&wid.equals("w0becbeb6b2d54c03a69d63e3facd2eaa"))) { // 「一覧へ戻る」ボタン + this.curScreen.updateFromState7(curScreen, wid, this.state); + } + if ((curScreen.equals("検索項目画面")&&wid.equals("w725d1e48b8584a70bad1fbdc07ea8280"))) { // 「検索」ボタン String searchCriteriaScreen = this.searchCriteriaScreen.getValue(); String search1 = this.search1.getValue(); String search2 = this.search2.getValue();