Jianghan 5 سال پیش
والد
کامیت
8d46bf0a3b

+ 228 - 4
src/service/repair_rule.go

@@ -2,6 +2,7 @@ package service
 
 import (
 	"encoding/json"
+	"io/ioutil"
 	"log"
 	mu "mfw/util"
 	"net"
@@ -9,6 +10,7 @@ import (
 	"qfw/util/elastic"
 	"qfw/util/redis"
 	"regexp"
+	"strings"
 	"time"
 	"udptask"
 	. "util"
@@ -32,6 +34,11 @@ type RepairRule struct {
 	repairSave    xweb.Mapper `xweb:"/service/jianyu/save"`
 	repairCreate  xweb.Mapper `xweb:"/service/jianyu/create"`
 	repairNewSave xweb.Mapper `xweb:"/service/jianyu/newSave"`
+
+	repairBulk	  xweb.Mapper `xweb:"/service/jianyu/bulk_repair"`
+	repairImport  xweb.Mapper `xweb:"/service/jianyu/importData"`
+	repairModify  xweb.Mapper `xweb:"/service/jianyu/modifySave"`
+	repairRecord  xweb.Mapper `xweb:"/service/jianyu/modifyRecord"`
 }
 
 func (jy *RepairRule) RepairList() {
@@ -236,6 +243,7 @@ func (jy *RepairRule) RepairSave() {
 		coll := qu.ObjToString(request_data["coll"])
 		id := qu.ObjToString((*updata)["_id"])
 		old_data, _ := JYMgo.FindById(coll, id, "") //记录当前表的源数据
+		delete(*old_data, "_id")
 		reasons := qu.ObjToString(request_data["reasons"])
 		contenthtml := qu.ObjToString(request_data["contenthtml"])
 		detail := qu.ObjToString(request_data["detail"])
@@ -244,7 +252,15 @@ func (jy *RepairRule) RepairSave() {
 		(*updata)["contenthtml"] = contenthtml
 		(*updata)["detail"] = detailClear(detail)
 		//变更字段
-		(*updata)["modifyinfo"] = modifyinfo
+		if (*updata)["modifyinfo"] != nil {
+			tmpinfo := (*updata)["modifyinfo"].(map[string]interface{})
+			for k, v := range *modifyinfo{
+				tmpinfo[k] = v
+			}
+			(*updata)["modifyinfo"] = tmpinfo
+		}else {
+			(*updata)["modifyinfo"] = modifyinfo
+		}
 
 		//处理个别字段
 		if val, ok := (*updata)["comeintime"]; ok {
@@ -290,7 +306,7 @@ func (jy *RepairRule) RepairSave() {
 			}
 		}
 
-		rep := JYMgo.Update(coll, query, set, false, true)
+		rep := JYMgo.Update(coll, query, set, false, false)
 		qu.Debug("mgo id:" + id + "------", rep)
 		if !rep {
 			jy.ServeJson(map[string]interface{}{
@@ -339,6 +355,7 @@ func (jy *RepairRule) RepairSave() {
 				"s_backupid":     id,
 				"o_oldinfo":      old_data,
 				"o_newinfo":      updata,
+				"modifyinfo": 	  modifyinfo,
 			}
 			Mgo.Save(JyRecord, log_data)
 
@@ -437,6 +454,213 @@ func detailClear(detail string) string {
 	return new_s
 }
 
-func s()  {
-	elastic.AnalyQuery()
+func (jy *RepairRule) RepairBulk()  {
+	defer qu.Catch()
+	jy.Render("repair/jianyu_bulk.html")
+}
+
+func (jy *RepairRule) RepairRecord() {
+	defer qu.Catch()
+	if jy.Method() == "POST" {
+		start, _ := jy.GetInteger("start")
+		limit, _ := jy.GetInteger("length")
+		draw, _ := jy.GetInteger("draw")
+		searchStr := jy.GetString("search[value]")
+		search := strings.TrimSpace(searchStr)
+		query := bson.M{}
+		if search != "" {
+			query["$or"] = []interface{}{
+				bson.M{"s_customer": bson.M{"$regex": search}},
+				bson.M{"s_tagname": bson.M{"$regex": search}},
+			}
+		}
+
+		data, _ := Mgo.Find("jymodifylog", query, `{"i_modifytime": -1}`, nil, false, start, limit)
+		count := Mgo.Count("jymodifylog", query)
+		jy.ServeJson(map[string]interface{}{
+			"draw":            draw,
+			"data":            data,
+			"recordsFiltered": count,
+			"recordsTotal":    count,
+		})
+	} else {
+		jy.Render("repair/jianyu_bulk.html")
+	}
+}
+
+func (jy *RepairRule) RepairImport() {
+	defer qu.Catch()
+	if jy.Method() == "POST" {
+		mf, _, err := jy.GetFile("xlsx")
+		if err == nil {
+			binary, err := ioutil.ReadAll(mf)
+			if err == nil {
+				data, err := ParsJyData(binary)
+				qu.Debug(err)
+				if err == nil {
+					jy.ServeJson(map[string]interface{}{
+						"data": data,
+						"rep":   true,
+					})
+					return
+				}
+			}
+		}
+		jy.ServeJson(map[string]interface{}{
+			"rep": false,
+		})
+	}
+}
+
+func (jy *RepairRule) RepairModify() {
+	defer qu.Catch()
+	if jy.Method() == "POST" {
+		user := jy.GetSession("user").(map[string]interface{})
+		data := GetPostForm(jy.Request)
+		var updata []map[string]interface{}
+		json.Unmarshal([]byte(qu.ObjToString(data["data"])), &updata)
+		var errs []map[string]interface{}
+		for _, tmp := range updata{
+			err := ModifyData(tmp, user)
+			if err != nil {
+				errs = append(errs, err)
+			}
+			time.Sleep(time.Millisecond * 1)
+		}
+
+		if len(errs) > 0 {
+			jy.ServeJson(map[string]interface{}{
+				"rep": false,
+				"data": errs,
+			})
+		}else {
+			jy.ServeJson(map[string]interface{}{
+				"rep": true,
+			})
+		}
+	}
+}
+
+func ModifyData(tmp map[string]interface{}, user map[string]interface{}) (err map[string]interface{}) {
+	id := qu.ObjToString(tmp["_id"])
+	old_data, _ := JYMgo.FindById(JyCollNameOne, id, `{}`)
+	coll := ""
+	if old_data != nil {
+		coll = JyCollNameOne
+	}else {
+		t, _ := JYMgo.FindById(JyCollNameTwo, id, `{}`)
+		if t != nil {
+			return map[string]interface{}{"_id": id, "err": "未找到数据"}
+		}else {
+			old_data = t
+		}
+	}
+	delete(*old_data, "_id")
+	new_data := Copy(*old_data).(map[string]interface{})
+	modifyinfo := make(map[string]interface{})
+	del_data := make(map[string]interface{})
+	for k, v := range tmp{
+		if k == "_id" {
+			continue
+		}
+		if strings.EqualFold(strings.ToUpper(qu.ObjToString(v)), "DEL") {
+			del_data[k] = ""
+			delete(new_data, k)
+		}else {
+			new_data[k] = v
+		}
+		modifyinfo[k] = true
+	}
+	//变更字段
+	if new_data["modifyinfo"] != nil {
+		tmpinfo := new_data["modifyinfo"].(map[string]interface{})
+		for k, v := range modifyinfo{
+			tmpinfo[k] = v
+		}
+		new_data["modifyinfo"] = tmpinfo
+	}else {
+		new_data["modifyinfo"] = modifyinfo
+	}
+	if val, ok := new_data["comeintime"]; ok {
+		new_data["comeintime"] = qu.Int64All(val)
+	} else {
+		curtime := time.Now().Unix()
+		new_data["comeintime"] = curtime
+	}
+
+	if val, ok := new_data["publishtime"]; ok {
+		new_data["publishtime"] = qu.Int64All(val)
+	} else {
+		pt := int64(0)
+		new_data["publishtime"] = pt
+	}
+	if val, ok := new_data["infoformat"]; ok {
+		new_data["infoformat"] = qu.IntAll(val)
+	} else {
+		new_data["infoformat"] = 1
+	}
+	new_data["extracttype"] = 0
+	query := bson.M{
+		"_id": qu.StringTOBsonId(id),
+	}
+	delete(new_data, "_id")
+	var set map[string]interface{}
+	if len(del_data) == 0 {
+		set = bson.M {
+			"$set": new_data,
+		}
+	}else {
+		set = bson.M {
+			"$set": new_data,
+			"$unset": del_data,
+		}
+	}
+	rep := JYMgo.Update(coll, query, set, false, false)
+	if !rep {
+		return map[string]interface{}{"_id": id, "err": "更新失败"}
+	}
+
+	indexNode := *qu.ObjToMap(Sysconfig["indexNode"])
+	param := map[string]interface{}{"coll": coll}
+	by, _ := json.Marshal(map[string]interface{}{
+		"gteid": id,
+		"lteid": id,
+		"stype": qu.ObjToString(indexNode["stype"]),
+		"param": param,
+	})
+	addr := &net.UDPAddr{
+		IP:   net.ParseIP(indexNode["addr"].(string)),
+		Port: qu.IntAll(indexNode["port"]),
+	}
+	udptask.Udpclient.WriteUdp(by, mu.OP_TYPE_DATA, addr)
+
+	//删除redis 指定key
+	jyredis := redis.RedisPool[RedisJYName].Get()
+	defer jyredis.Close()
+	if _, err := jyredis.Do("SELECT", 0); err != nil {
+		log.Println("更新-redis-select-db失败")
+	} else {
+		delName1 := RedisDelKey1 + id
+		if _, err1 := jyredis.Do("DEL", delName1); err1 != nil {
+			log.Println("更新-del-redis-fail:", delName1)
+		}
+		delName2 := RedisDelKey2 + id
+		if _, err2 := jyredis.Do("DEL", delName2); err2 != nil {
+			log.Println("更新-del-redis-fail:", delName2)
+		}
+	}
+
+	delete(new_data, "modifyinfo")
+	log_data := map[string]interface{}{
+		"s_modifyuser":   user["name"],
+		"s_type":         2,
+		"i_modifytime":   time.Now().Unix(),
+		"s_modifyreason": "批量修改",
+		"s_backupid":     id,
+		"o_oldinfo":      old_data,
+		"o_newinfo":      new_data,
+		"modifyinfo": 	  modifyinfo,
+	}
+	Mgo.Save(JyRecord, log_data)
+	return nil
 }

+ 119 - 0
src/util/deepcopy.go

@@ -0,0 +1,119 @@
+package util
+
+import (
+	"reflect"
+	"time"
+)
+
+// Interface for delegating copy process to type
+type Interface interface {
+	DeepCopy() interface{}
+}
+
+// Iface is an alias to Copy; this exists for backwards compatibility reasons.
+func Iface(iface interface{}) interface{} {
+	return Copy(iface)
+}
+
+// Copy creates a deep copy of whatever is passed to it and returns the copy
+// in an interface{}.  The returned value will need to be asserted to the
+// correct type.
+func Copy(src interface{}) interface{} {
+	if src == nil {
+		return nil
+	}
+
+	// Make the interface a reflect.Value
+	original := reflect.ValueOf(src)
+
+	// Make a copy of the same type as the original.
+	cpy := reflect.New(original.Type()).Elem()
+
+	// Recursively copy the original.
+	copyRecursive(original, cpy)
+
+	// Return the copy as an interface.
+	return cpy.Interface()
+}
+
+// copyRecursive does the actual copying of the interface. It currently has
+// limited support for what it can handle. Add as needed.
+func copyRecursive(original, cpy reflect.Value) {
+	// check for implement deepcopy.Interface
+	if original.CanInterface() {
+		if copier, ok := original.Interface().(Interface); ok {
+			cpy.Set(reflect.ValueOf(copier.DeepCopy()))
+			return
+		}
+	}
+
+	// handle according to original's Kind
+	switch original.Kind() {
+	case reflect.Ptr:
+		// Get the actual value being pointed to.
+		originalValue := original.Elem()
+
+		// if  it isn't valid, return.
+		if !originalValue.IsValid() {
+			return
+		}
+		cpy.Set(reflect.New(originalValue.Type()))
+		copyRecursive(originalValue, cpy.Elem())
+
+	case reflect.Interface:
+		// If this is a nil, don't do anything
+		if original.IsNil() {
+			return
+		}
+		// Get the value for the interface, not the pointer.
+		originalValue := original.Elem()
+
+		// Get the value by calling Elem().
+		copyValue := reflect.New(originalValue.Type()).Elem()
+		copyRecursive(originalValue, copyValue)
+		cpy.Set(copyValue)
+
+	case reflect.Struct:
+		t, ok := original.Interface().(time.Time)
+		if ok {
+			cpy.Set(reflect.ValueOf(t))
+			return
+		}
+		// Go through each field of the struct and copy it.
+		for i := 0; i < original.NumField(); i++ {
+			// The Type's StructField for a given field is checked to see if StructField.PkgPath
+			// is set to determine if the field is exported or not because CanSet() returns false
+			// for settable fields.  I'm not sure why.  -mohae
+			if original.Type().Field(i).PkgPath != "" {
+				continue
+			}
+			copyRecursive(original.Field(i), cpy.Field(i))
+		}
+
+	case reflect.Slice:
+		if original.IsNil() {
+			return
+		}
+		// Make a new slice and copy each element.
+		cpy.Set(reflect.MakeSlice(original.Type(), original.Len(), original.Cap()))
+		for i := 0; i < original.Len(); i++ {
+			copyRecursive(original.Index(i), cpy.Index(i))
+		}
+
+	case reflect.Map:
+		if original.IsNil() {
+			return
+		}
+		cpy.Set(reflect.MakeMap(original.Type()))
+		for _, key := range original.MapKeys() {
+			originalValue := original.MapIndex(key)
+			copyValue := reflect.New(originalValue.Type()).Elem()
+			copyRecursive(originalValue, copyValue)
+			copyKey := Copy(key.Interface())
+			cpy.SetMapIndex(reflect.ValueOf(copyKey), copyValue)
+		}
+
+	default:
+		cpy.Set(original)
+	}
+}

+ 32 - 0
src/util/parsxlsx.go

@@ -350,3 +350,35 @@ func numValToWord(numval string) (word string) {
 	}
 	return
 }
+
+/**
+ * 导入剑鱼批量修改数据
+ */
+func ParsJyData(filebyte []byte) ([]map[string]interface{}, error) {
+	var jyData []map[string]interface{}
+	var keyName []string
+	file, err := xlsx.OpenBinary(filebyte)
+	if err != nil {
+		return jyData, err
+	}
+
+	for i, v := range file.Sheets[0].Rows {
+		data := make(map[string]interface{})
+		for ii, vv := range v.Cells {
+			if i == 0 {
+				keyName = append(keyName, vv.Value)
+			}else {
+				if strings.EqualFold(strings.ToUpper(vv.Value), "DEL") {
+					data[keyName[ii]] = vv.Value
+				}else if vv.Value != "" {
+					data[keyName[ii]] = vv.Value
+				}
+			}
+		}
+		if len(data) > 0 {
+			jyData = append(jyData, data)
+		}
+	}
+
+	return jyData, nil
+}

+ 232 - 0
src/web/templates/repair/jianyu_bulk.html

@@ -0,0 +1,232 @@
+{{include "com/inc.html"}}
+<!-- Main Header -->
+{{include "com/header.html"}}
+<!-- Left side column. 权限菜单 -->
+{{include "com/menu.html"}}
+
+<div class="content-wrapper" id="showbtn">
+    <section class="content-header">
+        <h1>
+            <small>
+                <button class="btn btn-success btn-sm" onclick="importData()"><i class="fa fa-fw fa-cloud-upload fa-lg"></i>导入修改的公告</button>
+                <form style="display:none" id='uploadform' method='post'>
+                    <input type='file' name='xlsx' id='file'/>
+                </form>
+            </small>
+        </h1>
+        <ol class="breadcrumb">
+            <li><a href="#"><i class="fa fa-dashboard"></i> 首页</a></li>
+            <li><a href="/service/jianyu/repair"> 剑鱼维护</a></li>
+        </ol>
+        <br/>
+    </section>
+    <!-- Main content -->
+    <section class="content">
+        <div class="row">
+            <div class="col-xs-12">
+                <div class="box">
+                    <div class="box-body">
+                        <h3>修改记录</h3>
+                        <table id="dataTable" class="table table-bordered table-hover">
+                            <thead>
+                            <tr>
+                                <th>编号</th>
+                                <th>数据ID</th>
+                                <th>修改人</th>
+                                <th>修改时间</th>
+                                <th>修改字段</th>
+                                <th>修改原因</th>
+                            </tr>
+                            </thead>
+                        </table>
+                    </div>
+                    <!-- /.box-body -->
+                </div>
+                <!-- /.box -->
+            </div>
+        </div>
+    </section>
+</div>
+
+<!-- 导入修改数据model -->
+<div class="modal fade" id="modal-data" tabindex="-1" role="dialog" aria-hidden="true">
+    <div class="modal-dialog" style="width: 60%">
+        <div class="modal-content">
+            <div class="modal-header">
+                <div class="modal-header">
+                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
+                    <div class="edit-form">
+                        <div class="edit-info">
+                            <span class="info"><i class="fa fa-fw fa-tags fa-lg"></i>修改数据</span>
+                        </div>
+                        <div class="content">
+                            <table id="modifyData" class="table table-bordered">
+                                <thead>
+                                <tr>
+                                    <th>编号</th>
+                                    <th>修改内容</th>
+                                </tr>
+                                </thead>
+                            </table>
+                        </div>
+                    </div>
+                </div>
+                <div class="modal-footer">
+                    <input type="button" onclick="saveModify()" class="btn btn-primary saveBtn" value="修改">
+                    <input type="button" onclick="cancelModel()" class="btn btn-default" style="margin-left: 24px" value="取消">
+                </div>
+            </div>
+        </div>
+    </div><!-- /.modal -->
+</div>
+
+{{include "com/dialog.html"}}
+{{include "com/footer.html"}}
+<script>
+    menuActive("/service/jianyu/bulk_repair");
+
+    var curColl = ""
+    var modifyData = {}
+
+    $(document).ready(function () {
+        ttable = $('#dataTable').DataTable({
+            "paging": true,
+            "lengthChange": false,
+            "searching": true,
+            "ordering": false,
+            "info": true,
+            "autoWidth": false,
+            "serverSide": true,
+            "language": {
+                "url": "/dist/js/dataTables.chinese.lang"
+            },
+            "ajax": {
+                "url": "/service/jianyu/modifyRecord",
+                "type": "post",
+                "data": {}
+            },
+            "fnDrawCallback": function () {
+                $("ul.pagination").prepend("&nbsp;&nbsp;&nbsp;转到第 <input type='text' id='changePage'   style='width:20px;'> 页    <a type='text' href='javascript:void(0);' id='dataTable-btn' style='text-align:center'>GO</a>");
+                $('#dataTable-btn').click(function (e) {
+                    var redirectpage = 0
+                    if ($("#changePage").val() && $("#changePage").val() > 0) {
+                        var redirectpage = $("#changePage").val() - 1;
+                    }
+                    ttable.page(redirectpage).draw(false);
+                });
+                this.api().column(0).nodes().each(function(cell, i) {
+                    cell.innerHTML = i + 1;
+                });
+            },
+            "columns": [
+                {"data": null, width:"4%"},
+                {"data": "s_backupid", width: "10%"},
+                {"data": "s_modifyuser", width: "7%"},
+                {"data": "i_modifytime", width:"11%", render: function (val) {
+                        var dt = new Date()
+                        dt.setTime(parseInt(val) * 1000);
+                        return dt.format("yyyy-MM-dd")
+                    }},
+                {"data": function (row) {
+                        var str = ""
+                        for (const rowKey in row["modifyinfo"]) {
+                            str += rowKey + ","
+                        }
+                        return str
+                    }},
+                {"data": "s_modifyreason", width: "15%"}
+            ]
+        });
+
+        modifyData = $('#modifyData').DataTable({
+            "paging": true,
+            "lengthChange": false,
+            "searching": false,
+            "ordering": false,
+            "info": true,
+            "autoWidth": false,
+            "language": {
+                "url": "/dist/js/dataTables.chinese.lang"
+            },
+            "fnDrawCallback": function () {
+                $("ul.pagination").prepend("&nbsp;&nbsp;&nbsp;转到第 <input type='text' id='changePage'   style='width:20px;'> 页    <a type='text' href='javascript:void(0);' id='dataTable-btn' style='text-align:center'>GO</a>");
+                $('#dataTable-btn').click(function (e) {
+                    var redirectpage = 0
+                    if ($("#changePage").val() && $("#changePage").val() > 0) {
+                        var redirectpage = $("#changePage").val() - 1;
+                    }
+                    modifyData.page(redirectpage).draw(false);
+                });
+                this.api().column(0).nodes().each(function(cell, i) {
+                    cell.innerHTML = i + 1;
+                });
+            },
+            "columns": [
+                {"data": null, width: "7%"},
+                {"data": function (row) {
+                    var str = ""
+                        for (const rowKey in row) {
+                            str += rowKey + ":" + row[rowKey] + ","
+                        }
+                    return str
+                    }}
+            ]
+        });
+    });
+    function importData() {
+        $("#file").click();
+    }
+    $(function() {
+        $("#uploadform").find("input").change(function () {
+            var val = $(this).val() ? $(this).val() : "";
+            if (val.indexOf(".xlsx") < 0) {
+                showMsg("文件格式非法", function () {
+                });
+            } else {
+                var myform = new FormData();
+                myform.append('xlsx', $("#file")[0].files[0]);
+                $.ajax({
+                    url: "/service/jianyu/importData",
+                    type: 'POST',
+                    data: myform,
+                    async: false,
+                    contentType: false,
+                    processData: false,
+                    success: function (r) {
+                        if (r.rep) {
+                            modifyData = r.data;
+                            showTip("导入成功", 500);
+                            $('#modifyData').dataTable().fnClearTable();
+                            $('#modifyData').dataTable().fnAddData(r.data);
+                            $('#modal-data').modal("show")
+                        } else {
+                            showTip("导入失败",1000);
+                        }
+                    }
+                })
+            }
+        })
+    });
+
+    function cancelModel() {
+        $('#modal-data').modal("hide")
+    }
+
+    function saveModify() {
+        $.ajax({
+            url: "/service/jianyu/modifySave",
+            type: 'POST',
+            data: {"data": JSON.stringify(modifyData)},
+            success: function (r) {
+                if (r.rep) {
+                    showTip("保存成功", 1000);
+                    ttable.ajax.reload();
+                } else {
+                    showTip("保存失败", 1000);
+                }
+                $('#modal-data').modal("hide")
+            }
+        })
+    }
+
+</script>

+ 3 - 4
src/web/templates/repair/jianyu_create.html

@@ -3,7 +3,6 @@
 {{include "com/header.html"}}
 <!-- Left side column. 权限菜单 -->
 {{include "com/menu.html"}}
-{{include "com/modal.html"}}
 
 <style>
     /* 方法1:设置textarea合适的宽高 */
@@ -32,8 +31,8 @@
         <h1>新增数据</h1>
         <ol class="breadcrumb">
             <li><a href="#"><i class="fa fa-dashboard"></i> 首页</a></li>
-            <li><a href="/service/jianyu/repair">数据中心</a></li>
-            <li><a href="#">添加数据</a></li>
+            <li><a href="/service/jianyu/repair"> 剑鱼维护</a></li>
+            <li><a href="#"> 添加数据</a></li>
         </ol>
     </section>
     <!-- Main content -->
@@ -62,7 +61,7 @@
                     <textarea id="jsonContentHtml" style="width: 100%;height: 300px;padding: 5px"></textarea>
                 </div>
                 <div class="box-body" id="summaryDiv">
-                    <label class="col-sm-2 control-left"><span style="color:red;">* </span>请填写summary</label>
+                    <label class="col-sm-2 control-left">请填写summary</label>
                     <textarea id="summary" style="width: 100%;height: 200px;padding: 5px"></textarea>
                 </div>
             </form>

+ 3 - 13
src/web/templates/repair/jianyu_edit.html

@@ -3,7 +3,6 @@
 {{include "com/header.html"}}
 <!-- Left side column. 权限菜单 -->
 {{include "com/menu.html"}}
-{{include "com/modal.html"}}
 
 <style>
     /* 方法1:设置textarea合适的宽高 */
@@ -33,8 +32,8 @@
         <h1>维护数据</h1>
         <ol class="breadcrumb">
             <li><a href="#"><i class="fa fa-dashboard"></i> 首页</a></li>
-            <li><a href="/service/jianyu/repair">维护中心</a></li>
-            <li><a href="#">修复数据</a></li>
+            <li><a href="/service/jianyu/repair"> 剑鱼维护</a></li>
+            <li><a href="#"> 修复数据</a></li>
         </ol>
     </section>
     <!-- Main content -->
@@ -63,7 +62,7 @@
                     <textarea id="jsonContentHtml" style="width: 100%;height: 300px;padding: 5px"></textarea>
                 </div>
                 <div class="box-body" id="summaryDiv">
-                    <label class="col-sm-2 control-left"><span style="color:red;">* </span>请填写summary</label>
+                    <label class="col-sm-2 control-left">请填写summary</label>
                     <textarea id="summary" style="width: 100%;height: 200px;padding: 5px"></textarea>
                 </div>
             </form>
@@ -200,13 +199,4 @@
         return false
     }
 
-    //查看修改的字段
-    function checkUpdate() {
-
-    }
-
-
-
-
-
 </script>

+ 1 - 2
src/web/templates/repair/jianyu_repair.html

@@ -3,7 +3,6 @@
 {{include "com/header.html"}}
 <!-- Left side column. 权限菜单 -->
 {{include "com/menu.html"}}
-{{include "com/modal.html"}}
 
 <style>
     .j-input__inner {
@@ -47,7 +46,7 @@
         </h1>
         <ol class="breadcrumb">
             <li><a href="#"><i class="fa fa-dashboard"></i> 首页</a></li>
-            <li><a href="/service/jianyu/repair"> 维护中心</a></li>
+            <li><a href="/service/jianyu/repair"> 剑鱼维护</a></li>
         </ol>
 
         <br/>

+ 1 - 1
src/web/templates/task/task_list.html

@@ -83,7 +83,7 @@
                 {"data": "i_updatetime",width:"18%", render: function (val) {
                         var dt = new Date()
                         dt.setTime(parseInt(val) * 1000);
-                        return dt.format("yyyy-MM-dd hh-mm-ss")
+                        return dt.format("yyyy-MM-dd hh:mm:ss")
                     }},
                 {"data": "_id", width:"18%",render: function (val, a, row, pos) {
                         tmp = '<div>' +