address-client 3.2.117-fugou → 3.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (154) hide show
  1. package/.serena/project.yml +84 -0
  2. package/build/dev-server.js +32 -28
  3. package/build/webpack.base.conf.js +1 -0
  4. package/package.json +1 -1
  5. package/src/address.js +6 -6
  6. package/src/components/AddAreaMsg.vue +39 -147
  7. package/src/components/AddCommunityManageMsg.vue +22 -105
  8. package/src/components/AddStreetManageMsg.vue +6 -30
  9. package/src/components/AddStreetOrPcd.vue +13 -44
  10. package/src/components/AddressAddAddress.vue +14 -14
  11. package/src/components/AddressFiles.vue +1 -1
  12. package/src/components/AddressList.vue +24 -80
  13. package/src/components/AddressTree.vue +5 -5
  14. package/src/components/AreaFiles.vue +1 -1
  15. package/src/components/AreaList.vue +12 -63
  16. package/src/components/AreaManage.vue +0 -4
  17. package/src/components/AreaTree.vue +5 -5
  18. package/src/components/Basch.vue +1 -1
  19. package/src/components/BatchOrders.vue +6 -6
  20. package/src/components/BuildingList.vue +2 -2
  21. package/src/components/CityList.vue +4 -9
  22. package/src/components/CommunityAreaList.vue +1 -1
  23. package/src/components/CommunityManage.vue +1 -1
  24. package/src/components/CommunityManageList.vue +25 -33
  25. package/src/components/NewAddressInfo.vue +4 -3
  26. package/src/components/StreetList.vue +9 -14
  27. package/src/components/StreetManageList.vue +5 -10
  28. package/src/components/UserAddress.vue +80 -299
  29. package/src/components/UserAddressChange.vue +1 -1
  30. package/src/components/selectAddress/BatchList.vue +8 -10
  31. package/src/filiale/WEINAN/AddAreaMsg.vue +707 -0
  32. package/src/filiale/WEINAN/AddressList.vue +538 -0
  33. package/src/filiale/WEINAN/AddressManage.vue +122 -0
  34. package/src/filiale/WEINAN/AreaList.vue +416 -0
  35. package/src/filiale/WEINAN/AreaManage.vue +109 -0
  36. package/src/filiale/WEINAN/AreaUserList.vue +210 -0
  37. package/src/filiale/WEINAN/UserAddress.vue +730 -0
  38. package/src/filiale/WEINAN/sale.js +18 -0
  39. package/src/filiale/chengtou/UserAddress.vue +827 -0
  40. package/src/filiale/chengtou/sale.js +7 -0
  41. package/src/filiale/dongguan/AddStreetOrPcd.vue +385 -0
  42. package/src/filiale/dongguan/sale.js +7 -0
  43. package/src/filiale/gaomi/AddressList.vue +424 -0
  44. package/src/filiale/gaomi/UserAddress.vue +779 -0
  45. package/src/filiale/gaomi/sale.js +14 -0
  46. package/src/filiale/gongyi/AddAreaMsg.vue +617 -0
  47. package/src/filiale/gongyi/AreaManage.vue +100 -0
  48. package/src/filiale/gongyi/UserAddress.vue +698 -0
  49. package/src/filiale/gongyi/sale.js +14 -0
  50. package/src/filiale/haile/AddressList.vue +565 -0
  51. package/src/filiale/haile/sale.js +8 -0
  52. package/src/filiale/jingwei/UserAddress.vue +711 -0
  53. package/src/filiale/jingwei/sale.js +12 -0
  54. package/src/filiale/macheng/AddAreaMsg.vue +601 -0
  55. package/src/filiale/macheng/AddStreetOrPcd.vue +214 -0
  56. package/src/filiale/macheng/AddressList.vue +563 -0
  57. package/src/filiale/macheng/AreaList.vue +313 -0
  58. package/src/filiale/macheng/CityManage.vue +76 -0
  59. package/src/filiale/macheng/StreetList.vue +181 -0
  60. package/src/filiale/macheng/UserAddress.vue +690 -0
  61. package/src/filiale/macheng/sale.js +17 -0
  62. package/src/filiale/meihekou/UserAddress.vue +827 -0
  63. package/src/filiale/meihekou/sale.js +8 -0
  64. package/src/filiale/qianneng/AddAreaMsg.vue +690 -0
  65. package/src/filiale/qianneng/AddStreetOrPcd.vue +297 -0
  66. package/src/filiale/qianneng/AddressList.vue +588 -0
  67. package/src/filiale/qianneng/AreaList.vue +412 -0
  68. package/src/filiale/qianneng/CityManage.vue +81 -0
  69. package/src/filiale/qianneng/UserAddress.vue +1026 -0
  70. package/src/filiale/qianneng/sale.js +20 -0
  71. package/src/filiale/qinhua/AddAreaMsg.vue +682 -0
  72. package/src/filiale/qinhua/AddressList.vue +577 -0
  73. package/src/filiale/qinhua/AddressManage.vue +117 -0
  74. package/src/filiale/qinhua/AreaList.vue +406 -0
  75. package/src/filiale/qinhua/AreaManage.vue +100 -0
  76. package/src/filiale/qinhua/CityManage.vue +76 -0
  77. package/src/filiale/qinhua/StreetList.vue +236 -0
  78. package/src/filiale/qinhua/UserAddress.vue +827 -0
  79. package/src/filiale/qinhua/sale.js +20 -0
  80. package/src/filiale/rizhao/UserAddress.vue +826 -0
  81. package/src/filiale/rizhao/sale.js +8 -0
  82. package/src/filiale/rongcheng/AddressList.vue +364 -0
  83. package/src/filiale/rongcheng/UserAddress.vue +746 -0
  84. package/src/filiale/rongcheng/sale.js +11 -0
  85. package/src/filiale/shanggao/AddAreaMsg.vue +691 -0
  86. package/src/filiale/shanggao/AddStreetOrPcd.vue +281 -0
  87. package/src/filiale/shanggao/AddressList.vue +563 -0
  88. package/src/filiale/shanggao/AreaList.vue +417 -0
  89. package/src/filiale/shanggao/BuildingList.vue +129 -0
  90. package/src/filiale/shanggao/StreetList.vue +235 -0
  91. package/src/filiale/shanggao/UserAddress.vue +868 -0
  92. package/src/filiale/shanggao/sale.js +16 -0
  93. package/src/filiale/shanxian/AddAreaMsg.vue +705 -0
  94. package/src/filiale/shanxian/AddressList.vue +608 -0
  95. package/src/filiale/shanxian/AreaList.vue +439 -0
  96. package/src/filiale/shanxian/AreaManage.vue +107 -0
  97. package/src/filiale/shanxian/UserAddress.vue +833 -0
  98. package/src/filiale/shanxian/sale.js +15 -0
  99. package/src/filiale/shaoguan/AddAreaMsg.vue +595 -0
  100. package/src/filiale/shaoguan/UserAddress.vue +709 -0
  101. package/src/filiale/shaoguan/sale.js +11 -0
  102. package/src/filiale/tongchuan/AddAreaMsg.vue +601 -0
  103. package/src/filiale/tongchuan/AddStreetOrPcd.vue +302 -0
  104. package/src/filiale/tongchuan/AddressList.vue +380 -0
  105. package/src/filiale/tongchuan/AreaList.vue +310 -0
  106. package/src/filiale/tongchuan/AreaManage.vue +100 -0
  107. package/src/filiale/tongchuan/CityList.vue +128 -0
  108. package/src/filiale/tongchuan/StreetList.vue +210 -0
  109. package/src/filiale/tongchuan/UserAddress.vue +755 -0
  110. package/src/filiale/tongchuan/sale.js +19 -0
  111. package/src/filiale/wuhai/UserAddress.vue +742 -0
  112. package/src/filiale/wuhai/sale.js +12 -0
  113. package/src/filiale/xinkang/AddAreaMsg.vue +702 -0
  114. package/src/filiale/xinkang/AreaList.vue +408 -0
  115. package/src/filiale/xinkang/sale.js +9 -0
  116. package/src/filiale/yangchun/AddAreaMsg.vue +695 -0
  117. package/src/filiale/yangchun/sale.js +7 -0
  118. package/src/filiale/zhongsheng/AddressList.vue +621 -0
  119. package/src/filiale/zhongsheng/AreaList.vue +481 -0
  120. package/src/filiale/zhongsheng/sale.js +12 -0
  121. package/src/filiale/zhongyi/AddAreaMsg.vue +696 -0
  122. package/src/filiale/zhongyi/sale.js +12 -0
  123. package/src/filiale/zhoukou/AddAreaMsg.vue +632 -0
  124. package/src/filiale/zhoukou/AddressList.vue +392 -0
  125. package/src/filiale/zhoukou/AddressManage.vue +115 -0
  126. package/src/filiale/zhoukou/AreaList.vue +314 -0
  127. package/src/filiale/zhoukou/AreaManage.vue +100 -0
  128. package/src/filiale/zhoukou/UserAddress.vue +856 -0
  129. package/src/filiale/zhoukou/sale.js +23 -0
  130. package/src/main.js +1 -2
  131. package/src/util/AddressSafeApi.js +268 -0
  132. package/.gradle/3.5.1/file-changes/last-build.bin +0 -0
  133. package/.gradle/3.5.1/taskHistory/taskHistory.lock +0 -0
  134. package/.gradle/8.5/checksums/checksums.lock +0 -0
  135. package/.gradle/8.5/dependencies-accessors/dependencies-accessors.lock +0 -0
  136. package/.gradle/8.5/dependencies-accessors/gc.properties +0 -0
  137. package/.gradle/8.5/executionHistory/executionHistory.bin +0 -0
  138. package/.gradle/8.5/executionHistory/executionHistory.lock +0 -0
  139. package/.gradle/8.5/fileChanges/last-build.bin +0 -0
  140. package/.gradle/8.5/fileHashes/fileHashes.bin +0 -0
  141. package/.gradle/8.5/fileHashes/fileHashes.lock +0 -0
  142. package/.gradle/8.5/gc.properties +0 -0
  143. package/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  144. package/.gradle/buildOutputCleanup/cache.properties +0 -2
  145. package/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
  146. package/.gradle/file-system.probe +0 -0
  147. package/.gradle/vcs-1/gc.properties +0 -0
  148. package/build.gradle +0 -14
  149. package/gradle/wrapper/gradle-wrapper.jar +0 -0
  150. package/gradle/wrapper/gradle-wrapper.properties +0 -7
  151. package/gradlew +0 -249
  152. package/gradlew.bat +0 -92
  153. package/publish.bat +0 -7
  154. package/release.bat +0 -5
@@ -0,0 +1,84 @@
1
+ # list of languages for which language servers are started; choose from:
2
+ # al bash clojure cpp csharp csharp_omnisharp
3
+ # dart elixir elm erlang fortran go
4
+ # haskell java julia kotlin lua markdown
5
+ # nix perl php python python_jedi r
6
+ # rego ruby ruby_solargraph rust scala swift
7
+ # terraform typescript typescript_vts yaml zig
8
+ # Note:
9
+ # - For C, use cpp
10
+ # - For JavaScript, use typescript
11
+ # Special requirements:
12
+ # - csharp: Requires the presence of a .sln file in the project folder.
13
+ # When using multiple languages, the first language server that supports a given file will be used for that file.
14
+ # The first language is the default language and the respective language server will be used as a fallback.
15
+ # Note that when using the JetBrains backend, language servers are not used and this list is correspondingly ignored.
16
+ languages:
17
+ - vue
18
+
19
+ # the encoding used by text files in the project
20
+ # For a list of possible encodings, see https://docs.python.org/3.11/library/codecs.html#standard-encodings
21
+ encoding: "utf-8"
22
+
23
+ # whether to use the project's gitignore file to ignore files
24
+ # Added on 2025-04-07
25
+ ignore_all_files_in_gitignore: true
26
+
27
+ # list of additional paths to ignore
28
+ # same syntax as gitignore, so you can use * and **
29
+ # Was previously called `ignored_dirs`, please update your config if you are using that.
30
+ # Added (renamed) on 2025-04-07
31
+ ignored_paths: []
32
+
33
+ # whether the project is in read-only mode
34
+ # If set to true, all editing tools will be disabled and attempts to use them will result in an error
35
+ # Added on 2025-04-18
36
+ read_only: false
37
+
38
+ # list of tool names to exclude. We recommend not excluding any tools, see the readme for more details.
39
+ # Below is the complete list of tools for convenience.
40
+ # To make sure you have the latest list of tools, and to view their descriptions,
41
+ # execute `uv run scripts/print_tool_overview.py`.
42
+ #
43
+ # * `activate_project`: Activates a project by name.
44
+ # * `check_onboarding_performed`: Checks whether project onboarding was already performed.
45
+ # * `create_text_file`: Creates/overwrites a file in the project directory.
46
+ # * `delete_lines`: Deletes a range of lines within a file.
47
+ # * `delete_memory`: Deletes a memory from Serena's project-specific memory store.
48
+ # * `execute_shell_command`: Executes a shell command.
49
+ # * `find_referencing_code_snippets`: Finds code snippets in which the symbol at the given location is referenced.
50
+ # * `find_referencing_symbols`: Finds symbols that reference the symbol at the given location (optionally filtered by type).
51
+ # * `find_symbol`: Performs a global (or local) search for symbols with/containing a given name/substring (optionally filtered by type).
52
+ # * `get_current_config`: Prints the current configuration of the agent, including the active and available projects, tools, contexts, and modes.
53
+ # * `get_symbols_overview`: Gets an overview of the top-level symbols defined in a given file.
54
+ # * `initial_instructions`: Gets the initial instructions for the current project.
55
+ # Should only be used in settings where the system prompt cannot be set,
56
+ # e.g. in clients you have no control over, like Claude Desktop.
57
+ # * `insert_after_symbol`: Inserts content after the end of the definition of a given symbol.
58
+ # * `insert_at_line`: Inserts content at a given line in a file.
59
+ # * `insert_before_symbol`: Inserts content before the beginning of the definition of a given symbol.
60
+ # * `list_dir`: Lists files and directories in the given directory (optionally with recursion).
61
+ # * `list_memories`: Lists memories in Serena's project-specific memory store.
62
+ # * `onboarding`: Performs onboarding (identifying the project structure and essential tasks, e.g. for testing or building).
63
+ # * `prepare_for_new_conversation`: Provides instructions for preparing for a new conversation (in order to continue with the necessary context).
64
+ # * `read_file`: Reads a file within the project directory.
65
+ # * `read_memory`: Reads the memory with the given name from Serena's project-specific memory store.
66
+ # * `remove_project`: Removes a project from the Serena configuration.
67
+ # * `replace_lines`: Replaces a range of lines within a file with new content.
68
+ # * `replace_symbol_body`: Replaces the full definition of a symbol.
69
+ # * `restart_language_server`: Restarts the language server, may be necessary when edits not through Serena happen.
70
+ # * `search_for_pattern`: Performs a search for a pattern in the project.
71
+ # * `summarize_changes`: Provides instructions for summarizing the changes made to the codebase.
72
+ # * `switch_modes`: Activates modes by providing a list of their names
73
+ # * `think_about_collected_information`: Thinking tool for pondering the completeness of collected information.
74
+ # * `think_about_task_adherence`: Thinking tool for determining whether the agent is still on track with the current task.
75
+ # * `think_about_whether_you_are_done`: Thinking tool for determining whether the task is truly completed.
76
+ # * `write_memory`: Writes a named memory (for future reference) to Serena's project-specific memory store.
77
+ excluded_tools: []
78
+
79
+ # initial prompt for the project. It will always be given to the LLM upon activating the project
80
+ # (contrary to the memories, which are loaded on demand).
81
+ initial_prompt: ""
82
+
83
+ project_name: "AddressClient-v3"
84
+ included_optional_tools: []
@@ -6,43 +6,47 @@ var httpProxy = require('http-proxy')
6
6
 
7
7
  var app = express()
8
8
  var compiler = webpack(config)
9
- var proxy = httpProxy.createProxyServer()
10
9
 
11
10
  // Define HTTP proxies to your custom API backend
12
11
  // https://github.com/chimurai/http-proxy-middleware
13
- var str = 'http://localhost:8080/', str2= 'http://192.168.50.4:8400/#'
14
- var str3= 'http://192.168.50.4:8400/'
12
+ var str = 'http://192.168.50.67:31567/'
13
+ var str3 = 'http://192.168.50.67:31567/'
15
14
  var proxyTable = {
15
+ '/api': {
16
+ target: str3,
17
+ },
18
+ '/rs/logic/address_': {
19
+ target: 'http://127.0.0.1:9014'
20
+ },
21
+ '/rs/sql/address_': {
22
+ target: 'http://127.0.0.1:9014'
23
+ },
16
24
  '/rs/entity': {
17
25
  target: str
18
26
  // secure:true,
19
27
  // changeOrigin:true
20
28
  // target: 'http://127.0.0.1:8080'
21
29
  },
22
- '/api/af-revenue': {
23
- pathRewrite: {'/api/af-revenue': '/'},
24
- target: 'http://127.0.0.1:9026'
25
- },
26
- '/webapps':{
30
+ '/webapps': {
27
31
  target: str3,
28
- secure:true,
29
- changeOrigin:true
32
+ secure: true,
33
+ changeOrigin: true
30
34
  // target: 'http://127.0.0.1:8080'
31
35
  },
32
36
  '/rs/logic/getLogin': {
33
37
  target: str3,
34
- secure:true,
35
- changeOrigin:true
38
+ secure: true,
39
+ changeOrigin: true
36
40
  },
37
41
  '/rs/logic/getInitData': {
38
42
  target: str3,
39
- secure:true,
40
- changeOrigin:true,
43
+ secure: true,
44
+ changeOrigin: true
41
45
  },
42
46
  '/rs/logic/getSaleInitData': {
43
47
  target: str3,
44
- secure:true,
45
- changeOrigin:true
48
+ secure: true,
49
+ changeOrigin: true
46
50
  },
47
51
  // '/rs/logic':{
48
52
  // target: str3,
@@ -52,29 +56,29 @@ var proxyTable = {
52
56
  // },
53
57
  '/rs/vue': {
54
58
  target: str3,
55
- secure:true,
56
- changeOrigin:true
59
+ secure: true,
60
+ changeOrigin: true
57
61
  },
58
62
  '/rs/user': {
59
63
  target: str3,
60
- secure:true,
61
- changeOrigin:true
64
+ secure: true,
65
+ changeOrigin: true
62
66
  },
63
67
  '/rs/db': {
64
68
  target: str3,
65
- secure:true,
66
- changeOrigin:true
69
+ secure: true,
70
+ changeOrigin: true
67
71
  },
68
72
  '/rs/search': {
69
73
  target: str3,
70
- secure:true,
71
- changeOrigin:true
74
+ secure: true,
75
+ changeOrigin: true
72
76
  // target: 'http://127.0.0.1:8080'
73
77
  },
74
78
  '/rs/data': {
75
79
  target: str3,
76
- secure:true,
77
- changeOrigin:true
80
+ secure: true,
81
+ changeOrigin: true
78
82
  },
79
83
  '/rs/sql': {
80
84
  target: str
@@ -91,8 +95,8 @@ var proxyTable = {
91
95
  '/rs': {
92
96
  // target: 'http://192.168.50.199:8300'
93
97
  target: str3,
94
- secure:true,
95
- changeOrigin:true
98
+ secure: true,
99
+ changeOrigin: true
96
100
  }
97
101
  }
98
102
 
@@ -41,6 +41,7 @@ module.exports = {
41
41
  `${projectRoot}\\node_modules\\system-clients\\src`,
42
42
  `${projectRoot}\\node_modules\\ldap-clients\\src`,
43
43
  `${projectRoot}\\node_modules\\sale-client\\src`,
44
+ `${projectRoot}\\node_modules\\@afwenming123\\vue-plugin-hiprint`,
44
45
  ]
45
46
  },
46
47
  {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "address-client",
3
- "version": "3.2.117-fugou",
3
+ "version": "3.3.1",
4
4
  "description": "地址管理前台组件",
5
5
  "author": "wanbochao",
6
6
  "license": "ISC",
package/src/address.js CHANGED
@@ -65,10 +65,10 @@ export default function (filiale) {
65
65
  Vue.component('community-area-list', (resolve) => { require(['./components/CommunityAreaList'], resolve) })
66
66
 
67
67
  // 分公司特殊页面注册替换
68
- // if (filiale) {
69
- // let filialeComp = require(`./filiale/${filiale}/sale`).specialComp
70
- // for (let key in filialeComp) {
71
- // Vue.component(key, filialeComp[key])
72
- // }
73
- // }
68
+ if (filiale) {
69
+ let filialeComp = require(`./filiale/${filiale}/sale`).specialComp
70
+ for (let key in filialeComp) {
71
+ Vue.component(key, filialeComp[key])
72
+ }
73
+ }
74
74
  }
@@ -27,7 +27,7 @@
27
27
 
28
28
  <div class="col-sm-6 form-group"
29
29
  :class="[$v.f_pcd_id.required ? 'has-error' : 'has-success']">
30
- <label class="font_normal_body">县</label>
30
+ <label class="font_normal_body">省&ensp;市&ensp;区</label>
31
31
  <input type="text" class="input_search" class="input_search" style="width:60%" v-show="false" v-model="areamodel.f_pcd_id"
32
32
  v-validate:f_pcd_id='{required: true }'>
33
33
  <v-select
@@ -38,7 +38,7 @@
38
38
  </div>
39
39
  <div class="col-sm-6 form-group"
40
40
  :class="[$v.f_street_id.required ? 'has-error' : 'has-success']">
41
- <label class="font_normal_body">市区/乡镇</label>
41
+ <label class="font_normal_body">街道/乡镇</label>
42
42
  <input type="text" style="width:60%" class="input_search" v-show="false" v-model="areamodel.f_street_id"
43
43
  v-validate:f_street_id='{required: true }'>
44
44
  <v-select
@@ -47,15 +47,13 @@
47
47
  close-on-select search="true" @change="streetChange">
48
48
  </v-select>
49
49
  </div>
50
- <div class="col-sm-6 form-group"
51
- :class="[$v.f_community_id.required ? 'has-error' : 'has-success']">
52
- <label class="font_normal_body">片区</label>
53
- <input type="text" style="width:60%" class="input_search" v-show="false" v-model="areamodel.f_community_id"
54
- v-validate:f_community_id='{required: true }'>
55
- <v-select
56
- :value.sync="areamodel.f_community_id" :value-single="true"
57
- :options='communitylist' placeholder='请选择'
58
- close-on-select search="true" >
50
+ <div class="col-sm-6 form-group" :class="[$v.slice.required ? 'has-error' : 'has-success']">
51
+ <label class="font_normal_body">片&emsp;&emsp;区</label>
52
+ <input type="text" style="width:60%" class="input_search" v-show="false" v-model="$refs.slice.selectedItems"
53
+ v-validate:slice='{required: true }'>
54
+ <v-select :value.sync="areamodel.slice_area" v-model="areamodel.slice_area"
55
+ :options='sliceArea' placeholder='片区/管理站' filer-key="name"
56
+ close-on-select v-ref:slice>
59
57
  </v-select>
60
58
  </div>
61
59
  <!--小区(特殊)信息-->
@@ -272,6 +270,7 @@
272
270
  </template>
273
271
 
274
272
  <script>
273
+ import AddressSafeApi from '../util/AddressSafeApi'
275
274
  import {HttpResetClass} from 'vue-client'
276
275
 
277
276
  let initGen = async function (self) {
@@ -294,8 +293,6 @@
294
293
  pcdslist:[],
295
294
  //初始化街道数据
296
295
  streetslist:[],
297
- //片区
298
- communitylist:[],
299
296
  //小区
300
297
  areamodel: {
301
298
  f_area_id: '',
@@ -304,8 +301,6 @@
304
301
  f_linkphone:'',
305
302
  f_street_id:'',
306
303
  f_slice_area:'',
307
- f_community_id:'',
308
- f_community:'',
309
304
  f_adjustable_id:'',
310
305
  f_residential_area:'',
311
306
  f_user_type:'',
@@ -349,10 +344,11 @@
349
344
  // 初始化参数
350
345
  await this.initParams()
351
346
  if (this.areatype == '楼栋') {
352
- this.initareas(` f_orgid = '${this.f_filialeids}'`)
347
+ this.initareas({ orgId: this.f_filialeids })
353
348
  }
354
- await this.initpcds(` f_filialeid = '${this.f_filialeids}'`)
355
- // await this.initcommunity(` f_filialeid = '${this.f_filialeids}'`)
349
+ // 初始化片区
350
+ await this.initSlice(this.f_filialeids)
351
+ await this.initpcds({ filialeId: this.f_filialeids })
356
352
  },
357
353
  initrow(val){
358
354
  this.areamodel.f_meter_book = val.f_meter_book;
@@ -400,100 +396,23 @@
400
396
  }
401
397
  },
402
398
  //初始化小区添加小区
403
- async initareas(pconditon){
404
- // if(this.usertype){
405
- // pconditon=pconditon+` and f_special='1' `
406
- // }
399
+ async initareas (params) {
407
400
  this.areaslist = []
408
- let HttpReset = new HttpResetClass()
409
- let req = await HttpReset.load('POST', 'api/af-revenue/sql/address_singleTableOrderBy?pageNo=1&pageSize=9999999', {
410
- data: {
411
- items: '*',
412
- tablename: 't_area',
413
- orderitem: 'id',
414
- condition: pconditon
415
- }
416
- }, {resolveMsg: null, rejectMsg: '获取地址失败!'})
417
- let redata = []
418
- req.data.forEach((row) => {
419
- redata.push({
420
- label: '['+row.f_street+']'+row.f_residential_area,
421
- value: row.id,
422
- data: row,
423
- id: row.id
424
- })
425
- })
426
- this.areaslist=redata
401
+ const req = await AddressSafeApi.listAreaOptions(this, params, { rejectMsg: '获取地址失败!' })
402
+ this.areaslist = AddressSafeApi.mapAreaRows(req.data, (row) => '[' + row.f_street + ']' + row.f_residential_area)
427
403
  },
428
404
 
429
405
  //初始化省市区,添加街道
430
- async initpcds(pconditon){
406
+ async initpcds (params) {
431
407
  this.pcdslist = []
432
- let HttpReset = new HttpResetClass()
433
- let req = await HttpReset.load('POST', 'api/af-revenue/sql/address_singleTableOrderBy', {
434
- data: {
435
- items: '*',
436
- tablename: 't_pcd',
437
- orderitem: 'id',
438
- condition: pconditon
439
- }
440
- }, {resolveMsg: null, rejectMsg: '获取地址失败!'})
441
- let redata = []
442
- req.data.forEach((row, n) => {
443
- redata[n] = {
444
- label: row.f_pcd,
445
- value: row.id,
446
- data:row,
447
- id:row.id
448
- }
449
- })
450
- this.pcdslist=redata
451
-
408
+ const req = await AddressSafeApi.listPcdOptions(this, params, { rejectMsg: '获取地址失败!' })
409
+ this.pcdslist = AddressSafeApi.mapPcdRows(req.data)
452
410
  },
453
411
  //初始化街道 添加小区
454
- async initcommunity(pconditon){
455
- this.communitylist = []
456
- let HttpReset = new HttpResetClass()
457
- let req = await HttpReset.load('POST', 'api/af-revenue/sql/address_singleTableOrderBy', {
458
- data: {
459
- items: '*',
460
- tablename: 't_community',
461
- orderitem: 'id',
462
- condition: pconditon
463
- }
464
- }, {resolveMsg: null, rejectMsg: '获取地址失败!'})
465
- let redata = []
466
- req.data.forEach((row, n) => {
467
- redata[n] = {
468
- label: row.f_community_name,
469
- value: row.id,
470
- data:row,
471
- id:row.id
472
- }
473
- })
474
- this.communitylist=redata
475
- },
476
- async initstreets(pconditon){
412
+ async initstreets (params) {
477
413
  this.streetslist = []
478
- let HttpReset = new HttpResetClass()
479
- let req = await HttpReset.load('POST', 'api/af-revenue/sql/address_singleTableOrderBy', {
480
- data: {
481
- items: '*',
482
- tablename: 't_street',
483
- orderitem: 'id',
484
- condition: pconditon
485
- }
486
- }, {resolveMsg: null, rejectMsg: '获取地址失败!'})
487
- let redata = []
488
- req.data.forEach((row, n) => {
489
- redata[n] = {
490
- label: row.f_street,
491
- value: row.id,
492
- data:row,
493
- id:row.id
494
- }
495
- })
496
- this.streetslist=redata
414
+ const req = await AddressSafeApi.listStreetOptions(this, params, { rejectMsg: '获取地址失败!' })
415
+ this.streetslist = AddressSafeApi.mapStreetRows(req.data)
497
416
  },
498
417
  async areaidChangeHasnumber(){
499
418
  console.log(this.areamodel.f_area_id.length)
@@ -501,14 +420,7 @@
501
420
  this.$showAlert('请输入正确的位数', 'warning', 2000)
502
421
  this.areamodel.f_area_id = ''
503
422
  }else{
504
- let res =await this.$resetpost('api/af-revenue/sql/address_singleTableOrderBy', {
505
- data: {
506
- items: '*',
507
- tablename: 't_area',
508
- orderitem: 'id',
509
- condition: `f_area_id = '${this.areamodel.f_area_id}' and f_orgid = '${this.$login.f.orgid}'`
510
- }
511
- }, {resolveMsg: null, rejectMsg: null})
423
+ let res = await AddressSafeApi.checkAreaIdByOrg(this, { f_area_id: this.areamodel.f_area_id, excludeId: this.areamodel.id })
512
424
  if (res.data.length>0){
513
425
  if (res.data[0].id != this.areamodel.id) {
514
426
  this.$showAlert('当前编号已存在', 'warning', 2000)
@@ -526,7 +438,7 @@
526
438
  f_filialeid: this.f_filialeids
527
439
  }
528
440
 
529
- let res = await this.$resetpost('api/af-revenue/logic/address_validateAreaID', param, {resolveMsg: null,rejectMsg: '小区编号验证失败!!'})
441
+ let res = await this.$resetpost('rs/logic/address_validateAreaID', param, {resolveMsg: null,rejectMsg: '小区编号验证失败!!'})
530
442
  console.log('验证小区是否存在', res)
531
443
  if (res.data) {
532
444
  this.$showAlert('这个小区编号已存在!!!请核实', 'warning', 3000)
@@ -557,7 +469,7 @@
557
469
  async pcdChange(val){
558
470
  if(val){
559
471
  //那就把街道数据重新组织一下
560
- await this.initstreets(` f_filialeid = '${this.f_filialeids}' and f_pcd_id ='${val}' `)
472
+ await this.initstreets({ filialeId: this.f_filialeids, pcdId: val })
561
473
  if(this.areamodel.f_street_id){
562
474
  if (this.findbyid(this.streetslist,this.areamodel.f_street_id)) {
563
475
  let pcd_id=this.findbyid(this.streetslist,this.areamodel.f_street_id).f_pcd_id
@@ -573,24 +485,12 @@
573
485
  this.$resetValidation()
574
486
  },
575
487
  //街道变化
576
- async streetChange(val){
577
- if(val){
578
- await this.initcommunity(` f_filialeid = '${this.f_filialeids}' and f_street_id ='${val}' `)
579
- if(this.areamodel.f_community_id){
580
- if (this.findbyid(this.communitylist,this.areamodel.f_community_id)) {
581
- let pcd_id=this.findbyid(this.communitylist,this.areamodel.f_community_id).f_street_id
582
- if(pcd_id!=val){
583
- this.areamodel.f_community_id=''
584
- }
585
- } else {
586
- this.areamodel.f_community_id=''
587
- }
588
-
589
- }
488
+ streetChange(val){
489
+ if(val&&this.operation=='add'){
590
490
  // if(this.areamodel.f_pcd_id.length==0){
591
- // if (this.findbyid(this.streetslist,this.areamodel.f_street_id)) {
592
- // this.areamodel.f_pcd_id=this.findbyid(this.streetslist,this.areamodel.f_street_id).f_pcd_id
593
- // }
491
+ if (this.findbyid(this.streetslist,this.areamodel.f_street_id)) {
492
+ this.areamodel.f_pcd_id=this.findbyid(this.streetslist,this.areamodel.f_street_id).f_pcd_id
493
+ }
594
494
  // }
595
495
  }
596
496
  this.$resetValidation()
@@ -615,7 +515,7 @@
615
515
  this.buildingmodel.f_orgname = this.$login.f.orgs
616
516
  this.buildingmodel.f_depid = this.$login.f.depids
617
517
  this.buildingmodel.f_depname = this.$login.f.deps
618
- await this.$resetpost('api/af-revenue/logic/address_savebuilding', this.buildingmodel)
518
+ await this.$resetpost('rs/logic/address_savebuilding', this.buildingmodel)
619
519
  this.$refs.buildinglist.search()
620
520
  },
621
521
  //保存小区
@@ -638,9 +538,8 @@
638
538
  }
639
539
  this.areamodel.f_pcd=this.findbyid(this.pcdslist,this.areamodel.f_pcd_id).f_pcd
640
540
  this.areamodel.f_street=this.findbyid(this.streetslist,this.areamodel.f_street_id).f_street
641
- this.areamodel.f_community = this.findbyid(this.communitylist,this.areamodel.f_community_id).f_community_name
642
541
 
643
- await this.$resetpost('api/af-revenue/logic/address_updatearea', this.areamodel)
542
+ await this.$resetpost('rs/logic/address_updatearea', this.areamodel)
644
543
  },
645
544
  cleardara(){
646
545
  this.areamodel= {
@@ -678,23 +577,16 @@
678
577
  this.initdata()
679
578
  },
680
579
  'areamodel.f_pcd_id'(){
681
- if(this.areamodel.f_pcd_id&&this.areamodel.f_street_id && this.areamodel.f_community_id){
682
- if (this.findbyid(this.pcdslist,this.areamodel.f_pcd_id) && this.findbyid(this.streetslist,this.areamodel.f_street_id) &&this.findbyid(this.communitylist,this.areamodel.f_community_id)) {
683
- this.areamodel.f_area_address = this.findbyid(this.pcdslist,this.areamodel.f_pcd_id).f_pcd + this.findbyid(this.streetslist,this.areamodel.f_street_id).f_street+this.findbyid(this.communitylist,this.areamodel.f_community_id).f_community_name
580
+ if(this.areamodel.f_pcd_id&&this.areamodel.f_street_id){
581
+ if (this.findbyid(this.pcdslist,this.areamodel.f_pcd_id) && this.findbyid(this.streetslist,this.areamodel.f_street_id)) {
582
+ this.areamodel.f_area_address = this.findbyid(this.pcdslist,this.areamodel.f_pcd_id).f_pcd + this.findbyid(this.streetslist,this.areamodel.f_street_id).f_street
684
583
  }
685
584
  }
686
585
  },
687
586
  'areamodel.f_street_id'(){
688
- if(this.areamodel.f_pcd_id&&this.areamodel.f_street_id&& this.areamodel.f_community_id){
689
- if (this.findbyid(this.pcdslist,this.areamodel.f_pcd_id) && this.findbyid(this.streetslist,this.areamodel.f_street_id) &&this.findbyid(this.communitylist,this.areamodel.f_community_id)) {
690
- this.areamodel.f_area_address = this.findbyid(this.pcdslist,this.areamodel.f_pcd_id).f_pcd + this.findbyid(this.streetslist,this.areamodel.f_street_id).f_street+this.findbyid(this.communitylist,this.areamodel.f_community_id).f_community_name
691
- }
692
- }
693
- },
694
- 'areamodel.f_community_id'(){
695
- if(this.areamodel.f_pcd_id&&this.areamodel.f_street_id && this.areamodel.f_community_id){
696
- if (this.findbyid(this.pcdslist,this.areamodel.f_pcd_id) && this.findbyid(this.streetslist,this.areamodel.f_street_id) &&this.findbyid(this.communitylist,this.areamodel.f_community_id)) {
697
- this.areamodel.f_area_address = this.findbyid(this.pcdslist,this.areamodel.f_pcd_id).f_pcd + this.findbyid(this.streetslist,this.areamodel.f_street_id).f_street+this.findbyid(this.communitylist,this.areamodel.f_community_id).f_community_name
587
+ if (this.areamodel.f_pcd_id && this.areamodel.f_street_id) {
588
+ if (this.findbyid(this.pcdslist, this.areamodel.f_pcd_id) && this.findbyid(this.streetslist, this.areamodel.f_street_id)) {
589
+ this.areamodel.f_area_address = this.findbyid(this.pcdslist, this.areamodel.f_pcd_id).f_pcd + this.findbyid(this.streetslist, this.areamodel.f_street_id).f_street
698
590
  }
699
591
  }
700
592
  },