2
3
فهرست منبع

部门用户 待办任务

lining 6 سال پیش
والد
کامیت
8643fbac3b

+ 10 - 0
src/dashoo.cn/backend/api/business/oilrtx/rtx.go

@@ -44,3 +44,13 @@ type RtxOrganize struct {
 type RtxOrganizeItems struct {
 	Items []RtxOrganize `json:"items"`
 }
+
+type Tmp_User struct {
+	Department string `xorm:"VARCHAR(500)"`
+	Fullname   string `xorm:"VARCHAR(500)"`
+	Username   string `xorm:"VARCHAR(500)"`
+	Code       string `xorm:"VARCHAR(500)"`
+	Email      string `xorm:"VARCHAR(500)"`
+	Telphone   string `xorm:"VARCHAR(500)"`
+	Deptid     string `xorm:"VARCHAR(500)"`
+}

+ 3 - 0
src/dashoo.cn/backend/api/business/todolist/todolist.go

@@ -2,9 +2,12 @@ package todolist
 
 type TodoList struct {
 	Id               int    `xorm:"int(11)"`
+	SupplierId       string `xorm:"VARCHAR(30)`
 	CertId           string `xorm:"VARCHAR(30)"`
+	QualId           string `xorm:"VARCHAR(30)"`
 	SupplierTypeCode string `xorm:"VARCHAR(30)"`
 	Type             string `xorm:"VARCHAR(10)"`
 	SupplierName     string `xorm:"VARCHAR(50)"`
 	UserName         string `xorm:"VARCHAR(50)"`
+	Status           string `xorm:"VARCHAR(50)"`
 }

+ 288 - 1
src/dashoo.cn/backend/api/controllers/oilsupplier/todolist.go

@@ -1,6 +1,9 @@
 package oilsupplier
 
 import (
+	"dashoo.cn/backend/api/business/oilsupplier/annualaudit"
+	"dashoo.cn/backend/api/business/oilsupplier/infochange"
+	"dashoo.cn/backend/api/business/oilsupplier/qualchange"
 	"dashoo.cn/backend/api/business/oilsupplier/supplier"
 	"dashoo.cn/backend/api/business/oilsupplier/suppliercertappend"
 	"dashoo.cn/backend/api/business/todolist"
@@ -8,6 +11,7 @@ import (
 	. "dashoo.cn/backend/api/controllers"
 	"dashoo.cn/utils"
 	"fmt"
+	"strconv"
 	"strings"
 )
 
@@ -38,6 +42,22 @@ func (this *TodoListController) GetMyTaskEntityList() {
 		}
 	}
 
+	stype := this.GetString("Type")
+	supplierTypeCode := this.GetString("SupplierTypeCode")
+	supplierName := this.GetString("SupplierName")
+
+	if stype != "" {
+		where = where + " and b.SupplierTypeCode = '" + stype + "'"
+	}
+
+	if supplierTypeCode != "" {
+		where = where + " and b.SupplierTypeCode = '" + supplierTypeCode + "'"
+	}
+
+	if supplierName != "" {
+		where = where + " and a.SupplierName like '%" + supplierName + "%'"
+	}
+
 	//找出待办任务
 	actisvc := workflow.GetActivitiService(utils.DBE)
 	var certIdList string
@@ -81,7 +101,7 @@ func (this *TodoListController) GetMyTaskEntityList() {
 
 	//找出待办任务 -- 增项
 	whereapp := "1=1"
-	whereapp = whereapp + " and Status>0"
+	whereapp = whereapp + " and b.Status>0"
 	appendIdList := actisvc.GetMyTasks(workflow.OIL_APPEND_APPLY, this.User.Id)
 	appendIdarr := strings.Split(appendIdList, ",")
 	for i, item := range appendIdarr {
@@ -106,8 +126,275 @@ func (this *TodoListController) GetMyTaskEntityList() {
 		todolists = append(todolists, todo)
 	}
 
+	//  待办--年审
+	whereannu := "1=1"
+	var listannu []annualaudit.OilAnnualAudit
+	certIdList = actisvc.GetMyTasks(workflow.OIL_AUDIT_APPLY, this.User.Id)
+	annuIdarr := strings.Split(certIdList, ",")
+	for i, item := range annuIdarr {
+		idx := strings.Index(item, "-")
+		if idx >= 0 {
+			annuIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(annuIdarr, ",")
+	whereannu += " and Id in (" + certIdList + ")"
+	//根据部门查询待办任务
+	whereannu += " and Status != 2 "
+	svc.GetPagingEntitiesWithOrderBytbl("", page.CurrentPage, page.Size, orderby, asc, &listannu, whereannu)
+
+	for _, item :=range listannu {
+		todo.Id = item.Id
+		todo.Type = "3"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = item.SupplierTypeName
+		todolists = append(todolists, todo)
+	}
+
+	// 信息变更
+	whereInfo := "1=1"
+	certIdList = actisvc.GetMyTasks(workflow.OIL_INFO_CHANGE, this.User.Id)
+	appendIdarr = strings.Split(certIdList, ",")
+	for i, item := range appendIdarr {
+		idx := strings.Index(item,"-")
+		if (idx >= 0 ) {
+			appendIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(appendIdarr, ",")
+	whereInfo += " and Id in (" + certIdList + ")"
+
+	var listInfo []infochange.OilInfoChange
+	svc.GetPagingEntitiesWithOrderBytbl("", page.CurrentPage, page.Size, orderby, asc, &listInfo, whereInfo)
+	for _, item :=range listInfo {
+		todo.Id = item.Id
+		todo.Type = "4"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = item.SupplierTypeName
+		todo.Status = item.Status
+		todolists = append(todolists, todo)
+	}
+
+	// 资质变更
+	certIdList = actisvc.GetMyTasks(workflow.OIL_QUAL_CHANGE, this.User.Id)
+	appendIdarr = strings.Split(certIdList, ",")
+	for i, item := range appendIdarr {
+		idx := strings.Index(item, "-")
+		if idx >= 0 {
+			appendIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(appendIdarr, ",")
+	wherequal :=  "Id in (" + certIdList + ")"
+	wherequal += " and Status != -2 "
+
+	var listqual []qualchange.OilQualChangeMain
+	svc.GetPagingEntitiesWithOrderBytbl("", page.CurrentPage, page.Size, orderby, asc, &listqual, wherequal)
+	for _, item :=range listqual {
+		todo.Id = item.Id
+		todo.CertId = strconv.Itoa(item.SupplierCertId)
+		todo.SupplierId = strconv.Itoa(item.SupplierId)
+		todo.Type = "5"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = "0"
+		todolists = append(todolists, todo)
+	}
+
 	var datainfo DataInfo
 	datainfo.Items = todolists
 	this.Data["json"] = &datainfo
 	this.ServeJSON()
+	//this.SetUserDeptId()
 }
+
+// @Title 获取已办列表
+// @Description get user by token
+// @Success 200 {object} []supplier.OilSupplierView
+// @router /getmytaskfinishedlist [get]
+func (this *TodoListController) GetMyTaskFinishedList() {
+	var todolists []todolist.TodoList
+	var todo todolist.TodoList
+
+	page := this.GetPageInfoForm()
+	where := " 1=1 "
+	orderby := "Id"
+	asc := false
+	Order := this.GetString("Order")
+	where = where + " and b.Status>0"
+	Prop := this.GetString("Prop")
+	if Order != "" && Prop != "" {
+		orderby = Prop
+		if Order == "asc" {
+			asc = true
+		}
+	}
+
+	stype := this.GetString("Type")
+	supplierTypeCode := this.GetString("SupplierTypeCode")
+	supplierName := this.GetString("SupplierName")
+
+	if stype != "" {
+		where = where + " and b.SupplierTypeCode = '" + stype + "'"
+	}
+
+	if supplierTypeCode != "" {
+		where = where + " and b.SupplierTypeCode = '" + supplierTypeCode + "'"
+	}
+
+	if supplierName != "" {
+		where = where + " and a.SupplierName like '%" + supplierName + "%'"
+	}
+
+	//找出已办任务
+	actisvc := workflow.GetActivitiService(utils.DBE)
+	var certIdList string
+	if actisvc.GetHistoryMyTasks(workflow.OIL_SUPPLIER_APPLY, this.User.Id) != ""{
+		certIdList = actisvc.GetHistoryMyTasks(workflow.OIL_SUPPLIER_APPLY, this.User.Id)
+		certIdList = certIdList + ","
+	}
+	if actisvc.GetHistoryMyTasks(workflow.OIL_FIRST_SUPPLIER_APPLY, this.User.Id) != ""{
+		certIdList = fmt.Sprintf("%s %s",certIdList,actisvc.GetHistoryMyTasks(workflow.OIL_FIRST_SUPPLIER_APPLY, this.User.Id))
+		certIdList = certIdList + ","
+	}
+	if actisvc.GetHistoryMyTasks(workflow.OIL_SECOND_SUPPLIER_APPLY, this.User.Id) != ""{
+		certIdList = fmt.Sprintf("%s %s",certIdList,actisvc.GetHistoryMyTasks(workflow.OIL_SECOND_SUPPLIER_APPLY, this.User.Id))
+	}
+	certIdList = strings.Trim(certIdList, ",")
+	certIdarr := strings.Split(certIdList, ",")
+	for i, item := range certIdarr {
+		idx := strings.Index(item, "-")
+		if idx >= 0 {
+			certIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(certIdarr, ",")
+	where += " and b.Id in (" + certIdList + ")"
+	//根据部门查询待办任务
+
+	svc := supplier.GetOilSupplierService(utils.DBE)
+	var list []supplier.OilSupplierView
+	//svc.GetEntities(&list, where)
+	svc.GetMyPagingEntitiesWithOrderBytbl(OilSupplierName, OilSupplierCertName, page.CurrentPage, page.Size, orderby, asc, &list, where)
+
+	for _, item :=range list {
+		todo.Id = item.Id
+		todo.CertId = item.CertId
+		todo.SupplierTypeCode = item.SupplierTypeCode
+		todo.Type = "1"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todolists = append(todolists, todo)
+	}
+
+	//找出待办任务 -- 增项
+	whereapp := "1=1"
+	whereapp = whereapp + " and b.Status>0"
+	appendIdList := actisvc.GetHistoryMyTasks(workflow.OIL_APPEND_APPLY, this.User.Id)
+	appendIdarr := strings.Split(appendIdList, ",")
+	for i, item := range appendIdarr {
+		idx := strings.Index(item,"-")
+		if (idx >= 0 ) {
+			appendIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	appendIdList = strings.Join(appendIdarr, ",")
+	whereapp += " and b.Id in (" + appendIdList + ")"
+
+	var listapp []suppliercertappend.OilSupplierCertAppendTodo
+	svcapp := suppliercertappend.GetOilSupplierCertAppendService(utils.DBE)
+	svcapp.GetMyPagingEntitiesWithOrderBytbl(OilSupplierName, OilSupplierCertAppendName, page.CurrentPage, page.Size, orderby, asc, &listapp, whereapp)
+
+	for _, item :=range listapp {
+		todo.Id = item.Id
+		todo.Type = "2"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = item.AppendType
+		todolists = append(todolists, todo)
+	}
+
+	//  待办--年审
+	whereannu := "1=1"
+	var listannu []annualaudit.OilAnnualAudit
+	certIdList = actisvc.GetHistoryMyTasks(workflow.OIL_AUDIT_APPLY, this.User.Id)
+	annuIdarr := strings.Split(certIdList, ",")
+	for i, item := range annuIdarr {
+		idx := strings.Index(item, "-")
+		if idx >= 0 {
+			annuIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(annuIdarr, ",")
+	whereannu += " and Id in (" + certIdList + ")"
+	//根据部门查询待办任务
+	whereannu += " and Status != 2 "
+	svc.GetPagingEntitiesWithOrderBytbl("", page.CurrentPage, page.Size, orderby, asc, &listannu, whereannu)
+
+	for _, item :=range listannu {
+		todo.Id = item.Id
+		todo.Type = "3"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = item.SupplierTypeName
+		todolists = append(todolists, todo)
+	}
+
+	// 信息变更
+	whereInfo := "1=1"
+	certIdList = actisvc.GetHistoryMyTasks(workflow.OIL_INFO_CHANGE, this.User.Id)
+	appendIdarr = strings.Split(certIdList, ",")
+	for i, item := range appendIdarr {
+		idx := strings.Index(item,"-")
+		if (idx >= 0 ) {
+			appendIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(appendIdarr, ",")
+	whereInfo += " and Id in (" + certIdList + ")"
+
+	var listInfo []infochange.OilInfoChange
+	svc.GetPagingEntitiesWithOrderBytbl("", page.CurrentPage, page.Size, orderby, asc, &listInfo, whereInfo)
+	for _, item :=range listInfo {
+		todo.Id = item.Id
+		todo.Type = "4"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = item.SupplierTypeName
+		todo.Status = item.Status
+		todolists = append(todolists, todo)
+	}
+
+	// 资质变更
+	certIdList = actisvc.GetHistoryMyTasks(workflow.OIL_QUAL_CHANGE, this.User.Id)
+	appendIdarr = strings.Split(certIdList, ",")
+	for i, item := range appendIdarr {
+		idx := strings.Index(item, "-")
+		if idx >= 0 {
+			appendIdarr[i] = strings.Split(item, "-")[0]
+		}
+	}
+	certIdList = strings.Join(appendIdarr, ",")
+	wherequal :=  "Id in (" + certIdList + ")"
+	wherequal += " and Status != -2 "
+
+	var listqual []qualchange.OilQualChangeMain
+	svc.GetPagingEntitiesWithOrderBytbl("", page.CurrentPage, page.Size, orderby, asc, &listqual, wherequal)
+	for _, item :=range listqual {
+		todo.Id = item.Id
+		todo.CertId = strconv.Itoa(item.SupplierCertId)
+		todo.SupplierId = strconv.Itoa(item.SupplierId)
+		todo.Type = "5"
+		todo.SupplierName = item.SupplierName
+		todo.UserName = this.User.Realname
+		todo.SupplierTypeCode = "0"
+		todolists = append(todolists, todo)
+	}
+
+	var datainfo DataInfo
+	datainfo.Items = todolists
+	this.Data["json"] = &datainfo
+	this.ServeJSON()
+}

+ 66 - 0
src/dashoo.cn/backend/api/controllers/rtx/rtx.go

@@ -4,8 +4,14 @@ import (
 	"fmt"
 
 	"dashoo.cn/backend/api/business/oilrtx"
+	"dashoo.cn/backend/api/business/oilsupplier/supplier"
+	"dashoo.cn/backend/api/business/organize"
 	. "dashoo.cn/backend/api/controllers"
+	"dashoo.cn/business2/userRole"
 	"dashoo.cn/utils"
+	"fmt"
+	"strconv"
+	"strings"
 )
 
 type RtxController struct {
@@ -74,3 +80,63 @@ func (this *RtxController) PtrLogin() {
 	this.Data["json"] = &datainfo
 	this.ServeJSON()
 }
+
+// @Title get
+// @Description get workflow by token
+// @Success 200 {object} historicTasks
+// @router /syncUser [get]
+func (this *RtxController) SyncUserList() {
+ 	var tmpuserlist []oilrtx.Tmp_User
+ 	var baseuser userRole.Base_User
+	rtxSvc := supplier.GetOilSupplierService(utils.DBE)
+	rtxSvc.GetEntitysByWhere("tmp_user", "fullname<>'null'", &tmpuserlist)
+	pwd, key, _ := utils.TripleDesEncrypt("123456")
+	var counts int64 = 0
+	var fails int64 = 0
+	for _, tmpuser := range tmpuserlist {
+		baseuser.Id = 0
+		baseuser.Departmentid = tmpuser.Deptid
+		baseuser.Realname = tmpuser.Fullname
+		baseuser.Username = tmpuser.Username
+		baseuser.Userpassword = pwd
+		baseuser.Publickey = key
+		_,err := rtxSvc.InsertEntity(&baseuser)
+		if err == nil {
+			counts++
+		} else {
+			fails++
+		}
+		fmt.Println(counts,"==",fails)
+	}
+	var datainfo DataInfo
+	datainfo.StartIndex = counts
+	datainfo.PageIndex = fails
+	this.Data["json"] = &datainfo
+	this.ServeJSON()
+}
+
+// @Title get
+// @Description get workflow by token
+// @Success 200 {object} historicTasks
+// @router /syncUserDept [get]
+func (this *RtxController) SyncUserDept() {
+	var tmp_user1 oilrtx.Tmp_User
+	var tmp_userlist []oilrtx.Tmp_User
+	var orglist []organize.Base_Organize
+	svc := supplier.GetOilSupplierService(utils.DBE)
+	svc.GetEntitysByWhere("tmp_user", "fullname<>'null'",&tmp_userlist)
+	svc.GetEntitysByWhere("Base_Organize", "1=1",&orglist)
+	for _, tmp_user := range tmp_userlist{
+		for _,org := range orglist {
+			var dept = strings.Replace(org.Description, "/", "\\", -1)
+			if tmp_user.Department == dept{
+				where := "username='" + tmp_user.Username + "'"
+				tmp_user1.Deptid = strconv.Itoa(org.Id)
+				col := []string{"deptid"}
+				svc.UpdateEntityBywheretbl("tmp_user", tmp_user1, col, where)
+				break
+			}
+		}
+		fmt.Println(tmp_user)
+	}
+}

+ 7 - 0
src/dashoo.cn/frontend_web/src/api/oilsupplier/supplier.js

@@ -116,5 +116,12 @@ export default {
       method: 'GET',
       params: params
     })
+  },
+  getMyTaskFinished (params, myAxios) {
+    return myAxios({
+      url: '/todolist/getmytaskfinishedlist/',
+      method: 'GET',
+      params: params
+    })
   }
 }

+ 12 - 0
src/dashoo.cn/frontend_web/src/api/rtxservice/rtx.js

@@ -5,6 +5,18 @@ export default {
       method: 'GET'
     })
   },
+  syncUser (myAxios) {
+    return myAxios({
+      url: '/rtx/syncUser',
+      method: 'GET'
+    })
+  },
+  syncUserDept (myAxios) {
+    return myAxios({
+      url: '/rtx/syncUserDept',
+      method: 'GET'
+    })
+  }
   rtxLogin (params, myAxios) {
     return myAxios({
       url: '/rtx/ptrlogin',

+ 183 - 38
src/dashoo.cn/frontend_web/src/pages/index.vue

@@ -3,45 +3,116 @@
     <el-card class="box-card">
       <div slot="header">
         <span>
-          <i class="icon icon-table2"></i> 待办任务
+          <i class="icon icon-table2"></i> 待办/已办
         </span>
+        <el-form ref="form" :inline="true" style="float: right; margin-top: -10px">
+          <el-form-item label="类型">
+            <el-select size="mini" style="width:100px" v-model="searchForm.Type" placeholder="准入类别">
+              <el-option label="全部" value=""></el-option>
+              <el-option label="准入" value="1"></el-option>
+              <el-option label="增项" value="2"></el-option>
+              <el-option label="年审" value="3"></el-option>
+              <el-option label="信息变更" value="4"></el-option>
+              <el-option label="资质变更" value="5"></el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="类别">
+            <el-select size="mini" style="width:100px" v-model="searchForm.SupplierTypeCode" placeholder="准入类别">
+              <el-option label="全部" value=""></el-option>
+              <el-option label="物资类" value="01"></el-option>
+              <el-option label="基建类" value="02"></el-option>
+              <el-option label="技术服务类" value="03"></el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="公司名称">
+            <el-input size="mini" v-model="searchForm.SupplierName" placeholder="请输入" style="width: 100%"></el-input>
+          </el-form-item>
+          <el-form-item>
+            <el-button size="mini" type="primary" @click="handleSearch">查 询</el-button>
+          </el-form-item>
+        </el-form>
       </div>
-      <el-table
-        :data="entityList"
-        size="mini"
-        border
-        :stripe="true"
-        style="width: 100%">
-
-        <!--<el-table-column type="index" label="序号"></el-table-column>-->
-
-        <el-table-column label="待办类型" prop="Type">
-          <template slot-scope="scope">
-            <span v-if="scope.row.Type=='1'" style="color:#E6A23C">准入</span>
-            <span v-if="scope.row.Type=='2'" style="color:#E6A23C">增项</span>
-            <span v-if="scope.row.Type=='3'" style="color:#E6A23C">年审</span>
-          </template>
-        </el-table-column>
-        <el-table-column label="类别" prop="SupplierTypeCode">
-          <template slot-scope="scope">
-            <span v-if="scope.row.SupplierTypeCode=='01'">物质类</span>
-            <span v-if="scope.row.SupplierTypeCode=='02'">基建类</span>
-            <span v-if="scope.row.SupplierTypeCode=='03'">技术服务类</span>
-          </template>
-        </el-table-column>
-
-        <el-table-column label="公司名称" prop="SupplierName"></el-table-column>
-
-        <el-table-column label="执行人" prop="UserName"></el-table-column>
-
-        <el-table-column label="操作" width="130" align="center" fixed="right">
-          <template slot-scope="scope">
-            <el-button type="text" title="办理"  icon="el-icon-edit" size="mini" @click="rowClick(scope.row)">办理</el-button>
-            <!--<el-button type="text" title="编辑"  icon="el-icon-s-promotion" size="mini">跟踪</el-button>-->
-          </template>
-        </el-table-column>
-
-      </el-table>
+      <el-tabs v-model="activeName" type="border-card" @tab-click="handleClick">
+        <el-tab-pane label="待办任务" name="first">
+          <el-table
+          :data="entityList"
+          size="mini"
+          border
+          :stripe="true"
+          style="width: 100%">
+
+          <!--<el-table-column type="index" label="序号"></el-table-column>-->
+
+          <el-table-column label="待办类型" prop="Type">
+            <template slot-scope="scope">
+              <span v-if="scope.row.Type=='1'" style="color:#E6A23C">准入</span>
+              <span v-if="scope.row.Type=='2'" style="color:#E6A23C">增项</span>
+              <span v-if="scope.row.Type=='3'" style="color:#E6A23C">年审</span>
+              <span v-if="scope.row.Type=='4'" style="color:#E6A23C">信息变更</span>
+              <span v-if="scope.row.Type=='5'" style="color:#E6A23C">资质变更</span>
+            </template>
+          </el-table-column>
+          <el-table-column label="类别" prop="SupplierTypeCode">
+            <template slot-scope="scope">
+              <span v-if="scope.row.SupplierTypeCode=='01'">物质类</span>
+              <span v-if="scope.row.SupplierTypeCode=='02'">基建类</span>
+              <span v-if="scope.row.SupplierTypeCode=='03'">技术服务类</span>
+            </template>
+          </el-table-column>
+
+          <el-table-column label="公司名称" prop="SupplierName"></el-table-column>
+
+          <el-table-column label="执行人" prop="UserName"></el-table-column>
+
+          <el-table-column label="操作" width="130" align="center" fixed="right">
+            <template slot-scope="scope">
+              <el-button type="text" title="办理"  icon="el-icon-edit" size="mini" @click="rowClick(scope.row)">办理</el-button>
+              <!--<el-button type="text" title="编辑"  icon="el-icon-s-promotion" size="mini">跟踪</el-button>-->
+            </template>
+          </el-table-column>
+
+        </el-table>
+        </el-tab-pane>
+        <el-tab-pane label="已办任务" name="second">
+          <el-table
+            :data="entityList"
+            size="mini"
+            border
+            :stripe="true"
+            style="width: 100%">
+
+            <el-table-column label="已办类型" prop="Type">
+              <template slot-scope="scope">
+                <span v-if="scope.row.Type=='1'" style="color:#E6A23C">准入</span>
+                <span v-if="scope.row.Type=='2'" style="color:#E6A23C">增项</span>
+                <span v-if="scope.row.Type=='3'" style="color:#E6A23C">年审</span>
+                <span v-if="scope.row.Type=='4'" style="color:#E6A23C">信息变更</span>
+                <span v-if="scope.row.Type=='5'" style="color:#E6A23C">资质变更</span>
+              </template>
+            </el-table-column>
+            <el-table-column label="类别" prop="SupplierTypeCode">
+              <template slot-scope="scope">
+                <span v-if="scope.row.SupplierTypeCode=='01'">物质类</span>
+                <span v-if="scope.row.SupplierTypeCode=='02'">基建类</span>
+                <span v-if="scope.row.SupplierTypeCode=='03'">技术服务类</span>
+              </template>
+            </el-table-column>
+
+            <el-table-column label="公司名称" prop="SupplierName"></el-table-column>
+
+            <el-table-column label="执行人" prop="UserName"></el-table-column>
+
+            <el-table-column label="操作" width="130" align="center" fixed="right">
+              <template slot-scope="scope">
+                <el-button type="text" title="打开"  icon="el-icon-edit" size="mini" @click="rowClick(scope.row)">打开</el-button>
+                <!--<el-button type="text" title="编辑"  icon="el-icon-s-promotion" size="mini">跟踪</el-button>-->
+              </template>
+            </el-table-column>
+
+          </el-table>
+        </el-tab-pane>
+      </el-tabs>
+
     </el-card>
   </div>
 </template>
@@ -61,6 +132,8 @@
 
     data () {
       return {
+        tabindex: '',
+        activeName: 'first',
         currentDate: new Date(),
         // 查询时间
         CreateOn: [],
@@ -74,7 +147,20 @@
           Prop: ''
         },
         // 查询项
-        searchFormReset: {},
+        searchForm: {
+          Id: '',
+          Type: '',
+          SupplierTypeCode: '',
+          SupplierName: '',
+          IsPay: '1',
+          CreateOn: '',
+          CreateUserId: '',
+          CreateBy: '',
+          ModifiedOn: '',
+          ModifiedUserId: '',
+          ModifiedBy: ''
+
+        },
         entityList: []
       }
     },
@@ -82,6 +168,23 @@
       this.initDatas()
     },
     methods: {
+      handleSearch () {
+        this.currentPage = 1
+        if (this.tabindex === '0') {
+          this.initDatas()
+        } else {
+          this.finishedData()
+        }
+        this.initDatas()
+      },
+      handleClick (tab) {
+        this.tabindex = tab.index
+        if (tab.index === '0') {
+          this.initDatas()
+        } else {
+          this.finishedData()
+        }
+      },
       rowClick (val) {
         let SupplierType = ''
         if (val.Type === '1') {
@@ -102,7 +205,40 @@
             SupplierType = 'techdataopera'
           }
           this.$router.push('oilsupplier/addtionaudit/' + val.Id + '/' + SupplierType)
+        } else if (val.Type === '3') {
+        } else if (val.Type === '4') {
+          this.$router.push('oilsupplier/infochange/' + val.Id + '/auditoperation?InfoStatus=' + val.Status)
+        } else if (val.Type === '5') {
+          this.$router.push('oilsupplier/qualchange/' + val.SupplierId + '/auditoperation?certid=' + val.CertId + '&QualId=' + val.Id + '&QualStatus=' + val.Status)
+        }
+      },
+      finishedData () {
+        // 分页及列表条件
+        let params = {
+          _currentPage: this.currentPage,
+          _size: this.size,
+          Order: this.Column.Order,
+          Prop: this.Column.Prop,
+          Statustype: 2
         }
+        let myCreateOn = []
+        // 解析时间
+        if (this.CreateOn.length === 2) {
+          this.CreateOn[1].setHours(23)
+          this.CreateOn[1].setMinutes(59)
+          this.CreateOn[1].setSeconds(59)
+          myCreateOn.push(this.formatDateTime(this.CreateOn[0]))
+          myCreateOn.push(this.formatDateTime(this.CreateOn[1]))
+        }
+        // 查询条件
+        Object.assign(params, this.searchForm)
+        api.getMyTaskFinished(params, this.$axios).then(res => {
+          this.entityList = res.data.items
+          console.log(this.entityList, 'this.entityList')
+          this.currentItemCount = res.data.currentItemCount
+        }).catch(err => {
+          console.error(err)
+        })
       },
       initDatas () {
         // 分页及列表条件
@@ -132,6 +268,15 @@
         }).catch(err => {
           console.error(err)
         })
+      },
+      handleCurrentChange (value) {
+        this.currentPage = value
+        this.initData()
+      },
+      handleSizeChange (value) {
+        this.size = value
+        this.currentPage = 1
+        this.initData()
       }
     }
   }

+ 0 - 1
src/dashoo.cn/frontend_web/src/pages/oilsupplier/addtionaudit/techlist.vue

@@ -67,7 +67,6 @@
             <span v-if="scope.row.Status=='6'" style="color:#E6A23C">待缴费</span>
             <span v-if="scope.row.Status=='7'" style="color:#E6A23C">待入库</span>
             <span v-if="scope.row.Status=='8'" style="color:#67C23A">已入库</span>
-            </el-alert>
           </template>
         </el-table-column>
         <el-table-column prop="Remark" label="备注" sortable min-width="130" align="center" show-overflow-tooltip>

+ 18 - 1
src/dashoo.cn/frontend_web/src/pages/system/organize.vue

@@ -12,6 +12,8 @@
         <span style="float: right;">
           <el-button size="mini" type="primary" style="margin-left:10px; margin-top: -4px;" @click="opendatadialog(1,null,-1);resetForm('organizeform')">新增组织</el-button>
           <el-button size="mini" type="primary" style="margin-right:5px; margin-top: -4px;" @click="syncOrganize" :loading="syncOrgLoading">同步RTX部门</el-button>
+          <!--<el-button size="mini" type="primary" style="margin-right:5px; margin-top: -4px;"  :loading="loading" @click="syncUser">同步用户</el-button>-->
+          <!--<el-button size="mini" type="primary" style="margin-right:5px; margin-top: -4px;"  :loading="loadingTmp" @click="syncTmpUserDept">同步tmp用户部门</el-button>-->
         </span>
         <el-form ref="form" :inline="true" style="float: right; margin-top: -10px">
           <el-form-item label="组织名称">
@@ -113,6 +115,8 @@
 
     data() {
       return {
+        loading: false,
+        loadingTmp: false,
         syncOrgLoading: false,
         downloading: true,
         selectedNode: 0,
@@ -289,6 +293,19 @@
         this.currentPage = value
         this.initData()
       },
+      syncUser () {
+        this.loading = true
+        rtxApi.syncUser(this.$axios).then(res => {
+          this.loading = false
+          alert('同步成功' + res.data.StartIndex + '失败' + res.data.PageIndex)
+        })
+      },
+      syncTmpUserDept () {
+        this.loadingTmp = true
+        rtxApi.syncUserDept(this.$axios).then(res => {
+          this.loadingTmp = false
+        })
+      },
       syncOrganize () {
         let _this = this
         _this.syncOrgLoading = true
@@ -312,7 +329,7 @@
         })
       },
 
-      jstimehandle(val) {
+      jstimehandle (val) {
         val = val.replace('T', ' ')
         return val.substring(0, 19)
       },