Browse Source

Merge branch 'dev' of ssh://10.10.100.21/source/saas-platform into dev

rainco 7 years ago
parent
commit
53ef6c5bed
19 changed files with 306 additions and 148 deletions
  1. 16 0
      applications/commons/commons-server/src/main/java/com/usoftchina/saas/commons/controller/ShareController.java
  2. 4 0
      applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/po/report/PurchasePay.java
  3. 5 1
      applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/impl/ProdInOutServiceImpl.java
  4. 2 0
      applications/purchase/purchase-server/src/main/resources/mapper/PurchaseReportMapper.xml
  5. 2 0
      applications/sale/sale-dto/src/main/java/com/usoftchina/saas/sale/dto/ProdIODetailDTO.java
  6. 4 0
      applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/po/report/SalerecView.java
  7. 5 1
      applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/impl/ProdInOutServiceImpl.java
  8. 2 0
      applications/sale/sale-server/src/main/resources/mapper/ProdIODetailMapper.xml
  9. 2 0
      applications/sale/sale-server/src/main/resources/mapper/SalerecViewMapper.xml
  10. 2 0
      applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/ProdIODetail.java
  11. 4 1
      base-servers/gateway-server/src/main/resources/application.yml
  12. 56 46
      frontend/saas-portal-web/src/components/conenter/addenterprise.vue
  13. 55 45
      frontend/saas-portal-web/src/components/conenter/enterprise.vue
  14. 38 22
      frontend/saas-portal-web/src/components/conenter/invitation.vue
  15. 23 4
      frontend/saas-portal-web/src/pages/invitation_mobile_join/invitation_mobile_join.html
  16. 17 10
      frontend/saas-portal-web/static/css/gongsi.css
  17. 2 2
      frontend/saas-portal-web/static/css/invitation_mobile_join.css
  18. 17 12
      frontend/saas-portal-web/static/css/jquery-ui.css
  19. 50 4
      frontend/saas-web/app/view/main/MainController.js

+ 16 - 0
applications/commons/commons-server/src/main/java/com/usoftchina/saas/commons/controller/ShareController.java

@@ -66,6 +66,22 @@ public class ShareController {
         }
     }
 
+    /**
+     * 生成分享链接
+     * @param basePath
+     * @param companyName
+     * @param delay
+     * @return
+     */
+    @GetMapping("/pc")
+    public Result getPcUrl(String basePath, String companyName, @RequestParam(value = "delay", defaultValue = "1")Long delay){
+        Long companyId = BaseContextHolder.getCompanyId();
+        String username = BaseContextHolder.getUserName();
+        String params = "username=" + username + "&companyId=" + companyId + "&timestamp=" + new Date().getTime() + "&delay=" + delay + "&companyName=" + companyName;
+        String encodeParams = new String(UrlBase64.encode(params.getBytes()));
+        return Result.success(basePath + "/#/invitation" + "?param=" + encodeParams);
+    }
+
     /**
      * 将前台传入的encode参数decode并校验,返回给前端
      * @param param

+ 4 - 0
applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/po/report/PurchasePay.java

@@ -35,4 +35,8 @@ public class PurchasePay  extends CommonBaseEntity implements Serializable {
     private String pd_remark;
 
     private Integer companyid;
+
+    private Double pi_total;
+
+    private Double pi_nettotal;
 }

+ 5 - 1
applications/purchase/purchase-server/src/main/java/com/usoftchina/saas/purchase/service/impl/ProdInOutServiceImpl.java

@@ -259,13 +259,17 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
     public DocBaseDTO audit(ProdInOutFormDTO formData) {
         Long id = null;
         DocBaseDTO baseDTO = new DocBaseDTO();
+        String code = null;
         if (null != formData) {
             id = formData.getMain().getId();
             if (StringUtils.isEmpty(id) ||"0".equals(String.valueOf(id))) {
                 baseDTO = saveFormData(formData);
                 id = baseDTO.getId();
+                code = baseDTO.getCode();
             }
-            singleAudit(formData.getMain());
+            ProdInOutDTO dto = formData.getMain();
+            dto.setPi_inoutno(code == null ? dto.getPi_inoutno() : code);
+            singleAudit(dto);
             baseDTO = getBaseDTOById(id,formData.getMain().getPi_class(),formData.getMain().getPi_inoutno());
         }
         return baseDTO;

+ 2 - 0
applications/purchase/purchase-server/src/main/resources/mapper/PurchaseReportMapper.xml

@@ -18,6 +18,8 @@
     <result column="creatorid" property="creatorId" jdbcType="INTEGER"/>
     <result column="createTime" property="createTime" jdbcType="TIMESTAMP" />
     <result column="creatorName" property="creatorName" jdbcType="VARCHAR" />
+    <result column="pi_nettotal" property="pi_nettotal" jdbcType="DOUBLE" />
+    <result column="pi_total" property="pi_total" jdbcType="DOUBLE" />
   </resultMap>
   <resultMap id="ListMap" type="com.usoftchina.saas.purchase.po.report.PurchaseReportDetail">
     <id column="pu_id" property="pu_id" jdbcType="INTEGER" />

+ 2 - 0
applications/sale/sale-dto/src/main/java/com/usoftchina/saas/sale/dto/ProdIODetailDTO.java

@@ -90,6 +90,8 @@ public class ProdIODetailDTO implements Serializable {
 
     private Double pd_ordertotal;
 
+    private String pd_iocode;
+
     private ProductDTO productDTO;
 
 }

+ 4 - 0
applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/po/report/SalerecView.java

@@ -37,4 +37,8 @@ public class SalerecView {
     private Double rbd_amount;
 
     private Integer companyid;
+
+    private Double pi_total;
+
+    private Double pi_nettotal;
 }

+ 5 - 1
applications/sale/sale-server/src/main/java/com/usoftchina/saas/sale/service/impl/ProdInOutServiceImpl.java

@@ -242,13 +242,17 @@ public class ProdInOutServiceImpl extends CommonBaseServiceImpl<ProdInOutMapper,
     public DocBaseDTO audit(ProdInOutFormDTO formData) {
         Long id = null;
         DocBaseDTO baseDTO = new DocBaseDTO();
+        String code = null;
         if (null != formData) {
             id = formData.getMain().getId();
             if (StringUtils.isEmpty(id) || "0".equals(String.valueOf(id))) {
                 baseDTO = saveFormData(formData);
                 id = baseDTO.getId();
+                code = baseDTO.getCode();
             }
-            singleAudit( formData.getMain());
+            ProdInOutDTO dto = formData.getMain();
+            dto.setPi_inoutno(code == null ? dto.getPi_inoutno() : code);
+            singleAudit(dto);
         }
         baseDTO.setId(id);
         baseDTO.setCode(formData.getMain().getPi_inoutno());

+ 2 - 0
applications/sale/sale-server/src/main/resources/mapper/ProdIODetailMapper.xml

@@ -39,6 +39,7 @@
     <result column="pd_text4" jdbcType="VARCHAR" property="pd_text4" />
     <result column="pd_text5" jdbcType="VARCHAR" property="pd_text5" />
     <result column="pd_remark" jdbcType="VARCHAR" property="pd_remark" />
+    <result column="pi_iocode" jdbcType="VARCHAR" property="pd_iocode" />
     <result column="pd_ym" jdbcType="INTEGER" property="pd_ym" />
     <result column="pd_yqty" jdbcType="INTEGER" property="pd_yqty" />
     <result column="pd_ioid" jdbcType="INTEGER" property="pd_ioid" />
@@ -746,6 +747,7 @@
 
   <select id="selectByFK" parameterType="long" resultMap="BaseResultMap">
     select * from prodiodetail a left join product b on b.pr_id= a.pd_prodid and a.companyid = b.companyid
+    left join prodinout on pi_id = pd_piid
     where pd_piid=#{id} order by pd_pdno
   </select>
 

+ 2 - 0
applications/sale/sale-server/src/main/resources/mapper/SalerecViewMapper.xml

@@ -16,6 +16,8 @@
     <result column="rb_remark" property="rb_remark" jdbcType="VARCHAR" />
     <result column="companyid" property="companyid" jdbcType="INTEGER" />
     <result column="rbd_amount" property="rbd_amount" jdbcType="DOUBLE" />
+    <result column="pi_nettotal" property="pi_nettotal" jdbcType="DOUBLE" />
+    <result column="pi_total" property="pi_total" jdbcType="DOUBLE" />
   </resultMap>
   <select id="selectByCondition" resultMap="BaseResultMap">
     select  *  from Salerec_View

+ 2 - 0
applications/storage/storage-dto/src/main/java/com/usoftchina/saas/storage/po/ProdIODetail.java

@@ -63,6 +63,8 @@ public class ProdIODetail extends CommonBaseEntity implements Serializable {
 
     private Long pd_sdid;
 
+    private String pd_iocode;
+
     private Integer pd_status;
 
     private String pd_text1;

+ 4 - 1
base-servers/gateway-server/src/main/resources/application.yml

@@ -186,7 +186,10 @@ auth:
     - /ws/**
     - /api/file/download
     - /api/commons/excel/import/templet
-    - /api/commons/share/**
+    - /api/commons/share/valid/param
+    - /api/commons/share/weixin/ticket
+    - /api/commons/share/getSmsCode
+    - /api/commons/share/submit
     - /api/account/role/list/**
     - /api/account/account/share/join
   cookie:

+ 56 - 46
frontend/saas-portal-web/src/components/conenter/addenterprise.vue

@@ -15,7 +15,7 @@
                     <ul>
                         <li style="margin: 0">
                             <span class="qy-biaoti"><span class="xingxing">*</span>企业名称</span>
-                            <input class="inpind" ref="qyname" @change= "spaceName" type="text" placeholder="请填写企业全称">
+                            <input autofocus class="inpind" ref="qyname" @change= "spaceName" type="text" placeholder="请填写企业全称">
                             <div class="qy-Tips Tips-buttom"><span ref="qyno" style="color:red"></span></div>
                         </li>
                         <li>
@@ -72,27 +72,27 @@
                     </ul>
                 </div>
                 <div class="qy-conent jr-conent" :class= "{showqiye:nowindex == 1}">
-                    <ul style="padding:0">
+                    <ul style="padding:0;position: relative;">
                         <li>
                             <span class="qy-biaoti"><span class="xingxing marght">*</span>查找企业</span>
-                            <input @blur.prevent="Testingqyname" @keyup.13="Testingqyname" ref="lookupqyname" class="inpind" type="text"  placeholder="输入企业名称或管理员">
+                            <input @input="Testingqyname" ref="lookupqyname" class="inpind" type="text"  placeholder="输入企业名称或管理员">
                             <span class="warning" ref="warningqyname"></span>
                         </li>
                         <!-- 匹配企业后显示的内容 -->
-                        <li v-if="isqylist" class="hied" :class= "{showlookup:islookup}">
-                            <div class="lookup">
+                        <!-- <li v-if="isqylist" class="hied" :class= "{showlookup:islookup}"> -->
+                            <div class="lookup hied" :class= "{showlookup:islookup}">
                                 <ul>
                                     <li v-for="(d, i) in arr" :key="i" @click="qylist(i)" :class="{'hui':newindex === i}">
-                                        <span class="maxtxt">{{d.name}}</span>
-                                        <span class="maxtxt">{{d.admin}}</span>
                                         <span>{{d.adminMobile}}</span>
+                                        <span>{{d.admin}}</span>
+                                        <span>{{d.name}}</span>
                                     </li>
                                 </ul>
                             </div>
-                        </li>
+                        <!-- </li> -->
                         <li>
                             <span class="qy-biaoti"><span class="xingxing marght">*</span>姓<span style="width:2em;display: inline-block;"></span>名</span>
-                            <input @blur.prevent="Testingname" class="inpind" type="text" ref="lookupname" placeholder="输入真实姓名,待管理员审核">
+                            <input @blur.prevent="Testingname" class="inpind" maxlength="5" type="text" ref="lookupname" placeholder="输入真实姓名,待管理员审核">
                             <span class="warning" ref="warningname"></span>
                         </li>
                         <li>
@@ -111,7 +111,7 @@
 <script>
 import Session from '@/utils/session'
 // import VDistpicker from 'v-distpicker'
-import { setTimeout } from 'timers';
+import { setTimeout, clearTimeout } from 'timers';
     export default {
         data(){
             return {
@@ -122,7 +122,7 @@ import { setTimeout } from 'timers';
                 Email: '',
                 mytoken: Session.get(),//本地储存的用户信息
                 reg: new RegExp(/[\@\#\$\%\&\*!!\¥]/),//非法字符
-                regname:new RegExp(/[\@\#\$\%\&\*!!\¥0-9a-zA-Z]/),//非法字符加数字加
+                regname:new RegExp(/[\@\#\$\%\&\*!!\¥0-9a-zA-Z]/),//非法字符加数字加
                 isaddress: false,//公司地址验证
                 isaddressname: false,//公司地址是否为空
                 isname: true,//姓名验证
@@ -143,8 +143,9 @@ import { setTimeout } from 'timers';
                 isregname:false,
                 companyId:null,
                 admin:null,
-                isqylist:true,
-                arr:[]
+                isgsname:false,
+                arr:[],
+                times:null
             }
         },
         components:{
@@ -197,40 +198,43 @@ import { setTimeout } from 'timers';
             },
             //检测企业名称2
             Testingqyname(){
-                this.$refs.lookupqyname.blur();
                 let qyname = this.$refs.lookupqyname.value.replace(/\s+/g, "");//企业名字
                 let token = this.mytoken.token;
-                if (qyname == '') {
+                clearTimeout(this.times);
+                if(qyname == ''){
                     this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/warning.png" alt=""> 企业或管理员不能为空';
                     this.islookup = false;
                 } else {
-                    this.$ajax({
-                        url: this.$url.api+"/api/account/accountCenter/company/isOpen",//http://192.168.253.41:8560
-                        method:'GET',
-                        params: {
-                            companyName: qyname
-                        },
-                        headers:{
-                            "Authorization":token,
-                        }
-                    })
-                    .then(res=>{
-                        if (res.data.success) {
-                            this.newindex = '';
-                            this.arr = res.data.data;
-                            this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/ok.png" alt="">';
-                            this.islookup = true;
-                            this.isqylist = true;
-                            this.companyId = null;
-                        } else if (res.data.success == false && res.data.message == '公司不存在') {
-                            this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/warning.png" alt=""> 该企业不存在';
-                            this.islookup = false; 
-                        } else {
-                            this.$message.error('请求失败,请重试');
-                            this.islookup = false; 
-                            this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/warning.png" alt="">'
-                        }
-                    })
+                    this.times = setTimeout(()=>{
+                        this.$ajax({
+                            url: this.$url.api+"/api/account/accountCenter/company/isOpen",//http://192.168.253.41:8560
+                            method:'GET',
+                            params: {
+                                companyName: qyname
+                            },
+                            headers:{
+                                "Authorization":token,
+                            }
+                        })
+                        .then(res=>{
+                            if (res.data.success) {
+                                this.newindex = '';
+                                this.arr = res.data.data;
+                                this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/ok.png" alt="">';
+                                this.islookup = true;
+                                this.companyId = null;
+                                this.isgsname = true;//公司是否存在
+                            } else if (res.data.success == false && res.data.message == '公司不存在') {
+                                this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/warning.png" alt=""> 该企业不存在';
+                                this.islookup = false;
+                                this.isgsname = false;//公司是否存在 
+                            } else {
+                                this.$message.error('请求失败,请重试');
+                                this.islookup = false; 
+                                this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/warning.png" alt="">'
+                            }
+                        })
+                    },500)
                 }
             },
             //验证个人姓名1
@@ -271,14 +275,20 @@ import { setTimeout } from 'timers';
                 this.admin = this.arr[i].admin,
                 this.newindex = i,
                 this.$refs.lookupqyname.value = this.arr[i].name,
-                this.isqylist = false
+                this.islookup = false;
+                if (this.admin == this.mytoken.account.realname) {
+                    this.$refs.warningqyname.innerHTML = '<img style="width:14px" src="/static/img/warning.png" alt=""> 账号已在企业服务中,不能重复加入';
+                }
             },
             //加入企业提交按钮
             Submission(){
                 let token = this.mytoken.token;
+                let qyname = this.$refs.lookupqyname.value.replace(/\s+/g, "");//企业名字
                 let username = this.$refs.lookupname.value.replace(/\s+/g, "");//姓名过滤空格
-                if (!this.islookup) {
+                if (qyname == '') {
                     this.$message.error('企业或管理员不能为空');
+                } else if(!this.isgsname) {
+                    this.$message.error('该企业不存在');
                 } else if (!this.isTestingname) {
                     this.$message.error('姓名不能为空');
                 } else if (!this.isregname) {
@@ -302,7 +312,7 @@ import { setTimeout } from 'timers';
                         .then(res=>{
                             if (res.data.success) {
                                 this.$message.success('提交成功,待管理员批准加入');
-                                this.$store.state.ishongdian = true;//显示红点
+                                // this.$store.state.ishongdian = true;//显示红点
                                 setTimeout(()=>{
                                     this.$router.push({name:'company'});
                                     document.documentElement.scrollTop = 0;
@@ -515,7 +525,7 @@ import { setTimeout } from 'timers';
     background: #f5f4f4
 }
 .lookup > ul {
-    height: 300px;
+    max-height: 170px;
     overflow-y: scroll;
 }
 .maxtxt {

+ 55 - 45
frontend/saas-portal-web/src/components/conenter/enterprise.vue

@@ -38,7 +38,7 @@
             <div class="gs-tab">
                 <ul>
                     <li class="xs" v-for="(btn , index) in tab" :key='index' :class= "{gsactive:nowindex == index}" @click= "tabswitch(index)">{{btn.name}}</li>
-                    <span v-if="ishongdian" class="reddian"></span>
+                    <!-- <span v-if="ishongdian" class="reddian"></span> -->
                 </ul>
             </div>
             <div class="gs-none">
@@ -128,7 +128,11 @@
                             <li>
                                 <span>消息类型</span>
                                 <span>时间</span>
-                                <span class="newscentent">消息内容</span>
+                                <span class="newscentent" style="position: relative;top: 7px;">
+                                    <span>消息内容</span>
+                                    <span>管理员</span>
+                                    <span>联系方式</span>
+                                </span>
                                 <span>状态</span>
                                 <span>操作</span>
                             </li>
@@ -177,7 +181,7 @@ import { setTimeout } from 'timers';
                 mobile: null,
                 ismodifyname:true,
                 isname:true,//姓名验证
-                reg: new RegExp(/[\@\#\$\%\&\*!\¥]/),//非法字符
+                reg: new RegExp(/[\@\#\$\%\&\*!\¥]/),//非法字符
                 isheigh:false,//默认高度
                 isnews: false,
                 tab: [
@@ -208,6 +212,7 @@ import { setTimeout } from 'timers';
             setTokenPage() {
                 return this.$url.web + '/set-token.html'
             },
+            //红点
             ishongdian(){
                 return this.$store.state.ishongdian;
             },
@@ -219,39 +224,42 @@ import { setTimeout } from 'timers';
                 if (index == 3) {
                     this.nowindex = 3;
                     let id = this.mytoken.id;
-                    let param = {
+                    let param = [{
                         type:'condition',
-                        value:'creatorId='+id+''
-                    }
+                        value:"creatorId="+id
+                    }];
                     // tab切换到消息的时候获取申请列表
-                    this.$ajax({
+                    this.$store.state.isloading = true;
+                    let _this = this
+                    $.ajax({
                         url: this.$url.api+'/api/commons/remind/apply/list',
-                        method:'GET',
-                        async:false,
-                        params: {
+                        type: "GET",
+                        data:{
                             condition:JSON.stringify(param),
                             number:1,
                             size:this.size
                         },
                         headers:{
                             'Access-Control-Allow-Origin':'*',
-                            "Authorization":Session.getToken(),
-                            'Content-Type':'application/json;charset=UTF-8'
-                        }
-                    })
-                    .then(res=>{
-                        if (res.data.success) {
-                            let list = res.data.data.list;
-                            for (let i = 0; i < list.length - 1; i++) {
-                                for (let j = 0; j < list.length - i - 1; j++) {
-                                    if (list[i].companyName == list[j].companyName && list[i].status == 0) {
-                                        delete list[i]
+                            'Content-Type':'application/json;charset=UTF-8',
+                            "Authorization":Session.getToken()
+                        },
+                        success:function(res){
+                            _this.$store.state.isloading = false;
+                            if (res.success) {
+                                _this.arr = [];
+                                let list = res.data.list;
+                                for (let i = 0; i < list.length - 1; i++) {
+                                    for (let j = 0; j < list.length - i - 1; j++) {
+                                        if (list[i].companyName == list[j].companyName && list[i].status == 0) {
+                                            delete list[i]
+                                        }
                                     }
+                                    _this.arr.push(list[i])
                                 }
-                                this.arr.push(list[i])
+                                _this.listtotal = res.data.total;
+                                // _this.$store.state.ishongdian = false;//红点
                             }
-                            this.listtotal = res.data.data.total;
-                            this.$store.state.ishongdian = false;
                         }
                     })
                 } else {
@@ -284,40 +292,42 @@ import { setTimeout } from 'timers';
             },
             // 分页
              handleCurrentChange(val) {
+                this.$store.state.isloading = true;
+                document.documentElement.scrollTop = 0;
                 let id = this.mytoken.id;
-                let param = {
+                let param = [{
                     type:'condition',
                     value:'creatorId='+id+''
-                }
-                this.$ajax({
+                }];
+                let _this = this
+                $.ajax({
                     url: this.$url.api+'/api/commons/remind/apply/list',
-                    method:'GET',
-                    async:false,
-                    params: {
+                    type: "GET",
+                    data:{
                         condition:JSON.stringify(param),
                         number:val,
                         size:this.size
                     },
                     headers:{
                         'Access-Control-Allow-Origin':'*',
-                        "Authorization":Session.getToken(),
-                        'Content-Type':'application/json;charset=UTF-8'
-                    }
-                })
-                .then(res=>{
-                    if (res.data.success) {
-                        // this.arr = res.data.data.list;
-                        let arr2 = [];
-                        let list = res.data.data.list;
-                        for (let i = 0; i < list.length - 1; i++) {
-                            for (let j = 0; j < list.length - i - 1; j++) {
-                                if (list[i].companyName == list[j].companyName && list[i].status == 0) {
-                                    delete list[i]
+                        'Content-Type':'application/json;charset=UTF-8',
+                        "Authorization":Session.getToken()
+                    },
+                    success:function(res){
+                        _this.$store.state.isloading = false;
+                        if (res.success) {
+                            let arr2 = [];
+                            let list = res.data.list;
+                            for (let i = 0; i < list.length - 1; i++) {
+                                for (let j = 0; j < list.length - i - 1; j++) {
+                                    if (list[i].companyName == list[j].companyName && list[i].status == 0) {
+                                        delete list[i]
+                                    }
                                 }
+                                arr2.push(list[i])
                             }
-                            arr2.push(list[i])
+                            _this.arr = arr2
                         }
-                        this.arr = arr2
                     }
                 })
             },

+ 38 - 22
frontend/saas-portal-web/src/components/conenter/invitation.vue

@@ -44,12 +44,13 @@ import { setTimeout } from 'timers';
                 isregphone:false,
                 isname:false,
                 isregname:false,
-                regname:new RegExp(/[\@\#\$\%\&\*!!\¥0-9a-zA-Z]/),//非法字符加数字加
+                regname:new RegExp(/[\@\#\$\%\&\*!!\¥0-9a-zA-Z]/),//非法字符加数字加
                 isvalidCode:false,
                 isrole:false,
                 enterprise:[],
                 arr:[],
-                roleId:''
+                roleId:'',
+                times:''
             }
         },
         created(){
@@ -121,6 +122,7 @@ import { setTimeout } from 'timers';
             },
             // 获取验证码
             Obtaincode(){
+                this.$refs.Verification.value = '';
                 if (!this.isphone) {
                     this.$message.error('手机号码不能为空');
                 } else if (!this.isregphone){
@@ -128,20 +130,18 @@ import { setTimeout } from 'timers';
                 } else {
                     let phone = this.$refs.phone.value;//手机 
                     this.$ajax({
-                        url:'http://192.168.253.31:8560/api/commons/share/getSmsCode',
+                        url: this.$url.api+'/api/commons/share/getSmsCode'+`?mobile=${phone}`,//http://192.168.253.31:8560
                         method:'POST',
-                        data:{
-                            mobile:phone
-                        },
                         headers:{
                             "Authorization":Session.getToken(),
                         }
                     })
                     .then(res=>{
-                        console.log(res)
                         if (res.data.success) {
                             this.isobtaincode = false;
-                            this.settime()
+                            this.settime();
+                        } else {
+                            this.$message.error(res.data.message)
                         }
                     })
                 }
@@ -157,16 +157,16 @@ import { setTimeout } from 'timers';
                 } else if (!this.isregphone){
                     this.$message.error('请输入正确的手机号码');
                 } else if (!this.isname) {
-                    this.$message.error('姓名不能为空')
+                    this.$message.error('姓名不能为空');
                 } else if (!this.isregname) {
-                    this.$message.error("姓名不能包含符号、数字、英文等非法字符")
+                    this.$message.error("姓名不能包含符号、数字、英文等非法字符");
                 } else if(!this.isvalidCode){
-                    this.$message.error("请输入验证码")
+                    this.$message.error("请输入验证码");
                 } else if(!this.isrole){
                     this.$message.error('请选择岗位角色');
                 } else {
                     this.$ajax({
-                        url:'http://192.168.253.31:8560/api/commons/share/submit',
+                        url: this.$url.api+'/api/commons/share/submit',
                         method:'POST',
                         data:{
                             username:name,
@@ -174,27 +174,41 @@ import { setTimeout } from 'timers';
                             companyId:this.enterprise.companyId,
                             roleId:roleid,
                             validCode:Verification,
+                        },
+                        headers:{
+                            "Authorization":Session.getToken(),
+                        }
+                    })
+                    .then(res=>{
+                        if (res.data.success) {
+                            this.$message.success('提交成功,3秒后自动跳转...');
+                            setTimeout(()=>{
+                                this.$router.push({path: '/home'});
+                            },3000)
+                        } else {
+                            this.$message.error(res.data.message);
                         }
                     })
                 }
             },
             //倒计时
             settime(){
-                if (this.time == 0) {
-                    this.isobtaincode = true;
-                    clearTimeout(times)
-                } else {
-                    this.time--
-                }
-                let times = setTimeout(()=>{
-                    this.settime(this.time)
+                this.times = setTimeout(()=>{
+                    if (this.time == 0) {
+                        this.isobtaincode = true;
+                        this.time = 60;
+                        clearTimeout(this.times);
+                    } else {
+                        this.time--;
+                        this.settime();
+                    }
                 },1000)
             },
             //获取角色
             role(){
                 let companyId = this.enterprise.companyId;
                 this.$ajax({
-                    url:'http://192.168.253.31:8560/api/account/role/list'+`?id=${companyId}`,
+                    url: this.$url.api+'/api/account/role/list'+`?id=${companyId}`,
                     headers:{
                         "Authorization":Session.getToken(),
                     }
@@ -209,7 +223,7 @@ import { setTimeout } from 'timers';
             param(){
                 let param = "dXNlcm5hbWU96ZmI54KcJmNvbXBhbnlJZD0yNjImdGltZXN0bWFwPTE1NDUyODAyODU1MjQmZGVsYXk9MSZjb21wYW55TmFtZT3pmYjngpw."
                 this.$ajax({
-                    url:"http://192.168.253.31:8560/api/commons/share/valid/param"+`?param=${param}`,
+                    url: this.$url.api+"/api/commons/share/valid/param"+`?param=${param}`,
                     method:'POST',
                     headers:{
                         "Authorization":Session.getToken(),
@@ -218,6 +232,8 @@ import { setTimeout } from 'timers';
                 .then(res=>{
                     if (res.data.success) {
                         this.enterprise = res.data.data;
+                    } else {
+                        this.$message.error(res.data.message);
                     }
                 })
             },

+ 23 - 4
frontend/saas-portal-web/src/pages/invitation_mobile_join/invitation_mobile_join.html

@@ -17,6 +17,16 @@
         <link href="../../../static/css/toast.style.css" rel="stylesheet">
         <script type="text/javascript">
             $(document).ready(function(){ 
+                $( "#dialog-message" ).dialog({
+                    autoOpen : false, 
+                    modal: true,
+                    buttons: {
+                        "知道了": function() {
+                            $( this ).dialog( "close" );
+                        }
+                    }
+                });
+                document.getElementById('dialog-message').hidden = false;
                 //解析密文
                 var param = getUrlParam('param');
                 var companyId = 0;
@@ -100,8 +110,7 @@
                         },
                         success: function(data){
                             if(data.success){
-                                addToast("验证码已发送到手机,请查收","success");
-                                settime();
+                                $( "#dialog-message" ).dialog('open');
                             }else{
                                 addToast(data.message,"error");
                             }
@@ -184,15 +193,25 @@
             <input class="input_style" id="selectName" type="text" placeholder="请输入姓名"></input>
             <select class="input_style" id="selectJob" style="padding-top: 0px;" placeholder="请选择岗位"></select>
 			<button class="btn-submit" type="button" id="joinBtn" onclick="join();">提 交</button>
-            <div class="x-join-bottom">
+        </div>
+        <div class="x-join-bottom">
             <span style="font-size:16px;padding:0 0 0 5px;color: #999;">U企云服 | 电子行业企业管理云端方案</span>
             </br>
             <span style="font-size:16px;padding:0 0 0 5px;color: #999;">深圳市优软科技有限公司</span>
-            </div>
         </div>
         <div class="x-join-error" hidden>
             </br></br></br></br>
             <span id="error_code" style="padding:0 0 0 5px;color: #2f2c27;">访问链接已失效</span>
         </div>
+        <div id="dialog-message" hidden>
+            <p style="font-size: 15px;">
+                提交成功,欢迎你加入U企云服,通过https://saas.usoftchina.com访问U企云服,立即畅享轻松工作!
+            </p>
+            </br>
+            <p style="font-size: 13px;    color: #999;">
+                新用户登录密码随后将发送短信通知<br>
+                请注意查收
+            </p>
+        </div>
     </body>
 </html>

+ 17 - 10
frontend/saas-portal-web/static/css/gongsi.css

@@ -223,9 +223,10 @@
     color: red;
 }
 .qy-anniu {
-    margin-left: 56%;
+    /* margin-left: 56%; */
     margin-top: 30px;
     margin-bottom: 45px;
+    text-align: center;
 }
 .qy-conent input {
     border: 1px solid #1E88F5;
@@ -388,21 +389,23 @@
     text-align: center;
 }
 .jr-conent input {
-    width: 30%;
+    width: 31%;
     padding-left: 10px;
-    border: 0;
-    border-bottom: 1px solid #BDBEBE;
 }
 .hied {
     display: none;
 }
 .lookup {
-    width: 90%;
-    margin-left: 5%;
+    width: 80%;
     background: #FFFFFF;
     border: 1px solid #1E88F5;
     border-radius: 2px;
     text-align: left;
+    position: absolute;
+    z-index: 1;
+    top: 40px;
+    left: 50%;
+    transform: translate(-50%, 0%);
 }
 .showlookup {
     display: block !important;
@@ -411,24 +414,28 @@
     padding: 0;
 }
 .lookup > ul > li {
-    padding: 20px 20px 10px 20px;
+    padding: 5px 20px;
     margin-bottom: 0 !important;
+    overflow: hidden;
 } 
 .lookup > ul > li span{
     display: inline-block;
     overflow: hidden;
     text-overflow:ellipsis;
     white-space: nowrap;
+    float: right;
 } 
 .lookup > ul > li span:nth-child(1) {
-    width: 47%
+    width: 20%;
+    text-align: right;
 }
 .lookup > ul > li span:nth-child(2) {
     width: 30%;
-    padding: 0px 20px;
+    text-align: center;
 } 
 .lookup > ul > li span:nth-child(3) {
-    width: 20%;
+    width: 48%;
+    text-align: left;
 } 
 .saasguanli {
     width: 18% !important;

+ 2 - 2
frontend/saas-portal-web/static/css/invitation_mobile_join.css

@@ -4,13 +4,13 @@
 	box-sizing: border-box
 }
 body {
-	background: url("../img/invitation_background.png") no-repeat;
+    background-size: cover;
+    background-image: url(../img/invitation_background.png);
 	font-family: Microsoft YaHei, 微软雅黑, simhei;
 	font-size: 18px;
 	color:#333;	
 }
 .x-join-bottom {
-	margin-left: -40px;
 	width: 100%;
 	position: fixed;
 	bottom: 0;

+ 17 - 12
frontend/saas-portal-web/static/css/jquery-ui.css

@@ -159,6 +159,8 @@ button.ui-button-icons-only {
 	line-height: normal;
 }
 .ui-button-text-only .ui-button-text {
+	color: #2781c3;
+    margin-top: -6px;
 	padding: .4em 1em;
 }
 .ui-button-icon-only .ui-button-text,
@@ -402,6 +404,7 @@ button.ui-button::-moz-focus-inner {
 	position: relative;
 }
 .ui-dialog .ui-dialog-title {
+	height: 10px;
 	float: left;
 	margin: .1em 0;
 	white-space: nowrap;
@@ -426,6 +429,7 @@ button.ui-button::-moz-focus-inner {
 	overflow: auto;
 }
 .ui-dialog .ui-dialog-buttonpane {
+	height: 55px;
 	text-align: left;
 	border-width: 1px 0 0 0;
 	background-image: none;
@@ -433,9 +437,14 @@ button.ui-button::-moz-focus-inner {
 	padding: .3em 1em .5em .4em;
 }
 .ui-dialog .ui-dialog-buttonpane .ui-dialog-buttonset {
-	float: right;
+	height: 36px;
+    text-align: center;
 }
 .ui-dialog .ui-dialog-buttonpane button {
+	border: none;
+    background: unset;
+	font-size: 18px;
+    height: 26px;
 	margin: .5em .4em .5em 0;
 	cursor: pointer;
 }
@@ -484,8 +493,8 @@ button.ui-button::-moz-focus-inner {
 }
 .ui-menu .ui-menu-item a.ui-state-focus,
 .ui-menu .ui-menu-item a.ui-state-active {
-	font-weight: normal;
-	margin: -1px;
+	/* font-weight: normal;
+	margin: -1px; */
 }
 
 .ui-menu .ui-state-disabled {
@@ -805,8 +814,6 @@ body .ui-tooltip {
 	color: #222222;
 }
 .ui-widget-header {
-	border: 1px solid #aaaaaa;
-	background: #cccccc url(images/ui-bg_highlight-soft_75_cccccc_1x100.png) 50% 50% repeat-x;
 	color: #222222;
 	font-weight: bold;
 }
@@ -816,11 +823,9 @@ body .ui-tooltip {
 
 /* Interaction states
 ----------------------------------*/
-.ui-state-default,
-.ui-widget-content .ui-state-default,
 .ui-widget-header .ui-state-default {
-	border: 1px solid #d3d3d3;
-	background: #e6e6e6 url(images/ui-bg_glass_75_e6e6e6_1x400.png) 50% 50% repeat-x;
+	border: 1px solid #fff;
+	background: #ffffff url(../img/assets/chahao.png) no-repeat;
 	font-weight: normal;
 	color: #555555;
 }
@@ -849,8 +854,8 @@ body .ui-tooltip {
 .ui-state-focus a:hover,
 .ui-state-focus a:link,
 .ui-state-focus a:visited {
-	color: #212121;
-	text-decoration: none;
+	/* color: #212121;
+	text-decoration: none; */
 }
 .ui-state-active,
 .ui-widget-content .ui-state-active,
@@ -941,7 +946,7 @@ body .ui-tooltip {
 }
 .ui-state-hover .ui-icon,
 .ui-state-focus .ui-icon {
-	background-image: url(images/ui-icons_454545_256x240.png);
+	/* background-image: url(img/ui-icons_454545_256x240.png); */
 }
 .ui-state-active .ui-icon {
 	background-image: url(images/ui-icons_454545_256x240.png);

+ 50 - 4
frontend/saas-web/app/view/main/MainController.js

@@ -220,7 +220,7 @@ Ext.define('saas.view.main.MainController', {
             var win = Ext.create('Ext.window.Window', {  
                 cls:'x-window-dbfind', 
                 height: nowHeight,
-                width: '50%',
+                width: '45%',
                 modal:true,
                 title: '加入邀请',
                 bodyPadding: 10,
@@ -271,14 +271,32 @@ Ext.define('saas.view.main.MainController', {
                         padding:'5',
                         style:'border: 1px solid #000;',
                         src:'resources/images/default/basePhoto.png',
-                        //src: (serverOptions.basePath.https?serverOptions.basePath.https:serverOptions.basePath) + '/api/file/download?path='+signet,
                         name:'QRcode',
                         listeners:{
                             afterrender:function(f){
+                                var companyName = document.getElementsByClassName('x-main-master')[0].getElementsByClassName('x-btn-inner x-btn-inner-header-small')[0].innerText;
                                 var serverOptions = Ext.manifest.server;
                                 var delay = 1;//天
+                                var accountCenter = serverOptions.accountCenter;
                                 var basePath = serverOptions.basePath.https?serverOptions.basePath.https:serverOptions.basePath;
-                                f.setSrc(basePath+'/api/commons/share/qrcode?basePath='+basePath+'&delay='+delay)
+                                Ext.Ajax.request({  
+                                    url :basePath+'/api/commons/share/qrcode?basePath='+accountCenter+'&delay='+delay+'&companyName='+companyName,
+                                    timeout: 8000,  
+                                    headers:{
+                                        'Access-Control-Allow-Origin': '*',
+                                        'Authorization':  saas.util.State.get('session').token,
+                                        "Content-Type": 'application/json;charset=UTF-8'
+                                    },
+                                    method: 'GET',
+                                    responseType:'blob',
+                                    success: function(fp, o){
+                                        var url = URL.createObjectURL(fp.responseBlob);
+                                        f.setSrc(url)
+                                    },
+                                    failure: function (response, opts) {
+                                        saas.util.BaseUtil.showErrorToast('获取二维码失败');
+                                    }
+                                });
                             }
                         }
                     },{
@@ -302,7 +320,35 @@ Ext.define('saas.view.main.MainController', {
                     },{
                         xtype:'textfield',
                         width:500,
-                        value:'https://saas.usoftchina.com?admin=false&_noc=0'
+                        value:'暂无',
+                        listeners:{
+                            afterrender:function(f){
+                                var serverOptions = Ext.manifest.server;
+                                var accountCenter = serverOptions.accountCenter;
+                                var companyName = document.getElementsByClassName('x-main-master')[0].getElementsByClassName('x-btn-inner x-btn-inner-header-small')[0].innerText;
+                                var delay = 1;
+                                var basePath = serverOptions.basePath.https?serverOptions.basePath.https:serverOptions.basePath;
+                                Ext.Ajax.request({  
+                                    url :basePath+'/api/commons/share/pc?basePath='+accountCenter+'&delay='+delay+'&companyName='+companyName,
+                                    timeout: 8000,  
+                                    async:false,
+                                    headers:{
+                                        'Access-Control-Allow-Origin': '*',
+                                        'Authorization':  saas.util.State.get('session').token,
+                                        "Content-Type": 'application/json;charset=UTF-8'
+                                    },
+                                    method: 'GET',
+                                    success: function(fp, o){
+                                        var res = Ext.decode(fp.responseText);
+                                        var url = fp.data;
+                                        f.setValue(url)
+                                    },
+                                    failure: function (response, opts) {
+                                        saas.util.BaseUtil.showErrorToast('获取分享地址失败');
+                                    }
+                                });
+                            }
+                        }
                     },{
                         margin:'10 0 0 0',
                         width:110,