feat: add Provider field to appointment form, drive AI claim automation
Adds an optional Provider (NPI) select to the Edit Appointment form, sourced from Settings > NPI Providers. The AI "Claim for Column" batch flow now prefers the appointment's own provider when resolving which provider Selenium should select on the insurance site (e.g. MassHealth rendering provider dropdown), falling back to the existing per-procedure selection, active claim, or first configured provider. Also resyncs packages/db's committed compiled schema/client artifacts with their .ts sources — they had drifted out of sync (some untouched since July), which was silently stripping the new npiProviderId field via stale .strict() zod schemas. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -38,8 +38,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.PaymentCreateWithoutClaimInputObjectZodSchema = exports.PaymentCreateWithoutClaimInputObjectSchema = void 0;
|
||||
const z = __importStar(require("zod"));
|
||||
const prisma_1 = require("../../../generated/prisma");
|
||||
const decimal_js_1 = __importDefault(require("decimal.js"));
|
||||
const PaymentStatus_schema_1 = require("../enums/PaymentStatus.schema");
|
||||
const PatientCreateNestedOneWithoutPaymentInput_schema_1 = require("./PatientCreateNestedOneWithoutPaymentInput.schema");
|
||||
const UserCreateNestedOneWithoutUpdatedPaymentsInput_schema_1 = require("./UserCreateNestedOneWithoutUpdatedPaymentsInput.schema");
|
||||
@@ -48,13 +46,14 @@ const ServiceLineTransactionCreateNestedManyWithoutPaymentInput_schema_1 = requi
|
||||
const ServiceLineCreateNestedManyWithoutPaymentInput_schema_1 = require("./ServiceLineCreateNestedManyWithoutPaymentInput.schema");
|
||||
const CommissionBatchItemCreateNestedManyWithoutPaymentInput_schema_1 = require("./CommissionBatchItemCreateNestedManyWithoutPaymentInput.schema");
|
||||
const decimal_helpers_1 = require("../../helpers/decimal-helpers");
|
||||
const decimal_js_1 = __importDefault(require("decimal.js"));
|
||||
const makeSchema = () => z.object({
|
||||
userId: z.number().int(),
|
||||
totalBilled: z.union([
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'totalBilled' must be a Decimal",
|
||||
@@ -63,7 +62,7 @@ const makeSchema = () => z.object({
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'totalPaid' must be a Decimal",
|
||||
@@ -72,7 +71,7 @@ const makeSchema = () => z.object({
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'totalAdjusted' must be a Decimal",
|
||||
@@ -81,7 +80,7 @@ const makeSchema = () => z.object({
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'totalDue' must be a Decimal",
|
||||
@@ -90,7 +89,7 @@ const makeSchema = () => z.object({
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'mhPaidAmount' must be a Decimal",
|
||||
@@ -99,7 +98,7 @@ const makeSchema = () => z.object({
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'copayment' must be a Decimal",
|
||||
@@ -108,7 +107,7 @@ const makeSchema = () => z.object({
|
||||
z.number(),
|
||||
z.string(),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
z.instanceof(prisma_1.Prisma.Decimal),
|
||||
z.instanceof(decimal_js_1.default),
|
||||
decimal_helpers_1.DecimalJSLikeSchema,
|
||||
]).refine((v) => (0, decimal_helpers_1.isValidDecimalInput)(v), {
|
||||
message: "Field 'adjustment' must be a Decimal",
|
||||
|
||||
Reference in New Issue
Block a user