En route hai 1 ano
pai
achega
cb57684769

+ 4 - 2
.env.development

@@ -5,8 +5,10 @@ VUE_APP_TITLE =广州市建设工程消防协会
 ENV = 'development'
 
 # 开发环境
-VUE_APP_BASE_API = 'http://192.168.1.12:8032/'
-VUE_APP_IMG_API = 'http://192.168.1.12:8032'
+VUE_APP_BASE_API = 'http://192.168.1.121:8032/'
+VUE_APP_IMG_API = 'http://192.168.1.121:8032'
+# 开发环境-h5端地址
+VUE_APP_JUMP = 'http://192.168.1.20:8082'
 
 # 路由懒加载
 VUE_CLI_BABEL_TRANSPILE_MODULES = true

+ 2 - 0
.env.production

@@ -7,6 +7,8 @@ ENV = 'production'
 # 生产环境
 VUE_APP_BASE_API = 'https://api.gzxfxh2022.com/'
 VUE_APP_IMG_API = 'https://api.gzxfxh2022.com'
+# 生产环境-移动端地址
+VUE_APP_JUMP = 'https://sj.gzxfxh2022.com'
 
 # 路由懒加载
 VUE_CLI_BABEL_TRANSPILE_MODULES = true

+ 1 - 1
src/assets/css/index.scss

@@ -202,7 +202,7 @@ input[type="number"]::-webkit-outer-spin-button {
 
 .el-dialog {
   border-radius: 8px !important;
-
+  margin-top: 3vh!important;
   .el-dialog__header {
     border-bottom: 1px solid #d3d3d3aa;
     & > .el-dialog__title {

+ 28 - 20
src/components/membership/index.vue

@@ -17,6 +17,7 @@
         <el-row>
           <el-col
             v-for="(item, index) in ruleList"
+            :key="index"
             :span="item.span ? item.span : 12"
             ><el-form-item :label="item.label" :prop="item.prop">
               <el-select
@@ -27,7 +28,7 @@
               >
                 <el-option
                   v-for="items in options1"
-                  :key="item.value"
+                  :key="items.value"
                   :label="items.text"
                   :value="items.value"
                 >
@@ -41,7 +42,7 @@
               >
                 <el-option
                   v-for="items in options2"
-                  :key="item.value"
+                  :key="items.value"
                   :label="items.text"
                   :value="items.value"
                 >
@@ -51,9 +52,12 @@
                 v-model="ruleForm[item.prop]"
                 v-else-if="item.scope === 'options'"
               >
-                <el-radio v-for="items in item.options" :label="items.value">{{
-                  items.label
-                }}</el-radio>
+                <el-radio
+                  v-for="(items, indexs) in item.options"
+                  :key="indexs"
+                  :label="items.value"
+                  >{{ items.label }}</el-radio
+                >
               </el-radio-group>
 
               <el-date-picker
@@ -78,13 +82,16 @@
                   :href="$methods.splitImgHost(ruleForm.FilePath)"
                   target="_blank"
                   class="file_style"
-                  >点击查看文件</a
+                  >已上传(点击可查看下载)</a
                 >
                 <label for="uploads" style="vertical-align: text-bottom"
                   ><span class="btn">{{
                     ruleForm[item.prop] ? "更换文件" : "上传文件"
                   }}</span></label
                 >
+                <span style="margin-left: 20px; color: red"
+                  >(支持所有办公文件格式,多个文件请使用压缩包格式上传)</span
+                >
                 <input
                   type="file"
                   id="uploads"
@@ -254,6 +261,7 @@ export default {
           label: "资料上传",
           prop: "FilePath",
           scope: "file",
+          span: 24,
         },
       ],
       ruleForm: { CompanyTypeName: "", MemberLevel: "" },
@@ -297,21 +305,21 @@ export default {
       if (file === undefined) {
         return;
       }
-      if (file.size > 10 * 1024 * 1024) {
-        self.$message.error("文件不得大于10MB");
-        return;
-      }
-      var type = e.target.value.toLowerCase().split(".").splice(-1);
-      if (
-        type[0] != "jpg" &&
-        type[0] != "pdf" &&
-        type[0] != "png" &&
-        type[0] != "jpeg"
-      ) {
-        self.$message.error("上传格式需为:.jpg/.png/.jpeg/.pdf");
-        e.target.value = "";
+      if (file.size > 50 * 1024 * 1024) {
+        self.$message.error("文件不得大于50MB");
         return;
       }
+      // var type = e.target.value.toLowerCase().split(".").splice(-1);
+      // if (
+      //   type[0] != "jpg" &&
+      //   type[0] != "pdf" &&
+      //   type[0] != "png" &&
+      //   type[0] != "jpeg"
+      // ) {
+      //   self.$message.error("上传格式需为:.jpg/.png/.jpeg/.pdf");
+      //   e.target.value = "";
+      //   return;
+      // }
       let formDatas = new FormData();
       formDatas.append("file", file);
       this.$api
@@ -394,6 +402,6 @@ export default {
 }
 .btn {
   cursor: pointer;
-  color:red;
+  color: rgb(0, 102, 255);
 }
 </style>

+ 8 - 2
src/components/table/index.vue

@@ -21,15 +21,17 @@
       <el-table-column align="center" type="index"></el-table-column>
       <template v-for="(item, index) in tableList">
         <el-table-column
+        :key="index"
           header-align="center"
           :align="item.align ? item.align : 'center'"
           :prop="item.prop"
           :label="item.label"
           :width="item.width || ''"
+          :show-overflow-tooltip="item.tooltipShow || false"
           ><template slot-scope="scope"
             ><div v-if="item.scope === 'options'">
               <template v-for="(itemt, indext) in item.options">
-                <span v-if="itemt.value === scope.row[item.prop]">{{
+                <span v-if="itemt.value === scope.row[item.prop]" :key="indext">{{
                   itemt.label
                 }}</span>
               </template>
@@ -131,4 +133,8 @@ export default {
 };
 </script>
 
-<style lang="scss" scoped></style>
+<style lang="scss">
+.el-tooltip__popper.is-dark{
+  max-width: 500px!important;
+}
+</style>

+ 3 - 3
src/components/tinymce/index.vue

@@ -90,8 +90,8 @@ export default {
               if (file === undefined) {
                 return;
               }
-              if (file.size > 5 * 1024 * 1024) {
-                self.$message.error("文件不得大于5M");
+              if (file.size > 50 * 1024 * 1024) {
+                self.$message.error("文件不得大于50M");
                 return;
               }
               var type = file.name.toLowerCase().split(".").splice(-1);
@@ -202,7 +202,7 @@ export default {
       tinymce.editors["tinymce"].destroy();
     },
   },
-  deactivated() {
+  beforeDestroy() {
     console.log("触发");
     tinymce.editors["tinymce"].destroy();
   },

+ 4 - 1
src/router/index.js

@@ -11,7 +11,10 @@ const originalPush = VueRouter.prototype.push
 VueRouter.prototype.push = function push(location) {
   return originalPush.call(this, location).catch((err) => err)
 }
-
+const originalReplace = VueRouter.prototype.replace
+VueRouter.prototype.replace = function replace(location) {
+  return originalReplace.call(this, location).catch((err) => err)
+}
 const routes = [
   {
     path: '/',

+ 1 - 5
src/utils/permission.js

@@ -71,11 +71,7 @@ router.beforeEach(async (to, from, next) => {
 
   } else {
     if (!store.state.isDesktop) {
-      // request.getWeAppLink().then(res => {
-      //   console.log("isDesktop")
-      //   res.msg && (window.location.href = res.msg);
-      // });
-      // window.location.href = 'http://192.168.1.20:8081/home'
+      window.location.href = process.env.VUE_APP_JUMP + to.fullPath
     }
     // 前台处理
     if (to.matched.length === 0) {//未匹配到的时候跳转到404页面

+ 3 - 2
src/views/System/contentSet/advertisement/operation.vue

@@ -166,8 +166,8 @@ export default {
       if (file === undefined) {
         return;
       }
-      if (file.size > 0.3 * 1024 * 1024) {
-        self.$message.error("图片不得大于300kb");
+      if (file.size > 10 * 1024 * 1024) {
+        self.$message.error("图片不得大于10MB");
         return;
       }
       var type = e.target.value.toLowerCase().split(".").splice(-1);
@@ -192,6 +192,7 @@ export default {
       this.$refs[formName].validate(async (valid) => {
         if (valid) {
           this.$api.XfSysBussinessSaveBanner(this.ruleForm).then((res) => {
+            this.$message.success("操作成功");
             this.close();
             this.$parent.search();
           });

+ 8 - 3
src/views/System/contentSet/article/operation.vue

@@ -101,7 +101,11 @@
                 :min-height="300"
                 :max-height="500" /> -->
               <div class="tinymce-box">
-                <editor ref="tinymceRef" :value="ruleForm.NewContent"></editor>
+                <editor
+                  v-if="dialogVisible"
+                  ref="tinymceRef"
+                  :value="ruleForm.NewContent"
+                ></editor>
               </div>
             </el-form-item>
           </el-col>
@@ -179,8 +183,8 @@ export default {
       if (file === undefined) {
         return;
       }
-      if (file.size > 0.9 * 1024 * 1024) {
-        self.$message.error("图片不得大于900kb");
+      if (file.size > 10 * 1024 * 1024) {
+        self.$message.error("图片不得大于10MB");
         return;
       }
       var type = e.target.value.toLowerCase().split(".").splice(-1);
@@ -210,6 +214,7 @@ export default {
         if (valid) {
           this.ruleForm.NewContent = this.$refs.tinymceRef.getContent();
           this.$api.XfSysBussinessSaveNews(this.ruleForm).then((res) => {
+            this.$message.success("操作成功");
             this.close();
             this.$parent.search();
           });

+ 7 - 6
src/views/System/contentSet/homeSet/operation.vue

@@ -114,7 +114,7 @@ export default {
         {
           label: "编号",
           prop: "NewsId",
-          width:"90"
+          width: "90",
         },
         {
           label: "标题",
@@ -128,7 +128,7 @@ export default {
             { label: "是", value: true },
             { label: "否", value: false },
           ],
-          width:"90"
+          width: "90",
         },
         {
           label: "会员可见",
@@ -138,18 +138,18 @@ export default {
             { label: "是", value: true },
             { label: "否", value: false },
           ],
-          width:"90"
+          width: "90",
         },
         {
           label: "所属项目",
           prop: "MenuName",
-          width:"90"
+          width: "90",
         },
         {
           label: "创建时间",
           prop: "CreateTime",
           scope: "time",
-          width:"140"
+          width: "140",
         },
         {
           label: "状态",
@@ -159,7 +159,7 @@ export default {
             { label: "停用", value: 0 },
             { label: "正常", value: 1 },
           ],
-          width:"90"
+          width: "90",
         },
       ],
       total: 0,
@@ -215,6 +215,7 @@ export default {
               type: this.ruleForm.TypeId,
             })
             .then((res) => {
+              this.$message.success("操作成功");
               this.close();
               this.$parent.search();
             });

+ 2 - 1
src/views/System/contentSet/websiteMenu/index.vue

@@ -16,6 +16,7 @@
       <el-table-column align="center" type="index"></el-table-column>
       <template v-for="(item, index) in tableList">
         <el-table-column
+        :key="index"
           header-align="center"
           :align="item.align ? item.align : 'center'"
           :prop="item.prop"
@@ -25,7 +26,7 @@
           <template slot-scope="scope">
             <div v-if="item.scope === 'options'">
               <template v-for="(itemt, indext) in item.options">
-                <span v-if="itemt.value === scope.row[item.prop]">{{
+                <span v-if="itemt.value === scope.row[item.prop]" :key="indext">{{
                   itemt.label
                 }}</span>
               </template>

+ 1 - 0
src/views/System/systemSet/list/operation.vue

@@ -170,6 +170,7 @@ export default {
       this.$refs[formName].validate((valid) => {
         if (valid) {
           this.$api.XfSystemApiSaveAdminUser(this.listData).then((res) => {
+              this.$message.success("操作成功");
             this.close();
             this.$parent.search();
           });

+ 1 - 0
src/views/System/systemSet/roles/operation.vue

@@ -166,6 +166,7 @@ export default {
           var data = JSON.parse(JSON.stringify(this.listData));
           data.MenuIds = this.getMenuAllCheckedKeys();
           this.$api.XfSystemApiSaveRole(data).then((res) => {
+            this.$message.success("操作成功");
             this.close();
             this.$parent.search();
           });

+ 1 - 0
src/views/System/vip/friendshipLink/operation.vue

@@ -81,6 +81,7 @@ export default {
           this.$api
             .XfSysBussinessSaveWebFriendlinks(this.ruleForm)
             .then((res) => {
+              this.$message.success("操作成功");
               this.close();
               this.$parent.search();
             });

+ 7 - 3
src/views/System/vip/notice/operation.vue

@@ -24,6 +24,7 @@
             <el-form-item label="通知" prop="EmailContent">
               <div class="tinymce-box">
                 <editor
+                  v-if="dialogVisible"
                   ref="tinymceRef"
                   :value="ruleForm.EmailContent"
                 ></editor>
@@ -93,9 +94,6 @@ export default {
       },
       rules: {
         Title: [{ required: true, message: "请输入标题", trigger: "blur" }],
-        EmailContent: [
-          { required: true, message: "请输入通知", trigger: "blur" },
-        ],
       },
       loading: false,
       formData: { pageindex: 1, pagesize: 10 },
@@ -290,15 +288,21 @@ export default {
       this.clearCheck();
       this.loading = false;
       this.$refs["ruleForm"].resetFields();
+      // this.dialogVisible = false;
       done();
     },
     submit(formName) {
       this.$refs[formName].validate(async (valid) => {
         if (valid) {
+          if (this.ruleForm.ItemList.length == 0) {
+            this.$message.error("请勾选需要通知的会员单位");
+            return;
+          }
           this.ruleForm.EmailContent = this.$refs.tinymceRef.getContent();
           this.$api
             .XfSysBussinessSaveActivityDetail(this.ruleForm)
             .then((res) => {
+              this.$message.success("操作成功");
               this.dialogVisible = false;
               this.$parent.search();
             });

+ 1 - 0
src/views/System/vip/suggestion/index.vue

@@ -68,6 +68,7 @@ export default {
         {
           label: "留言/建议",
           prop: "ProposeContent",
+          tooltipShow:true
         },
         {
           label: "时间",

+ 1 - 0
src/views/contribute/operation.vue

@@ -99,6 +99,7 @@
             <el-form-item label="文章内容" prop="NewContent">
               <div class="tinymce-box">
                 <editor
+                v-if="dialogVisible"
                   ref="tinymceRef"
                   :value="ruleForm.NewContent"
                   :imgUrl="'XfWebApiUploadFile'"

+ 9 - 0
src/views/home/index.vue

@@ -3,6 +3,7 @@
     <el-carousel height="500px" loop>
       <el-carousel-item v-for="(item, index) in BannerList1" :key="index">
         <img
+          @click="jumpUrl(item.JumpUrl)"
           style="width: 100%; height: 100%"
           :src="$methods.splitImgHost(item.ImageUrl)"
         />
@@ -20,6 +21,7 @@
         <li
           class="lis"
           v-for="(item, index) in tableData"
+          :key="index"
           @click="jumpInfo(item)"
         >
           <div class="top">
@@ -37,6 +39,7 @@
         <el-carousel height="350px" style="width: 560px" class="carousel">
           <el-carousel-item v-for="(item, index) in BannerList2" :key="index">
             <img
+              @click="jumpUrl(item.JumpUrl)"
               style="width: 100%; height: 100%"
               :src="$methods.splitImgHost(item.ImageUrl)"
               alt=""
@@ -416,6 +419,12 @@ export default {
           break;
       }
     },
+    jumpUrl(url) {
+      if (url) {
+        window.open(url, "_blank");
+      }
+      return;
+    },
     jumpWL(e) {
       window.open(e.Friendlinks, "_blank");
       return;

+ 2 - 1
src/views/info/index.vue

@@ -63,7 +63,7 @@ export default {
       infoData: {},
       headerData: {},
       config: {
-        // url: "", // 网址,默认使用 window.location.href
+        url: window.location.href, // 网址,默认使用 window.location.href
         source: "", // 来源(QQ空间会用到), 默认读取head标签:<meta name="site" content="http://overtrue" />
         title: "", // 标题,默认读取 document.title 或者 <meta name="title" content="share.js" />
         description: "", // 描述, 默认读取head标签:<meta name="description" content="PHP弱类型的实现原理分析" />
@@ -107,6 +107,7 @@ export default {
       this.getHeaderTitleData();
       //获取侧边栏列表
       this.getList();
+      console.log(window.location.href,'href')
     },
     getHeaderTitleData() {
       this.$api

+ 3 - 0
vue.config.js

@@ -8,6 +8,9 @@ function resolve(dir) {
 // 是否为生产环境
 const isProduction = process.env.ENV !== 'development'
 module.exports = {
+    devServer: {
+        port: 8081,
+    },
     lintOnSave: false,//禁用代码检测
     productionSourceMap: false,
     configureWebpack: {