Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set Modified flag prior to export #43

Open
isc-tleavitt opened this issue Jun 7, 2024 · 1 comment
Open

Set Modified flag prior to export #43

isc-tleavitt opened this issue Jun 7, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@isc-tleavitt
Copy link
Collaborator

In pkg.isc.codetidy.Utils:Run need to add:

		// Allow source control to export, etc.
		set sourceControl.Modified(pInternalName) = 1
		do sourceControl.OnAfterSave(pInternalName)
@isc-tleavitt isc-tleavitt added the bug Something isn't working label Jun 7, 2024
@isc-tleavitt
Copy link
Collaborator Author

Might also make sense to put this in Composite:

Method OnAfterSave(InternalName As %String, Object As %RegisteredObject = {$$$NULLOREF}) As %Status
{
	new $namespace
	set InternalName = ..CorrectInternalNames(InternalName)
	set tExtension = ..GetPrimaryExtension(InternalName)
	if '$isobject(tExtension) {
		quit ##super(.InternalName, .Object)
	}
	
	// Code required to run CodeTidy's OnAfterSave function
	set classes = ..GetSubExtensionClasses()
	set pointer = 0
	while $listnext(classes, pointer, class) {
		set extension = ..GetSubExtension(class)
		if $isobject(extension) {
			do $method(extension, "OnAfterSave", .InternalName, .Object)
			merge ..Modified = extension.Modified
		}
	}
	
	merge tExtension.Modified = ..Modified
	quit $method(tExtension, "OnAfterSave", .InternalName, .Object)
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant