Working memory performance is modulated by the level of dopamine (DA) D1 receptors stimulation in the prefrontal cortex (PFC). This modulation is exerted at different time scales. Injection of D1 agonists/antagonists exerts a long-lasting influence (several minutes or hours) on PFC pyramidal neurons. In contrast, during performance of a cognitive task, the duration of the postsynaptic effect of phasic DA release is short lasting. The functional relationships of these two time scales of DA modulation remain poorly understood. Here we propose a model that combines these two time scales of DA modulation on a prefrontal neural network. The model links the cellular and behavioral levels during performance of the delayed alternation task. The network, which represents the activity of deep-layer pyramidal neurons with intrinsic neuronal properties, exhibits two stable states of activity that can be switched on and off by excitatory inputs from long-distance cortical areas arriving in superficial layers. These stable states allow PFC neurons to maintain representations during the delay period. The role of an increase of DA receptors stimulation is to restrict inputs arriving on the prefrontal network. The model explains how the level of working memory performance follows an inverted U-shape with an increased stimulation of DA D1 receptors. The model predicts that (1) D1 receptor agonists increase perseverations, (2) D1 antagonists increase distractability, and (3) the duration of the postsynaptic effect of phasic DA release in the PFC is adjusted to the delay period of the task. These results show how the precise duration of the postsynaptic effect of phasic DA release influences behavioral performance during a simple cognitive task.