填报修改某个单元格数据该行时间为更新时间为啥全部的时间都变成更新时间了只改了一行的数据

填报修改某个单元格数据 该行时间为更新时间 为啥全部的时间都变成更新时间了 只改了一行的数据image.png

FineReport 疯狂的原味鸡 发布于 2023-7-20 16:58 (编辑于 2023-7-20 17:01)
1min目标场景问卷 立即参与
回答问题
悬赏:3 F币 + 添加悬赏
提示:增加悬赏、完善问题、追问等操作,可使您的问题被置顶,并向所有关注者发送通知
共2回答
最佳回答
1
Z4u3z1Lv6专家互助
发布于2023-7-20 17:02(编辑于 2023-7-21 09:46)

找个单元格比如 A1 输入公式NOW()

然后这个字段的值用A1,最后勾选未修改不提交

----------------

Date.prototype.Format = function (fmt) { // author: meizz

  var o = {

    "M+": this.getMonth() + 1, // 月份

    "d+": this.getDate(), // 日

    "h+": this.getHours(), // 小时

    "m+": this.getMinutes(), // 分

    "s+": this.getSeconds(), // 秒

    "q+": Math.floor((this.getMonth() + 3) / 3), // 季度

    "S": this.getMilliseconds() // 毫秒

  };

  if (/(y+)/.test(fmt))

    fmt = fmt.replace(RegExp.$1, (this.getFullYear() + "").substr(4 - RegExp.$1.length));

  for (var k in o)

    if (new RegExp("(" + k + ")").test(fmt)) fmt = fmt.replace(RegExp.$1, (RegExp.$1.length == 1) ? (o[k]) : (("00" + o[k]).substr(("" + o[k]).length)));

      return fmt;

}

var location = this.options.location; //获取当前控件的位置

var cr = FR.cellStr2ColumnRow(location);

var col = cr.col; //列号

var ro = cr.row; //行号

var b=new Date().Format("yyyy-MM-dd hh:mm:ss");

contentPane.setCellValue(0, col+2, ro, b);

----------------

WorkBook1.rar

image.png

最佳回答
1
用户k6280494Lv6资深互助
发布于2023-7-20 16:59

截图看下你的填报属性,怎么设置的

  • 2关注人数
  • 1099浏览人数
  • 最后回答于:2023-7-21 09:46
    请选择关闭问题的原因
    确定 取消
    返回顶部