This commit is contained in:
ChuXun
2026-01-04 17:58:44 +08:00
parent cf8f4c5c3a
commit ec3b5157fe
180 changed files with 4677 additions and 18032 deletions

View File

@@ -502,12 +502,36 @@
document.body.removeChild(form);
},report: function () {
var imgSrc = this.$image[0].currentSrc;
var objectId = imgSrc.substring(imgSrc.lastIndexOf("/")+1, imgSrc.lastIndexOf("."));
var objectId = this.getPathObjectId(imgSrc);
var params = new Array();
params.push({'name':'type', 'value':'image'});
params.push({'name':'sourceIdstr', 'value': jQuery.md5(objectId)});
params.push({'name':'sourceContent', 'value': encodeURIComponent(JSON.stringify({'image':imgSrc}))});
this.formutils('https://groupweb.chaoxing.com/pc/report/reportIndex', params, '_blank');
}, getPathObjectId: function (path) {
if (!path || path.length === 0) {
return "";
}
var arr = path.split("/");
if (arr.length < 1) {
return "";
}
var objectId;
if (path.indexOf("star4") > -1 && arr.length > 1) {
objectId = arr[arr.length - 2];
} else {
objectId = arr[arr.length - 1];
if (objectId.indexOf(".") > -1) {
objectId = objectId.split(".")[0];
}
}
if (this.isValidObjectId(objectId)) {
return objectId;
} else {
return "";
}
}, isValidObjectId: function (objectId) {
return typeof objectId != 'undefined' && (objectId.length === 32 || objectId.length === 24);
}
}, u.DEFAULTS = {
inline: !1,