Commit 0bea1e8f authored by Quxl's avatar Quxl

x

parent a3d56184
...@@ -33,6 +33,10 @@ ...@@ -33,6 +33,10 @@
<groupId>org.springframework.boot</groupId> <groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId> <artifactId>spring-boot-starter-web</artifactId>
</dependency> </dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-aop</artifactId>
</dependency>
<dependency> <dependency>
<groupId>org.apache.cxf</groupId> <groupId>org.apache.cxf</groupId>
<artifactId>cxf-spring-boot-starter-jaxws</artifactId> <artifactId>cxf-spring-boot-starter-jaxws</artifactId>
......
...@@ -37,50 +37,39 @@ public class WsConfig { ...@@ -37,50 +37,39 @@ public class WsConfig {
WSS4JInInterceptor authInterceptor; WSS4JInInterceptor authInterceptor;
@Bean @Bean
public Endpoint getMaterialMasterPoint(MaterialMasterService materialMasterService) { public Endpoint getMaterialMasterPoint(MaterialMasterService service) {
EndpointImpl endpoint = new EndpointImpl(bus, materialMasterService); return this.createEndpoint("/material_master", service);
endpoint.setInInterceptors(Arrays.asList(authInterceptor));
endpoint.publish("/material_master");
return endpoint;
} }
@Bean @Bean
public Endpoint getPriceListPoint(PriceListService priceListService) { public Endpoint getPriceListPoint(PriceListService service) {
EndpointImpl endpoint = new EndpointImpl(bus, priceListService); return this.createEndpoint("/price_list", service);
endpoint.setInInterceptors(Arrays.asList(authInterceptor));
endpoint.publish("/price_list");
return endpoint;
} }
@Bean @Bean
public Endpoint getProFormaInvoicePoint(PrformaInvoiceService priceListService) { public Endpoint getProFormaInvoicePoint(PrformaInvoiceService service) {
EndpointImpl endpoint = new EndpointImpl(bus, priceListService); return this.createEndpoint("/prforma_invoice", service);
endpoint.setInInterceptors(Arrays.asList(authInterceptor));
endpoint.publish("/prforma_invoice");
return endpoint;
} }
@Bean @Bean
public Endpoint getSoConfirmQuotationPoint(ConfirmQuotationService soConfirmQuotationService) { public Endpoint getSoConfirmQuotationPoint(ConfirmQuotationService service) {
EndpointImpl endpoint = new EndpointImpl(bus, soConfirmQuotationService); return this.createEndpoint("/confirm_quotation", service);
endpoint.setInInterceptors(Arrays.asList(authInterceptor));
endpoint.publish("/confirm_quotation");
return endpoint;
} }
@Bean @Bean
public Endpoint getShippingNotificationPoint(ShippingNotificationService shippingNotificationService) { public Endpoint getShippingNotificationPoint(ShippingNotificationService service) {
EndpointImpl endpoint = new EndpointImpl(bus, shippingNotificationService); return this.createEndpoint("/shipping_notification", service);
endpoint.setInInterceptors(Arrays.asList(authInterceptor));
endpoint.publish("/shipping_notification");
return endpoint;
} }
@Bean @Bean
public Endpoint getDNDeletionPoint(DNDeletionService deletionService) { public Endpoint getDNDeletionPoint(DNDeletionService service) {
EndpointImpl endpoint = new EndpointImpl(bus, deletionService); return this.createEndpoint("/dn_deletion", service);
}
private Endpoint createEndpoint(String path, Object service) {
EndpointImpl endpoint = new EndpointImpl(bus, service);
endpoint.setInInterceptors(Arrays.asList(authInterceptor)); endpoint.setInInterceptors(Arrays.asList(authInterceptor));
endpoint.publish("/dn_deletion"); endpoint.publish(path);
return endpoint; return endpoint;
} }
......
...@@ -4,10 +4,12 @@ import java.util.List; ...@@ -4,10 +4,12 @@ import java.util.List;
import javax.xml.bind.annotation.XmlAccessType; import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType; import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.bind.annotation.XmlType; import javax.xml.bind.annotation.XmlType;
@XmlType(name = "Z_MT_SD_002_PRICE_LIST") @XmlType(name = "Z_MT_SD_002_PRICE_LIST")
@XmlAccessorType(XmlAccessType.FIELD) @XmlAccessorType(XmlAccessType.FIELD)
@XmlRootElement(name = "Z_MT_SD_002_PRICE_LIST", namespace="http://schneider-distributor.com/")
public class Z_MT_SD_002_PRICE_LIST { public class Z_MT_SD_002_PRICE_LIST {
RECORD RECORD; RECORD RECORD;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment