瀏覽代碼

提交签约详情-及用户管理中字段

plg 5 月之前
父節點
當前提交
3076732d03

+ 215 - 50
src/components/EditHomeRegister.vue

@@ -11,10 +11,10 @@
         :model="ruleForm"
         :rules="rules"
         ref="ruleForm"
-        label-width="120px"
+        label-width="150px"
         class="demo-ruleForm"
       >
-        <el-row>
+        <!-- <el-row>
           <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
             <el-form-item label="头像" prop="avatar">
               <el-upload
@@ -43,56 +43,175 @@
               ></el-input>
             </el-form-item>
           </el-col>
-        </el-row>
+        </el-row> -->
         <el-row>
           <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
-            <el-form-item label="个人描述" prop="description">
+            <el-form-item label="报告来源" prop="description">
               <el-input
-                v-model="ruleForm.description"
+                v-model="ruleForm.reportSource"
                 class="inputCom"
-                placeholder="请输入描述"
+                placeholder="请输入报告来源"
               ></el-input>
             </el-form-item>
           </el-col>
           <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
-            <el-form-item label="岗位" prop="job">
+            <el-form-item label="公司名称" prop="companyName">
               <el-input
                 v-model="ruleForm.job"
                 class="inputCom"
-                placeholder="请输入岗位"
+                placeholder="请输入公司名称"
               ></el-input>
             </el-form-item>
           </el-col>
           <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
-            <el-form-item label="邮箱" prop="mail">
+            <el-form-item label="公司英文名称" prop="companyEname">
               <el-input
-                v-model="ruleForm.mail"
+                v-model="ruleForm.companyEname"
                 class="inputCom"
-                placeholder="请输入邮箱"
+                placeholder="请输入公司英文名称"
               ></el-input>
             </el-form-item>
           </el-col>
           <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
-            <el-form-item label="手机号" prop="phone">
+            <el-form-item label="是否展示详细信息" prop="isDetail">
+              <el-select v-model="ruleForm.isDetail" placeholder="请选择状态">
+                <el-option
+                  :label="item.name"
+                  :value="item.id"
+                  v-for="item in isDetailList"
+                  :key="item.id"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="公司logo" prop="logo">
+              <el-upload
+                accept=".png, .jpg, .jpeg"
+                class="avatar-uploader"
+                name="file"
+                :action="action"
+                :show-file-list="false"
+                :on-success="handleLogoSuccess"
+                :before-upload="beforeAvatarUpload"
+              >
+                <img v-if="ruleForm.logo" :src="ruleForm.logo" class="avatar" />
+                <i v-else class="el-icon-plus avatar-uploader-icon"></i>
+                <div class="el-upload__tip" slot="tip">
+                  建议上传jpg/png/jpeg文件,且不超过500kb
+                </div>
+              </el-upload>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="首页二维码" prop="firstPageCode">
+              <el-upload
+                accept=".png, .jpg, .jpeg"
+                class="avatar-uploader"
+                name="file"
+                :action="action"
+                :show-file-list="false"
+                :on-success="handleFirstPageCodeSuccess"
+                :before-upload="beforeAvatarUpload"
+              >
+                <img v-if="ruleForm.firstPageCode" :src="ruleForm.firstPageCode" class="avatar" />
+                <i v-else class="el-icon-plus avatar-uploader-icon"></i>
+                <div class="el-upload__tip" slot="tip">
+                  建议上传jpg/png/jpeg文件,且不超过500kb
+                </div>
+              </el-upload>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="网址" prop="webAddress">
+              <el-input
+                v-model="ruleForm.webAddress"
+                class="inputCom"
+                placeholder="请输入网址"
+              ></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="邮箱" prop="mail">
               <el-input
-                v-model="ruleForm.phone"
+                v-model="ruleForm.mail"
                 class="inputCom"
-                placeholder="请输入手机号"
+                placeholder="请输入邮箱"
               ></el-input>
             </el-form-item>
           </el-col>
           <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
-            <el-form-item label="状态" prop="state">
-              <el-select v-model="ruleForm.state" placeholder="请选择状态">
+            <el-form-item label="是否展示尾页二维码" prop="isCode">
+              <el-select v-model="ruleForm.state" placeholder="请选择是否展示尾页二维码">
+                <el-option
+                  :label="item.name"
+                  :value="item.id"
+                  v-for="item in isCodeList"
+                  :key="item.id"
+                ></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="是否展示尾页公司名及地址" prop="isLastPageName">
+              <el-select v-model="ruleForm.isLastPageName" placeholder="请选择是否展示尾页公司名及地址">
                 <el-option
                   :label="item.name"
-                  :value="item.state"
-                  v-for="item in stateList"
-                  :key="item.state"
+                  :value="item.id"
+                  v-for="item in isLastPageNameList"
+                  :key="item.id"
                 ></el-option>
               </el-select>
             </el-form-item>
           </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="尾页公司名" prop="lastPageName">
+              <el-input
+                v-model="ruleForm.lastPageName"
+                class="inputCom"
+                placeholder="请输入尾页公司名"
+              ></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="尾页公司地址" prop="lastPageAddress">
+              <el-input
+                v-model="ruleForm.lastPageAddress"
+                class="inputCom"
+                placeholder="请输入尾页公司地址"
+              ></el-input>
+            </el-form-item>
+          </el-col>
+           <el-row>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="尾页二维码" prop="lastPageCode">
+              <el-upload
+                accept=".png, .jpg, .jpeg"
+                class="avatar-uploader"
+                name="file"
+                :action="action"
+                :show-file-list="false"
+                :on-success="handleLastPageCodeSuccess"
+                :before-upload="beforeAvatarUpload"
+              >
+                <img v-if="ruleForm.lastPageCode" :src="ruleForm.lastPageCode" class="avatar" />
+                <i v-else class="el-icon-plus avatar-uploader-icon"></i>
+                <div class="el-upload__tip" slot="tip">
+                  建议上传jpg/png/jpeg文件,且不超过500kb
+                </div>
+              </el-upload>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <el-form-item label="姓名" prop="name">
+              <el-input
+                v-model="ruleForm.name"
+                class="inputCom"
+                placeholder="请输入姓名"
+              ></el-input>
+            </el-form-item>
+          </el-col>
+        </el-row>
         </el-row>
       </el-form>
       <span slot="footer" class="dialog-footer">
@@ -154,42 +273,74 @@ export default {
         { name: "签约", state: "1" },
         { name: "解约", state: "0" },
       ],
+      isDetailList: [
+        { name: "是", id: "1" },
+        { name: "否", id: "0" },
+      ],
+      isCodeList:[
+        { name: "是", id: "1" },
+        { name: "否", id: "0" },
+      ],
+      isLastPageNameList:[
+        { name: "是", id: "1" },
+        { name: "否", id: "0" },
+      ],
       ruleForm: {
-        id: "",
+        //渠道ID
         channelId: "",
-        //头像
-        avatar: "",
-        //员工姓名
-        name: "",
-        //描述
-        description: "",
-        //岗位
-        job: "",
+        //报告来源
+        reportSource: "",
+        //公司名称
+        companyName: "",
+        //是否展示详细信息
+        isDetail: "",
+        //公司英文名称
+        companyEname: "",
+        //网址
+        webAddress: "",
+        //是否展示尾页二维码
+        isCode: "",
+        //是否展示尾页公司名称及地址
+        isLastPageName: "",
+        // //尾页公司名称
+        lastPageName: "",
+        //尾页公司地址
+        lastPageAddress: "",
+        //是否删除
+        isDelete: "",
+        //主键
+        id: "",
         //邮箱
         mail: "",
-        //手机号
-        phone: "",
-        //状态
-        state: "",
-        // //删除状态
-        isDelete: "0",
+        //尾页二维码
+        lastPageCode: "",
+        //公司logo
+        logo: "",
+        //首页二维码
+        firstPageCode: "",
       },
       isView: true,
       rules: {
-        name: [{ required: true, message: "请输入姓名", trigger: "blur" }],
-        phone: [
-          { required: true, message: "请输入手机号", trigger: "blur" },
-          {
-            pattern: /^1[3456789]\d{9}$/,
-            message: "请输入正确的手机号",
-            trigger: ["blur", "change"],
-          },
+        reportSource: [{ required: true, message: "请输入报告来源", trigger: "blur" }],
+        // phone: [
+        //   { required: true, message: "请输入手机号", trigger: "blur" },
+        //   {
+        //     pattern: /^1[3456789]\d{9}$/,
+        //     message: "请输入正确的手机号",
+        //     trigger: ["blur", "change"],
+        //   },
+        // ],
+        isDetail: [
+          { required: true, message: "请选择是否展示详细信息", trigger: "change" },
         ],
-        state: [{ required: true, message: "请输选择状态", trigger: "change" }],
-        mail: [
-          { required: true, message: "请输选择邮箱", trigger: "blur" },
-          { type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"] },
+
+        isLastPageName: [
+          { required: true, message: "是否展示尾页公司名称及地址", trigger: "change" },
         ],
+        // mail: [
+        //   { required: true, message: "请输选择邮箱", trigger: "blur" },
+        //   { type: "email", message: "请输入正确的邮箱地址", trigger: ["blur", "change"] },
+        // ],
       },
     };
   },
@@ -215,12 +366,25 @@ export default {
       }
       return true;
     },
-    //handleAvatarSuccess
+  
     //上传成功后的回调
-    handleAvatarSuccess(data) {
+    handleLogoSuccess(data) {
+      if (data.code == 200) {
+        this.ruleForm.logo = basePath + "/file/show?filePath=" + data.data;
+      } else {
+        //失败
+      }
+    },
+    handleFirstPageCodeSuccess(){
+      if (data.code == 200) {
+        this.ruleForm.firstPageCode = basePath + "/file/show?filePath=" + data.data;
+      } else {
+        //失败
+      }
+    },
+    handleLastPageCodeSuccess(){
       if (data.code == 200) {
-        this.ruleForm.avatar = basePath + "/file/show?filePath=" + data.data;
-     
+        this.ruleForm.lastPageCode = basePath + "/file/show?filePath=" + data.data;
       } else {
         //失败
       }
@@ -266,6 +430,7 @@ export default {
       }
     },
     open(val) {
+      debugger;
       this.dialogVisible = true;
       this.isView = val;
 

+ 0 - 2
src/views/login.vue

@@ -219,8 +219,6 @@ export default {
     //注册的时候尽量使用一种方式,账号密码的方式,因为一个人同时用两种会当为俩客户。
     //注册信息需要哪些?
     //管理员在哪下载二维码
-
-    console.log(this.$route.query.id);
   },
   activated() {},
   methods: {

+ 12 - 1
src/views/manage/channelInfo/channelUserManage.vue

@@ -56,6 +56,8 @@
             width=""
           >
           </el-table-column>
+          <el-table-column prop="reportNum" label="报告数量" align="center" width="">
+          </el-table-column>
           <!-- <el-table-column
             prop="isDelete"
             label="删除状态"
@@ -152,6 +154,15 @@
               </div>
             </div>
           </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <div class="user_out">
+              <div class="user_out_sub">报告数量</div>
+              <div class="user_out_subNext">
+                {{ detailObj.reportNum}}
+              </div>
+            </div>
+          </el-col>
+          
         </el-row>
       </div>
     </el-dialog>
@@ -324,7 +335,7 @@ export default {
         (res) => {
           // console.log(res,'用户测试记录')
           if (res && res.code == 200) {
-            this.tableData = res.data.content;
+            this.tableData = res.data.data;
             this.total = res.data.totalElements;
           } else {
             // this.$toast.fail(res.msg);

+ 1 - 1
src/views/manage/channelManagement/channelManagement.vue

@@ -295,7 +295,7 @@ export default {
       }
     },
     resetUser(index, val) {
-      console.log(val);
+  
       this.$http.get(`/user/reset/${val.id}`, {}, (res) => {
         //  this.$toast.success({message:'成功'});
         if (res && res.code == 200) {

+ 5 - 4
src/views/manage/channelManagement/contract.vue

@@ -107,13 +107,13 @@
                 @click="viewPoster(scope.row)"
                 >查看海报</el-button
               >
-              <el-button
+              <!-- <el-button
                 type="text"
                 size="small"
                 v-if="scope.row.state != 0"
                 @click="editHomeFun(scope.row)"
-                >编辑首页</el-button
-              >
+                >PDF设置</el-button
+              > -->
               <el-button
                 type="text"
                 size="small"
@@ -341,7 +341,8 @@ export default {
   methods: {
     //编辑首页
     editHomeFun(row){
-      this.$router.push({path:'/manage/editHomePage',query:{id:row.id}})
+      debugger;
+      this.$router.push({path:'/manage/editHomePage',query:{channelId:row.channelId}})
     },
     //充值次数
     topUpCount(row){

+ 11 - 13
src/views/manage/channelManagement/editHomePage.vue

@@ -14,7 +14,7 @@
       <el-row class="add_user_class">
         <el-col :span="24">
           <div class="search-head">
-            <el-button type="primary" round icon="el-icon-plus" @click="addUser"
+            <el-button type="success" round icon="el-icon-plus" @click="addUser"
               >新增</el-button
             >
             <el-button type="primary" round icon="el-icon-back" @click="goBack"
@@ -102,7 +102,7 @@
           </el-table-column>
         </el-table>
       </div>
-
+<!-- 
       <el-pagination
         small
         background
@@ -112,7 +112,7 @@
         :page-size="pageSize"
         :total="total"
       >
-      </el-pagination>
+      </el-pagination> -->
       <!-- <el-pagination small background layout="total prev, pager, next" :total="36">
           </el-pagination> -->
     </div>
@@ -216,11 +216,13 @@ export default {
       type: 0,
 
       detailObj: {},
+      channelId:''
     };
   },
   created() {},
   mounted() {
     this.userInfo = JSON.parse(oSessionStorage.getItem("userInfo"));
+    this.channelId=this.$route.query.channelId
     if (!this.userInfo) {
       //如果用户信息不存在跳转登陆页
       this.$router.push({ path: "/" });
@@ -302,7 +304,7 @@ export default {
       }
     },
     addRegisterUser(val) {
-      this.$refs.register.open(val);
+      this.$refs.register.open(this.channelId);
     },
     editRegisterUser(val) {
       this.$refs.register.edit(val);
@@ -326,20 +328,16 @@ export default {
     //根据现有情况进行搜索
     searchList() {
       //  let url =``
-      this.$http.post(
-        `/staff/find`,
+      this.$http.get(
+        `/pdf/find/${this.channelId}`,
         {
-          pageNum: this.pageNum,
-          pageSize: this.pageSize,
-          
-          // name: this.name,
-          // isDelete: 0,
         },
         (res) => {
+          debugger;
           // console.log(res,'用户测试记录')
           if (res && res.code == 200) {
-            this.tableData = res.data.content;
-            this.total = res.data.totalElements;
+            this.tableData = res.data;
+            // this.total = res.data.totalElements;
           } else {
             // this.$toast.fail(res.msg);
             this.$message.error(res.msg);

+ 12 - 1
src/views/manage/channelManagement/staff.vue

@@ -56,6 +56,8 @@
             width=""
           >
           </el-table-column>
+          <el-table-column prop="reportNum" label="报告数量" align="center" width="">
+          </el-table-column>
           <!-- <el-table-column
             prop="isDelete"
             label="删除状态"
@@ -169,6 +171,14 @@
               </div>
             </div>
           </el-col>
+          <el-col :xs="24" :sm="24" :md="12" :lg="12" :xl="12">
+            <div class="user_out">
+              <div class="user_out_sub">报告数量</div>
+              <div class="user_out_subNext">
+                {{ detailObj.reportNum}}
+              </div>
+            </div>
+          </el-col>
         </el-row>
       </div>
     </el-dialog>
@@ -348,9 +358,10 @@ export default {
           // isDelete: 0,
         },
         (res) => {
+          debugger;
           // console.log(res,'用户测试记录')
           if (res && res.code == 200) {
-            this.tableData = res.data.content;
+            this.tableData = res.data.data;
             this.total = res.data.totalElements;
           } else {
             // this.$toast.fail(res.msg);

+ 4 - 5
src/views/manage/manageMain.vue

@@ -497,7 +497,6 @@ export default {
     if (oSessionStorage.getItem("userInfo")) {
       this.userInfo = JSON.parse(oSessionStorage.getItem("userInfo"));
       this.userType = this.userInfo.type;
-      console.log(this.userInfo, "有用户信息吗");
       //假如是代理用户则 //代理用户菜单不显示
       if (this.userType == "0") {
         for (let i = 0; i < this.menuList.length; i++) {
@@ -522,7 +521,7 @@ export default {
     this.active = this.$route.path;
     this.selectMenu(this.$route.path);
     this.bus.$on("menuStatusUpdate", (e) => {
-      console.log(that.$refs.menu.activeIndex);
+
       that.$refs.menu.activeIndex = e;
       that.active = e;
       //  that.$forceUpdate()
@@ -541,7 +540,7 @@ export default {
     },
     //匹配获取页签名称-2020-03-17 lwl
     selectMenu(param) {
-      console.log(param, "888");
+
       this.menuList.forEach((item) => {
         if (item.path == param) {
           this.crumbParent = item.name;
@@ -582,7 +581,7 @@ export default {
 
     /*lxh-修改密码*/
     submitForm(formName) {
-      console.log(this.userInfo);
+
       this.$refs[formName].validate((valid) => {
         if (valid) {
           this.$http.post(
@@ -624,7 +623,7 @@ export default {
     // 重置表单
     resetForm(formName) {
       this.$refs[formName].resetFields();
-      console.log(this.userType);
+
     },
     // 修改密码
     changePwd() {

+ 30 - 5
src/views/manage/userManage.vue

@@ -7,7 +7,16 @@
             <span>用户名:</span>
             <el-input v-model="name" clearable placeholder="请输入用户名"></el-input>&nbsp;&nbsp;&nbsp;&nbsp;
             <span>用户昵称:</span>
-            <el-input v-model="userName" clearable placeholder="请输入用户昵称"></el-input>&nbsp;&nbsp;
+            <el-input v-model="userName" clearable placeholder="请输入用户昵称"></el-input>&nbsp;&nbsp;&nbsp;&nbsp;
+            <span>渠道:</span>
+            <el-select v-model="channel" placeholder="请选择渠道">
+              <el-option
+                :label="item.name"
+                :value="item.id"
+                v-for="item in channelList"
+                :key="item.id"
+              ></el-option> </el-select
+            >&nbsp;&nbsp;&nbsp;&nbsp;
             <el-button type="primary" round icon="el-icon-search" @click="searchTarget">搜索</el-button>
             <el-button type="info" round icon="el-icon-delete-solid" @click="clearSearch">清空</el-button>
             <el-button type="success" round class="add_class" icon="el-icon-plus" @click="addUser">新增用户</el-button>
@@ -32,7 +41,7 @@
           </el-table-column>
           <!-- <el-table-column prop="state" label="用户状态" align="center" :formatter="formatterDelete" width="">
           </el-table-column> -->
-          <el-table-column prop="channelId" label="所属渠道ID" align="center" width=""></el-table-column>
+          <el-table-column prop="channelName" label="所属渠道" align="center" width=""></el-table-column>
           <el-table-column prop="type" label="所属角色" align="center" width="" :formatter="formatterRole"
             show-overflow-tooltip>
           </el-table-column>
@@ -85,7 +94,7 @@
             所属渠道
           </div>
           <div class="user_out_subNext">
-            {{ view.channelId }}
+            {{ view.channelName }}
           </div>
           <div class="user_out_sub">
             所属角色
@@ -135,13 +144,15 @@ export default {
         channelId: '',
         role: ''
       },
+      channel:'',
+      channelList: [{ name: "渠道天成", id: "1" }],
     };
   },
   created() { },
   mounted() {
     this.userInfo = JSON.parse(oSessionStorage.getItem("userInfo"));
     
-    
+    this.getChannel();
     if (!this.userInfo) {
       //如果用户信息不存在跳转登陆页
       this.$router.push({ path: "/" });
@@ -149,6 +160,18 @@ export default {
     this.searchTarget();
   },
   methods: {
+     //获取渠道信息
+     getChannel() {
+      this.$http.get(`/channel/findAll`, {}, (res) => {
+        //  this.$toast.success({message:'成功'});
+        if (res && res.code == 200) {
+          //将值赋值给list
+          this.channelList = res.data;
+        } else {
+          this.$message.error(res.msg);
+        }
+      });
+    },
     formatterDelete(row) {
       if (row.state == 0) {
         return '已删除'
@@ -187,6 +210,7 @@ export default {
     clearSearch() {
       this.name = "";
       this.userName = "";
+      this.channel='';
       this.searchTarget();
     },
     formatterRole(val) {
@@ -237,11 +261,12 @@ export default {
           phone: "",
           name: this.name,
           userName: this.userName,
+          channelId:this.channel
         },
         (res) => {
           // console.log(res,'用户测试记录')
           if (res && res.code == 200) {
-            this.tableData = res.data.content;
+            this.tableData = res.data.data;
             this.total = res.data.totalElements;
           } else {
             // this.$toast.fail(res.msg);