Commit abdb3f17ff56d14dd1af5f2cfb617b770e260fd9
1 parent
857cca47
Exists in
dev
点火
Showing
7 changed files
with
359 additions
and
185 deletions
Show diff stats
zr-cloud/zr-modules/zr-schsf/src/main/java/com/chinagas/modules/schsf/controller/McIgnitionController.java
1 | package com.chinagas.modules.schsf.controller; | 1 | package com.chinagas.modules.schsf.controller; |
2 | 2 | ||
3 | -import com.alibaba.excel.EasyExcel; | ||
4 | -import com.alibaba.excel.util.MapUtils; | ||
5 | -import com.alibaba.fastjson2.JSON; | 3 | +import cn.hutool.core.bean.BeanUtil; |
6 | import com.chinagas.common.core.domain.AjaxResult; | 4 | import com.chinagas.common.core.domain.AjaxResult; |
5 | +import com.chinagas.common.core.utils.StringUtils; | ||
7 | import com.chinagas.common.core.web.controller.BaseController; | 6 | import com.chinagas.common.core.web.controller.BaseController; |
8 | import com.chinagas.common.core.web.page.TableDataInfo; | 7 | import com.chinagas.common.core.web.page.TableDataInfo; |
9 | import com.chinagas.common.log.annotation.Log; | 8 | import com.chinagas.common.log.annotation.Log; |
@@ -14,11 +13,7 @@ import com.chinagas.modules.schsf.service.IMcIgnitionService; | @@ -14,11 +13,7 @@ import com.chinagas.modules.schsf.service.IMcIgnitionService; | ||
14 | import org.springframework.beans.factory.annotation.Autowired; | 13 | import org.springframework.beans.factory.annotation.Autowired; |
15 | import org.springframework.web.bind.annotation.*; | 14 | import org.springframework.web.bind.annotation.*; |
16 | 15 | ||
17 | -import javax.servlet.http.HttpServletResponse; | ||
18 | -import java.io.IOException; | ||
19 | -import java.net.URLEncoder; | ||
20 | import java.util.List; | 16 | import java.util.List; |
21 | -import java.util.Map; | ||
22 | 17 | ||
23 | 18 | ||
24 | /** | 19 | /** |
@@ -47,9 +42,35 @@ public class McIgnitionController extends BaseController | @@ -47,9 +42,35 @@ public class McIgnitionController extends BaseController | ||
47 | } | 42 | } |
48 | 43 | ||
49 | 44 | ||
50 | - /** | ||
51 | - * 导出点火维护列表 | 45 | + /** |
46 | + * 新增点火维护 | ||
52 | */ | 47 | */ |
48 | + @RequirePermission("schsf:mcIgnition:maintenance") | ||
49 | + @Log(title = "点火维护", businessType = BusinessType.UPDATE) | ||
50 | + @PostMapping("/maintenance") | ||
51 | + public AjaxResult maintenance(@RequestBody McIgnition mcIgnition) throws CloneNotSupportedException { | ||
52 | + if (BeanUtil.isEmpty(mcIgnition)){ | ||
53 | + throw new RuntimeException("参数不可为空"); | ||
54 | + } | ||
55 | + if (mcIgnition.getId()==null){ | ||
56 | + throw new RuntimeException("id不可为空"); | ||
57 | + } | ||
58 | + if (StringUtils.isEmpty(mcIgnition.getIgnCnfStatusCode())){ | ||
59 | + throw new RuntimeException("确认状态不可为空"); | ||
60 | + } | ||
61 | + if (mcIgnition.getIgnTime()==null){ | ||
62 | + throw new RuntimeException("点火时间不可为空"); | ||
63 | + } | ||
64 | + return toAjax(mcIgnitionService.updateMcIgnitionMaintenance(mcIgnition)); | ||
65 | + } | ||
66 | + | ||
67 | + | ||
68 | + | ||
69 | + | ||
70 | +/* | ||
71 | + *//** | ||
72 | + * 导出点火维护列表 | ||
73 | + *//* | ||
53 | @RequirePermission("schsf:mcIgnition:export") | 74 | @RequirePermission("schsf:mcIgnition:export") |
54 | @Log(title = "点火维护",businessType = BusinessType.EXPORT) | 75 | @Log(title = "点火维护",businessType = BusinessType.EXPORT) |
55 | @PostMapping("/export") | 76 | @PostMapping("/export") |
@@ -78,9 +99,9 @@ public class McIgnitionController extends BaseController | @@ -78,9 +99,9 @@ public class McIgnitionController extends BaseController | ||
78 | } | 99 | } |
79 | 100 | ||
80 | 101 | ||
81 | - /** | 102 | + *//** |
82 | * 获取点火维护详细信息 | 103 | * 获取点火维护详细信息 |
83 | - */ | 104 | + *//* |
84 | @RequirePermission("schsf:mcIgnition:query") | 105 | @RequirePermission("schsf:mcIgnition:query") |
85 | @GetMapping(value = "/{id}") | 106 | @GetMapping(value = "/{id}") |
86 | public AjaxResult getInfo(@PathVariable("id") Long id) | 107 | public AjaxResult getInfo(@PathVariable("id") Long id) |
@@ -88,9 +109,9 @@ public class McIgnitionController extends BaseController | @@ -88,9 +109,9 @@ public class McIgnitionController extends BaseController | ||
88 | return AjaxResult.success(mcIgnitionService.selectMcIgnitionById(id)); | 109 | return AjaxResult.success(mcIgnitionService.selectMcIgnitionById(id)); |
89 | } | 110 | } |
90 | 111 | ||
91 | - /** | 112 | + *//** |
92 | * 新增点火维护 | 113 | * 新增点火维护 |
93 | - */ | 114 | + *//* |
94 | @RequirePermission("schsf:mcIgnition:add") | 115 | @RequirePermission("schsf:mcIgnition:add") |
95 | @Log(title = "点火维护", businessType = BusinessType.INSERT) | 116 | @Log(title = "点火维护", businessType = BusinessType.INSERT) |
96 | @PostMapping | 117 | @PostMapping |
@@ -99,9 +120,9 @@ public class McIgnitionController extends BaseController | @@ -99,9 +120,9 @@ public class McIgnitionController extends BaseController | ||
99 | return toAjax(mcIgnitionService.insertMcIgnition(mcIgnition)); | 120 | return toAjax(mcIgnitionService.insertMcIgnition(mcIgnition)); |
100 | } | 121 | } |
101 | 122 | ||
102 | - /** | 123 | + *//** |
103 | * 修改点火维护 | 124 | * 修改点火维护 |
104 | - */ | 125 | + *//* |
105 | @RequirePermission("schsf:mcIgnition:edit") | 126 | @RequirePermission("schsf:mcIgnition:edit") |
106 | @Log(title = "点火维护", businessType = BusinessType.UPDATE) | 127 | @Log(title = "点火维护", businessType = BusinessType.UPDATE) |
107 | @PutMapping | 128 | @PutMapping |
@@ -110,14 +131,14 @@ public class McIgnitionController extends BaseController | @@ -110,14 +131,14 @@ public class McIgnitionController extends BaseController | ||
110 | return toAjax(mcIgnitionService.updateMcIgnition(mcIgnition)); | 131 | return toAjax(mcIgnitionService.updateMcIgnition(mcIgnition)); |
111 | } | 132 | } |
112 | 133 | ||
113 | - /** | 134 | + *//** |
114 | * 删除点火维护 | 135 | * 删除点火维护 |
115 | - */ | 136 | + *//* |
116 | @RequirePermission("schsf:mcIgnition:remove") | 137 | @RequirePermission("schsf:mcIgnition:remove") |
117 | @Log(title = "点火维护", businessType = BusinessType.DELETE) | 138 | @Log(title = "点火维护", businessType = BusinessType.DELETE) |
118 | @DeleteMapping("/{ids}") | 139 | @DeleteMapping("/{ids}") |
119 | public AjaxResult remove(@PathVariable Long[] ids) | 140 | public AjaxResult remove(@PathVariable Long[] ids) |
120 | { | 141 | { |
121 | return toAjax(mcIgnitionService.deleteMcIgnitionByIds(ids)); | 142 | return toAjax(mcIgnitionService.deleteMcIgnitionByIds(ids)); |
122 | - } | 143 | + }*/ |
123 | } | 144 | } |
zr-cloud/zr-modules/zr-schsf/src/main/java/com/chinagas/modules/schsf/domain/McIgnition.java
1 | package com.chinagas.modules.schsf.domain; | 1 | package com.chinagas.modules.schsf.domain; |
2 | 2 | ||
3 | +import cn.hutool.core.date.DateTime; | ||
3 | import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; | 4 | import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; |
4 | import com.alibaba.excel.annotation.ExcelProperty; | 5 | import com.alibaba.excel.annotation.ExcelProperty; |
5 | import com.chinagas.common.core.web.domain.BaseEntity; | 6 | import com.chinagas.common.core.web.domain.BaseEntity; |
6 | import org.apache.commons.lang3.builder.ToStringBuilder; | 7 | import org.apache.commons.lang3.builder.ToStringBuilder; |
7 | import org.apache.commons.lang3.builder.ToStringStyle; | 8 | import org.apache.commons.lang3.builder.ToStringStyle; |
8 | 9 | ||
10 | +import java.time.LocalDateTime; | ||
9 | import java.util.Date; | 11 | import java.util.Date; |
10 | 12 | ||
11 | /** | 13 | /** |
@@ -15,340 +17,361 @@ import java.util.Date; | @@ -15,340 +17,361 @@ import java.util.Date; | ||
15 | * @date 2024-05-22 | 17 | * @date 2024-05-22 |
16 | */ | 18 | */ |
17 | @ExcelIgnoreUnannotated | 19 | @ExcelIgnoreUnannotated |
18 | -public class McIgnition extends BaseEntity | ||
19 | -{ | 20 | +public class McIgnition extends BaseEntity implements Cloneable { |
20 | private static final long serialVersionUID = 1L; | 21 | private static final long serialVersionUID = 1L; |
21 | 22 | ||
22 | - /** 主键id */ | 23 | + /** |
24 | + * 主键id | ||
25 | + */ | ||
23 | private Long id; | 26 | private Long id; |
24 | 27 | ||
25 | - /** 拜访id */ | 28 | + /** |
29 | + * 拜访id | ||
30 | + */ | ||
26 | @ExcelProperty(value = "拜访id") | 31 | @ExcelProperty(value = "拜访id") |
27 | private Long visitId; | 32 | private Long visitId; |
28 | 33 | ||
29 | - /** 区域名称 */ | 34 | + /** |
35 | + * 区域名称 | ||
36 | + */ | ||
30 | @ExcelProperty(value = "区域名称") | 37 | @ExcelProperty(value = "区域名称") |
31 | private String regionName; | 38 | private String regionName; |
32 | 39 | ||
33 | - /** 集团名称 */ | 40 | + /** |
41 | + * 集团名称 | ||
42 | + */ | ||
34 | @ExcelProperty(value = "集团名称") | 43 | @ExcelProperty(value = "集团名称") |
35 | private String groupName; | 44 | private String groupName; |
36 | 45 | ||
37 | - /** 公司名称 */ | 46 | + /** |
47 | + * 公司名称 | ||
48 | + */ | ||
38 | @ExcelProperty(value = "公司名称") | 49 | @ExcelProperty(value = "公司名称") |
39 | private String companyName; | 50 | private String companyName; |
40 | 51 | ||
41 | - /** 公司代码 */ | 52 | + /** |
53 | + * 公司代码 | ||
54 | + */ | ||
42 | @ExcelProperty(value = "公司代码") | 55 | @ExcelProperty(value = "公司代码") |
43 | private String companyCode; | 56 | private String companyCode; |
44 | 57 | ||
45 | - /** 客户-省 */ | 58 | + /** |
59 | + * 客户-省 | ||
60 | + */ | ||
46 | @ExcelProperty(value = "客户-省") | 61 | @ExcelProperty(value = "客户-省") |
47 | private String userProvince; | 62 | private String userProvince; |
48 | 63 | ||
49 | - /** 客户-市 */ | 64 | + /** |
65 | + * 客户-市 | ||
66 | + */ | ||
50 | @ExcelProperty(value = "客户-市") | 67 | @ExcelProperty(value = "客户-市") |
51 | private String userCity; | 68 | private String userCity; |
52 | 69 | ||
53 | - /** 客户-区 */ | 70 | + /** |
71 | + * 客户-区 | ||
72 | + */ | ||
54 | @ExcelProperty(value = "客户-区") | 73 | @ExcelProperty(value = "客户-区") |
55 | private String userDistrict; | 74 | private String userDistrict; |
56 | 75 | ||
57 | - /** 客户-街道 */ | 76 | + /** |
77 | + * 客户-街道 | ||
78 | + */ | ||
58 | @ExcelProperty(value = "客户-街道") | 79 | @ExcelProperty(value = "客户-街道") |
59 | private String userStreet; | 80 | private String userStreet; |
60 | 81 | ||
61 | - /** 村(小区) */ | 82 | + /** |
83 | + * 村(小区) | ||
84 | + */ | ||
62 | @ExcelProperty(value = "村(小区)") | 85 | @ExcelProperty(value = "村(小区)") |
63 | private String vlgOrCmty; | 86 | private String vlgOrCmty; |
64 | 87 | ||
65 | - /** 城乡分类 */ | 88 | + /** |
89 | + * 城乡分类 | ||
90 | + */ | ||
66 | @ExcelProperty(value = "城乡分类") | 91 | @ExcelProperty(value = "城乡分类") |
67 | private String urbRurCls; | 92 | private String urbRurCls; |
68 | 93 | ||
69 | - /** 客户-详细地址 */ | 94 | + /** |
95 | + * 客户-详细地址 | ||
96 | + */ | ||
70 | @ExcelProperty(value = "客户-详细地址") | 97 | @ExcelProperty(value = "客户-详细地址") |
71 | private String userDetailedAddress; | 98 | private String userDetailedAddress; |
72 | 99 | ||
73 | - /** 客户-用户编号 */ | 100 | + /** |
101 | + * 客户-用户编号 | ||
102 | + */ | ||
74 | @ExcelProperty(value = "客户-用户编号") | 103 | @ExcelProperty(value = "客户-用户编号") |
75 | private String userCode; | 104 | private String userCode; |
76 | 105 | ||
77 | - /** 客户-户名 */ | 106 | + /** |
107 | + * 客户-户名 | ||
108 | + */ | ||
78 | @ExcelProperty(value = "客户-户名") | 109 | @ExcelProperty(value = "客户-户名") |
79 | private String userName; | 110 | private String userName; |
80 | 111 | ||
81 | - /** 客户-电话 */ | 112 | + /** |
113 | + * 客户-电话 | ||
114 | + */ | ||
82 | @ExcelProperty(value = "客户-电话") | 115 | @ExcelProperty(value = "客户-电话") |
83 | private String userPhone; | 116 | private String userPhone; |
84 | 117 | ||
85 | - /** 点火确认状态代码(0:未确认,1:是,2:否) */ | ||
86 | - @ExcelProperty(value = "点火确认状态代码(0:未确认,1:是,2:否)") | 118 | + /** |
119 | + * 点火确认状态代码(NULL:未确认,Y:是,N:否) | ||
120 | + */ | ||
121 | + @ExcelProperty(value = "点火确认状态代码(NULL:未确认,Y:是,N:否)") | ||
87 | private String ignCnfStatusCode; | 122 | private String ignCnfStatusCode; |
88 | 123 | ||
89 | - /** 点火时间 */ | 124 | + /** |
125 | + * 点火时间 | ||
126 | + */ | ||
90 | @ExcelProperty(value = "点火时间") | 127 | @ExcelProperty(value = "点火时间") |
91 | - private Date ignTime; | 128 | + private LocalDateTime ignTime; |
92 | 129 | ||
93 | - /** 未点火原因 */ | 130 | + /** |
131 | + * 未点火原因 | ||
132 | + */ | ||
94 | @ExcelProperty(value = "未点火原因") | 133 | @ExcelProperty(value = "未点火原因") |
95 | private String nIgnRsn; | 134 | private String nIgnRsn; |
96 | 135 | ||
97 | - /** 负责人ID */ | 136 | + /** |
137 | + * 负责人ID | ||
138 | + */ | ||
98 | @ExcelProperty(value = "负责人ID") | 139 | @ExcelProperty(value = "负责人ID") |
99 | private Long cnfPersonId; | 140 | private Long cnfPersonId; |
100 | 141 | ||
101 | - /** 负责人名称 */ | 142 | + /** |
143 | + * 负责人名称 | ||
144 | + */ | ||
102 | @ExcelProperty(value = "负责人名称") | 145 | @ExcelProperty(value = "负责人名称") |
103 | private String cnfPersonName; | 146 | private String cnfPersonName; |
104 | 147 | ||
105 | - /** 负责人账号 */ | 148 | + /** |
149 | + * 负责人账号 | ||
150 | + */ | ||
106 | @ExcelProperty(value = "负责人账号") | 151 | @ExcelProperty(value = "负责人账号") |
107 | private String cnfPersonAccount; | 152 | private String cnfPersonAccount; |
108 | 153 | ||
109 | - /** 删除标志(0:未删除,1:已删除) */ | 154 | + /** |
155 | + * 删除标志(0:未删除,1:已删除) | ||
156 | + */ | ||
110 | @ExcelProperty(value = "删除标志") | 157 | @ExcelProperty(value = "删除标志") |
111 | private String defFlag; | 158 | private String defFlag; |
112 | 159 | ||
113 | - public void setId(Long id) | ||
114 | - { | 160 | + |
161 | + /** | ||
162 | + * 状态名称 | ||
163 | + */ | ||
164 | + private String statusName; | ||
165 | + /** | ||
166 | + * 状态代码 | ||
167 | + */ | ||
168 | + private String statusCode; | ||
169 | + | ||
170 | + | ||
171 | + public void setId(Long id) { | ||
115 | this.id = id; | 172 | this.id = id; |
116 | } | 173 | } |
117 | 174 | ||
118 | - public Long getId() | ||
119 | - { | 175 | + public Long getId() { |
120 | return id; | 176 | return id; |
121 | } | 177 | } |
122 | - public void setVisitId(Long visitId) | ||
123 | - { | 178 | + |
179 | + public void setVisitId(Long visitId) { | ||
124 | this.visitId = visitId; | 180 | this.visitId = visitId; |
125 | } | 181 | } |
126 | 182 | ||
127 | - public Long getVisitId() | ||
128 | - { | 183 | + public Long getVisitId() { |
129 | return visitId; | 184 | return visitId; |
130 | } | 185 | } |
131 | - public void setRegionName(String regionName) | ||
132 | - { | 186 | + |
187 | + public void setRegionName(String regionName) { | ||
133 | this.regionName = regionName; | 188 | this.regionName = regionName; |
134 | } | 189 | } |
135 | 190 | ||
136 | - public String getRegionName() | ||
137 | - { | 191 | + public String getRegionName() { |
138 | return regionName; | 192 | return regionName; |
139 | } | 193 | } |
140 | - public void setGroupName(String groupName) | ||
141 | - { | 194 | + |
195 | + public void setGroupName(String groupName) { | ||
142 | this.groupName = groupName; | 196 | this.groupName = groupName; |
143 | } | 197 | } |
144 | 198 | ||
145 | - public String getGroupName() | ||
146 | - { | 199 | + public String getGroupName() { |
147 | return groupName; | 200 | return groupName; |
148 | } | 201 | } |
149 | - public void setCompanyName(String companyName) | ||
150 | - { | 202 | + |
203 | + public void setCompanyName(String companyName) { | ||
151 | this.companyName = companyName; | 204 | this.companyName = companyName; |
152 | } | 205 | } |
153 | 206 | ||
154 | - public String getCompanyName() | ||
155 | - { | 207 | + public String getCompanyName() { |
156 | return companyName; | 208 | return companyName; |
157 | } | 209 | } |
158 | - public void setCompanyCode(String companyCode) | ||
159 | - { | 210 | + |
211 | + public void setCompanyCode(String companyCode) { | ||
160 | this.companyCode = companyCode; | 212 | this.companyCode = companyCode; |
161 | } | 213 | } |
162 | 214 | ||
163 | - public String getCompanyCode() | ||
164 | - { | 215 | + public String getCompanyCode() { |
165 | return companyCode; | 216 | return companyCode; |
166 | } | 217 | } |
167 | - public void setUserProvince(String userProvince) | ||
168 | - { | 218 | + |
219 | + public void setUserProvince(String userProvince) { | ||
169 | this.userProvince = userProvince; | 220 | this.userProvince = userProvince; |
170 | } | 221 | } |
171 | 222 | ||
172 | - public String getUserProvince() | ||
173 | - { | 223 | + public String getUserProvince() { |
174 | return userProvince; | 224 | return userProvince; |
175 | } | 225 | } |
176 | - public void setUserCity(String userCity) | ||
177 | - { | 226 | + |
227 | + public void setUserCity(String userCity) { | ||
178 | this.userCity = userCity; | 228 | this.userCity = userCity; |
179 | } | 229 | } |
180 | 230 | ||
181 | - public String getUserCity() | ||
182 | - { | 231 | + public String getUserCity() { |
183 | return userCity; | 232 | return userCity; |
184 | } | 233 | } |
185 | - public void setUserDistrict(String userDistrict) | ||
186 | - { | 234 | + |
235 | + public void setUserDistrict(String userDistrict) { | ||
187 | this.userDistrict = userDistrict; | 236 | this.userDistrict = userDistrict; |
188 | } | 237 | } |
189 | 238 | ||
190 | - public String getUserDistrict() | ||
191 | - { | 239 | + public String getUserDistrict() { |
192 | return userDistrict; | 240 | return userDistrict; |
193 | } | 241 | } |
194 | - public void setUserStreet(String userStreet) | ||
195 | - { | 242 | + |
243 | + public void setUserStreet(String userStreet) { | ||
196 | this.userStreet = userStreet; | 244 | this.userStreet = userStreet; |
197 | } | 245 | } |
198 | 246 | ||
199 | - public String getUserStreet() | ||
200 | - { | 247 | + public String getUserStreet() { |
201 | return userStreet; | 248 | return userStreet; |
202 | } | 249 | } |
203 | - public void setVlgOrCmty(String vlgOrCmty) | ||
204 | - { | 250 | + |
251 | + public void setVlgOrCmty(String vlgOrCmty) { | ||
205 | this.vlgOrCmty = vlgOrCmty; | 252 | this.vlgOrCmty = vlgOrCmty; |
206 | } | 253 | } |
207 | 254 | ||
208 | - public String getVlgOrCmty() | ||
209 | - { | 255 | + public String getVlgOrCmty() { |
210 | return vlgOrCmty; | 256 | return vlgOrCmty; |
211 | } | 257 | } |
212 | - public void setUrbRurCls(String urbRurCls) | ||
213 | - { | 258 | + |
259 | + public void setUrbRurCls(String urbRurCls) { | ||
214 | this.urbRurCls = urbRurCls; | 260 | this.urbRurCls = urbRurCls; |
215 | } | 261 | } |
216 | 262 | ||
217 | - public String getUrbRurCls() | ||
218 | - { | 263 | + public String getUrbRurCls() { |
219 | return urbRurCls; | 264 | return urbRurCls; |
220 | } | 265 | } |
221 | - public void setUserDetailedAddress(String userDetailedAddress) | ||
222 | - { | 266 | + |
267 | + public void setUserDetailedAddress(String userDetailedAddress) { | ||
223 | this.userDetailedAddress = userDetailedAddress; | 268 | this.userDetailedAddress = userDetailedAddress; |
224 | } | 269 | } |
225 | 270 | ||
226 | - public String getUserDetailedAddress() | ||
227 | - { | 271 | + public String getUserDetailedAddress() { |
228 | return userDetailedAddress; | 272 | return userDetailedAddress; |
229 | } | 273 | } |
230 | - public void setUserCode(String userCode) | ||
231 | - { | 274 | + |
275 | + public void setUserCode(String userCode) { | ||
232 | this.userCode = userCode; | 276 | this.userCode = userCode; |
233 | } | 277 | } |
234 | 278 | ||
235 | - public String getUserCode() | ||
236 | - { | 279 | + public String getUserCode() { |
237 | return userCode; | 280 | return userCode; |
238 | } | 281 | } |
239 | - public void setUserName(String userName) | ||
240 | - { | 282 | + |
283 | + public void setUserName(String userName) { | ||
241 | this.userName = userName; | 284 | this.userName = userName; |
242 | } | 285 | } |
243 | 286 | ||
244 | - public String getUserName() | ||
245 | - { | 287 | + public String getUserName() { |
246 | return userName; | 288 | return userName; |
247 | } | 289 | } |
248 | - public void setUserPhone(String userPhone) | ||
249 | - { | 290 | + |
291 | + public void setUserPhone(String userPhone) { | ||
250 | this.userPhone = userPhone; | 292 | this.userPhone = userPhone; |
251 | } | 293 | } |
252 | 294 | ||
253 | - public String getUserPhone() | ||
254 | - { | 295 | + public String getUserPhone() { |
255 | return userPhone; | 296 | return userPhone; |
256 | } | 297 | } |
257 | - public void setIgnCnfStatusCode(String ignCnfStatusCode) | ||
258 | - { | 298 | + |
299 | + public void setIgnCnfStatusCode(String ignCnfStatusCode) { | ||
259 | this.ignCnfStatusCode = ignCnfStatusCode; | 300 | this.ignCnfStatusCode = ignCnfStatusCode; |
260 | } | 301 | } |
261 | 302 | ||
262 | - public String getIgnCnfStatusCode() | ||
263 | - { | 303 | + public String getIgnCnfStatusCode() { |
264 | return ignCnfStatusCode; | 304 | return ignCnfStatusCode; |
265 | } | 305 | } |
266 | - public void setIgnTime(Date ignTime) | ||
267 | - { | 306 | + |
307 | + public void setIgnTime(LocalDateTime ignTime) { | ||
268 | this.ignTime = ignTime; | 308 | this.ignTime = ignTime; |
269 | } | 309 | } |
270 | 310 | ||
271 | - public Date getIgnTime() | ||
272 | - { | 311 | + public LocalDateTime getIgnTime() { |
273 | return ignTime; | 312 | return ignTime; |
274 | } | 313 | } |
275 | - public void setnIgnRsn(String nIgnRsn) | ||
276 | - { | 314 | + |
315 | + public void setnIgnRsn(String nIgnRsn) { | ||
277 | this.nIgnRsn = nIgnRsn; | 316 | this.nIgnRsn = nIgnRsn; |
278 | } | 317 | } |
279 | 318 | ||
280 | - public String getnIgnRsn() | ||
281 | - { | 319 | + public String getnIgnRsn() { |
282 | return nIgnRsn; | 320 | return nIgnRsn; |
283 | } | 321 | } |
284 | - public void setCnfPersonId(Long cnfPersonId) | ||
285 | - { | 322 | + |
323 | + public void setCnfPersonId(Long cnfPersonId) { | ||
286 | this.cnfPersonId = cnfPersonId; | 324 | this.cnfPersonId = cnfPersonId; |
287 | } | 325 | } |
288 | 326 | ||
289 | - public Long getCnfPersonId() | ||
290 | - { | 327 | + public Long getCnfPersonId() { |
291 | return cnfPersonId; | 328 | return cnfPersonId; |
292 | } | 329 | } |
293 | - public void setCnfPersonName(String cnfPersonName) | ||
294 | - { | 330 | + |
331 | + public void setCnfPersonName(String cnfPersonName) { | ||
295 | this.cnfPersonName = cnfPersonName; | 332 | this.cnfPersonName = cnfPersonName; |
296 | } | 333 | } |
297 | 334 | ||
298 | - public String getCnfPersonName() | ||
299 | - { | 335 | + public String getCnfPersonName() { |
300 | return cnfPersonName; | 336 | return cnfPersonName; |
301 | } | 337 | } |
302 | - public void setCnfPersonAccount(String cnfPersonAccount) | ||
303 | - { | 338 | + |
339 | + public void setCnfPersonAccount(String cnfPersonAccount) { | ||
304 | this.cnfPersonAccount = cnfPersonAccount; | 340 | this.cnfPersonAccount = cnfPersonAccount; |
305 | } | 341 | } |
306 | 342 | ||
307 | - public String getCnfPersonAccount() | ||
308 | - { | 343 | + public String getCnfPersonAccount() { |
309 | return cnfPersonAccount; | 344 | return cnfPersonAccount; |
310 | } | 345 | } |
311 | - public void setDefFlag(String defFlag) | ||
312 | - { | 346 | + |
347 | + public void setDefFlag(String defFlag) { | ||
313 | this.defFlag = defFlag; | 348 | this.defFlag = defFlag; |
314 | } | 349 | } |
315 | 350 | ||
316 | - public String getDefFlag() | ||
317 | - { | 351 | + public String getDefFlag() { |
318 | return defFlag; | 352 | return defFlag; |
319 | } | 353 | } |
320 | 354 | ||
355 | + | ||
356 | + public String getStatusName() { | ||
357 | + return statusName; | ||
358 | + } | ||
359 | + | ||
360 | + public void setStatusName(String statusName) { | ||
361 | + this.statusName = statusName; | ||
362 | + } | ||
363 | + | ||
364 | + public String getStatusCode() { | ||
365 | + return statusCode; | ||
366 | + } | ||
367 | + | ||
368 | + public void setStatusCode(String statusCode) { | ||
369 | + this.statusCode = statusCode; | ||
370 | + } | ||
371 | + | ||
372 | + | ||
321 | @Override | 373 | @Override |
322 | - public String toString() { | ||
323 | - return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) | ||
324 | - .append("id", getId()) | ||
325 | - .append("visitId", getVisitId()) | ||
326 | - .append("regionName", getRegionName()) | ||
327 | - .append("groupName", getGroupName()) | ||
328 | - .append("companyName", getCompanyName()) | ||
329 | - .append("companyCode", getCompanyCode()) | ||
330 | - .append("userProvince", getUserProvince()) | ||
331 | - .append("userCity", getUserCity()) | ||
332 | - .append("userDistrict", getUserDistrict()) | ||
333 | - .append("userStreet", getUserStreet()) | ||
334 | - .append("vlgOrCmty", getVlgOrCmty()) | ||
335 | - .append("urbRurCls", getUrbRurCls()) | ||
336 | - .append("userDetailedAddress", getUserDetailedAddress()) | ||
337 | - .append("userCode", getUserCode()) | ||
338 | - .append("userName", getUserName()) | ||
339 | - .append("userPhone", getUserPhone()) | ||
340 | - .append("ignCnfStatusCode", getIgnCnfStatusCode()) | ||
341 | - .append("ignTime", getIgnTime()) | ||
342 | - .append("nIgnRsn", getnIgnRsn()) | ||
343 | - .append("cnfPersonId", getCnfPersonId()) | ||
344 | - .append("cnfPersonName", getCnfPersonName()) | ||
345 | - .append("cnfPersonAccount", getCnfPersonAccount()) | ||
346 | - .append("remark", getRemark()) | ||
347 | - .append("createTime", getCreateTime()) | ||
348 | - .append("createBy", getCreateBy()) | ||
349 | - .append("updateTime", getUpdateTime()) | ||
350 | - .append("updateBy", getUpdateBy()) | ||
351 | - .append("defFlag", getDefFlag()) | ||
352 | - .toString(); | 374 | + public McIgnition clone() throws CloneNotSupportedException { |
375 | + return (McIgnition) super.clone(); | ||
353 | } | 376 | } |
354 | } | 377 | } |
zr-cloud/zr-modules/zr-schsf/src/main/java/com/chinagas/modules/schsf/enums/IgnitionStatusEnums.java
0 → 100644
@@ -0,0 +1,28 @@ | @@ -0,0 +1,28 @@ | ||
1 | +package com.chinagas.modules.schsf.enums; | ||
2 | + | ||
3 | +/** | ||
4 | + * 点火维护状态 | ||
5 | + */ | ||
6 | +public enum IgnitionStatusEnums { | ||
7 | + | ||
8 | + MAINTENANCE_PENDING("MAINTENANCE_PENDING", "待维护"), | ||
9 | + MAINTENANCE_YES("MAINTENANCE_YES", "已维护(是)"), | ||
10 | + MAINTENANCE_NO("MAINTENANCE_NO", "已维护(否)"), | ||
11 | + CANCEL("CANCEL", "已作废"); | ||
12 | + | ||
13 | + private final String code; | ||
14 | + private final String info; | ||
15 | + | ||
16 | + | ||
17 | + public String getCode() { | ||
18 | + return code; | ||
19 | + } | ||
20 | + public String getInfo() { | ||
21 | + return info; | ||
22 | + } | ||
23 | + IgnitionStatusEnums(String code, String info) { | ||
24 | + this.code = code; | ||
25 | + this.info = info; | ||
26 | + } | ||
27 | + | ||
28 | +} |
zr-cloud/zr-modules/zr-schsf/src/main/java/com/chinagas/modules/schsf/service/IMcIgnitionService.java
@@ -68,4 +68,13 @@ public interface IMcIgnitionService | @@ -68,4 +68,13 @@ public interface IMcIgnitionService | ||
68 | * @return 结果 | 68 | * @return 结果 |
69 | */ | 69 | */ |
70 | public int deleteMcIgnitionById(Long id); | 70 | public int deleteMcIgnitionById(Long id); |
71 | + | ||
72 | + /** | ||
73 | + * 点火确认 | ||
74 | + * @param mcIgnition | ||
75 | + * @return | ||
76 | + */ | ||
77 | + int updateMcIgnitionMaintenance(McIgnition mcIgnition) throws CloneNotSupportedException; | ||
78 | + | ||
79 | + void updateMcIgnitionCancel(Long visitId) throws CloneNotSupportedException; | ||
71 | } | 80 | } |
zr-cloud/zr-modules/zr-schsf/src/main/java/com/chinagas/modules/schsf/service/impl/McIgnitionServiceImpl.java
@@ -3,15 +3,20 @@ package com.chinagas.modules.schsf.service.impl; | @@ -3,15 +3,20 @@ package com.chinagas.modules.schsf.service.impl; | ||
3 | import com.alibaba.fastjson2.JSON; | 3 | import com.alibaba.fastjson2.JSON; |
4 | import com.chinagas.common.core.utils.DateUtils; | 4 | import com.chinagas.common.core.utils.DateUtils; |
5 | import com.chinagas.common.core.utils.StringUtils; | 5 | import com.chinagas.common.core.utils.StringUtils; |
6 | +import com.chinagas.common.datascope.annotation.DataScope; | ||
7 | +import com.chinagas.common.security.utils.SecurityUtils; | ||
6 | import com.chinagas.modules.schsf.domain.McIgnition; | 8 | import com.chinagas.modules.schsf.domain.McIgnition; |
7 | import com.chinagas.modules.schsf.domain.McVisit; | 9 | import com.chinagas.modules.schsf.domain.McVisit; |
10 | +import com.chinagas.modules.schsf.enums.IgnitionStatusEnums; | ||
8 | import com.chinagas.modules.schsf.enums.YesNoEnums; | 11 | import com.chinagas.modules.schsf.enums.YesNoEnums; |
9 | import com.chinagas.modules.schsf.mapper.McIgnitionMapper; | 12 | import com.chinagas.modules.schsf.mapper.McIgnitionMapper; |
10 | import com.chinagas.modules.schsf.service.IMcIgnitionService; | 13 | import com.chinagas.modules.schsf.service.IMcIgnitionService; |
11 | import com.chinagas.modules.schsf.service.IMcOperationLogService; | 14 | import com.chinagas.modules.schsf.service.IMcOperationLogService; |
12 | import org.springframework.beans.factory.annotation.Autowired; | 15 | import org.springframework.beans.factory.annotation.Autowired; |
13 | import org.springframework.stereotype.Service; | 16 | import org.springframework.stereotype.Service; |
17 | +import org.springframework.transaction.annotation.Transactional; | ||
14 | 18 | ||
19 | +import java.time.LocalDateTime; | ||
15 | import java.util.List; | 20 | import java.util.List; |
16 | 21 | ||
17 | /** | 22 | /** |
@@ -20,6 +25,7 @@ import java.util.List; | @@ -20,6 +25,7 @@ import java.util.List; | ||
20 | * @author cw | 25 | * @author cw |
21 | * @date 2024-05-22 | 26 | * @date 2024-05-22 |
22 | */ | 27 | */ |
28 | +@Transactional | ||
23 | @Service | 29 | @Service |
24 | public class McIgnitionServiceImpl implements IMcIgnitionService { | 30 | public class McIgnitionServiceImpl implements IMcIgnitionService { |
25 | @Autowired | 31 | @Autowired |
@@ -39,6 +45,13 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | @@ -39,6 +45,13 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | ||
39 | return 0; | 45 | return 0; |
40 | } | 46 | } |
41 | 47 | ||
48 | + LocalDateTime time = DateUtils.getNowLocal(); | ||
49 | + String userId = SecurityUtils.getUserId().toString(); | ||
50 | + String userAccount = SecurityUtils.getUsername(); | ||
51 | + String userName = SecurityUtils.getLoginUser().getSysUser().getNickName(); | ||
52 | + | ||
53 | + | ||
54 | + | ||
42 | McIgnition mcIgnition = new McIgnition(); | 55 | McIgnition mcIgnition = new McIgnition(); |
43 | mcIgnition.setRegionName(mcVisit.getRegionName()); | 56 | mcIgnition.setRegionName(mcVisit.getRegionName()); |
44 | mcIgnition.setGroupName(mcVisit.getGroupName()); | 57 | mcIgnition.setGroupName(mcVisit.getGroupName()); |
@@ -63,14 +76,17 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | @@ -63,14 +76,17 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | ||
63 | mcIgnition.setUserPhone(mcVisit.getUserPhone()); | 76 | mcIgnition.setUserPhone(mcVisit.getUserPhone()); |
64 | mcIgnition.setIgnCnfStatusCode("0"); | 77 | mcIgnition.setIgnCnfStatusCode("0"); |
65 | 78 | ||
66 | - mcIgnition.setCreateTime(mcVisit.getCreateTime()); | ||
67 | - mcIgnition.setCreateBy(mcVisit.getCreateBy()); | ||
68 | - mcIgnition.setUpdateTime(mcVisit.getUpdateTime()); | ||
69 | - mcIgnition.setUpdateBy(mcVisit.getUpdateBy()); | 79 | + mcIgnition.setCreateTime(time); |
80 | + mcIgnition.setCreateBy(userId); | ||
81 | + mcIgnition.setUpdateTime(time); | ||
82 | + mcIgnition.setUpdateBy(userId); | ||
83 | + | ||
84 | + mcIgnition.setStatusCode(IgnitionStatusEnums.MAINTENANCE_PENDING.getCode()); | ||
85 | + mcIgnition.setStatusName(IgnitionStatusEnums.MAINTENANCE_PENDING.getInfo()); | ||
70 | int i = mcIgnitionMapper.insertMcIgnition(mcIgnition); | 86 | int i = mcIgnitionMapper.insertMcIgnition(mcIgnition); |
71 | //1:添加记录 | 87 | //1:添加记录 |
72 | - iMcOperationLogService.insertMcOperationLog("mc_ignition", mcIgnition.getId(), "项目公司_收费员", | ||
73 | - mcVisit.getBillingPersonName(), mcVisit.getBillingPersonAccount(),mcVisit.getCreateBy(), mcIgnition.getCreateTime(), | 88 | + iMcOperationLogService.insertMcOperationLog("mc_ignition", mcIgnition.getId(), "点火维护", |
89 | + userName,userAccount,userId, mcIgnition.getCreateTime(), | ||
74 | "发起", "1", null, null, JSON.toJSONString(mcIgnition)); | 90 | "发起", "1", null, null, JSON.toJSONString(mcIgnition)); |
75 | return i; | 91 | return i; |
76 | } | 92 | } |
@@ -92,6 +108,7 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | @@ -92,6 +108,7 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | ||
92 | * @param mcIgnition 点火维护 | 108 | * @param mcIgnition 点火维护 |
93 | * @return 点火维护 | 109 | * @return 点火维护 |
94 | */ | 110 | */ |
111 | + @DataScope(deptAlias = "d", userAlias = "u") | ||
95 | @Override | 112 | @Override |
96 | public List<McIgnition> selectMcIgnitionList(McIgnition mcIgnition) { | 113 | public List<McIgnition> selectMcIgnitionList(McIgnition mcIgnition) { |
97 | return mcIgnitionMapper.selectMcIgnitionList(mcIgnition); | 114 | return mcIgnitionMapper.selectMcIgnitionList(mcIgnition); |
@@ -142,4 +159,68 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | @@ -142,4 +159,68 @@ public class McIgnitionServiceImpl implements IMcIgnitionService { | ||
142 | public int deleteMcIgnitionById(Long id) { | 159 | public int deleteMcIgnitionById(Long id) { |
143 | return mcIgnitionMapper.deleteMcIgnitionById(id); | 160 | return mcIgnitionMapper.deleteMcIgnitionById(id); |
144 | } | 161 | } |
162 | + | ||
163 | + /** | ||
164 | + * 点火维护 | ||
165 | + * @param mcIgnition | ||
166 | + * @return | ||
167 | + */ | ||
168 | + @Override | ||
169 | + public int updateMcIgnitionMaintenance(McIgnition mcIgnitionVo) throws CloneNotSupportedException { | ||
170 | + LocalDateTime time = DateUtils.getNowLocal(); | ||
171 | + Long userId = SecurityUtils.getUserId(); | ||
172 | + String userAccount = SecurityUtils.getUsername(); | ||
173 | + String userName = SecurityUtils.getLoginUser().getSysUser().getNickName(); | ||
174 | + //老数据 | ||
175 | + McIgnition mcIgnition_old = mcIgnitionMapper.selectMcIgnitionById(mcIgnitionVo.getId()); | ||
176 | + //新数据 | ||
177 | + McIgnition mcIgnition_new = mcIgnition_old.clone(); | ||
178 | + mcIgnition_new.setIgnCnfStatusCode(mcIgnitionVo.getIgnCnfStatusCode()); | ||
179 | + mcIgnition_new.setIgnTime(mcIgnitionVo.getIgnTime()); | ||
180 | + mcIgnition_new.setnIgnRsn(mcIgnitionVo.getnIgnRsn()); | ||
181 | + mcIgnition_new.setUpdateBy(userId.toString()); | ||
182 | + mcIgnition_new.setUpdateTime(time); | ||
183 | + mcIgnition_new.setStatusCode(mcIgnitionVo.getIgnCnfStatusCode().equals("Y")?IgnitionStatusEnums.MAINTENANCE_YES.getCode():IgnitionStatusEnums.MAINTENANCE_NO.getCode()); | ||
184 | + mcIgnition_new.setStatusName(mcIgnitionVo.getIgnCnfStatusCode().equals("Y")?IgnitionStatusEnums.MAINTENANCE_YES.getInfo():IgnitionStatusEnums.MAINTENANCE_NO.getInfo()); | ||
185 | + mcIgnition_new.setCnfPersonId(userId); | ||
186 | + mcIgnition_new.setCnfPersonAccount(userAccount); | ||
187 | + mcIgnition_new.setCnfPersonName(userName); | ||
188 | + int i = mcIgnitionMapper.updateMcIgnition(mcIgnition_new); | ||
189 | + //1:添加记录 | ||
190 | + iMcOperationLogService.insertMcOperationLog("mc_ignition", mcIgnitionVo.getId(), "点火维护", | ||
191 | + userName, userAccount,userId.toString(), time, | ||
192 | + "维护", "1", null, JSON.toJSONString(mcIgnition_old), JSON.toJSONString(mcIgnition_new)); | ||
193 | + return i; | ||
194 | + } | ||
195 | + | ||
196 | + /** | ||
197 | + * 作废 | ||
198 | + * @param visitId | ||
199 | + */ | ||
200 | + @Override | ||
201 | + public void updateMcIgnitionCancel(Long visitId) throws CloneNotSupportedException { | ||
202 | + LocalDateTime time = DateUtils.getNowLocal(); | ||
203 | + String userId = SecurityUtils.getUserId().toString(); | ||
204 | + String userAccount = SecurityUtils.getUsername(); | ||
205 | + String userName = SecurityUtils.getLoginUser().getSysUser().getNickName(); | ||
206 | + | ||
207 | + McIgnition mcIgnition= new McIgnition(); | ||
208 | + mcIgnition.setVisitId(visitId); | ||
209 | + List<McIgnition> mcIgnitions = mcIgnitionMapper.selectMcIgnitionList(mcIgnition); | ||
210 | + if (mcIgnitions !=null && mcIgnitions.size()>0){ | ||
211 | + for (McIgnition mcIgnition_old : mcIgnitions) { | ||
212 | + //新数据 | ||
213 | + McIgnition mcIgnition_new = mcIgnition_old.clone(); | ||
214 | + mcIgnition_new.setUpdateBy(userId); | ||
215 | + mcIgnition_new.setUpdateTime(time); | ||
216 | + mcIgnition_new.setStatusCode(IgnitionStatusEnums.CANCEL.getCode()); | ||
217 | + mcIgnition_new.setStatusName(IgnitionStatusEnums.CANCEL.getInfo()); | ||
218 | + int i = mcIgnitionMapper.updateMcIgnition(mcIgnition_new); | ||
219 | + //1:添加记录 | ||
220 | + iMcOperationLogService.insertMcOperationLog("mc_ignition", mcIgnition_new.getId(), "点火维护", | ||
221 | + userName, userAccount,userId, time, | ||
222 | + "作废", "1", null, JSON.toJSONString(mcIgnition_old), JSON.toJSONString(mcIgnition_new)); | ||
223 | + } | ||
224 | + } | ||
225 | + } | ||
145 | } | 226 | } |
zr-cloud/zr-modules/zr-schsf/src/main/java/com/chinagas/modules/schsf/service/impl/McVisitServiceImpl.java
@@ -105,7 +105,7 @@ public class McVisitServiceImpl implements IMcVisitService { | @@ -105,7 +105,7 @@ public class McVisitServiceImpl implements IMcVisitService { | ||
105 | 105 | ||
106 | private void getStatusNodeName(String publishStatus, String modificationStatus, String defFlag, McVisit mcVisit) { | 106 | private void getStatusNodeName(String publishStatus, String modificationStatus, String defFlag, McVisit mcVisit) { |
107 | if (StringUtils.isNotEmpty(defFlag) && defFlag.equals("1")) { | 107 | if (StringUtils.isNotEmpty(defFlag) && defFlag.equals("1")) { |
108 | - mcVisit.setDefFlag("1"); | 108 | +// mcVisit.setDefFlag("1"); |
109 | mcVisit.setStatusNodeName(""); | 109 | mcVisit.setStatusNodeName(""); |
110 | mcVisit.setStatusCode(VisitStatusEnums.CANCEL.getCode()); | 110 | mcVisit.setStatusCode(VisitStatusEnums.CANCEL.getCode()); |
111 | mcVisit.setStatusName(VisitStatusEnums.CANCEL.getInfo()); | 111 | mcVisit.setStatusName(VisitStatusEnums.CANCEL.getInfo()); |
@@ -414,6 +414,9 @@ public class McVisitServiceImpl implements IMcVisitService { | @@ -414,6 +414,9 @@ public class McVisitServiceImpl implements IMcVisitService { | ||
414 | iMcOperationLogService.insertMcOperationLog("mc_visit", mcVisit.getId(), "项目公司_市场负责人", | 414 | iMcOperationLogService.insertMcOperationLog("mc_visit", mcVisit.getId(), "项目公司_市场负责人", |
415 | userName, userAccount, userId, updateTime, | 415 | userName, userAccount, userId, updateTime, |
416 | "作废", "1", null, JSON.toJSONString(mcVisit), JSON.toJSONString(mcVisit_new)); | 416 | "作废", "1", null, JSON.toJSONString(mcVisit), JSON.toJSONString(mcVisit_new)); |
417 | + | ||
418 | + //2:作废至点火记录 | ||
419 | + iMcIgnitionService.updateMcIgnitionCancel(id); | ||
417 | return mcVisitMapper.updateMcVisit(mcVisit_new); | 420 | return mcVisitMapper.updateMcVisit(mcVisit_new); |
418 | } | 421 | } |
419 | 422 |
zr-cloud/zr-modules/zr-schsf/src/main/resources/mapper/McIgnitionMapper.xml
@@ -39,7 +39,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -39,7 +39,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
39 | select t.id, t.visit_id, t.region_name, t.group_name, t.company_name, t.company_code, t.user_province, t.user_city, | 39 | select t.id, t.visit_id, t.region_name, t.group_name, t.company_name, t.company_code, t.user_province, t.user_city, |
40 | t.user_district, t.user_street, t.vlg_or_cmty, t.urb_rur_cls, t.user_detailed_address, | 40 | t.user_district, t.user_street, t.vlg_or_cmty, t.urb_rur_cls, t.user_detailed_address, |
41 | t.user_code, t.user_name, t.user_phone, t.ign_cnf_status_code, t.ign_time, t.n_ign_rsn, t.cnf_person_id, | 41 | t.user_code, t.user_name, t.user_phone, t.ign_cnf_status_code, t.ign_time, t.n_ign_rsn, t.cnf_person_id, |
42 | - t.cnf_person_name, t.cnf_person_account, t.remark, t.create_time, t.create_by, t.update_time, t.update_by, t.def_flag | 42 | + t.cnf_person_name, t.cnf_person_account, t.remark, t.create_time, t.create_by, t.update_time, t.update_by, t.def_flag,t.status_code,t.status_name |
43 | from mc_ignition t | 43 | from mc_ignition t |
44 | left join sys_user u on u.user_id = t.create_by | 44 | left join sys_user u on u.user_id = t.create_by |
45 | left join sys_dept d on d.dept_id = t.company_code | 45 | left join sys_dept d on d.dept_id = t.company_code |
@@ -70,6 +70,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -70,6 +70,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
70 | <if test="cnfPersonName != null and cnfPersonName != ''"> and t.cnf_person_name like concat('%', #{cnfPersonName}, '%')</if> | 70 | <if test="cnfPersonName != null and cnfPersonName != ''"> and t.cnf_person_name like concat('%', #{cnfPersonName}, '%')</if> |
71 | <if test="cnfPersonAccount != null and cnfPersonAccount != ''"> and t.cnf_person_account = #{cnfPersonAccount}</if> | 71 | <if test="cnfPersonAccount != null and cnfPersonAccount != ''"> and t.cnf_person_account = #{cnfPersonAccount}</if> |
72 | <if test="defFlag != null and defFlag != ''"> and t.def_flag = #{defFlag}</if> | 72 | <if test="defFlag != null and defFlag != ''"> and t.def_flag = #{defFlag}</if> |
73 | + <if test="statusCode != null and statusCode != ''"> and t.status_code = #{statusCode}</if> | ||
74 | + <if test="statusName != null and statusName != ''"> and t.status_name = #{statusName}</if> | ||
73 | <!-- 数据范围过滤 --> | 75 | <!-- 数据范围过滤 --> |
74 | ${params.dataScope} | 76 | ${params.dataScope} |
75 | </where> | 77 | </where> |
@@ -111,6 +113,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -111,6 +113,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
111 | <if test="updateTime != null">update_time,</if> | 113 | <if test="updateTime != null">update_time,</if> |
112 | <if test="updateBy != null and updateBy != ''">update_by,</if> | 114 | <if test="updateBy != null and updateBy != ''">update_by,</if> |
113 | <if test="defFlag != null and defFlag != ''">def_flag,</if> | 115 | <if test="defFlag != null and defFlag != ''">def_flag,</if> |
116 | + <if test="statusCode != null">status_code,</if> | ||
117 | + <if test="statusName != null">status_name,</if> | ||
114 | </trim> | 118 | </trim> |
115 | <trim prefix="values (" suffix=")" suffixOverrides=","> | 119 | <trim prefix="values (" suffix=")" suffixOverrides=","> |
116 | <if test="id != null">#{id},</if> | 120 | <if test="id != null">#{id},</if> |
@@ -141,6 +145,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -141,6 +145,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
141 | <if test="updateTime != null">#{updateTime},</if> | 145 | <if test="updateTime != null">#{updateTime},</if> |
142 | <if test="updateBy != null and updateBy != ''">#{updateBy},</if> | 146 | <if test="updateBy != null and updateBy != ''">#{updateBy},</if> |
143 | <if test="defFlag != null and defFlag != ''">#{defFlag},</if> | 147 | <if test="defFlag != null and defFlag != ''">#{defFlag},</if> |
148 | + <if test="statusCode != null">#{statusCode},</if> | ||
149 | + <if test="statusName != null">#{statusName},</if> | ||
144 | </trim> | 150 | </trim> |
145 | </insert> | 151 | </insert> |
146 | 152 | ||
@@ -174,6 +180,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -174,6 +180,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
174 | <if test="updateTime != null">update_time = #{updateTime},</if> | 180 | <if test="updateTime != null">update_time = #{updateTime},</if> |
175 | <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if> | 181 | <if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if> |
176 | <if test="defFlag != null and defFlag != ''">def_flag = #{defFlag},</if> | 182 | <if test="defFlag != null and defFlag != ''">def_flag = #{defFlag},</if> |
183 | + <if test="statusCode != null">status_code = #{statusCode},</if> | ||
184 | + <if test="statusName != null">status_name = #{statusName},</if> | ||
177 | </trim> | 185 | </trim> |
178 | where id = #{id} | 186 | where id = #{id} |
179 | </update> | 187 | </update> |
@@ -193,15 +201,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | @@ -193,15 +201,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" | ||
193 | <select id="selectMcIgnitionParamList" parameterType="com.chinagas.modules.schsf.domain.McIgnition" resultMap="McIgnitionResult"> | 201 | <select id="selectMcIgnitionParamList" parameterType="com.chinagas.modules.schsf.domain.McIgnition" resultMap="McIgnitionResult"> |
194 | <include refid="selectMcIgnitionVo"/> | 202 | <include refid="selectMcIgnitionVo"/> |
195 | where 1=1 | 203 | where 1=1 |
196 | - and region_name = #{regionName} | ||
197 | - and group_name = #{groupName} | ||
198 | - and company_name = #{companyName} | ||
199 | - and company_code = #{companyCode} | ||
200 | - and user_province = #{userProvince} | ||
201 | - and user_city = #{userCity} | ||
202 | - and user_district = #{userDistrict} | ||
203 | - and user_street = #{userStreet} | ||
204 | - and vlg_or_cmty = #{vlgOrCmty} | 204 | + and t.def_flag ='0' |
205 | + and t.region_name = #{regionName} | ||
206 | + and t.group_name = #{groupName} | ||
207 | + and t.company_name = #{companyName} | ||
208 | + and t.company_code = #{companyCode} | ||
209 | + and t.user_province = #{userProvince} | ||
210 | + and t.user_city = #{userCity} | ||
211 | + and t.user_district = #{userDistrict} | ||
212 | + and t.user_street = #{userStreet} | ||
213 | + and t.vlg_or_cmty = #{vlgOrCmty} | ||
205 | </select> | 214 | </select> |
206 | 215 | ||
207 | </mapper> | 216 | </mapper> |