diff --git a/src/Result.java b/src/Result.java index 7f7015d..d0c71db 100644 --- a/src/Result.java +++ b/src/Result.java @@ -3,7 +3,7 @@ public class Result { private Screen screen; private ScreenTemplates screenTemplates; - private String value = "Result"; + private String value = "result"; public Result(Screen screen, ScreenTemplates screenTemplates) { this.screen = screen; this.screenTemplates = screenTemplates; diff --git a/src/ScreenTemplates.java b/src/ScreenTemplates.java index 67d104f..184452a 100644 --- a/src/ScreenTemplates.java +++ b/src/ScreenTemplates.java @@ -180,7 +180,7 @@ temp_json23.put("height", 55); Map temp_json24 = new HashMap<>(); temp_json24.put("type", "textInput"); - temp_json24.put("text", "textInput"); + temp_json24.put("text", ""); temp_json24.put("visible", true); temp_json24.put("x", 370); temp_json24.put("y", 245); @@ -196,7 +196,7 @@ temp_json25.put("height", 20); Map temp_json26 = new HashMap<>(); temp_json26.put("type", "textInput"); - temp_json26.put("text", "textInput"); + temp_json26.put("text", ""); temp_json26.put("visible", true); temp_json26.put("x", 685); temp_json26.put("y", 245); @@ -212,7 +212,7 @@ temp_json27.put("height", 55); Map temp_json28 = new HashMap<>(); temp_json28.put("type", "textInput"); - temp_json28.put("text", "textInput"); + temp_json28.put("text", ""); temp_json28.put("visible", true); temp_json28.put("x", 55); temp_json28.put("y", 245); @@ -220,7 +220,7 @@ temp_json28.put("height", 65); Map temp_json29 = new HashMap<>(); temp_json29.put("type", "textInput"); - temp_json29.put("text", "textInput"); + temp_json29.put("text", ""); temp_json29.put("visible", true); temp_json29.put("x", 370); temp_json29.put("y", 380); @@ -228,7 +228,7 @@ temp_json29.put("height", 65); Map temp_json30 = new HashMap<>(); temp_json30.put("type", "textInput"); - temp_json30.put("text", "textInput"); + temp_json30.put("text", ""); temp_json30.put("visible", true); temp_json30.put("x", 685); temp_json30.put("y", 380); @@ -236,7 +236,7 @@ temp_json30.put("height", 65); Map temp_json31 = new HashMap<>(); temp_json31.put("type", "textInput"); - temp_json31.put("text", "textInput"); + temp_json31.put("text", ""); temp_json31.put("visible", true); temp_json31.put("x", 995); temp_json31.put("y", 245); @@ -244,7 +244,7 @@ temp_json31.put("height", 65); Map temp_json32 = new HashMap<>(); temp_json32.put("type", "textInput"); - temp_json32.put("text", "textInput"); + temp_json32.put("text", ""); temp_json32.put("visible", true); temp_json32.put("x", 55); temp_json32.put("y", 380); @@ -255,7 +255,7 @@ temp_json13.put("wcada3c4a537b4c7eae76954b6ed08ea8", temp_json15); temp_json13.put("we631b90a7c5749ed863429194cbc4187", temp_json16); temp_json13.put("we1c1c127a4d84410a65936d971bf99bd", temp_json17); - temp_json13.put("Result", temp_json18); + temp_json13.put("result", temp_json18); temp_json13.put("w2789e405544b4a32a669b65e6a6af685", temp_json21); temp_json13.put("w14fd3296e1064497a0c4ced93b47f21d", temp_json22); temp_json13.put("w725d1e48b8584a70bad1fbdc07ea8280", temp_json23); diff --git a/src/Widget.java b/src/Widget.java index fb65bad..fc33ee5 100644 --- a/src/Widget.java +++ b/src/Widget.java @@ -99,23 +99,23 @@ // public void updateFromWidget(String self, String scId, String wid, Map widget, String curScreen) { // this.value = widget; // } - public void updateDataFromState(String screenId, String widId, int state, String searchCriteriaScreen, String search1, String search2, String search3, String search5, String search6, String result, String address1_, String address2_, String businessdescription1_, String businessdescription2_, String companyoverview_, Map> businessCardManagement) { + public void updateDataFromState(String screenId, String widId, int state, String search1, String search2, String search3, String search5, String search6, String result, String address1_, String address2_, String businessdescription1_, String businessdescription2_, String companyoverview_, Map> businessCardManagement) { Map> temp_if0; if ((state==0)) { Map temp_json92 = new HashMap<>(); - temp_json92.put("address1", text); - temp_json92.put("address2", text); - temp_json92.put("businessDescription1", text); - temp_json92.put("businessDescription2", text); - temp_json92.put("companyOverview", text); + temp_json92.put("住所1", search5); + temp_json92.put("住所2", search6); + temp_json92.put("事業内容1", search1); + temp_json92.put("事業内容2", search2); + temp_json92.put("会社概要", search3); Map> temp_search0 = new HashMap<>(); for (String key: businessCardManagement.keySet()) { boolean isMatch = true; for (String qKey: temp_json92.keySet()) { Map value = businessCardManagement.get(key); for (String valKey: value.keySet()) { - if (valKey.equals(qKey)) { - if (value.get(valKey).equals(temp_json92.get(qKey))) { + if (temp_json92.get(qKey) != null && !temp_json92.get(qKey).equals("") && valKey.equals(qKey)) { + if (!value.get(valKey).equals(temp_json92.get(qKey))) { isMatch = false; } break; diff --git a/src/Widget1.java b/src/Widget1.java index e07e4ce..8704017 100644 --- a/src/Widget1.java +++ b/src/Widget1.java @@ -662,7 +662,6 @@ 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(); String search3 = this.search3.getValue(); @@ -674,8 +673,6 @@ String businessdescription1 = this.businessdescription1.getValue(); String businessdescription2 = this.businessdescription2.getValue(); String companyoverview = this.companyoverview.getValue(); - this.widget1 = screen.getWidgets().getWidget(searchCriteriaScreen); - String searchCriteriaScreen_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(search1); String search1_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(search2); @@ -686,8 +683,6 @@ String search5_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(search6); String search6_ = this.widget1.getText(); - this.widget1 = screen.getWidgets().getWidget(result); - String result_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(address1); String address1_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(address2); @@ -698,8 +693,10 @@ String businessdescription2_ = this.widget1.getText(); this.widget1 = screen.getWidgets().getWidget(companyoverview); String companyoverview_ = this.widget1.getText(); + this.widget1 = screen.getWidgets().getWidget(result); + String result_ = this.widget1.getText(); Map> businessCardManagement = this.businessCardManagement.getValue(); - this.widget1.updateDataFromState(curScreen, wid, this.state, searchCriteriaScreen_, search1_, search2_, search3_, search5_, search6_, result_, address1_, address2_, businessdescription1_, businessdescription2_, companyoverview_, businessCardManagement); + this.widget1.updateDataFromState(curScreen, result, this.state, search1_, search2_, search3_, search5_, search6_, result_, address1_, address2_, businessdescription1_, businessdescription2_, companyoverview_, businessCardManagement); } } public void setReferences(Screen screen, CurScreen curScreen, SwingPresenter presenter, BusinessCardManagement businessCardManagement, Company company, Representative representative, Position position, Establishment establishment, Address1 address1, Address2 address2, Businessdescription1 businessdescription1, Businessdescription2 businessdescription2, Companyoverview companyoverview, URL URL, ContactPerson1 contactPerson1, Position1 position1, Tel1 tel1, Email1 email1, ContactPerson2 contactPerson2, Position2 position2, Tel2 tel2, Email2 email2, ContactPerson3 contactPerson3, Position3 position3, Tel3 tel3, Email3 email3, ContactPerson4 contactPerson4, Position4 position4, Tel4 tel4, Email4 email4, SearchCriteriaScreen searchCriteriaScreen, Search1 search1, Search2 search2, Search3 search3, Search5 search5, Search6 search6, Result result, W2d109ad3739d4744a1874ac179fc38b9 w2d109ad3739d4744a1874ac179fc38b9, W4ca84254d30c423ab8e449171a5b5123 w4ca84254d30c423ab8e449171a5b5123) {