mirror of
https://github.com/frappe/erpnext.git
synced 2026-08-24 12:36:37 +00:00
fix(asset): resolve backport conflicts for asset repair on fully depreciated assets
Conflict markers were left unresolved in the Mergify backport (PR #57076), breaking JSON parsing and JS linting. v15-hotfix's asset.js already shows the Repair Asset button unconditionally for docstatus==1, so no button changes are needed there; only the link_filters and modified timestamp in asset_repair.json needed resolving, preserving the existing null filter entry. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -94,35 +94,6 @@ frappe.ui.form.on("Asset", {
|
||||
|
||||
if (frm.doc.docstatus == 1) {
|
||||
if (["Submitted", "Partially Depreciated", "Fully Depreciated"].includes(frm.doc.status)) {
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
if (frm.doc.maintenance_required && !frm.doc.maintenance_schedule) {
|
||||
frm.add_custom_button(
|
||||
__("Maintain Asset"),
|
||||
function () {
|
||||
frm.trigger("create_asset_maintenance");
|
||||
},
|
||||
__("Actions")
|
||||
);
|
||||
}
|
||||
if (frm.doc.status === "Fully Depreciated") {
|
||||
frm.add_custom_button(
|
||||
__("Asset Repair"),
|
||||
function () {
|
||||
frm.trigger("create_asset_repair");
|
||||
},
|
||||
__("Actions")
|
||||
);
|
||||
}
|
||||
frm.add_custom_button(
|
||||
__("Split Asset"),
|
||||
function () {
|
||||
frm.trigger("split_asset");
|
||||
},
|
||||
__("Actions")
|
||||
);
|
||||
|
||||
>>>>>>> c7774a95e5 (fix(asset): allow asset repair creation for fully depreciated assets)
|
||||
frm.add_custom_button(
|
||||
__("Transfer Asset"),
|
||||
function () {
|
||||
|
||||
@@ -140,11 +140,7 @@
|
||||
"fieldtype": "Link",
|
||||
"in_list_view": 1,
|
||||
"label": "Asset",
|
||||
<<<<<<< HEAD
|
||||
"link_filters": "[[\"Asset\",\"status\",\"not in\",[\"Work In Progress\",\"Capitalized\",\"Fully Depreciated\",\"Sold\",\"Scrapped\",\"Cancelled\",null]]]",
|
||||
=======
|
||||
"link_filters": "[[\"Asset\",\"status\",\"not in\",[\"Work In Progress\",\"Capitalized\",\"Sold\",\"Scrapped\",\"Cancelled\"]]]",
|
||||
>>>>>>> c7774a95e5 (fix(asset): allow asset repair creation for fully depreciated assets)
|
||||
"link_filters": "[[\"Asset\",\"status\",\"not in\",[\"Work In Progress\",\"Capitalized\",\"Sold\",\"Scrapped\",\"Cancelled\",null]]]",
|
||||
"options": "Asset",
|
||||
"reqd": 1
|
||||
},
|
||||
@@ -254,18 +250,8 @@
|
||||
],
|
||||
"index_web_pages_for_search": 1,
|
||||
"is_submittable": 1,
|
||||
<<<<<<< HEAD
|
||||
"links": [],
|
||||
"modified": "2026-01-06 15:48:13.862505",
|
||||
=======
|
||||
"links": [
|
||||
{
|
||||
"link_doctype": "Stock Entry",
|
||||
"link_fieldname": "asset_repair"
|
||||
}
|
||||
],
|
||||
"modified": "2026-06-20 15:43:54.943335",
|
||||
>>>>>>> c7774a95e5 (fix(asset): allow asset repair creation for fully depreciated assets)
|
||||
"modified": "2026-07-13 12:00:00.000000",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Assets",
|
||||
"name": "Asset Repair",
|
||||
|
||||
Reference in New Issue
Block a user