aboutsummaryrefslogtreecommitdiff
path: root/libbrep/package.hxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2017-06-10 02:11:14 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2017-06-14 17:51:00 +0300
commitae4eb4360376a52866b4737ba8f0fc76255821a0 (patch)
tree5d98093c1fdb604bfded1a88d8bbd5803ffbb505 /libbrep/package.hxx
parentda701337ca32a54682a0daddcd2ab85a2f886a18 (diff)
Support displaying unbuilt package configurations on builds page
Diffstat (limited to 'libbrep/package.hxx')
-rw-r--r--libbrep/package.hxx13
1 files changed, 13 insertions, 0 deletions
diff --git a/libbrep/package.hxx b/libbrep/package.hxx
index ee51778..4693a34 100644
--- a/libbrep/package.hxx
+++ b/libbrep/package.hxx
@@ -495,6 +495,19 @@ namespace brep
//
#pragma db member(version) set(this.version.init (this.id.version, (?)))
};
+
+ #pragma db view object(package) \
+ object(repository: package::internal_repository)
+ struct package_version_count
+ {
+ size_t result;
+
+ operator size_t () const {return result;}
+
+ // Database mapping.
+ //
+ #pragma db member(result) column("count(" + package::id.name + ")")
+ };
}
#endif // LIBBREP_PACKAGE_HXX