Your Name лет назад: 3
Родитель
Сommit
fce54d917d

+ 32 - 13
java110-bean/src/main/java/com/java110/dto/machinePrinter/MachinePrinterDto.java

@@ -1,6 +1,7 @@
 package com.java110.dto.machinePrinter;
 
 import com.java110.dto.PageDto;
+
 import java.io.Serializable;
 import java.util.Date;
 
@@ -15,10 +16,11 @@ import java.util.Date;
 public class MachinePrinterDto extends PageDto implements Serializable {
 
     private String implBean;
-private String machineId;
-private String machineCode;
-private String communityId;
-private String machineName;
+    private String implBeanName;
+    private String machineId;
+    private String machineCode;
+    private String communityId;
+    private String machineName;
 
 
     private Date createTime;
@@ -29,31 +31,40 @@ private String machineName;
     public String getImplBean() {
         return implBean;
     }
-public void setImplBean(String implBean) {
+
+    public void setImplBean(String implBean) {
         this.implBean = implBean;
     }
-public String getMachineId() {
+
+    public String getMachineId() {
         return machineId;
     }
-public void setMachineId(String machineId) {
+
+    public void setMachineId(String machineId) {
         this.machineId = machineId;
     }
-public String getMachineCode() {
+
+    public String getMachineCode() {
         return machineCode;
     }
-public void setMachineCode(String machineCode) {
+
+    public void setMachineCode(String machineCode) {
         this.machineCode = machineCode;
     }
-public String getCommunityId() {
+
+    public String getCommunityId() {
         return communityId;
     }
-public void setCommunityId(String communityId) {
+
+    public void setCommunityId(String communityId) {
         this.communityId = communityId;
     }
-public String getMachineName() {
+
+    public String getMachineName() {
         return machineName;
     }
-public void setMachineName(String machineName) {
+
+    public void setMachineName(String machineName) {
         this.machineName = machineName;
     }
 
@@ -73,4 +84,12 @@ public void setMachineName(String machineName) {
     public void setStatusCd(String statusCd) {
         this.statusCd = statusCd;
     }
+
+    public String getImplBeanName() {
+        return implBeanName;
+    }
+
+    public void setImplBeanName(String implBeanName) {
+        this.implBeanName = implBeanName;
+    }
 }

+ 75 - 77
java110-db/src/main/resources/mapper/common/MachinePrinterV1ServiceDaoImplMapper.xml

@@ -5,102 +5,100 @@
 <mapper namespace="machinePrinterV1ServiceDaoImpl">
 
 
-
-
-
     <!-- 保存云打印机信息 add by wuxw 2018-07-03 -->
     <insert id="saveMachinePrinterInfo" parameterType="Map">
         insert into machine_printer(
-impl_bean,machine_id,machine_code,community_id,machine_name
-) values (
-#{implBean},#{machineId},#{machineCode},#{communityId},#{machineName}
-)
+        impl_bean,machine_id,machine_code,community_id,machine_name
+        ) values (
+        #{implBean},#{machineId},#{machineCode},#{communityId},#{machineName}
+        )
     </insert>
 
 
-
     <!-- 查询云打印机信息 add by wuxw 2018-07-03 -->
     <select id="getMachinePrinterInfo" parameterType="Map" resultType="Map">
-        select  t.impl_bean,t.impl_bean implBean,t.machine_id,t.machine_id machineId,t.machine_code,t.machine_code machineCode,t.status_cd,t.status_cd statusCd,t.community_id,t.community_id communityId,t.machine_name,t.machine_name machineName 
-from machine_printer t 
-where 1 =1 
-<if test="implBean !=null and implBean != ''">
-   and t.impl_bean= #{implBean}
-</if> 
-<if test="machineId !=null and machineId != ''">
-   and t.machine_id= #{machineId}
-</if> 
-<if test="machineCode !=null and machineCode != ''">
-   and t.machine_code= #{machineCode}
-</if> 
-<if test="statusCd !=null and statusCd != ''">
-   and t.status_cd= #{statusCd}
-</if> 
-<if test="communityId !=null and communityId != ''">
-   and t.community_id= #{communityId}
-</if> 
-<if test="machineName !=null and machineName != ''">
-   and t.machine_name= #{machineName}
-</if> 
-order by t.create_time desc
-<if test="page != -1 and page != null ">
-   limit #{page}, #{row}
-</if> 
+        select t.impl_bean,t.impl_bean implBean,t.machine_id,t.machine_id machineId,t.machine_code,t.machine_code
+        machineCode,t.status_cd,t.status_cd statusCd,t.community_id,t.community_id
+        communityId,t.machine_name,t.machine_name machineName,td.`name` implBeanName
+        from machine_printer t
+        left join t_dict td on t.impl_bean = td.status_cd and td.table_name = 'machine_printer' and td.table_columns = 'impl_bean'
+        where 1 =1
+        <if test="implBean !=null and implBean != ''">
+            and t.impl_bean= #{implBean}
+        </if>
+        <if test="machineId !=null and machineId != ''">
+            and t.machine_id= #{machineId}
+        </if>
+        <if test="machineCode !=null and machineCode != ''">
+            and t.machine_code= #{machineCode}
+        </if>
+        <if test="statusCd !=null and statusCd != ''">
+            and t.status_cd= #{statusCd}
+        </if>
+        <if test="communityId !=null and communityId != ''">
+            and t.community_id= #{communityId}
+        </if>
+        <if test="machineName !=null and machineName != ''">
+            and t.machine_name= #{machineName}
+        </if>
+        order by t.create_time desc
+        <if test="page != -1 and page != null ">
+            limit #{page}, #{row}
+        </if>
 
     </select>
 
 
-
-
     <!-- 修改云打印机信息 add by wuxw 2018-07-03 -->
     <update id="updateMachinePrinterInfo" parameterType="Map">
-        update  machine_printer t set t.status_cd = #{statusCd}
-<if test="newBId != null and newBId != ''">
-,t.b_id = #{newBId}
-</if> 
-<if test="implBean !=null and implBean != ''">
-, t.impl_bean= #{implBean}
-</if> 
-<if test="machineCode !=null and machineCode != ''">
-, t.machine_code= #{machineCode}
-</if> 
-<if test="communityId !=null and communityId != ''">
-, t.community_id= #{communityId}
-</if> 
-<if test="machineName !=null and machineName != ''">
-, t.machine_name= #{machineName}
-</if> 
- where 1=1 <if test="machineId !=null and machineId != ''">
-and t.machine_id= #{machineId}
-</if> 
+        update machine_printer t set t.status_cd = #{statusCd}
+        <if test="newBId != null and newBId != ''">
+            ,t.b_id = #{newBId}
+        </if>
+        <if test="implBean !=null and implBean != ''">
+            , t.impl_bean= #{implBean}
+        </if>
+        <if test="machineCode !=null and machineCode != ''">
+            , t.machine_code= #{machineCode}
+        </if>
+        <if test="communityId !=null and communityId != ''">
+            , t.community_id= #{communityId}
+        </if>
+        <if test="machineName !=null and machineName != ''">
+            , t.machine_name= #{machineName}
+        </if>
+        where 1=1
+        <if test="machineId !=null and machineId != ''">
+            and t.machine_id= #{machineId}
+        </if>
 
     </update>
 
     <!-- 查询云打印机数量 add by wuxw 2018-07-03 -->
-     <select id="queryMachinePrintersCount" parameterType="Map" resultType="Map">
-        select  count(1) count 
-from machine_printer t 
-where 1 =1 
-<if test="implBean !=null and implBean != ''">
-   and t.impl_bean= #{implBean}
-</if> 
-<if test="machineId !=null and machineId != ''">
-   and t.machine_id= #{machineId}
-</if> 
-<if test="machineCode !=null and machineCode != ''">
-   and t.machine_code= #{machineCode}
-</if> 
-<if test="statusCd !=null and statusCd != ''">
-   and t.status_cd= #{statusCd}
-</if> 
-<if test="communityId !=null and communityId != ''">
-   and t.community_id= #{communityId}
-</if> 
-<if test="machineName !=null and machineName != ''">
-   and t.machine_name= #{machineName}
-</if> 
+    <select id="queryMachinePrintersCount" parameterType="Map" resultType="Map">
+        select count(1) count
+        from machine_printer t
+        where 1 =1
+        <if test="implBean !=null and implBean != ''">
+            and t.impl_bean= #{implBean}
+        </if>
+        <if test="machineId !=null and machineId != ''">
+            and t.machine_id= #{machineId}
+        </if>
+        <if test="machineCode !=null and machineCode != ''">
+            and t.machine_code= #{machineCode}
+        </if>
+        <if test="statusCd !=null and statusCd != ''">
+            and t.status_cd= #{statusCd}
+        </if>
+        <if test="communityId !=null and communityId != ''">
+            and t.community_id= #{communityId}
+        </if>
+        <if test="machineName !=null and machineName != ''">
+            and t.machine_name= #{machineName}
+        </if>
 
 
-     </select>
+    </select>
 
 </mapper>

+ 3 - 0
java110-utils/src/main/java/com/java110/utils/constant/MappingConstant.java

@@ -37,6 +37,9 @@ public final class MappingConstant {
     public static final String ENV_DOMAIN = "ENV_DOMAIN";
 
 
+    //飞蛾小票机配置
+    public static final String FEIE_DOMAIN = "FEIE_DOMAIN";
+
     public  static final String KEY_LOG_ON_OFF = "LOG_ON_OFF";
 
     public  static final String KEY_COST_TIME_ON_OFF = "COST_TIME_ON_OFF";

+ 3 - 3
service-job/src/main/java/com/java110/job/printer/manufactor/FeieManufactor.java

@@ -155,11 +155,11 @@ public class FeieManufactor implements IPrinter {
         printStr += getPrintPayFeeDetailFloorContent(totalDecimal.doubleValue());
 
         String stime = String.valueOf(System.currentTimeMillis() / 1000);
-        String user =  MappingCache.getValue(MappingConstant.URL_DOMAIN,"user");
-        String ukey =  MappingCache.getValue(MappingConstant.URL_DOMAIN,"ukey");
+        String user =  MappingCache.getValue(MappingConstant.FEIE_DOMAIN,"user");
+        String ukey =  MappingCache.getValue(MappingConstant.FEIE_DOMAIN,"ukey");
 
         MultiValueMap<String, Object> postParameters = new LinkedMultiValueMap<>();
-        postParameters.add("user", MappingCache.getValue(MappingConstant.URL_DOMAIN,"user"));
+        postParameters.add("user", user);
         postParameters.add("stime", stime);
         postParameters.add("sig", signature(user,ukey,stime));
         postParameters.add("apiname", "Open_printMsg");