1
This commit is contained in:
273
mosty-yszx/mosty-yszx.iml
Normal file
273
mosty-yszx/mosty-yszx.iml
Normal file
@ -0,0 +1,273 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module org.jetbrains.idea.maven.project.MavenProjectsManager.isMavenModule="true" type="JAVA_MODULE" version="4">
|
||||
<component name="FacetManager">
|
||||
<facet type="Spring" name="Spring">
|
||||
<configuration />
|
||||
</facet>
|
||||
<facet type="web" name="Web">
|
||||
<configuration>
|
||||
<webroots />
|
||||
</configuration>
|
||||
</facet>
|
||||
<facet type="JRebel" name="JRebel">
|
||||
<configuration>
|
||||
<option name="ideModuleStorage">
|
||||
<map>
|
||||
<entry key="com.zeroturnaround.jrebel.FormatVersion" value="7.0.0" />
|
||||
<entry key="com.zeroturnaround.jrebel.remoting.DeleteUnindexedFiles" value="false" />
|
||||
<entry key="com.zeroturnaround.jrebel.remoting.ModuleRemoteServerSelection" value="off" />
|
||||
<entry key="jrebelEnabled" value="true" />
|
||||
<entry key="lastExternalPluginCheckTime" value="1721024353927" />
|
||||
</map>
|
||||
</option>
|
||||
<option name="version" value="2" />
|
||||
</configuration>
|
||||
</facet>
|
||||
</component>
|
||||
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_8">
|
||||
<output url="file://$MODULE_DIR$/target/classes" />
|
||||
<output-test url="file://$MODULE_DIR$/target/test-classes" />
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/target" />
|
||||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-context:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-aop:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-expression:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-autoconfigure:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-logging:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: ch.qos.logback:logback-classic:1.2.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.logging.log4j:log4j-to-slf4j:2.12.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.logging.log4j:log4j-api:2.13.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.slf4j:jul-to-slf4j:1.7.30" level="project" />
|
||||
<orderEntry type="library" name="Maven: jakarta.annotation:jakarta.annotation-api:1.3.5" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-core:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-jcl:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.yaml:snakeyaml:1.25" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-test:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-test:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-test-autoconfigure:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.jayway.jsonpath:json-path:2.4.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: net.minidev:json-smart:2.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: net.minidev:accessors-smart:1.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.ow2.asm:asm:5.0.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.slf4j:slf4j-api:1.7.30" level="project" />
|
||||
<orderEntry type="library" name="Maven: jakarta.xml.bind:jakarta.xml.bind-api:2.3.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: jakarta.activation:jakarta.activation-api:1.2.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.junit.jupiter:junit-jupiter:5.6.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.junit.jupiter:junit-jupiter-api:5.6.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.opentest4j:opentest4j:1.2.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.junit.platform:junit-platform-commons:1.6.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.junit.jupiter:junit-jupiter-params:5.6.2" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: org.junit.jupiter:junit-jupiter-engine:5.6.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.junit.vintage:junit-vintage-engine:5.6.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apiguardian:apiguardian-api:1.1.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.junit.platform:junit-platform-engine:1.6.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: junit:junit:4.12" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mockito:mockito-junit-jupiter:3.1.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.assertj:assertj-core:3.13.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.hamcrest:hamcrest:2.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mockito:mockito-core:3.1.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: net.bytebuddy:byte-buddy:1.10.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: net.bytebuddy:byte-buddy-agent:1.10.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.objenesis:objenesis:2.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.skyscreamer:jsonassert:1.5.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.vaadin.external.google:android-json:0.0.20131108.vaadin1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-test:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.xmlunit:xmlunit-core:2.6.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-starter:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-context:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.security:spring-security-crypto:5.3.3.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-commons:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.security:spring-security-rsa:1.0.9.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.bouncycastle:bcpkix-jdk15on:1.64" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.bouncycastle:bcprov-jdk15on:1.64" level="project" />
|
||||
<orderEntry type="library" name="Maven: mysql:mysql-connector-java:8.0.16" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba.cloud:spring-cloud-starter-alibaba-nacos-discovery:2.0.3.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba.nacos:nacos-client:1.3.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba.nacos:nacos-common:1.3.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-io:commons-io:2.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpasyncclient:4.1.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpcore-nio:4.4.13" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba.nacos:nacos-api:1.3.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.google.guava:guava:29.0-jre" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.google.guava:failureaccess:1.0.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.google.code.findbugs:jsr305:3.0.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.checkerframework:checker-qual:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.google.errorprone:error_prone_annotations:2.3.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.google.j2objc:j2objc-annotations:1.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-codec:commons-codec:1.13" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-core:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-databind:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml.jackson.core:jackson-annotations:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.prometheus:simpleclient:0.5.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba.spring:spring-context-support:1.0.10" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-starter-netflix-ribbon:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-netflix-ribbon:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-netflix-archaius:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-starter-netflix-archaius:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-configuration:commons-configuration:1.8" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.ribbon:ribbon:2.3.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.netflix.ribbon:ribbon-transport:2.3.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: io.reactivex:rxnetty-contexts:0.4.9" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: io.reactivex:rxnetty-servo:0.4.9" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: javax.inject:javax.inject:1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: io.reactivex:rxnetty:0.4.9" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.ribbon:ribbon-core:2.3.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-lang:commons-lang:2.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.ribbon:ribbon-httpclient:2.3.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-collections:commons-collections:3.2.2" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.sun.jersey:jersey-client:1.19.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.sun.jersey:jersey-core:1.19.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: javax.ws.rs:jsr311-api:1.1.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.sun.jersey.contribs:jersey-apache-client4:1.19.1" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.netflix.servo:servo-core:0.12.21" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.netflix.netflix-commons:netflix-commons-util:0.3.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.ribbon:ribbon-loadbalancer:2.3.0" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.netflix.netflix-commons:netflix-statistics:0.1.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.reactivex:rxjava:1.3.8" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-starter-openfeign:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.cloud:spring-cloud-openfeign-core:2.2.5.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-aop:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.aspectj:aspectjweaver:1.9.5" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.github.openfeign.form:feign-form-spring:3.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.github.openfeign.form:feign-form:3.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-fileupload:commons-fileupload:1.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-web:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-beans:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.github.openfeign:feign-core:10.10.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.github.openfeign:feign-slf4j:10.10.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.github.openfeign:feign-hystrix:10.10.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.archaius:archaius-core:0.7.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.hystrix:hystrix-core:1.5.18" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.hdrhistogram:HdrHistogram:2.1.9" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.vividsolutions:jts:1.13" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:common-magic-api-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:common-base-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.velocity:velocity-engine-core:2.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-swagger2:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.swagger:swagger-annotations:1.5.14" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.swagger:swagger-models:1.5.14" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-spi:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-core:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-schema:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-swagger-common:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-spring-web:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.reflections:reflections:0.9.11" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.javassist:javassist:3.21.0-GA" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml:classmate:1.5.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.plugin:spring-plugin-core:1.2.0.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.plugin:spring-plugin-metadata:1.2.0.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mapstruct:mapstruct:1.2.0.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.springfox:springfox-swagger-ui:2.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.github.caspar-chen:swagger-ui-layer:1.1.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-web:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-json:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jdk8:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml.jackson.datatype:jackson-datatype-jsr310:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.fasterxml.jackson.module:jackson-module-parameter-names:2.11.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-tomcat:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-core:9.0.30" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-websocket:9.0.30" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-webmvc:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: cn.hutool:hutool-all:5.7.20" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.belerweb:pinyin4j:2.5.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba:fastjson:1.2.83" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.commons:commons-lang3:3.9" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.projectlombok:lombok:1.18.10" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.github.pagehelper:pagehelper:5.3.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.github.jsqlparser:jsqlparser:4.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: jakarta.validation:jakarta.validation-api:2.0.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-boot-starter:3.4.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.baomidou:mybatis-plus:3.4.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-jdbc:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.zaxxer:HikariCP:3.4.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-extension:3.4.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-core:3.4.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.baomidou:mybatis-plus-annotation:3.4.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mybatis:mybatis:3.5.7" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mybatis:mybatis-spring:2.0.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.poi:poi-ooxml:4.1.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.poi:poi-ooxml-schemas:4.1.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.xmlbeans:xmlbeans:3.1.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.commons:commons-compress:1.19" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.github.virtuald:curvesapi:1.06" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.poi:poi:4.1.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.commons:commons-collections4:4.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.commons:commons-math3:3.6.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.zaxxer:SparseBitSet:1.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.ssssssss:magic-api-spring-boot-starter:2.0.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.ssssssss:magic-api:2.0.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-websocket:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-messaging:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-websocket:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-jdbc:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.commons:commons-text:1.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-beanutils:commons-beanutils:1.9.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: commons-logging:commons-logging:1.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.ssssssss:magic-script:1.8.5" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.ssssssss:magic-editor:2.0.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.ssssssss:magic-api-plugin-swagger:2.0.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:common-token-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.alibaba:transmittable-thread-local:2.11.5" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.auth0:java-jwt:3.8.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:common-redis-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-data-redis:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.data:spring-data-redis:2.3.2.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.data:spring-data-keyvalue:2.3.2.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.data:spring-data-commons:2.3.2.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-tx:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-oxm:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework:spring-context-support:5.2.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.lettuce:lettuce-core:5.2.1.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.netty:netty-common:4.1.51.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.netty:netty-handler:4.1.51.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.netty:netty-resolver:4.1.51.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.netty:netty-buffer:4.1.51.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.netty:netty-codec:4.1.51.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.netty:netty-transport:4.1.51.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.projectreactor:reactor-core:3.3.8.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.reactivestreams:reactive-streams:1.0.3" level="project" />
|
||||
<orderEntry type="module" module-name="mosty-base-feign-sdk" />
|
||||
<orderEntry type="library" name="Maven: com.netflix.feign:feign-slf4j:8.14.4" level="project" />
|
||||
<orderEntry type="library" scope="RUNTIME" name="Maven: com.netflix.feign:feign-core:8.14.4" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:common-core-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:common-config-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mybatis.spring.boot:mybatis-spring-boot-starter:2.2.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.mybatis.spring.boot:mybatis-spring-boot-autoconfigure:2.2.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-core:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-lang:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-cache:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-hash:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-core:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-crypto-cipher:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-config-core:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-config-ogdl:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-event:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.shiro:shiro-ehcache:1.8.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: net.sf.ehcache:ehcache-core:2.6.11" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.springframework.boot:spring-boot-starter-validation:2.2.4.RELEASE" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.tomcat.embed:tomcat-embed-el:9.0.30" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.hibernate.validator:hibernate-validator:6.0.18.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.jboss.logging:jboss-logging:3.4.1.Final" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.github.penggle:kaptcha:2.3.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: javax.servlet:javax.servlet-api:4.0.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.jhlabs:filters:2.0.235-1" level="project" />
|
||||
<orderEntry type="library" name="Maven: io.minio:minio:8.0.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.carrotsearch.thirdparty:simple-xml-safe:2.7.1" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.squareup.okhttp3:okhttp:3.14.6" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.squareup.okio:okio:1.17.2" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpclient:4.5.10" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.apache.httpcomponents:httpcore:4.4.13" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.hikvision.ga:artemis-http-client:1.1.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: ch.qos.logback:logback-core:1.2.3" level="project" />
|
||||
<orderEntry type="library" name="Maven: org.locationtech.jts:jts-core:1.18.0" level="project" />
|
||||
<orderEntry type="library" name="Maven: com.mosty:operation-log-aspect-starter:1.0.0-SNAPSHOT" level="project" />
|
||||
</component>
|
||||
</module>
|
120
mosty-yszx/pom.xml
Normal file
120
mosty-yszx/pom.xml
Normal file
@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<parent>
|
||||
<artifactId>mosty-dyga-cloud</artifactId>
|
||||
<groupId>com.mosty</groupId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<artifactId>mosty-yszx</artifactId>
|
||||
<description>要素中心</description>
|
||||
|
||||
<properties>
|
||||
<maven.compiler.source>8</maven.compiler.source>
|
||||
<maven.compiler.target>8</maven.compiler.target>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>mysql</groupId>
|
||||
<artifactId>mysql-connector-java</artifactId>
|
||||
<version>8.0.16</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.alibaba.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
|
||||
<version>2.0.3.RELEASE</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springframework.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-openfeign</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.vividsolutions</groupId>
|
||||
<artifactId>jts</artifactId>
|
||||
<version>1.13</version>
|
||||
</dependency>
|
||||
|
||||
<!--magicAPI-->
|
||||
<dependency>
|
||||
<groupId>com.mosty</groupId>
|
||||
<artifactId>common-magic-api-starter</artifactId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<!--登录jar包-->
|
||||
<dependency>
|
||||
<groupId>com.mosty</groupId>
|
||||
<artifactId>common-token-starter</artifactId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<!--redis包-->
|
||||
<dependency>
|
||||
<groupId>com.mosty</groupId>
|
||||
<artifactId>common-redis-starter</artifactId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<!--base-feign-->
|
||||
<dependency>
|
||||
<groupId>com.mosty</groupId>
|
||||
<artifactId>mosty-base-feign-sdk</artifactId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
<!--日志包-->
|
||||
<dependency>
|
||||
<groupId>com.mosty</groupId>
|
||||
<artifactId>operation-log-aspect-starter</artifactId>
|
||||
<version>1.0.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>org.geotools</groupId>-->
|
||||
<!-- <artifactId>gt-shapefile</artifactId>-->
|
||||
<!-- <version>24-SNAPSHOT</version>-->
|
||||
<!-- </dependency>-->
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>org.geotools</groupId>-->
|
||||
<!-- <artifactId>gt-swing</artifactId>-->
|
||||
<!-- <version>24-SNAPSHOT</version>-->
|
||||
<!-- </dependency>-->
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<!-- 这个插件,可以将应用打包成一个可执行的jar包;-->
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
</plugin>
|
||||
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<configuration>
|
||||
<source>8</source>
|
||||
<target>8</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
@ -0,0 +1,29 @@
|
||||
package com.mosty.yszx;
|
||||
|
||||
import com.mosty.common.base.timeconsume.EnableTimeConsume;
|
||||
import org.mybatis.spring.annotation.MapperScan;
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
|
||||
import org.springframework.cloud.openfeign.EnableFeignClients;
|
||||
|
||||
/**
|
||||
* 要素中心 微服务
|
||||
* @author zengbo
|
||||
* @date 2022/7/11 19:43 PM[
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@EnableTimeConsume
|
||||
//@ComponentScan("com.mosty")
|
||||
@EnableFeignClients(basePackages = "com.mosty.base.feign.service")
|
||||
@MapperScan("com.mosty.yszx.mapper")
|
||||
@EnableDiscoveryClient
|
||||
@SpringBootApplication
|
||||
public class MostyYszxApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
||||
SpringApplication.run(MostyYszxApplication.class, args);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package com.mosty.yszx.config;
|
||||
|
||||
import feign.RequestInterceptor;
|
||||
import feign.RequestTemplate;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.web.context.request.RequestContextHolder;
|
||||
import org.springframework.web.context.request.ServletRequestAttributes;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
|
||||
@Configuration
|
||||
public class FeignConfig implements RequestInterceptor {
|
||||
|
||||
@Override
|
||||
public void apply(RequestTemplate requestTemplate) {
|
||||
ServletRequestAttributes attr = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
|
||||
if (attr != null) {
|
||||
HttpServletRequest request = attr.getRequest();
|
||||
// 添加token
|
||||
requestTemplate.header("Authorization", request.getHeader("Authorization"));
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package com.mosty.yszx.config;
|
||||
|
||||
import lombok.Data;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 全局配置
|
||||
* @author kevin
|
||||
* @date 2022/5/25 1:56 上午
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@Data
|
||||
@Configuration
|
||||
@ConfigurationProperties("exclude.path-patterns")
|
||||
public class GlobalYmlConfig {
|
||||
|
||||
/**
|
||||
* swagger 静态文件的放行列表
|
||||
*/
|
||||
private List<String> swagger;
|
||||
|
||||
}
|
120
mosty-yszx/src/main/java/com/mosty/yszx/config/WebMvcConfig.java
Normal file
120
mosty-yszx/src/main/java/com/mosty/yszx/config/WebMvcConfig.java
Normal file
@ -0,0 +1,120 @@
|
||||
package com.mosty.yszx.config;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.fasterxml.jackson.core.JsonGenerator;
|
||||
import com.fasterxml.jackson.databind.DeserializationFeature;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.fasterxml.jackson.databind.SerializationFeature;
|
||||
import com.fasterxml.jackson.databind.module.SimpleModule;
|
||||
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateDeserializer;
|
||||
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
|
||||
import com.fasterxml.jackson.datatype.jsr310.deser.LocalTimeDeserializer;
|
||||
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateSerializer;
|
||||
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
|
||||
import com.fasterxml.jackson.datatype.jsr310.ser.LocalTimeSerializer;
|
||||
import com.mosty.common.token.SysUserInterceptor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.InitializingBean;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.http.MediaType;
|
||||
import org.springframework.http.converter.HttpMessageConverter;
|
||||
import org.springframework.http.converter.json.MappingJackson2HttpMessageConverter;
|
||||
import org.springframework.web.servlet.config.annotation.*;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.LocalTime;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 单体服务拦截器
|
||||
* @author kevin
|
||||
* @date 2022/3/21 11:17 PM
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@Configuration
|
||||
@Slf4j
|
||||
public class WebMvcConfig implements WebMvcConfigurer, InitializingBean {
|
||||
|
||||
private static final String DEFAULT_TIME_FORMAT = "HH:mm:ss";
|
||||
private static final String DEFAULT_DATE_FORMAT = "yyyy-MM-dd";
|
||||
private static final String DEFAULT_DATE_TIME_FORMAT = "yyyy-MM-dd HH:mm:ss";
|
||||
|
||||
@Value("${server.servlet.context-path:/}")
|
||||
private String contextPath;
|
||||
|
||||
@Autowired
|
||||
private GlobalYmlConfig globalYmlConfig;
|
||||
|
||||
@Override
|
||||
public void extendMessageConverters(List<HttpMessageConverter<?>> converters) {
|
||||
MappingJackson2HttpMessageConverter converter = new MappingJackson2HttpMessageConverter();
|
||||
ObjectMapper objectMapper = converter.getObjectMapper();
|
||||
// 生成JSON时,将所有Long转换成String
|
||||
SimpleModule simpleModule = new SimpleModule();
|
||||
//日期格式化
|
||||
simpleModule.addSerializer(LocalDateTime.class, new LocalDateTimeSerializer(DateTimeFormatter.ofPattern(DEFAULT_DATE_TIME_FORMAT)));
|
||||
simpleModule.addSerializer(LocalDate.class, new LocalDateSerializer(DateTimeFormatter.ofPattern(DEFAULT_DATE_FORMAT)));
|
||||
simpleModule.addSerializer(LocalTime.class, new LocalTimeSerializer(DateTimeFormatter.ofPattern(DEFAULT_TIME_FORMAT)));
|
||||
simpleModule.addDeserializer(LocalDateTime.class, new LocalDateTimeDeserializer(DateTimeFormatter.ofPattern(DEFAULT_DATE_TIME_FORMAT)));
|
||||
simpleModule.addDeserializer(LocalDate.class, new LocalDateDeserializer(DateTimeFormatter.ofPattern(DEFAULT_DATE_FORMAT)));
|
||||
simpleModule.addDeserializer(LocalTime.class, new LocalTimeDeserializer(DateTimeFormatter.ofPattern(DEFAULT_TIME_FORMAT)));
|
||||
objectMapper.registerModule(simpleModule);
|
||||
// 时间格式化
|
||||
objectMapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
|
||||
objectMapper.configure(JsonGenerator.Feature.WRITE_BIGDECIMAL_AS_PLAIN, true);
|
||||
objectMapper.configure(JsonGenerator.Feature.IGNORE_UNKNOWN, true);
|
||||
objectMapper.setDateFormat(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"));
|
||||
objectMapper.disable(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS);
|
||||
// 设置格式化内容
|
||||
converter.setObjectMapper(objectMapper);
|
||||
converters.add(0, converter);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterPropertiesSet() throws Exception {
|
||||
log.info("当前服务的 contextPath={}", contextPath);
|
||||
log.info("当前服务的 swaggerExcludePathPatterns={}", JSON.toJSONString(globalYmlConfig.getSwagger()));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addViewControllers(ViewControllerRegistry registry) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void configureContentNegotiation(ContentNegotiationConfigurer configurer) {
|
||||
configurer.defaultContentType(MediaType.APPLICATION_JSON);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addInterceptors(InterceptorRegistry registry) {
|
||||
registry.addInterceptor(userInfoInterceptor()).addPathPatterns("/**")
|
||||
.excludePathPatterns(globalYmlConfig.getSwagger());
|
||||
log.info("初始化WebMvcConfig 监控拦截器SysUserInterceptor");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addResourceHandlers(ResourceHandlerRegistry registry) {
|
||||
if (!registry.hasMappingForPattern("/template/**")) {
|
||||
registry.addResourceHandler("/template/**").addResourceLocations("classpath:/template/");
|
||||
}
|
||||
registry.addResourceHandler("swagger-ui.html")
|
||||
.addResourceLocations("classpath:/META-INF/resources/");
|
||||
registry.addResourceHandler("docs.html")
|
||||
.addResourceLocations("classpath:/META-INF/resources/");
|
||||
registry.addResourceHandler("/webjars/**")
|
||||
.addResourceLocations("classpath:/META-INF/resources/webjars/");
|
||||
WebMvcConfigurer.super.addResourceHandlers(registry);
|
||||
}
|
||||
|
||||
@Bean
|
||||
public SysUserInterceptor userInfoInterceptor() {
|
||||
log.info("初始化WebMvcConfig 拦截器SysUserInterceptor");
|
||||
return new SysUserInterceptor();
|
||||
}
|
||||
}
|
@ -0,0 +1,96 @@
|
||||
package com.mosty.yszx.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.entity.log.BusinessType;
|
||||
import com.mosty.common.base.entity.log.Log;
|
||||
import com.mosty.common.token.JwtSysUser;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDelDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDto;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsAjVo;
|
||||
import com.mosty.yszx.service.TbYsAjService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/18
|
||||
* 要素中心-案件接口
|
||||
**/
|
||||
@Api(tags = "要素中心-案件接口")
|
||||
@RestController
|
||||
@AllArgsConstructor
|
||||
@RequestMapping("/tbYsAj")
|
||||
public class TbYsAjController {
|
||||
|
||||
private final TbYsAjService tbYsAjService;
|
||||
|
||||
@ApiOperation("案件新增")
|
||||
@JwtSysUser
|
||||
@Log(title = "案件新增", businessType = BusinessType.INSERT)
|
||||
@PostMapping("addAj")
|
||||
public ResponseResult<Void> addAj(@RequestBody TbYsAjDto dto) {
|
||||
this.tbYsAjService.addAj(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("案件修改")
|
||||
@JwtSysUser
|
||||
@Log(title = "案件修改", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("updateAj")
|
||||
public ResponseResult<Void> updateAj(@RequestBody TbYsAjDto dto) {
|
||||
this.tbYsAjService.updateAj(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("案件查询-分页")
|
||||
@JwtSysUser
|
||||
@GetMapping("getPageList")
|
||||
public ResponseResult<IPage<TbYsAjVo>> getPageList(TbYsAjQuery dto) {
|
||||
return ResponseResult.success(this.tbYsAjService.getPageList(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("案件查询-不分页")
|
||||
@JwtSysUser
|
||||
@GetMapping("getList")
|
||||
public ResponseResult<List<TbYsAjVo>> getList(TbYsAjNoPageQuery dto) {
|
||||
return ResponseResult.success(this.tbYsAjService.getList(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("删除案件信息")
|
||||
@JwtSysUser
|
||||
@DeleteMapping("delAj")
|
||||
public ResponseResult<Void> delAj(TbYsAjDelDto dto) {
|
||||
this.tbYsAjService.delAj(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("获取案件信息的数据--热力图")
|
||||
@JwtSysUser
|
||||
@GetMapping("getAjHotMap")
|
||||
public ResponseResult<List<Map<String,Object>>> getAjHotMap(TbYsAjNoPageQuery dto) {
|
||||
return ResponseResult.success(this.tbYsAjService.getAjHotMap(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("查询案件案件详情")
|
||||
@JwtSysUser
|
||||
@GetMapping("getInfo")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "ID", required = true),
|
||||
@ApiImplicitParam(name = "ajfl", value = "--D_BB_AJLB(案件类别)案件分类:1-刑事案件,2-行政案件", required = true)
|
||||
})
|
||||
public ResponseResult<TbYsAjVo> getInfo(String id, String ajfl) {
|
||||
return ResponseResult.success(this.tbYsAjService.getInfo(id, ajfl));
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,95 @@
|
||||
package com.mosty.yszx.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlVo;
|
||||
import com.mosty.common.base.domain.BaseController;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.entity.log.BusinessType;
|
||||
import com.mosty.common.base.entity.log.Log;
|
||||
import com.mosty.common.token.JwtSysUser;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsDl;
|
||||
import com.mosty.yszx.service.TbYsDlService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/18
|
||||
* 要素中心-地理要素
|
||||
**/
|
||||
@Api(tags = "要素中心-地理要素")
|
||||
@RestController
|
||||
@AllArgsConstructor
|
||||
@RequestMapping("/tbYsDl")
|
||||
public class TbYsDlController extends BaseController {
|
||||
|
||||
@Resource
|
||||
private TbYsDlService tbYsDlService;
|
||||
|
||||
@RequestMapping(value = "/selectGeography", method = {RequestMethod.GET, RequestMethod.POST})
|
||||
@ApiOperation(value = "大屏-地图-地理要素(社会资源),pageNum参数不传则查询所有数据")
|
||||
@JwtSysUser
|
||||
public ResponseResult<IPage<TbYsDlVo>> queryAll(@RequestBody TbYsDlQuery dto) {
|
||||
return ResponseResult.success(this.tbYsDlService.queryAll(dto));
|
||||
}
|
||||
|
||||
@GetMapping("/selectByNr")
|
||||
@ApiOperation(value = "根据关键字查询地理要素")
|
||||
@JwtSysUser
|
||||
public ResponseResult<List<TbYsDlVo>> selectByNr(@RequestParam("keyword") String keyword) {
|
||||
return ResponseResult.success(this.tbYsDlService.selectByNr(keyword));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "通过主键查询单条数据")
|
||||
@GetMapping("{id}")
|
||||
public ResponseResult<TbYsDlVo> queryById(@PathVariable("id") String id) {
|
||||
return ResponseResult.success(this.tbYsDlService.queryById(id));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "新增地理要素数据")
|
||||
@PostMapping
|
||||
public ResponseResult<Void> add(@RequestBody TbYsDlDto dto) {
|
||||
this.tbYsDlService.insert(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation(value = "编辑地理要素数据")
|
||||
@PutMapping
|
||||
@Log(title = "编辑地理要素数据", businessType = BusinessType.INSERT)
|
||||
public ResponseResult<Void> edit(@RequestBody TbYsDlDto dto) {
|
||||
this.tbYsDlService.update(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation(value = "删除")
|
||||
@DeleteMapping("{id}")
|
||||
@Log(title = "删除地理要素数据", businessType = BusinessType.INSERT)
|
||||
public ResponseResult<Void> deleteById(@PathVariable("id") String id) {
|
||||
this.tbYsDlService.deleteById(id);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@PostMapping("/selectVideoServo")
|
||||
@ApiOperation(value = "大屏-巡组气泡框-视频随动")
|
||||
@JwtSysUser
|
||||
public ResponseResult<List<TbYsDl>> selectVideoServo(@RequestBody TbYsDl tbYsDl) {
|
||||
return ResponseResult.success(this.tbYsDlService.selectVideoServo(tbYsDl));
|
||||
}
|
||||
|
||||
@GetMapping("/selectDlys")
|
||||
@ApiOperation(value = "根据名称查询地理要素")
|
||||
@JwtSysUser
|
||||
public ResponseResult<TbYsDl> selectDlys(@RequestParam String ysmc) {
|
||||
return ResponseResult.success(this.tbYsDlService.selectDlys(ysmc));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,132 @@
|
||||
package com.mosty.yszx.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgAndGlbmDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgByJwdDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgGlbmDto;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgGlbmVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgVo;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.entity.log.BusinessType;
|
||||
import com.mosty.common.base.entity.log.Log;
|
||||
import com.mosty.common.core.business.entity.vo.Base64Str;
|
||||
import com.mosty.common.token.JwtSysUser;
|
||||
import com.mosty.yszx.service.TbYsGajgService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/18
|
||||
* 要素中心--公安机关要素
|
||||
**/
|
||||
@Api(tags = "要素中心--公安机关要素")
|
||||
@RestController
|
||||
@AllArgsConstructor
|
||||
@RequestMapping("/tbYsGajg")
|
||||
public class TbYsGajgController {
|
||||
|
||||
private final TbYsGajgService tbYsGajgService;
|
||||
|
||||
@ApiOperation("公安机关要素新增")
|
||||
@JwtSysUser
|
||||
@Log(title = "公安机关要素新增", businessType = BusinessType.INSERT)
|
||||
@PostMapping("add")
|
||||
public ResponseResult<Integer> insertEntity(@RequestBody TbYsGajgDto dto) {
|
||||
return ResponseResult.success(this.tbYsGajgService.insertEntity(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("公安机关要素新增--添加关联部门")
|
||||
@JwtSysUser
|
||||
@Log(title = "公安机关要素新增--添加关联部门", businessType = BusinessType.INSERT)
|
||||
@PostMapping("addGajg")
|
||||
public ResponseResult<Integer> addGajg(@RequestBody TbYsGajgAndGlbmDto dto) {
|
||||
return ResponseResult.success(this.tbYsGajgService.addGajg(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("公安机关要素修改--修改关联部门")
|
||||
@JwtSysUser
|
||||
@Log(title = "公安机关要素修改--修改关联部门", businessType = BusinessType.INSERT)
|
||||
@PostMapping("editGajg")
|
||||
public ResponseResult<Void> editGajg(@RequestBody TbYsGajgAndGlbmDto dto) {
|
||||
this.tbYsGajgService.editGajg(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("公安机关要素修改")
|
||||
@JwtSysUser
|
||||
@Log(title = "公安机关要素修改", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public ResponseResult<Void> updateEntity(@RequestBody TbYsGajgDto dto) {
|
||||
this.tbYsGajgService.updateEntity(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据来源id 和来源表名修改 公安机关要素")
|
||||
@JwtSysUser
|
||||
@Log(title = "根据来源id 和来源表名 修改 公安机关要素", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("update")
|
||||
public ResponseResult<Void> updateEntityByLY(@RequestBody TbYsGajgDto dto) {
|
||||
this.tbYsGajgService.updateEntityByLY(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("公安机关要素详情查询")
|
||||
@JwtSysUser
|
||||
@GetMapping("{id}")
|
||||
public ResponseResult<TbYsGajgVo> getInfo(@PathVariable("id") String id) {
|
||||
return ResponseResult.success(this.tbYsGajgService.getInfo(id));
|
||||
}
|
||||
|
||||
@ApiOperation("公安机关要素查询列表,pageNum参数不传查询所有列表")
|
||||
@JwtSysUser
|
||||
@PostMapping("getList")
|
||||
public ResponseResult<IPage<TbYsGajgVo>> getPageList(@RequestBody TbYsGajgQuery dto) {
|
||||
return ResponseResult.success(this.tbYsGajgService.getPageList(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("查询公安机关列表(包含关联部门ID)")
|
||||
@JwtSysUser
|
||||
@PostMapping("getGajgList")
|
||||
public ResponseResult<List<TbYsGajgGlbmVo>> getGajgList(@RequestBody TbYsGajgQuery dto) {
|
||||
return ResponseResult.success(this.tbYsGajgService.getGajgList(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("删除公安机关要素")
|
||||
@JwtSysUser
|
||||
@DeleteMapping("{id}")
|
||||
public ResponseResult<Void> delEntity(@PathVariable("id") String id) {
|
||||
this.tbYsGajgService.delEntity(id);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据来源id 和来源表名 删除公安机关要素")
|
||||
@JwtSysUser
|
||||
@Log(title = "根据来源id 和来源表名 删除公安机关要素", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping
|
||||
public ResponseResult<Void> delEntity(@RequestBody TbYsGajgDto dto) {
|
||||
this.tbYsGajgService.delEntity(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("根据经纬度判断所属公安机关")
|
||||
@JwtSysUser
|
||||
@PostMapping("getGajgByJwd")
|
||||
public ResponseResult<TbYsGajgVo> getGajgByJwd(@RequestBody TbYsGajgByJwdDto dto) {
|
||||
return ResponseResult.success(this.tbYsGajgService.getGajgByJwd(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("查询关联部门")
|
||||
@JwtSysUser
|
||||
@PostMapping("getGlbmList/{id}")
|
||||
public ResponseResult<List<TbYsGajgGlbmDto>> getGlbmList(@PathVariable("id") String id) {
|
||||
return ResponseResult.success(this.tbYsGajgService.getGlbmList(id));
|
||||
}
|
||||
}
|
@ -0,0 +1,77 @@
|
||||
package com.mosty.yszx.controller;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDelDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsRyDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRy;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjQuery;
|
||||
import com.mosty.base.model.vo.yszx.*;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.entity.log.BusinessType;
|
||||
import com.mosty.common.base.entity.log.Log;
|
||||
import com.mosty.common.token.JwtSysUser;
|
||||
import com.mosty.yszx.service.TbYsAjService;
|
||||
import com.mosty.yszx.service.TbYsRyService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/11/28
|
||||
* 要素中心-人员要素接口
|
||||
**/
|
||||
@Api(tags = "要素中心-人员要素接口")
|
||||
@RestController
|
||||
@AllArgsConstructor
|
||||
@RequestMapping("/tbYsRy")
|
||||
public class TbYsRyController {
|
||||
|
||||
private final TbYsRyService tbYsRyService;
|
||||
|
||||
@ApiOperation("查询人员详情")
|
||||
@JwtSysUser
|
||||
@GetMapping("getRyInfo")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "sfzh", value = "身份证号", required = true)
|
||||
})
|
||||
public ResponseResult<TbYsRyVo> getRyInfo(String sfzh) {
|
||||
return ResponseResult.success(this.tbYsRyService.getRyInfo(sfzh));
|
||||
}
|
||||
|
||||
@ApiOperation("添加人员要素")
|
||||
@PostMapping("addRyYs")
|
||||
public ResponseResult<TbYsRyVo> addRyYs(@RequestBody TbYsRyDto dto) {
|
||||
this.tbYsRyService.addRyYs(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("修改人员要素")
|
||||
@PostMapping("updateRyYs")
|
||||
public ResponseResult<TbYsRyVo> updateRyYs(@RequestBody TbYsRyDto dto) {
|
||||
this.tbYsRyService.updateRyYs(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("修改人员标签要素")
|
||||
@PostMapping("updateRyBqYs")
|
||||
public ResponseResult<Void> updateRyBqYs(@RequestBody TbYsRyBqUpdateDto dto) {
|
||||
this.tbYsRyService.updateRyBqYs(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("修改人员电话要素")
|
||||
@PostMapping("updateRyDhys")
|
||||
public ResponseResult<Void> updateRyDhys(@RequestBody TbYsRyDhUpdateDto dto) {
|
||||
this.tbYsRyService.updateRyDhys(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
}
|
@ -0,0 +1,221 @@
|
||||
package com.mosty.yszx.controller;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.hikvision.artemis.sdk.ArtemisHttpUtil;
|
||||
import com.mosty.base.model.entity.lzother.ZhjmxfXfqwXfqyGzdw;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtPageOneQuery;
|
||||
import com.mosty.base.utils.CameraPreviewUtil;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.entity.log.BusinessType;
|
||||
import com.mosty.common.base.entity.log.Log;
|
||||
import com.mosty.common.token.JwtSysUser;
|
||||
import com.mosty.base.model.dto.yszx.TbYsSxtDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsSxt;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtQuery;
|
||||
import com.mosty.yszx.service.TbYsSxtService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.data.redis.core.RedisTemplate;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/18
|
||||
* 要素中心-摄像头接口
|
||||
**/
|
||||
@Api(tags = "要素中心-摄像头接口")
|
||||
@RestController
|
||||
@AllArgsConstructor
|
||||
@RequestMapping("/tbYsSxt")
|
||||
public class TbYsSxtController {
|
||||
|
||||
private final TbYsSxtService tbYsSxtService;
|
||||
|
||||
@ApiOperation("摄像头新增")
|
||||
@Log(title = "摄像头新增", businessType = BusinessType.INSERT)
|
||||
@PostMapping("add")
|
||||
public ResponseResult<Integer> insertEntity(@RequestBody TbYsSxtDto dto) {
|
||||
return ResponseResult.success(this.tbYsSxtService.insertEntity(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("摄像头修改")
|
||||
@JwtSysUser
|
||||
@Log(title = "摄像头修改", businessType = BusinessType.UPDATE)
|
||||
@PutMapping("update")
|
||||
public ResponseResult<Void> updateEntity(@RequestBody TbYsSxtDto dto) {
|
||||
this.tbYsSxtService.updateEntity(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("查询摄像头列表--分页")
|
||||
@JwtSysUser
|
||||
@GetMapping("getPageList")
|
||||
public ResponseResult<IPage<TbYsSxt>> getPageList(TbYsSxtQuery dto) {
|
||||
return ResponseResult.success(this.tbYsSxtService.getPageList(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("查询摄像头列表--不分页")
|
||||
@JwtSysUser
|
||||
@GetMapping("getList")
|
||||
public ResponseResult<List<TbYsSxt>> getList(TbYsSxtNoPageQuery dto) {
|
||||
return ResponseResult.success(this.tbYsSxtService.getList(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("查询摄像头详情")
|
||||
@JwtSysUser
|
||||
@GetMapping("{id}")
|
||||
public ResponseResult<TbYsSxt> getList(@PathVariable("id") String id) {
|
||||
return ResponseResult.success(this.tbYsSxtService.getInfo(id));
|
||||
}
|
||||
|
||||
@ApiOperation("根据设备编号查询摄像头详情")
|
||||
@JwtSysUser
|
||||
@GetMapping("getInfoBySbbh/{sbbh}")
|
||||
public ResponseResult<TbYsSxtDto> getInfoBySbbh(@PathVariable("sbbh") String sbbh) {
|
||||
return ResponseResult.success(this.tbYsSxtService.getInfoBySbbh(sbbh));
|
||||
}
|
||||
|
||||
@ApiOperation("删除摄像头信息")
|
||||
@JwtSysUser
|
||||
@DeleteMapping("{id}")
|
||||
public ResponseResult<TbYsSxt> delEntity(@PathVariable("id") String id) {
|
||||
this.tbYsSxtService.delEntity(id);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("查询摄像头-事件中心")
|
||||
@JwtSysUser
|
||||
@Log(title = "查询摄像头-事件中心", businessType = BusinessType.OTHER)
|
||||
@GetMapping("getSjList")
|
||||
public ResponseResult<List<TbYsSxt>> getSjList(String jd, String wd, String sjid) {
|
||||
return ResponseResult.success(this.tbYsSxtService.getSjList(jd, wd, sjid));
|
||||
}
|
||||
|
||||
@ApiOperation("获取所有的感知源的设备编号")
|
||||
@JwtSysUser
|
||||
@PostMapping("getSxtBhList")
|
||||
public ResponseResult<List<String>> getSxtBhList(@RequestBody List<String> ids) {
|
||||
return ResponseResult.success(this.tbYsSxtService.getSxtBhList(ids));
|
||||
}
|
||||
|
||||
@ApiOperation("添加泸州感知源数据")
|
||||
@JwtSysUser
|
||||
@PostMapping("addLzGzy")
|
||||
public ResponseResult<Void> addLzGzy(@RequestBody ZhjmxfXfqwXfqyGzdw dto) {
|
||||
this.tbYsSxtService.addLzGzy(dto);
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
@ApiOperation("查询感知源信息")
|
||||
@JwtSysUser
|
||||
@PostMapping("selectGzy")
|
||||
public ResponseResult<TbYsSxtDto> selectGzy(@RequestBody TbYsSxtPageOneQuery dto) {
|
||||
return ResponseResult.success(this.tbYsSxtService.selectGzy(dto));
|
||||
}
|
||||
|
||||
@ApiOperation("摄像头更新经纬度")
|
||||
@JwtSysUser
|
||||
@GetMapping("updateJwd")
|
||||
public ResponseResult<Void> updateJwd() {
|
||||
this.tbYsSxtService.updateJwd();
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ApiOperation("更新泸州感知源数据")
|
||||
@Log(title = "更新泸州感知源数据", businessType = BusinessType.OTHER)
|
||||
@GetMapping("updateLzGzy")
|
||||
@JwtSysUser
|
||||
public ResponseResult<String> updateLzGzy() {
|
||||
this.tbYsSxtService.updateLzGzy();
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation("获取HLS地址")
|
||||
@Log(title = "查询HLS地址", businessType = BusinessType.OTHER)
|
||||
@GetMapping("previewURLs")
|
||||
@JwtSysUser
|
||||
@ApiImplicitParams({@ApiImplicitParam(name = "sbbh", value = "设备编号", dataType = "String"),
|
||||
@ApiImplicitParam(name = "protocol", value = "协议类型( 0-udp,1-tcp),默认为tcp,在protocol设置为rtsp或者rtmp时有效", dataType = "String"),
|
||||
})
|
||||
public ResponseResult<String> previewURLs(String sbbh,String protocol) {
|
||||
if(StringUtils.isBlank(protocol)){
|
||||
protocol = "hls";
|
||||
}
|
||||
String getCamsApi = "/api/video/v1/cameras/previewURLs";
|
||||
String result = "";
|
||||
JSONObject jsonBody = new JSONObject();
|
||||
jsonBody.put("cameraIndexCode", sbbh);
|
||||
jsonBody.put("streamType", 0);
|
||||
jsonBody.put("protocol", protocol);
|
||||
jsonBody.put("transmode", 0);
|
||||
jsonBody.put("expand", "transcode=0");
|
||||
result = CameraPreviewUtil.getCameraPreviewURL(getCamsApi, jsonBody);
|
||||
return ResponseResult.success(result);
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation("获取监控点回放取流URL")
|
||||
@Log(title = "获取监控点回放取流URL", businessType = BusinessType.OTHER)
|
||||
@PatchMapping("playbackURLs")
|
||||
@JwtSysUser
|
||||
@ApiImplicitParams({@ApiImplicitParam(name = "sbbh", value = "设备编号", dataType = "String"),
|
||||
@ApiImplicitParam(name = "beginTime", value = "开始查询时间(ISO8601格式yyyy-MM-dd'T'HH:mm:ss.SSSzzz,和结束时间相差不超过三天)", dataType = "String"),
|
||||
@ApiImplicitParam(name = "endTime", value = "结束查询时间(ISO8601格式yyyy-MM-dd'T'HH:mm:ss.SSSzzz,和开始时间相差不超过三天)", dataType = "String"),
|
||||
@ApiImplicitParam(name = "protocol", value = "协议类型( 0-udp,1-tcp),默认为tcp,在protocol设置为rtsp或者rtmp时有效", dataType = "String"),
|
||||
})
|
||||
public ResponseResult<String> playbackURLs(String sbbh,String beginTime,String endTime,String protocol) {
|
||||
if(StringUtils.isBlank(protocol)){
|
||||
protocol = "hls";
|
||||
}
|
||||
String getCamsApi = "/api/video/v1/cameras/playbackURLs";
|
||||
String result = "";
|
||||
JSONObject jsonBody = new JSONObject();
|
||||
jsonBody.put("cameraIndexCode", sbbh);
|
||||
jsonBody.put("beginTime",beginTime+"+08:00");
|
||||
jsonBody.put("endTime",endTime+"+08:00");
|
||||
jsonBody.put("recordLocation", 0);
|
||||
jsonBody.put("protocol", protocol);
|
||||
jsonBody.put("needReturnClipInfo", true);
|
||||
jsonBody.put("expand", "transcode=0");
|
||||
result = CameraPreviewUtil.getCameraPreviewURL(getCamsApi, jsonBody);
|
||||
return ResponseResult.success(result);
|
||||
}
|
||||
|
||||
@ApiOperation("根据监控点编号进行云台操作")
|
||||
@Log(title = "根据监控点编号进行云台操作", businessType = BusinessType.OTHER)
|
||||
@PatchMapping("controlling")
|
||||
@JwtSysUser
|
||||
@ApiImplicitParams({@ApiImplicitParam(name = "sbbh", value = "设备编号", dataType = "String"),
|
||||
@ApiImplicitParam(name = "action", value = "开始或停止操作(0 开始 1 停止)", dataType = "Integer"),
|
||||
@ApiImplicitParam(name = "command", value = "控制命令(不区分大小写) 说明: LEFT 左转 RIGHT 右转 UP 上转 DOWN 下转 ZOOM_IN 焦距变大 ZOOM_OUT 焦距变小 LEFT_UP 左上 LEFT_DOWN 左下 RIGHT_UP 右上 RIGHT_DOWN 右下 FOCUS_NEAR 焦点前移 FOCUS_FAR 焦点后移 IRIS_ENLARGE 光圈扩大 IRIS_REDUCE 光圈缩小 以下命令presetIndex不可为空: GOTO_PRESET到预置点", dataType = "String"),
|
||||
@ApiImplicitParam(name = "speed", value = "云台速度(取值范围1-100,默认40)", dataType = "Integer"),
|
||||
@ApiImplicitParam(name = "presetIndex", value = "预置点编号(取值范围为1-128)", dataType = "Integer"),
|
||||
})
|
||||
public ResponseResult<String> controlling(String sbbh,Integer action,String command,Integer speed,Integer presetIndex) {
|
||||
String getCamsApi = "/api/video/v1/ptzs/controlling";
|
||||
String result = "";
|
||||
JSONObject jsonBody = new JSONObject();
|
||||
jsonBody.put("cameraIndexCode", sbbh);
|
||||
jsonBody.put("action", action);
|
||||
jsonBody.put("command", command);
|
||||
jsonBody.put("speed", speed);
|
||||
jsonBody.put("presetIndex", presetIndex);
|
||||
result = CameraPreviewUtil.getCameraPreviewURL(getCamsApi, jsonBody);
|
||||
return ResponseResult.success(result);
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsDl;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 要素-地理要素表(TbYsDl)表数据库访问层
|
||||
*
|
||||
* @author zhangHaiJun
|
||||
* @since 2022-07-12 10:08:34
|
||||
*/
|
||||
@Mapper
|
||||
public interface TbYsDlMapper extends BaseMapper<TbYsDl> {
|
||||
|
||||
@ApiOperation("查询列表分页")
|
||||
List<TbYsDl> getPageList(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询列表数据总和")
|
||||
int getCount(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询所有数据不分页")
|
||||
List<TbYsDl> getList(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询地理要素详情")
|
||||
TbYsDl getInfoById(String id);
|
||||
|
||||
@ApiOperation("添加地理要素数据")
|
||||
void insertEntity(TbYsDl dl);
|
||||
|
||||
@ApiOperation("修改地理要素信息")
|
||||
void updateEntity(TbYsDl dl);
|
||||
}
|
||||
|
||||
|
@ -0,0 +1,18 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsGajgGlbm;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/8/26
|
||||
**/
|
||||
@Mapper
|
||||
public interface TbYsGajgGlbmMapper extends BaseMapper<TbYsGajgGlbm> {
|
||||
|
||||
@ApiOperation("删除关联部门")
|
||||
void deleteGlbm(@Param("id") String id);
|
||||
}
|
@ -0,0 +1,35 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsGajg;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/20
|
||||
**/
|
||||
@Mapper
|
||||
public interface TbYsGajgMapper extends BaseMapper<TbYsGajg> {
|
||||
|
||||
@ApiOperation("新增公安机关要素")
|
||||
int insertEntity(TbYsGajg gajg);
|
||||
|
||||
@ApiOperation("获取公安机关详情")
|
||||
TbYsGajg getInfoById(String id);
|
||||
|
||||
@ApiOperation("修改公安机关要素")
|
||||
void updateEntity(TbYsGajg gajg);
|
||||
|
||||
@ApiOperation("查询公安机关总数")
|
||||
int getCount(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询公安机关列表分页")
|
||||
List<TbYsGajg> getListPage(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询公安机关列表-不分页")
|
||||
List<TbYsGajg> getList(Map<String, Object> map);
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRyBq;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
@Mapper
|
||||
public interface TbYsRyBqMapper extends BaseMapper<TbYsRyBq> {
|
||||
|
||||
@ApiOperation("删除人员标签")
|
||||
void deleteByRyId(@Param("id") String id);
|
||||
}
|
@ -0,0 +1,13 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRyDh;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
@Mapper
|
||||
public interface TbYsRyDhMapper extends BaseMapper<TbYsRyDh> {
|
||||
|
||||
@ApiOperation("删除人员电话")
|
||||
void deleteByRyId(String id);
|
||||
}
|
@ -0,0 +1,10 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRy;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
@Mapper
|
||||
public interface TbYsRyMapper extends BaseMapper<TbYsRy> {
|
||||
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsSxt;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/19
|
||||
**/
|
||||
@Mapper
|
||||
public interface TbYsSxtMapper extends BaseMapper<TbYsSxt> {
|
||||
|
||||
@ApiOperation("添加摄像头信息")
|
||||
int insertEntity(TbYsSxt sxt);
|
||||
|
||||
@ApiOperation("修改摄像头信息")
|
||||
void updateEntity(TbYsSxt sxt);
|
||||
|
||||
@ApiOperation("查询摄像头的详细信息")
|
||||
TbYsSxt getInfoById(String id);
|
||||
|
||||
@ApiOperation("查询摄像头列表总数")
|
||||
int getCount(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询摄像头列表--分页")
|
||||
List<TbYsSxt> getPageList(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询摄像头列表--不分页·")
|
||||
List<TbYsSxt> getList(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询摄像头-事件中心")
|
||||
List<TbYsSxt> getSjList(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询摄像头的详细信息")
|
||||
TbYsSxt queryBySjlyid(String sjlyid);
|
||||
|
||||
@ApiOperation("清空摄像头数据")
|
||||
void deleteAll();
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.entity.yszx.TbYsXsaj;
|
||||
import com.mosty.base.model.vo.yszx.TbYsAjVo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/21
|
||||
**/
|
||||
@Mapper
|
||||
public interface TbYsXsajMapper extends BaseMapper<TbYsXsaj> {
|
||||
|
||||
@ApiOperation("新增行事案件")
|
||||
void insertXsaj(TbYsXsaj xs);
|
||||
|
||||
@ApiOperation("查询行事案件详情")
|
||||
TbYsXsaj selectXsAjById(String id);
|
||||
|
||||
@ApiOperation("修改行事案件")
|
||||
void updateXsEntity(TbYsXsaj xs);
|
||||
}
|
@ -0,0 +1,40 @@
|
||||
package com.mosty.yszx.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDelDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsXzaj;
|
||||
import com.mosty.base.model.vo.yszx.TbYsAjVo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/21
|
||||
**/
|
||||
@Mapper
|
||||
public interface TbYsXzajMapper extends BaseMapper<TbYsXzaj> {
|
||||
|
||||
@ApiOperation("新增行政案件")
|
||||
void insertXzaj(TbYsXzaj xz);
|
||||
|
||||
@ApiOperation("查询行政案件详情")
|
||||
TbYsXzaj selectXzAjById(String id);
|
||||
|
||||
@ApiOperation("修改行政案件")
|
||||
void updateXzEntity(TbYsXzaj xz);
|
||||
|
||||
@ApiOperation("获取案件总数")
|
||||
int getCount(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("获取案件列表")
|
||||
List<TbYsAjVo> getList(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("查询案件不分页")
|
||||
List<TbYsAjVo> getListAll(Map<String, Object> map);
|
||||
|
||||
@ApiOperation("删除案件信息")
|
||||
void delAj(TbYsAjDelDto dto);
|
||||
}
|
@ -0,0 +1,117 @@
|
||||
package com.mosty.yszx.mybatisplus;
|
||||
|
||||
import cn.hutool.http.HttpStatus;
|
||||
import com.baomidou.mybatisplus.core.handlers.MetaObjectHandler;
|
||||
import com.mosty.common.base.exception.BusinessException;
|
||||
import com.mosty.common.base.util.IpUtil;
|
||||
import com.mosty.common.token.UserInfo;
|
||||
import com.mosty.common.token.UserInfoManager;
|
||||
import org.apache.ibatis.reflection.MetaObject;
|
||||
|
||||
import java.sql.Timestamp;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* MybatisPlus注入处理器
|
||||
*
|
||||
* @author Lhh
|
||||
* @date 2021/4/25
|
||||
*/
|
||||
public class CreateAndUpdateMetaObjectHandler implements MetaObjectHandler {
|
||||
|
||||
@Override
|
||||
public void insertFill(MetaObject metaObject) {
|
||||
try {
|
||||
UserInfo userInfo = UserInfoManager.getUser();
|
||||
//根据属性名字设置要填充的值
|
||||
if (metaObject.hasGetter("xtCjip")) {
|
||||
if (metaObject.getValue("xtCjip") == null) {
|
||||
this.strictInsertFill(metaObject, "xtCjip", String.class, IpUtil.getIpAddress());
|
||||
}
|
||||
}
|
||||
//根据属性名字设置要填充的值
|
||||
if (metaObject.hasGetter("xtSjzt")) {
|
||||
if (metaObject.getValue("xtSjzt") == null) {
|
||||
this.strictInsertFill(metaObject, "xtSjzt", String.class, "1");
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtScbz")) {
|
||||
if (metaObject.getValue("xtScbz") == null) {
|
||||
this.strictInsertFill(metaObject, "xtScbz", String.class, "0");
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtCjsj")) {
|
||||
if (metaObject.getValue("xtCjsj") == null) {
|
||||
this.strictInsertFill(metaObject, "xtCjsj", Timestamp.class, new Timestamp(System.currentTimeMillis()));
|
||||
}
|
||||
}
|
||||
if (Objects.nonNull(userInfo)) {
|
||||
if (metaObject.hasGetter("xtCjrId")) {
|
||||
if (metaObject.getValue("xtCjrId") == null) {
|
||||
this.strictInsertFill(metaObject, "xtCjrId", String.class, String.valueOf(userInfo.userId));
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtCjr")) {
|
||||
if (metaObject.getValue("xtCjr") == null) {
|
||||
this.strictInsertFill(metaObject, "xtCjr", String.class, String.valueOf(userInfo.userName));
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtCjbmdm")) {
|
||||
if (metaObject.getValue("xtCjbmdm") == null) {
|
||||
this.strictInsertFill(metaObject, "xtCjbmdm", String.class, String.valueOf(userInfo.getDeptId()));
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtCjbmmc")) {
|
||||
if (metaObject.getValue("xtCjbmmc") == null) {
|
||||
this.strictInsertFill(metaObject, "xtCjbmmc", String.class, userInfo.getDeptName());
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
throw new BusinessException("自动注入异常 => " + e.getMessage(), HttpStatus.HTTP_UNAUTHORIZED);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateFill(MetaObject metaObject) {
|
||||
try {
|
||||
UserInfo userInfo = UserInfoManager.getUser();
|
||||
if (metaObject.hasGetter("xtZhgxip")) {
|
||||
if (metaObject.getValue("xtZhgxip") == null) {
|
||||
this.strictUpdateFill(metaObject, "xtZhgxip", String.class, IpUtil.getIpAddress());
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtZhgxsj")) {
|
||||
if (metaObject.getValue("xtZhgxsj") == null) {
|
||||
this.strictUpdateFill(metaObject, "xtZhgxsj", Timestamp.class, new Timestamp(System.currentTimeMillis()));
|
||||
}
|
||||
}
|
||||
if (Objects.nonNull(userInfo)) {
|
||||
if (metaObject.hasGetter("xtZhgxrid")) {
|
||||
if (metaObject.getValue("xtZhgxrid") == null) {
|
||||
this.strictUpdateFill(metaObject, "xtZhgxrid", String.class, String.valueOf(userInfo.userId));
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtZhgxr")) {
|
||||
if (metaObject.getValue("xtZhgxr") == null) {
|
||||
this.strictUpdateFill(metaObject, "xtZhgxr", String.class, userInfo.userName);
|
||||
}
|
||||
}
|
||||
|
||||
if (metaObject.hasGetter("xtZhgxbmdm")) {
|
||||
if (metaObject.getValue("xtZhgxbmdm") == null) {
|
||||
this.strictUpdateFill(metaObject, "xtZhgxbmdm", String.class, String.valueOf(userInfo.getDeptId()));
|
||||
}
|
||||
}
|
||||
if (metaObject.hasGetter("xtZhgxbm")) {
|
||||
if (metaObject.getValue("xtZhgxbm") == null) {
|
||||
this.strictUpdateFill(metaObject, "xtZhgxbm", String.class, userInfo.getDeptName());
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
throw new BusinessException("自动注入异常 => " + e.getMessage(), HttpStatus.HTTP_UNAUTHORIZED);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
package com.mosty.yszx.mybatisplus;
|
||||
|
||||
import com.baomidou.mybatisplus.core.handlers.MetaObjectHandler;
|
||||
import org.mybatis.spring.annotation.MapperScan;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
import org.springframework.transaction.annotation.EnableTransactionManagement;
|
||||
|
||||
/**
|
||||
* mybatis-plus配置类
|
||||
*
|
||||
* @author Lhh
|
||||
*/
|
||||
@EnableTransactionManagement(proxyTargetClass = true)
|
||||
@Configuration
|
||||
@MapperScan("com.mosty.yszx.mapper")
|
||||
public class MybatisPlusConfig {
|
||||
|
||||
/**
|
||||
* 元对象字段填充控制器
|
||||
* https://baomidou.com/guide/auto-fill-metainfo.html
|
||||
*/
|
||||
@Bean
|
||||
public MetaObjectHandler metaObjectHandler() {
|
||||
return new CreateAndUpdateMetaObjectHandler();
|
||||
}
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,72 @@
|
||||
package com.mosty.yszx.remote;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.mosty.base.model.dto.base.GetDeptListDTO;
|
||||
import com.mosty.base.model.dto.base.GetSsbmDto;
|
||||
import com.mosty.base.model.dto.base.SysDeptDTO;
|
||||
import com.mosty.base.feign.service.MostyBaseFeignService;
|
||||
import com.mosty.base.model.vo.base.DeptInfoVo;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.exception.BusinessException;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 调用部门信息远程适配层
|
||||
*
|
||||
* @author kevin
|
||||
* @date 2022/7/6 10:37 上午
|
||||
* @since 1.0.0
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
@AllArgsConstructor
|
||||
public class TbBaseAdaptRemoteService {
|
||||
|
||||
private final MostyBaseFeignService mostyBaseFeignService;
|
||||
|
||||
|
||||
// 根据部门编码查询部门信息
|
||||
public DeptInfoVo getOrgByDeptId(String deptid) {
|
||||
if (StringUtils.isBlank(deptid)) {
|
||||
return null;
|
||||
}
|
||||
ResponseResult<DeptInfoVo> responseResult = mostyBaseFeignService.getOrgByDeptId(deptid);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("根据部门ID查询部门信息异常 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
throw new BusinessException("根据部门ID查询部门信息异常");
|
||||
}
|
||||
return responseResult.getData();
|
||||
}
|
||||
|
||||
// 根据部门编码查询部门信息
|
||||
public DeptInfoVo getOrgByOrgcode(String orgcode) {
|
||||
if (StringUtils.isBlank(orgcode)) {
|
||||
return null;
|
||||
}
|
||||
ResponseResult<DeptInfoVo> responseResult = mostyBaseFeignService.getOrgByOrgcode(orgcode);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("根据部门ID查询部门信息异常 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
throw new BusinessException("根据部门ID查询部门信息异常");
|
||||
}
|
||||
return responseResult.getData();
|
||||
}
|
||||
|
||||
// 获取权限查询条件
|
||||
public String getSsbm(String ssbmdm, String isChild) {
|
||||
GetSsbmDto dto = new GetSsbmDto(ssbmdm, isChild);
|
||||
ResponseResult<String> responseResult = mostyBaseFeignService.getSsbm(dto);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("获取权限查询条件异常 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
throw new BusinessException("获取权限查询条件异常");
|
||||
}
|
||||
return responseResult.getData();
|
||||
}
|
||||
}
|
@ -0,0 +1,56 @@
|
||||
package com.mosty.yszx.remote;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.mosty.base.feign.service.MostyRwzxFeignService;
|
||||
import com.mosty.base.model.dto.rwzx.TbRwTaskDto;
|
||||
import com.mosty.base.model.entity.rwzx.TbRwTask;
|
||||
import com.mosty.base.model.entity.yjzl.TbZlxx;
|
||||
import com.mosty.base.model.query.rwzx.TbRwTaskByYwidQuery;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.exception.BusinessException;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/10/05
|
||||
* 外部调用任务中心接口
|
||||
**/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class TbRwzxAdaptRemoteService {
|
||||
|
||||
@Resource
|
||||
private MostyRwzxFeignService mostyRwzxFeignService;
|
||||
|
||||
// 发送任务给各个用户
|
||||
public Integer addRw(TbRwTaskDto dto) {
|
||||
ResponseResult<Integer> responseResult = mostyRwzxFeignService.addRw(dto);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("任务下发失败 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
return 0;
|
||||
}
|
||||
return responseResult.getData();
|
||||
}
|
||||
|
||||
// 获取任务信息
|
||||
public TbRwTask getRwByYwid(TbRwTaskByYwidQuery dto) {
|
||||
ResponseResult<TbRwTask> responseResult = mostyRwzxFeignService.getRwByYwid(dto);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("获取任务信息失败 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
throw new BusinessException("任务查询报错!!");
|
||||
}
|
||||
return responseResult.getData();
|
||||
}
|
||||
|
||||
// 修改旧的指令任务状态为未读
|
||||
public void changeTaskStateByZlid(TbZlxx zlxx) {
|
||||
ResponseResult<Void> responseResult = mostyRwzxFeignService.changeTaskStateByZlid(zlxx);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("修改任务状态失败 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
throw new BusinessException("修改任务状态失败!!");
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,33 @@
|
||||
package com.mosty.yszx.remote;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.mosty.base.model.dto.sjzx.TbSjSpbfDTO;
|
||||
import com.mosty.base.feign.service.MostySjzxFeignService;
|
||||
import com.mosty.common.base.domain.ResponseResult;
|
||||
import com.mosty.common.base.exception.BusinessException;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* 事件中心远程调用
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
@AllArgsConstructor
|
||||
public class TbSjzxAdaptRemoteService {
|
||||
|
||||
private final MostySjzxFeignService mostySjzxFeignService;
|
||||
|
||||
// 保存视频播放日志
|
||||
public void tbSjSpbfAdd(TbSjSpbfDTO dto) {
|
||||
ResponseResult<Integer> responseResult = mostySjzxFeignService.tbSjSpbfAdd(dto);
|
||||
if (responseResult == null || !responseResult.isSuccess()) {
|
||||
log.error("保存视频播放日志失败 responseResult = {}", JSON.toJSONString(responseResult));
|
||||
throw new BusinessException("保存视频播放日志失败");
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,40 @@
|
||||
package com.mosty.yszx.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDelDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDto;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsAjVo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/21
|
||||
**/
|
||||
public interface TbYsAjService {
|
||||
|
||||
@ApiOperation("案件新增")
|
||||
void addAj(TbYsAjDto dto);
|
||||
|
||||
@ApiOperation("案件修改")
|
||||
void updateAj(TbYsAjDto dto);
|
||||
|
||||
@ApiOperation("分页获取案件列表")
|
||||
IPage<TbYsAjVo> getPageList(TbYsAjQuery dto);
|
||||
|
||||
@ApiOperation("不分页获取案件列表")
|
||||
List<TbYsAjVo> getList(TbYsAjNoPageQuery dto);
|
||||
|
||||
@ApiOperation("删除案件信息")
|
||||
void delAj(TbYsAjDelDto dto);
|
||||
|
||||
@ApiOperation("获取案件数据--热力图")
|
||||
List<Map<String,Object>> getAjHotMap(TbYsAjNoPageQuery dto);
|
||||
|
||||
@ApiOperation("获取案件详情")
|
||||
TbYsAjVo getInfo(String id, String ajfl);
|
||||
}
|
@ -0,0 +1,45 @@
|
||||
package com.mosty.yszx.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsDl;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
*
|
||||
要素-地理要素表(TbYsDl)表服务接口
|
||||
*
|
||||
* @author zhangHaiJun
|
||||
* @since 2022-07-12 10:08:38
|
||||
*/
|
||||
public interface TbYsDlService {
|
||||
|
||||
@ApiOperation("查询所有数据")
|
||||
IPage<TbYsDlVo> queryAll(TbYsDlQuery dto);
|
||||
|
||||
@ApiOperation("通过ID查询单条数据")
|
||||
TbYsDlVo queryById(String id);
|
||||
|
||||
@ApiOperation("新增数据")
|
||||
void insert(TbYsDlDto tbYsDl);
|
||||
|
||||
@ApiOperation("修改数据")
|
||||
void update(TbYsDlDto tbYsDl);
|
||||
|
||||
@ApiOperation("通过主键删除数据")
|
||||
void deleteById(String id);
|
||||
|
||||
@ApiOperation("大屏-巡组气泡框-视频随动")
|
||||
List<TbYsDl> selectVideoServo(TbYsDl tbYsDl);
|
||||
|
||||
@ApiOperation("根据关键字查询")
|
||||
List<TbYsDlVo> selectByNr(String keyword);
|
||||
|
||||
@ApiOperation("根据名称查询地理要素")
|
||||
TbYsDl selectDlys(String ysmc);
|
||||
}
|
||||
|
@ -0,0 +1,58 @@
|
||||
package com.mosty.yszx.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgAndGlbmDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgByJwdDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgGlbmDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsGajg;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgGlbmVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgVo;
|
||||
import com.mosty.common.core.business.entity.vo.Base64Str;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/20
|
||||
**/
|
||||
public interface TbYsGajgService {
|
||||
|
||||
@ApiOperation("公安机关要素新增")
|
||||
int insertEntity(TbYsGajgDto dto);
|
||||
|
||||
@ApiOperation("公安机关要素修改")
|
||||
void updateEntity(TbYsGajgDto dto);
|
||||
|
||||
@ApiOperation("根据来源修改公安机关要素")
|
||||
void updateEntityByLY(TbYsGajgDto dto);
|
||||
|
||||
@ApiOperation("公安机关要素详情查询")
|
||||
TbYsGajgVo getInfo(String id);
|
||||
|
||||
@ApiOperation("查询公安机关列表")
|
||||
IPage<TbYsGajgVo> getPageList(TbYsGajgQuery dto);
|
||||
|
||||
@ApiOperation("删除公安机关要素")
|
||||
void delEntity(String id);
|
||||
|
||||
@ApiOperation("删除公安机关要素")
|
||||
void delEntity(TbYsGajgDto dto);
|
||||
|
||||
@ApiOperation("根据经纬度判断所属公安机关")
|
||||
TbYsGajgVo getGajgByJwd(TbYsGajgByJwdDto dto);
|
||||
|
||||
@ApiOperation("公安机关要素新增--添加关联部门")
|
||||
int addGajg(TbYsGajgAndGlbmDto dto);
|
||||
|
||||
@ApiOperation("公安机关要素修改--修改关联部门")
|
||||
void editGajg(TbYsGajgAndGlbmDto dto);
|
||||
|
||||
@ApiOperation("查询公安机关关联部门")
|
||||
List<TbYsGajgGlbmDto> getGlbmList(String id);
|
||||
|
||||
@ApiOperation("查询公安机关列表(包含关联部门ID)")
|
||||
List<TbYsGajgGlbmVo> getGajgList(TbYsGajgQuery dto);
|
||||
}
|
@ -0,0 +1,25 @@
|
||||
package com.mosty.yszx.service;
|
||||
|
||||
import com.mosty.base.model.dto.yszx.TbYsRyDto;
|
||||
import com.mosty.base.model.vo.yszx.TbYsRyBqUpdateDto;
|
||||
import com.mosty.base.model.vo.yszx.TbYsRyDhUpdateDto;
|
||||
import com.mosty.base.model.vo.yszx.TbYsRyVo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
public interface TbYsRyService {
|
||||
|
||||
@ApiOperation("查询人员详情")
|
||||
TbYsRyVo getRyInfo(String sfzh);
|
||||
|
||||
@ApiOperation("添加人员要素")
|
||||
void addRyYs(TbYsRyDto dto);
|
||||
|
||||
@ApiOperation("修改人员要素")
|
||||
void updateRyYs(TbYsRyDto dto);
|
||||
|
||||
@ApiOperation("修改人员标签要素")
|
||||
void updateRyBqYs(TbYsRyBqUpdateDto dto);
|
||||
|
||||
@ApiOperation("修改人员电话要素")
|
||||
void updateRyDhys(TbYsRyDhUpdateDto dto);
|
||||
}
|
@ -0,0 +1,64 @@
|
||||
package com.mosty.yszx.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.mosty.base.model.dto.yszx.TbYsSxtDto;
|
||||
import com.mosty.base.model.entity.lzother.ZhjmxfXfqwXfqyGzdw;
|
||||
import com.mosty.base.model.entity.yszx.TbYsSxt;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtPageOneQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtQuery;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/19
|
||||
**/
|
||||
public interface TbYsSxtService {
|
||||
|
||||
@ApiOperation("摄像头新增")
|
||||
int insertEntity(TbYsSxtDto dto);
|
||||
|
||||
@ApiOperation("摄像头修改")
|
||||
void updateEntity(TbYsSxtDto dto);
|
||||
|
||||
@ApiOperation("查询摄像头分页列表")
|
||||
IPage<TbYsSxt> getPageList(TbYsSxtQuery dto);
|
||||
|
||||
@ApiOperation("查询摄像头列表---不分页")
|
||||
List<TbYsSxt> getList(TbYsSxtNoPageQuery dto);
|
||||
|
||||
@ApiOperation("查询摄像头详情信息")
|
||||
TbYsSxt getInfo(String id);
|
||||
|
||||
@ApiOperation("删除摄像头信息")
|
||||
void delEntity(String id);
|
||||
|
||||
@ApiOperation("查询摄像头-事件中心")
|
||||
List<TbYsSxt> getSjList(String jd ,String wd ,String sjid);
|
||||
|
||||
@ApiOperation("摄像头新增")
|
||||
int insertEntity(TbYsSxt sxt);
|
||||
|
||||
@ApiOperation("查询摄像头详情信息")
|
||||
TbYsSxt queryBySjlyid(String sjlyid);
|
||||
|
||||
@ApiOperation("根据设备编号查询摄像头详情")
|
||||
TbYsSxtDto getInfoBySbbh(String sbbh);
|
||||
|
||||
@ApiOperation("获取所有的感知源的设备编号")
|
||||
List<String> getSxtBhList(List<String> ids);
|
||||
|
||||
@ApiOperation("添加泸州感知源数据")
|
||||
void addLzGzy(ZhjmxfXfqwXfqyGzdw dto);
|
||||
|
||||
@ApiOperation("查询感知源信息")
|
||||
TbYsSxtDto selectGzy(TbYsSxtPageOneQuery dto);
|
||||
|
||||
@ApiOperation("摄像头更新经纬度")
|
||||
void updateJwd();
|
||||
|
||||
@ApiOperation("更新泸州感知源数据")
|
||||
void updateLzGzy();
|
||||
}
|
@ -0,0 +1,229 @@
|
||||
package com.mosty.yszx.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.mosty.base.utils.GeoHashKit;
|
||||
import com.mosty.base.utils.JtsUtils;
|
||||
import com.mosty.base.utils.UUIDGenerator;
|
||||
import com.mosty.base.model.vo.base.DeptInfoVo;
|
||||
import com.mosty.common.base.util.StringUtils;
|
||||
import com.mosty.common.token.UserInfo;
|
||||
import com.mosty.common.token.UserInfoManager;
|
||||
import com.mosty.common.util.PermissionsUtil;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDelDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsAjDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsXsaj;
|
||||
import com.mosty.base.model.entity.yszx.TbYsXzaj;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsAjQuery;
|
||||
import com.mosty.base.model.vo.yszx.TbYsAjVo;
|
||||
import com.mosty.yszx.mapper.TbYsXsajMapper;
|
||||
import com.mosty.yszx.mapper.TbYsXzajMapper;
|
||||
import com.mosty.yszx.remote.TbBaseAdaptRemoteService;
|
||||
import com.mosty.yszx.service.TbYsAjService;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/21
|
||||
**/
|
||||
@Service
|
||||
@AllArgsConstructor
|
||||
public class TbYsAjServiceImpl implements TbYsAjService {
|
||||
|
||||
private final TbYsXsajMapper tbYsXsajMapper;
|
||||
private final TbYsXzajMapper tbYsXzajMapper;
|
||||
private final TbBaseAdaptRemoteService tbBaseAdaptRemoteService;
|
||||
|
||||
@Override
|
||||
public void addAj(TbYsAjDto dto) {
|
||||
String id = UUIDGenerator.getUUID();
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByDeptId(dto.getSsbmid());
|
||||
if ("1".equals(dto.getAjfl())) {
|
||||
TbYsXsaj xs = new TbYsXsaj();
|
||||
BeanUtils.copyProperties(dto, xs);
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
xs.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
xs.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
xs.setJsnr(dto.getAjmc() + " " + dto.getAjbh() + " " + dto.getDzmc() +
|
||||
" " + dto.getAymc() + " " + dto.getAjnr());
|
||||
xs.setId(id);
|
||||
xs.setXtSjly("1");
|
||||
if (dept != null) {
|
||||
xs.setSsbm(dept.getDeptname());
|
||||
xs.setSsbmid(dept.getDeptid());
|
||||
xs.setSsbmdm(dept.getDeptcode());
|
||||
xs.setSsxgajdm(dept.getFxjcode());
|
||||
xs.setSsxgajid(dept.getFxjid());
|
||||
xs.setSsxgaj(dept.getFxjname());
|
||||
xs.setSssgaj(dept.getDszname());
|
||||
xs.setSssgajdm(dept.getDszcode());
|
||||
xs.setSssgajid(dept.getDszid());
|
||||
}
|
||||
this.tbYsXsajMapper.insertXsaj(xs);
|
||||
} else if ("2".equals(dto.getAjfl())) {
|
||||
TbYsXzaj xz = new TbYsXzaj();
|
||||
BeanUtils.copyProperties(dto, xz);
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
xz.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
xz.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
xz.setJsnr(dto.getAjmc() + " " + dto.getAjbh() + " " + dto.getDzmc() +
|
||||
" " + dto.getAymc() + " " + dto.getAjnr());
|
||||
xz.setId(id);
|
||||
xz.setXtSjly("1");
|
||||
if (dept != null) {
|
||||
xz.setSsbm(dept.getDeptname());
|
||||
xz.setSsbmid(dept.getDeptid());
|
||||
xz.setSsbmdm(dept.getDeptcode());
|
||||
xz.setSsxgajdm(dept.getFxjcode());
|
||||
xz.setSsxgajid(dept.getFxjid());
|
||||
xz.setSsxgaj(dept.getFxjname());
|
||||
xz.setSssgaj(dept.getDszname());
|
||||
xz.setSssgajdm(dept.getDszcode());
|
||||
xz.setSssgajid(dept.getDszid());
|
||||
}
|
||||
this.tbYsXzajMapper.insertXzaj(xz);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateAj(TbYsAjDto dto) {
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByDeptId(dto.getSsbmid());
|
||||
if ("1".equals(dto.getAjfl())) {
|
||||
TbYsXsaj xs = new TbYsXsaj();
|
||||
BeanUtils.copyProperties(dto, xs);
|
||||
if (xs.getJd() != null && xs.getWd() != null) {
|
||||
xs.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
xs.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
if (dept != null) {
|
||||
xs.setSsbm(dept.getDeptname());
|
||||
xs.setSsbmid(dept.getDeptid());
|
||||
xs.setSsbmdm(dept.getDeptcode());
|
||||
xs.setSsxgajdm(dept.getFxjcode());
|
||||
xs.setSsxgajid(dept.getFxjid());
|
||||
xs.setSsxgaj(dept.getFxjname());
|
||||
xs.setSssgaj(dept.getDszname());
|
||||
xs.setSssgajdm(dept.getDszcode());
|
||||
xs.setSssgajid(dept.getDszid());
|
||||
}this.tbYsXsajMapper.updateXsEntity(xs);
|
||||
xs = this.tbYsXsajMapper.selectXsAjById(xs.getId());
|
||||
xs.setJsnr(dto.getAjmc() + " " + dto.getAjbh() + " " + dto.getDzmc() +
|
||||
" " + dto.getAymc() + " " + dto.getAjnr());
|
||||
this.tbYsXsajMapper.updateXsEntity(xs);
|
||||
} else if ("2".equals(dto.getAjfl())) {
|
||||
TbYsXzaj xz = new TbYsXzaj();
|
||||
BeanUtils.copyProperties(dto, xz);
|
||||
if (xz.getJd() != null && xz.getWd() != null) {
|
||||
xz.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
xz.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
if (dept != null) {
|
||||
xz.setSsbm(dept.getDeptname());
|
||||
xz.setSsbmid(dept.getDeptid());
|
||||
xz.setSsbmdm(dept.getDeptcode());
|
||||
xz.setSsxgajdm(dept.getFxjcode());
|
||||
xz.setSsxgajid(dept.getFxjid());
|
||||
xz.setSsxgaj(dept.getFxjname());
|
||||
xz.setSssgaj(dept.getDszname());
|
||||
xz.setSssgajdm(dept.getDszcode());
|
||||
xz.setSssgajid(dept.getDszid());
|
||||
}
|
||||
this.tbYsXzajMapper.updateXzEntity(xz);
|
||||
xz = this.tbYsXzajMapper.selectXzAjById(xz.getId());
|
||||
xz.setJsnr(dto.getAjmc() + " " + dto.getAjbh() + " " + dto.getDzmc() +
|
||||
" " + dto.getAymc() + " " + dto.getAjnr());
|
||||
this.tbYsXzajMapper.updateXzEntity(xz);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public IPage<TbYsAjVo> getPageList(TbYsAjQuery dto) {
|
||||
if (StringUtils.isNotBlank(dto.getStartTime())) {
|
||||
dto.setStartTime(dto.getStartTime() + " 00:00:00");
|
||||
}
|
||||
if (StringUtils.isNotBlank(dto.getEndTime())) {
|
||||
dto.setEndTime(dto.getEndTime() + " 23:59:59");
|
||||
}
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("pageIndex", (dto.getPageNum() - 1) * dto.getPageSize());
|
||||
map.put("pageSize", dto.getPageSize());
|
||||
map.put("dto", dto);
|
||||
UserInfo user = UserInfoManager.get();
|
||||
String useSql = PermissionsUtil.createSql("", user);
|
||||
map.put("useSql", useSql);
|
||||
int count = this.tbYsXzajMapper.getCount(map);
|
||||
List<TbYsAjVo> list = this.tbYsXzajMapper.getList(map);
|
||||
IPage<TbYsAjVo> page = new Page<>();
|
||||
page.setRecords(list);
|
||||
page.setTotal(count);
|
||||
return page;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsAjVo> getList(TbYsAjNoPageQuery dto) {
|
||||
if (StringUtils.isNotBlank(dto.getStartTime())) {
|
||||
dto.setStartTime(dto.getStartTime() + " 00:00:00");
|
||||
}
|
||||
if (StringUtils.isNotBlank(dto.getEndTime())) {
|
||||
dto.setEndTime(dto.getEndTime() + " 23:59:59");
|
||||
}
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("dto", dto);
|
||||
UserInfo user = UserInfoManager.get();
|
||||
String useSql = PermissionsUtil.createSql("", user);
|
||||
map.put("useSql", useSql);
|
||||
return this.tbYsXzajMapper.getListAll(map);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delAj(TbYsAjDelDto dto) {
|
||||
this.tbYsXzajMapper.delAj(dto);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<Map<String, Object>> getAjHotMap(TbYsAjNoPageQuery dto) {
|
||||
if (StringUtils.isNotBlank(dto.getStartTime())) {
|
||||
dto.setStartTime(dto.getStartTime() + " 00:00:00");
|
||||
}
|
||||
if (StringUtils.isNotBlank(dto.getEndTime())) {
|
||||
dto.setEndTime(dto.getEndTime() + " 23:59:59");
|
||||
}
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("dto", dto);
|
||||
UserInfo user = UserInfoManager.get();
|
||||
String useSql = PermissionsUtil.createSql("", user);
|
||||
map.put("useSql", useSql);
|
||||
List<TbYsAjVo> list = this.tbYsXzajMapper.getListAll(map);
|
||||
List<Map<String, Object>> rList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
Map<String, Object> mp = new HashMap<>();
|
||||
mp.put("lng", item.getJd());
|
||||
mp.put("lat", item.getWd());
|
||||
mp.put("count", 1);
|
||||
rList.add(mp);
|
||||
});
|
||||
return rList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsAjVo getInfo(String id, String ajfl) {
|
||||
TbYsAjVo vo = new TbYsAjVo();
|
||||
if ("1".equals(ajfl)) {
|
||||
TbYsXsaj xs = this.tbYsXsajMapper.selectXsAjById(id);
|
||||
BeanUtils.copyProperties(xs, vo);
|
||||
return vo;
|
||||
} else if ("2".equals(ajfl)) {
|
||||
TbYsXzaj xz = this.tbYsXzajMapper.selectXzAjById(id);
|
||||
BeanUtils.copyProperties(xz, vo);
|
||||
return vo;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
@ -0,0 +1,238 @@
|
||||
package com.mosty.yszx.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.Wrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mosty.base.utils.GeoHashKit;
|
||||
import com.mosty.base.utils.JtsUtils;
|
||||
import com.mosty.base.utils.UUIDGenerator;
|
||||
import com.mosty.base.model.vo.base.DeptInfoVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlQuery;
|
||||
import com.mosty.common.token.UserInfo;
|
||||
import com.mosty.common.token.UserInfoManager;
|
||||
import com.mosty.common.util.PermissionsUtil;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsDlDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsDl;
|
||||
import com.mosty.yszx.mapper.TbYsDlMapper;
|
||||
import com.mosty.yszx.remote.TbBaseAdaptRemoteService;
|
||||
import com.mosty.yszx.service.TbYsDlService;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 要素-地理要素表(TbYsDl)表服务实现类
|
||||
*
|
||||
* @author zhangHaiJun
|
||||
* @since 2022-07-12 10:08:40
|
||||
*/
|
||||
@Service("tbYsDlService")
|
||||
public class TbYsDlServiceImpl extends ServiceImpl<TbYsDlMapper, TbYsDl>
|
||||
implements TbYsDlService {
|
||||
|
||||
@Resource
|
||||
private TbBaseAdaptRemoteService tbBaseAdaptRemoteService;
|
||||
|
||||
@Override
|
||||
public IPage<TbYsDlVo> queryAll(TbYsDlQuery dto) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("dto", dto);
|
||||
UserInfo user = UserInfoManager.getUser();
|
||||
String useSql = user != null ? PermissionsUtil.createSql("", user) : "";
|
||||
map.put("useSql", useSql);
|
||||
IPage<TbYsDlVo> page;
|
||||
if (dto.getPageNum() != null && dto.getPageSize() != null) {
|
||||
page = new Page<>(dto.getPageNum(), dto.getPageSize());
|
||||
map.put("pageIndex", (dto.getPageNum() - 1) * dto.getPageSize());
|
||||
map.put("pageSize", dto.getPageSize());
|
||||
int count = this.baseMapper.getCount(map);
|
||||
List<TbYsDl> list = this.baseMapper.getPageList(map);
|
||||
List<TbYsDlVo> rList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsDlVo vo = new TbYsDlVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
rList.add(vo);
|
||||
});
|
||||
page.setRecords(rList);
|
||||
page.setTotal(count);
|
||||
} else {
|
||||
page = new Page<>();
|
||||
List<TbYsDl> list = this.baseMapper.getList(map);
|
||||
List<TbYsDlVo> rList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsDlVo vo = new TbYsDlVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
rList.add(vo);
|
||||
});
|
||||
page.setRecords(rList);
|
||||
}
|
||||
return page;
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsDlVo queryById(String id) {
|
||||
TbYsDl item = this.baseMapper.getInfoById(id);
|
||||
TbYsDlVo vo = null;
|
||||
if (item != null) {
|
||||
vo = new TbYsDlVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
vo.setDtm(JtsUtils.decodePolygon(item.getDtm()));
|
||||
vo.setZb(new BigDecimal[]{item.getJd(), item.getWd()});
|
||||
}
|
||||
return vo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void insert(TbYsDlDto dto) {
|
||||
TbYsDl dl = new TbYsDl();
|
||||
BeanUtils.copyProperties(dto, dl);
|
||||
dl.setId(UUIDGenerator.getUUID());
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
dl.setZb(JtsUtils.getPoint(dl.getJd(), dl.getWd()));
|
||||
dl.setZbhash(GeoHashKit.encode(dl.getJd(), dl.getWd()));
|
||||
}
|
||||
if (dto.getQy() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
dl.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
dl.setJsnr(dto.getYsmc() + " " + dto.getYsjc() + " " + dto.getYswzXz()
|
||||
+ " " + dto.getYswzBc());
|
||||
dl.setXtSjly("1");
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmid());
|
||||
if (dept != null) {
|
||||
dl.setSsbm(dept.getDeptname());
|
||||
dl.setSsbmid(dept.getDeptid());
|
||||
dl.setSsbmdm(dept.getDeptcode());
|
||||
dl.setSsxgajdm(dept.getFxjcode());
|
||||
dl.setSsxgajid(dept.getFxjid());
|
||||
dl.setSsxgaj(dept.getFxjname());
|
||||
dl.setSssgaj(dept.getDszname());
|
||||
dl.setSssgajdm(dept.getDszcode());
|
||||
dl.setSssgajid(dept.getDszid());
|
||||
}
|
||||
this.baseMapper.insertEntity(dl);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void update(TbYsDlDto dto) {
|
||||
TbYsDl dl = new TbYsDl();
|
||||
BeanUtils.copyProperties(dto, dl);
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
dl.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
dl.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
if (qw != null) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
dl.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
this.baseMapper.updateEntity(dl);
|
||||
dl = this.baseMapper.getInfoById(dl.getId());
|
||||
dl.setJsnr(dl.getYsmc() + " " + dl.getYsjc() + " " + dl.getYswzXz() +
|
||||
" " + dl.getYswzBc());
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByDeptId(dto.getSsbmid());
|
||||
if (dept != null) {
|
||||
dl.setSsbmdm(dept.getDeptid());
|
||||
dl.setSsbm(dept.getDeptname());
|
||||
dl.setSsxgaj(dept.getFxjname());
|
||||
dl.setSsxgajdm(dept.getFxjid());
|
||||
dl.setSssgaj(dept.getDszname());
|
||||
dl.setSssgajdm(dept.getDszid());
|
||||
}
|
||||
this.baseMapper.updateEntity(dl);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void deleteById(String id) {
|
||||
this.baseMapper.deleteById(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsDl> selectVideoServo(TbYsDl tbYsDl) {
|
||||
//地理位置
|
||||
String dlsql = "( \n" +
|
||||
"6371 * acos( \n" +
|
||||
"cos(radians(jd))\n" +
|
||||
"* cos( radians( " + tbYsDl.getJd() + ") )\n" +
|
||||
"* cos(radians( " + tbYsDl.getWd() + " ) - radians(wd))\n" +
|
||||
"+ sin( radians(jd) ) \n" +
|
||||
"* sin( radians(" + tbYsDl.getJd() + ") ) \n" +
|
||||
") \n" +
|
||||
")";
|
||||
// UserInfo userInfo = UserInfoManager.get();
|
||||
// PermissionsUtil.queryWrapperUtil(queryWrapper, userInfo);
|
||||
QueryWrapper<TbYsDl> queryWrapper = new QueryWrapper<>();
|
||||
tbYsDl.setSsbmdm(this.tbBaseAdaptRemoteService.getSsbm(tbYsDl.getSsbmdm(), null));
|
||||
|
||||
List<TbYsDl> tbYsDlList = baseMapper.selectList((Wrapper<TbYsDl>) queryWrapper
|
||||
.like(StringUtils.isNotBlank(tbYsDl.getYsdl()), "ysdl", tbYsDl.getYsdl())
|
||||
.like(StringUtils.isNotBlank(tbYsDl.getYszl()), "yszl", tbYsDl.getYszl())
|
||||
.likeRight(StringUtils.isNotBlank(tbYsDl.getSsbmdm()), "ssbmdm", tbYsDl.getSsbmdm())
|
||||
.like(StringUtils.isNotBlank(tbYsDl.getYsxl()), "ysxl", tbYsDl.getYsxl())
|
||||
.le(StringUtils.isNotBlank(dlsql), dlsql, tbYsDl.getCxjl())
|
||||
.eq("xt_sjzt", 1)
|
||||
);
|
||||
return tbYsDlList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsDlVo> selectByNr(String keyword) {
|
||||
List<TbYsDl> list = this.baseMapper.selectList(
|
||||
new LambdaQueryWrapper<TbYsDl>()
|
||||
.like(TbYsDl::getJsnr, keyword)
|
||||
.eq(TbYsDl::getXtScbz, "0")
|
||||
);
|
||||
List<TbYsDlVo> rList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsDlVo vo = new TbYsDlVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
vo.setDtm(JtsUtils.decodePolygon(item.getDtm()));
|
||||
vo.setZb(new BigDecimal[]{item.getJd(), item.getWd()});
|
||||
rList.add(vo);
|
||||
});
|
||||
return rList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsDl selectDlys(String ysmc) {
|
||||
return this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsDl>()
|
||||
.eq(TbYsDl::getYsmc, ysmc)
|
||||
.eq(TbYsDl::getXtSjzt, "1")
|
||||
.last(" limit 1")
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,675 @@
|
||||
package com.mosty.yszx.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mosty.base.model.dto.base.GetDeptListDTO;
|
||||
import com.mosty.base.model.dto.rwzx.TbRwTaskDto;
|
||||
import com.mosty.base.model.dto.rwzx.TbRwTaskUserDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgAndGlbmDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgByJwdDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgDto;
|
||||
import com.mosty.base.model.dto.yszx.TbYsGajgGlbmDto;
|
||||
import com.mosty.base.model.entity.rwzx.TbRwTask;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgGlbmVo;
|
||||
import com.mosty.base.utils.*;
|
||||
import com.mosty.base.model.vo.base.DeptInfoVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgQuery;
|
||||
import com.mosty.common.core.business.entity.vo.Base64Str;
|
||||
import com.mosty.common.token.UserInfo;
|
||||
import com.mosty.common.token.UserInfoManager;
|
||||
import com.mosty.common.util.PermissionsUtil;
|
||||
import com.mosty.base.model.entity.yszx.TbYsGajg;
|
||||
import com.mosty.base.model.entity.yszx.TbYsGajgGlbm;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgVo;
|
||||
import com.mosty.yszx.mapper.TbYsGajgGlbmMapper;
|
||||
import com.mosty.yszx.mapper.TbYsGajgMapper;
|
||||
import com.mosty.yszx.remote.TbBaseAdaptRemoteService;
|
||||
import com.mosty.yszx.remote.TbRwzxAdaptRemoteService;
|
||||
import com.mosty.yszx.service.TbYsGajgService;
|
||||
import org.locationtech.jts.geom.Coordinate;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.checkerframework.checker.units.qual.C;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/20
|
||||
**/
|
||||
@Service
|
||||
@AllArgsConstructor
|
||||
public class TbYsGajgServiceImpl extends ServiceImpl<TbYsGajgMapper, TbYsGajg> implements TbYsGajgService {
|
||||
|
||||
private final TbBaseAdaptRemoteService tbBaseAdaptRemoteService;
|
||||
private final TbYsGajgGlbmMapper tbYsGajgGlbmMapper;
|
||||
private final TbRwzxAdaptRemoteService tbRwzxAdaptRemoteService;
|
||||
|
||||
|
||||
@Override
|
||||
public int addGajg(TbYsGajgAndGlbmDto dto) {
|
||||
TbYsGajg gajg = new TbYsGajg();
|
||||
BeanUtils.copyProperties(dto, gajg);
|
||||
gajg.setId(UUIDGenerator.getUUID());
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
gajg.setZb(JtsUtils.getPoint(gajg.getJd(), gajg.getWd()));
|
||||
gajg.setZbhash(GeoHashKit.encode(gajg.getJd(), gajg.getWd()));
|
||||
}
|
||||
if (dto.getQy() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
}
|
||||
if (dto.getQy1() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy1();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm1(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
if (dto.getQy2() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy2();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm2(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
gajg.setJsnr(dto.getGajgmc() + " " + dto.getGajgjc() + " " + dto.getWzXz() + " " + dto.getWzBc());
|
||||
gajg.setXtSjly("1");
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmdm());
|
||||
if (dept != null) {
|
||||
gajg.setSsbm(dept.getDeptname());
|
||||
gajg.setSsbmid(dept.getDeptid());
|
||||
gajg.setSsbmdm(dept.getDeptcode());
|
||||
gajg.setSsxgajdm(dept.getFxjcode());
|
||||
gajg.setSsxgajid(dept.getFxjid());
|
||||
gajg.setSsxgaj(dept.getFxjname());
|
||||
gajg.setSssgaj(dept.getDszname());
|
||||
gajg.setSssgajdm(dept.getDszcode());
|
||||
gajg.setSssgajid(dept.getDszid());
|
||||
}
|
||||
List<TbYsGajgGlbmDto> dtoList = dto.getGlbmDtoList();
|
||||
dtoList.forEach(item -> {
|
||||
TbYsGajgGlbm bm = new TbYsGajgGlbm();
|
||||
bm.setId(UUIDGenerator.getUUID());
|
||||
bm.setGajgId(gajg.getId());
|
||||
DeptInfoVo vo = this.tbBaseAdaptRemoteService.getOrgByOrgcode(item.getSsbmdm());
|
||||
if (vo != null) {
|
||||
bm.setSsbmdm(vo.getDeptcode());
|
||||
bm.setSsbm(vo.getDeptname());
|
||||
bm.setSsbmid(vo.getDeptid());
|
||||
bm.setSsxgaj(vo.getFxjname());
|
||||
bm.setSsxgajid(vo.getFxjid());
|
||||
bm.setSsxgajdm(vo.getFxjcode());
|
||||
bm.setSssgaj(vo.getDszname());
|
||||
bm.setSssgajdm(vo.getDszcode());
|
||||
bm.setSssgajid(vo.getDszid());
|
||||
}
|
||||
bm.setXtSjly("1");
|
||||
this.tbYsGajgGlbmMapper.insert(bm);
|
||||
});
|
||||
gajg.setXtSjly("1");
|
||||
// 添加关联部门
|
||||
return this.baseMapper.insertEntity(gajg);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public void editGajg(TbYsGajgAndGlbmDto dto) {
|
||||
TbYsGajg gajg = new TbYsGajg();
|
||||
BeanUtils.copyProperties(dto, gajg);
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
gajg.setZb(JtsUtils.getPoint(gajg.getJd(), gajg.getWd()));
|
||||
gajg.setZbhash(GeoHashKit.encode(gajg.getJd(), gajg.getWd()));
|
||||
}
|
||||
if (dto.getQy() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
}
|
||||
if (dto.getQy1() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy1();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm1(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
if (dto.getQy2() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy2();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm2(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
gajg.setJsnr(dto.getGajgmc() + " " + dto.getGajgjc() + " " + dto.getWzXz() + " " + dto.getWzBc());
|
||||
gajg.setXtSjly("1");
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmdm());
|
||||
if (dept != null) {
|
||||
gajg.setSsbm(dept.getDeptname());
|
||||
gajg.setSsbmid(dept.getDeptid());
|
||||
gajg.setSsbmdm(dept.getDeptcode());
|
||||
gajg.setSsxgajdm(dept.getFxjcode());
|
||||
gajg.setSsxgajid(dept.getFxjid());
|
||||
gajg.setSsxgaj(dept.getFxjname());
|
||||
gajg.setSssgaj(dept.getDszname());
|
||||
gajg.setSssgajdm(dept.getDszcode());
|
||||
gajg.setSssgajid(dept.getDszid());
|
||||
}
|
||||
List<TbYsGajgGlbmDto> dtoList = dto.getGlbmDtoList();
|
||||
// 删除之前的配置
|
||||
this.deleteGlbm(gajg.getId());
|
||||
dtoList.forEach(item -> {
|
||||
TbYsGajgGlbm bm = new TbYsGajgGlbm();
|
||||
bm.setId(UUIDGenerator.getUUID());
|
||||
bm.setGajgId(gajg.getId());
|
||||
DeptInfoVo vo = this.tbBaseAdaptRemoteService.getOrgByOrgcode(item.getSsbmdm());
|
||||
if (vo != null) {
|
||||
bm.setSsbmdm(vo.getDeptcode());
|
||||
bm.setSsbm(vo.getDeptname());
|
||||
bm.setSsbmid(vo.getDeptid());
|
||||
bm.setSsxgaj(vo.getFxjname());
|
||||
bm.setSsxgajid(vo.getFxjid());
|
||||
bm.setSsxgajdm(vo.getFxjcode());
|
||||
bm.setSssgaj(vo.getDszname());
|
||||
bm.setSssgajdm(vo.getDszcode());
|
||||
bm.setSssgajid(vo.getDszid());
|
||||
}
|
||||
bm.setXtSjly("1");
|
||||
this.tbYsGajgGlbmMapper.insert(bm);
|
||||
});
|
||||
gajg.setXtSjly("1");
|
||||
// 添加关联部门
|
||||
this.baseMapper.updateEntity(gajg);
|
||||
// 添加任务提醒
|
||||
UserInfo user = UserInfoManager.get();
|
||||
this.addTask(gajg, user);
|
||||
}
|
||||
|
||||
// 添加任务提醒功能
|
||||
private void addTask(TbYsGajg gajg, UserInfo user) {
|
||||
TbRwTaskDto dto = new TbRwTaskDto();
|
||||
String rwmc = "公安机关位置变更提醒";
|
||||
String rwnr = gajg.getGajgmc() + "信息发生变更,请知晓!!";
|
||||
dto.setRwmc(rwmc).setRwnr(rwnr)
|
||||
.setRwjsdx("02").setSfaqwc("0").setRwlx("1").setRwxl("06").setRwjjcd("3")
|
||||
.setRwms("2").setSsbmdm(gajg.getSsbmdm()).setSsbm(gajg.getSsbm()).setRwxxlx("WZBG").setSsbmid(gajg.getSsbmid());
|
||||
if (user != null) {
|
||||
dto.setCjrid(String.valueOf(user.getUserId())).setCjrxm(user.getUserName())
|
||||
.setCjrsfzh(user.getIdEntityCard()).setSsbm(user.getDeptName()).setSsbmdm(String.valueOf(user.getDeptId()));
|
||||
} else {
|
||||
dto.setCjrid("-1").setCjrxm("系统").setCjrsfzh("000000");
|
||||
}
|
||||
// 添加执行人
|
||||
List<TbRwTaskUserDto> userDtoList = new ArrayList<>();
|
||||
TbRwTaskUserDto userDto = new TbRwTaskUserDto();
|
||||
userDto.setRwzflx("02").setJsbmdm(gajg.getSssgajdm()).setJsbmmc(gajg.getSssgaj());
|
||||
userDtoList.add(userDto);
|
||||
dto.setUserDtoList(userDtoList);
|
||||
this.tbRwzxAdaptRemoteService.addRw(dto);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsGajgGlbmDto> getGlbmList(String id) {
|
||||
List<TbYsGajgGlbm> list = this.tbYsGajgGlbmMapper.selectList(
|
||||
new LambdaQueryWrapper<TbYsGajgGlbm>()
|
||||
.eq(TbYsGajgGlbm::getXtSjzt, "1")
|
||||
.eq(TbYsGajgGlbm::getGajgId, id)
|
||||
);
|
||||
List<TbYsGajgGlbmDto> rList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsGajgGlbmDto dto = new TbYsGajgGlbmDto();
|
||||
BeanUtils.copyProperties(item, dto);
|
||||
rList.add(dto);
|
||||
});
|
||||
return rList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsGajgGlbmVo> getGajgList(TbYsGajgQuery dto) {
|
||||
List<String> ysxlList = StringUtils.isEmpty(dto.getYsxl()) ? null : Arrays.asList(dto.getYsxl().split(","));
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
dto.setSsbmdm(this.tbBaseAdaptRemoteService.getSsbm(dto.getSsbmdm(), null));
|
||||
map.put("dto", dto);
|
||||
// UserInfo user = UserInfoManager.getUser();
|
||||
// String useSql = user != null ? PermissionsUtil.createSql("", user) : "";
|
||||
// map.put("useSql", useSql);
|
||||
map.put("ysxlList", ysxlList);
|
||||
List<TbYsGajg> list = this.baseMapper.getList(map);
|
||||
List<TbYsGajgGlbmVo> voList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsGajgGlbmVo vo = new TbYsGajgGlbmVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
// 查询关联部门
|
||||
List<TbYsGajgGlbmDto> glbmList = this.getGlbmList(item.getId());
|
||||
List<String> glbms = (glbmList != null && glbmList.size() != 0) ?
|
||||
glbmList.stream().map(TbYsGajgGlbmDto::getSsbmid).collect(Collectors.toList()) : new ArrayList<>();
|
||||
glbms.add(item.getSsbmid());
|
||||
vo.setGlbmSsbmdmList(glbms);
|
||||
voList.add(vo);
|
||||
});
|
||||
return voList;
|
||||
}
|
||||
|
||||
private void deleteGlbm(String id) {
|
||||
this.tbYsGajgGlbmMapper.deleteGlbm(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertEntity(TbYsGajgDto dto) {
|
||||
TbYsGajg gajg = new TbYsGajg();
|
||||
BeanUtils.copyProperties(dto, gajg);
|
||||
gajg.setId(UUIDGenerator.getUUID());
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
gajg.setZb(JtsUtils.getPoint(gajg.getJd(), gajg.getWd()));
|
||||
gajg.setZbhash(GeoHashKit.encode(gajg.getJd(), gajg.getWd()));
|
||||
}
|
||||
if (dto.getQy() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
}
|
||||
if (dto.getQy1() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy1();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm1(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
if (dto.getQy2() != null) {
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy2();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm2(JtsUtils.getPolygon(list));
|
||||
}
|
||||
}
|
||||
gajg.setJsnr(dto.getGajgmc() + " " + dto.getGajgjc() + " " + dto.getWzXz() + " " + dto.getWzBc());
|
||||
gajg.setXtSjly("1");
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmdm());
|
||||
if (dept != null) {
|
||||
gajg.setSsbm(dept.getDeptname());
|
||||
gajg.setSsbmid(dept.getDeptid());
|
||||
gajg.setSsbmdm(dept.getDeptcode());
|
||||
gajg.setSsxgajdm(dept.getFxjcode());
|
||||
gajg.setSsxgajid(dept.getFxjid());
|
||||
gajg.setSsxgaj(dept.getFxjname());
|
||||
gajg.setSssgaj(dept.getDszname());
|
||||
gajg.setSssgajdm(dept.getDszcode());
|
||||
gajg.setSssgajid(dept.getDszid());
|
||||
}
|
||||
return this.baseMapper.insertEntity(gajg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateEntity(TbYsGajgDto dto) {
|
||||
TbYsGajg gajg = new TbYsGajg();
|
||||
BeanUtils.copyProperties(dto, gajg);
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
gajg.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
gajg.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
// 一分钟范围
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
// 三分钟范围
|
||||
ArrayList<BigDecimal[]> list1 = new ArrayList<>();
|
||||
List<BigDecimal> qw1 = dto.getQy1();
|
||||
if (!CollectionUtils.isEmpty(qw1)) {
|
||||
for (int i = 0; i < qw1.size(); i++) {
|
||||
if (i != qw1.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw1.get(i);
|
||||
des[1] = qw1.get(i + 1);
|
||||
list1.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list1.size() > 0) {
|
||||
gajg.setDtm1(JtsUtils.getPolygon(list1));
|
||||
}
|
||||
// 三分钟范围
|
||||
ArrayList<BigDecimal[]> list2 = new ArrayList<>();
|
||||
List<BigDecimal> qw2 = dto.getQy1();
|
||||
if (!CollectionUtils.isEmpty(qw2)) {
|
||||
for (int i = 0; i < qw2.size(); i++) {
|
||||
if (i != qw2.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw2.get(i);
|
||||
des[1] = qw2.get(i + 1);
|
||||
list2.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list2.size() > 0) {
|
||||
gajg.setDtm2(JtsUtils.getPolygon(list2));
|
||||
}
|
||||
this.baseMapper.updateEntity(gajg);
|
||||
gajg = this.baseMapper.getInfoById(gajg.getId());
|
||||
gajg.setJsnr(gajg.getGajgmc() + " " + gajg.getGajgjc() + " " + gajg.getWzXz() + " " + gajg.getWzBc());
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByDeptId(dto.getSsbmid());
|
||||
if (dept != null) {
|
||||
gajg.setSsbm(dept.getDeptname());
|
||||
gajg.setSsbmid(dept.getDeptid());
|
||||
gajg.setSsbmdm(dept.getDeptcode());
|
||||
gajg.setSsxgajdm(dept.getFxjcode());
|
||||
gajg.setSsxgajid(dept.getFxjid());
|
||||
gajg.setSsxgaj(dept.getFxjname());
|
||||
gajg.setSssgaj(dept.getDszname());
|
||||
gajg.setSssgajdm(dept.getDszcode());
|
||||
gajg.setSssgajid(dept.getDszid());
|
||||
}
|
||||
this.baseMapper.updateEntity(gajg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateEntityByLY(TbYsGajgDto dto) {
|
||||
TbYsGajg gajg = this.baseMapper.selectOne(new LambdaQueryWrapper<TbYsGajg>()
|
||||
.eq(TbYsGajg::getLyid, dto.getLyid())
|
||||
.eq(TbYsGajg::getLybm, dto.getLybm()));
|
||||
dto.setId(gajg.getId());
|
||||
BeanUtils.copyProperties(dto, gajg);
|
||||
if (dto.getJd() != null && dto.getWd() != null) {
|
||||
gajg.setZb(JtsUtils.getPoint(dto.getJd(), dto.getWd()));
|
||||
gajg.setZbhash(GeoHashKit.encode(dto.getJd(), dto.getWd()));
|
||||
}
|
||||
// 一分钟圈层
|
||||
ArrayList<BigDecimal[]> list = new ArrayList<>();
|
||||
List<BigDecimal> qw = dto.getQy();
|
||||
if (!CollectionUtils.isEmpty(qw)) {
|
||||
for (int i = 0; i < qw.size(); i++) {
|
||||
if (i != qw.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw.get(i);
|
||||
des[1] = qw.get(i + 1);
|
||||
list.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list.size() > 0) {
|
||||
gajg.setDtm(JtsUtils.getPolygon(list));
|
||||
}
|
||||
// 三分钟圈层
|
||||
ArrayList<BigDecimal[]> list1 = new ArrayList<>();
|
||||
List<BigDecimal> qw1 = dto.getQy1();
|
||||
if (!CollectionUtils.isEmpty(qw1)) {
|
||||
for (int i = 0; i < qw1.size(); i++) {
|
||||
if (i != qw1.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw1.get(i);
|
||||
des[1] = qw1.get(i + 1);
|
||||
list1.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list1.size() > 0) {
|
||||
gajg.setDtm1(JtsUtils.getPolygon(list1));
|
||||
}
|
||||
// 五分钟圈层
|
||||
ArrayList<BigDecimal[]> list2 = new ArrayList<>();
|
||||
List<BigDecimal> qw2 = dto.getQy2();
|
||||
if (!CollectionUtils.isEmpty(qw2)) {
|
||||
for (int i = 0; i < qw2.size(); i++) {
|
||||
if (i != qw2.size() - 1 && i % 2 == 0) {
|
||||
BigDecimal[] des = new BigDecimal[2];
|
||||
des[0] = qw2.get(i);
|
||||
des[1] = qw2.get(i + 1);
|
||||
list2.add(des);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (list2.size() > 0) {
|
||||
gajg.setDtm2(JtsUtils.getPolygon(list2));
|
||||
}
|
||||
this.baseMapper.updateEntity(gajg);
|
||||
gajg = this.baseMapper.getInfoById(gajg.getId());
|
||||
gajg.setJsnr(gajg.getGajgmc() + " " + gajg.getGajgjc() + " " + gajg.getWzXz() + " " + gajg.getWzBc());
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmdm());
|
||||
if (dept != null) {
|
||||
gajg.setSsbm(dept.getDeptname());
|
||||
gajg.setSsbmid(dept.getDeptid());
|
||||
gajg.setSsbmdm(dept.getDeptcode());
|
||||
gajg.setSsxgajdm(dept.getFxjcode());
|
||||
gajg.setSsxgajid(dept.getFxjid());
|
||||
gajg.setSsxgaj(dept.getFxjname());
|
||||
gajg.setSssgaj(dept.getDszname());
|
||||
gajg.setSssgajdm(dept.getDszcode());
|
||||
gajg.setSssgajid(dept.getDszid());
|
||||
}
|
||||
this.baseMapper.updateEntity(gajg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsGajgVo getInfo(String id) {
|
||||
TbYsGajg item = this.baseMapper.getInfoById(id);
|
||||
TbYsGajgVo vo = null;
|
||||
if (item != null) {
|
||||
vo = new TbYsGajgVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
vo.setDtm(JtsUtils.decodePolygon(item.getDtm()));
|
||||
vo.setDtm1(JtsUtils.decodePolygon(item.getDtm1()));
|
||||
vo.setDtm2(JtsUtils.decodePolygon(item.getDtm2()));
|
||||
vo.setZb(new BigDecimal[]{item.getJd(), item.getWd()});
|
||||
vo.setGlbmDtoList(
|
||||
this.tbYsGajgGlbmMapper.selectList(
|
||||
new LambdaQueryWrapper<TbYsGajgGlbm>()
|
||||
.eq(TbYsGajgGlbm::getGajgId, vo.getId())
|
||||
.eq(TbYsGajgGlbm::getXtSjzt, "1")
|
||||
)
|
||||
);
|
||||
}
|
||||
return vo;
|
||||
}
|
||||
|
||||
@Override
|
||||
public IPage<TbYsGajgVo> getPageList(TbYsGajgQuery dto) {
|
||||
List<String> ysxlList = StringUtils.isEmpty(dto.getYsxl()) ? null : Arrays.asList(dto.getYsxl().split(","));
|
||||
IPage<TbYsGajgVo> page;
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
dto.setSsbmdm(this.tbBaseAdaptRemoteService.getSsbm(dto.getSsbmdm(), null));
|
||||
map.put("dto", dto);
|
||||
// UserInfo user = UserInfoManager.getUser();
|
||||
// String useSql = user != null ? PermissionsUtil.createSql("", user) : "";
|
||||
// map.put("useSql", useSql);
|
||||
map.put("ysxlList", ysxlList);
|
||||
if (dto.getPageNum() != null && dto.getPageSize() != null) {
|
||||
page = new Page<>(dto.getPageNum(), dto.getPageSize());
|
||||
map.put("pageIndex", (dto.getPageNum() - 1) * dto.getPageSize());
|
||||
map.put("pageSize", dto.getPageSize());
|
||||
int count = this.baseMapper.getCount(map);
|
||||
List<TbYsGajg> list = this.baseMapper.getListPage(map);
|
||||
List<TbYsGajgVo> voList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsGajgVo vo = new TbYsGajgVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
vo.setDtm(JtsUtils.decodePolygon(item.getDtm()));
|
||||
vo.setDtm1(JtsUtils.decodePolygon(item.getDtm1()));
|
||||
vo.setDtm2(JtsUtils.decodePolygon(item.getDtm2()));
|
||||
vo.setZb(new BigDecimal[]{item.getJd(), item.getWd()});
|
||||
voList.add(vo);
|
||||
});
|
||||
page.setTotal(count);
|
||||
page.setRecords(voList);
|
||||
} else {
|
||||
page = new Page<>();
|
||||
List<TbYsGajg> list = this.baseMapper.getList(map);
|
||||
List<TbYsGajgVo> voList = new ArrayList<>();
|
||||
list.forEach(item -> {
|
||||
TbYsGajgVo vo = new TbYsGajgVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
vo.setDtm(JtsUtils.decodePolygon(item.getDtm()));
|
||||
vo.setDtm1(JtsUtils.decodePolygon(item.getDtm1()));
|
||||
vo.setDtm2(JtsUtils.decodePolygon(item.getDtm2()));
|
||||
vo.setZb(new BigDecimal[]{item.getJd(), item.getWd()});
|
||||
voList.add(vo);
|
||||
});
|
||||
page.setRecords(voList);
|
||||
}
|
||||
return page;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delEntity(String id) {
|
||||
TbYsGajg item = this.baseMapper.getInfoById(id);
|
||||
if (item != null) {
|
||||
item.setXtScbz("1");
|
||||
}
|
||||
this.baseMapper.updateEntity(item);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delEntity(TbYsGajgDto dto) {
|
||||
TbYsGajg tbYsGajg = this.baseMapper.selectOne(new LambdaQueryWrapper<TbYsGajg>()
|
||||
.eq(TbYsGajg::getLyid, dto.getLyid())
|
||||
.eq(TbYsGajg::getLybm, dto.getLybm()));
|
||||
if (tbYsGajg != null) {
|
||||
tbYsGajg.setXtScbz("1");
|
||||
}
|
||||
this.baseMapper.updateEntity(tbYsGajg);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsGajgVo getGajgByJwd(TbYsGajgByJwdDto dto) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
TbYsGajgQuery query = new TbYsGajgQuery();
|
||||
query.setYsdl(dto.getYsdl());
|
||||
query.setYszl(dto.getYszl());
|
||||
query.setYsxl(dto.getYsxl());
|
||||
map.put("dto", query);
|
||||
List<TbYsGajg> list = this.baseMapper.getList(map);
|
||||
for (TbYsGajg item : list) {
|
||||
List<BigDecimal[]> jwdList = JtsUtils.decodePolygon(item.getDtm());
|
||||
Coordinate[] coordinates = new Coordinate[jwdList.size()];
|
||||
for (int i = 0; i < jwdList.size(); i++) {
|
||||
BigDecimal[] jwd = jwdList.get(i);
|
||||
Coordinate coor = new Coordinate();
|
||||
coor.x = jwd[0].doubleValue();
|
||||
coor.y = jwd[1].doubleValue();
|
||||
coordinates[i] = coor;
|
||||
}
|
||||
boolean flag = Kit.isInGeometry(coordinates, dto.getJd() + "," + dto.getWd());
|
||||
if (flag) {
|
||||
TbYsGajgVo vo = new TbYsGajgVo();
|
||||
BeanUtils.copyProperties(item, vo);
|
||||
return vo;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
@ -0,0 +1,134 @@
|
||||
package com.mosty.yszx.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mosty.base.model.dto.yszx.TbYsRyDto;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRy;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRyBq;
|
||||
import com.mosty.base.model.entity.yszx.TbYsRyDh;
|
||||
import com.mosty.base.model.vo.yszx.*;
|
||||
import com.mosty.yszx.mapper.TbYsRyBqMapper;
|
||||
import com.mosty.yszx.mapper.TbYsRyDhMapper;
|
||||
import com.mosty.yszx.mapper.TbYsRyMapper;
|
||||
import com.mosty.yszx.service.TbYsRyService;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@Service
|
||||
@AllArgsConstructor
|
||||
public class TbYsRyServiceImpl extends ServiceImpl<TbYsRyMapper, TbYsRy>
|
||||
implements TbYsRyService {
|
||||
|
||||
private final TbYsRyDhMapper tbYsRyDhMapper;
|
||||
private final TbYsRyBqMapper tbYsRyBqMapper;
|
||||
|
||||
@Override
|
||||
public TbYsRyVo getRyInfo(String sfzh) {
|
||||
TbYsRy ry = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsRy>()
|
||||
.eq(TbYsRy::getZjhm, sfzh)
|
||||
.eq(TbYsRy::getXtSjzt, "1")
|
||||
);
|
||||
if (ry != null) {
|
||||
TbYsRyVo vo = new TbYsRyVo();
|
||||
BeanUtils.copyProperties(ry, vo);
|
||||
// 查询人员电话
|
||||
List<TbYsRyDh> dhList = this.tbYsRyDhMapper.selectList(
|
||||
new LambdaQueryWrapper<TbYsRyDh>()
|
||||
.eq(TbYsRyDh::getRyid, ry.getId())
|
||||
.eq(TbYsRyDh::getXtSjzt, "1")
|
||||
);
|
||||
List<TbYsRyDhVo> dhVos = new ArrayList<>();
|
||||
dhList.forEach(dh -> {
|
||||
TbYsRyDhVo dhVo = new TbYsRyDhVo();
|
||||
BeanUtils.copyProperties(dh, dhVo);
|
||||
dhVos.add(dhVo);
|
||||
});
|
||||
vo.setDhList(dhVos);
|
||||
// 查询人员标签
|
||||
List<TbYsRyBq> bqList = this.tbYsRyBqMapper.selectList(
|
||||
new LambdaQueryWrapper<TbYsRyBq>()
|
||||
.eq(TbYsRyBq::getRyid, ry.getId())
|
||||
.eq(TbYsRyBq::getXtSjzt, "1")
|
||||
);
|
||||
List<TbYsRyBqVo> bqVos = new ArrayList<>();
|
||||
bqList.forEach(bq -> {
|
||||
TbYsRyBqVo bqVo = new TbYsRyBqVo();
|
||||
BeanUtils.copyProperties(bq, bqVo);
|
||||
bqVos.add(bqVo);
|
||||
});
|
||||
vo.setBqList(bqVos);
|
||||
return vo;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addRyYs(TbYsRyDto dto) {
|
||||
TbYsRy ry = new TbYsRy();
|
||||
BeanUtils.copyProperties(dto, ry);
|
||||
this.baseMapper.insert(ry);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateRyYs(TbYsRyDto dto) {
|
||||
TbYsRy ry = new TbYsRy();
|
||||
BeanUtils.copyProperties(dto, ry);
|
||||
this.baseMapper.updateById(ry);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateRyBqYs(TbYsRyBqUpdateDto dto) {
|
||||
TbYsRy ry = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsRy>()
|
||||
.eq(TbYsRy::getZjhm, dto.getSfzh())
|
||||
.eq(TbYsRy::getXtSjzt, "1")
|
||||
);
|
||||
if (ry != null) {
|
||||
// 删除人员标签(新加的数据)
|
||||
this.tbYsRyBqMapper.deleteByRyId(ry.getId());
|
||||
// 新增人员标签
|
||||
TbYsRyBq bq = new TbYsRyBq();
|
||||
bq.setRyid(ry.getId());
|
||||
bq.setZjzl("1");
|
||||
bq.setZjhm(ry.getZjhm());
|
||||
bq.setBqdm(dto.getBqdm());
|
||||
bq.setBqmc(dto.getBqmc());
|
||||
bq.setBqrq(new Date());
|
||||
bq.setXtSjly("1");
|
||||
this.tbYsRyBqMapper.insert(bq);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateRyDhys(TbYsRyDhUpdateDto dto) {
|
||||
TbYsRy ry = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsRy>()
|
||||
.eq(TbYsRy::getZjhm, dto.getSfzh())
|
||||
.eq(TbYsRy::getXtSjzt, "1")
|
||||
);
|
||||
if (ry != null) {
|
||||
// 删除人员电话(新加的数据)
|
||||
this.tbYsRyDhMapper.deleteByRyId(ry.getId());
|
||||
for (int i = 0; i < dto.getList().size(); i++) {
|
||||
Map<String, String> map = dto.getList().get(i);
|
||||
// 新增人员电话
|
||||
TbYsRyDh dh = new TbYsRyDh();
|
||||
dh.setRyid(ry.getId());
|
||||
dh.setZjzl("1");
|
||||
dh.setXm(ry.getXm());
|
||||
dh.setZjhm(ry.getZjhm());
|
||||
dh.setLxdh(map.get("lxdh"));
|
||||
dh.setImsi(map.get("imsi"));
|
||||
dh.setXtSjly("1");
|
||||
this.tbYsRyDhMapper.insert(dh);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,370 @@
|
||||
package com.mosty.yszx.service.impl;
|
||||
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.hikvision.artemis.sdk.ArtemisHttpUtil;
|
||||
import com.mosty.base.model.dto.sjzx.TbSjSpbfDTO;
|
||||
import com.mosty.base.model.dto.yszx.Cameras;
|
||||
import com.mosty.base.model.dto.yszx.TbYsSxtDto;
|
||||
import com.mosty.base.model.entity.lzother.ZhjmxfXfqwXfqyGzdw;
|
||||
import com.mosty.base.model.entity.yszx.TbYsGajg;
|
||||
import com.mosty.base.model.entity.yszx.TbYsSxt;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtNoPageQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtPageOneQuery;
|
||||
import com.mosty.base.model.query.yszx.TbYsSxtQuery;
|
||||
import com.mosty.base.model.vo.base.DeptInfoVo;
|
||||
import com.mosty.base.model.vo.yszx.TbYsGajgQuery;
|
||||
import com.mosty.base.utils.CameraPreviewUtil;
|
||||
import com.mosty.base.utils.UUIDGenerator;
|
||||
import com.mosty.yszx.mapper.TbYsGajgMapper;
|
||||
import com.mosty.yszx.mapper.TbYsSxtMapper;
|
||||
import com.mosty.yszx.remote.TbBaseAdaptRemoteService;
|
||||
import com.mosty.yszx.remote.TbSjzxAdaptRemoteService;
|
||||
import com.mosty.yszx.service.TbYsSxtService;
|
||||
import lombok.AllArgsConstructor;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
import org.springframework.util.StringUtils;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
|
||||
//import org.locationtech.jts.geom.Geometry;
|
||||
//import org.locationtech.jts.io.WKTReader;
|
||||
//import org.geotools.geometry.jts.JTSFactoryFinder;
|
||||
|
||||
/**
|
||||
* @author dw
|
||||
* @since 2022/7/19
|
||||
**/
|
||||
@Service
|
||||
@AllArgsConstructor
|
||||
public class TbYsSxtServiceImpl extends ServiceImpl<TbYsSxtMapper, TbYsSxt> implements TbYsSxtService {
|
||||
|
||||
private final TbSjzxAdaptRemoteService tbSjzxAdaptRemoteService;
|
||||
private final TbBaseAdaptRemoteService tbBaseAdaptRemoteService;
|
||||
private final TbYsGajgMapper tbYsGajgMapper;
|
||||
|
||||
@Override
|
||||
public int insertEntity(TbYsSxtDto dto) {
|
||||
TbYsSxt sxt = new TbYsSxt();
|
||||
BeanUtils.copyProperties(dto, sxt);
|
||||
sxt.setId(UUIDGenerator.getUUID());
|
||||
sxt.setJsnr(sxt.getSbbh() + " " + sxt.getSbmc() + " " + sxt.getCsmc() + " " + sxt.getDzmc());
|
||||
sxt.setXtSjly("1");
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmdm());
|
||||
if (dept != null) {
|
||||
sxt.setSsbmdm(dept.getDeptcode());
|
||||
sxt.setSsbmid(dept.getDeptid());
|
||||
sxt.setSsbm(dept.getDeptname());
|
||||
sxt.setSsxgaj(dept.getFxjname());
|
||||
sxt.setSsxgajid(dept.getFxjid());
|
||||
sxt.setSsxgajdm(dept.getFxjcode());
|
||||
sxt.setSssgaj(dept.getDszname());
|
||||
sxt.setSssgajid(dept.getDszid());
|
||||
sxt.setSssgajdm(dept.getDszid());
|
||||
}
|
||||
return this.baseMapper.insertEntity(sxt);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateEntity(TbYsSxtDto dto) {
|
||||
TbYsSxt sxt = new TbYsSxt();
|
||||
BeanUtils.copyProperties(dto, sxt);
|
||||
|
||||
this.baseMapper.updateEntity(sxt);
|
||||
sxt = this.baseMapper.getInfoById(sxt.getId());
|
||||
sxt.setJsnr(sxt.getSbbh() + " " + sxt.getSbmc() + " " + sxt.getCsmc() + " " + sxt.getDzmc());
|
||||
DeptInfoVo dept = this.tbBaseAdaptRemoteService.getOrgByOrgcode(dto.getSsbmdm());
|
||||
if (dept != null) {
|
||||
sxt.setSsbmdm(dept.getDeptid());
|
||||
sxt.setSsbm(dept.getDeptname());
|
||||
sxt.setSsxgaj(dept.getFxjname());
|
||||
sxt.setSsxgajdm(dept.getFxjid());
|
||||
sxt.setSssgaj(dept.getDszname());
|
||||
sxt.setSssgajdm(dept.getDszid());
|
||||
}
|
||||
this.baseMapper.updateEntity(sxt);
|
||||
}
|
||||
|
||||
@Override
|
||||
public IPage<TbYsSxt> getPageList(TbYsSxtQuery dto) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
dto.setSsbmdm(this.tbBaseAdaptRemoteService.getSsbm(dto.getSsbmdm(),null));
|
||||
map.put("pageIndex", (dto.getPageNum() - 1) * dto.getPageSize());
|
||||
map.put("pageSize", dto.getPageSize());
|
||||
map.put("dto", dto);
|
||||
|
||||
int count = this.baseMapper.getCount(map);
|
||||
List<TbYsSxt> list = this.baseMapper.getPageList(map);
|
||||
IPage<TbYsSxt> page = new Page<>(dto.getPageNum(), dto.getPageSize());
|
||||
page.setTotal(count);
|
||||
page.setRecords(list);
|
||||
return page;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsSxt> getList(TbYsSxtNoPageQuery dto) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
dto.setSsbmdm(this.tbBaseAdaptRemoteService.getSsbm(dto.getSsbmdm(),null));
|
||||
map.put("dto", dto);
|
||||
return this.baseMapper.getList(map);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsSxt getInfo(String id) {
|
||||
return this.baseMapper.getInfoById(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void delEntity(String id) {
|
||||
TbYsSxt sxt = this.baseMapper.getInfoById(id);
|
||||
if (sxt != null) {
|
||||
sxt.setXtScbz("1");
|
||||
this.baseMapper.updateEntity(sxt);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<TbYsSxt> getSjList(String jd, String wd, String sjid) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
map.put("jd", jd);
|
||||
map.put("wd", wd);
|
||||
List<TbYsSxt> tbYsSxt = this.baseMapper.getSjList(map);
|
||||
if (!CollectionUtils.isEmpty(tbYsSxt)) {
|
||||
for (TbYsSxt tb : tbYsSxt) {
|
||||
TbSjSpbfDTO tbSjSpbf = new TbSjSpbfDTO();
|
||||
tbSjSpbf.setId(UUIDGenerator.getUUID());
|
||||
tbSjSpbf.setSjId(sjid);
|
||||
tbSjSpbf.setSxtId(tb.getId());
|
||||
tbSjSpbf.setBfkssj(new Date());
|
||||
tbSjSpbf.setSsbm(tb.getSsbm());
|
||||
tbSjSpbf.setSsbmdm(tb.getSsbmdm());
|
||||
tbSjSpbf.setSsxgaj(tb.getSsxgaj());
|
||||
tbSjSpbf.setSsxgajdm(tb.getSsxgajdm());
|
||||
tbSjSpbf.setSssgaj(tb.getSssgaj());
|
||||
tbSjSpbf.setSssgajdm(tb.getSssgajdm());
|
||||
tbSjzxAdaptRemoteService.tbSjSpbfAdd(tbSjSpbf);
|
||||
}
|
||||
}
|
||||
return tbYsSxt;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int insertEntity(TbYsSxt sxt) {
|
||||
return this.baseMapper.insertEntity(sxt);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsSxt queryBySjlyid(String sjlyid) {
|
||||
return this.baseMapper.queryBySjlyid(sjlyid);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsSxtDto getInfoBySbbh(String sbbh) {
|
||||
TbYsSxt sxt = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsSxt>()
|
||||
.eq(TbYsSxt::getSbbh, sbbh)
|
||||
.last(" limit 1")
|
||||
);
|
||||
if (sxt != null) {
|
||||
TbYsSxtDto dto = new TbYsSxtDto();
|
||||
BeanUtils.copyProperties(sxt, dto);
|
||||
return dto;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<String> getSxtBhList(List<String> ids) {
|
||||
List<String> rList = new ArrayList<>();
|
||||
ids.forEach(id -> {
|
||||
TbYsSxt sxt = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsSxt>()
|
||||
.eq(TbYsSxt::getXtSjzt, "1")
|
||||
.eq(TbYsSxt::getSbbh, id)
|
||||
.last("limit 1")
|
||||
);
|
||||
if (sxt == null) {
|
||||
rList.add(id);
|
||||
}
|
||||
});
|
||||
return rList;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addLzGzy(ZhjmxfXfqwXfqyGzdw dto) {
|
||||
TbYsSxt sxt = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsSxt>()
|
||||
.eq(TbYsSxt::getXtSjzt, "1")
|
||||
.eq(TbYsSxt::getSbbh, dto.getSbbh())
|
||||
.last(" limit 1")
|
||||
);
|
||||
if (sxt != null) return;
|
||||
sxt = new TbYsSxt();
|
||||
sxt.setSjlyid(dto.getId());
|
||||
sxt.setJkdbgbh(dto.getSbbh());
|
||||
sxt.setSbbh(dto.getSbbh());
|
||||
sxt.setSbmc(dto.getSbmc());
|
||||
sxt.setCsmc(dto.getCsmc());
|
||||
sxt.setIpdz(dto.getIpdz());
|
||||
sxt.setIpv6dz(dto.getIpv6dz());
|
||||
sxt.setJd(dto.getDqjd());
|
||||
sxt.setWd(dto.getDqwd());
|
||||
sxt.setXzqhdm(dto.getAzddXzqhdm());
|
||||
sxt.setDzmc(StringUtils.isEmpty(dto.getAzddDzmc()) ? dto.getSbmc() : dto.getAzddDzmc());
|
||||
sxt.setSblxdm(dto.getGzsblxdm());
|
||||
sxt.setJsfxdm(dto.getJsfxdm());
|
||||
sxt.setJsqysm(dto.getJsqysm());
|
||||
sxt.setSxjwzlxdm(dto.getSxjwzlxdm());
|
||||
sxt.setSxjytdm(dto.getSxjytdm());
|
||||
sxt.setSbzt("1");
|
||||
sxt.setXtSjly("1");
|
||||
sxt.setSblx("01");
|
||||
sxt.setJsnr(sxt.getSbbh() + " " + sxt.getSbmc() + " " + sxt.getCsmc() + " " + sxt.getDzmc());
|
||||
sxt.setSsxgaj(dto.getSsfxjmc());
|
||||
sxt.setSsxgajdm(dto.getSsfxjdm());
|
||||
sxt.setSssgaj(dto.getSsdszmc());
|
||||
sxt.setSssgajdm(dto.getSsdszdm());
|
||||
// TODO 计算所属辖区位置
|
||||
this.baseMapper.insertEntity(sxt);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TbYsSxtDto selectGzy(TbYsSxtPageOneQuery dto) {
|
||||
TbYsSxt sxt = this.baseMapper.selectOne(
|
||||
new LambdaQueryWrapper<TbYsSxt>()
|
||||
.eq(TbYsSxt::getSbmc, dto.getSbmc())
|
||||
.eq(TbYsSxt::getJd, dto.getJd())
|
||||
.eq(TbYsSxt::getWd, dto.getWd())
|
||||
.eq(TbYsSxt::getXtSjzt, "1")
|
||||
.last(" limit 1")
|
||||
);
|
||||
if (sxt != null) {
|
||||
TbYsSxtDto vo = new TbYsSxtDto();
|
||||
BeanUtils.copyProperties(sxt, vo);
|
||||
return vo;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void updateJwd() {
|
||||
//获取经纬度为空为0数据
|
||||
LambdaQueryWrapper<TbYsSxt> wp = new LambdaQueryWrapper<>();
|
||||
wp.ne(TbYsSxt::getJd, 0).ne(TbYsSxt::getWd, 0);
|
||||
wp.notLike(TbYsSxt::getSsbm, "派出所").or(w -> w.isNull(TbYsSxt::getSsbm));
|
||||
List<TbYsSxt> tbYsSxts = this.baseMapper.selectList(wp);
|
||||
if (!CollectionUtils.isEmpty(tbYsSxts)) {
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
TbYsGajgQuery query = new TbYsGajgQuery();
|
||||
query.setGajgmc("派出所");
|
||||
map.put("dto", query);
|
||||
List<String> ysxlList = new ArrayList<String>() {{
|
||||
this.add("001001004");
|
||||
}};
|
||||
map.put("ysxlList", ysxlList);
|
||||
List<TbYsGajg> tbYsGajgs = this.tbYsGajgMapper.getList(map);
|
||||
// if (!CollectionUtils.isEmpty(tbYsGajgs)) {
|
||||
// for (TbYsSxt tb : tbYsSxts) {
|
||||
// if (tb.getJd() != null || tb.getWd() != null) {
|
||||
// for (TbYsGajg tbYsGajg : tbYsGajgs) {
|
||||
// if (!StringUtils.isEmpty(tbYsGajg.getDtm())) {
|
||||
// String wktPoly = tbYsGajg.getDtm().toString();
|
||||
// WKTReader reader = new WKTReader(JTSFactoryFinder.getGeometryFactory());
|
||||
// Geometry geometry;
|
||||
// try {
|
||||
// geometry = reader.read(wktPoly);
|
||||
// Geometry geometryOut = reader.read("POINT(" + tb.getJd() + " " + tb.getWd() + ")");
|
||||
// boolean isSsd = geometry.contains(geometryOut);
|
||||
// if (isSsd) {
|
||||
// tb.setSsbm(tbYsGajg.getGajgjc());
|
||||
// tb.setSsbmdm(tbYsGajg.getSsbmdm());
|
||||
// tb.setSsbmid(tbYsGajg.getSsbmid());
|
||||
// TbYsSxtDto dto = new TbYsSxtDto();
|
||||
// BeanUtils.copyProperties(tb, dto);
|
||||
// this.updateEntity(dto);
|
||||
// break;
|
||||
// }
|
||||
// } catch (Exception e) {
|
||||
// e.printStackTrace();
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void updateLzGzy() {
|
||||
this.baseMapper.deleteAll();
|
||||
saveGzy(1);
|
||||
|
||||
}
|
||||
|
||||
public void saveGzy(Integer pageNo) {
|
||||
final String getCamsApi = "/api/resource/v1/cameras";
|
||||
JSONObject jsonBody = new JSONObject();
|
||||
jsonBody.put("pageNo", pageNo);
|
||||
jsonBody.put("pageSize", 1000);
|
||||
jsonBody.put("treeCode", 0);
|
||||
String result = CameraPreviewUtil.getCameraPreviewURL(getCamsApi, jsonBody);// post请求application/json类型参数
|
||||
if (!StringUtils.isEmpty(result)) {
|
||||
Cameras cameras = JSONObject.parseObject(result, Cameras.class);
|
||||
if (cameras.getCode().equals("0") && cameras.getData() != null) {
|
||||
List<Cameras.listInfo> list = cameras.getData().getList();
|
||||
if (!CollectionUtils.isEmpty(list)) {
|
||||
list.forEach(v -> {
|
||||
if (!StringUtils.isEmpty(v.getCapabilitySetName()) && v.getCapabilitySetName().indexOf("Face") < 0) {
|
||||
// if (v.getStatus() == 1) {
|
||||
ZhjmxfXfqwXfqyGzdw entity = new ZhjmxfXfqwXfqyGzdw();
|
||||
entity.setId(UUIDGenerator.getUUID());
|
||||
entity.setSbbh(v.getGbIndexCode());
|
||||
entity.setSbmc(v.getName());
|
||||
entity.setCsmc("海康威视");
|
||||
entity.setDqjd(StringUtils.isEmpty(v.getLongitude()) ? null : new BigDecimal(v.getLongitude()));
|
||||
entity.setDqwd(StringUtils.isEmpty(v.getLatitude()) ? null : new BigDecimal(v.getLatitude()));
|
||||
// entity.setAzddDzmc(v.getName());
|
||||
entity.setGzsblxdm("01");
|
||||
entity.setCjsjlxdm("01");
|
||||
entity.setSxjytdm("1");
|
||||
entity.setSsdszmc("四川省雅安市公安局");
|
||||
entity.setSsdszdm("511800000000");
|
||||
entity.setSsstmc("四川省公安厅");
|
||||
entity.setSsstdm("510000000000");
|
||||
if (!StringUtils.isEmpty(v.getGbIndexCode()) && v.getGbIndexCode().length() >= 6) {
|
||||
String xzqh = v.getGbIndexCode().substring(0, 6);
|
||||
entity.setAzddXzqhdm(xzqh);
|
||||
switch (xzqh) {
|
||||
case "511825":
|
||||
entity.setSsfxjmc("四川省雅安市天全县公安局");
|
||||
entity.setSsfxjdm(xzqh + "000000");
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (!StringUtils.isEmpty(entity.getSsfxjmc())) {
|
||||
this.addLzGzy(entity);
|
||||
}
|
||||
// }
|
||||
}
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
}
|
||||
Integer page = (int) Math.ceil((double) cameras.getData().getTotal() / (double) cameras.getData().getPageSize());
|
||||
System.out.println(pageNo);
|
||||
if (page > pageNo) {
|
||||
this.saveGzy(pageNo + 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
75
mosty-yszx/src/main/resources/application.yml
Normal file
75
mosty-yszx/src/main/resources/application.yml
Normal file
@ -0,0 +1,75 @@
|
||||
ribbon:
|
||||
ReadTimeout: 600000
|
||||
ConnectTimeout: 600000
|
||||
spring:
|
||||
servlet:
|
||||
multipart:
|
||||
max-file-size: 100MB
|
||||
max-request-size: 100MB
|
||||
jackson:
|
||||
serialization:
|
||||
write-dates-as-timestamps: false
|
||||
# # 格式化返回时间 yyyy-MM-dd HH:mm:ss
|
||||
date-format: yyyy-MM-dd HH:mm:ss
|
||||
time-zone: GMT+8
|
||||
datasource:
|
||||
driver-class-name: com.mysql.jdbc.Driver
|
||||
url: jdbc:mysql://192.168.200.131:3306/mosty_yszx?autoReconnect=true&failOverReadOnly=false&useUnicode=true&characterEncoding=utf8&useSSL=false&allowMultiQueries=true&rewriteBatchedStatements=true&serverTimezone=Asia/Shanghai
|
||||
username: root
|
||||
password: mosty888
|
||||
hikari:
|
||||
minimum-idle: 10 # ??????????10???0???maximum-pool-size??????maximum-pool-size
|
||||
maximum-pool-size: 20 # ??????????0????????10??????1?????minimum-idle??
|
||||
idle-timeout: 500000 # ????????????600000?10????????max-lifetime?max-lifetime>0??????0????0???10???????10??
|
||||
max-lifetime: 540000 # ????????????0???30??????????30??.?????mysql????????
|
||||
connection-timeout: 60000 # ????????????250????????????30?
|
||||
connection-test-query: SELECT 1 # ???????????????
|
||||
# Redis数据库索引(默认为0)
|
||||
redis:
|
||||
database: 8
|
||||
# Redis服务器地址
|
||||
host: 192.168.200.131
|
||||
# Redis服务器连接端口
|
||||
port: 6379
|
||||
# Redis服务器连接密码(默认为空)
|
||||
password: mosty888
|
||||
# 连接超时时间(毫秒)
|
||||
timeout: 2000
|
||||
jedis:
|
||||
pool:
|
||||
max-active: 50
|
||||
|
||||
swagger:
|
||||
host: 80.155.0.84
|
||||
port: 8018
|
||||
|
||||
mybatis-plus:
|
||||
global-config:
|
||||
db-config:
|
||||
logic-delete-value: 1 # 逻辑已删除值(默认为 1)
|
||||
logic-not-delete-value: 0 # 逻辑未删除值(默认为 0)
|
||||
configuration:
|
||||
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||
|
||||
magic-api:
|
||||
web: /magic/web
|
||||
#配置文件存储位置。当以classpath开头时,为只读模式
|
||||
resource:
|
||||
# location: /data/magic-api
|
||||
type: database
|
||||
table-name: magic_api # 数据库中的表名
|
||||
prefix: /magic-api # 前缀
|
||||
datasource:
|
||||
response-code:
|
||||
success: 10000
|
||||
exclude:
|
||||
pathPatterns:
|
||||
swagger:
|
||||
- /swagger-resources/**
|
||||
- /webjars/**
|
||||
- /v2/**
|
||||
- /swagger-ui.html/**
|
||||
- /docs.html/**
|
||||
|
||||
config:
|
||||
orgCode: 510600000000
|
39
mosty-yszx/src/main/resources/bootstrap.yml
Normal file
39
mosty-yszx/src/main/resources/bootstrap.yml
Normal file
@ -0,0 +1,39 @@
|
||||
server:
|
||||
port: 8018
|
||||
servlet:
|
||||
context-path: /mosty-yszx/
|
||||
spring:
|
||||
application:
|
||||
name: mosty-yszx
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
namespace: 657d1843-b590-41ac-b5e7-5d261bf00de9
|
||||
server-addr: 192.168.200.131:8848
|
||||
register-enabled: true # 是否将自己注册到配置中心,让其他服务发现调用(本地调试使用)
|
||||
|
||||
|
||||
# 开启健康监控
|
||||
management:
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: '*'
|
||||
endpoint:
|
||||
health:
|
||||
show-details: always
|
||||
auditevents:
|
||||
enabled: true
|
||||
|
||||
#swagger:
|
||||
# enable: true
|
||||
# title: 基础微服务
|
||||
# version: 1.0.0
|
||||
# name: 基础微服务
|
||||
# url: ''
|
||||
# email: ''
|
||||
|
||||
# 日志
|
||||
#logging:
|
||||
# file: /application/applogs/admin.log
|
||||
|
114
mosty-yszx/src/main/resources/logback-spring.xml
Normal file
114
mosty-yszx/src/main/resources/logback-spring.xml
Normal file
@ -0,0 +1,114 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<configuration scan="true" scanPeriod="60 seconds" debug="false">
|
||||
<jmxConfigurator/>
|
||||
<property name="PROJECT_NAME" value="msxf-retail-sort" />
|
||||
<property name="LOG_FILE_INFO" value="${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}}/msxf-retail-sort-info.log" />
|
||||
<property name="LOG_FILE_WARN" value="${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}}/msxf-retail-sort-warn.log" />
|
||||
<property name="LOG_FILE_ERR" value="${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}}/msxf-retail-sort-error.log" />
|
||||
<property name="LOG_BUSINESS" value="${LOG_PATH:-${LOG_TEMP:-${java.io.tmpdir:-/tmp}}}/business/business-2de.log"/>
|
||||
<include resource="org/springframework/boot/logging/logback/defaults.xml" />
|
||||
<include resource="org/springframework/boot/logging/logback/console-appender.xml" />
|
||||
<contextName>${PROJECT_NAME}</contextName>
|
||||
|
||||
<appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} ${LOG_LEVEL_PATTERN:-%5p} ${PID:- } --- [%t] %-40.40logger{39} %m%n${LOG_EXCEPTION_CONVERSION_WORD:-%wEx}</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
|
||||
<appender name="LOG_FILE_INFO" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
|
||||
<level>INFO</level>
|
||||
</filter>
|
||||
<encoder>
|
||||
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} ${LOG_LEVEL_PATTERN:-%5p} ${PID:- } --- [%t] %-40.40logger{39} %m%n${LOG_EXCEPTION_CONVERSION_WORD:-%wEx}</pattern>
|
||||
</encoder>
|
||||
<file>${LOG_FILE_INFO}</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_FILE_INFO}-7de.%d{yyyy-MM-dd}.%i</fileNamePattern>
|
||||
<timeBasedFileNamingAndTriggeringPolicy
|
||||
class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
|
||||
<maxFileSize>1024MB</maxFileSize>
|
||||
</timeBasedFileNamingAndTriggeringPolicy>
|
||||
|
||||
</rollingPolicy>
|
||||
</appender>
|
||||
|
||||
<appender name="LOG_FILE_WARN"
|
||||
class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
|
||||
<level>WARN</level>
|
||||
</filter>
|
||||
<encoder>
|
||||
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} ${LOG_LEVEL_PATTERN:-%5p} ${PID:- } --- [%t] %-40.40logger{39} %m%n${LOG_EXCEPTION_CONVERSION_WORD:-%wEx}</pattern>
|
||||
</encoder>
|
||||
<file>${LOG_FILE_WARN}</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_FILE_WARN}-30de.%d{yyyy-MM-dd}.%i</fileNamePattern>
|
||||
<timeBasedFileNamingAndTriggeringPolicy
|
||||
class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
|
||||
<maxFileSize>1024MB</maxFileSize>
|
||||
</timeBasedFileNamingAndTriggeringPolicy>
|
||||
</rollingPolicy>
|
||||
</appender>
|
||||
|
||||
<appender name="LOG_FILE_ERROR"
|
||||
class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
|
||||
<level>ERROR</level>
|
||||
</filter>
|
||||
<encoder>
|
||||
<pattern>%d{yyyy-MM-dd HH:mm:ss.SSS} ${LOG_LEVEL_PATTERN:-%5p} ${PID:- } --- [%t] %-40.40logger{39} %m%n${LOG_EXCEPTION_CONVERSION_WORD:-%wEx}</pattern>
|
||||
</encoder>
|
||||
<file>${LOG_FILE_ERR}</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_FILE_ERR}.%d{yyyy-MM-dd}.%i</fileNamePattern>
|
||||
<timeBasedFileNamingAndTriggeringPolicy
|
||||
class="ch.qos.logback.core.rolling.SizeAndTimeBasedFNATP">
|
||||
<maxFileSize>512MB</maxFileSize>
|
||||
</timeBasedFileNamingAndTriggeringPolicy>
|
||||
</rollingPolicy>
|
||||
</appender>
|
||||
|
||||
<!--添加监控日志 -->
|
||||
<appender name="business-log-appender"
|
||||
class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
|
||||
<level>info</level>
|
||||
</filter>
|
||||
<file>${LOG_BUSINESS}</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_BUSINESS}.%d{yyyy-MM-dd}.%i
|
||||
</fileNamePattern>
|
||||
<maxFileSize>1024MB</maxFileSize>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>%msg%n</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<logger name="business-log" additivity="false" level="info">
|
||||
<appender-ref ref="business-log-appender"/>
|
||||
<appender-ref ref="CONSOLE" />
|
||||
</logger>
|
||||
<!-- show parameters for hibernate sql 专为 Hibernate 定制 -->
|
||||
<logger name="logging.level.jdbc" level="INFO" />
|
||||
<logger name="logging.level.jdbc.sqlonly" level="INFO" />
|
||||
<logger name="org.springframework" level="INFO" additivity="true" />
|
||||
<Logger name="jdbc.sqlonly" level="info" />
|
||||
<Logger name="jdbc.sqltiming" level="warn" />
|
||||
<Logger name="jdbc.audit" level="warn" />
|
||||
<Logger name="jdbc.resultset" level="warn" />
|
||||
<Logger name="jdbc.resultsettable" level="warn" />
|
||||
<logger name="jdbc.connection" level="warn" />
|
||||
<Logger name="log4jdbc.debug" level="warn" />
|
||||
<Logger name="org.apache.kafka.clients.NetworkClient" level="ERROR" />
|
||||
|
||||
<root level="INFO">
|
||||
<appender-ref ref="CONSOLE" />
|
||||
<!-- <appender-ref ref="LOG_FILE_INFO" />-->
|
||||
<appender-ref ref="LOG_FILE_WARN" />
|
||||
<appender-ref ref="LOG_FILE_ERROR" />
|
||||
</root>
|
||||
</configuration>
|
314
mosty-yszx/src/main/resources/mapper/TbYsDlMapper.xml
Normal file
314
mosty-yszx/src/main/resources/mapper/TbYsDlMapper.xml
Normal file
@ -0,0 +1,314 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsDlMapper">
|
||||
<resultMap type="com.mosty.base.model.entity.yszx.TbYsDl" id="TbYsDlMap">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="ysdl" column="ysdl" jdbcType="VARCHAR"/>
|
||||
<result property="yszl" column="yszl" jdbcType="VARCHAR"/>
|
||||
<result property="ysxl" column="ysxl" jdbcType="VARCHAR"/>
|
||||
<result property="ysmc" column="ysmc" jdbcType="VARCHAR"/>
|
||||
<result property="ysjc" column="ysjc" jdbcType="VARCHAR"/>
|
||||
<result property="yswzXzqh" column="yswz_xzqh" jdbcType="VARCHAR"/>
|
||||
<result property="yswzXz" column="yswz_xz" jdbcType="VARCHAR"/>
|
||||
<result property="yswzBc" column="yswz_bc" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="zb" column="zb" typeHandler="com.mosty.base.feign.handle.PointTypeHandler"/>
|
||||
<result property="zbhash" column="zbhash" jdbcType="VARCHAR"/>
|
||||
<result property="dtm" column="dtm" typeHandler="com.mosty.base.feign.handle.PolygonTypeHandler"/>
|
||||
<result property="znsbbs" column="znsbbs" jdbcType="VARCHAR"/>
|
||||
<result property="lybm" column="lybm" jdbcType="VARCHAR"/>
|
||||
<result property="lyid" column="lyid" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjly" column="xt_sjly" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjzt" column="xt_sjzt" jdbcType="VARCHAR"/>
|
||||
<result property="xtScbz" column="xt_scbz" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjip" column="xt_cjip" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjsj" column="xt_cjsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjrId" column="xt_cjr_id" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjr" column="xt_cjr" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmdm" column="xt_cjbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmmc" column="xt_cjbm" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxip" column="xt_zhgxip" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxsj" column="xt_zhgxsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxrid" column="xt_zhgxrid" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxr" column="xt_zhgxr" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbmdm" column="xt_zhgxbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbm" column="xt_zhgxbm" jdbcType="VARCHAR"/>
|
||||
<result property="bz" column="bz" jdbcType="VARCHAR"/>
|
||||
<result property="distance" column="distance" jdbcType="NUMERIC"/>
|
||||
<result property="sssgajid" column="sssgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajid" column="ssxgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmid" column="ssbmid" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="base_column_list">
|
||||
id
|
||||
,ysdl,yszl,ysxl,ysmc,ysjc,yswz_xzqh,yswz_xz,yswz_bc,jd,wd,zbhash,znsbbs,ssbmid,ssxgajid,sssgajid,
|
||||
lybm,lyid,jsnr,ssbm, ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly, xt_sjzt, xt_scbz,
|
||||
xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr, xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz
|
||||
</sql>
|
||||
|
||||
<sql id="zb_sql">
|
||||
ST_ASWKT
|
||||
(zb)
|
||||
as zb,ST_ASWKT(dtm) as dtm
|
||||
</sql>
|
||||
|
||||
<!--修改公安机关要素-->
|
||||
<update id="updateEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsDl">
|
||||
update tb_ys_dl
|
||||
<set>
|
||||
<if test="ysdl != null and ysdl != ''">
|
||||
ysdl = #{ysdl},
|
||||
</if>
|
||||
<if test="yszl != null and yszl != ''">
|
||||
yszl = #{yszl},
|
||||
</if>
|
||||
<if test="ysxl != null and ysxl != ''">
|
||||
ysxl = #{ysxl},
|
||||
</if>
|
||||
<if test="ysmc != null and ysmc != ''">
|
||||
ysmc = #{ysmc},
|
||||
</if>
|
||||
<if test="ysjc != null and ysjc != ''">
|
||||
ysjc = #{ysjc},
|
||||
</if>
|
||||
<if test="yswzXzqh != null and yswzXzqh != ''">
|
||||
yswz_xzqh = #{yswzXzqh},
|
||||
</if>
|
||||
<if test="yswzXz != null and yswzXz != ''">
|
||||
yswz_xz = #{yswzXz},
|
||||
</if>
|
||||
<if test="yswzBc != null and yswzBc != ''">
|
||||
yswz_bc = #{yswzBc},
|
||||
</if>
|
||||
<if test="jd != null">
|
||||
jd = #{jd},
|
||||
</if>
|
||||
<if test="wd != null">
|
||||
wd = #{wd},
|
||||
</if>
|
||||
<if test="zb != null">
|
||||
zb = ST_GEOMFROMTEXT(#{zb,typeHandler=com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
</if>
|
||||
<if test="zbhash != null and zbhash != ''">
|
||||
zbhash = #{zbhash},
|
||||
</if>
|
||||
<if test="dtm != null">
|
||||
dtm = ST_GEOMFROMTEXT(#{dtm,typeHandler=com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
</if>
|
||||
<if test="znsbbs != null and znsbbs != ''">
|
||||
znsbbs = #{znsbbs},
|
||||
</if>
|
||||
<if test="lybm != null and lybm != ''">
|
||||
lybm = #{lybm},
|
||||
</if>
|
||||
<if test="lyid != null and lyid != ''">
|
||||
lyid = #{lyid},
|
||||
</if>
|
||||
<if test="jsnr != null and jsnr != ''">
|
||||
jsnr = #{jsnr},
|
||||
</if>
|
||||
<if test="ssbm != null and ssbm != ''">
|
||||
ssbm = #{ssbm},
|
||||
</if>
|
||||
<if test="ssbmdm != null and ssbmdm != ''">
|
||||
ssbmdm = #{ssbmdm},
|
||||
</if>
|
||||
<if test="ssxgaj != null and ssxgaj != ''">
|
||||
ssxgaj = #{ssxgaj},
|
||||
</if>
|
||||
<if test="ssxgajdm != null and ssxgajdm != ''">
|
||||
ssxgajdm = #{ssxgajdm},
|
||||
</if>
|
||||
<if test="sssgaj != null and sssgaj != ''">
|
||||
sssgaj = #{sssgaj},
|
||||
</if>
|
||||
<if test="sssgajdm != null and sssgajdm != ''">
|
||||
sssgajdm = #{sssgajdm},
|
||||
</if>
|
||||
<if test="xtSjly != null and xtSjly != ''">
|
||||
xt_sjly = #{xtSjly},
|
||||
</if>
|
||||
<if test="xtSjzt != null and xtSjzt != ''">
|
||||
xt_sjzt = #{xtSjzt},
|
||||
</if>
|
||||
<if test="xtScbz != null and xtScbz != ''">
|
||||
xt_scbz = #{xtScbz},
|
||||
</if>
|
||||
<if test="xtCjip != null and xtCjip != ''">
|
||||
xt_cjip = #{xtCjip},
|
||||
</if>
|
||||
<if test="xtCjsj != null">
|
||||
xt_cjsj = #{xtCjsj},
|
||||
</if>
|
||||
<if test="xtCjrId != null and xtCjrId != ''">
|
||||
xt_cjr_id = #{xtCjrId},
|
||||
</if>
|
||||
<if test="xtCjr != null and xtCjr != ''">
|
||||
xt_cjr = #{xtCjr},
|
||||
</if>
|
||||
<if test="xtCjbmdm != null and xtCjbmdm != ''">
|
||||
xt_cjbmdm = #{xtCjbmdm},
|
||||
</if>
|
||||
<if test="xtCjbmmc != null and xtCjbmmc != ''">
|
||||
xt_cjbmmc = #{xtCjbmmc},
|
||||
</if>
|
||||
<if test="xtZhgxip != null and xtZhgxip != ''">
|
||||
xt_zhgxip = #{xtZhgxip},
|
||||
</if>
|
||||
<if test="xtZhgxsj != null">
|
||||
xt_zhgxsj = #{xtZhgxsj},
|
||||
</if>
|
||||
<if test="xtZhgxrid != null and xtZhgxrid != ''">
|
||||
xt_zhgxrid = #{xtZhgxrid},
|
||||
</if>
|
||||
<if test="xtZhgxr != null and xtZhgxr != ''">
|
||||
xt_zhgxr = #{xtZhgxr},
|
||||
</if>
|
||||
<if test="xtZhgxbmdm != null and xtZhgxbmdm != ''">
|
||||
xt_zhgxbmdm = #{xtZhgxbmdm},
|
||||
</if>
|
||||
<if test="xtZhgxbm != null and xtZhgxbm != ''">
|
||||
xt_zhgxbm = #{xtZhgxbm},
|
||||
</if>
|
||||
<if test="bz != null and bz != ''">
|
||||
bz = #{bz}
|
||||
</if>
|
||||
<if test="ssbmid != null and ssbmid != ''">
|
||||
ssbmid = #{ssbmid},
|
||||
</if>
|
||||
<if test="ssxgajid != null and ssxgajid != ''">
|
||||
ssxgajid = #{ssxgajid},
|
||||
</if>
|
||||
<if test="sssgajid != null and sssgajid != ''">
|
||||
sssgajid = #{sssgajid},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<!--新增地理要素-->
|
||||
<insert id="insertEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsDl">
|
||||
insert into tb_ys_dl
|
||||
(id, ysdl, yszl, ysxl, ysmc, ysjc, yswz_xzqh, yswz_xz, yswz_bc, jd, wd, zb, ssbmid, ssxgajid, sssgajid,
|
||||
zbhash, dtm, znsbbs, lybm, lyid, jsnr, ssbm, ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm,
|
||||
xt_sjly, xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id,
|
||||
xt_cjr, xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz)
|
||||
values (#{id}, #{ysdl}, #{yszl}, #{ysxl}, #{ysmc}, #{ysjc}, #{yswzXzqh}, #{yswzXz}, #{yswzBc}, #{jd}, #{wd},
|
||||
ST_GEOMFROMTEXT(#{zb,typeHandler = com.mosty.base.feign.handle.PointTypeHandler}), #{ssbmid},
|
||||
#{ssxgajid}, #{sssgajid},
|
||||
#{zbhash},
|
||||
ST_GEOMFROMTEXT(#{dtm,typeHandler = com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
#{znsbbs}, #{lybm}, #{lyid}, #{jsnr}, #{ssbm}, #{ssbmdm}, #{ssxgaj}, #{ssxgajdm},
|
||||
#{sssgaj}, #{sssgajdm}, #{xtSjly}, #{xtSjzt}, #{xtScbz}, #{xtCjip}, #{xtCjsj}, #{xtCjrId},
|
||||
#{xtCjr}, #{xtCjbmdm}, #{xtCjbmmc}, #{xtZhgxip}, #{xtZhgxsj}, #{xtZhgxrid},
|
||||
#{xtZhgxr}, #{xtZhgxbmdm}, #{xtZhgxbm}, #{bz})
|
||||
</insert>
|
||||
|
||||
<!--获取地理要素详情-->
|
||||
<select id="getInfoById" resultMap="TbYsDlMap">
|
||||
select
|
||||
<include refid="base_column_list"/>,
|
||||
<include refid="zb_sql"/>
|
||||
from tb_ys_dl where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and id = #{id}
|
||||
</select>
|
||||
|
||||
<select id="getCount" resultType="Integer" parameterType="Map">
|
||||
select count(1) from tb_ys_dl where xt_sjzt = '1' and xt_scbz = '0'
|
||||
<if test="dto.ysdl != null and dto.ysdl != ''">
|
||||
and ysdl = #{dto.ysdl}
|
||||
</if>
|
||||
<if test="dto.yszl != null and dto.yszl != ''">
|
||||
and yszl = #{dto.yszl}
|
||||
</if>
|
||||
<if test="dto.ysxl != null and dto.ysxl != ''">
|
||||
and ysxl = #{dto.ysxl}
|
||||
</if>
|
||||
<if test="dto.ysmc != null and dto.ysmc != ''">
|
||||
and ysmc like concat('%',#{dto.ysmc},'%')
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%',#{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[and st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) <= #{dto.radius}]]>
|
||||
</if>
|
||||
${useSql}
|
||||
</select>
|
||||
|
||||
<!--查询分页-->
|
||||
<select id="getPageList" parameterType="Map" resultMap="TbYsDlMap">
|
||||
select
|
||||
<include refid="base_column_list"/>,
|
||||
<include refid="zb_sql"/>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_dl where xt_sjzt = '1' and xt_scbz = '0'
|
||||
<if test="dto.ysdl != null and dto.ysdl != ''">
|
||||
and ysdl = #{dto.ysdl}
|
||||
</if>
|
||||
<if test="dto.yszl != null and dto.yszl != ''">
|
||||
and yszl = #{dto.yszl}
|
||||
</if>
|
||||
<if test="dto.ysxl != null and dto.ysxl != ''">
|
||||
and ysxl = #{dto.ysxl}
|
||||
</if>
|
||||
<if test="dto.ysmc != null and dto.ysmc != ''">
|
||||
and ysmc like concat('%',#{dto.ysmc},'%')
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%',#{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[having distance <= #{dto.radius}]]>
|
||||
</if>
|
||||
${useSql}
|
||||
order by xt_cjsj desc
|
||||
limit #{pageIndex},#{pageSize}
|
||||
</select>
|
||||
|
||||
<!--查询不分页-->
|
||||
<select id="getList" parameterType="Map" resultMap="TbYsDlMap">
|
||||
select
|
||||
<include refid="base_column_list"/>,
|
||||
<include refid="zb_sql"/>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_dl where xt_sjzt = '1' and xt_scbz = '0'
|
||||
<if test="dto.ysdl != null and dto.ysdl != ''">
|
||||
and ysdl = #{dto.ysdl}
|
||||
</if>
|
||||
<if test="dto.yszl != null and dto.yszl != ''">
|
||||
and yszl = #{dto.yszl}
|
||||
</if>
|
||||
<if test="dto.ysxl != null and dto.ysxl != ''">
|
||||
and ysxl = #{dto.ysxl}
|
||||
</if>
|
||||
<if test="dto.ysmc != null and dto.ysmc != ''">
|
||||
and ysmc like concat('%',#{dto.ysmc},'%')
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%',#{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[having distance <= #{dto.radius}]]>
|
||||
</if>
|
||||
${useSql}
|
||||
order by xt_cjsj desc
|
||||
</select>
|
||||
</mapper>
|
||||
|
||||
|
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsGajgGlbmMapper">
|
||||
|
||||
<delete id="deleteGlbm">
|
||||
delete from tb_ys_gajg_glbm where gajg_id = #{id}
|
||||
</delete>
|
||||
</mapper>
|
371
mosty-yszx/src/main/resources/mapper/TbYsGajgMapper.xml
Normal file
371
mosty-yszx/src/main/resources/mapper/TbYsGajgMapper.xml
Normal file
@ -0,0 +1,371 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsGajgMapper">
|
||||
<resultMap type="com.mosty.base.model.entity.yszx.TbYsGajg" id="tbYsGajg">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="ysdl" column="ysdl" jdbcType="VARCHAR"/>
|
||||
<result property="yszl" column="yszl" jdbcType="VARCHAR"/>
|
||||
<result property="ysxl" column="ysxl" jdbcType="VARCHAR"/>
|
||||
<result property="gajgmc" column="gajgmc" jdbcType="VARCHAR"/>
|
||||
<result property="gajgjc" column="gajgjc" jdbcType="VARCHAR"/>
|
||||
<result property="wzXzqh" column="wz_xzqh" jdbcType="VARCHAR"/>
|
||||
<result property="wzXz" column="wz_xz" jdbcType="VARCHAR"/>
|
||||
<result property="wzBc" column="wz_bc" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="zb" column="zb" typeHandler="com.mosty.base.feign.handle.PointTypeHandler"/>
|
||||
<result property="zbhash" column="zbhash" jdbcType="VARCHAR"/>
|
||||
<result property="dtm" column="dtm" typeHandler="com.mosty.base.feign.handle.PolygonTypeHandler"/>
|
||||
<result property="dtm1" column="dtm1" typeHandler="com.mosty.base.feign.handle.PolygonTypeHandler"/>
|
||||
<result property="dtm2" column="dtm2" typeHandler="com.mosty.base.feign.handle.PolygonTypeHandler"/>
|
||||
<result property="lybm" column="lybm" jdbcType="VARCHAR"/>
|
||||
<result property="lyid" column="lyid" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjly" column="xt_sjly" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjzt" column="xt_sjzt" jdbcType="VARCHAR"/>
|
||||
<result property="xtScbz" column="xt_scbz" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjip" column="xt_cjip" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjsj" column="xt_cjsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjrId" column="xt_cjr_id" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjr" column="xt_cjr" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmdm" column="xt_cjbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmmc" column="xt_cjbmmc" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxip" column="xt_zhgxip" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxsj" column="xt_zhgxsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxrid" column="xt_zhgxrid" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxr" column="xt_zhgxr" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbmdm" column="xt_zhgxbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbm" column="xt_zhgxbm" jdbcType="VARCHAR"/>
|
||||
<result property="bz" column="bz" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajid" column="sssgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajid" column="ssxgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmid" column="ssbmid" jdbcType="VARCHAR"/>
|
||||
<result property="color" column="color" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="base_column_list">
|
||||
|
||||
|
||||
id
|
||||
,ysdl,yszl,ysxl,gajgmc,gajgjc,wz_xzqh,wz_xz,wz_bc,jd,wd,ssbmid,ssxgajid,sssgajid,
|
||||
zbhash,lybm,lyid,jsnr,ssbm, ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly, xt_sjzt, xt_scbz,
|
||||
xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr, xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz, color
|
||||
|
||||
|
||||
</sql>
|
||||
|
||||
<sql id="zb_sql">
|
||||
|
||||
|
||||
ST_ASWKT
|
||||
(zb)
|
||||
as zb,
|
||||
ST_ASWKT(dtm) as dtm,
|
||||
ST_ASWKT(dtm1) as dtm1,
|
||||
ST_ASWKT(dtm2) as dtm2
|
||||
|
||||
|
||||
</sql>
|
||||
|
||||
<select id="getCount" resultType="Integer" parameterType="Map">
|
||||
select count(1) from tb_ys_gajg where xt_sjzt = '1' and xt_scbz = '0'
|
||||
<if test="dto.ysdl != null and dto.ysdl != ''">
|
||||
and ysdl = #{dto.ysdl}
|
||||
</if>
|
||||
<if test="dto.yszl != null and dto.yszl != ''">
|
||||
and yszl = #{dto.yszl}
|
||||
</if>
|
||||
<if test="ysxlList != null and ysxlList.size() != 0">
|
||||
and ysxl in
|
||||
<foreach collection="ysxlList" open="(" separator="," close=")" item="item">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%',#{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.gajgmc != null and dto.gajgmc != ''">
|
||||
and gajgmc like concat('%',#{dto.gajgmc},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.bz != null and dto.bz != ''">
|
||||
and bz like concat('%',#{dto.bz},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.ssbmdm != null and dto.ssbmdm != ''">
|
||||
and ssbmdm like concat(#{dto.ssbmdm,jdbcType=VARCHAR},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[and st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) <= #{dto.radius}]]>
|
||||
</if>
|
||||
<!-- ${useSql}-->
|
||||
</select>
|
||||
|
||||
<!--查询分页-->
|
||||
<select id="getListPage" parameterType="Map" resultMap="tbYsGajg">
|
||||
select
|
||||
<include refid="base_column_list"/>,
|
||||
<include refid="zb_sql"/>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_gajg where xt_sjzt = '1' and xt_scbz = '0'
|
||||
<if test="dto.ysdl != null and dto.ysdl != ''">
|
||||
and ysdl = #{dto.ysdl}
|
||||
</if>
|
||||
<if test="dto.yszl != null and dto.yszl != ''">
|
||||
and yszl = #{dto.yszl}
|
||||
</if>
|
||||
<if test="ysxlList != null and ysxlList.size() != 0">
|
||||
and ysxl in
|
||||
<foreach collection="ysxlList" open="(" separator="," close=")" item="item">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%',#{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.gajgmc != null and dto.gajgmc != ''">
|
||||
and gajgmc like concat('%',#{dto.gajgmc},'%')
|
||||
</if>
|
||||
<if test="dto.bz != null and dto.bz != ''">
|
||||
and bz like concat('%',#{dto.bz},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.ssbmdm != null and dto.ssbmdm != ''">
|
||||
and ssbmdm like concat(#{dto.ssbmdm,jdbcType=VARCHAR},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[having distance <= #{dto.radius}]]>
|
||||
</if>
|
||||
<!-- ${useSql}-->
|
||||
order by ysxl desc
|
||||
limit #{pageIndex},#{pageSize}
|
||||
</select>
|
||||
|
||||
<!--查询不分页-->
|
||||
<select id="getList" parameterType="Map" resultMap="tbYsGajg">
|
||||
select
|
||||
<include refid="base_column_list"/>,
|
||||
<include refid="zb_sql"/>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_gajg where xt_sjzt = '1' and xt_scbz = '0'
|
||||
<if test="dto.ysdl != null and dto.ysdl != ''">
|
||||
and ysdl = #{dto.ysdl}
|
||||
</if>
|
||||
<if test="dto.yszl != null and dto.yszl != ''">
|
||||
and yszl = #{dto.yszl}
|
||||
</if>
|
||||
<if test="ysxlList != null and ysxlList.size() != 0">
|
||||
and ysxl in
|
||||
<foreach collection="ysxlList" open="(" separator="," close=")" item="item">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%',#{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.gajgmc != null and dto.gajgmc != ''">
|
||||
and gajgmc like concat('%',#{dto.gajgmc},'%')
|
||||
</if>
|
||||
<if test="dto.bz != null and dto.bz != ''">
|
||||
and bz like concat('%',#{dto.bz},'%')
|
||||
</if>
|
||||
<if test="dto.ssbmdm != null and dto.ssbmdm != ''">
|
||||
and ssbmdm like concat(#{dto.ssbmdm,jdbcType=VARCHAR},'%')
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[having distance <= #{dto.radius}]]>
|
||||
</if>
|
||||
<!-- ${useSql}-->
|
||||
order by ssbmdm asc
|
||||
</select>
|
||||
|
||||
<!--修改公安机关要素-->
|
||||
<update id="updateEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsGajg">
|
||||
update tb_ys_gajg
|
||||
<set>
|
||||
<if test="ysdl != null and ysdl != ''">
|
||||
ysdl = #{ysdl},
|
||||
</if>
|
||||
<if test="yszl != null and yszl != ''">
|
||||
yszl = #{yszl},
|
||||
</if>
|
||||
<if test="ysxl != null and ysxl != ''">
|
||||
ysxl = #{ysxl},
|
||||
</if>
|
||||
<if test="gajgmc != null and gajgmc != ''">
|
||||
gajgmc = #{gajgmc},
|
||||
</if>
|
||||
<if test="gajgjc != null and gajgjc != ''">
|
||||
gajgjc = #{gajgjc},
|
||||
</if>
|
||||
<if test="wzXzqh != null and wzXzqh != ''">
|
||||
wz_xzqh = #{wzXzqh},
|
||||
</if>
|
||||
<if test="wzXz != null and wzXz != ''">
|
||||
wz_xz = #{wzXz},
|
||||
</if>
|
||||
<if test="wzBc != null and wzBc != ''">
|
||||
wz_bc = #{wzBc},
|
||||
</if>
|
||||
<if test="jd != null">
|
||||
jd = #{jd},
|
||||
</if>
|
||||
<if test="wd != null">
|
||||
wd = #{wd},
|
||||
</if>
|
||||
<if test="zb != null">
|
||||
zb = ST_GEOMFROMTEXT(#{zb,typeHandler=com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
</if>
|
||||
<if test="zbhash != null and zbhash != ''">
|
||||
zbhash = #{zbhash},
|
||||
</if>
|
||||
<if test="dtm != null">
|
||||
dtm = ST_GEOMFROMTEXT(#{dtm,typeHandler=com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
</if>
|
||||
<if test="dtm1 != null">
|
||||
dtm1 = ST_GEOMFROMTEXT(#{dtm1,typeHandler=com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
</if>
|
||||
<if test="dtm2 != null">
|
||||
dtm2 = ST_GEOMFROMTEXT(#{dtm2,typeHandler=com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
</if>
|
||||
<if test="lybm != null and lybm != ''">
|
||||
lybm = #{lybm},
|
||||
</if>
|
||||
<if test="lyid != null and lyid != ''">
|
||||
lyid = #{lyid},
|
||||
</if>
|
||||
<if test="jsnr != null and jsnr != ''">
|
||||
jsnr = #{jsnr},
|
||||
</if>
|
||||
<if test="ssbm != null and ssbm != ''">
|
||||
ssbm = #{ssbm},
|
||||
</if>
|
||||
<if test="ssbmdm != null and ssbmdm != ''">
|
||||
ssbmdm = #{ssbmdm},
|
||||
</if>
|
||||
<if test="ssxgaj != null and ssxgaj != ''">
|
||||
ssxgaj = #{ssxgaj},
|
||||
</if>
|
||||
<if test="ssxgajdm != null and ssxgajdm != ''">
|
||||
ssxgajdm = #{ssxgajdm},
|
||||
</if>
|
||||
<if test="ssbmid != null and ssbmid != ''">
|
||||
ssbmid = #{ssbmid},
|
||||
</if>
|
||||
<if test="ssxgajid != null and ssxgajid != ''">
|
||||
ssxgajid = #{ssxgajid},
|
||||
</if>
|
||||
<if test="sssgajid != null and sssgajid != ''">
|
||||
sssgajid = #{sssgajid},
|
||||
</if>
|
||||
<if test="sssgaj != null and sssgaj != ''">
|
||||
sssgaj = #{sssgaj},
|
||||
</if>
|
||||
<if test="sssgajdm != null and sssgajdm != ''">
|
||||
sssgajdm = #{sssgajdm},
|
||||
</if>
|
||||
<if test="xtSjly != null and xtSjly != ''">
|
||||
xt_sjly = #{xtSjly},
|
||||
</if>
|
||||
<if test="xtSjzt != null and xtSjzt != ''">
|
||||
xt_sjzt = #{xtSjzt},
|
||||
</if>
|
||||
<if test="xtScbz != null and xtScbz != ''">
|
||||
xt_scbz = #{xtScbz},
|
||||
</if>
|
||||
<if test="xtCjip != null and xtCjip != ''">
|
||||
xt_cjip = #{xtCjip},
|
||||
</if>
|
||||
<if test="xtCjsj != null">
|
||||
xt_cjsj = #{xtCjsj},
|
||||
</if>
|
||||
<if test="xtCjrId != null and xtCjrId != ''">
|
||||
xt_cjr_id = #{xtCjrId},
|
||||
</if>
|
||||
<if test="xtCjr != null and xtCjr != ''">
|
||||
xt_cjr = #{xtCjr},
|
||||
</if>
|
||||
<if test="xtCjbmdm != null and xtCjbmdm != ''">
|
||||
xt_cjbmdm = #{xtCjbmdm},
|
||||
</if>
|
||||
<if test="xtCjbmmc != null and xtCjbmmc != ''">
|
||||
xt_cjbmmc = #{xtCjbmmc},
|
||||
</if>
|
||||
<if test="xtZhgxip != null and xtZhgxip != ''">
|
||||
xt_zhgxip = #{xtZhgxip},
|
||||
</if>
|
||||
<if test="xtZhgxsj != null">
|
||||
xt_zhgxsj = #{xtZhgxsj},
|
||||
</if>
|
||||
<if test="xtZhgxrid != null and xtZhgxrid != ''">
|
||||
xt_zhgxrid = #{xtZhgxrid},
|
||||
</if>
|
||||
<if test="xtZhgxr != null and xtZhgxr != ''">
|
||||
xt_zhgxr = #{xtZhgxr},
|
||||
</if>
|
||||
<if test="xtZhgxbmdm != null and xtZhgxbmdm != ''">
|
||||
xt_zhgxbmdm = #{xtZhgxbmdm},
|
||||
</if>
|
||||
<if test="xtZhgxbm != null and xtZhgxbm != ''">
|
||||
xt_zhgxbm = #{xtZhgxbm},
|
||||
</if>
|
||||
<if test="color != null and color != ''">
|
||||
color = #{color},
|
||||
</if>
|
||||
<if test="bz != null and bz != ''">
|
||||
bz = #{bz}
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<!--获取公安机关详情-->
|
||||
<select id="getInfoById" resultMap="tbYsGajg">
|
||||
select
|
||||
<include refid="base_column_list"/>,
|
||||
<include refid="zb_sql"/>
|
||||
from tb_ys_gajg where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsGajg">
|
||||
|
||||
|
||||
insert into tb_ys_gajg
|
||||
(id, ysdl, yszl, ysxl, gajgmc, gajgjc, wz_xzqh, ssbmid, ssxgajid, sssgajid,
|
||||
wz_xz, wz_bc, jd, wd, zb, zbhash, dtm, dtm1, dtm2, lybm, lyid,
|
||||
jsnr, ssbm, ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm,
|
||||
xt_sjly, xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id,
|
||||
xt_cjr, xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz,color)
|
||||
values (#{id}, #{ysdl}, #{yszl}, #{ysxl}, #{gajgmc}, #{gajgjc}, #{wzXzqh}, #{ssbmid}, #{ssxgajid}, #{sssgajid},
|
||||
#{wzXz}, #{wzBc}, #{jd}, #{wd},
|
||||
ST_GEOMFROMTEXT(#{zb,typeHandler = com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
#{zbhash},
|
||||
ST_GEOMFROMTEXT(#{dtm,typeHandler = com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
ST_GEOMFROMTEXT(#{dtm1,typeHandler = com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
ST_GEOMFROMTEXT(#{dtm2,typeHandler = com.mosty.base.feign.handle.PolygonTypeHandler}),
|
||||
#{lybm}, #{lyid},
|
||||
#{jsnr}, #{ssbm}, #{ssbmdm}, #{ssxgaj}, #{ssxgajdm}, #{sssgaj}, #{sssgajdm},
|
||||
#{xtSjly}, #{xtSjzt}, #{xtScbz}, #{xtCjip}, #{xtCjsj}, #{xtCjrId},
|
||||
#{xtCjr}, #{xtCjbmdm}, #{xtCjbmmc}, #{xtZhgxip}, #{xtZhgxsj}, #{xtZhgxrid},
|
||||
#{xtZhgxr}, #{xtZhgxbmdm}, #{xtZhgxbm}, #{bz}, #{color})
|
||||
|
||||
|
||||
</insert>
|
||||
</mapper>
|
||||
|
||||
|
8
mosty-yszx/src/main/resources/mapper/TbYsRyBqMapper.xml
Normal file
8
mosty-yszx/src/main/resources/mapper/TbYsRyBqMapper.xml
Normal file
@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsRyBqMapper">
|
||||
|
||||
<delete id="deleteByRyId">
|
||||
delete from tb_ys_ry_bq where ryid = #{id}
|
||||
</delete>
|
||||
</mapper>
|
9
mosty-yszx/src/main/resources/mapper/TbYsRyDhMapper.xml
Normal file
9
mosty-yszx/src/main/resources/mapper/TbYsRyDhMapper.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsRyDhMapper">
|
||||
<delete id="deleteByRyId">
|
||||
delete
|
||||
from tb_ys_ry_dh
|
||||
where ryid = #{id}
|
||||
</delete>
|
||||
</mapper>
|
5
mosty-yszx/src/main/resources/mapper/TbYsRyMapper.xml
Normal file
5
mosty-yszx/src/main/resources/mapper/TbYsRyMapper.xml
Normal file
@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsRyMapper">
|
||||
|
||||
</mapper>
|
369
mosty-yszx/src/main/resources/mapper/TbYsSxtMapper.xml
Normal file
369
mosty-yszx/src/main/resources/mapper/TbYsSxtMapper.xml
Normal file
@ -0,0 +1,369 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsSxtMapper">
|
||||
<resultMap type="com.mosty.base.model.entity.yszx.TbYsSxt" id="tbYsSxt">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="sjlyid" column="sjlyid" jdbcType="VARCHAR"/>
|
||||
<result property="jkdbgbh" column="jkdbgbh" jdbcType="VARCHAR"/>
|
||||
<result property="sbbh" column="sbbh" jdbcType="VARCHAR"/>
|
||||
<result property="sbmc" column="sbmc" jdbcType="VARCHAR"/>
|
||||
<result property="csmc" column="csmc" jdbcType="VARCHAR"/>
|
||||
<result property="ipdz" column="ipdz" jdbcType="VARCHAR"/>
|
||||
<result property="ipv6dz" column="ipv6dz" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="xzqhdm" column="xzqhdm" jdbcType="VARCHAR"/>
|
||||
<result property="dzmc" column="dzmc" jdbcType="VARCHAR"/>
|
||||
<result property="sblxdm" column="sblxdm" jdbcType="VARCHAR"/>
|
||||
<result property="sjlxdm" column="sjlxdm" jdbcType="VARCHAR"/>
|
||||
<result property="jsfxdm" column="jsfxdm" jdbcType="VARCHAR"/>
|
||||
<result property="jsqysm" column="jsqysm" jdbcType="VARCHAR"/>
|
||||
<result property="sxjwzlxdm" column="sxjwzlxdm" jdbcType="VARCHAR"/>
|
||||
<result property="sxjytdm" column="sxjytdm" jdbcType="VARCHAR"/>
|
||||
<result property="sbzt" column="sbzt" jdbcType="VARCHAR"/>
|
||||
<result property="sblx" column="sblx" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajid" column="sssgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajid" column="ssxgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmid" column="ssbmid" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjly" column="xt_sjly" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjzt" column="xt_sjzt" jdbcType="VARCHAR"/>
|
||||
<result property="xtScbz" column="xt_scbz" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjip" column="xt_cjip" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjsj" column="xt_cjsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjrId" column="xt_cjr_id" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjr" column="xt_cjr" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmdm" column="xt_cjbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmmc" column="xt_cjbmmc" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxip" column="xt_zhgxip" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxsj" column="xt_zhgxsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxrid" column="xt_zhgxrid" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxr" column="xt_zhgxr" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbmdm" column="xt_zhgxbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbm" column="xt_zhgxbm" jdbcType="VARCHAR"/>
|
||||
<result property="bz" column="bz" jdbcType="VARCHAR"/>
|
||||
<result property="distance" column="distance" jdbcType="NUMERIC"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="base_column_list">
|
||||
|
||||
id
|
||||
,sjlyid, jkdbgbh,sbbh,sbmc,csmc,ipdz,ipv6dz,jd,wd,xzqhdm,dzmc,sblxdm,sjlxdm,jsfxdm,jsqysm,sxjwzlxdm,sxjytdm,
|
||||
sbzt,sblx,jsnr,ssbm, ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly, xt_sjzt, xt_scbz,
|
||||
xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr, xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz,ssbmid,ssxgajid,sssgajid
|
||||
|
||||
</sql>
|
||||
|
||||
|
||||
<!--查询摄像头列表总数-->
|
||||
<select id="getCount" resultType="Integer" parameterType="Map">
|
||||
select count(1) from tb_ys_sxt where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and jd is not null and wd is not null
|
||||
<if test="dto.sbbh != null and dto.sbbh != ''">
|
||||
and sbbh like concat('%',#{dto.sbbh},'%')
|
||||
</if>
|
||||
<if test="dto.sbmc != null and dto.sbmc != ''">
|
||||
and sbmc like concat('%',#{dto.sbmc},'%')
|
||||
</if>
|
||||
<if test="dto.sblxdm != null and dto.sblxdm != ''">
|
||||
and sblxdm = #{dto.sblxdm}
|
||||
</if>
|
||||
<if test="dto.sbzt != null and dto.sbzt != ''">
|
||||
and sbzt = #{dto.sbzt}
|
||||
</if>
|
||||
<if test="dto.sblx != null and dto.sblx != ''">
|
||||
and sblx = #{dto.sblx}
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%', #{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.ssbmdm != null and dto.ssbmdm != ''">
|
||||
and ssbmdm like concat(#{dto.ssbmdm},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[and st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) <= #{dto.radius}]]>
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<!--查询分页-->
|
||||
<select id="getPageList" parameterType="Map" resultMap="tbYsSxt">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
<if test="dto.jd != null and dto.wd != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_sxt where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and jd is not null and wd is not null
|
||||
<if test="dto.sbbh != null and dto.sbbh != ''">
|
||||
and sbbh like concat('%',#{dto.sbbh},'%')
|
||||
</if>
|
||||
<if test="dto.sbmc != null and dto.sbmc != ''">
|
||||
and sbmc like concat('%',#{dto.sbmc},'%')
|
||||
</if>
|
||||
<if test="dto.sblxdm != null and dto.sblxdm != ''">
|
||||
and sblxdm = #{dto.sblxdm}
|
||||
</if>
|
||||
<if test="dto.sbzt != null and dto.sbzt != ''">
|
||||
and sbzt = #{dto.sbzt}
|
||||
</if>
|
||||
<if test="dto.sblx != null and dto.sblx != ''">
|
||||
and sblx = #{dto.sblx}
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%', #{dto.jsnr},'%')
|
||||
</if>
|
||||
<if test="dto.ssbmdm != null and dto.ssbmdm != ''">
|
||||
and ssbmdm like concat(#{dto.ssbmdm},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[having distance <= #{dto.radius}]]>
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null ">
|
||||
order by distance asc
|
||||
</if>
|
||||
limit #{pageIndex},#{pageSize}
|
||||
</select>
|
||||
|
||||
<!--查询不分页-->
|
||||
<select id="getList" parameterType="Map" resultMap="tbYsSxt">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
<if test="dto.jd != null and dto.wd != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_sxt where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and jd is not null and wd is not null
|
||||
<if test="dto.sbbh != null and dto.sbbh != ''">
|
||||
and sbbh like concat('%',#{dto.sbbh},'%')
|
||||
</if>
|
||||
<if test="dto.sbmc != null and dto.sbmc != ''">
|
||||
and sbmc like concat('%',#{dto.sbmc},'%')
|
||||
</if>
|
||||
<if test="dto.sblxdm != null and dto.sblxdm != ''">
|
||||
and sblxdm = #{dto.sblxdm}
|
||||
</if>
|
||||
<if test="dto.sbzt != null and dto.sbzt != ''">
|
||||
and sbzt = #{dto.sbzt}
|
||||
</if>
|
||||
<if test="dto.sblx != null and dto.sblx != ''">
|
||||
and sblx = #{dto.sblx}
|
||||
</if>
|
||||
<if test="dto.jsnr != null and dto.jsnr != ''">
|
||||
and jsnr like concat('%', #{dto.jsnr},'%')
|
||||
</if>
|
||||
|
||||
<if test="dto.ssbmdm != null and dto.ssbmdm != ''">
|
||||
and ssbmdm like concat(#{dto.ssbmdm},'%')
|
||||
</if>
|
||||
|
||||
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[having distance <= #{dto.radius}]]>
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null">
|
||||
order by distance asc
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<!--获取公安机关详情-->
|
||||
<select id="getInfoById" resultMap="tbYsSxt">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
from tb_ys_sxt where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and id = #{id}
|
||||
</select>
|
||||
|
||||
<select id="queryBySjlyid" resultMap="tbYsSxt">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
from tb_ys_sxt where xt_sjzt = '1' and xt_scbz = '0'
|
||||
and sjlyid = #{sjlyid} limit 0,1
|
||||
</select>
|
||||
|
||||
<insert id="insertEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsSxt">
|
||||
|
||||
insert into tb_ys_sxt(id, sjlyid, jkdbgbh, sbbh, sbmc, csmc, ipdz, ipv6dz, jd, wd,
|
||||
xzqhdm, dzmc, sblxdm, sjlxdm, jsfxdm, jsqysm, sxjwzlxdm, sxjytdm, sbzt, sblx,
|
||||
jsnr, ssbm, ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly, xt_sjzt,
|
||||
xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr, xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj,
|
||||
xt_zhgxrid, xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm,
|
||||
bz,ssbmid,ssxgajid,sssgajid)
|
||||
values (#{id}, #{sjlyid}, #{jkdbgbh}, #{sbbh}, #{sbmc}, #{csmc}, #{ipdz}, #{ipv6dz}, #{jd}, #{wd},
|
||||
#{xzqhdm},
|
||||
#{dzmc}, #{sblxdm}, #{sjlxdm}, #{jsfxdm}, #{jsqysm}, #{sxjwzlxdm}, #{sxjytdm}, #{sbzt}, #{sblx},
|
||||
#{jsnr}, #{ssbm}, #{ssbmdm}, #{ssxgaj}, #{ssxgajdm}, #{sssgaj}, #{sssgajdm}, #{xtSjly}, #{xtSjzt},
|
||||
#{xtScbz}, #{xtCjip}, #{xtCjsj}, #{xtCjrId}, #{xtCjr}, #{xtCjbmdm}, #{xtCjbmmc}, #{xtZhgxip},
|
||||
#{xtZhgxsj},
|
||||
#{xtZhgxrid}, #{xtZhgxr}, #{xtZhgxbmdm}, #{xtZhgxbm}, #{bz},#{ssbmid},#{ssxgajid},#{sssgajid})
|
||||
|
||||
</insert>
|
||||
|
||||
<!--修改公安机关要素-->
|
||||
<update id="updateEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsSxt">
|
||||
update tb_ys_sxt
|
||||
<set>
|
||||
<if test="sjlyid != null and sjlyid != ''">
|
||||
sjlyid = #{sjlyid},
|
||||
</if>
|
||||
<if test="jkdbgbh != null and jkdbgbh != ''">
|
||||
jkdbgbh = #{jkdbgbh},
|
||||
</if>
|
||||
<if test="sbbh != null and sbbh != ''">
|
||||
sbbh = #{sbbh},
|
||||
</if>
|
||||
<if test="sbmc != null and sbmc != ''">
|
||||
sbmc = #{sbmc},
|
||||
</if>
|
||||
<if test="csmc != null and csmc != ''">
|
||||
csmc = #{csmc},
|
||||
</if>
|
||||
<if test="ipdz != null and ipdz != ''">
|
||||
ipdz = #{ipdz},
|
||||
</if>
|
||||
<if test="ipv6dz != null and ipv6dz != ''">
|
||||
ipv6dz = #{ipv6dz},
|
||||
</if>
|
||||
<if test="jd != null">
|
||||
jd = #{jd},
|
||||
</if>
|
||||
<if test="wd != null">
|
||||
wd = #{wd},
|
||||
</if>
|
||||
<if test="xzqhdm != null and xzqhdm != ''">
|
||||
xzqhdm = #{xzqhdm},
|
||||
</if>
|
||||
<if test="dzmc != null and dzmc != ''">
|
||||
dzmc = #{dzmc},
|
||||
</if>
|
||||
<if test="sblxdm != null and sblxdm != ''">
|
||||
sblxdm = #{sblxdm},
|
||||
</if>
|
||||
<if test="sjlxdm != null and sjlxdm != ''">
|
||||
sjlxdm = #{sjlxdm},
|
||||
</if>
|
||||
<if test="jsfxdm != null and jsfxdm != ''">
|
||||
jsfxdm = #{jsfxdm},
|
||||
</if>
|
||||
<if test="jsqysm != null and jsqysm != ''">
|
||||
jsqysm = #{jsqysm},
|
||||
</if>
|
||||
<if test="sxjwzlxdm != null and sxjwzlxdm != ''">
|
||||
sxjwzlxdm = #{sxjwzlxdm},
|
||||
</if>
|
||||
<if test="sxjytdm != null and sxjytdm != ''">
|
||||
sxjytdm = #{sxjytdm},
|
||||
</if>
|
||||
<if test="sbzt != null and sbzt != ''">
|
||||
sbzt = #{sbzt},
|
||||
</if>
|
||||
<if test="sblx != null and sblx != ''">
|
||||
sblx = #{sblx},
|
||||
</if>
|
||||
<if test="jsnr != null and jsnr != ''">
|
||||
jsnr = #{jsnr},
|
||||
</if>
|
||||
<if test="ssbm != null and ssbm != ''">
|
||||
ssbm = #{ssbm},
|
||||
</if>
|
||||
<if test="ssbmdm != null and ssbmdm != ''">
|
||||
ssbmdm = #{ssbmdm},
|
||||
</if>
|
||||
<if test="ssxgaj != null and ssxgaj != ''">
|
||||
ssxgaj = #{ssxgaj},
|
||||
</if>
|
||||
<if test="ssxgajdm != null and ssxgajdm != ''">
|
||||
ssxgajdm = #{ssxgajdm},
|
||||
</if>
|
||||
<if test="sssgaj != null and sssgaj != ''">
|
||||
sssgaj = #{sssgaj},
|
||||
</if>
|
||||
<if test="sssgajdm != null and sssgajdm != ''">
|
||||
sssgajdm = #{sssgajdm},
|
||||
</if>
|
||||
<if test="ssbmid != null and ssbmid != ''">
|
||||
ssbmid = #{ssbmid},
|
||||
</if>
|
||||
<if test="ssxgajid != null and ssxgajid != ''">
|
||||
ssxgajid = #{ssxgajid},
|
||||
</if>
|
||||
<if test="sssgajid != null and sssgajid != ''">
|
||||
sssgajid = #{sssgajid},
|
||||
</if>
|
||||
<if test="xtSjly != null and xtSjly != ''">
|
||||
xt_sjly = #{xtSjly},
|
||||
</if>
|
||||
<if test="xtSjzt != null and xtSjzt != ''">
|
||||
xt_sjzt = #{xtSjzt},
|
||||
</if>
|
||||
<if test="xtScbz != null and xtScbz != ''">
|
||||
xt_scbz = #{xtScbz},
|
||||
</if>
|
||||
<if test="xtCjip != null and xtCjip != ''">
|
||||
xt_cjip = #{xtCjip},
|
||||
</if>
|
||||
<if test="xtCjsj != null">
|
||||
xt_cjsj = #{xtCjsj},
|
||||
</if>
|
||||
<if test="xtCjrId != null and xtCjrId != ''">
|
||||
xt_cjr_id = #{xtCjrId},
|
||||
</if>
|
||||
<if test="xtCjr != null and xtCjr != ''">
|
||||
xt_cjr = #{xtCjr},
|
||||
</if>
|
||||
<if test="xtCjbmdm != null and xtCjbmdm != ''">
|
||||
xt_cjbmdm = #{xtCjbmdm},
|
||||
</if>
|
||||
<if test="xtCjbmmc != null and xtCjbmmc != ''">
|
||||
xt_cjbmmc = #{xtCjbmmc},
|
||||
</if>
|
||||
<if test="xtZhgxip != null and xtZhgxip != ''">
|
||||
xt_zhgxip = #{xtZhgxip},
|
||||
</if>
|
||||
<if test="xtZhgxsj != null">
|
||||
xt_zhgxsj = #{xtZhgxsj},
|
||||
</if>
|
||||
<if test="xtZhgxrid != null and xtZhgxrid != ''">
|
||||
xt_zhgxrid = #{xtZhgxrid},
|
||||
</if>
|
||||
<if test="xtZhgxr != null and xtZhgxr != ''">
|
||||
xt_zhgxr = #{xtZhgxr},
|
||||
</if>
|
||||
<if test="xtZhgxbmdm != null and xtZhgxbmdm != ''">
|
||||
xt_zhgxbmdm = #{xtZhgxbmdm},
|
||||
</if>
|
||||
<if test="xtZhgxbm != null and xtZhgxbm != ''">
|
||||
xt_zhgxbm = #{xtZhgxbm},
|
||||
</if>
|
||||
<if test="bz != null and bz != ''">
|
||||
bz = #{bz}
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<select id="getSjList" parameterType="Map" resultMap="tbYsSxt">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
<if test="jd != null and wd != null ">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{jd},#{wd})) as distance
|
||||
</if>
|
||||
from tb_ys_sxt where xt_sjzt = '1' and xt_scbz = '0'
|
||||
order by distance asc
|
||||
limit 0,3
|
||||
</select>
|
||||
|
||||
<delete id="deleteAll">
|
||||
delete from tb_ys_sxt
|
||||
</delete>
|
||||
</mapper>
|
||||
|
||||
|
259
mosty-yszx/src/main/resources/mapper/TbYsXsajMapper.xml
Normal file
259
mosty-yszx/src/main/resources/mapper/TbYsXsajMapper.xml
Normal file
@ -0,0 +1,259 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsXsajMapper">
|
||||
|
||||
<resultMap type="com.mosty.base.model.vo.yszx.TbYsAjVo" id="tbYsAjVo">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="sjlyid" column="sjlyid" jdbcType="VARCHAR"/>
|
||||
<result property="ajbh" column="ajbh" jdbcType="VARCHAR"/>
|
||||
<result property="ajmc" column="ajmc" jdbcType="VARCHAR"/>
|
||||
<result property="ajnr" column="ajnr" jdbcType="VARCHAR"/>
|
||||
<result property="farq" column="farq" jdbcType="TIMESTAMP"/>
|
||||
<result property="fasj" column="fasj" jdbcType="TIMESTAMP"/>
|
||||
<result property="ajlb" column="ajlb" jdbcType="VARCHAR"/>
|
||||
<result property="aymc" column="aymc" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="xzqhdm" column="xzqhdm" jdbcType="VARCHAR"/>
|
||||
<result property="dzmc" column="dzmc" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="distance" column="distance" jdbcType="NUMERIC"/>
|
||||
</resultMap>
|
||||
|
||||
<!--行事案件-->
|
||||
<resultMap type="com.mosty.base.model.entity.yszx.TbYsXsaj" id="tbYsXsaj">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="sjlyid" column="sjlyid" jdbcType="VARCHAR"/>
|
||||
<result property="ajbh" column="ajbh" jdbcType="VARCHAR"/>
|
||||
<result property="ajmc" column="ajmc" jdbcType="VARCHAR"/>
|
||||
<result property="ajnr" column="ajnr" jdbcType="VARCHAR"/>
|
||||
<result property="farq" column="farq" jdbcType="TIMESTAMP"/>
|
||||
<result property="fasj" column="fasj" jdbcType="TIMESTAMP"/>
|
||||
<result property="ajlb" column="ajlb" jdbcType="VARCHAR"/>
|
||||
<result property="aymc" column="aymc" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="zb" column="zb" typeHandler="com.mosty.base.feign.handle.PointTypeHandler"/>
|
||||
<result property="zbhash" column="zbhash" jdbcType="VARCHAR"/>
|
||||
<result property="xzqhdm" column="xzqhdm" jdbcType="VARCHAR"/>
|
||||
<result property="dzmc" column="dzmc" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjly" column="xt_sjly" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjzt" column="xt_sjzt" jdbcType="VARCHAR"/>
|
||||
<result property="xtScbz" column="xt_scbz" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjip" column="xt_cjip" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjsj" column="xt_cjsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjrId" column="xt_cjr_id" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjr" column="xt_cjr" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmdm" column="xt_cjbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmmc" column="xt_cjbmmc" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxip" column="xt_zhgxip" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxsj" column="xt_zhgxsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxrid" column="xt_zhgxrid" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxr" column="xt_zhgxr" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbmdm" column="xt_zhgxbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbm" column="xt_zhgxbm" jdbcType="VARCHAR"/>
|
||||
<result property="bz" column="bz" jdbcType="VARCHAR"/>
|
||||
<result property="distance" column="distance" jdbcType="NUMERIC"/>
|
||||
<result property="sssgajid" column="sssgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajid" column="ssxgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmid" column="ssbmid" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="base_column_list">
|
||||
id
|
||||
, ajfl, sjlyid, ajbh, ajmc, ajnr, farq, fasj,ssbmid,ssxgajid,sssgajid,
|
||||
ajlb, aymc, jd, wd, zbhash, xzqhdm, dzmc, jsnr, ssbm,
|
||||
ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly,
|
||||
xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr,
|
||||
xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz
|
||||
</sql>
|
||||
|
||||
<sql id="base_column">
|
||||
id
|
||||
, sjlyid, ajbh, ajmc, ajnr, farq, fasj,ssbmid,ssxgajid,sssgajid,
|
||||
ajlb, aymc, jd, wd, zbhash, xzqhdm, dzmc, jsnr, ssbm,
|
||||
ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly,
|
||||
xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr,
|
||||
xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz
|
||||
</sql>
|
||||
|
||||
<sql id="blob_column_List">
|
||||
ST_ASWKT
|
||||
(zb) as zb
|
||||
</sql>
|
||||
|
||||
|
||||
<!--新增行事案件-->
|
||||
<insert id="insertXsaj" parameterType="com.mosty.base.model.entity.yszx.TbYsXsaj">
|
||||
insert into tb_ys_xsaj
|
||||
(id, sjlyid, ajbh, ajmc, ajnr, farq, fasj,ssbmid,ssxgajid,sssgajid,
|
||||
ajlb, aymc, jd, wd, zb, zbhash, xzqhdm, dzmc, jsnr, ssbm,
|
||||
ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly,
|
||||
xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr,
|
||||
xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz)
|
||||
values (#{id}, #{sjlyid}, #{ajbh}, #{ajmc}, #{ajnr}, #{farq}, #{fasj},#{ssbmid},#{ssxgajid},#{sssgajid},
|
||||
#{ajlb}, #{aymc}, #{jd}, #{wd},
|
||||
ST_GEOMFROMTEXT(#{zb,typeHandler=com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
#{zbhash}, #{xzqhdm}, #{dzmc}, #{jsnr}, #{ssbm},
|
||||
#{ssbmdm}, #{ssxgaj}, #{ssxgajdm}, #{sssgaj}, #{sssgajdm}, #{xtSjly},
|
||||
#{xtSjzt}, #{xtScbz}, #{xtCjip}, #{xtCjsj}, #{xtCjrId}, #{xtCjr},
|
||||
#{xtCjbmdm}, #{xtCjbmmc}, #{xtZhgxip}, #{xtZhgxsj}, #{xtZhgxrid},
|
||||
#{xtZhgxr}, #{xtZhgxbmdm}, #{xtZhgxbm}, #{bz})
|
||||
</insert>
|
||||
|
||||
|
||||
<!--查询刑事案件详情-->
|
||||
<select id="selectXsAjById" resultMap="tbYsXsaj">
|
||||
select
|
||||
<include refid="base_column"/>
|
||||
from tb_ys_xsaj
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
|
||||
<!--修改行事案件-->
|
||||
<update id="updateXsEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsXsaj">
|
||||
update tb_ys_xsaj
|
||||
<set>
|
||||
<if test="sjlyid != null and sjlyid != ''">
|
||||
sjlyid = #{sjlyid},
|
||||
</if>
|
||||
<if test="ajbh != null and ajbh != ''">
|
||||
ajbh = #{ajbh},
|
||||
</if>
|
||||
<if test="ajmc != null and ajmc != ''">
|
||||
ajmc = #{ajmc},
|
||||
</if>
|
||||
<if test="ajnr != null and ajnr != ''">
|
||||
ajnr = #{ajnr},
|
||||
</if>
|
||||
<if test="farq != null">
|
||||
farq = #{farq},
|
||||
</if>
|
||||
<if test="fasj != null">
|
||||
fasj = #{fasj},
|
||||
</if>
|
||||
<if test="ajlb != null and ajlb != ''">
|
||||
ajlb = #{ajlb},
|
||||
</if>
|
||||
<if test="aymc != null and aymc != ''">
|
||||
aymc = #{aymc},
|
||||
</if>
|
||||
<if test="jd != null">
|
||||
jd = #{jd},
|
||||
</if>
|
||||
<if test="wd != null">
|
||||
wd = #{wd},
|
||||
</if>
|
||||
<if test="zb != null">
|
||||
zb = ST_GEOMFROMTEXT(#{zb,typeHandler=com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
</if>
|
||||
<if test="zbhash != null and zbhash != ''">
|
||||
zbhash = #{zbhash},
|
||||
</if>
|
||||
<if test="xzqhdm != null and xzqhdm != ''">
|
||||
xzqhdm = #{xzqhdm},
|
||||
</if>
|
||||
<if test="dzmc != null and dzmc != ''">
|
||||
dzmc = #{dzmc},
|
||||
</if>
|
||||
<if test="jsnr != null and jsnr != ''">
|
||||
jsnr = #{jsnr},
|
||||
</if>
|
||||
<if test="ssbm != null and ssbm != ''">
|
||||
ssbm = #{ssbm},
|
||||
</if>
|
||||
<if test="ssbmdm != null and ssbmdm != ''">
|
||||
ssbmdm = #{ssbmdm},
|
||||
</if>
|
||||
<if test="ssxgaj != null and ssxgaj != ''">
|
||||
ssxgaj = #{ssxgaj},
|
||||
</if>
|
||||
<if test="ssxgajdm != null and ssxgajdm != ''">
|
||||
ssxgajdm = #{ssxgajdm},
|
||||
</if>
|
||||
<if test="sssgaj != null and sssgaj != ''">
|
||||
sssgaj = #{sssgaj},
|
||||
</if>
|
||||
<if test="sssgajdm != null and sssgajdm != ''">
|
||||
sssgajdm = #{sssgajdm},
|
||||
</if>
|
||||
<if test="xtSjly != null and xtSjly != ''">
|
||||
xt_sjly = #{xtSjly},
|
||||
</if>
|
||||
<if test="xtSjzt != null and xtSjzt != ''">
|
||||
xt_sjzt = #{xtSjzt},
|
||||
</if>
|
||||
<if test="xtScbz != null and xtScbz != ''">
|
||||
xt_scbz = #{xtScbz},
|
||||
</if>
|
||||
<if test="xtCjip != null and xtCjip != ''">
|
||||
xt_cjip = #{xtCjip},
|
||||
</if>
|
||||
<if test="xtCjsj != null">
|
||||
xt_cjsj = #{xtCjsj},
|
||||
</if>
|
||||
<if test="xtCjrId != null and xtCjrId != ''">
|
||||
xt_cjr_id = #{xtCjrId},
|
||||
</if>
|
||||
<if test="xtCjr != null and xtCjr != ''">
|
||||
xt_cjr = #{xtCjr},
|
||||
</if>
|
||||
<if test="xtCjbmdm != null and xtCjbmdm != ''">
|
||||
xt_cjbmdm = #{xtCjbmdm},
|
||||
</if>
|
||||
<if test="xtCjbmmc != null and xtCjbmmc != ''">
|
||||
xt_cjbmmc = #{xtCjbmmc},
|
||||
</if>
|
||||
<if test="xtZhgxip != null and xtZhgxip != ''">
|
||||
xt_zhgxip = #{xtZhgxip},
|
||||
</if>
|
||||
<if test="xtZhgxsj != null">
|
||||
xt_zhgxsj = #{xtZhgxsj},
|
||||
</if>
|
||||
<if test="xtZhgxrid != null and xtZhgxrid != ''">
|
||||
xt_zhgxrid = #{xtZhgxrid},
|
||||
</if>
|
||||
<if test="xtZhgxr != null and xtZhgxr != ''">
|
||||
xt_zhgxr = #{xtZhgxr},
|
||||
</if>
|
||||
<if test="xtZhgxbmdm != null and xtZhgxbmdm != ''">
|
||||
xt_zhgxbmdm = #{xtZhgxbmdm},
|
||||
</if>
|
||||
<if test="xtZhgxbm != null and xtZhgxbm != ''">
|
||||
xt_zhgxbm = #{xtZhgxbm},
|
||||
</if>
|
||||
<if test="bz != null and bz != ''">
|
||||
bz = #{bz}
|
||||
</if>
|
||||
<if test="ssbmid != null and ssbmid != ''">
|
||||
ssbmid = #{ssbmid},
|
||||
</if>
|
||||
<if test="ssxgajid != null and ssxgajid != ''">
|
||||
ssxgajid = #{ssxgajid},
|
||||
</if>
|
||||
<if test="sssgajid != null and sssgajid != ''">
|
||||
sssgajid = #{sssgajid},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
</mapper>
|
||||
|
||||
|
418
mosty-yszx/src/main/resources/mapper/TbYsXzajMapper.xml
Normal file
418
mosty-yszx/src/main/resources/mapper/TbYsXzajMapper.xml
Normal file
@ -0,0 +1,418 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.mosty.yszx.mapper.TbYsXzajMapper">
|
||||
|
||||
<resultMap type="com.mosty.base.model.vo.yszx.TbYsAjVo" id="tbYsAjVo">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="sjlyid" column="sjlyid" jdbcType="VARCHAR"/>
|
||||
<result property="ajbh" column="ajbh" jdbcType="VARCHAR"/>
|
||||
<result property="ajmc" column="ajmc" jdbcType="VARCHAR"/>
|
||||
<result property="ajnr" column="ajnr" jdbcType="VARCHAR"/>
|
||||
<result property="farq" column="farq" jdbcType="TIMESTAMP"/>
|
||||
<result property="fasj" column="fasj" jdbcType="TIMESTAMP"/>
|
||||
<result property="ajlb" column="ajlb" jdbcType="VARCHAR"/>
|
||||
<result property="aymc" column="aymc" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="xzqhdm" column="xzqhdm" jdbcType="VARCHAR"/>
|
||||
<result property="dzmc" column="dzmc" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="distance" column="distance" jdbcType="NUMERIC"/>
|
||||
<result property="sssgajid" column="sssgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajid" column="ssxgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmid" column="ssbmid" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<!--行政案件-->
|
||||
<resultMap type="com.mosty.base.model.entity.yszx.TbYsXzaj" id="tbYsXzaj">
|
||||
<result property="id" column="id" jdbcType="VARCHAR"/>
|
||||
<result property="sjlyid" column="sjlyid" jdbcType="VARCHAR"/>
|
||||
<result property="ajbh" column="ajbh" jdbcType="VARCHAR"/>
|
||||
<result property="ajmc" column="ajmc" jdbcType="VARCHAR"/>
|
||||
<result property="ajnr" column="ajnr" jdbcType="VARCHAR"/>
|
||||
<result property="farq" column="farq" jdbcType="TIMESTAMP"/>
|
||||
<result property="fasj" column="fasj" jdbcType="TIMESTAMP"/>
|
||||
<result property="ajlb" column="ajlb" jdbcType="VARCHAR"/>
|
||||
<result property="aymc" column="aymc" jdbcType="VARCHAR"/>
|
||||
<result property="jd" column="jd" jdbcType="NUMERIC"/>
|
||||
<result property="wd" column="wd" jdbcType="NUMERIC"/>
|
||||
<result property="zb" column="zb" typeHandler="com.mosty.base.feign.handle.PointTypeHandler"/>
|
||||
<result property="zbhash" column="zbhash" jdbcType="VARCHAR"/>
|
||||
<result property="xzqhdm" column="xzqhdm" jdbcType="VARCHAR"/>
|
||||
<result property="dzmc" column="dzmc" jdbcType="VARCHAR"/>
|
||||
<result property="jsnr" column="jsnr" jdbcType="VARCHAR"/>
|
||||
<result property="ssbm" column="ssbm" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmdm" column="ssbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgaj" column="ssxgaj" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajdm" column="ssxgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="sssgaj" column="sssgaj" jdbcType="VARCHAR"/>
|
||||
<result property="sssgajdm" column="sssgajdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjly" column="xt_sjly" jdbcType="VARCHAR"/>
|
||||
<result property="xtSjzt" column="xt_sjzt" jdbcType="VARCHAR"/>
|
||||
<result property="xtScbz" column="xt_scbz" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjip" column="xt_cjip" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjsj" column="xt_cjsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjrId" column="xt_cjr_id" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjr" column="xt_cjr" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmdm" column="xt_cjbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtCjbmmc" column="xt_cjbmmc" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxip" column="xt_zhgxip" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxsj" column="xt_zhgxsj" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxrid" column="xt_zhgxrid" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxr" column="xt_zhgxr" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbmdm" column="xt_zhgxbmdm" jdbcType="VARCHAR"/>
|
||||
<result property="xtZhgxbm" column="xt_zhgxbm" jdbcType="VARCHAR"/>
|
||||
<result property="bz" column="bz" jdbcType="VARCHAR"/>
|
||||
<result property="distance" column="distance" jdbcType="NUMERIC"/>
|
||||
<result property="sssgajid" column="sssgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssxgajid" column="ssxgajid" jdbcType="VARCHAR"/>
|
||||
<result property="ssbmid" column="ssbmid" jdbcType="VARCHAR"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="base_column_list">
|
||||
id
|
||||
, ajfl, sjlyid, ajbh, ajmc, ajnr, farq, fasj,ssbmid,ssxgajid,sssgajid,
|
||||
ajlb, aymc, jd, wd, zbhash, xzqhdm, dzmc, jsnr, ssbm,
|
||||
ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly,
|
||||
xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr,
|
||||
xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz
|
||||
</sql>
|
||||
|
||||
<sql id="base_column">
|
||||
id
|
||||
, sjlyid, ajbh, ajmc, ajnr, farq, fasj,ssbmid,ssxgajid,sssgajid,
|
||||
ajlb, aymc, jd, wd, zbhash, xzqhdm, dzmc, jsnr, ssbm,
|
||||
ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly,
|
||||
xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr,
|
||||
xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz
|
||||
</sql>
|
||||
|
||||
<sql id="blob_column_List">
|
||||
ST_ASWKT
|
||||
(zb) as zb
|
||||
</sql>
|
||||
|
||||
|
||||
<!--新增行政案件-->
|
||||
<insert id="insertXzaj" parameterType="com.mosty.base.model.entity.yszx.TbYsXzaj">
|
||||
insert into tb_ys_xzaj
|
||||
(id, sjlyid, ajbh, ajmc, ajnr, farq, fasj,ssbmid,ssxgajid,sssgajid,
|
||||
ajlb, aymc, jd, wd, zb, zbhash, xzqhdm, dzmc, jsnr, ssbm,
|
||||
ssbmdm, ssxgaj, ssxgajdm, sssgaj, sssgajdm, xt_sjly,
|
||||
xt_sjzt, xt_scbz, xt_cjip, xt_cjsj, xt_cjr_id, xt_cjr,
|
||||
xt_cjbmdm, xt_cjbmmc, xt_zhgxip, xt_zhgxsj, xt_zhgxrid,
|
||||
xt_zhgxr, xt_zhgxbmdm, xt_zhgxbm, bz)
|
||||
values (#{id}, #{sjlyid}, #{ajbh}, #{ajmc}, #{ajnr}, #{farq}, #{fasj},#{ssbmid},#{ssxgajid},#{sssgajid},
|
||||
#{ajlb}, #{aymc}, #{jd}, #{wd},
|
||||
ST_GEOMFROMTEXT(#{zb,typeHandler=com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
#{zbhash}, #{xzqhdm}, #{dzmc}, #{jsnr}, #{ssbm},
|
||||
#{ssbmdm}, #{ssxgaj}, #{ssxgajdm}, #{sssgaj}, #{sssgajdm}, #{xtSjly},
|
||||
#{xtSjzt}, #{xtScbz}, #{xtCjip}, #{xtCjsj}, #{xtCjrId}, #{xtCjr},
|
||||
#{xtCjbmdm}, #{xtCjbmmc}, #{xtZhgxip}, #{xtZhgxsj}, #{xtZhgxrid},
|
||||
#{xtZhgxr}, #{xtZhgxbmdm}, #{xtZhgxbm}, #{bz})
|
||||
</insert>
|
||||
|
||||
<!--查询行政案件详情-->
|
||||
<select id="selectXzAjById" resultMap="tbYsXzaj">
|
||||
select
|
||||
<include refid="base_column"/>
|
||||
from tb_ys_xzaj
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<!--修改行政案件-->
|
||||
<update id="updateXzEntity" parameterType="com.mosty.base.model.entity.yszx.TbYsXzaj">
|
||||
update tb_ys_xzaj
|
||||
<set>
|
||||
<if test="sjlyid != null and sjlyid != ''">
|
||||
sjlyid = #{sjlyid},
|
||||
</if>
|
||||
<if test="ajbh != null and ajbh != ''">
|
||||
ajbh = #{ajbh},
|
||||
</if>
|
||||
<if test="ajmc != null and ajmc != ''">
|
||||
ajmc = #{ajmc},
|
||||
</if>
|
||||
<if test="ajnr != null and ajnr != ''">
|
||||
ajnr = #{ajnr},
|
||||
</if>
|
||||
<if test="farq != null">
|
||||
farq = #{farq},
|
||||
</if>
|
||||
<if test="fasj != null">
|
||||
fasj = #{fasj},
|
||||
</if>
|
||||
<if test="ajlb != null and ajlb != ''">
|
||||
ajlb = #{ajlb},
|
||||
</if>
|
||||
<if test="aymc != null and aymc != ''">
|
||||
aymc = #{aymc},
|
||||
</if>
|
||||
<if test="jd != null">
|
||||
jd = #{jd},
|
||||
</if>
|
||||
<if test="wd != null">
|
||||
wd = #{wd},
|
||||
</if>
|
||||
<if test="zb != null">
|
||||
zb = ST_GEOMFROMTEXT(#{zb,typeHandler=com.mosty.base.feign.handle.PointTypeHandler}),
|
||||
</if>
|
||||
<if test="zbhash != null and zbhash != ''">
|
||||
zbhash = #{zbhash},
|
||||
</if>
|
||||
<if test="xzqhdm != null and xzqhdm != ''">
|
||||
xzqhdm = #{xzqhdm},
|
||||
</if>
|
||||
<if test="dzmc != null and dzmc != ''">
|
||||
dzmc = #{dzmc},
|
||||
</if>
|
||||
<if test="jsnr != null and jsnr != ''">
|
||||
jsnr = #{jsnr},
|
||||
</if>
|
||||
<if test="ssbm != null and ssbm != ''">
|
||||
ssbm = #{ssbm},
|
||||
</if>
|
||||
<if test="ssbmdm != null and ssbmdm != ''">
|
||||
ssbmdm = #{ssbmdm},
|
||||
</if>
|
||||
<if test="ssxgaj != null and ssxgaj != ''">
|
||||
ssxgaj = #{ssxgaj},
|
||||
</if>
|
||||
<if test="ssxgajdm != null and ssxgajdm != ''">
|
||||
ssxgajdm = #{ssxgajdm},
|
||||
</if>
|
||||
<if test="sssgaj != null and sssgaj != ''">
|
||||
sssgaj = #{sssgaj},
|
||||
</if>
|
||||
<if test="sssgajdm != null and sssgajdm != ''">
|
||||
sssgajdm = #{sssgajdm},
|
||||
</if>
|
||||
<if test="xtSjly != null and xtSjly != ''">
|
||||
xt_sjly = #{xtSjly},
|
||||
</if>
|
||||
<if test="xtSjzt != null and xtSjzt != ''">
|
||||
xt_sjzt = #{xtSjzt},
|
||||
</if>
|
||||
<if test="xtScbz != null and xtScbz != ''">
|
||||
xt_scbz = #{xtScbz},
|
||||
</if>
|
||||
<if test="xtCjip != null and xtCjip != ''">
|
||||
xt_cjip = #{xtCjip},
|
||||
</if>
|
||||
<if test="xtCjsj != null">
|
||||
xt_cjsj = #{xtCjsj},
|
||||
</if>
|
||||
<if test="xtCjrId != null and xtCjrId != ''">
|
||||
xt_cjr_id = #{xtCjrId},
|
||||
</if>
|
||||
<if test="xtCjr != null and xtCjr != ''">
|
||||
xt_cjr = #{xtCjr},
|
||||
</if>
|
||||
<if test="xtCjbmdm != null and xtCjbmdm != ''">
|
||||
xt_cjbmdm = #{xtCjbmdm},
|
||||
</if>
|
||||
<if test="xtCjbmmc != null and xtCjbmmc != ''">
|
||||
xt_cjbmmc = #{xtCjbmmc},
|
||||
</if>
|
||||
<if test="xtZhgxip != null and xtZhgxip != ''">
|
||||
xt_zhgxip = #{xtZhgxip},
|
||||
</if>
|
||||
<if test="xtZhgxsj != null">
|
||||
xt_zhgxsj = #{xtZhgxsj},
|
||||
</if>
|
||||
<if test="xtZhgxrid != null and xtZhgxrid != ''">
|
||||
xt_zhgxrid = #{xtZhgxrid},
|
||||
</if>
|
||||
<if test="xtZhgxr != null and xtZhgxr != ''">
|
||||
xt_zhgxr = #{xtZhgxr},
|
||||
</if>
|
||||
<if test="xtZhgxbmdm != null and xtZhgxbmdm != ''">
|
||||
xt_zhgxbmdm = #{xtZhgxbmdm},
|
||||
</if>
|
||||
<if test="xtZhgxbm != null and xtZhgxbm != ''">
|
||||
xt_zhgxbm = #{xtZhgxbm},
|
||||
</if>
|
||||
<if test="bz != null and bz != ''">
|
||||
bz = #{bz}
|
||||
</if>
|
||||
<if test="ssbmid != null and ssbmid != ''">
|
||||
ssbmid = #{ssbmid},
|
||||
</if>
|
||||
<if test="ssxgajid != null and ssxgajid != ''">
|
||||
ssxgajid = #{ssxgajid},
|
||||
</if>
|
||||
<if test="sssgajid != null and sssgajid != ''">
|
||||
sssgajid = #{sssgajid},
|
||||
</if>
|
||||
</set>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<!--获取案件总数-->
|
||||
<select id="getCount" resultType="Integer" parameterType="Map">
|
||||
select count(1) from
|
||||
<if test='dto.ajfl == "0"'>
|
||||
(
|
||||
select * from tb_ys_xsaj union all
|
||||
select * from tb_ys_xzaj
|
||||
) as tb
|
||||
</if>
|
||||
<if test='dto.ajfl == "1"'>
|
||||
tb_ys_xsaj
|
||||
</if>
|
||||
<if test='dto.ajfl == "2"'>
|
||||
tb_ys_xzaj
|
||||
</if>
|
||||
where xt_scbz = '0' and xt_sjzt = '1'
|
||||
<if test="dto.ajmc != null and dto.ajmc != ''">
|
||||
and ajmc like concat('%',#{dto.ajmc},'%')
|
||||
</if>
|
||||
<if test="dto.ajnr != null and dto.ajnr != ''">
|
||||
and ajnr like concat('%',#{dto.ajnr},'%')
|
||||
</if>
|
||||
<if test="dto.ajlb != null and dto.ajlb != ''">
|
||||
and ajlb = #{dto.ajlb}
|
||||
</if>
|
||||
<if test="dto.startTime != null and dto.startTime != '' and endTime != null and endTime != ''">
|
||||
and fasj between #{dto.startTime} and #{endTime}
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[and st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) <= #{dto.radius}]]>
|
||||
</if>
|
||||
${useSql}
|
||||
</select>
|
||||
|
||||
<!--分页获取案件列表-->
|
||||
<select id="getList" resultMap="tbYsAjVo" parameterType="Map">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,distance
|
||||
</if>
|
||||
<if test='dto.ajfl == "0"'>
|
||||
from (
|
||||
select *,1 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xsaj union all
|
||||
select *,2 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xzaj
|
||||
) as tb
|
||||
</if>
|
||||
<if test='dto.ajfl == "1"'>
|
||||
from (select * ,1 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xsaj) as tb
|
||||
</if>
|
||||
<if test='dto.ajfl == "2"'>
|
||||
from (select * ,2 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xzaj) as tb
|
||||
</if>
|
||||
where xt_scbz = '0' and xt_sjzt = '1'
|
||||
<if test="dto.ajmc != null and dto.ajmc != ''">
|
||||
and ajmc like concat('%',#{dto.ajmc},'%')
|
||||
</if>
|
||||
<if test="dto.ajnr != null and dto.ajnr != ''">
|
||||
and dto.ajnr like concat('%',#{dto.ajnr},'%')
|
||||
</if>
|
||||
<if test="dto.ajlb != null and dto.ajlb != ''">
|
||||
and ajlb = #{dto.ajlb}
|
||||
</if>
|
||||
<if test="dto.startTime != null and dto.startTime != '' and endTime != null and endTime != ''">
|
||||
and fasj between #{dto.startTime} and #{endTime}
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[and st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) <= #{dto.radius}]]>
|
||||
</if>
|
||||
${useSql}
|
||||
order by fasj desc
|
||||
limit #{pageIndex},#{pageSize}
|
||||
</select>
|
||||
|
||||
<!--查询案件列表不分页-->
|
||||
<select id="getListAll" resultMap="tbYsAjVo" parameterType="Map">
|
||||
select
|
||||
<include refid="base_column_list"/>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,distance
|
||||
</if>
|
||||
<if test='dto.ajfl == "0"'>
|
||||
from (
|
||||
select *,1 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xsaj union all
|
||||
select *,2 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xzaj
|
||||
) as tb
|
||||
</if>
|
||||
<if test='dto.ajfl == "1"'>
|
||||
from (select * ,1 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xsaj) as tb
|
||||
</if>
|
||||
<if test='dto.ajfl == "2"'>
|
||||
from (select * ,2 as ajfl
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
,st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) as distance
|
||||
</if>
|
||||
from tb_ys_xzaj) as tb
|
||||
</if>
|
||||
where xt_scbz = '0' and xt_sjzt = '1'
|
||||
<if test="dto.ajmc != null and dto.ajmc != ''">
|
||||
and ajmc like concat('%',#{dto.ajmc},'%')
|
||||
</if>
|
||||
<if test="dto.ajnr != null and dto.ajnr != ''">
|
||||
and ajnr like concat('%',#{dto.ajnr},'%')
|
||||
</if>
|
||||
<if test="dto.ajlb != null and dto.ajlb != ''">
|
||||
and ajlb = #{dto.ajlb}
|
||||
</if>
|
||||
<if test="dto.startTime != null and dto.startTime != '' and endTime != null and endTime != ''">
|
||||
and fasj between #{dto.startTime} and #{endTime}
|
||||
</if>
|
||||
<if test="dto.jd != null and dto.wd != null and dto.radius != null">
|
||||
<![CDATA[and st_distance_sphere(POINT(jd,wd),POINT(#{dto.jd},#{dto.wd})) <= #{dto.radius}]]>
|
||||
</if>
|
||||
${useSql}
|
||||
order by fasj desc
|
||||
</select>
|
||||
|
||||
<!--删除案件信息-->
|
||||
<update id="delAj" parameterType="com.mosty.base.model.dto.yszx.TbYsAjDelDto">
|
||||
update
|
||||
<if test='ajfl == "1"'>
|
||||
tb_ys_xsaj
|
||||
</if>
|
||||
<if test='ajfl == "2"'>
|
||||
tb_ys_xzaj
|
||||
</if>
|
||||
set xt_scbz = '1'
|
||||
where id = #{id}
|
||||
</update>
|
||||
</mapper>
|
||||
|
||||
|
16
mosty-yszx/src/main/resources/rebel.xml
Normal file
16
mosty-yszx/src/main/resources/rebel.xml
Normal file
@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
|
||||
<!--
|
||||
This is the JRebel configuration file. It maps the running application to your IDE workspace, enabling JRebel reloading for this project.
|
||||
Refer to https://manuals.jrebel.com/jrebel/standalone/config.html for more information.
|
||||
-->
|
||||
<application generated-by="intellij" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.zeroturnaround.com" xsi:schemaLocation="http://www.zeroturnaround.com http://update.zeroturnaround.com/jrebel/rebel-2_3.xsd">
|
||||
|
||||
<id>mosty-yszx</id>
|
||||
|
||||
<classpath>
|
||||
<dir name="E:/project/rs/mosty-dyga-cloud/mosty-yszx/target/classes">
|
||||
</dir>
|
||||
</classpath>
|
||||
|
||||
</application>
|
Reference in New Issue
Block a user