Removed 'automatic' resolution
This commit is contained in:
parent
944de9398a
commit
9b6e551bad
|
@ -28,7 +28,7 @@ export type FullContract<
|
||||||
isResolved: boolean
|
isResolved: boolean
|
||||||
resolutionTime?: number // When the contract creator resolved the market
|
resolutionTime?: number // When the contract creator resolved the market
|
||||||
resolution?: string
|
resolution?: string
|
||||||
resolutionType: 'manual' | 'combined' | 'automatic'
|
resolutionType: 'manual' | 'combined'
|
||||||
|
|
||||||
closeEmailsSent?: number
|
closeEmailsSent?: number
|
||||||
|
|
||||||
|
@ -98,9 +98,9 @@ export type Numeric = {
|
||||||
}
|
}
|
||||||
|
|
||||||
export type outcomeType = 'BINARY' | 'MULTI' | 'FREE_RESPONSE' | 'NUMERIC'
|
export type outcomeType = 'BINARY' | 'MULTI' | 'FREE_RESPONSE' | 'NUMERIC'
|
||||||
export type resolutionType = 'MANUAL' | 'COMBINED' | 'AUTOMATIC'
|
export type resolutionType = 'MANUAL' | 'COMBINED'
|
||||||
export const OUTCOME_TYPES = ['BINARY', 'MULTI', 'FREE_RESPONSE', 'NUMERIC']
|
export const OUTCOME_TYPES = ['BINARY', 'MULTI', 'FREE_RESPONSE', 'NUMERIC']
|
||||||
export const RESOLUTION_TYPES = ['MANUAL', 'COMBINED', 'AUTOMATIC']
|
export const RESOLUTION_TYPES = ['MANUAL', 'COMBINED']
|
||||||
|
|
||||||
export const MAX_QUESTION_LENGTH = 480
|
export const MAX_QUESTION_LENGTH = 480
|
||||||
export const MAX_DESCRIPTION_LENGTH = 10000
|
export const MAX_DESCRIPTION_LENGTH = 10000
|
||||||
|
|
|
@ -64,6 +64,7 @@ export function getNewContract(
|
||||||
isResolved: false,
|
isResolved: false,
|
||||||
createdTime: Date.now(),
|
createdTime: Date.now(),
|
||||||
closeTime,
|
closeTime,
|
||||||
|
resolutionType: 'manual',
|
||||||
|
|
||||||
volume: 0,
|
volume: 0,
|
||||||
volume24Hours: 0,
|
volume24Hours: 0,
|
||||||
|
|
|
@ -142,11 +142,11 @@ export const createContract = newEndpoint(['POST'], async (req, _res) => {
|
||||||
ante,
|
ante,
|
||||||
closeTime,
|
closeTime,
|
||||||
tags ?? [],
|
tags ?? [],
|
||||||
|
resolutionType,
|
||||||
NUMERIC_BUCKET_COUNT,
|
NUMERIC_BUCKET_COUNT,
|
||||||
min ?? 0,
|
min ?? 0,
|
||||||
max ?? 0,
|
max ?? 0,
|
||||||
manaLimitPerUser ?? 0,
|
manaLimitPerUser ?? 0,
|
||||||
resolutionType,
|
|
||||||
)
|
)
|
||||||
|
|
||||||
if (!isFree && ante) await chargeUser(creator.id, ante, true)
|
if (!isFree && ante) await chargeUser(creator.id, ante, true)
|
||||||
|
|
|
@ -396,17 +396,6 @@ export function NewContract(props: { question: string; tag?: string }) {
|
||||||
/>
|
/>
|
||||||
<span className="label-text">Combined (experimental)</span>
|
<span className="label-text">Combined (experimental)</span>
|
||||||
</label>
|
</label>
|
||||||
<label className="label cursor-pointer gap-2">
|
|
||||||
<input
|
|
||||||
className="radio"
|
|
||||||
type="radio"
|
|
||||||
name="res"
|
|
||||||
checked={resolutionType === 'AUTOMATIC'}
|
|
||||||
value="AUTOMATIC"
|
|
||||||
onChange={() => setResolutionType('AUTOMATIC')}
|
|
||||||
/>
|
|
||||||
<span className="label-text">Automatic (experimental)</span>
|
|
||||||
</label>
|
|
||||||
</Row>
|
</Row>
|
||||||
<Spacer h={4} />
|
<Spacer h={4} />
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user