huangxiao 1 ماه پیش
والد
کامیت
340017626e

+ 9 - 0
src/main/java/net/mingsoft/tf/action/EnterpriseAction.java

@@ -92,6 +92,7 @@ public class EnterpriseAction extends BaseAction{
         @Parameter(name = "enterpriseName", description = "企业名称", in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseType", description = "企业类型", in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseBooth", description = "展位号", in = ParameterIn.QUERY),
+        @Parameter(name = "enterpriseVisits", description = "访问量", in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseContact", description = "联系人", in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseTel", description = "联系电话", in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseAddress", description = "企业地址", in = ParameterIn.QUERY),
@@ -142,6 +143,7 @@ public class EnterpriseAction extends BaseAction{
         @Parameter(name = "enterpriseName", description = "企业名称", required = true, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseType", description = "企业类型", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseBooth", description = "展位号", required = false, in = ParameterIn.QUERY),
+        @Parameter(name = "enterpriseVisits", description = "访问量", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseContact", description = "联系人", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseTel", description = "联系电话", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseAddress", description = "企业地址", required = false, in = ParameterIn.QUERY),
@@ -166,6 +168,9 @@ public class EnterpriseAction extends BaseAction{
         if (  StringUtils.isNotBlank(enterprise.getEnterpriseBooth()) && !StringUtil.checkLength(enterprise.getEnterpriseBooth()+"", 0, 255)) {
           return ResultData.build().error(getResString("err.length", this.getResString("enterprise.booth"), "0", "255"));
         }
+        if (!StringUtil.checkLength(enterprise.getEnterpriseVisits()+"", 0, 11)) {
+          return ResultData.build().error(getResString("err.length", this.getResString("enterprise.visits"), "0", "11"));
+        }
         if (  StringUtils.isNotBlank(enterprise.getEnterpriseContact()) && !StringUtil.checkLength(enterprise.getEnterpriseContact()+"", 0, 255)) {
           return ResultData.build().error(getResString("err.length", this.getResString("enterprise.contact"), "0", "255"));
         }
@@ -205,6 +210,7 @@ public class EnterpriseAction extends BaseAction{
         @Parameter(name = "enterpriseName", description = "企业名称", required = true, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseType", description = "企业类型", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseBooth", description = "展位号", required = false, in = ParameterIn.QUERY),
+        @Parameter(name = "enterpriseVisits", description = "访问量", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseContact", description = "联系人", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseTel", description = "联系电话", required = false, in = ParameterIn.QUERY),
         @Parameter(name = "enterpriseAddress", description = "企业地址", required = false, in = ParameterIn.QUERY),
@@ -234,6 +240,9 @@ public class EnterpriseAction extends BaseAction{
         if (  StringUtils.isNotBlank(enterprise.getEnterpriseBooth()) && !StringUtil.checkLength(enterprise.getEnterpriseBooth()+"", 0, 255)) {
           return ResultData.build().error(getResString("err.length", this.getResString("enterprise.booth"), "0", "255"));
         }
+        if (!StringUtil.checkLength(enterprise.getEnterpriseVisits()+"", 0, 11)) {
+          return ResultData.build().error(getResString("err.length", this.getResString("enterprise.visits"), "0", "11"));
+        }
         if (  StringUtils.isNotBlank(enterprise.getEnterpriseContact()) && !StringUtil.checkLength(enterprise.getEnterpriseContact()+"", 0, 255)) {
           return ResultData.build().error(getResString("err.length", this.getResString("enterprise.contact"), "0", "255"));
         }

+ 2 - 1
src/main/java/net/mingsoft/tf/dao/IEnterpriseDao.xml

@@ -6,6 +6,7 @@
 				<result column="ENTERPRISE_NAME" property="enterpriseName" /><!--企业名称 -->
 				<result column="ENTERPRISE_TYPE" property="enterpriseType" /><!--企业类型 -->
 				<result column="ENTERPRISE_BOOTH" property="enterpriseBooth" /><!--展位号 -->
+				<result column="ENTERPRISE_VISITS" property="enterpriseVisits" /><!--访问量 -->
 				<result column="ENTERPRISE_CONTACT" property="enterpriseContact" /><!--联系人 -->
 				<result column="ENTERPRISE_TEL" property="enterpriseTel" /><!--联系电话 -->
 				<result column="ENTERPRISE_ADDRESS" property="enterpriseAddress" /><!--企业地址 -->
@@ -16,7 +17,7 @@
 	</resultMap>
 
 	<select id="query" resultMap="resultMap">
-		SELECT * FROM ENTERPRISE
+		SELECT * FROM MDIY_FORM_ENTERPRISE
 		<where>
 			DEL=0
 			<include refid="net.mingsoft.base.dao.IBaseDao.sqlWhere"></include>

+ 18 - 0
src/main/java/net/mingsoft/tf/entity/EnterpriseEntity.java

@@ -41,6 +41,11 @@ private static final long serialVersionUID = 1765597336717L;
     @TableField(condition = SqlCondition.LIKE)
     private String enterpriseBooth;
     /**
+    * 访问量
+    */
+    
+    private Integer enterpriseVisits;
+    /**
     * 联系人
     */
     @TableField(condition = SqlCondition.LIKE)
@@ -119,6 +124,19 @@ private static final long serialVersionUID = 1765597336717L;
         return this.enterpriseBooth;
     }
     /**
+    * 设置访问量
+    */
+    public void setEnterpriseVisits(Integer enterpriseVisits) {
+        this.enterpriseVisits = enterpriseVisits;
+    }
+
+    /**
+    * 获取访问量
+    */
+    public Integer getEnterpriseVisits() {
+        return this.enterpriseVisits;
+    }
+    /**
     * 设置联系人
     */
     public void setEnterpriseContact(String enterpriseContact) {

+ 2 - 0
src/main/java/net/mingsoft/tf/resources/resources_en_US.properties

@@ -27,6 +27,8 @@ channel=channel
 purpose=purpose
 enterprise.name=enterprise name
 enterprise.type=enterprise type
+enterprise.booth=enterprise booth
+enterprise.visits=enterprise visits
 enterprise.contact=enterprise contact
 enterprise.tel=enterprise tel
 enterprise.address=enterprise address

+ 2 - 0
src/main/java/net/mingsoft/tf/resources/resources_zh_CN.properties

@@ -27,6 +27,8 @@ channel=\u4e86\u89e3\u6e20\u9053
 purpose=\u53c2\u89c2\u76ee\u7684
 enterprise.name=\u4f01\u4e1a\u540d\u79f0
 enterprise.type=\u4f01\u4e1a\u7c7b\u578b
+enterprise.booth=\u5c55\u4f4d\u53f7
+enterprise.visits=\u8bbf\u95ee\u91cf
 enterprise.contact=\u8054\u7cfb\u4eba
 enterprise.tel=\u8054\u7cfb\u7535\u8bdd
 enterprise.address=\u4f01\u4e1a\u5730\u5740

+ 48 - 14
src/main/webapp/WEB-INF/manager/tf/enterprise/form.ftl

@@ -49,6 +49,10 @@
 
                                 </el-col>
                         </el-row>
+                        <el-row
+                                :gutter="0"
+                                justify="start" align="top">
+                                <el-col :span=12>
             <!--展位号-->
 
 	        <el-form-item  label="展位号" prop="enterpriseBooth">
@@ -61,6 +65,22 @@
                         placeholder="请输入展位号">
                 </el-input>
 	        </el-form-item>   
+                                </el-col>
+                                <el-col :span=12>
+            <!--访问量-->
+
+	        <el-form-item  label="访问量" prop="enterpriseVisits">
+	            <el-input
+                        v-model.number="form.enterpriseVisits"
+                         :disabled="false"
+                          :readonly="false"
+                          :style="{width:  '100%'}"
+                          :clearable="true"
+                        placeholder="请输入访问量">
+                </el-input>
+	        </el-form-item>   
+                                </el-col>
+                        </el-row>
                         <el-row
                                 :gutter="0"
                                 justify="start" align="top">
@@ -140,17 +160,13 @@ placeholder="请选择入驻时间"                    :readonly="false"
 
                                 </el-col>
                         </el-row>
-        <!--企业简介-->	
-	        <el-form-item  label="企业简介" prop="enterpriseIntroduction">
-	            <el-input
-                        type="textarea" :rows="5"
-                        :disabled="false"
-                        v-model="form.enterpriseIntroduction"
-                        :style="{width: '100%'}"
-                        placeholder="请输入企业简介">
-                </el-input>
-	        </el-form-item>
-	   
+        <!--企业简介-->
+    
+        <el-form-item  label="企业简介" prop="enterpriseIntroduction">
+             <vue-ueditor-wrap style="line-height: 0px"
+                      v-model="form.enterpriseIntroduction" :config="ms.editorConfig"></vue-ueditor-wrap>
+        </el-form-item>
+   
         <!--LOGO-->
     
         <el-form-item  label="LOGO" prop="enterpriseLogo">
@@ -203,6 +219,8 @@ placeholder="请选择入驻时间"                    :readonly="false"
                     				enterpriseType:"",
                     // 展位号
                     enterpriseBooth:'',
+                    // 访问量
+                    enterpriseVisits:'',
                     // 联系人
                     enterpriseContact:'',
                     // 联系电话
@@ -213,7 +231,7 @@ placeholder="请选择入驻时间"                    :readonly="false"
                    enterpriseEntryTime:"",
                     				// 经营状态
                     				enterpriseOperatingStatus:"",
-                    // 企业简介 
+                    // 企业简介
                     enterpriseIntroduction:'',
                     // LOGO
                     enterpriseLogo: [],
@@ -224,6 +242,8 @@ placeholder="请选择入驻时间"                    :readonly="false"
                         enterpriseName: [{"type":"string","message":"企业名称格式不正确"},{"required":true,"message":"企业名称不能为空"},{"min":0,"max":255,"message":"企业名称长度必须为0-255"}],
                         // 展位号
                         enterpriseBooth: [{"min":0,"max":255,"message":"展位号长度必须为0-255"}],
+                        // 访问量
+                        enterpriseVisits: [{"type":"number","message":"访问量格式不正确"}],
                         // 联系人
                         enterpriseContact: [{"min":0,"max":255,"message":"联系人长度必须为0-255"}],
                         // 联系电话
@@ -236,7 +256,16 @@ placeholder="请选择入驻时间"                    :readonly="false"
             }
         },
         watch:{
-               
+                     disabled: {
+          handler(newVal) {
+            if (newVal === true) {
+              ms.editorConfig.readonly = true;
+            } else {
+              ms.editorConfig.readonly = false;
+            }
+          },
+          immediate: true
+        }
         },
         components:{
         },
@@ -302,7 +331,12 @@ placeholder="请选择入驻时间"                    :readonly="false"
                 ms.http.get(ms.manager + "/tf/enterprise/get.do", {"id":id}).then(function (res) {
                     that.loading = false
                     if(res.result&&res.data) {
-                                                                                                                     if (res.data.enterpriseLogo) {
+                                                         
+                   // 自定义模型需要根据控件配置转换
+                     if(res.data.enterpriseVisits){
+                     	res.data.enterpriseVisits=String(res.data.enterpriseVisits);
+                     }
+                                                                               if (res.data.enterpriseLogo) {
                           res.data.enterpriseLogo = JSON.parse(res.data.enterpriseLogo);
                           res.data.enterpriseLogo.forEach(function (value) {
                              if(!value.url.startsWith("http://") && !value.url.startsWith("https://")){

+ 21 - 1
src/main/webapp/WEB-INF/manager/tf/enterprise/index.ftl

@@ -116,6 +116,8 @@
                         </el-table-column>
                             <el-table-column label="展位号"   align="left" prop="enterpriseBooth">
                             </el-table-column>
+                            <el-table-column label="访问量"   align="right" prop="enterpriseVisits">
+                            </el-table-column>
                             <el-table-column label="联系人"   align="left" prop="enterpriseContact">
                             </el-table-column>
                             <el-table-column label="联系电话"   align="left" prop="enterpriseTel">
@@ -215,6 +217,15 @@
     "type": "input"
     },
     {
+    "isSearch": "",
+    "action": "and",
+    "field": "ENTERPRISE_VISITS",
+    "el": "eq",
+    "model": "enterpriseVisits",
+    "name": "访问量",
+    "type": "number"
+    },
+    {
     "isSearch": "true",
     "action": "and",
     "field": "ENTERPRISE_CONTACT",
@@ -293,7 +304,16 @@
             }
         },
         watch:{
-               
+                     disabled: {
+          handler(newVal) {
+            if (newVal === true) {
+              ms.editorConfig.readonly = true;
+            } else {
+              ms.editorConfig.readonly = false;
+            }
+          },
+          immediate: true
+        }
         },
         methods:{
             isChecked: function(row) {

+ 4 - 4
src/main/webapp/static/locale/lang/enterprise/en_US.js

@@ -5,9 +5,9 @@ var en_US ={
             placeholder:'',
             help:'',
         },
-        enterpriseBooth:{
-            text:'展位号',
-            placeholder:'请输入展位号',
+        gridQobud:{
+            text:'栅格布局',
+            placeholder:'',
             help:'',
         },
         gridZztst:{
@@ -27,7 +27,7 @@ var en_US ={
         },
         enterpriseIntroduction:{
             text:'企业简介',
-            placeholder:'请输入企业简介',
+            placeholder:'',
             help:'',
         },
         enterpriseLogo:{

+ 4 - 4
src/main/webapp/static/locale/lang/enterprise/zh_CN.js

@@ -6,9 +6,9 @@ var zh_CN ={
             placeholder:'',
             help:'',
         },
-        enterpriseBooth:{
-            text:'展位号',
-            placeholder:'请输入展位号',
+        gridQobud:{
+            text:'栅格布局',
+            placeholder:'',
             help:'',
         },
         gridZztst:{
@@ -28,7 +28,7 @@ var zh_CN ={
         },
         enterpriseIntroduction:{
             text:'企业简介',
-            placeholder:'请输入企业简介',
+            placeholder:'',
             help:'',
         },
         enterpriseLogo:{